:root.theme-light,
html.theme-light {
  --sunlit-wheat: #F4F0E5;
  --silent-waters: #3F4E4F;
  --midnight-sky: #1A2224;
  --stone-tint: #8E857C;
  --brown-sugar: #A27B5C;
  --brown-sugar-tint: #A58061;
  --soft-stone: #CDB8A3;
  --amber-glow: #BD7B46;
  --amber-rgb: 189, 123, 70;
  --dusty-wine: #7B4E57;
  --divider-stone: rgba(26, 34, 36, 0.08);
  --focus-amber: rgba(189, 123, 70, 0.65);
}

html.theme-light,
html.theme-light body {
  background: var(--sunlit-wheat);
  color: var(--silent-waters);
}

html.theme-light ::selection {
  background: rgba(189, 123, 70, 0.35);
  color: var(--midnight-sky);
}

html.theme-light h1,
html.theme-light h2,
html.theme-light h3,
html.theme-light h4,
html.theme-light h5,
html.theme-light h6 {
  color: var(--midnight-sky) !important;
}

html.theme-light label {
  color: var(--midnight-sky);
}

html.theme-light .text-soft {
  color: var(--silent-waters) !important;
}

html.theme-light .text-white {
  color: var(--midnight-sky) !important;
}

html.theme-light .text-white\/80 { color: var(--midnight-sky) !important; }
html.theme-light .text-white\/70 { color: rgba(26, 34, 36, 0.82) !important; }
html.theme-light .text-white\/60 { color: rgba(26, 34, 36, 0.72) !important; }
html.theme-light .text-white\/50 { color: rgba(26, 34, 36, 0.66) !important; }
html.theme-light .text-white\/40 { color: rgba(26, 34, 36, 0.58) !important; }
html.theme-light .text-white\/20 { color: rgba(26, 34, 36, 0.42) !important; }
html.theme-light .text-esoteric-slate { color: var(--stone-tint) !important; }

html.theme-light .text-esoteric-copper { color: var(--amber-glow) !important; }
html.theme-light .text-esoteric-emerald { color: var(--dusty-wine) !important; }
html.theme-light .text-text-secondary { color: var(--stone-tint) !important; }

html.theme-light .bg-background-light,
html.theme-light .bg-background-dark {
  background-color: var(--sunlit-wheat) !important;
}

html.theme-light .bg-background-dark\/60 {
  background-color: rgba(205, 184, 163, 0.88) !important;
}

html.theme-light .bg-background-dark\/70 {
  background-color: rgba(165, 128, 92, 0.9) !important;
}

html.theme-light .bg-surface-dark {
  background-color: var(--brown-sugar-tint) !important;
}

html.theme-light .bg-surface-dark\/60 {
  background-color: rgba(205, 184, 163, 0.9) !important;
}
html.theme-light .bg-esoteric-dark {
  background-color: #1f2a30 !important;
  color: var(--sunlit-wheat) !important;
}

html.theme-light .bg-white\/5 {
  background-color: rgba(205, 184, 163, 0.6) !important;
}

html.theme-light .bg-white\/10 {
  background-color: rgba(205, 184, 163, 0.78) !important;
}

html.theme-light .border-white\/10,
html.theme-light .border-white\/5 {
  border-color: var(--divider-stone) !important;
}

html.theme-light .bg-primary,
html.theme-light .hover\:bg-primary:hover {
  background-color: var(--amber-glow) !important;
}

html.theme-light .bg-primary\/90 { background-color: rgba(var(--amber-rgb), 0.9) !important; }
html.theme-light .bg-primary\/50 { background-color: rgba(var(--amber-rgb), 0.5) !important; }
html.theme-light .bg-primary\/40 { background-color: rgba(var(--amber-rgb), 0.4) !important; }
html.theme-light .bg-primary\/30 { background-color: rgba(var(--amber-rgb), 0.3) !important; }
html.theme-light .bg-primary\/25 { background-color: rgba(var(--amber-rgb), 0.25) !important; }
html.theme-light .bg-primary\/20 { background-color: rgba(var(--amber-rgb), 0.2) !important; }
html.theme-light .bg-primary\/15 { background-color: rgba(var(--amber-rgb), 0.15) !important; }
html.theme-light .bg-primary\/10 { background-color: rgba(var(--amber-rgb), 0.1) !important; }

