/* DIGICALC 0.32 styles
   Extracted from the former single-file HTML version. */

:root {
    color-scheme: dark;
}

html {
    background: #030712;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    min-height: 100vh;
    background: linear-gradient(180deg, #111827 0%, #030712 100%);
    color: #f3f4f6;
    letter-spacing: 0.01em;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(59, 130, 246, 0.05), transparent 22%);
}

.tab-active {
    background: #2563eb;
    color: #ffffff;
    font-weight: 700;
    border: 1px solid #1d4ed8;
    box-shadow: none;
}

.tab-inactive {
    color: #9ca3af;
    border: 1px solid transparent;
    background: transparent;
}

.tab-inactive:hover {
    color: #ffffff;
    background: #374151;
    border-color: #4b5563;
}

input[type="number"], input[type="text"], input[type="date"], select, textarea {
    width: 100%;
    min-height: 42px;
    background: #030712;
    border: 1px solid #4b5563;
    color: #f9fafb;
    border-radius: 0.75rem;
    padding: 0.55rem 0.9rem;
    transition: border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}

input:hover, select:hover, textarea:hover {
    border-color: #6b7280;
    background: #0b1220;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

input::placeholder, textarea::placeholder {
    color: #6b7280;
}

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: #1f2937; }
::-webkit-scrollbar-thumb { background: #4b5563; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #6b7280; }

.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

.card {
    background: #1f2937;
    border: 1px solid #374151;
    border-radius: 1rem;
    box-shadow: 0 18px 38px -28px rgba(0, 0, 0, 0.9);
}

.soft-panel {
    background: #111827;
    border: 1px solid #374151;
    border-radius: 1rem;
}

.metric-tile {
    position: relative;
    overflow: hidden;
    background: #1f2937;
    border: 1px solid #374151;
    border-radius: 1rem;
    padding: 1rem;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.02);
}

.metric-tile::after {
    content: '';
    position: absolute;
    inset: auto -22% -52% auto;
    width: 110px;
    height: 110px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(59,130,246,0.14), transparent 66%);
    pointer-events: none;
}

.table-shell {
    overflow: hidden;
    border-radius: 1rem;
    border: 1px solid rgba(203, 213, 225, 0.95);
    background: #ffffff;
    box-shadow: 0 20px 36px -30px rgba(15, 23, 42, 0.5);
}

.shift-table thead th {
    background: rgba(17, 24, 39, 0.92);
    color: #9ca3af;
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.shift-table tbody tr:nth-child(odd) {
    background: rgba(17, 24, 39, 0.46);
}

.shift-table tbody tr:hover {
    background: rgba(31, 41, 55, 0.82);
}

.app-shell {
    position: relative;
    isolation: isolate;
    background: #030712;
}

.page-break {
    page-break-after: always;
}

.pdf-report .card {
    border: none;
    box-shadow: none;
    padding: 0 !important;
    margin-bottom: 12px !important;
    color: #000 !important;
    backdrop-filter: none !important;
    background: #fff !important;
}

.pdf-report h1 { font-size: 1.2rem !important; margin-bottom: 0.25rem !important; color: #000 !important; }
.pdf-report h2 { font-size: 1rem !important; margin-bottom: 0.2rem !important; }
.pdf-report table { font-size: 7.5px !important; border: 1px solid #e5e7eb !important; }
.pdf-report th, .pdf-report td { padding: 3px !important; border: 0.5px solid #e5e7eb !important; }
.pdf-report .avoid-break { page-break-inside: avoid; }
.pdf-report .screen-only { display: none !important; }

@media print {
    .no-print { display: none; }
    body::before { display: none; }
}

.result-ui {
    background: #1f2937 !important;
    border-color: #374151 !important;
    color: #f3f4f6 !important;
    box-shadow: 0 18px 38px -28px rgba(0, 0, 0, 0.9) !important;
}

.result-ui .screen-only .bg-white,
.result-ui .screen-only .bg-slate-50,
.result-ui .screen-only .bg-blue-50,
.result-ui .screen-only .bg-purple-50 {
    background: #111827 !important;
    border-color: #374151 !important;
}

.result-ui .screen-only .text-slate-900,
.result-ui .screen-only .text-slate-700,
.result-ui .screen-only .text-blue-700,
.result-ui .screen-only .text-purple-700 {
    color: #f9fafb !important;
}

.result-ui .screen-only .text-slate-600,
.result-ui .screen-only .text-slate-500 {
    color: #9ca3af !important;
}

.result-ui h1,
.result-ui h2,
.result-ui .text-slate-900 {
    color: #f9fafb !important;
}

.result-ui .table-shell {
    border-color: #4b5563 !important;
    background: #111827 !important;
}

.result-ui table {
    color: #e5e7eb !important;
}

.result-ui thead,
.result-ui thead th {
    background: #030712 !important;
    color: #cbd5e1 !important;
    border-color: #4b5563 !important;
}

.result-ui tbody tr,
.result-ui tbody tr:nth-child(odd),
.result-ui tbody tr:nth-child(even),
.result-ui tbody td {
    background: #111827 !important;
    border-color: #374151 !important;
    color: #e5e7eb !important;
}

.result-ui tbody tr:nth-child(even),
.result-ui tbody tr:nth-child(even) td {
    background: #0b1220 !important;
}

.result-ui tbody .bg-blue-50\/50,
.result-ui tbody .bg-emerald-50\/60,
.result-ui tbody .bg-emerald-100\/70,
.result-ui tbody .bg-purple-50\/70 {
    background: #172033 !important;
}

.result-ui tfoot,
.result-ui tfoot tr,
.result-ui tfoot td {
    background: #030712 !important;
    border-color: #374151 !important;
    color: #f9fafb !important;
}

.pdf-report,
.pdf-report * {
    color: #000 !important;
    text-shadow: none !important;
    box-shadow: none !important;
}

.pdf-report,
.pdf-report .pdf-table-section,
.pdf-report .avoid-break,
.pdf-report .bg-white,
.pdf-report .bg-gray-50\/30,
.pdf-report .bg-gray-100\/50,
.pdf-report .bg-slate-50,
.pdf-report .bg-blue-50,
.pdf-report .bg-emerald-50\/60,
.pdf-report .bg-emerald-100\/70,
.pdf-report .bg-purple-50\/70,
.pdf-report .bg-blue-700,
.pdf-report .bg-blue-800,
.pdf-report .bg-blue-900,
.pdf-report .bg-purple-700,
.pdf-report thead,
.pdf-report tbody tr,
.pdf-report tfoot,
.pdf-report tfoot tr,
.pdf-report th,
.pdf-report td {
    background: #fff !important;
}

.pdf-report table {
    border-collapse: collapse !important;
    border: 1px solid #000 !important;
}

.pdf-report th,
.pdf-report td {
    border: 0.5px solid #000 !important;
}

.pdf-report thead th,
.pdf-report tfoot td {
    font-weight: 800 !important;
}

.pdf-report .bg-blue-600,
.pdf-report .bg-gray-100,
.pdf-report .bg-gray-50,
.pdf-report .bg-slate-100 {
    background: #fff !important;
}

.pdf-report .border-blue-600,
.pdf-report .border-gray-100,
.pdf-report .border-gray-200,
.pdf-report .border-slate-200,
.pdf-report .border-slate-300,
.pdf-report .border-white\/10 {
    border-color: #000 !important;
}
