/*
* Plugin Name: EDR² Check-in System
* Description: Styles for the EDR² Check-in System plugin.
*/

/* General form styling */
.edr2-checkin-form {
    background-color: #f9f9f9;
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 5px;
    max-width: 500px;
    margin: 20px auto;
}

.edr2-checkin-form h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.edr2-form-group {
    margin-bottom: 15px;
}

.edr2-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #555;
}

.edr2-form-group input[type="text"],
.edr2-form-group input[type="email"],
.edr2-form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box; /* Ensures padding doesn't increase total width */
}

.edr2-form-group input[type="text"]:focus,
.edr2-form-group input[type="email"]:focus,
.edr2-form-group textarea:focus {
    border-color: #0073aa;
    outline: none;
    box-shadow: 0 0 5px rgba(0, 115, 170, 0.3);
}

.edr2-form-group textarea {
    resize: vertical; /* Allow vertical resizing */
}

/* Buttons */
.edr2-checkin-button {
    display: inline-block;
    background-color: #0073aa;
    color: white;
    padding: 10px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
}

.edr2-checkin-button:hover {
    background-color: #005177;
}

.edr2-checkin-button[type="submit"] {
    width: 100%;
    margin-top: 10px;
}

/* Modal Styling */
.edr2-checkin-modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 1000; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
    justify-content: center;
    align-items: center;
    padding-top: 50px;
}

.edr2-checkin-modal-content {
    background-color: #fff;
    margin: auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2), 0 6px 20px 0 rgba(0,0,0,0.19);
}

.edr2-checkin-modal-content h2 {
    margin-top: 0;
    color: #333;
}

.edr2-checkin-modal-content p {
    margin-bottom: 20px;
    color: #666;
}

.edr2-checkin-modal-content .edr2-checkin-button {
    margin: 5px;
}

.edr2-register-prompt {
    margin-top: 16px;
    font-size: 14px;
    color: #555;
}

.edr2-register-link {
    margin-left: 6px;
    font-weight: 600;
}

/* Messages */
.edr2-checkin-message {
    margin-top: 15px;
    padding: 10px;
    border-radius: 4px;
    text-align: center;
    white-space: pre-wrap;
}

.edr2-checkin-message.success {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.edr2-checkin-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

.edr2-checkin-message.info {
    background-color: #d1ecf1;
    color: #0c5460;
    border-color: #bee5eb;
}

.edr2-qr-generator {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px auto;
    width: 100%;
}

.edr2-qr-generator canvas,
.edr2-qr-generator img {
    max-width: 100%;
    height: auto !important;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    margin: 0 auto;
}

/* Hide page title on the check-in page */
.page-id-3075 .page-title {
    display: none;
}

.edr2-settings-tab-navigation {
    margin-top: 24px;
    margin-bottom: 0;
}

.edr2-tab-panels {
    border: 1px solid #ccd0d4;
    border-top: none;
    background-color: #ffffff;
    padding: 24px;
    margin-top: 0;
}

.edr2-settings-tab-panel {
    display: none;
}

.edr2-settings-tab-panel.active {
    display: block;
}

.edr2-dashboard-counts {
    display: flex;
    gap: 12px;
    margin: 0 0 12px 0;
}

.edr2-dashboard-entry-badge-icon {
    display: inline-block;
    margin-right: 4px;
    color: #8a5200;
    line-height: 1;
}

.edr2-dashboard-count-box {
    flex: 1;
    padding: 8px 10px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    background: #fff;
}

.edr2-dashboard-count-label {
    font-size: 12px;
    color: #646970;
}

.edr2-dashboard-count-value {
    font-size: 20px;
    font-weight: 600;
    line-height: 1.2;
}

.edr2-dashboard-qr-heartbeat {
    margin: 0 0 12px 0;
    padding: 8px 10px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    background: #fff;
}

.edr2-dashboard-qr-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.edr2-dashboard-qr-label {
    font-size: 12px;
    color: #646970;
}

.edr2-dashboard-qr-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
}

.edr2-dashboard-qr-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.edr2-dashboard-qr-time {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.35;
}

.edr2-dashboard-qr-subtext {
    font-size: 12px;
    color: #646970;
}

/* Role tags styles */
.edr2-role-tags {
    border: 1px solid #8c8f94 !important;
    border-radius: 4px;
    background: #fff;
    padding: 4px !important;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    min-height: 40px;
}