html.theme-light .bg-primary-soft {
  background-color: #d9b08c !important;
}

html.theme-light .bg-primary-deep,
html.theme-light .hover\:bg-primary-deep:hover {
  background-color: #8f5631 !important;
}

html.theme-light .text-primary {
  color: var(--amber-glow) !important;
}

html.theme-light .border-primary {
  border-color: var(--amber-glow) !important;
}

html.theme-light .border-primary\/50 { border-color: rgba(var(--amber-rgb), 0.5) !important; }
html.theme-light .border-primary\/40 { border-color: rgba(var(--amber-rgb), 0.4) !important; }
html.theme-light .border-primary\/30 { border-color: rgba(var(--amber-rgb), 0.3) !important; }
html.theme-light .border-primary\/20 { border-color: rgba(var(--amber-rgb), 0.2) !important; }

html.theme-light header {
  background: rgba(205, 184, 163, 0.92) !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky);
}

html.theme-light header .text-white,
html.theme-light header .text-white\/50,
html.theme-light header .text-white\/70 {
  color: var(--midnight-sky) !important;
}

html.theme-light header .text-white\/50 {
  color: var(--stone-tint) !important;
}

html.theme-light nav a {
  color: var(--midnight-sky);
}

html.theme-light .card-glow {
  box-shadow: 0 18px 48px rgba(26, 34, 36, 0.18);
}

html.theme-light .astro-card {
  background: linear-gradient(145deg, rgba(165, 128, 97, 0.96), rgba(189, 123, 70, 0.92));
  border: 1px solid var(--divider-stone);
  box-shadow: 0 18px 48px rgba(26, 34, 36, 0.18);
  color: var(--sunlit-wheat);
}
html.theme-light .intro-card {
  background: #A27B5C;
  border-color: var(--divider-stone);
  color: var(--midnight-sky);
}
html.theme-light .intro-card h1 { color: var(--midnight-sky) !important; }
html.theme-light .intro-card p { color: var(--midnight-sky) !important; }
html.theme-light .intro-card .text-esoteric-slate,
html.theme-light .intro-card .text-sm.uppercase {
  color: rgba(26, 34, 36, 0.78) !important;
}

html.theme-light .astro-pill {
  background: rgba(205, 184, 163, 0.95);
  border: 1px solid var(--divider-stone);
  color: var(--midnight-sky);
}

html.theme-light .astro-pill .material-symbols-outlined {
  color: var(--amber-glow);
}

html.theme-light .astro-subcard {
  background: rgba(205, 184, 163, 0.86);
  border: 1px solid var(--divider-stone);
  color: var(--silent-waters);
}

html.theme-light .entry-content {
  color: var(--silent-waters);
}

html.theme-light .entry-content blockquote {
  border-left-color: var(--divider-stone);
  color: var(--silent-waters);
}

html.theme-light .manual-overlay {
  background: rgba(205, 184, 163, 0.92);
  border: 1px solid var(--divider-stone);
}

html.theme-light .manual-pill {
  background: var(--soft-stone);
  border-color: var(--divider-stone);
  color: var(--midnight-sky);
}

html.theme-light .manual-pill select {
  color: var(--midnight-sky);
}

html.theme-light .manual-pill .rx-toggle {
  background: rgba(189, 123, 70, 0.15);
  color: var(--midnight-sky);
}

html.theme-light .manual-pill .rx-toggle.active {
  background: rgba(189, 123, 70, 0.35);
  color: var(--midnight-sky);
}

html.theme-light .cal-card {
  background: var(--soft-stone);
  border: 1px solid var(--divider-stone);
}
html.theme-light .cal-card h2,
html.theme-light .cal-card p,
html.theme-light .cal-card .uppercase,
html.theme-light .cal-card .text-esoteric-slate {
  color: var(--midnight-sky) !important;
}

