:root {
  color-scheme: light;
  --ink: #24312f;
  --muted: #66726f;
  --paper: #fbfaf6;
  --soft: #eef5f2;
  --line: #dce4df;
  --green: #2f7d65;
  --coral: #d46b55;
  --gold: #c79b3b;
  --blue: #4477a8;
  --shadow: 0 24px 70px rgb(36 49 47 / 16%);
  --x: 50vw;
  --y: 20vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(circle at var(--x) var(--y), rgb(255 255 255 / 70%), transparent 19rem),
    var(--paper);
  color: var(--ink);
  margin: 0;
}

.apple-flow {
  background:
    radial-gradient(circle at var(--x) var(--y), rgb(255 255 255 / 72%), transparent 19rem),
    var(--paper);
  color: var(--ink);
}

.apple-flow .hero {
  background:
    radial-gradient(circle at 18% 28%, rgb(199 155 59 / 24%), transparent 24rem),
    linear-gradient(135deg, #f8f1e5 0%, #edf5f2 52%, #f7e8df 100%);
  color: var(--ink);
  position: relative;
}

.apple-flow .hero::after {
  background: linear-gradient(180deg, transparent, var(--paper));
  bottom: 0;
  content: "";
  height: 12vh;
  left: 0;
  position: absolute;
  right: 0;
}

.apple-flow nav,
.apple-flow .hero-grid {
  position: relative;
  z-index: 1;
}

.apple-flow nav a,
.apple-flow .identity-panel strong,
.apple-flow .lead {
  color: var(--ink);
}

.apple-flow .eyebrow {
  color: var(--green);
}

.apple-flow h1 {
  background: linear-gradient(100deg, var(--ink), var(--green), var(--coral), var(--ink));
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
}

.apple-flow .band,
.apple-flow .split,
.apple-flow .readiness,
.apple-flow .moments {
  color: var(--ink);
}

.apple-flow article,
.apple-flow details {
  background: #fff;
  border-color: var(--line);
  box-shadow: 0 16px 40px rgb(36 49 47 / 8%);
  color: var(--ink);
}

.apple-flow article.accent {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.apple-flow article p,
.apple-flow li,
.apple-flow details p {
  color: var(--muted);
}

.apple-flow article.accent li {
  color: rgb(255 255 255 / 86%);
}

.cinema-scroll {
  background:
    linear-gradient(90deg, rgb(68 119 168 / 8%), transparent 34%),
    linear-gradient(135deg, #fffaf2, #f0f7f3);
  color: var(--ink);
  display: grid;
  gap: 4vw;
  grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
  min-height: 230vh;
  padding: 8vh max(22px, calc((100vw - 1180px) / 2)) 12vh;
}

.cinema-stage {
  height: 100vh;
  position: sticky;
  top: 0;
}

.cinema-stage::before {
  background:
    radial-gradient(circle at 50% 42%, rgb(47 125 101 / 18%), transparent 22rem),
    radial-gradient(circle at 62% 58%, rgb(212 107 85 / 14%), transparent 18rem);
  content: "";
  filter: blur(4px);
  inset: 8vh 0;
  position: absolute;
}

.cinema-frame,
.cinema-orbit {
  border: 10px solid rgb(255 255 255 / 82%);
  box-shadow: var(--shadow);
  margin: 0;
  overflow: hidden;
  position: absolute;
  transition: transform 700ms cubic-bezier(0.2, 0.8, 0.2, 1), opacity 700ms ease, filter 700ms ease;
}

.cinema-frame {
  aspect-ratio: 4 / 5;
  border-radius: 28px;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(1);
  width: min(52vw, 480px);
}

.cinema-frame img,
.cinema-orbit img {
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.cinema-orbit {
  border-radius: 18px;
  opacity: 0.74;
  width: min(24vw, 220px);
}

.cinema-orbit-one {
  aspect-ratio: 3 / 2;
  right: 4%;
  top: 22%;
  transform: translate3d(0, 0, 0) rotate(4deg);
}

.cinema-orbit-two {
  aspect-ratio: 2 / 3;
  bottom: 18%;
  left: 2%;
  transform: translate3d(0, 0, 0) rotate(-5deg);
}

.cinema-stage[data-scene="1"] .cinema-frame {
  transform: translate(-50%, -50%) scale(1.08) rotate(-1deg);
}

.cinema-stage[data-scene="1"] .cinema-orbit-one {
  opacity: 1;
  transform: translate3d(-22px, 22px, 0) rotate(-2deg) scale(1.08);
}

.cinema-stage[data-scene="1"] .cinema-orbit-two {
  opacity: 0.38;
  transform: translate3d(-26px, -10px, 0) rotate(-9deg) scale(0.9);
}

.cinema-stage[data-scene="2"] .cinema-frame {
  filter: saturate(1.05) contrast(1.04);
  transform: translate(-50%, -50%) scale(0.96) rotate(1deg);
}

.cinema-stage[data-scene="2"] .cinema-orbit-one {
  opacity: 0.3;
  transform: translate3d(34px, -18px, 0) rotate(8deg) scale(0.86);
}

.cinema-stage[data-scene="2"] .cinema-orbit-two {
  opacity: 1;
  transform: translate3d(32px, -24px, 0) rotate(1deg) scale(1.12);
}

.cinema-copy {
  display: grid;
  gap: 46vh;
  padding: 28vh 0 36vh;
  position: relative;
  z-index: 1;
}

.cinema-copy article {
  background: transparent;
  border: 0;
  box-shadow: none;
  min-height: auto;
  opacity: 0.42;
  padding: 0;
  transform: none;
}

.cinema-copy article.active {
  opacity: 1;
}

.cinema-copy h2 {
  font-size: clamp(44px, 6vw, 88px);
  letter-spacing: 0;
}

.cinema-copy p:last-child {
  color: var(--muted);
  font-size: clamp(18px, 2vw, 24px);
  line-height: 1.45;
}

.scroll-progress {
  background: linear-gradient(90deg, var(--coral), var(--gold), var(--green), var(--blue));
  height: 5px;
  left: 0;
  position: fixed;
  right: 0;
  top: 0;
  transform: scaleX(0);
  transform-origin: left;
  z-index: 10;
}

nav {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin: 0 auto;
  max-width: 1120px;
  padding: 22px;
}

nav a {
  border-radius: 999px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  padding: 9px 12px;
  text-decoration: none;
  transition: background 180ms ease, box-shadow 180ms ease, color 180ms ease, transform 180ms ease;
}

nav a:hover {
  background: rgb(255 255 255 / 64%);
  box-shadow: 0 10px 28px rgb(36 49 47 / 10%);
  transform: translateY(-2px);
}

.language-switcher {
  background: rgb(255 255 255 / 58%);
  border: 1px solid rgb(255 255 255 / 78%);
  border-radius: 999px;
  display: flex;
  gap: 4px;
  padding: 4px;
}

.language-switcher button {
  background: transparent;
  color: var(--ink);
  font-size: 12px;
  min-width: 34px;
  padding: 7px 9px;
}

.language-switcher button.active {
  background: var(--green);
  color: #fff;
}

.hero {
  background:
    radial-gradient(circle at 18% 28%, rgb(199 155 59 / 24%), transparent 24rem),
    linear-gradient(135deg, #f8f1e5 0%, #edf5f2 52%, #f7e8df 100%);
  min-height: 92vh;
  overflow: hidden;
}

.hero-grid,
.band,
.split,
.readiness {
  margin: 0 auto;
  max-width: 1120px;
  padding: 64px 22px;
}

.hero-grid {
  align-items: center;
  display: grid;
  gap: 44px;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 1.05fr);
  min-height: calc(92vh - 76px);
}

.intro,
.photo-stage,
article,
.timeline li {
  animation: rise 780ms ease both;
}

.eyebrow {
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  margin: 0 0 12px;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  background: linear-gradient(100deg, var(--ink), var(--green), var(--coral), var(--ink));
  background-size: 240% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: name-shimmer 6s ease-in-out infinite;
  font-size: clamp(76px, 13vw, 170px);
  line-height: 0.86;
  margin-bottom: 22px;
}

:lang(zh-CN) h1,
:lang(zh-HK) h1 {
  font-size: clamp(68px, 10vw, 118px);
  line-height: 1;
}

h2 {
  font-size: clamp(34px, 5vw, 68px);
  line-height: 0.98;
  margin-bottom: 18px;
}

h3 {
  color: var(--green);
  font-size: 20px;
  margin-bottom: 14px;
}

.lead {
  color: #3d4a47;
  font-size: clamp(21px, 2.5vw, 30px);
  line-height: 1.35;
  max-width: 650px;
}

.identity-panel {
  border-top: 1px solid rgb(36 49 47 / 18%);
  display: grid;
  gap: 18px 28px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 34px;
  max-width: 620px;
  padding-top: 22px;
}

.identity-panel div {
  display: grid;
  gap: 5px;
}

.identity-panel span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.identity-panel strong {
  color: var(--ink);
  font-size: 15px;
  line-height: 1.35;
}

.photo-stage {
  min-height: 560px;
  position: relative;
}

.photo {
  background: linear-gradient(135deg, #fdf7ed, #e0eee9);
  border: 10px solid rgb(255 255 255 / 82%);
  box-shadow: var(--shadow);
  margin: 0;
  overflow: hidden;
  position: absolute;
  transition: filter 240ms ease, transform 240ms ease;
}

.photo:hover {
  animation-play-state: paused;
  filter: saturate(1.08);
  transform: translate(-50%, -8px) rotate(1deg);
}

.photo img {
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.photo-button {
  background: transparent;
  border: 0;
  cursor: pointer;
  display: block;
  height: 100%;
  padding: 0;
  width: 100%;
}

.photo-placeholder {
  background:
    linear-gradient(135deg, rgb(47 125 101 / 22%), transparent 45%),
    linear-gradient(45deg, rgb(212 107 85 / 20%), transparent 50%),
    repeating-linear-gradient(135deg, rgb(255 255 255 / 28%) 0 14px, transparent 14px 28px),
    #f7eadc;
  height: 100%;
  width: 100%;
}

.photo-placeholder.activity {
  background:
    linear-gradient(135deg, rgb(68 119 168 / 24%), transparent 50%),
    linear-gradient(45deg, rgb(199 155 59 / 25%), transparent 48%),
    repeating-linear-gradient(45deg, rgb(255 255 255 / 30%) 0 12px, transparent 12px 24px),
    #e8f1ed;
}

.photo figcaption {
  background: rgb(255 255 255 / 84%);
  bottom: 12px;
  border-radius: 999px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  left: 12px;
  padding: 8px 11px;
  position: absolute;
}

.photo-main {
  animation: main-float 7s ease-in-out infinite;
  aspect-ratio: 4 / 5;
  border-radius: 8px;
  left: 50%;
  top: 18px;
  transform: translateX(-50%) rotate(1.5deg);
  width: min(72%, 390px);
  z-index: 2;
}

.photo-side {
  animation: side-float 6.5s ease-in-out infinite;
  aspect-ratio: 1;
  border-radius: 8px;
  bottom: 18px;
  left: 0;
  transform: rotate(-7deg);
  width: min(46%, 250px);
}

.learning-map {
  background: rgb(255 255 255 / 86%);
  border: 1px solid rgb(255 255 255 / 92%);
  border-radius: 8px;
  bottom: 24px;
  box-shadow: 0 18px 56px rgb(36 49 47 / 16%);
  display: grid;
  gap: 10px;
  padding: 16px;
  position: absolute;
  right: 0;
  width: 190px;
  z-index: 5;
}

.learning-map strong {
  color: var(--green);
  font-size: 11px;
  letter-spacing: 0;
  text-transform: uppercase;
}

.learning-map span {
  align-items: center;
  color: var(--ink);
  display: grid;
  font-size: 13px;
  font-weight: 900;
  gap: 8px;
  grid-template-columns: 9px 1fr;
}

.learning-map span::before {
  background: var(--coral);
  border-radius: 50%;
  content: "";
  height: 9px;
  width: 9px;
}

.learning-map span:nth-child(3)::before {
  background: var(--gold);
}

.learning-map span:nth-child(4)::before {
  background: var(--blue);
}

.learning-map span:nth-child(5)::before {
  background: var(--green);
}

.section-head {
  margin-bottom: 28px;
  max-width: 760px;
}

.section-head h2 {
  background: linear-gradient(100deg, var(--ink), var(--green), var(--coral));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.profile-grid,
.growth-grid,
.readiness-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

article {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgb(36 49 47 / 8%);
  min-height: 230px;
  padding: 24px;
  transform: translateY(18px);
  transition: border-color 220ms ease, box-shadow 220ms ease, transform 220ms ease;
}

article:hover {
  border-color: rgb(47 125 101 / 22%);
  box-shadow: 0 26px 70px rgb(36 49 47 / 14%);
  transform: translateY(-8px);
}

article.is-visible,
.section-head.is-visible,
.timeline li.is-visible,
details.is-visible {
  opacity: 1;
  transform: translateY(0);
}

article:nth-child(2) {
  animation-delay: 80ms;
}

article:nth-child(3) {
  animation-delay: 160ms;
}

article:nth-child(4) {
  animation-delay: 240ms;
}

article p,
li,
.timeline span {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

ul,
ol {
  margin: 0;
  padding-left: 20px;
}

.split {
  padding-top: 84px;
}

.readiness {
  background: #fff;
  max-width: none;
}

.readiness > * {
  margin-left: auto;
  margin-right: auto;
  max-width: 1120px;
}

.readiness-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.moments {
  background:
    linear-gradient(90deg, rgb(68 119 168 / 10%), transparent 34%),
    linear-gradient(135deg, #fffaf2, #f0f7f3);
  padding: 76px 22px;
}

.moments > * {
  margin-left: auto;
  margin-right: auto;
  max-width: 1120px;
}

.moment-feature {
  align-items: stretch;
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr;
}

.moment-gallery {
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(340px, 0.84fr) repeat(4, minmax(84px, 0.29fr));
  grid-template-rows: repeat(3, 170px);
  min-height: 534px;
}

.moment-cover {
  background: #fff;
  border: 10px solid rgb(255 255 255 / 88%);
  border-radius: 8px;
  box-shadow: var(--shadow);
  cursor: pointer;
  grid-column: 1;
  grid-row: 1 / 4;
  min-height: 0;
  overflow: hidden;
  padding: 0;
  position: relative;
  transition: box-shadow 240ms ease, transform 240ms ease, filter 240ms ease;
  z-index: 3;
}

.moment-cover:hover {
  box-shadow: 0 30px 86px rgb(36 49 47 / 20%);
  filter: saturate(1.06);
  transform: translateY(-8px) rotate(-0.5deg);
}

.moment-cover img {
  display: block;
  height: 100%;
  object-fit: cover;
  object-position: center 48%;
  transition: transform 520ms cubic-bezier(0.2, 0.8, 0.2, 1);
  width: 100%;
}

.moment-cover:hover img {
  transform: scale(1.045);
}

.moment-cover span {
  background: rgb(255 255 255 / 88%);
  border: 1px solid rgb(255 255 255 / 95%);
  border-radius: 999px;
  bottom: 16px;
  color: var(--ink);
  font-weight: 900;
  left: 16px;
  padding: 10px 14px;
  position: absolute;
}

.moment-thumbnails {
  display: contents;
}

.moment-mini {
  background: #fff;
  border: 6px solid rgb(255 255 255 / 88%);
  border-radius: 8px;
  box-shadow: 0 18px 54px rgb(36 49 47 / 14%);
  cursor: pointer;
  height: 100%;
  overflow: hidden;
  padding: 0;
  transition: transform 260ms ease, filter 260ms ease;
  width: 100%;
}

.moment-mini:nth-child(1) {
  grid-column: 2 / span 2;
  grid-row: 1;
}

.moment-mini:nth-child(2) {
  grid-column: 4 / span 2;
  grid-row: 1;
}

.moment-mini:nth-child(3) {
  grid-column: 2;
  grid-row: 2 / span 2;
}

.moment-mini:nth-child(4) {
  grid-column: 3 / span 2;
  grid-row: 2;
}

.moment-mini:nth-child(5) {
  grid-column: 3 / span 2;
  grid-row: 3;
}

.moment-mini:nth-child(6) {
  grid-column: 5;
  grid-row: 2 / span 2;
}

.moment-mini:hover {
  filter: saturate(1.08);
  transform: translateY(-5px);
}

.moment-mini img {
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.moment-mini:nth-child(3) img {
  object-position: 58% 50%;
}

.moment-mini:nth-child(4) img {
  object-position: 45% 54%;
}

.moment-mini:nth-child(5) img {
  object-position: center 44%;
}

.moment-mini:nth-child(6) img {
  object-position: 52% 56%;
}

.moment-strip {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.moment-note {
  min-height: auto;
}

.moment-note h3 {
  color: var(--green);
  margin-bottom: 12px;
}

.gallery-modal {
  background: rgb(36 49 47 / 46%);
  backdrop-filter: blur(14px);
  display: grid;
  inset: 0;
  padding: 24px;
  place-items: center;
  position: fixed;
  z-index: 20;
}

.gallery-modal[hidden] {
  display: none;
}

.gallery-shell {
  background:
    linear-gradient(180deg, rgb(255 255 255 / 86%), rgb(255 250 242 / 94%)),
    linear-gradient(135deg, #fffaf2, #eef7f3);
  border-radius: 8px;
  box-shadow: 0 30px 90px rgb(0 0 0 / 28%);
  max-width: 1040px;
  min-height: 680px;
  padding: 34px;
  position: relative;
  width: min(100%, 980px);
}

.gallery-close {
  height: 38px;
  padding: 0;
  pointer-events: auto;
  position: absolute;
  right: 18px;
  top: 18px;
  width: 38px;
  z-index: 3;
}

.coverflow {
  cursor: grab;
  height: 382px;
  overflow: hidden;
  perspective: 1100px;
  position: relative;
  touch-action: pan-y;
  user-select: none;
}

.coverflow.dragging {
  cursor: grabbing;
}

.cover-card {
  background:
    linear-gradient(135deg, rgb(255 255 255 / 72%), rgb(238 245 242 / 86%)),
    #fff;
  border: 8px solid #fff;
  border-radius: 8px;
  box-shadow: 0 26px 72px rgb(36 49 47 / 24%);
  height: 335px;
  left: 50%;
  margin: 0 -34px;
  opacity: var(--opacity);
  overflow: hidden;
  position: absolute;
  top: 20px;
  transform: translateX(calc(-50% + var(--shift))) rotateY(var(--turn)) scale(var(--scale));
  transition: box-shadow 220ms ease, transform 420ms cubic-bezier(0.2, 0.8, 0.2, 1), opacity 420ms ease, filter 420ms ease;
  width: 258px;
  z-index: var(--depth);
}

.cover-card[aria-hidden="true"] {
  pointer-events: none;
}

.cover-card img {
  height: 100%;
  object-fit: cover;
  transition: transform 360ms ease;
  width: 100%;
}

.cover-card:hover {
  box-shadow: 0 34px 86px rgb(36 49 47 / 28%);
}

.cover-card:hover img {
  transform: scale(1.035);
}

.gallery-copy {
  background: rgb(255 255 255 / 88%);
  border: 1px solid rgb(220 228 223 / 96%);
  border-radius: 8px;
  box-shadow: 0 18px 52px rgb(36 49 47 / 10%);
  margin: 0 auto;
  max-width: 720px;
  min-height: 178px;
  padding: 24px 28px;
  text-align: left;
}

.gallery-meta {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: space-between;
  margin-bottom: 10px;
}

.gallery-meta span {
  color: var(--green);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.gallery-copy h2 {
  color: var(--ink);
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.05;
  margin-bottom: 12px;
}

.gallery-copy p:last-child {
  color: var(--muted);
  line-height: 1.65;
  margin: 0;
}

.gallery-controls {
  align-items: center;
  display: flex;
  gap: 14px;
  justify-content: center;
  margin-top: 22px;
}

.gallery-controls button {
  height: 42px;
  padding: 0;
  width: 42px;
}

.gallery-slider {
  appearance: none;
  background: linear-gradient(90deg, var(--green), var(--gold));
  border: 1px solid rgb(220 228 223 / 80%);
  border-radius: 999px;
  cursor: pointer;
  height: 12px;
  max-width: 360px;
  padding: 0;
  width: min(42vw, 360px);
}

.gallery-slider::-webkit-slider-thumb {
  appearance: none;
  background: #fff;
  border: 4px solid var(--green);
  border-radius: 999px;
  box-shadow: 0 4px 14px rgb(36 49 47 / 22%);
  height: 26px;
  width: 26px;
}

.gallery-slider::-moz-range-thumb {
  background: #fff;
  border: 4px solid var(--green);
  border-radius: 999px;
  box-shadow: 0 4px 14px rgb(36 49 47 / 22%);
  height: 18px;
  width: 18px;
}

details {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 44px rgb(36 49 47 / 10%);
  min-height: 190px;
  padding: 22px;
  transform: translateY(18px);
  transition: border-color 220ms ease, transform 220ms ease, box-shadow 220ms ease;
}

details:hover {
  border-color: rgb(212 107 85 / 22%);
  box-shadow: var(--shadow);
  transform: translateY(-8px);
}

summary {
  cursor: pointer;
  font-size: 20px;
  font-weight: 900;
  list-style: none;
}

details p {
  color: var(--muted);
  line-height: 1.65;
  margin: 16px 0 0;
}

.growth-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.accent {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.accent h3 {
  color: #fff;
}

.accent li {
  color: rgb(255 255 255 / 82%);
}

.timeline-band {
  padding-bottom: 94px;
}

.private-band {
  border-top: 1px solid var(--line);
}

.login-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  margin: 0 auto;
  max-width: 620px;
  padding: 30px;
}

.login-panel label {
  display: block;
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 8px;
}

.login-row {
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr auto;
}

input,
button {
  border-radius: 8px;
  font: inherit;
}

input {
  border: 1px solid var(--line);
  min-width: 0;
  padding: 13px 14px;
}

button {
  background: var(--green);
  border: 0;
  color: #fff;
  cursor: pointer;
  font-weight: 900;
  padding: 13px 18px;
}

.photo .photo-button {
  background: transparent;
  border: 0;
  color: inherit;
  height: 100%;
  padding: 0;
  width: 100%;
}

.login-error {
  color: var(--coral);
  font-weight: 800;
  margin: 12px 0 0;
  min-height: 24px;
}

.logout {
  margin-top: 18px;
}

.timeline {
  display: grid;
  gap: 16px;
  list-style: none;
  padding: 0;
}

.timeline li {
  align-items: start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px 20px;
  grid-template-columns: 88px minmax(160px, 230px) 1fr;
  padding: 22px;
}

time {
  color: var(--coral);
  font-weight: 900;
}

strong {
  color: var(--ink);
}

.kg-dashboard {
  background:
    linear-gradient(135deg, rgb(255 255 255 / 86%), rgb(238 245 242 / 92%)),
    var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 22px 68px rgb(36 49 47 / 12%);
  margin-top: 24px;
  padding: 26px;
}

.kg-header {
  align-items: start;
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr auto;
}

.kg-header h3 {
  font-size: clamp(26px, 3vw, 38px);
  margin-bottom: 10px;
}

.kg-header p:last-child {
  color: var(--muted);
  line-height: 1.7;
  margin: 0;
  max-width: 760px;
}

.kg-source {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--green);
  font-size: 13px;
  font-weight: 900;
  padding: 10px 14px;
  text-decoration: none;
  white-space: nowrap;
}

.kg-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 24px 0;
}

.kg-toolbar button {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  font-size: 14px;
  padding: 10px 14px;
}

.kg-toolbar button.active,
.kg-toolbar button:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.kg-layout {
  align-items: start;
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.35fr);
}

.kg-list {
  display: grid;
  gap: 10px;
}

.kg-card {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  display: grid;
  gap: 6px;
  padding: 16px;
  text-align: left;
}

.kg-card span {
  color: var(--coral);
  font-size: 12px;
  font-weight: 900;
}

.kg-card strong {
  font-size: 18px;
}

.kg-card small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.kg-card.active,
.kg-card:hover {
  border-color: var(--green);
  box-shadow: 0 14px 34px rgb(36 49 47 / 12%);
  transform: translateY(-2px);
}

.kg-detail {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 100%;
  padding: 24px;
}

.kg-chip {
  background: rgb(47 125 101 / 10%);
  border-radius: 999px;
  color: var(--green);
  display: inline-flex;
  font-size: 13px;
  font-weight: 900;
  margin-bottom: 12px;
  padding: 8px 12px;
}

.kg-detail h4 {
  font-size: clamp(24px, 3vw, 34px);
  margin: 0 0 18px;
}

.kg-metrics {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 0 20px;
}

.kg-metrics div {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.kg-metrics dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 8px;
}

.kg-metrics dd {
  margin: 0;
}

.kg-score {
  display: flex;
  gap: 4px;
}

.kg-score i {
  background: #d9e1dc;
  border-radius: 999px;
  display: block;
  height: 8px;
  width: 22px;
}

.kg-score i.filled {
  background: linear-gradient(90deg, var(--green), var(--gold));
}

.kg-notes {
  display: grid;
  gap: 12px;
}

.kg-notes p {
  border-top: 1px solid var(--line);
  color: var(--muted);
  line-height: 1.65;
  margin: 0;
  padding-top: 12px;
}

.kg-notes b {
  color: var(--ink);
  display: block;
  margin-bottom: 3px;
}

.parent-page {
  background:
    radial-gradient(circle at 18% 0%, rgb(199 155 59 / 18%), transparent 24rem),
    linear-gradient(135deg, #f8f1e5 0%, #edf5f2 52%, #f7e8df 100%);
  color: var(--ink);
}

.parent-hero {
  min-height: 78vh;
  padding-bottom: 64px;
}

.parent-hero nav a {
  color: var(--ink);
}

.parent-login-card {
  margin: 12vh auto 0;
  max-width: 760px;
  padding: 0 22px;
}

.parent-login-card h1 {
  background: linear-gradient(100deg, var(--ink), var(--green), var(--coral), var(--ink));
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: clamp(60px, 12vw, 132px);
  line-height: 0.9;
}

.parent-login-card p {
  color: #3d4a47;
  font-size: clamp(20px, 3vw, 30px);
  line-height: 1.35;
}

.parent-login-card form {
  background: rgb(255 255 255 / 72%);
  border: 1px solid rgb(255 255 255 / 84%);
  border-radius: 8px;
  margin-top: 30px;
  padding: 22px;
}

.parent-login-card label {
  color: var(--ink);
  display: block;
  font-weight: 900;
  margin-bottom: 8px;
}

.parent-content {
  margin: 0 auto;
  max-width: 1340px;
  padding: 42px 22px 90px;
}

.parent-page.parent-unlocked .parent-hero {
  min-height: auto;
  padding-bottom: 0;
}

.parent-page.parent-unlocked .parent-login-card {
  display: none;
}

.parent-page.parent-unlocked .parent-content {
  padding-top: 12px;
}

.parent-page.parent-unlocked .kg-dashboard {
  padding: 16px;
}

.parent-page.parent-unlocked .kg-header {
  gap: 12px;
}

.parent-page.parent-unlocked .kg-header h2 {
  font-size: clamp(28px, 3.4vw, 46px);
  margin-bottom: 8px;
}

.parent-page.parent-unlocked .kg-header p:last-child {
  display: none;
}

.parent-page.parent-unlocked .kg-toolbar {
  margin: 14px 0 10px;
}

.parent-page.parent-unlocked .kg-toolbar button {
  padding: 8px 11px;
}

.deep-dashboard {
  background: rgb(255 255 255 / 82%);
  border-color: rgb(255 255 255 / 90%);
  box-shadow: 0 22px 70px rgb(36 49 47 / 12%);
}

.deep-dashboard h2,
.deep-dashboard h3,
.deep-dashboard strong,
.deep-dashboard b {
  color: var(--ink);
}

.deep-dashboard .kg-header p {
  color: var(--muted);
}

.school-workbench {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(620px, 1.08fr) minmax(390px, 0.92fr);
}

.admission-controls {
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) 220px;
  margin-top: 10px;
}

.admission-controls label {
  display: grid;
  gap: 8px;
}

.admission-controls span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.admission-controls input,
.admission-controls select {
  appearance: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font: inherit;
  min-height: 42px;
  padding: 0 14px;
}

.admission-controls input::placeholder {
  color: rgb(102 114 111 / 60%);
}

.admission-overview {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin: 12px 0;
}

.admission-overview div {
  background: linear-gradient(180deg, #fff, #f7fbf8);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 56px;
  padding: 9px;
}

.admission-overview b {
  color: var(--ink);
  display: block;
  font-size: clamp(20px, 2.4vw, 28px);
  line-height: 1;
}

.admission-overview span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.3;
  margin-top: 7px;
}

.school-list {
  display: grid;
  align-self: start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 42px rgb(36 49 47 / 8%);
  max-height: calc(100vh - 118px);
  overflow: auto;
}

.school-table-head,
.school-row {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(210px, 2fr) 92px 54px 54px 54px 66px;
}

.school-table-head {
  background: #f7fbf8;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  padding: 12px 14px;
  position: sticky;
  top: 0;
  z-index: 2;
}

.school-card.school-row {
  background: #fff;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  color: var(--ink);
  cursor: pointer;
  min-height: 74px;
  padding: 12px 14px;
  text-align: left;
  transition: background 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.school-name-cell {
  display: grid;
  gap: 4px;
}

.school-card:focus-visible {
  border-color: var(--green);
  box-shadow: 0 0 0 4px rgb(47 125 101 / 14%);
  outline: 0;
}

.school-name-cell strong {
  font-size: 15px;
  line-height: 1.3;
}

.school-name-cell small,
.school-row > span,
.detail-top a {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.detail-top a {
  color: var(--green);
  font-weight: 900;
}

.school-row > b {
  background: rgb(47 125 101 / 9%);
  border-radius: 999px;
  color: var(--green);
  font-size: 13px;
  justify-self: start;
  min-width: 42px;
  padding: 6px 8px;
  text-align: center;
}

.school-card.active,
.school-card:hover {
  background: rgb(47 125 101 / 7%);
  box-shadow: inset 4px 0 0 var(--green);
  transform: none;
}

.compare-toggle {
  background: rgb(47 125 101 / 8%);
  border: 1px solid rgb(47 125 101 / 16%);
  border-radius: 999px;
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  justify-self: end;
  margin: 0;
  min-height: 32px;
  padding: 0 10px;
}

.compare-toggle.active {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.compare-tray {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  margin-top: 14px;
  padding: 12px;
}

.compare-tray > p {
  color: var(--muted);
  margin: 0;
}

.compare-head {
  align-items: center;
  display: flex;
  justify-content: space-between;
  margin-bottom: 12px;
}

.compare-head button {
  background: rgb(47 125 101 / 8%);
  border: 1px solid rgb(47 125 101 / 16%);
  border-radius: 999px;
  color: var(--green);
  font-weight: 900;
  min-height: 34px;
  padding: 0 12px;
}

.compare-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.compare-grid article {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

.compare-grid h4 {
  color: var(--ink);
  margin: 8px 0 12px;
}

.compare-grid span {
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
}

.compare-grid dl {
  display: grid;
  gap: 6px;
  margin: 0 0 12px;
}

.compare-grid div {
  display: flex;
  justify-content: space-between;
}

.compare-grid dt,
.compare-grid p {
  color: var(--muted);
}

.compare-grid dd {
  color: var(--ink);
  font-weight: 900;
  margin: 0;
}

.compare-grid p {
  font-size: 12px;
  line-height: 1.55;
  margin: 8px 0 0;
}

.compare-grid b {
  display: block;
  margin-bottom: 2px;
}

.school-detail {
  animation: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 42px rgb(36 49 47 / 8%);
  min-height: 620px;
  max-height: calc(100vh - 118px);
  overflow: auto;
  padding: 26px;
  position: sticky;
  top: 18px;
  transform: none;
  opacity: 1;
}

.detail-top {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
}

.score-panel {
  display: grid;
  gap: 12px;
  margin: 22px 0;
}

.source-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.source-strip span {
  background: rgb(47 125 101 / 10%);
  border: 1px solid rgb(47 125 101 / 16%);
  border-radius: 999px;
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  padding: 8px 10px;
}

.decision-panel {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 18px;
}

.decision-panel div {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

.decision-panel b {
  display: block;
  margin-bottom: 5px;
}

.decision-panel span {
  color: var(--muted);
  line-height: 1.55;
}

.score-row {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: 90px 44px 1fr;
}

.score-row span {
  color: var(--muted);
  font-weight: 900;
}

.score-row b {
  font-size: 20px;
}

.score-row i {
  background: #d9e1dc;
  border-radius: 999px;
  display: block;
  height: 10px;
  overflow: hidden;
}

.score-row em {
  background: linear-gradient(90deg, var(--green), var(--gold));
  border-radius: inherit;
  display: block;
  height: 100%;
}

.evidence-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.evidence-grid p {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  line-height: 1.65;
  margin: 0;
  padding: 16px;
}

.evidence-grid b {
  display: block;
  margin-bottom: 4px;
}

@keyframes rise {
  from {
    opacity: 1;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes name-shimmer {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@keyframes main-float {
  0%,
  100% {
    transform: translateX(-50%) rotate(1.5deg) translateY(0);
  }
  50% {
    transform: translateX(-50%) rotate(0.5deg) translateY(-12px);
  }
}

@keyframes side-float {
  0%,
  100% {
    transform: rotate(-7deg) translateY(0);
  }
  50% {
    transform: rotate(-4deg) translateY(12px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    scroll-behavior: auto !important;
  }
}

@media (max-width: 880px) {
  nav {
    justify-content: flex-start;
    overflow-x: auto;
  }

  .hero-grid,
  .profile-grid,
  .growth-grid,
  .readiness-grid,
  .moment-strip,
  .moment-feature,
  .identity-panel,
  .cinema-scroll {
    grid-template-columns: 1fr;
  }

  .moment-gallery {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    min-height: auto;
  }

  .moment-cover {
    min-height: 390px;
  }

  .moment-thumbnails {
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 0;
  }

  .moment-mini,
  .moment-mini:nth-child(n) {
    grid-column: auto;
    grid-row: auto;
    height: 118px;
    width: 100%;
  }

  .moment-mini:hover {
    transform: translateY(-4px);
  }

  .cinema-scroll {
    min-height: auto;
  }

  .cinema-stage {
    height: 70vh;
    position: relative;
  }

  .cinema-copy {
    gap: 24px;
    padding: 0;
  }

  .cinema-copy article {
    opacity: 1;
  }

  .identity-panel div,
  .identity-panel div:nth-child(odd) {
    border-right: 0;
  }

  .hero-grid {
    padding-top: 32px;
  }

  .photo-stage {
    min-height: auto;
  }

  .learning-map {
    bottom: auto;
    margin: -28px auto 0;
    position: relative;
    right: auto;
    width: min(260px, 78%);
  }

  .photo-main {
    animation: none;
    left: auto;
    margin: 0 auto;
    position: relative;
    top: auto;
    transform: rotate(1deg);
  }

  .photo-main:hover {
    transform: translateY(-6px) rotate(1deg);
  }

  .timeline li {
    grid-template-columns: 1fr;
  }

  .kg-header,
  .kg-layout,
  .school-workbench {
    grid-template-columns: 1fr;
  }

  .school-list,
  .school-detail {
    max-height: none;
  }

  .school-detail {
    min-height: auto;
    order: -1;
    overflow: visible;
    position: static;
  }

  .school-table-head {
    display: none;
  }

  .school-card.school-row {
    border: 1px solid var(--line);
    border-radius: 8px;
    gap: 10px;
    grid-template-columns: 1fr repeat(3, 54px);
    margin: 0 0 10px;
    min-height: auto;
  }

  .school-list {
    background: #fff;
    border: 1px solid var(--line);
    box-shadow: 0 14px 34px rgb(36 49 47 / 8%);
    max-height: min(620px, 70vh);
    overflow: auto;
    padding: 8px;
  }

  .school-list::before {
    background: #fff;
    border-bottom: 1px solid var(--line);
    color: var(--green);
    content: "選擇學校";
    display: block;
    font-size: 13px;
    font-weight: 900;
    margin: -8px -8px 8px;
    padding: 12px 14px;
    position: sticky;
    top: 0;
    z-index: 2;
  }

  .school-name-cell,
  .school-row > span {
    grid-column: 1 / -1;
  }

  .school-row > b {
    justify-self: stretch;
  }

  .school-row > b::before {
    color: var(--muted);
    content: "總 ";
    font-size: 10px;
  }

  .school-row > b:nth-of-type(2)::before {
    content: "難 ";
  }

  .school-row > b:nth-of-type(3)::before {
    content: "配 ";
  }

  .compare-toggle {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .admission-controls,
  .compare-grid {
    grid-template-columns: 1fr;
  }

  .admission-overview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .kg-source {
    justify-self: start;
  }
}

@media (max-width: 560px) {
  .hero-grid,
  .band,
  .split,
  .moments {
    padding-left: 16px;
    padding-right: 16px;
  }

  h1 {
    font-size: 76px;
  }

  .lead {
    font-size: 20px;
  }

  .photo-stage {
    min-height: 390px;
  }

  .photo-main {
    width: 82%;
  }

  .moment-cover {
    min-height: 330px;
  }

  .moment-thumbnails {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .moment-mini,
  .moment-mini:nth-child(n) {
    height: 112px;
  }

  .photo-side {
    width: 48%;
  }

  .gallery-shell {
    min-height: 610px;
    padding: 18px;
  }

  .coverflow {
    height: 330px;
  }

  .cover-card {
    height: 290px;
    width: 225px;
  }

  .gallery-copy {
    padding: 18px;
  }

  .gallery-meta {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .gallery-slider {
    width: min(50vw, 260px);
  }

  .cinema-scroll {
    padding-left: 16px;
    padding-right: 16px;
  }

  .cinema-frame {
    width: min(74vw, 330px);
  }

  .cinema-orbit {
    width: min(34vw, 150px);
  }

  .login-row {
    grid-template-columns: 1fr;
  }

  .kg-dashboard {
    padding: 18px;
  }

  .kg-metrics {
    grid-template-columns: 1fr;
  }

  .parent-login-card {
    margin-top: 8vh;
  }

  .evidence-grid {
    grid-template-columns: 1fr;
  }

  .decision-panel {
    grid-template-columns: 1fr;
  }

  .admission-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .score-row {
    grid-template-columns: 76px 40px 1fr;
  }
}
