/* Homepage-only light theme. Keep chapter identity in small accents, not full-color bands. */
html[data-theme="light"] {
  --bg: #d2e4e2;
  --bg2: #bcd5d4;
  --card: rgba(255, 255, 255, .82);
  --card-hover: rgba(255, 255, 255, .94);
  --border: rgba(24, 74, 79, .21);
  --border-hover: rgba(14, 103, 96, .36);
  --teal: #087d72;
  --teal-dim: rgba(8, 125, 114, .11);
  --teal-glow: rgba(8, 125, 114, .2);
  --purple: #536aa0;
  --purple-dim: rgba(83, 106, 160, .09);
  --gold: #8a651c;
  --gold-dim: rgba(138, 101, 28, .085);
  --rose: #a34f68;
  --blue: #2e7097;
  --text: #0d292e;
  --muted: #3d6065;
  --muted2: #657d81;
}

html[data-theme="light"] body {
  background:
    radial-gradient(circle at 12% 8%, rgba(6, 104, 99, .18), transparent 31%),
    radial-gradient(circle at 88% 13%, rgba(52, 93, 151, .15), transparent 30%),
    radial-gradient(circle at 70% 76%, rgba(184, 126, 35, .07), transparent 28%),
    linear-gradient(90deg,
      #8fabad 0%,
      #bad0cf 13%,
      #edf5f3 34%,
      #f3f8f7 66%,
      #b8cfce 87%,
      #8ba8ac 100%);
}

html[data-theme="light"] .motion-field {
  opacity: .58;
  background: linear-gradient(90deg,
    rgba(25, 76, 84, .16),
    rgba(25, 76, 84, .035) 18%,
    transparent 34% 66%,
    rgba(44, 75, 111, .035) 82%,
    rgba(44, 75, 111, .16));
}
html[data-theme="light"] .motion-field::before {
  filter: saturate(.92) contrast(1.1);
}
html[data-theme="light"] .motion-field::after {
  opacity: .34;
  mix-blend-mode: multiply;
  filter: saturate(.86) contrast(1.08);
}
html[data-theme="light"] .motion-thread {
  border-color: rgba(24, 74, 79, .13);
  opacity: .56;
  filter: saturate(.8);
}
html[data-theme="light"] #particles {
  opacity: .58;
  filter: saturate(1.12) contrast(1.08);
}

