/* 首页主题颜色、背景与模块视觉覆盖。修改时保留页面中样式表的加载顺序。 */
:root {
  --ink: #1b3449;
  --blue: #29495f;
  --orange: #bd6038;
  --gold: #c59a42;
  --soft: #efede7;
  --line: #d5d1c8;
  --muted: #68747d;
}
body {
  background: #f8f7f3;
}
.announcement {
  background: #1b3449;
  color: #e5e2da;
}
.announcement span {
  color: #d2ad61;
}
.site-header {
  background: rgba(248, 247, 243, 0.98);
  border-bottom-color: #d8d4cb;
}
.button {
  background: #bd6038;
}
.button:hover {
  background: #a9512d;
}
.hero {
  background: linear-gradient(125deg, #e9e5dc 0%, #f4f1ea 64%, #ded6c5 100%);
  color: var(--ink);
}
.hero:after {
  border-color: rgba(176, 139, 66, 0.1);
}
.hero-lead {
  color: #596b77;
}
.hero .eyebrow {
  color: #9f512f;
}
.hero .text-link {
  color: var(--ink);
  border-bottom-color: #7b8992;
}
.problem-card {
  background: #faf9f5;
  box-shadow: 14px 14px 0 #b08a43;
  border-color: #cfc8ba;
}
.problem-note {
  background: #29495f;
  color: #f7f5ef;
}
.stats,
.programs,
.bookstore {
  background: #f8f7f3;
}
.stats,
.stats div {
  border-color: #d9d5cc;
}
.method,
.stories {
  background: #eceae4;
}
.method-panel {
  background: #29495f;
}
.trial {
  background: #e5e1d8;
}
.trial-points span {
  background: #d8d2c6;
}
.trial-form,
.book-card,
.program-card,
.story-grid blockquote {
  background: #faf9f5;
  border-color: #d5d1c8;
}
.site-footer {
  background: #eceae4;
  border-top-color: #bd6038;
}
.book-cover {
  box-shadow: 6px 6px 0 #d8d1c3;
}
.info-card {
  border-top-color: #bd6038;
}
.page-cta {
  background: #e5e1d8;
}
@media (max-width: 620px) {
  .problem-card {
    box-shadow: 8px 8px 0 #b08a43;
  }
}
.press-feature {
  max-width: 1120px;
  margin: 0 auto;
  padding: 75px 28px;
  text-align: center;
}
.press-feature > div {
  max-width: 740px;
  margin: auto;
}
.press-feature h2 {
  margin: 10px 0;
  font: 800 clamp(30px, 4vw, 44px) / 1.15 Manrope;
}
.press-feature p:not(.kicker) {
  max-width: 660px;
  margin: 20px auto;
  color: #68747d;
  line-height: 1.7;
}
.press-feature .button {
  display: inline-block;
  margin-top: 10px;
}
@media (max-width: 700px) {
  .press-feature {
    padding: 55px 23px;
  }
}
.v2-system,
.v2-programs {
  max-width: 1180px;
  margin: auto;
  padding: 78px 28px;
}
.v2-system {
  border-top: 1px solid #d6d1c7;
}
.v2-heading {
  max-width: 780px;
  margin-bottom: 36px;
}
.v2-heading h2 {
  margin: 9px 0;
  font: 800 clamp(34px, 4vw, 50px) / 1.08 Manrope;
}
.v2-heading > p:last-child {
  color: #68747d;
  line-height: 1.7;
}
.v2-five {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin-bottom: 28px;
}
.v2-five article {
  padding: 23px 18px;
  border: 1px solid #d5d1c8;
  border-right: 0;
}
.v2-five article:last-child {
  border-right: 1px solid #d5d1c8;
}
.v2-five b,
.v2-program-grid span {
  color: #a45130;
  font-size: 0.875rem;
}
.v2-five h3 {
  margin: 13px 0 5px;
  font: 800 19px Manrope;
}
.v2-five strong {
  font-size: 0.875rem;
}
.v2-five p {
  color: #68747d;
  font-size: 0.875rem;
  line-height: 1.6;
}
.v2-programs {
  max-width: none;
  padding-left: max(calc((100vw - var(--max)) / 2), 28px);
  padding-right: max(calc((100vw - var(--max)) / 2), 28px);
  background: #e9e5dc;
}
.v2-program-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.v2-program-grid a {
  padding: 27px;
  background: #faf9f5;
  border-top: 4px solid #b08b42;
}
.v2-program-grid h3 {
  font: 750 20px Manrope;
}
.v2-program-grid p {
  min-height: 65px;
  color: #68747d;
  font-size: 1rem;
  line-height: 1.6;
}
.v2-program-grid b {
  color: #9f512f;
  font-size: 0.875rem;
}
@media (max-width: 850px) {
  .v2-five {
    grid-template-columns: 1fr;
  }
  .v2-five article {
    border-right: 1px solid #d5d1c8;
    border-bottom: 0;
  }
  .v2-five article:last-child {
    border-bottom: 1px solid #d5d1c8;
  }
  .v2-program-grid {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 550px) {
  .v2-program-grid {
    grid-template-columns: 1fr;
  }
  .v2-system,
  .v2-programs {
    padding-top: 55px;
    padding-bottom: 55px;
  }
}

/* V2 follows document order; legacy section order values caused new blocks to jump above the hero. */
main > * {
  order: initial !important;
}
html,
body {
  max-width: 100%;
  overflow-x: clip;
}
.site-header {
  gap: 14px;
}
.main-nav {
  gap: 15px;
}
.main-nav a {
  white-space: nowrap;
}
.hero h1 {
  font-size: clamp(44px, 4.3vw, 60px);
}
@media (max-width: 1500px) {
  .site-header {
    padding-left: 22px;
    padding-right: 22px;
  }
  .header-cta {
    display: none;
  }
}
@media (max-width: 1100px) {
  .site-header .menu-toggle {
    display: block;
  }
  .site-header .header-cta {
    display: none;
  }
  .site-header .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 10px 22px 18px;
    background: #f8f7f3;
    border-bottom: 1px solid #d8d4cb;
    box-shadow: 0 14px 24px #1b344912;
    transform: translateY(-140%);
    z-index: -1;
  }
  .site-header .main-nav.open {
    transform: none;
  }
  .site-header .main-nav a {
    width: 100%;
    padding: 10px 0;
    text-align: center;
    font-size: 0.875rem;
  }
  .hero {
    grid-template-columns: 1fr;
  }
  .hero-copy {
    max-width: 800px;
  }
  .hero-problem {
    width: min(520px, 100%);
    margin-top: 20px;
  }
}
@media (max-width: 620px) {
  .site-header .brand-logo {
    width: auto;
  }
  .site-header .login-button {
    margin-left: auto;
  }
  .hero h1 {
    font-size: clamp(36px, 10vw, 44px);
    letter-spacing: -2px;
  }
}
.v2-program-grid.general-program-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 700px) {
  .v2-program-grid.general-program-grid {
    grid-template-columns: 1fr;
  }
}