html.theme-light .cal-day {
  background: var(--sunlit-wheat);
  border: 1px solid rgba(26, 34, 36, 0.14);
  color: var(--midnight-sky);
}
html.theme-light .cal-day .text-white,
html.theme-light .cal-day .text-white\/60 {
  color: var(--midnight-sky) !important;
}
html.theme-light .cal-day .cal-icon-face { color: inherit !important; }

html.theme-light .cal-day .date-circle {
  border-color: rgba(189, 123, 70, 0.85);
  color: var(--midnight-sky);
}

html.theme-light .cal-day.today {
  border-color: rgba(189, 123, 70, 0.85);
  box-shadow: 0 0 0 1px rgba(189, 123, 70, 0.6);
}

html.theme-light .cal-day:hover {
  background: var(--soft-stone);
  border-color: rgba(189, 123, 70, 0.55);
}

html.theme-light input,
html.theme-light select,
html.theme-light textarea,
html.theme-light .choices__inner {
  background: rgba(205, 184, 163, 0.9) !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}

html.theme-light input::placeholder,
html.theme-light textarea::placeholder {
  color: rgba(26, 34, 36, 0.55);
}

html.theme-light input:focus,
html.theme-light select:focus,
html.theme-light textarea:focus,
html.theme-light .choices.is-focused .choices__inner,
html.theme-light .choices.is-open .choices__inner {
  box-shadow: 0 0 0 3px var(--focus-amber) !important;
  border-color: var(--amber-glow) !important;
  outline: none !important;
}

html.theme-light .choices__list--dropdown,
html.theme-light .choices__list[aria-expanded] {
  background: var(--sunlit-wheat) !important;
  border-color: var(--divider-stone) !important;
}

html.theme-light .choices__list--dropdown .choices__item,
html.theme-light .choices__list[aria-expanded] .choices__item {
  color: var(--midnight-sky) !important;
}

html.theme-light .choices__list--dropdown .choices__item--selectable.is-highlighted {
  background: rgba(189, 123, 70, 0.18) !important;
  color: var(--midnight-sky) !important;
}

html.theme-light .choices__placeholder {
  color: rgba(26, 34, 36, 0.5) !important;
}

html.theme-light .tox {
  --surface: var(--soft-stone);
  --border: var(--divider-stone);
}

html.theme-light .tox .tox-toolbar,
html.theme-light .tox .tox-toolbar__primary,
html.theme-light .tox .tox-editor-header {
  background: var(--soft-stone) !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}

html.theme-light .tox .tox-menubar,
html.theme-light .tox .tox-statusbar {
  background: var(--soft-stone) !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}

html.theme-light .tox .tox-edit-area__iframe {
  background: var(--sunlit-wheat);
}

html.theme-light .tox .tox-tbtn,
html.theme-light .tox .tox-mbtn {
  color: var(--midnight-sky);
}

html.theme-light .tox .tox-tbtn:hover,
html.theme-light .tox .tox-mbtn:hover {
  background: rgba(189, 123, 70, 0.15);
}

html.theme-light .dropzone {
  border-color: var(--divider-stone);
  background: rgba(205, 184, 163, 0.35);
}

html.theme-light .dropzone .dz-message {
  color: var(--midnight-sky);
}

html.theme-light .bg-black\/40 {
  background-color: rgba(26, 34, 36, 0.35) !important;
}

html.theme-light .border-emerald-300\/30,
html.theme-light .border-red-300\/30 {
  border-color: var(--divider-stone) !important;
}

html.theme-light .bg-emerald-500\/10,
html.theme-light .bg-red-500\/10 {
  background-color: rgba(165, 128, 92, 0.25) !important;
  color: var(--midnight-sky) !important;
}

