/* --- DESIGN SYSTEM & VARIÁVEIS --- */
:root {
    --bg-dark: #eef4f7;
    --bg-card: rgba(255, 255, 255, 0.82);
    --border-color: rgba(15, 23, 42, 0.1);
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;

    --color-cyan: #0891b2;
    --color-purple: #4f46e5;
    --color-emerald: #059669;
    --color-rose: #e11d48;
    --color-ink: #102033;
    --color-osmar: #0ea5e9;

    --glow-cyan: rgba(14, 165, 233, 0.18);
    --glow-purple: rgba(79, 70, 229, 0.12);

    --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- RESET & GERAIS --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background:
        linear-gradient(135deg, rgba(240, 249, 255, 0.92), rgba(248, 250, 252, 0.96) 45%, rgba(236, 253, 245, 0.86)),
        var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-sans);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* --- GLOW BACKGROUND --- */
.glow-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.glow-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(110px);
    opacity: 0.22;
}

.glow-1 {
    top: -10%;
    right: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, #0ea5e9 0%, transparent 70%);
}

.glow-2 {
    bottom: -10%;
    left: -10%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, #10b981 0%, transparent 70%);
}

/* --- GLASSMORPHISM --- */
.glass {
    background: var(--bg-card);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid var(--border-color);
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.1);
}

/* --- SCREENS --- */
.screen {
    display: none;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.screen.active {
    display: block;
    opacity: 1;
}

#login-screen {
    display: none;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    background:
        linear-gradient(115deg, rgba(255, 255, 255, 0.76), rgba(240, 249, 255, 0.5) 42%, rgba(236, 253, 245, 0.58)),
        radial-gradient(circle at 18% 42%, rgba(14, 165, 233, 0.2), transparent 32%),
        radial-gradient(circle at 82% 30%, rgba(16, 185, 129, 0.18), transparent 34%);
}

#login-screen.active {
    display: flex;
}

/* --- TELA DE LOGIN --- */
.login-card {
    border-radius: 18px;
    padding: 48px 40px;
    width: 100%;
    max-width: 460px;
    text-align: center;
    transition: var(--transition-smooth);
    border-top: 4px solid var(--color-osmar);
}

.login-card:hover {
    border-color: rgba(14, 165, 233, 0.24);
    box-shadow: 0 20px 54px rgba(15, 23, 42, 0.14);
}

.login-header {
    margin-bottom: 36px;
}

.logo-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #0ea5e9, #10b981);
    border-radius: 14px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 16px;
    font-size: 28px;
    color: white;
    box-shadow: 0 14px 28px rgba(14, 165, 233, 0.24);
}

.login-header h1 {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 8px;
    letter-spacing: 0;
    color: var(--text-primary);
    background: linear-gradient(to right, #0f172a, #0e7490);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-byline {
    display: inline-flex;
    width: fit-content;
    margin: 0 auto 14px;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(14, 165, 233, 0.08);
    border: 1px solid rgba(14, 165, 233, 0.18);
    color: #0369a1;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 15px;
}

.login-support {
    max-width: 320px;
    margin: 8px auto 0;
    color: var(--text-muted) !important;
    line-height: 1.45;
}

.input-group {
    margin-bottom: 24px;
    text-align: left;
}

.input-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
    margin-left: 4px;
}

.input-wrapper {
    position: relative;
}

.input-wrapper input {
    width: 100%;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px 16px 14px 44px;
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 15px;
    transition: var(--transition-smooth);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--color-cyan);
    background: #ffffff;
    box-shadow: 0 0 16px var(--glow-cyan);
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 18px;
    transition: var(--transition-smooth);
}

.input-wrapper input:focus + .input-icon {
    color: var(--color-cyan);
}

/* --- ERROS --- */
.error-message {
    background: rgba(244, 63, 94, 0.1);
    border: 1px solid rgba(244, 63, 94, 0.25);
    color: var(--color-rose);
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: left;
}

.hidden {
    display: none !important;
}