/* Subject cards use restrained curriculum colors and purposeful motion. */
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto 1fr auto;
  min-height: 286px;
  overflow: hidden;
  border: 1px solid var(--subject-border);
  border-top: 5px solid var(--subject-accent);
  background: linear-gradient(145deg, var(--subject-surface) 0%, #fff 72%);
  box-shadow: 0 14px 34px rgba(23, 50, 77, .08);
  transition: transform .32s ease, box-shadow .32s ease, border-color .32s ease;
  animation: subject-card-enter .58s cubic-bezier(.2, .75, .25, 1) both;
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 180px;
  height: 180px;
  top: -96px;
  right: -72px;
  border: 30px solid var(--subject-orbit);
  border-radius: 50%;
  transition: transform .45s ease;
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card-mathematics {
  --subject-accent: #2f6f99;
  --subject-border: #b9d2e1;
  --subject-surface: #e8f2f8;
  --subject-orbit: rgba(47, 111, 153, .10);
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card-science {
  --subject-accent: #52785f;
  --subject-border: #c2d5c7;
  --subject-surface: #edf4ed;
  --subject-orbit: rgba(82, 120, 95, .11);
  animation-delay: .1s;
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card > span {
  grid-row: auto;
  display: grid;
  place-items: center;
  box-sizing: border-box;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 50%;
  background: var(--subject-accent);
  color: #fff;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card h3 {
  margin-block: 24px 10px;
  color: #17324d;
  font-size: clamp(24px, 2.3vw, 31px);
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card p {
  min-height: 0;
  max-width: 34rem;
  color: #445b6d;
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card b {
  align-self: end;
  color: var(--subject-accent);
  font-size: .94rem;
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card b i {
  display: inline-block;
  margin-left: .3em;
  font-style: normal;
  transition: transform .28s ease;
}
body.playful-site.academic-site.home-page
  .v2-program-grid.general-program-grid > .subject-card:focus-visible {
  outline: 3px solid var(--subject-accent);
  outline-offset: 4px;
}
@media (hover: hover) and (pointer: fine) {
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card:hover {
    transform: translateY(-7px);
    border-color: var(--subject-accent);
    box-shadow: 0 22px 42px rgba(23, 50, 77, .16);
  }
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card:hover::after {
    transform: translate(-8px, 8px) scale(1.08);
  }
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card:hover b i {
    transform: translateX(6px);
  }
}
@keyframes subject-card-enter {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (max-width: 700px) {
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card {
    min-height: 0;
    padding: 22px;
    row-gap: 0;
  }
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card h3 {
    margin-block: 16px 12px;
    font-size: 24px;
  }
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card p {
    margin-block: 0 24px;
    font-size: 16px;
    line-height: 1.6;
  }
}
@media (prefers-reduced-motion: reduce) {
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card,
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card::after,
  body.playful-site.academic-site.home-page
    .v2-program-grid.general-program-grid > .subject-card b i {
    animation: none;
    transition: none;
  }
}