html.theme-light .pattern-snapshot {
  background: linear-gradient(135deg, rgba(205, 184, 163, 0.92), rgba(189, 123, 70, 0.18)) !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky);
}
html.theme-light .pattern-snapshot .text-esoteric-slate {
  color: var(--silent-waters) !important;
}

/* Entry detail page (light) */
html.theme-light .entry-page .astro-card {
  background: linear-gradient(180deg, var(--sunlit-wheat), #f7f2e8);
  border: 1px solid var(--divider-stone);
  box-shadow: 0 16px 36px rgba(26, 34, 36, 0.12);
  color: var(--silent-waters);
}
html.theme-light .entry-page .astro-card .entry-content,
html.theme-light .entry-page .astro-card .entry-content p,
html.theme-light .entry-page .astro-card .entry-content h1,
html.theme-light .entry-page .astro-card .entry-content h2,
html.theme-light .entry-page .astro-card .entry-content h3 {
  color: var(--midnight-sky);
}
html.theme-light .entry-page .astro-card .entry-content blockquote {
  border-left-color: var(--divider-stone);
}
html.theme-light .entry-page .astro-card a {
  color: var(--amber-glow);
}
html.theme-light .entry-page .astro-card a:hover {
  color: #8f5631;
}
html.theme-light .entry-page .bg-surface-dark\/60 {
  background: #f1e8dc !important;
  border: 1px solid var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}

html.theme-light .shadow-card {
  background: var(--sunlit-wheat) !important;
  border-color: rgba(162, 123, 92, 0.35) !important;
  position: relative;
  overflow: hidden;
}
html.theme-light .shadow-card h4,
html.theme-light .shadow-card .text-white,
html.theme-light .shadow-card .text-gray-300,
html.theme-light .shadow-card .text-gray-500 {
  color: var(--midnight-sky) !important;
}
html.theme-light .shadow-card p {
  color: var(--silent-waters) !important;
}
html.theme-light .shadow-card .shadow-badge {
  background: var(--amber-glow) !important;
  color: var(--sunlit-wheat) !important;
  border: 1px solid rgba(162, 123, 92, 0.4) !important;
}
html.theme-light .shadow-card .material-symbols-outlined,
html.theme-light .shadow-card .text-esoteric-brown {
  color: var(--amber-glow) !important;
}
html.theme-light .shadow-card .shadow-accent {
  background: var(--amber-glow) !important;
  opacity: 0.8;
}
html.theme-light .shadow-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(189, 123, 70, 0.08), rgba(244, 240, 229, 0));
  pointer-events: none;
}

