:root {
  color: #182747;
  background: #f1f5fb;
  font-family: "Microsoft YaHei UI", "PingFang SC", "Noto Sans CJK SC", sans-serif;
  line-height: 1.55;
  --ink: #182747;
  --muted: #505e75;
  --violet: #124bc0;
  --line: #e0e8f4;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input { font: inherit; }
button, a { touch-action: manipulation; }
a { color: var(--violet); }
[hidden] { display: none !important; }
.wrap { max-width: 1312px; margin-inline: auto; padding-inline: 28px; }
.bar { background: white; border-bottom: 1px solid var(--line); }
.masthead { min-height: 72px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 22px; }
.brand { display: inline-flex; width: max-content; align-items: center; gap: 10px; color: var(--ink); font-size: 1.14rem; font-weight: 850; text-decoration: none; }
.logo { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: #1451d0; color: white; }
.main-nav { display: flex; align-self: stretch; gap: clamp(16px, 4vw, 46px); }
.main-nav :is(a, button) { display: grid; place-items: center; position: relative; min-height: 45px; padding: 0; border: 0; background: transparent; white-space: nowrap; color: var(--muted); font-weight: 700; text-decoration: none; cursor: pointer; }
.main-nav [aria-current] { color: var(--violet); }
.main-nav [aria-current]::after { content: ""; position: absolute; bottom: 11px; width: 24px; height: 3px; border-radius: 3px; background: #2464e5; }
.mast-label { justify-self: end; font-size: .9rem; font-weight: 750; text-decoration: none; }
.intro { padding-block: 26px 30px; }
.hero { overflow: hidden; isolation: isolate; position: relative; display: grid; grid-template-columns: 1.2fr 1fr; align-items: center; min-height: clamp(300px, 34vw, 415px); border-radius: 19px; color: white; background: radial-gradient(ellipse at 76% 45%, #254fa5 0%, transparent 56%), linear-gradient(120deg, #0b1c50 0%, #163878 72%, #19275e 100%); }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; opacity: .36; background-image: radial-gradient(#8eb7ff 1px, transparent 1px); background-size: 24px 24px; mask-image: linear-gradient(102deg, transparent 30%, black 96%); }
.hero-copy { padding: 40px 0 40px clamp(28px, 5vw, 72px); z-index: 1; }
.hero h1 { font-size: clamp(2.35rem, 5.4vw, 5rem); line-height: 1.13; letter-spacing: -.045em; margin: 0; }
.lede { color: #e0ebff; font-size: clamp(1rem, 1.7vw, 1.2rem); margin: 18px 0 23px; }
.hero-link { display: inline-flex; align-items: center; min-height: 44px; border-radius: 8px; padding: 0 17px; background: white; color: #1e438e; font-weight: 800; text-decoration: none; }
.hero-link:hover { background: #e3edff; }
.art { position: relative; align-self: stretch; }
.orbit { position: absolute; width: 68%; aspect-ratio: 1; border: 1px solid #7cacff66; border-radius: 50%; top: 50%; left: 50%; transform: translate(-50%, -50%); box-shadow: inset 0 0 70px #528aff40, 0 0 42px #528aff35; }
.orbit::after { content: ""; position: absolute; inset: 13%; border: 1px dashed #9dbdff88; border-radius: inherit; }
.cat, .butterfly { position: absolute; object-fit: contain; filter: drop-shadow(0 12px 5px #10245268); }
.cat { height: 41%; left: 20%; bottom: 13%; transform: rotate(-8deg); }
.butterfly { height: 24%; right: 12%; top: 23%; transform: rotate(14deg); }
.spark { position: absolute; color: #cae0ff; font-size: 1.7rem; }
.spark.one { top: 19%; left: 13%; }.spark.two { bottom: 18%; right: 17%; }
.art-block { position: absolute; z-index: 1; padding: 6px 13px; border-radius: 7px; font-size: clamp(.83rem, 1.35vw, 1rem); font-weight: 800; box-shadow: 0 4px 0 #0b1b4a50; }
.first { top: 25%; left: 26%; background: #ffcb5c; color: #4c2d00; transform: rotate(-9deg); }
.second { top: 40%; left: 38%; background: #1481ed; color: white; transform: rotate(6deg); }
.lesson { margin-top: 24px; scroll-margin-top: 18px; padding: clamp(18px, 3vw, 34px); display: grid; grid-template-columns: minmax(125px, .78fr) minmax(0, 2.5fr) minmax(180px, 1.12fr); gap: clamp(18px, 3vw, 36px); border: 1px solid var(--line); border-radius: 17px; background: white; box-shadow: 0 6px 24px #1837650b; }
.lesson h2 { margin: 0 0 12px; font-size: 1.3rem; }
.task-list h2 { font-size: 1rem; }
.task-list button { display: flex; align-items: center; gap: 9px; padding: 8px; width: 100%; margin-bottom: 8px; border: 1px solid var(--line); border-radius: 9px; text-align: left; color: var(--ink); background: #f6f8fc; cursor: pointer; font-weight: 700; font-size: .9rem; }
.task-list button [aria-hidden] { width: 28px; height: 28px; flex-shrink: 0; display: grid; place-items: center; border-radius: 7px; color: #184cba; background: #e3edff; }
.task-list button[aria-pressed="true"] { border-color: #2762da; background: #eef4ff; box-shadow: inset 0 0 0 1px #2762da; color: #1244aa; }
.lesson-stage { position: relative; isolation: isolate; overflow: hidden; width: 100%; min-height: 170px; aspect-ratio: 2.1; border-radius: 11px; background: linear-gradient(#aff0ff 5%, #d3f8ff 63%, #cdea9a 63%); }
.lesson-stage::before { content: ""; position: absolute; top: 12%; right: 13%; width: 15%; aspect-ratio: 1; border-radius: 50%; background: #fff6ad; }
.stage-hill { position: absolute; inset: 52% -7% -40%; border-radius: 50% 65% 0 0; background: #8acb78; transform: rotate(-6deg); }
.stage-path { position: absolute; inset: 74% -8% -38%; border-radius: 50%; background: #f6dfad; transform: rotate(-5deg); }
.stage-cat, .stage-butterfly { position: absolute; object-fit: contain; }
.stage-cat { left: 22%; bottom: 17%; height: 53%; }.stage-butterfly { right: 19%; top: 35%; height: 30%; }
.eyebrow { color: var(--violet); font-size: .88rem; font-weight: 800; margin: 0 0 7px; }
.lesson-copy h3 { margin: 0 0 8px; font-size: 1.08rem; }
.lesson-copy p:not(.eyebrow) { margin: 0 0 16px; color: var(--muted); }
.primary, .secondary, .plain { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; border-radius: 9px; padding: 8px 15px; font-weight: 750; cursor: pointer; }
.primary { border: 1px solid #1957cc; color: white; background: #1957cc; }.primary:hover { background: #1046aa; }
.secondary { border: 1px solid #c4d6f5; color: var(--violet); background: white; }.secondary:hover { background: #edf4ff; }
.plain { padding-inline: 0; border: 0; color: var(--violet); background: none; }
:is(a, button, summary):focus-visible { outline: 3px solid #4b78e1; outline-offset: 3px; }
.studio { max-width: 1640px; padding-top: 12px; }
.studio-heading { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 14px; }
.studio-heading h1 { font-size: clamp(1.35rem, 3vw, 2rem); margin: 0; }
.workbench { display: flex; gap: 12px; align-items: stretch; }
.tips { flex: 0 0 235px; background: white; border: 1px solid var(--line); border-radius: 15px; padding: 16px; min-width: 0; }
.tips h2, .save-help h3 { margin: 0 0 8px; font-size: 1.08rem; }
.tips .status { background: #eef4ff; border-radius: 9px; padding: 9px; margin: 0 0 12px; font-size: .88rem; color: var(--muted); }
.tips details { border-bottom: 1px solid var(--line); padding: 10px 0; }
.tips summary { font-weight: 700; cursor: pointer; }
.tips details p, .save-help p { color: var(--muted); font-size: .9rem; margin: 7px 0; }
.save-help { margin-top: 16px; }.save-help a { font-size: .88rem; }
.editor-shell { flex: 1; min-width: 0; overflow: auto; background: white; border: 1px solid var(--line); border-radius: 15px; }
.editor-shell iframe { display: block; width: 100%; min-width: 750px; height: max(640px, calc(100vh - 185px)); border: 0; }
.footer { display: flex; justify-content: space-between; gap: 16px; padding-block: 14px 24px; color: var(--muted); font-size: .92rem; }
.footer a { color: inherit; }.credits { padding-block: 36px; max-width: 780px; }.credits a { overflow-wrap: anywhere; }
@media (max-width: 850px) {
  .workbench { flex-direction: column; }.tips { flex: auto; }.editor-shell iframe { height: 650px; }
  .lesson { grid-template-columns: minmax(125px, .7fr) minmax(0, 1.8fr); }
  .lesson-copy { grid-column: 2; }
}
@media (max-width: 610px) {
  .wrap { padding-inline: 16px; }
  .masthead { grid-template-columns: 1fr auto; gap: 0 10px; padding-top: 12px; }
  .main-nav { grid-row: 2; grid-column: 1 / -1; gap: 25px; order: 3; }
  .main-nav [aria-current]::after { bottom: 4px; }
  .mast-label { font-size: .83rem; }
  .intro { padding-top: 15px; }.hero { grid-template-columns: 1fr; }
  .hero-copy { padding: 26px 22px 6px; }.lede { margin: 12px 0 16px; }.art { min-height: 167px; }
  .orbit { width: 48%; }.cat { height: 55%; left: 25%; }.butterfly { height: 36%; right: 18%; }
  .first { top: 12%; left: 28%; }.second { top: 34%; left: 43%; }
  .lesson { grid-template-columns: 1fr; gap: 12px; }.lesson-copy { grid-column: auto; }
  .task-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .task-list h2 { grid-column: 1 / -1; margin-bottom: 3px; }
  .task-list button { padding: 6px; gap: 5px; font-size: .84rem; }
  .task-list button [aria-hidden] { width: 20px; height: 24px; }
  .studio-heading .secondary { font-size: .88rem; }
}