.edr2-role-tag {
    background: #f0f0f1 !important;
    border: 1px solid #c3c4c7 !important;
    border-radius: 5px !important;
    padding: 2px 8px !important;
    font-size: 12px !important;
    color: #3c434a !important;
}

.edr2-role-tag.edr2-role-tag-missing {
    background: #fff1f0 !important;
    border-color: #d63638 !important;
    color: #d63638 !important;
    text-decoration: line-through;
}

.edr2-remove-role {
    margin-left: 4px;
    color: #d63638 !important;
}

.edr2-role-input {
    flex: 1;
    min-width: 150px;
    border: none !important;
    box-shadow: none !important;
    padding: 4px 8px !important;
    height: auto !important;
    background: transparent !important;
}

/* Autocomplete styles */
.ui-autocomplete {
    background: #fff;
    border: 1px solid #c3c4c7;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    z-index: 999999 !important;
    padding: 0;
    margin: 0;
    list-style: none;
    max-height: 300px;
    overflow-y: auto;
}

.ui-autocomplete .ui-menu-item-wrapper {
    padding: 8px 12px;
    cursor: pointer;
}

.ui-autocomplete .ui-state-active,
.ui-autocomplete .ui-menu-item-wrapper:hover {
    background-color: #2271b1;
    color: #fff;
    border: none;
}

/* Shortcode Reference Table */
.edr2-shortcode-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    background: #fff;
    border: 1px solid #ccd0d4;
    box-shadow: 0 1px 1px rgba(0,0,0,.04);
}

.edr2-shortcode-table th,
.edr2-shortcode-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #f0f0f1;
}

.edr2-shortcode-table th {
    background: #f8f9fa;
    font-weight: 600;
}

.edr2-shortcode-table code {
    background: #f0f0f1;
    padding: 3px 6px;
    border-radius: 3px;
    color: #d63638;
    font-family: Consolas, Monaco, monospace;
    font-size: 13px;
    vertical-align: middle;
}

.edr2-copy-shortcode {
    vertical-align: middle;
}

.edr2-copy-shortcode .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
    line-height: 1;
}


/* Kiosk Mode Styling */
:root {
    --edr2-kiosk-body-bg: #2c3e50;
    --edr2-kiosk-body-color: #ecf0f1;
    --edr2-kiosk-card-bg: #ffffff;
    --edr2-kiosk-card-color: #333333;
    --edr2-kiosk-accent: #0073aa;
    --edr2-kiosk-muted: #888888;
}

/* Dark mode overrides */
@media (prefers-color-scheme: dark) {
    :root {
        --edr2-kiosk-card-bg: #1a252f;
        --edr2-kiosk-card-color: #ecf0f1;
        --edr2-kiosk-muted: #aaaaaa;
    }
}

/* Theme-specific dark mode detection (Blocksy, etc.) */
body.dark-mode, body.dark, [data-theme="dark"] body, body[data-theme="dark"] {
    --edr2-kiosk-card-bg: #1a252f;
    --edr2-kiosk-card-color: #ecf0f1;
    --edr2-kiosk-muted: #aaaaaa;
}

body.edr2-kiosk-mode {
    background-color: var(--edr2-kiosk-card-bg) !important;
}

.edr2-kiosk-mode .content-area,
.edr2-kiosk-mode main,
.edr2-kiosk-mode #primary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

.edr2-kiosk-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 80vh;
    padding: 40px;
    box-sizing: border-box;
    text-align: center;
}

.edr2-kiosk-wrapper .edr2-qr-generator canvas,
.edr2-kiosk-wrapper .edr2-qr-generator img {
    margin: 0 auto;
    /* Ensure QR code has a slight white border in dark mode for scannability */
    background: white;
    padding: 10px;
    border-radius: 5px;
}

.edr2_kiosk_mode {
    background-color: var(--edr2-kiosk-body-bg) !important;
    color: var(--edr2-kiosk-body-color) !important;
}

.edr2_kiosk_mode .edr2-kiosk-wrapper {
    background: var(--edr2-kiosk-card-bg);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    color: var(--edr2-kiosk-card-color);
    max-width: 800px;
    margin: 50px auto !important;
}

.edr2-kiosk-title {
    font-size: 3em;
    margin-bottom: 40px;
    color: var(--edr2-kiosk-accent);
}

.edr2-qr-code-container {
    text-align: center;
    margin: 20px auto;
}