/* Calendar mood icon colors (higher contrast) */
html.theme-light .cal-card .cal-icon-face.text-yellow-300 { color: #b45309 !important; }
html.theme-light .cal-card .cal-icon-face.text-blue-300 { color: #2563eb !important; }
html.theme-light .cal-card .cal-icon-face.text-pink-300 { color: #be185d !important; }
html.theme-light .cal-card .cal-icon-face.text-emerald-300 { color: #047857 !important; }
html.theme-light .cal-card .cal-icon-face.text-green-300 { color: #15803d !important; }
html.theme-light .cal-card .cal-icon-face.text-gray-300 { color: #4b5563 !important; }
html.theme-light .cal-card .cal-icon-face.text-red-300 { color: #b91c1c !important; }
html.theme-light .cal-card .cal-icon-face.text-indigo-200 { color: #4338ca !important; }
html.theme-light .cal-card .cal-icon-face.text-amber-300 { color: #b45309 !important; }
html.theme-light .cal-card .cal-icon-face.text-cyan-300 { color: #0ea5e9 !important; }

/* New Entry light tweaks */
html.theme-light .new-entry-page input,
html.theme-light .new-entry-page select,
html.theme-light .new-entry-page textarea {
  background: transparent !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page input::placeholder,
html.theme-light .new-entry-page textarea::placeholder {
  color: rgba(26, 34, 36, 0.5);
}
html.theme-light .new-entry-page .choices__inner {
  background: transparent !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .choices__list--dropdown,
html.theme-light .new-entry-page .choices__list[aria-expanded] {
  background: var(--sunlit-wheat) !important;
  border-color: var(--divider-stone) !important;
}
html.theme-light .new-entry-page .manual-overlay {
  background: rgba(205, 184, 163, 0.92) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .manual-pill {
  background: transparent !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .manual-pill option { color: var(--midnight-sky); }
html.theme-light .new-entry-page .card-stage,
html.theme-light .new-entry-page #card-stage,
html.theme-light .new-entry-page .card-preview {
  background: #f4f0e5 !important;
  border: 1px solid rgba(162, 123, 92, 0.3) !important;
}
html.theme-light .new-entry-page #card-preview-name,
html.theme-light .new-entry-page #card-preview-arcana {
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .bg-background-dark\/70 {
  background: #a27b5c !important;
  color: var(--sunlit-wheat) !important;
}
html.theme-light .new-entry-page .bg-background-dark\/70 .text-white,
html.theme-light .new-entry-page .bg-background-dark\/70 .text-text-secondary {
  color: var(--sunlit-wheat) !important;
}
html.theme-light .new-entry-page .tox {
  --surface: #fdf8f0;
  --border: rgba(26, 34, 36, 0.18);
}
html.theme-light .new-entry-page .tox .tox-toolbar,
html.theme-light .new-entry-page .tox .tox-toolbar__primary,
html.theme-light .new-entry-page .tox .tox-editor-header {
  background: #f0e7da !important;
  border-color: rgba(26, 34, 36, 0.14) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .tox .tox-menubar,
html.theme-light .new-entry-page .tox .tox-statusbar {
  background: #f0e7da !important;
  border-color: rgba(26, 34, 36, 0.14) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .tox .tox-edit-area__iframe {
  background: #fdf8f0 !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .tox .tox-tbtn,
html.theme-light .new-entry-page .tox .tox-mbtn {
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .tox .tox-tbtn:hover,
html.theme-light .new-entry-page .tox .tox-mbtn:hover {
  background: rgba(26, 34, 36, 0.08);
}
html.theme-light .new-entry-page .tox .tox-toolbar__primary .tox-tbtn--enabled,
html.theme-light .new-entry-page .tox .tox-toolbar__primary .tox-tbtn--enabled:hover {
  background: rgba(189, 123, 70, 0.16) !important;
  border-color: transparent !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .tox .tox-edit-area__iframe body {
  background: #fdf8f0 !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page .tox .tox-toolbar__group {
  border-color: rgba(26, 34, 36, 0.1) !important;
}
html.theme-light .new-entry-page #card-stage .bg-primary\/25 {
  display: none !important;
}
html.theme-light .new-entry-page #astro-intro-card h2,
html.theme-light .new-entry-page #astro-intro-card p,
html.theme-light .new-entry-page #astro-intro-card .text-text-secondary {
  font-family: 'Spline Sans', 'Source Sans Pro', system-ui, sans-serif !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .new-entry-page #astro-intro-card h2 {
  font-weight: 600;
}

/* Admin add card: lighten form fields */
html.theme-light .admin-add-page input,
html.theme-light .admin-add-page select,
html.theme-light .admin-add-page textarea,
html.theme-light .admin-add-page .tinymce-field {
  background: transparent !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .admin-add-page input::placeholder,
html.theme-light .admin-add-page textarea::placeholder {
  color: rgba(26, 34, 36, 0.5);
}
html.theme-light .admin-add-page label {
  color: var(--midnight-sky);
}

html.theme-light .admin-edit-page input,
html.theme-light .admin-edit-page select,
html.theme-light .admin-edit-page textarea,
html.theme-light .admin-edit-page .tinymce-field {
  background: transparent !important;
  border-color: var(--divider-stone) !important;
  color: var(--midnight-sky) !important;
}
html.theme-light .admin-edit-page input::placeholder,
html.theme-light .admin-edit-page textarea::placeholder {
  color: rgba(26, 34, 36, 0.5);
}
html.theme-light .admin-edit-page label {
  color: var(--midnight-sky);
}
}