/* --- BOTÕES --- */
.btn-primary {
    width: 100%;
    background: linear-gradient(135deg, #0284c7 0%, #059669 100%);
    border: none;
    border-radius: 10px;
    padding: 16px;
    color: white;
    font-family: var(--font-sans);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    transition: var(--transition-smooth);
    box-shadow: 0 12px 24px rgba(14, 165, 233, 0.22);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(14, 165, 233, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

.login-signature {
    margin-top: 24px;
    padding-top: 18px;
    border-top: 1px solid var(--border-color);
    display: grid;
    gap: 6px;
    color: var(--text-muted);
    font-size: 13px;
}

.login-signature span {
    font-weight: 700;
    color: var(--text-secondary);
}

.login-signature a {
    color: #0369a1;
    font-weight: 800;
    text-decoration: none;
}

.login-signature a:hover {
    color: #059669;
}

/* --- HEADER --- */
header {
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    border-radius: 0;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header .logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

header .logo i {
    font-size: 24px;
    background: linear-gradient(135deg, #0284c7, #059669);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

header .logo small {
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 16px;
}

.user-info {
    display: flex;
    flex-direction: column;
    text-align: right;
}

.user-greeting {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.establishment-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.btn-logout {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.btn-logout:hover {
    background: rgba(244, 63, 94, 0.1);
    border-color: rgba(244, 63, 94, 0.3);
    color: var(--color-rose);
}

/* --- DASHBOARD CONTAINER --- */
.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 24px;
}

/* --- METRICS GRID --- */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.metric-card {
    border-radius: 20px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: var(--transition-smooth);
}

.metric-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.15);
}

.metric-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 22px;
    color: white;
}

.bg-cyan {
    background: linear-gradient(135deg, #0891b2, var(--color-cyan));
    box-shadow: 0 8px 20px rgba(6, 182, 212, 0.2);
}

.bg-purple {
    background: linear-gradient(135deg, #7c3aed, var(--color-purple));
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.2);
}

.bg-emerald {
    background: linear-gradient(135deg, #059669, var(--color-emerald));
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.2);
}

.metric-data h3 {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 4px;
}

.metric-data p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* --- CHARTS GRID --- */
.charts-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-bottom: 48px;
}

@media (max-width: 900px) {
    .charts-grid {
        grid-template-columns: 1fr;
    }
}

.chart-card {
    border-radius: 20px;
    padding: 24px;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.chart-header h2 {
    font-size: 18px;
    font-weight: 700;
}

.badge {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    color: var(--text-secondary);
}

.chart-wrapper {
    height: 300px;
    position: relative;
}

.chart-wrapper-doughnut {
    height: 300px;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* --- PLATES MANAGEMENT --- */
.plates-section {
    margin-bottom: 48px;
}

.section-header {
    margin-bottom: 24px;
}

.section-header h2 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 6px;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 15px;
}

.plates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

@media (max-width: 480px) {
    .plates-grid {
        grid-template-columns: 1fr;
    }
}

.plate-card {
    border-radius: 14px;
    padding: 18px;
    position: relative;
    overflow: hidden;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.plate-card:hover,
.plate-card:focus-visible {
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    outline: none;
}

.device-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.device-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(6, 182, 212, 0.12);
    border: 1px solid rgba(6, 182, 212, 0.24);
    color: var(--color-cyan);
    font-size: 18px;
}

.plate-card h3 {
    color: var(--text-primary);
    font-size: 17px;
    line-height: 1.25;
    font-weight: 800;
    margin-bottom: 4px;
}

.plate-card p {
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.device-destinations {
    display: grid;
    gap: 8px;
    margin: 16px 0;
    padding: 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.07);
}

.destination-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
    font-size: 13px;
}

.destination-row span {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-wrap: anywhere;
}

.destination-row i {
    width: 14px;
    color: var(--color-cyan);
    text-align: center;
    flex: 0 0 auto;
}

.destination-row strong {
    color: var(--text-primary);
    font-size: 12px;
    white-space: nowrap;
}

.status-pill {
    width: fit-content;
    border-radius: 999px;
    padding: 5px 9px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.status-pill.active {
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.28);
    color: #34d399;
}

.status-pill.suspended {
    background: rgba(244, 63, 94, 0.12);
    border: 1px solid rgba(244, 63, 94, 0.28);
    color: #fb7185;
}

.device-card-meta {
    display: grid;
    gap: 6px;
    margin: 14px 0;
}

.device-card-meta span {
    color: var(--text-secondary);
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-wrap: anywhere;
}

.device-card-meta i {
    color: var(--color-cyan);
    width: 14px;
    text-align: center;
}

.plate-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.btn-test {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 6px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: var(--transition-smooth);
}

.btn-test:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.btn-configure {
    width: 100%;
    justify-content: center;
    color: var(--text-primary);
}

body.modal-open {
    overflow: hidden;
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.device-modal {
    width: min(760px, 100%);
    max-height: min(88vh, 820px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 16px;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.24);
}

.modal-header {
    padding: 18px 20px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.modal-kicker {
    color: var(--color-cyan);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.modal-header h2 {
    font-size: 20px;
    line-height: 1.2;
    margin-top: 4px;
}

.modal-close {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary);
    cursor: pointer;
}

.modal-close:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
}

.modal-body {
    overflow: auto;
}

.modal-device-form {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 18px 20px 20px;
}

.modal-device-form .form-panel {
    background: rgba(248, 250, 252, 0.9);
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 12px;
    padding: 14px;
}

.modal-device-form .form-panel-header {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 12px;
}

.modal-device-form .form-panel-header > i {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    color: var(--color-cyan);
    flex: 0 0 auto;
}

.modal-device-form .form-panel-header h4 {
    color: var(--text-primary);
    font-size: 15px;
    line-height: 1.2;
    margin-bottom: 2px;
}

.modal-device-form .form-panel-header p {
    color: var(--text-muted);
    font-size: 12px;
}

.modal-device-form .form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.span-2 {
    grid-column: span 2;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    position: sticky;
    bottom: 0;
    z-index: 5;
    padding-top: 8px;
    background: linear-gradient(to top, #ffffff 80%, rgba(255, 255, 255, 0));
}

.btn-secondary-action {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: 10px;
    padding: 12px 16px;
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

.btn-secondary-action:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
}

@media (max-width: 720px) {
    .form-grid {
        grid-template-columns: 1fr;
    }

    .span-2 {
        grid-column: auto;
    }

    .modal-actions {
        justify-content: stretch;
        position: static;
        flex-direction: column-reverse;
    }
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    display: flex;
    justify-content: space-between;
}

.form-group label span {
    font-weight: 400;
    color: var(--text-muted);
}

.form-input-wrapper {
    position: relative;
}

.form-input-wrapper i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
}

.form-input-wrapper input,
.form-input-wrapper textarea {
    width: 100%;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 10px 12px 10px 38px;
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 14px;
    transition: var(--transition-smooth);
}

.form-input-wrapper textarea {
    min-height: 92px;
    resize: vertical;
    line-height: 1.45;
}

.form-input-wrapper textarea + i,
.form-input-wrapper:has(textarea) i {
    top: 16px;
    transform: none;
}

.form-input-wrapper input:focus,
.form-input-wrapper textarea:focus {
    outline: none;
    border-color: var(--color-purple);
    background: rgba(255, 255, 255, 0.05);
}

.form-select-wrapper {
    position: relative;
}

.form-select-wrapper select {
    width: 100%;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 10px 12px;
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 14px;
    transition: var(--transition-smooth);
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
}

.form-select-wrapper select:focus {
    outline: none;
    border-color: var(--color-purple);
    background: rgba(255, 255, 255, 0.05);
}

.form-select-wrapper::after {
    content: '\f107';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.btn-save {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    border-radius: 10px;
    padding: 12px;
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    transition: var(--transition-smooth);
    margin-top: 4px;
}

.btn-save:hover {
    background: var(--color-ink);
    color: white;
    border-color: var(--color-ink);
}

.btn-save.success {
    background: var(--color-emerald);
    border-color: var(--color-emerald);
    color: white;
}

/* --- LOADING & EMPTY STATES --- */
.loading-state, .empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 48px;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 16px;
}

.loading-state i {
    font-size: 32px;
    color: var(--color-cyan);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: #27272a;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #3f3f46;
}

/* --- SUPERADMIN SPECIFIC STYLES --- */
.superadmin-grid {
    animation: fadeIn 0.5s ease;
}

.badge-admin {
    background: linear-gradient(135deg, #a855f7, #6366f1);
    box-shadow: 0 0 10px rgba(168, 85, 247, 0.4);
}

/* Tabela Admin */
.admin-table {
    border-radius: 12px;
    overflow: hidden;
}

.admin-table th {
    font-size: 13px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.admin-table td {
    padding: 14px 16px;
    color: var(--text-primary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    vertical-align: middle;
}

.superadmin-card,
.admin-table,
.table-wrapper {
    color: var(--text-primary) !important;
}

.superadmin-card h2,
.superadmin-card label,
.admin-table td,
.admin-table th,
.admin-table strong,
#comerciantes-table-body [style*="color: white"] {
    color: var(--text-primary) !important;
}

.superadmin-card p,
.admin-table span,
#comerciantes-table-body [style*="#a1a1aa"],
#comerciantes-table-body [style*="#71717a"] {
    color: var(--text-secondary) !important;
}

.superadmin-card input,
.superadmin-card select {
    background: rgba(255, 255, 255, 0.86) !important;
    border-color: rgba(15, 23, 42, 0.12) !important;
    color: var(--text-primary) !important;
}

.table-wrapper {
    background: rgba(255, 255, 255, 0.7) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
}

.admin-table tr:last-child td {
    border-bottom: none;
}

.admin-table tr:hover td {
    background: rgba(255, 255, 255, 0.015);
}

.admin-device-row,
.admin-status-row {
    display: grid;
    gap: 4px;
    padding: 8px 0;
}

.admin-device-row + .admin-device-row,
.admin-status-row + .admin-status-row {
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.admin-device-row strong {
    color: var(--text-primary);
    font-size: 14px;
}

.admin-device-row span,
.admin-status-row span {
    color: var(--text-secondary);
    font-size: 12px;
}

.recording-links {
    display: grid;
    gap: 7px;
    margin-top: 8px;
}

.recording-link-row {
    display: grid;
    grid-template-columns: 48px minmax(190px, 1fr) auto;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 8px;
    background: rgba(248, 250, 252, 0.82);
}

.recording-link-row span {
    color: var(--text-primary) !important;
    font-size: 12px;
    font-weight: 800;
}

.recording-link-row code {
    min-width: 0;
    color: #0f766e;
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-copy-link {
    border: 1px solid rgba(14, 165, 233, 0.18);
    border-radius: 7px;
    background: rgba(14, 165, 233, 0.08);
    color: #0369a1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-width: 78px;
    padding: 7px 9px;
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 800;
}

.btn-copy-link:hover {
    background: rgba(14, 165, 233, 0.14);
}

.btn-copy-link.copied {
    background: rgba(5, 150, 105, 0.12);
    border-color: rgba(5, 150, 105, 0.22);
    color: #047857;
}

.admin-status-row {
    grid-template-columns: auto auto auto;
    align-items: center;
    justify-content: center;
    column-gap: 10px;
}

/* Switch Toggle Premium */
.switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: .4s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: #a1a1aa;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: rgba(16, 185, 129, 0.2);
    border-color: rgba(16, 185, 129, 0.4);
}

input:checked + .slider:before {
    background-color: #10b981;
    transform: translateX(24px);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
}

/* Responsividade do SuperAdmin Grid */
@media (max-width: 900px) {
    .superadmin-grid {
        grid-template-columns: 1fr !important;
    }
}