.edr2-kiosk-display-id {
    margin-bottom: 16px;
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--edr2-kiosk-muted);
}

.edr2-kiosk-content-inner {
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.edr2-qr-display-area {
    position: relative;
    width: 100%;
    aspect-ratio: 1/1;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.edr2-qr-canvas,
.edr2-qr-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.edr2-qr-canvas img,
.edr2-qr-canvas canvas {
    max-width: 100%;
    max-height: 100%;
}

.edr2-qr-overlay[hidden] {
    display: none;
}

.edr2-qr-status {
    width: 100%;
    margin-top: 12px;
    text-align: center;
    font-size: 14px;
    line-height: 1.4;
    color: #50575e;
}

.edr2-qr-status-warning {
    color: #8a5a00;
}

.edr2-qr-status-danger {
    color: #b42318;
}

.edr2-qr-panel {
    box-sizing: border-box;
    width: 100%;
    padding: 24px;
    border-radius: 20px;
    border: 3px solid #f59e0b;
    background: linear-gradient(180deg, #fffaf0 0%, #fff3d9 100%);
    color: #6b4f00;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 12px;
}

.edr2-qr-panel-danger {
    border-color: #d63638;
    background: linear-gradient(180deg, #fff5f5 0%, #ffe0e0 100%);
    color: #8a1c1c;
}

.edr2-qr-panel-warning {
    border-color: #f59e0b;
}

.edr2-qr-panel-eyebrow {
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.edr2-qr-panel-title {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.1;
}

.edr2-qr-panel-body {
    max-width: 28rem;
    font-size: 1.05rem;
    line-height: 1.5;
}

.edr2-qr-fallback {
    width: 100%;
    max-width: 30rem;
    margin-top: 8px;
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.72);
}

.edr2-qr-fallback-label {
    margin-bottom: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.edr2-qr-fallback-link {
    display: block;
    overflow-wrap: anywhere;
    font-size: 0.95rem;
    font-weight: 600;
    color: inherit;
}

.edr2-kiosk-instruction {
    width: 100%;
    margin-top: 20px !important;
    font-size: 3em !important;
    line-height: 1.2;
    font-weight: bold;
    color: var(--edr2-kiosk-card-color);
}

.edr2-kiosk-logo {
    display: block;
    width: 100% !important;
    max-width: 100% !important;
    height: auto;
    margin-bottom: 30px;
    /* Ensure white logos are visible on light backgrounds */
    filter: drop-shadow(0px 0px 4px rgba(0,0,0,0.3));
}

/* Kiosk Visitor List */
.edr2-kiosk-table {
    font-size: 1.5em;
    border-collapse: collapse;
    width: 100%;
    color: var(--edr2-kiosk-card-color);
}

.edr2-kiosk-table th, 
.edr2-kiosk-table td {
    padding: 20px !important;
    text-align: left;
}

.edr2-kiosk-table thead th {
    background-color: var(--edr2-kiosk-accent);
    color: #ffffff;
}

.edr2-kiosk-refresh-note {
    font-size: 1.2em;
    color: var(--edr2-kiosk-muted);
    margin-bottom: 20px;
    font-style: italic;
}

.edr2-display-id-badge {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 8px;
    border-radius: 999px;
    background: #1f2937;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    vertical-align: middle;
}

/* Zebra striping for kiosk table */
.edr2-kiosk-table tbody tr:nth-child(even) {
    background-color: rgba(0, 0, 0, 0.05);
}

/* For dark mode cards, make zebra striping lighter */
body.dark-mode .edr2-kiosk-table tbody tr:nth-child(even), 
body.dark .edr2-kiosk-table tbody tr:nth-child(even), 
[data-theme="dark"] .edr2-kiosk-table tbody tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.05);
}

.edr2-kiosk-table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

/* Visitor List Filters */
.edr2-visitor-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.edr2-visitor-filters .button {
    text-decoration: none;
    padding: 10px 20px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #eee;
    color: #333;
    font-weight: 500;
    transition: all 0.2s ease;
}

/* Dark mode adjustments for filters and messages */
@media (prefers-color-scheme: dark) {
    .edr2-visitor-filters .button {
        background: #34495e;
        color: #ecf0f1;
        border-color: #5d6d7e;
    }
    .edr2-visitor-filters .button:hover {
        background: #465c71;
    }
    .edr2-visitor-list-wrapper > p {
        color: #ecf0f1;
    }
}

body.dark-mode .edr2-visitor-filters .button,
body.dark .edr2-visitor-filters .button,
[data-theme="dark"] body .edr2-visitor-filters .button,
body[data-theme="dark"] .edr2-visitor-filters .button {
    background: #34495e;
    color: #ecf0f1;
    border-color: #5d6d7e;
}

body.dark-mode .edr2-visitor-filters .button:hover,
body.dark .edr2-visitor-filters .button:hover,
[data-theme="dark"] body .edr2-visitor-filters .button:hover,
body[data-theme="dark"] .edr2-visitor-filters .button:hover {
    background: #465c71;
}

body.dark-mode .edr2-visitor-list-wrapper > p,
body.dark .edr2-visitor-list-wrapper > p,
[data-theme="dark"] body .edr2-visitor-list-wrapper > p,
body[data-theme="dark"] .edr2-visitor-list-wrapper > p {
    color: #ecf0f1;
}

.edr2-visitor-filters .button:hover {
    background: #ddd;
    border-color: #bbb;
}

.edr2-visitor-filters .button-primary {
    background: #0073aa !important;
    color: #fff !important;
    border-color: #005177 !important;
}

.edr2-kiosk-wrapper .edr2-visitor-filters .button {
    font-size: 1.5em;
    padding: 15px 30px;
}

/* PC mode for visitor list shortcode */
.edr2-pc-wrapper {
    max-width: 1400px;
    margin: 0 auto;
}

.edr2-pc-wrapper .edr2-logo-standard {
    width: 10% !important;
    max-width: 10% !important;
    height: auto;
}

.edr2-pc-wrapper .edr2-visitor-header {
    gap: 24px;
}

.edr2-pc-wrapper .edr2-visitor-filters .button {
    padding: 12px 22px;
}

.edr2-pc-wrapper .wp-list-table {
    font-size: 1.02rem;
}

.edr2-pc-wrapper .wp-list-table th,
.edr2-pc-wrapper .wp-list-table td {
    padding-top: 12px;
    padding-bottom: 12px;
}

/* Loading indicator for visitor list */
.edr2-visitor-list-wrapper {
    position: relative;
    min-height: 100px; /* Ensure it has some height for loading overlay */
}

.edr2-visitor-list-wrapper.edr2-loading {
    opacity: 0.5; /* Dim the content */
    pointer-events: none; /* Prevent interaction during loading */
}

.edr2-visitor-list-wrapper.edr2-loading::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7); /* Light overlay */
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Error message styling */
.edr2-error-message {
    color: #dc3232;
    background-color: #ffeaea;
    border: 1px solid #dc3232;
    padding: 10px;
    border-radius: 4px;
    text-align: center;
    margin: 20px 0;
}

.edr2-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
    white-space: nowrap;
}

.edr2-visitor-total {
    font-size: 1.1em;
    color: inherit; /* Allow theme to set color, usually #333 in light mode */
}

/* Visitor List Styles */
.edr2-visitor-list-logo {
    text-align: center;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.03); /* Extremely subtle tint for light mode */
    border-radius: 8px;
    display: inline-block;
    width: 100%;
    box-sizing: border-box;
}