html[data-theme="light"] #topnav {
  background-color: rgba(224, 239, 237, .9);
  background-image: linear-gradient(90deg,
    rgba(8, 89, 87, .1),
    rgba(255, 255, 255, .58) 22% 78%,
    rgba(54, 82, 126, .09));
  border-bottom-color: rgba(17, 68, 74, .2);
  box-shadow: 0 10px 34px rgba(18, 59, 65, .12);
  backdrop-filter: blur(26px) saturate(1.22);
}
html[data-theme="light"] #topnav::after {
  content: '';
  position: absolute;
  left: 5%;
  right: 5%;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(8, 125, 114, .45), rgba(70, 92, 143, .32), transparent);
  pointer-events: none;
}
html[data-theme="light"].is-scrolling #topnav {
  background: rgba(218, 235, 233, .98);
  box-shadow: 0 8px 26px rgba(18, 59, 65, .14);
}
html[data-theme="light"] .nav-logo {
  color: #f5fffe;
  padding-inline: .72rem;
  letter-spacing: -.055em;
  background: linear-gradient(135deg, #082e34 0%, #10515a 56%, #263f61 100%);
  border-color: rgba(255, 255, 255, .28);
  box-shadow: 0 8px 22px rgba(11, 54, 61, .2), inset 0 1px rgba(255, 255, 255, .16);
}
html[data-theme="light"] .nav-logo span {
  background: linear-gradient(135deg, #69e7d1 0%, #8bc9f0 58%, #b4b6ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
}
html[data-theme="light"] .nav-links a {
  color: color-mix(in srgb, var(--nav-accent, #087d72) 36%, #17383d);
  font-weight: 640;
  letter-spacing: 0;
  text-shadow: none;
}
html[data-theme="light"] .nav-links a::after {
  left: 50%;
  right: auto;
  bottom: .2rem;
  width: 3px;
  height: 3px;
  background: var(--nav-accent, #087d72);
  box-shadow: 0 0 5px color-mix(in srgb, var(--nav-accent, #087d72) 34%, transparent);
  transform: translateX(-50%) scale(.4);
}
html[data-theme="light"] .nav-links a:hover {
  color: color-mix(in srgb, var(--nav-accent, #087d72) 50%, #102f34);
  background: rgba(255, 255, 255, .22);
}
html[data-theme="light"] .nav-links a:hover::after { opacity: .7; transform: translateX(-50%) scale(1); }
html[data-theme="light"] .nav-links a[aria-current="location"] {
  color: color-mix(in srgb, var(--nav-accent, #087d72) 45%, #0b2b30);
  background: color-mix(in srgb, var(--nav-accent, #087d72) 4%, rgba(255, 255, 255, .3));
  text-shadow: none;
}
html[data-theme="light"] .nav-links a[aria-current="location"]::after { opacity: 1; transform: translateX(-50%) scale(1); }
html[data-theme="light"] .nav-cta,
html[data-theme="light"] .nav-cta:hover {
  color: #f7fffe;
  background: linear-gradient(135deg, #0a625c, #244d68);
  border: 1px solid rgba(255, 255, 255, .2);
  box-shadow: 0 8px 24px rgba(11, 72, 74, .2), inset 0 1px rgba(255, 255, 255, .13);
}
html[data-theme="light"] .theme-toggle,
html[data-theme="light"] .lang-dropdown-toggle {
  color: #17383d;
  background: rgba(255, 255, 255, .42);
  border-color: rgba(17, 68, 74, .18);
  box-shadow: inset 0 1px rgba(255, 255, 255, .55);
}
html[data-theme="light"] .lang-dropdown-menu { background: rgba(245, 249, 248, .98); }
html[data-theme="light"] .hamburger span { background: #17383d; }

html[data-theme="light"] #hero .btn-ghost {
  color: #17383d;
  background: rgba(247, 251, 250, .68);
  border-color: rgba(19, 67, 72, .28);
  box-shadow: 0 8px 22px rgba(18, 59, 65, .08);
}
html[data-theme="light"] #hero .btn-ghost:hover {
  color: #075f58;
  background: rgba(239, 249, 247, .9);
  border-color: rgba(8, 125, 114, .48);
}
html[data-theme="light"] #hero .hero-social a {
  color: #294f54;
  background: rgba(247, 251, 250, .68);
  border-color: rgba(19, 67, 72, .25);
  box-shadow: 0 7px 18px rgba(18, 59, 65, .08);
}
html[data-theme="light"] #hero .hero-social a:hover {
  color: #087d72;
  background: rgba(239, 249, 247, .92);
  border-color: rgba(8, 125, 114, .48);
}

html[data-theme="light"] .hero-name .grad {
  background: linear-gradient(135deg, #315f9a 0%, #654ea3 52%, #a65a68 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

html[data-theme="light"] .mobile-chapter-nav summary,
html[data-theme="light"] .mobile-chapter-nav nav {
  color: #10202a;
  background: rgba(246, 255, 252, .94);
  border-color: rgba(13, 111, 103, .22);
  box-shadow: 0 14px 34px rgba(20, 82, 88, .16);
}

html[data-theme="light"] .mobile-chapter-nav nav a {
  color: #405b65;
}

html[data-theme="light"] :is(.section-h em, .gradient-text) {
  filter: saturate(1.12) contrast(1.08);
}

@media (max-width: 960px) {
  html[data-theme="light"] .nav-links.mobile-open {
    background: rgba(218, 235, 233, .98);
    border-bottom-color: rgba(17, 68, 74, .2);
    box-shadow: 0 18px 40px rgba(18, 59, 65, .16);
  }
  html[data-theme="light"] .nav-links.mobile-open > li > a {
    background: transparent;
    border: 0;
    border-bottom: 1px solid rgba(17, 68, 74, .1);
    border-radius: 0;
  }
  html[data-theme="light"] .nav-links.mobile-open > li > a[aria-current="location"] {
    background: rgba(255, 255, 255, .3);
  }
}

html[data-theme="light"] :is(
  #about, #experience, #a2sv, #products, #skills, #education,
  #awards, #personal, #gallery, #blog
) {
  background: linear-gradient(155deg, rgba(248, 251, 250, .95), rgba(218, 235, 233, .89)) !important;
  border-top-color: rgba(24, 74, 79, .17);
  box-shadow: inset 0 1px rgba(255, 255, 255, .82);
}

/* Let the fixed solar system remain visible in wide-screen side gutters. */
@media (min-width: 1200px) {
  html[data-theme="light"] :is(
    #about, #experience, #a2sv, #products, #skills, #education,
    #awards, #personal, #gallery, #blog
  ) {
    background: linear-gradient(90deg,
      rgba(105, 153, 158, .4) 0%,
      rgba(184, 214, 212, .64) 8%,
      rgba(246, 250, 249, .95) 15%,
      rgba(229, 241, 239, .93) 85%,
      rgba(182, 212, 211, .64) 92%,
      rgba(101, 147, 154, .42) 100%) !important;
  }
}

html[data-theme="light"] #about { border-top-color: rgba(23, 111, 104, .2); }
html[data-theme="light"] #experience { border-top-color: rgba(87, 100, 105, .18); }
html[data-theme="light"] #a2sv { border-top-color: rgba(53, 103, 133, .22); }
html[data-theme="light"] #products { border-top-color: rgba(152, 85, 104, .18); }
html[data-theme="light"] #skills { border-top-color: rgba(69, 112, 116, .18); }
html[data-theme="light"] #education { border-top-color: rgba(132, 99, 38, .18); }
html[data-theme="light"] #awards { border-top-color: rgba(112, 79, 102, .16); }
html[data-theme="light"] #gallery { border-top-color: rgba(82, 100, 138, .18); }
html[data-theme="light"] #blog { border-top-color: rgba(91, 108, 92, .18); }

html[data-theme="light"] :is(.tl-card, .a2sv-mini, .skill-card, .edu-card, .award-item, .gallery-story, .blog-card) {
  background-color: rgba(255, 255, 255, .9);
  border-color: rgba(24, 74, 79, .22);
  box-shadow: 0 15px 38px rgba(18, 59, 65, .13), inset 0 1px rgba(255, 255, 255, .9);
}

html[data-theme="light"] :is(.section-sub, .about-copy p, .tl-bullets, .blog-excerpt) {
  color: #34575d;
}

html[data-theme="light"] #contact {
  background:
    radial-gradient(circle at 18% 70%, rgba(46, 112, 151, .13), transparent 34%),
    radial-gradient(circle at 82% 28%, rgba(8, 125, 114, .12), transparent 32%),
    linear-gradient(180deg, #d8e9e6, #bdd6d5 58%, #9fbdc0) !important;
  border-top-color: rgba(23, 111, 104, .2);
}
html[data-theme="light"] #contact::after {
  background: linear-gradient(180deg, rgba(239, 247, 246, .52), rgba(197, 216, 217, .12) 48%, rgba(91, 119, 124, .24));
}
html[data-theme="light"] .contact-galaxy-art {
  opacity: .7;
  mix-blend-mode: multiply;
  filter: saturate(.92) contrast(1.18) brightness(.94);
}
html[data-theme="light"] .contact-form {
  background: linear-gradient(155deg, rgba(249, 252, 251, .88), rgba(230, 239, 239, .78));
  border-color: rgba(32, 66, 70, .18);
  box-shadow: 0 26px 70px rgba(24, 55, 61, .13);
}
html[data-theme="light"] .contact-form::before {
  background: linear-gradient(90deg, transparent, #176f68, #315f78, transparent);
  box-shadow: 0 0 18px rgba(23, 111, 104, .14);
}
html[data-theme="light"] .contact-signal { color: #6f612f; }
html[data-theme="light"] .contact-signal::before {
  background: #7f7136;
  box-shadow: 0 0 9px rgba(127, 113, 54, .32);
}
html[data-theme="light"] .contact-submit,
html[data-theme="light"] .contact-submit:hover:not(:disabled) {
  color: #f7fffe;
  background: linear-gradient(135deg, #176f68, #315f78);
  box-shadow: 0 10px 26px rgba(23, 111, 104, .14);
}

@media (prefers-reduced-motion: reduce) {
  html[data-theme="light"] .motion-field,
  html[data-theme="light"] #particles { opacity: .4; }
}
