:root{
    color-scheme:dark;
}

html[data-theme="light"]{
    color-scheme:light;
    --bg:#f1f5f9;
    --card:#ffffff;
    --text:#172033;
    --gray:#5b6879;
    --muted:#5b6879;
    --border:#cbd5e1;
    --panel:#ffffff;
    --panel-strong:#f8fafc;
    --accent:#0b72d9;
    --accent-hover:#075eaf;
}

html[data-theme="light"] body{
    background:
        radial-gradient(circle at 8% 0%, rgba(14,165,233,.08), transparent 28%),
        #f1f5f9 !important;
    background-repeat:no-repeat !important;
    background-size:100% 760px !important;
    color:#172033 !important;
    min-height:100vh;
}

html[data-theme="light"] .brand-topbar,
html[data-theme="light"] .page-topbar,
html[data-theme="light"] .popup-brand,
html[data-theme="light"] .login-topbar{
    background:#ffffff !important;
    border-color:#d7e0ea !important;
    box-shadow:0 12px 30px rgba(15,23,42,.09) !important;
}

html[data-theme="light"] .brand-hs,
html[data-theme="light"] .brand-service{
    color:#0f172a !important;
}

html[data-theme="light"] .header{
    background:#ffffff !important;
    border-color:#d7e0ea !important;
    color:#172033 !important;
}

html[data-theme="light"] .section,
html[data-theme="light"] .client-card,
html[data-theme="light"] .info-panel,
html[data-theme="light"] .report-panel,
html[data-theme="light"] .card-panel,
html[data-theme="light"] .serwisant-list,
html[data-theme="light"] .device-list,
html[data-theme="light"] .certificate-list,
html[data-theme="light"] .serwisant-form,
html[data-theme="light"] .device-form,
html[data-theme="light"] .certificate-form,
html[data-theme="light"] .content-panel,
html[data-theme="light"] .panel,
html[data-theme="light"] .security-table-wrap{
    background:#ffffff !important;
    border-color:#cbd5e1 !important;
    color:#172033 !important;
    box-shadow:0 12px 28px rgba(15,23,42,.07);
}

html[data-theme="light"] .info-card,
html[data-theme="light"] .summary,
html[data-theme="light"] .summary-item,
html[data-theme="light"] .serwisant-row,
html[data-theme="light"] .device-row,
html[data-theme="light"] .certificate-row,
html[data-theme="light"] .content-highlight,
html[data-theme="light"] .content-card,
html[data-theme="light"] .content-accordion,
html[data-theme="light"] .session-row,
html[data-theme="light"] .summary-chip{
    background:#f8fafc !important;
    border-color:#cbd5e1 !important;
    color:#172033 !important;
}

html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] textarea{
    background:#ffffff !important;
    border-color:#b9c6d5 !important;
    color:#172033 !important;
}

html[data-theme="light"] input::placeholder,
html[data-theme="light"] textarea::placeholder{
    color:#718096 !important;
    opacity:1;
}

html[data-theme="light"] input:disabled,
html[data-theme="light"] select:disabled,
html[data-theme="light"] textarea:disabled{
    background:#e9eef5 !important;
    color:#64748b !important;
}

html[data-theme="light"] select option{
    background:#ffffff;
    color:#172033;
}

html[data-theme="light"] table,
html[data-theme="light"] .table-wrap{
    background:#ffffff !important;
    border-color:#cbd5e1 !important;
    color:#172033 !important;
}

html[data-theme="light"] th,
html[data-theme="light"] .table-wrap.is-scrollable thead th,
html[data-theme="light"] .security-table th{
    background:#e8eef6 !important;
    color:#334155 !important;
    border-color:#c5d0dd !important;
}

html[data-theme="light"] td,
html[data-theme="light"] .security-table td{
    color:#172033 !important;
    border-color:#d7e0ea !important;
}

html[data-theme="light"] tbody tr:hover{
    background:#eff6ff !important;
}

html[data-theme="light"] tr.selected,
html[data-theme="light"] .selected{
    background:#dbeafe !important;
}

html[data-theme="light"] .card{
    background:#ffffff !important;
    border:1px solid #d7e0ea;
    color:#172033 !important;
    box-shadow:0 10px 24px rgba(15,23,42,.07);
}

html[data-theme="light"] .card:hover{
    background:#0b84ff !important;
    color:#ffffff !important;
}
html[data-theme="light"] .slowniki-card{
    background:#ffffff !important;
    border-color:#d7e0ea !important;
    color:#172033 !important;
    box-shadow:0 12px 28px rgba(15,23,42,.08);
}