/* Ensure the background doesn't darken in dark mode */
@media (prefers-color-scheme: dark) {
    .edr2-visitor-list-logo {
        background: transparent;
    }
}

body.dark-mode .edr2-visitor-list-logo, 
body.dark .edr2-visitor-list-logo, 
[data-theme="dark"] .edr2-visitor-list-logo {
    background: transparent;
}

.edr2-logo-standard {
    max-width: 200px;
    height: auto;
    /* Ensure white logos are visible on light backgrounds */
    filter: drop-shadow(0px 0px 1px rgba(0,0,0,0.2));
}

.edr2-logo-kiosk {
    max-width: 400px;
    height: auto;
}

.edr2-visitor-list-refresh-note {
    font-size: 0.85em;
    color: #888;
    margin-bottom: 10px;
    opacity: 0.8;
}

/* Dark mode adjustments for standard visitor list */
@media (prefers-color-scheme: dark) {
    .edr2-visitor-total {
        color: #ecf0f1;
    }
    .edr2-visitor-list-refresh-note {
        color: #aaa;
    }
    .wp-list-table.widefat.striped tbody tr:nth-child(even) {
        background-color: rgba(255, 255, 255, 0.05) !important;
    }
}

/* Theme-specific dark mode detection */
body.dark-mode .edr2-visitor-total,
body.dark .edr2-visitor-total,
[data-theme="dark"] body .edr2-visitor-total,
body[data-theme="dark"] .edr2-visitor-total {
    color: #ecf0f1;
}

