:root {
    color-scheme: light;
    --theme-page: #ffffff;
    --theme-surface: #ffffff;
    --theme-text: #111827;
    --theme-muted: #64748b;
    --theme-border: #cbd5e1;
}

html,
body { background: var(--theme-page) !important; }

html[data-theme="dark"] {
    color-scheme: dark;
    --theme-page: #101722;
    --theme-surface: #161d29;
    --theme-text: #edf2f7;
    --theme-muted: #bdc9da;
    --theme-border: #3e4d63;
    --theme-fg-purple: #c4b5fd;
    --theme-fg-green: #86efac;
    --theme-fg-blue: #93c5fd;
    --theme-fg-cyan: #67e8f9;
    --theme-fg-amber: #fde68a;
    --theme-fg-rose: #fda4af;
    --theme-fg-red: #fda4af;
    --crp-bg-06b6d4: #04778b;
    --crp-bg-10b981: #0b835c;
    --crp-bg-15803d: #147b3a;
    --crp-bg-16a34a: #117e39;
    --crp-bg-16a34a-a180: rgba(17, 126, 57, 0.18);
    --crp-bg-22c55e: #157a3a;
    --crp-bg-22c55e-a180: rgba(21, 122, 58, 0.18);
    --crp-bg-2563eb: #0c3183;
    --crp-bg-2563eb-a140: rgba(12, 49, 131, 0.14);
    --crp-bg-38bdf8: #05618a;
    --crp-bg-3b82f6: #063889;
    --crp-bg-5b21b6: #3c1679;
    --crp-bg-6b7280: #415168;
    --crp-bg-6d28d9: #3c1579;
    --crp-bg-7c3aed: #380c83;
    --crp-bg-7c3aed-a140: rgba(56, 12, 131, 0.14);
    --crp-bg-7c3aed-a180: rgba(56, 12, 131, 0.18);
    --crp-bg-86efac: #117e38;
    --crp-bg-94a3b8: #394556;
    --crp-bg-9ca3af: #415168;
    --crp-bg-a855f7: #490688;
    --crp-bg-b91c1c: #7c1313;
    --crp-bg-bbf7d0: #0f3d1f;
    --crp-bg-be123c: #820c29;
    --crp-bg-bfdbfe: #0f243d;
    --crp-bg-cbd5e1: #1c2531;
    --crp-bg-cffafe: #0f393d;
    --crp-bg-d1d5db: #334155;
    --crp-bg-d8b4fe: #260f3d;
    --crp-bg-d97706: #8b4c04;
    --crp-bg-dbe1e8: #1e262f;
    --crp-bg-dbe3ec: #1a2632;
    --crp-bg-dbeafe: #0f233d;
    --crp-bg-dc2626: #7b1414;
    --crp-bg-dcfce7: #0f3d1f;
    --crp-bg-ddd6fe-a950: rgba(23, 15, 61, 0.95);
    --crp-bg-e11d48: #7e1028;
    --crp-bg-e2e8f0: #1a2532;
    --crp-bg-e2e8f0-a720: rgba(26, 37, 50, 0.72);
    --crp-bg-e5e7eb: #1e293b;
    --crp-bg-e9d5ff: #250f3d;
    --crp-bg-ea580c: #883307;
    --crp-bg-ecfdf5: #0f3d28;
    --crp-bg-ecfeff: #0f3b3d;
    --crp-bg-ede9fe: #180f3d;
    --crp-bg-eef2f7: #182534;
    --crp-bg-eef2ff: #0f1a3d;
    --crp-bg-ef4444: #840b0b;
    --crp-bg-eff6ff: #0f233d;
    --crp-bg-f0f9ff: #0f2b3d;
    --crp-bg-f0fdf4: #0f3d1d;
    --crp-bg-f1f5f9: #172636;
    --crp-bg-f3e8ff: #250f3d;
    --crp-bg-f3f4f6: #161d29;
    --crp-bg-f59e0b: #895806;
    --crp-bg-f5f3ff: #170f3d;
    --crp-bg-f8fafc: #172636;
    --crp-bg-f8fafc-a820: rgba(23, 38, 54, 0.82);
    --crp-bg-f8fafc-a940: rgba(23, 38, 54, 0.94);
    --crp-bg-f97316: #8b3b04;
    --crp-bg-facc15: #8c7003;
    --crp-bg-faf5ff: #260f3d;
    --crp-bg-faf5ff-a580: rgba(38, 15, 61, 0.58);
    --crp-bg-faf5ff-a950: rgba(38, 15, 61, 0.95);
    --crp-bg-faf5ff-a960: rgba(38, 15, 61, 0.96);
    --crp-bg-fb7185: #8b0417;
    --crp-bg-fb923c: #8c4103;
    --crp-bg-fbbf24: #8c6603;
    --crp-bg-fbfaff: #180f3d;
    --crp-bg-fde68a: #3d340f;
    --crp-bg-fecaca: #3d0f0f;
    --crp-bg-fecdd3: #3d0f15;
    --crp-bg-fee2e2: #3d0f0f;
    --crp-bg-fef2f2: #3d0f0f;
    --crp-bg-fef3c7: #3d340f;
    --crp-bg-ffe4e6: #3d0f13;
    --crp-bg-ffedd5: #3d2a0f;
    --crp-bg-fff1f2: #3d0f13;
    --crp-bg-fff7ed: #3d290f;
    --crp-bg-fffbeb: #3d340f;
    --crp-bg-ffffff: #161d29;
    --crp-bg-ffffff-a350: rgba(22, 29, 41, 0.35);
    --crp-bg-ffffff-a360: rgba(22, 29, 41, 0.36);
    --crp-bg-ffffff-a420: rgba(22, 29, 41, 0.42);
    --crp-bg-ffffff-a450: rgba(22, 29, 41, 0.45);
    --crp-bg-ffffff-a550: rgba(22, 29, 41, 0.55);
    --crp-bg-ffffff-a580: rgba(22, 29, 41, 0.58);
    --crp-bg-ffffff-a720: rgba(22, 29, 41, 0.72);
    --crp-bg-ffffff-a780: rgba(22, 29, 41, 0.78);
    --crp-bg-ffffff-a860: rgba(22, 29, 41, 0.86);
    --crp-bg-ffffff-a900: rgba(22, 29, 41, 0.9);
    --crp-bg-ffffff-a960: rgba(22, 29, 41, 0.96);
    --crp-bg-ffffff-a980: rgba(22, 29, 41, 0.98);
    --crp-border-06b6d4: #208697;
    --crp-border-0ea5e9: #207297;
    --crp-border-16a34a: #20974c;
    --crp-border-16a34a-a140: rgba(32, 151, 76, 0.14);
    --crp-border-16a34a-a280: rgba(32, 151, 76, 0.28);
    --crp-border-16a34a-a340: rgba(32, 151, 76, 0.34);
    --crp-border-16a34a-a400: rgba(32, 151, 76, 0.4);
    --crp-border-22c55e: #20974c;
    --crp-border-22c55e-a260: rgba(32, 151, 76, 0.26);
    --crp-border-2563eb: #204597;
    --crp-border-2563eb-a160: rgba(32, 69, 151, 0.16);
    --crp-border-2563eb-a200: rgba(32, 69, 151, 0.2);
    --crp-border-2563eb-a240: rgba(32, 69, 151, 0.24);
    --crp-border-2563eb-a340: rgba(32, 69, 151, 0.34);
    --crp-border-2563eb-a380: rgba(32, 69, 151, 0.38);
    --crp-border-3b82f6: #204d97;
    --crp-border-60a5fa: #205697;
    --crp-border-64748b: #3e4d63;
    --crp-border-6b7280: #3e4d63;
    --crp-border-6d28d9: #4f2097;
    --crp-border-7c3aed: #4c2097;
    --crp-border-7c3aed-a140: rgba(76, 32, 151, 0.14);
    --crp-border-7c3aed-a220: rgba(76, 32, 151, 0.22);
    --crp-border-7c3aed-a240: rgba(76, 32, 151, 0.24);
    --crp-border-7c3aed-a260: rgba(76, 32, 151, 0.26);
    --crp-border-7c3aed-a280: rgba(76, 32, 151, 0.28);
    --crp-border-7c3aed-a340: rgba(76, 32, 151, 0.34);
    --crp-border-7c3aed-a350: rgba(76, 32, 151, 0.35);
    --crp-border-7c3aed-a520: rgba(76, 32, 151, 0.52);
    --crp-border-86efac: #20974b;
    --crp-border-8b5cf6: #452097;
    --crp-border-93c5fd: #205897;
    --crp-border-94a3b8: #3e4d63;
    --crp-border-9ca3af: #3e4d63;
    --crp-border-a78bfa: #3e2097;
    --crp-border-a7f3d0: #209761;
    --crp-border-a855f7: #5d2097;
    --crp-border-b45309: #975420;
    --crp-border-b91c1c: #972020;
    --crp-border-bae6fd: #206f97;
    --crp-border-bbf7d0: #20974a;
    --crp-border-bfdbfe: #205597;
    --crp-border-c4b5fd: #392097;
    --crp-border-c7d2fe: #203897;
    --crp-border-cbd5e1: #435a74;
    --crp-border-d1d5db: #3e4d63;
    --crp-border-d8b4fe: #5a2097;
    --crp-border-d97706: #976020;
    --crp-border-dbe2ed: #3d557a;
    --crp-border-dbeafe: #205397;
    --crp-border-dc2626: #972020;
    --crp-border-ddd6fe: #352097;
    --crp-border-e11d48: #97203a;
    --crp-border-e11d48-a320: rgba(151, 32, 58, 0.32);
    --crp-border-e11d48-a340: rgba(151, 32, 58, 0.34);
    --crp-border-e2e8f0: #3f5879;
    --crp-border-e5e7eb: #3e4d63;
    --crp-border-ea580c: #974920;
    --crp-border-ede9fe: #372097;
    --crp-border-f43f5e: #972035;
    --crp-border-f59e0b: #976b20;
    --crp-border-f59e0b-a380: rgba(151, 107, 32, 0.38);
    --crp-border-f59e0b-a420: rgba(151, 107, 32, 0.42);
    --crp-border-f97316: #975120;
    --crp-border-fb7185: #972031;
    --crp-border-fb923c: #975620;
    --crp-border-fcd34d: #977c20;
    --crp-border-fdba74: #975d20;
    --crp-border-fde68a: #978020;
    --crp-border-fecaca: #972020;
    --crp-border-fecdd3: #97202f;
    --crp-border-fed7aa: #976020;
    --crp-border-ffffff: #3e4d63;
    --crp-fg-0f172a: #acbce1;
    --crp-fg-111827: #b1bfdd;
    --crp-fg-14532d: #a5e9c0;
    --crp-fg-155e75: #a0dbee;
    --crp-fg-15803d: #9fefbd;
    --crp-fg-166534: #a3ebbe;
    --crp-fg-16a34a: #9cf2bc;
    --crp-fg-16a34a-a900: rgba(156, 242, 188, 0.9);
    --crp-fg-1d4ed8: #9cb3f2;
    --crp-fg-1e3a8a: #a3b6eb;
    --crp-fg-1f2937: #b7c4d7;
    --crp-fg-22c55e: #9feebc;
    --crp-fg-312e81: #aeace2;
    --crp-fg-334155: #edf2f7;
    --crp-fg-374151: #edf2f7;
    --crp-fg-422006: #f4c19a;
    --crp-fg-475569: #cbd5e1;
    --crp-fg-4b5563: #cbd5e1;
    --crp-fg-4c1d95: #bfa1ed;
    --crp-fg-581c87: #cba2ec;
    --crp-fg-5b21b6: #bea0ee;
    --crp-fg-64748b: #cbd5e1;
    --crp-fg-6b7280: #cbd5e1;
    --crp-fg-6d28d9: #bea0ee;
    --crp-fg-7c2d12: #f1b29d;
    --crp-fg-8b94a6: #cbd5e1;
    --crp-fg-92400e: #f4bc9a;
    --crp-fg-991b1b: #eea0a0;
    --crp-fg-9a3412: #f3b19b;
    --crp-fg-9ca3af: #cbd5e1;
    --crp-fg-9f1239: #f49ab3;
    --crp-fg-b91c1c: #f09e9e;
    --crp-fg-be123c: #f49ab0;
    --crp-fg-c2410c: #f4b49a;
    --crp-fg-dc2626: #ef9e9e;
    --crp-fg-ef4444: #f49a9a;
    --blog-ink: #b1bfdd !important;
    --blog-line: #3e4d63 !important;
    --blog-muted: #cbd5e1 !important;
    --border: #352097 !important;
    --crp-border: #352097 !important;
    --crp-ink: #b1bfdd !important;
    --crp-muted: #cbd5e1 !important;
    --green-soft: #0f3d1f !important;
    --grey-card: #161d29 !important;
    --grey-panel: #1c2530 !important;
    --grey-panel-strong: #1e293b !important;
    --ink: #b1bfdd !important;
    --line: #3e4d63 !important;
    --muted: #cbd5e1 !important;
    --nav-panel-bg: #161d29 !important;
    --panel: #161d29 !important;
    --purple-soft: #2e0787 !important;
    --reminder-border: #425475 !important;
    --reminder-ink: #b1bfdd !important;
    --reminder-muted: #cbd5e1 !important;
    --reminder-panel: #161d29 !important;
    --reminder-soft: #172636 !important;
    --surface: #161d29 !important;
    --surface-soft: #172636 !important;
    --text: #b1bfdd !important;
    --text: #edf2f7 !important;
    --ink: #edf2f7 !important;
    --muted: #bdc9da !important;
    --surface: #161d29 !important;
    --surface-soft: #1e293b !important;
    --border: #3e4d63 !important;
    --line: #3e4d63 !important;
    --nav-panel-bg: #161d29 !important;
    --purple-light: #241b32 !important;
    --violet-soft: #241b32 !important;
    --green-light: #122b20 !important;
    --green-soft: #122b20 !important;
    --blue-light: #15263c !important;
    --amber-light: #302616 !important;
    --rose-light: #321d27 !important;
    --cyan-light: #142d34 !important;
    --green: #15803d !important;
    --green-dark: #166534 !important;
    --green-bright: #15803d !important;
    --crp-green: #15803d !important;
    --crp-green-bright: #15803d !important;
    --crp-amber: #8b5700 !important;
    --crp-blue: #1d4ed8 !important;
    --crp-cyan: #0e7490 !important;
    --amber: #8b5700 !important;
    --orange: #b45309 !important;
    --blue: #1d4ed8 !important;
    --cyan: #0e7490 !important;
}

#themeSettingsPanel[hidden] { display: none !important; }
.theme-choices { display: flex; flex-wrap: wrap; gap: 10px; border: 0; padding: 0; margin: 0; }
.theme-choices legend { margin-bottom: 10px; color: var(--theme-muted); font-size: 14px; }
.theme-choice { display: inline-flex; align-items: center; gap: 9px; min-height: 46px; padding: 11px 15px; border: 2px solid var(--theme-border); border-radius: 10px; background: var(--theme-surface); color: var(--theme-text); font-size: 14px; font-weight: 700; cursor: pointer; }
.theme-choice:has(input:checked) { border-color: #8b5cf6; }
.theme-choice:focus-within { outline: 3px solid #a78bfa; outline-offset: 3px; }
.theme-choice input { accent-color: #7c3aed; margin: 0; }
.theme-swatch { width: 20px; height: 20px; border: 1px solid #94a3b8; border-radius: 50%; }
.theme-swatch-white { background: #ffffff; }
.theme-swatch-dark { background: #101722; }

@media print {
    html,
    body { background: #ffffff !important; color: #111827 !important; }
}