html[data-theme="light"] .slowniki-card p{
    color:#263548 !important;
}

html[data-theme="light"] .slowniki-card:hover{
    background:linear-gradient(135deg,#0b84ff,#2563eb) !important;
    border-color:#1d4ed8 !important;
    color:#ffffff !important;
    box-shadow:0 18px 36px rgba(37,99,235,.22);
}

html[data-theme="light"] .slowniki-card:hover p{
    color:#ffffff !important;
}

html[data-theme="light"] .tabs .tab,
html[data-theme="light"] .tab-btn,
html[data-theme="light"] .mini-btn,
html[data-theme="light"] .secondary,
html[data-theme="light"] .confirm-cancel,
html[data-theme="light"] .lookup-toggle{
    background:#e7edf5 !important;
    border-color:#c5d0dd !important;
    color:#263548 !important;
}

html[data-theme="light"] .tabs .tab.active,
html[data-theme="light"] .tab-btn.active{
    background:#0b84ff !important;
    color:#ffffff !important;
}

html[data-theme="light"] .mini-btn:hover,
html[data-theme="light"] .secondary:hover,
html[data-theme="light"] .confirm-cancel:hover,
html[data-theme="light"] .lookup-toggle:hover{
    background:#d6e0ec !important;
}

html[data-theme="light"] .lookup-menu{
    background:#ffffff !important;
    border-color:#b9c6d5 !important;
    box-shadow:0 14px 30px rgba(15,23,42,.16) !important;
}

html[data-theme="light"] .lookup-option{
    color:#172033 !important;
}

html[data-theme="light"] .lookup-option:hover,
html[data-theme="light"] .lookup-option.is-active{
    background:#dbeafe !important;
    color:#1e3a8a !important;
}

html[data-theme="light"] .confirm-overlay{
    background:rgba(15,23,42,.34) !important;
}

html[data-theme="light"] .confirm-dialog{
    background:#ffffff !important;
    border-color:#cbd5e1 !important;
    color:#172033 !important;
    box-shadow:0 22px 55px rgba(15,23,42,.22) !important;
}

html[data-theme="light"] .confirm-dialog p,
html[data-theme="light"] .content-intro,
html[data-theme="light"] .content-card p,
html[data-theme="light"] .content-section p,
html[data-theme="light"] .accordion-body p,
html[data-theme="light"] .report-user,
html[data-theme="light"] .certificate-targets label,
html[data-theme="light"] .security-details{
    color:#475569 !important;
}

html[data-theme="light"] label,
html[data-theme="light"] .hint,
html[data-theme="light"] .subtle,
html[data-theme="light"] .muted-note,
html[data-theme="light"] .serwisant-sub,
html[data-theme="light"] .device-sub,
html[data-theme="light"] .certificate-sub,
html[data-theme="light"] .report-note,
html[data-theme="light"] .certificate-note,
html[data-theme="light"] .certificate-selected-file,
html[data-theme="light"] .summary-note,
html[data-theme="light"] .session-sub,
html[data-theme="light"] .session-time,
html[data-theme="light"] .empty-state,
html[data-theme="light"] .security-meta,
html[data-theme="light"] .security-empty,
html[data-theme="light"] .table-head-check,
html[data-theme="light"] .signature-label{
    color:#5b6879 !important;
}

html[data-theme="light"] .info-row,
html[data-theme="light"] .serwisant-meta,
html[data-theme="light"] .device-meta,
html[data-theme="light"] .certificate-meta,
html[data-theme="light"] .content-list{
    color:#263548 !important;
    border-color:#d7e0ea !important;
}

html[data-theme="light"] .info-label{
    color:#5b6879 !important;
}

html[data-theme="light"] .content-accordion summary,
html[data-theme="light"] .signature-value,
html[data-theme="light"] .signature-footer-text,
html[data-theme="light"] .summary-count,
html[data-theme="light"] .session-name,
html[data-theme="light"] .security-event{
    color:#172033 !important;
}

html[data-theme="light"] .content-accordion summary:hover{
    background:#eef4fa !important;
}

html[data-theme="light"] .certificate-drop-zone{
    background:linear-gradient(145deg,#f8fafc,#eef5fb) !important;
    border-color:#94a3b8 !important;
}

html[data-theme="light"] .certificate-drop-zone:hover,
html[data-theme="light"] .certificate-drop-zone.is-dragover{
    background:linear-gradient(145deg,#e0f2fe,#f8fafc) !important;
    border-color:#0284c7 !important;
}

html[data-theme="light"] .certificate-drop-copy{
    color:#334155 !important;
}

html[data-theme="light"] .certificate-drop-copy strong{
    color:#172033 !important;
}

html[data-theme="light"] .certificate-drop-copy span{
    color:#64748b !important;
}

html[data-theme="light"] .certificate-selected-file{
    background:#eef4fa !important;
}

html[data-theme="light"] .status.info{
    background:#dbeafe !important;
    border-color:#93c5fd !important;
    color:#1e3a8a !important;
}

html[data-theme="light"] .status.success{
    background:#dcfce7 !important;
    border-color:#86efac !important;
    color:#166534 !important;
}

html[data-theme="light"] .status.warning{
    background:#fef3c7 !important;
    border-color:#fcd34d !important;
    color:#92400e !important;
}

html[data-theme="light"] .status.error{
    background:#fee2e2 !important;
    border-color:#fca5a5 !important;
    color:#991b1b !important;
}

html[data-theme="light"] body:has(.login-page){
    background:
        radial-gradient(circle at top left, rgba(37,99,235,.13), transparent 35%),
        radial-gradient(circle at bottom right, rgba(220,38,38,.08), transparent 30%),
        #edf2f7 !important;
}

html[data-theme="light"] .login-shell{
    background:rgba(255,255,255,.96) !important;
    border-color:#d7e0ea !important;
    box-shadow:0 30px 70px rgba(15,23,42,.15) !important;
}

html[data-theme="light"] .login-hero{
    background:
        linear-gradient(180deg,rgba(248,250,252,.98),rgba(238,244,250,.98)),
        linear-gradient(135deg,rgba(220,38,38,.06),transparent 45%) !important;
    border-color:#d7e0ea !important;
}

html[data-theme="light"] .login-topbar-note,
html[data-theme="light"] .login-subtitle,
html[data-theme="light"] .login-help span{
    color:#5b6879 !important;
}

html[data-theme="light"] .login-badge,
html[data-theme="light"] .login-help{
    background:#f8fafc !important;
    border-color:#d7e0ea !important;
    color:#334155 !important;
}

html[data-theme="light"] .login-help strong,
html[data-theme="light"] .login-field label{
    color:#263548 !important;
}

html[data-theme="light"] .login-form input{
    background:#ffffff !important;
    color:#172033 !important;
}
html[data-theme="light"] .backup-card{
    background:#ffffff !important;
    border-color:#d7e0ea !important;
    color:#172033 !important;
    box-shadow:0 14px 32px rgba(15,23,42,.08);
}

html[data-theme="light"] .backup-card h2,
html[data-theme="light"] .backup-card h3,
html[data-theme="light"] .backup-name{
    color:#172033 !important;
}

html[data-theme="light"] .backup-note,
html[data-theme="light"] .backup-sub{
    color:#5b6879 !important;
}

html[data-theme="light"] .backup-item{
    background:#f8fafc !important;
    border-color:#cbd5e1 !important;
    color:#172033 !important;
}

html[data-theme="light"] .backup-card input[type="file"]{
    background:#ffffff !important;
    border-color:#b8c5d4 !important;
    color:#263548 !important;
}

html[data-theme="light"] .backup-card input[type="file"]::file-selector-button{
    background:#e7edf5;
    border:1px solid #b8c5d4;
    color:#263548;
}

html[data-theme="light"] .backup-card input[type="file"]::file-selector-button:hover{
    background:#dbe5f0;
}

html[data-theme="light"] .backup-card .ghost-btn,
html[data-theme="light"] .confirm-cancel{
    background:#e7edf5 !important;
    border-color:#c7d2df !important;
    color:#263548 !important;
}

html[data-theme="light"] .backup-card .ghost-btn:hover,
html[data-theme="light"] .confirm-cancel:hover{
    background:#d6e0ec !important;
}

html[data-theme="light"] .backup-card .danger-btn{
    background:#b91c1c !important;
    border-color:#991b1b !important;
    color:#ffffff !important;
}

html[data-theme="light"] .backup-card .danger-btn:hover{
    background:#991b1b !important;
}

html[data-theme="light"] .confirm-dialog{
    background:#ffffff !important;
    border-color:#cbd5e1 !important;
    color:#172033 !important;
    box-shadow:0 24px 60px rgba(15,23,42,.22) !important;
}

html[data-theme="light"] .confirm-dialog h3{
    color:#172033 !important;
}

html[data-theme="light"] .confirm-dialog p{
    color:#5b6879 !important;
}