body.dark-mode .edr2-visitor-list-refresh-note,
body.dark .edr2-visitor-list-refresh-note,
[data-theme="dark"] body .edr2-visitor-list-refresh-note,
body[data-theme="dark"] .edr2-visitor-list-refresh-note {
    color: #aaa;
}

body.dark-mode .wp-list-table.widefat.striped tbody tr:nth-child(even),
body.dark .wp-list-table.widefat.striped tbody tr:nth-child(even),
[data-theme="dark"] body .wp-list-table.widefat.striped tbody tr:nth-child(even),
body[data-theme="dark"] .wp-list-table.widefat.striped tbody tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.05) !important;
}

.edr2-visitor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 15px;
}

.edr2-visitor-filters-kiosk {
    margin-bottom: 30px;
}

.edr2-attendance-cell {
    text-align: center;
}

.edr2-attendance-toggle {
    transform: scale(1.2);
}

.edr2-kiosk-title {
    margin-bottom: 5px !important;
}

/* Responsive adjustments for QR Kiosk */
@media screen and (max-width: 768px) {
    .edr2-kiosk-wrapper {
        padding: 20px;
        min-height: auto;
    }
    
    .edr2-kiosk-title {
        font-size: 2em;
        margin-bottom: 20px;
    }
    
    .edr2-kiosk-instruction {
        font-size: 2em !important;
        margin-top: 20px !important;
    }
    
    .edr2-kiosk-logo {
        height: auto;
    }

    .edr2-qr-generator {
        min-height: auto !important;
    }

    .edr2-qr-panel {
        padding: 20px;
        border-radius: 16px;
    }

    .edr2-qr-panel-title {
        font-size: 1.6rem;
    }

    .edr2-qr-panel-body {
        font-size: 1rem;
    }

    .edr2-kiosk-table {
        font-size: 1.2em;
    }

    .edr2-kiosk-table th,
    .edr2-kiosk-table td {
        padding: 12px !important;
    }

    .edr2-kiosk-refresh-note {
        font-size: 1em;
    }

    .edr2-logo-kiosk {
        max-width: 300px;
    }
}

@media screen and (max-width: 600px) {
    .edr2-visitor-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .edr2-visitor-total {
        order: -1;
        width: 100%;
        text-align: center;
        padding-bottom: 10px;
        border-bottom: 1px solid #eee;
        margin-bottom: 5px;
    }

    .edr2-visitor-filters {
        width: 100%;
        justify-content: center;
    }
}

@media screen and (max-width: 480px) {
    .edr2-kiosk-title {
        font-size: 1.5em;
        margin-bottom: 10px !important;
    }
    
    .edr2-kiosk-instruction {
        font-size: 1.8em !important;
    }

    .edr2-kiosk-refresh-note {
        font-size: 0.85em;
        margin-bottom: 15px;
    }

    .edr2-visitor-list-wrapper table.fixed {
        table-layout: auto !important;
    }

    /* Hide the 'Duration' and 'Time' columns on very small screens to prevent horizontal scroll */
    .edr2-visitor-list-wrapper .edr2-col-duration,
    .edr2-visitor-list-wrapper .edr2-col-time {
        display: none;
    }

    .edr2-checkin-form {
        margin: 10px;
        padding: 15px;
    }

    .edr2-checkin-modal-content {
        width: 90%;
        padding: 15px;
    }

    .edr2-modal-buttons {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .edr2-modal-buttons .edr2-checkin-button {
        margin: 0;
        width: 100%;
    }

    .edr2-kiosk-table {
        font-size: 1.1em;
    }

    .edr2-kiosk-table th,
    .edr2-kiosk-table td {
        padding: 10px !important;
    }

    .edr2-visitor-list-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .edr2-visitor-filters {
        flex-wrap: wrap;
        justify-content: center;
    }

    .edr2-visitor-filters .button {
        padding: 8px 15px;
        font-size: 0.9em;
    }

    .edr2-kiosk-wrapper .edr2-visitor-filters .button {
        font-size: 1.1em;
        padding: 10px 20px;
    }

    .edr2-logo-kiosk {
        max-width: 200px;
    }
}
