/* Knowledge Island UI skin
 * Visual language based on the Animal Island design system, adapted to the
 * existing static knowledge-graph app. All data and app behaviour stay in
 * their original files; this sheet is the presentation boundary.
 */

@font-face {
  font-family: "Nunito";
  src: url("fonts/nunito-latin-500.woff2") format("woff2");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Nunito";
  src: url("fonts/nunito-latin-700.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Nunito";
  src: url("fonts/nunito-latin-900.woff2") format("woff2");
  font-style: normal;
  font-weight: 900;
  font-display: swap;
}
@font-face {
  font-family: "Noto Sans SC";
  src: url("fonts/noto-sans-sc-400.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Noto Sans SC";
  src: url("fonts/noto-sans-sc-500.woff2") format("woff2");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Noto Sans SC";
  src: url("fonts/noto-sans-sc-700.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  color-scheme: light;
  --island-paper: #f8f8f0;
  --island-content: rgb(247, 243, 223);
  --island-card: #fffdf4;
  --island-card-solid: #f7f3df;
  --island-input: #fffbe7;
  --island-lemon: #fff0b9;
  --island-mint: #e6f9f6;
  --island-teal: #82d5bb;
  --island-blue: #e8edff;
  --island-coral: #fde5df;
  --island-purple: #f0e8ff;
  --island-ink: #794f27;
  --island-body: #725d42;
  --island-muted: #8a7b66;
  --island-faint: #9f927d;
  --island-line: #d8ccb8;
  --island-line-strong: #bdaea0;
  --island-primary: #19c8b9;
  --island-primary-hover: #3dd4c6;
  --island-primary-active: #11a89b;
  --island-primary-edge: #0f9d92;
  --island-success: #4b9b42;
  --island-success-bg: #e4f6e9;
  --island-warning: #b47a17;
  --island-warning-bg: #fff1c4;
  --island-error: #c9564b;
  --island-error-bg: #ffe8df;
  --island-focus: #ffcc00;
  --island-ease: cubic-bezier(.4, 0, .2, 1);
  --island-font: "Nunito", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --island-radius-sm: 14px;
  --island-radius: 20px;
  --island-radius-lg: 28px;
  --island-shadow-soft: 0 3px 10px rgba(61, 52, 40, .09);
  --island-shadow-lift: 0 8px 24px rgba(61, 52, 40, .12);

  --bg: var(--island-paper);
  --bg-elev: var(--island-card);
  --bg-muted: var(--island-content);
  --text: var(--island-ink);
  --muted: var(--island-muted);
  --line: var(--island-line);
  --brand: var(--island-primary);
  --brand-strong: #00897b;
  --brand-soft: var(--island-mint);
  --on-brand: #fffdf4;
  --junior: #6d82c7;
  --junior-soft: var(--island-blue);
  --focus: var(--island-focus);
  --shadow: var(--island-shadow-soft);
  --radius: var(--island-radius);
  --radius-sm: var(--island-radius-sm);
  --header-bg: rgba(248, 248, 240, .94);
  --font: var(--island-font);
  --fs: 16px;
  --ok: #3c8740;
  --ok-bg: var(--island-success-bg);
  --on-ok: #fff;
  --bad: var(--island-error);
  --bad-bg: var(--island-error-bg);
  --on-bad: #fff;
  --warn: var(--island-warning);
  --warn-bg: var(--island-warning-bg);
  --unk: #716c65;
  --unk-bg: #f0ece2;
  --accent: var(--island-primary);
  --panel: var(--island-card);
  --node-primary: #129f95;
  --node-primary-bg: #dff7f1;
  --node-junior: #6d82c7;
  --node-junior-bg: #e8edff;
  --node-senior: #a672ca;
  --node-senior-bg: #f2e9fa;
  --node-current-bg: #fff0b9;
  --node-current-border: #d69b18;
  --node-text: var(--island-ink);
  --edge: #88745e;
  --edge-soft: #b5a58f;
  --hard-bg: #fff1c4;
  --hard-fg: #8a5e10;
  --soft-bg: #e9eef7;
  --soft-fg: #58667a;
  --diagram-ok-bg: var(--island-success-bg);
  --diagram-ok: var(--island-success);
  --diagram-bad-bg: var(--island-error-bg);
  --diagram-bad: var(--island-error);
  --diagram-unk-bg: #f0ece2;
  --diagram-unk: #867a68;
  --diagram-shaky-bg: var(--island-warning-bg);
  --diagram-shaky: var(--island-warning);
  --diagram-text: var(--island-ink);
  --diagram-edge: #88745e;
}

body.subject-physics {
  --brand-strong: #966116;
  --junior: #b17825;
  --junior-soft: #fff1d6;
  --node-primary: #b27a26;
  --node-primary-bg: #fff1d1;
}

body.subject-english {
  --brand-strong: #5463a2;
  --junior: #7888c6;
  --junior-soft: #e8edff;
  --node-primary: #6979be;
  --node-primary-bg: #e8edff;
}

body.subject-chinese {
  --brand-strong: #a45368;
  --junior: #bf7085;
  --junior-soft: #fde9e9;
  --node-primary: #b35e75;
  --node-primary-bg: #fbe6e9;
}

html {
  background: var(--island-paper);
  font-family: var(--island-font);
}

body {
  min-width: 320px;
  overflow-x: hidden;
  color: var(--island-ink);
  background-color: var(--island-paper);
  background-image:
    radial-gradient(circle at 1px 1px, rgba(121, 79, 39, .10) 1.2px, transparent 1.3px),
    radial-gradient(circle at 11px 13px, rgba(25, 200, 185, .05) 1.3px, transparent 1.4px),
    linear-gradient(135deg, rgba(255, 253, 244, .80), rgba(248, 248, 240, .92));
  background-size: 24px 24px, 38px 38px, 100% 100%;
  font-family: var(--island-font);
  font-weight: 500;
  color-scheme: light;
}

h1, h2, h3, h4, strong, b, button, .btn, .nav-link, .section-title {
  font-family: var(--island-font);
}

h1, h2, .section-title {
  color: var(--island-ink);
  letter-spacing: -.028em;
}

p, li, dd, dt, label, .lede, .muted, .small {
  color: var(--island-body);
}

a {
  color: #00897b;
}

::selection {
  background: #ffeb99;
  color: var(--island-ink);
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 3px solid var(--island-focus);
  outline-offset: 2px;
}

.top-banner {
  min-height: 38px;
  gap: 8px;
  border-bottom: 1px solid rgba(121, 79, 39, .10);
  background: #fff0b9;
  color: var(--island-body);
  font-size: 13px;
  font-weight: 700;
}
.top-banner::before {
  content: "";
  width: 23px;
  height: 23px;
  flex: none;
  background: url("thiings/life-brain.png") center / contain no-repeat;
  filter: drop-shadow(0 2px 2px rgba(61, 52, 40, .12));
}
.top-banner .banner-emoji {
  display: none;
}
.top-banner:hover {
  background: #ffe58d;
  color: var(--island-ink);
}

.site-header {
  z-index: 32;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 28px;
  padding: 11px max(24px, calc((100vw - 1380px) / 2));
  border-bottom: 1px solid rgba(121, 79, 39, .12);
  background: rgba(248, 248, 240, .92);
  box-shadow: 0 2px 8px rgba(61, 52, 40, .04);
  backdrop-filter: blur(14px);
}

.header-left {
  display: flex;
  align-items: center;
  gap: clamp(24px, 3vw, 52px);
  min-width: 0;
}

.brand {
  gap: 10px;
  min-height: 52px;
}
.brand .logo {
  width: 47px;
  height: 47px;
  object-fit: contain;
  padding: 2px;
  border: 2px solid var(--island-line-strong);
  border-radius: 50%;
  background: #fff8dc;
  box-shadow: 0 3px 0 rgba(121, 79, 39, .14);
  filter: drop-shadow(0 3px 2px rgba(61, 52, 40, .08));
}
.brand-name {
  color: var(--island-ink);
  font-size: 20px;
  font-weight: 900;
  letter-spacing: -.025em;
}
.brand-kicker {
  color: #00897b;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .055em;
}

.site-nav {
  gap: 8px;
}
.subject-switch {
  gap: 2px;
  padding: 4px;
  border: 1.5px solid rgba(121, 79, 39, .12);
  border-radius: 50px;
  background: #f0e8d8;
}
.page-links {
  gap: 3px;
  padding: 3px;
  border: 1.5px solid rgba(121, 79, 39, .10);
  border-radius: 50px;
  background: rgba(255, 253, 244, .72);
}

.subject-menu {
  position: relative;
  z-index: 40;
  flex: none;
}
.subject-menu summary {
  min-width: 112px;
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 16px;
  border: 1.5px solid #88dacf;
  border-radius: 50px;
  background: var(--island-mint);
  color: #087e75;
  box-shadow: 0 3px 0 #c6e8df;
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
  list-style: none;
  transition: transform .2s var(--island-ease), background .2s var(--island-ease), box-shadow .2s var(--island-ease);
}
.subject-menu summary::-webkit-details-marker {
  display: none;
}
.subject-menu summary::after {
  content: "";
  width: 7px;
  height: 7px;
  margin-left: 2px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform .2s var(--island-ease);
}
.subject-menu summary:hover {
  background: #d9f7f1;
  transform: translateY(-1px);
}
.subject-menu[open] summary {
  background: #d9f7f1;
  box-shadow: 0 1px 0 #c6e8df;
}
.subject-menu[open] summary::after {
  transform: translateY(2px) rotate(225deg);
}
.subject-menu summary > span {
  color: var(--island-muted);
  font-size: 11px;
}
.subject-current {
  color: var(--island-ink);
  font-size: 14px;
  font-weight: 900;
}
.subject-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 188px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  padding: 10px;
  border: 1.5px solid var(--island-line);
  border-radius: 20px;
  background: rgba(255, 253, 244, .98);
  box-shadow: 0 14px 34px rgba(61, 52, 40, .16);
  backdrop-filter: blur(14px);
}
.subject-dropdown::before {
  content: "";
  position: absolute;
  right: 31px;
  top: -6px;
  width: 11px;
  height: 11px;
  border-left: 1.5px solid var(--island-line);
  border-top: 1.5px solid var(--island-line);
  background: var(--island-card);
  transform: rotate(45deg);
}
.subject-dropdown .subject-link {
  position: relative;
  z-index: 1;
  min-width: 0;
  min-height: 70px;
  flex-direction: column;
  gap: 3px;
  padding: 7px 5px;
  border: 1.5px solid transparent;
  border-radius: 15px;
  background: var(--subject-bg, #f4efe4);
  color: var(--island-body);
  font-size: 12px;
}
.subject-dropdown .subject-link::before {
  content: "";
  width: 31px;
  height: 31px;
  background: var(--subject-icon) center / contain no-repeat;
  filter: drop-shadow(0 3px 2px rgba(61, 52, 40, .12));
}
.subject-dropdown .subject-link[data-subject="math"] {
  --subject-bg: #e5f7ef;
  --subject-icon: url("thiings/note.png");
}
.subject-dropdown .subject-link[data-subject="chinese"] {
  --subject-bg: #fde7e9;
  --subject-icon: url("thiings/message.png");
}
.subject-dropdown .subject-link[data-subject="english"] {
  --subject-bg: #e8edff;
  --subject-icon: url("thiings/play.png");
}
.subject-dropdown .subject-link[data-subject="physics"] {
  --subject-bg: #fff1c4;
  --subject-icon: url("thiings/source.png");
}
.subject-dropdown .subject-link:hover {
  border-color: rgba(121, 79, 39, .20);
  background: var(--subject-bg);
  color: var(--island-ink);
  transform: translateY(-1px);
}
.subject-dropdown .subject-link.on {
  border-color: var(--island-primary);
  background: var(--subject-bg);
  color: #087e75;
  box-shadow: inset 0 0 0 2px rgba(25, 200, 185, .13);
}
.nav-link {
  min-height: 40px;
  padding: 0 13px;
  border-radius: 50px;
  color: var(--island-body);
  font-size: 14px;
  font-weight: 700;
  transition: color .2s var(--island-ease), background .2s var(--island-ease), transform .2s var(--island-ease);
}
.nav-link:hover {
  color: var(--island-ink);
  background: #fff7dc;
  transform: translateY(-1px);
}
.nav-link.active,
.nav-link[aria-current="page"] {
  color: #126f68;
  background: var(--island-mint);
  box-shadow: inset 0 0 0 1.5px rgba(25, 200, 185, .3);
}
.nav-link.subject-link {
  min-width: 52px;
  justify-content: center;
  padding: 0 13px;
}
.nav-link.subject-link:hover {
  background: rgba(255, 253, 244, .82);
  color: var(--island-ink);
}
.nav-link.subject-link.on {
  color: #fffdf4;
  background: var(--island-primary);
  box-shadow: 0 2px 0 var(--island-primary-edge);
}
.nav-link.subject-link.on:hover {
  background: var(--island-primary-hover);
}
.nav-link.resource-search-btn {
  gap: 6px;
  color: #087e75;
  border: 1.5px solid #88dacf;
  background: var(--island-mint);
}
.nav-link.resource-search-btn::before {
  content: "";
  width: 19px;
  height: 19px;
  background: url("thiings/search.png") center / contain no-repeat;
}
.nav-link.resource-search-btn .resource-search-ico {
  display: none;
}
.nav-link.resource-search-btn:hover {
  color: #006f68;
  border-color: var(--island-primary);
  background: #d9f7f1;
}

button,
.btn,
input[type="search"],
input[type="text"],
input[type="number"],
select,
textarea {
  font-family: var(--island-font);
}

button,
.btn {
  min-height: 44px;
  padding: 9px 17px;
  border: 1.5px solid var(--island-line);
  border-radius: 50px;
  background: var(--island-card);
  color: var(--island-ink);
  font-weight: 700;
  box-shadow: 0 2px 4px rgba(61, 52, 40, .05);
  transition:
    transform .2s var(--island-ease),
    background .2s var(--island-ease),
    border-color .2s var(--island-ease),
    box-shadow .2s var(--island-ease),
    color .2s var(--island-ease);
}
button:hover,
.btn:hover {
  border-color: #9edfd2;
  background: #f4fff9;
  color: #087e75;
  box-shadow: var(--island-shadow-soft);
  transform: translateY(-1px);
}
button:active,
.btn:active {
  box-shadow: 0 1px 3px rgba(61, 52, 40, .06);
  transform: translateY(1px);
}
button.primary,
.btn-primary {
  border-color: var(--island-primary);
  background: var(--island-primary);
  color: #fffdf4;
  box-shadow: 0 5px 0 var(--island-primary-edge);
}
button.primary:hover,
.btn-primary:hover {
  border-color: var(--island-primary-hover);
  background: var(--island-primary-hover);
  color: #fffdf4;
  box-shadow: 0 6px 0 var(--island-primary-edge);
  filter: none;
  transform: translateY(-1px);
}
button.primary:active,
.btn-primary:active {
  border-color: var(--island-primary-active);
  background: var(--island-primary-active);
  box-shadow: 0 1px 0 var(--island-primary-edge);
  transform: translateY(2px);
}
.btn-lg {
  min-height: 50px;
  padding: 11px 23px;
  font-size: 16px;
  font-weight: 800;
}
button.good {
  color: #fff;
  border-color: #4aa64f;
  background: #5aae5a;
}
button.good:hover {
  color: #fff;
  border-color: #45984b;
  background: #68ba68;
}
button.bad {
  color: #fff;
  border-color: var(--island-error);
  background: #de7165;
}
button.bad:hover {
  color: #fff;
  border-color: var(--island-error);
  background: #e78377;
}
button:disabled {
  opacity: .55;
  box-shadow: none;
  transform: none;
}

input[type="search"],
input[type="text"],
input[type="number"],
select,
textarea {
  min-height: 44px;
  padding: 10px 16px;
  border: 1.5px solid var(--island-line);
  border-radius: 50px;
  background: var(--island-input);
  color: var(--island-ink);
  font-weight: 500;
  box-shadow: none;
  transition: border-color .2s var(--island-ease), box-shadow .2s var(--island-ease), background .2s var(--island-ease);
}
textarea {
  border-radius: 18px;
}
select {
  padding-right: 38px;
  text-overflow: ellipsis;
}
input::placeholder,
textarea::placeholder {
  color: var(--island-faint);
  font-weight: 400;
}
input:hover,
select:hover,
textarea:hover {
  border-color: #bcae94;
}
input:focus,
select:focus,
textarea:focus {
  border-color: #e4b630;
  outline: 3px solid rgba(255, 204, 0, .30);
  outline-offset: 0;
  background: #fffdf4;
}

.site-footer {
  position: relative;
  margin-top: 34px;
  padding: 22px 16px 26px;
  border-top: 1px solid rgba(121, 79, 39, .12);
  background: rgba(248, 248, 240, .72);
  color: var(--island-muted);
  font-size: 13px;
}
.site-footer a {
  color: #00897b;
  font-weight: 700;
}

.home {
  width: min(1160px, calc(100% - 40px));
  padding: 34px 0 58px;
}

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, .9fr);
  gap: 34px;
  align-items: center;
  min-height: 430px;
  padding: 44px 48px;
  overflow: hidden;
  border: 1.5px solid #d8ccb8;
  border-radius: 34px;
  background:
    radial-gradient(circle at 84% 45%, rgba(130, 213, 187, .20), transparent 31%),
    linear-gradient(135deg, rgba(255, 253, 244, .97), rgba(247, 243, 223, .96));
  box-shadow: 0 8px 0 rgba(121, 79, 39, .07);
}
.hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  width: 440px;
  height: 440px;
  right: -185px;
  top: -180px;
  border: 2px dashed rgba(25, 200, 185, .26);
  border-radius: 50%;
}
.hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 270px;
  height: 270px;
  right: -92px;
  bottom: -170px;
  border-radius: 50%;
  background: rgba(255, 240, 185, .55);
}
.hero > .eyebrow {
  align-self: end;
  grid-column: 1;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 13px;
  color: #00897b;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .02em;
  line-height: 1.55;
}
.eyebrow::before {
  content: "";
  width: 21px;
  height: 21px;
  flex: none;
  background: url("thiings/note.png") center / contain no-repeat;
}
.hero h1 {
  grid-column: 1;
  max-width: 650px;
  margin: 0;
  color: var(--island-ink);
  font-size: clamp(42px, 4vw, 54px);
  line-height: 1.07;
  font-weight: 900;
  letter-spacing: -.052em;
  text-wrap: balance;
  white-space: nowrap;
}
.hero h1::after {
  content: "";
  display: block;
  width: min(280px, 65%);
  height: 13px;
  margin-top: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 280 13'%3E%3Cpath d='M3 9c48-7 78-1 117-5 47-5 72 7 158-2' fill='none' stroke='%23f4bd43' stroke-width='5' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
  opacity: .62;
}
.hero .lede {
  grid-column: 1;
  max-width: 660px;
  margin: 11px 0 0;
  color: var(--island-body);
  font-size: 17px;
  line-height: 1.65;
  white-space: nowrap;
}
.hero-actions {
  grid-column: 1;
  display: flex;
  gap: 12px;
  margin-top: 2px;
}
.hero-actions .btn {
  flex: 0 1 auto;
  min-width: 150px;
}
.quiet-link {
  grid-column: 1;
  margin: 3px 0 0;
  color: var(--island-muted);
  font-size: 14px;
}
.quiet-link a {
  color: #00897b;
  font-weight: 700;
  text-decoration-color: rgba(0, 137, 123, .35);
  text-underline-offset: 4px;
}

/* Original, local-asset knowledge island illustration. */
.knowledge-island {
  position: relative;
  grid-column: 2;
  grid-row: 1 / span 6;
  align-self: stretch;
  display: grid;
  place-items: center;
  min-height: 390px;
  margin: -8px -12px -8px 0;
}
.island-orbit {
  position: absolute;
  width: min(330px, 90%);
  aspect-ratio: 1;
  border: 2px dashed rgba(49, 175, 159, .32);
  border-radius: 50%;
  animation: island-orbit 32s linear infinite;
}
.island-orbit::before,
.island-orbit::after {
  content: "";
  position: absolute;
  border-radius: 50%;
}
.island-orbit::before {
  inset: 19%;
  border: 1.5px dashed rgba(218, 166, 63, .32);
}
.island-orbit::after {
  left: 13%;
  top: 8%;
  width: 12px;
  height: 12px;
  background: #f7cd67;
  border: 2px solid var(--island-line-strong);
}
.island-sun {
  position: absolute;
  right: 2%;
  top: 1%;
  width: 74px;
  height: 74px;
  border: 2px solid #d3b56d;
  border-radius: 50%;
  background: #fff0b9;
  box-shadow: 0 0 0 10px rgba(255, 240, 185, .30);
}
.island-sun::before,
.island-sun::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: rgba(245, 195, 28, .26);
}
.island-sun::before { width: 6px; height: 6px; left: 43%; top: 35%; }
.island-sun::after { width: 5px; height: 5px; left: 61%; top: 53%; }
.island-core {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 178px;
  min-height: 178px;
  padding: 22px 16px;
  border: 2px solid var(--island-line-strong);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 32%, #fffdf4 0 30%, transparent 31%),
    #fff6d8;
  text-align: center;
  box-shadow: 0 7px 0 rgba(121, 79, 39, .13), 0 16px 30px rgba(61, 52, 40, .08);
}
.island-core img {
  width: 62px;
  height: 62px;
  object-fit: contain;
  filter: drop-shadow(0 4px 3px rgba(61, 52, 40, .13));
}
.island-core strong {
  margin-top: 1px;
  color: var(--island-ink);
  font-size: 20px;
  font-weight: 900;
  line-height: 1.2;
}
.island-core span {
  margin-top: 4px;
  color: #00897b;
  font-size: 11px;
  font-weight: 700;
}
.island-node {
  position: absolute;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 105px;
  min-height: 104px;
  padding: 10px 8px;
  border: 2px solid var(--island-line-strong);
  border-radius: 22px;
  background: var(--node-bg, var(--island-card));
  color: var(--island-ink);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 5px 0 rgba(121, 79, 39, .12);
  transition: transform .25s var(--island-ease), box-shadow .25s var(--island-ease);
}
.island-node:hover {
  color: var(--island-ink);
  transform: translateY(-4px) rotate(-1deg);
  box-shadow: 0 9px 0 rgba(121, 79, 39, .12), 0 14px 24px rgba(61, 52, 40, .08);
}
.island-node img {
  width: 51px;
  height: 51px;
  object-fit: contain;
  filter: drop-shadow(0 4px 3px rgba(61, 52, 40, .12));
}
.island-node small {
  color: var(--island-muted);
  font-size: 10px;
  font-weight: 600;
}
.island-node-math {
  --node-bg: #e5f7ef;
  left: 0;
  top: 15%;
  transform: rotate(-3deg);
}
.island-node-math:hover { transform: translateY(-4px) rotate(-3deg); }
.island-node-chinese {
  --node-bg: #fde7e9;
  right: 1%;
  top: 12%;
  transform: rotate(2.5deg);
}
.island-node-chinese:hover { transform: translateY(-4px) rotate(2.5deg); }
.island-node-english {
  --node-bg: #e8edff;
  left: 1%;
  bottom: 7%;
  transform: rotate(2deg);
}
.island-node-english:hover { transform: translateY(-4px) rotate(2deg); }
.island-node-physics {
  --node-bg: #fff1c4;
  right: 0;
  bottom: 5%;
  transform: rotate(-2deg);
}
.island-node-physics:hover { transform: translateY(-4px) rotate(-2deg); }
.island-mascot {
  position: absolute;
  z-index: 4;
  width: 104px;
  height: 104px;
  right: 8%;
  top: 45%;
  object-fit: contain;
  border: 2px solid rgba(121, 79, 39, .22);
  border-radius: 50%;
  background: rgba(255, 253, 244, .88);
  padding: 4px;
  box-shadow: 0 4px 0 rgba(121, 79, 39, .08);
  filter: drop-shadow(0 7px 4px rgba(61, 52, 40, .17));
  animation: mascot-float 4.8s ease-in-out infinite;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 46px 0 18px;
  color: var(--island-ink);
  font-size: 27px;
  font-weight: 900;
}
.section-title::before {
  content: "";
  width: 12px;
  height: 28px;
  flex: none;
  border: 1.5px solid #a89a83;
  border-radius: 4px;
  background: var(--island-primary);
  box-shadow: 4px 3px 0 rgba(121, 79, 39, .10);
  transform: skewY(-13deg);
}

.steps {
  gap: 16px;
}
.steps li {
  position: relative;
  min-height: 206px;
  padding: 23px 21px;
  overflow: hidden;
  border: 1.5px solid var(--step-line, #d8ccb8);
  border-radius: 22px;
  background:
    radial-gradient(circle at 91% 10%, rgba(255, 253, 244, .90), transparent 36%),
    var(--step-bg, var(--island-card));
  box-shadow: none;
  transition: transform .25s var(--island-ease);
}
.steps li:nth-child(1) { --step-bg: #e9f9f4; --step-line: #9adccc; }
.steps li:nth-child(2) { --step-bg: #fff2bd; --step-line: #e3c466; }
.steps li:nth-child(3) { --step-bg: #f1e8fb; --step-line: #c7acdc; }
.steps li::after {
  content: "";
  position: absolute;
  right: -31px;
  bottom: -42px;
  width: 118px;
  height: 118px;
  border: 2px dashed rgba(121, 79, 39, .13);
  border-radius: 50%;
}
.steps li:hover {
  transform: translateY(-3px);
}
.step-no {
  width: 37px;
  height: 37px;
  border: 1.5px solid rgba(121, 79, 39, .14);
  border-radius: 13px;
  background: rgba(255, 253, 244, .78);
  color: var(--island-ink);
  font-size: 16px;
  font-weight: 900;
}
.steps h3 {
  margin: 16px 0 7px;
  color: var(--island-ink);
  font-size: 19px;
  font-weight: 800;
}
.steps p {
  margin: 0;
  color: var(--island-body);
  font-size: 14px;
  line-height: 1.75;
}

.stat-grid {
  gap: 14px;
}
.stat-card {
  position: relative;
  min-height: 142px;
  padding: 24px 18px 18px;
  overflow: hidden;
  border: 1.5px solid var(--stat-line, #d8ccb8);
  border-radius: 20px;
  background: var(--stat-bg, var(--island-card));
}
.stat-card:nth-child(1) { --stat-bg: #e5f8f3; --stat-line: #9adccc; }
.stat-card:nth-child(2) { --stat-bg: #fff1be; --stat-line: #e3c466; }
.stat-card:nth-child(3) { --stat-bg: #e8edff; --stat-line: #b3c0e7; }
.stat-card:nth-child(4) { --stat-bg: #f3e8fb; --stat-line: #c8afdf; }
.stat-card::before {
  content: "";
  position: absolute;
  width: 47px;
  height: 47px;
  right: 12px;
  top: 13px;
  opacity: .88;
  background: var(--stat-icon) center / contain no-repeat;
  filter: drop-shadow(0 3px 2px rgba(61, 52, 40, .08));
}
.stat-card:nth-child(1) { --stat-icon: url("thiings/note.png"); }
.stat-card:nth-child(2) { --stat-icon: url("thiings/link.png"); }
.stat-card:nth-child(3) { --stat-icon: url("thiings/check.png"); }
.stat-card:nth-child(4) { --stat-icon: url("thiings/source.png"); }
.stat-num {
  position: relative;
  z-index: 1;
  color: var(--island-ink);
  font-size: clamp(30px, 3.2vw, 40px);
  font-weight: 900;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.stat-label {
  margin-top: 34px;
  color: var(--island-body);
  font-size: 13px;
  font-weight: 700;
}
.stat-note {
  margin-top: 11px;
  color: var(--island-muted);
  font-size: 12.5px;
}

.grade-grid {
  gap: 13px;
}
a.grade-card {
  min-height: 123px;
  padding: 16px 16px 14px;
  border: 1.5px solid var(--grade-line, #d8ccb8);
  border-top-width: 1.5px;
  border-radius: 20px;
  background: var(--grade-bg, var(--island-card));
  box-shadow: none;
  transition: transform .2s var(--island-ease), box-shadow .2s var(--island-ease);
}
a.grade-card.is-primary { --grade-bg: #f0fbf7; --grade-line: #b3dfd3; }
a.grade-card.is-junior { --grade-bg: #edf1ff; --grade-line: #bbc7ea; }
a.grade-card.is-senior { --grade-bg: #f4ecfb; --grade-line: #cfb8e2; }
a.grade-card::after {
  content: "";
  align-self: flex-end;
  width: 19px;
  height: 19px;
  margin-top: auto;
  background: url("thiings/next.png") center / contain no-repeat;
  opacity: .72;
}
a.grade-card:hover,
a.iq-card:hover {
  border-color: var(--grade-line, var(--brand));
  box-shadow: 0 5px 12px rgba(61, 52, 40, .08);
  transform: translateY(-2px);
}
.grade-stage {
  color: var(--island-muted);
  font-size: 11px;
  font-weight: 700;
}
a.grade-card strong {
  margin: 2px 0;
  color: var(--island-ink);
  font-size: 19px;
  font-weight: 800;
}
.grade-count {
  color: #00897b;
  font-size: 12px;
  font-weight: 700;
}
a.iq-card {
  position: relative;
  min-height: 88px;
  margin-top: 20px;
  padding: 18px 78px 18px 20px;
  overflow: hidden;
  border: 1.5px solid #e3c466;
  border-top-width: 1.5px;
  border-radius: 20px;
  background: #fff2bd;
}
a.iq-card::before {
  content: "";
  position: absolute;
  width: 63px;
  height: 63px;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: url("thiings/life-brain.png") center / contain no-repeat;
  filter: drop-shadow(0 4px 3px rgba(61, 52, 40, .12));
}
a.iq-card .card-emoji {
  display: none;
}
a.iq-card strong {
  color: var(--island-ink);
  font-size: 17px;
  font-weight: 800;
}
a.iq-card .iq-sub {
  color: var(--island-body);
  font-size: 13px;
  font-weight: 600;
}
a.iq-card .iq-note {
  margin-top: 2px;
  color: var(--island-muted);
  font-size: 11px;
}
.load-error {
  border: 1.5px solid #e5b2a8;
  border-radius: 18px;
  background: var(--island-error-bg);
  color: var(--island-body);
}

/* Explore: directory, graph canvas, detail sheet */
body.page-explore {
  background: var(--island-paper);
}
body.page-explore .site-header {
  position: relative;
}
.explore {
  gap: 0;
  background: rgba(247, 243, 223, .42);
}
.side {
  border-right: 1.5px solid var(--island-line);
  background: rgba(255, 253, 244, .88);
}
.side-tools {
  gap: 10px;
  padding: 15px 13px;
  border-bottom: 1.5px solid rgba(121, 79, 39, .11);
  background: rgba(255, 253, 244, .92);
}
.stage-tabs {
  gap: 5px;
  padding: 4px;
  border: 1.5px solid rgba(121, 79, 39, .10);
  border-radius: 50px;
  background: #f0e8d8;
}
.stage-tab {
  flex: 1;
  min-width: 0;
  min-height: 34px;
  padding: 4px 10px;
  border: 0;
  border-radius: 50px;
  background: transparent;
  box-shadow: none;
  color: var(--island-body);
  font-size: 12px;
  font-weight: 700;
}
.stage-tab:hover {
  background: rgba(255, 253, 244, .72);
  box-shadow: none;
  transform: none;
}
.stage-tab.on,
.stage-tab[aria-selected="true"] {
  border-color: transparent;
  background: #fffdf4;
  color: var(--island-ink);
  box-shadow: 0 2px 5px rgba(61, 52, 40, .08);
}
.filter-row {
  gap: 6px;
}
.side-tools select {
  min-height: 40px;
  padding: 7px 30px 7px 12px;
  font-size: 12px;
}
.count {
  color: var(--island-muted);
  font-size: 12px;
  font-weight: 600;
}
.list {
  padding: 4px 3px 18px;
}
.vol {
  margin: 5px 8px;
  overflow: hidden;
  border: 1.5px solid rgba(121, 79, 39, .10);
  border-radius: 15px;
  background: rgba(255, 253, 244, .72);
}
.vol > summary,
.chap > summary {
  padding: 11px 13px;
  color: var(--island-body);
  font-weight: 700;
}
.vol > summary {
  position: sticky;
  border-bottom: 1px solid rgba(121, 79, 39, .08);
  background: #f4eddd;
}
.vol[open] > summary {
  color: var(--island-ink);
  background: #f7efda;
}
.chap > summary {
  color: var(--island-body);
  font-size: 13px;
}
.count-pill {
  color: var(--island-faint);
  font-size: 11px;
}
.topic-item {
  width: calc(100% - 14px);
  margin: 3px 7px;
  padding: 8px 10px;
  border-radius: 12px;
  color: var(--island-body);
  transition: background .18s var(--island-ease), color .18s var(--island-ease);
}
.topic-item:hover {
  background: #f1eadb;
  color: var(--island-ink);
}
.topic-item.sel {
  background: var(--island-mint);
  color: var(--island-ink);
  box-shadow: inset 3px 0 0 var(--island-primary);
}
.topic-item .nm {
  font-size: 13px;
  font-weight: 700;
}
.topic-item .meta {
  color: var(--island-muted);
  font-size: 11px;
}
.graph-pane {
  background:
    radial-gradient(circle at 1px 1px, rgba(121, 79, 39, .08) 1.2px, transparent 1.3px),
    #f7f3df;
  background-size: 25px 25px;
}
.graph-toolbar {
  gap: 9px;
  padding: 9px 12px;
  border-bottom: 1.5px solid rgba(121, 79, 39, .11);
  background: rgba(255, 253, 244, .90);
  backdrop-filter: blur(8px);
}
.graph-toolbar button {
  min-height: 38px;
  padding: 6px 13px;
  border: 1.5px solid var(--island-line);
  background: #fffdf4;
  font-size: 12px;
  box-shadow: 0 2px 4px rgba(61, 52, 40, .04);
}
.depth-label {
  color: var(--island-muted);
  font-size: 12px;
}
.seg {
  gap: 4px;
  padding: 3px;
  border: 1.5px solid rgba(121, 79, 39, .10);
  border-radius: 50px;
  background: #f0e8d8;
}
.seg button {
  min-height: 32px;
  padding: 4px 12px;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: var(--island-body);
}
.seg button:hover {
  background: rgba(255, 253, 244, .70);
  box-shadow: none;
  transform: none;
}
.depth button.on {
  border-color: transparent;
  background: var(--island-primary);
  color: #fffdf4;
}
.zoom-tools {
  gap: 5px;
}
.zoom-tools button {
  color: var(--island-body);
}
.graph-stage {
  border-bottom: 1px solid rgba(121, 79, 39, .08);
}
.graph-empty {
  align-items: flex-start;
  justify-content: center;
  gap: 11px;
  max-width: 620px;
  margin: auto;
  padding: 40px;
  text-align: left;
}
.graph-empty::before {
  content: "";
  width: 91px;
  height: 91px;
  margin-bottom: 2px;
  background: url("thiings/link.png") center / contain no-repeat;
  filter: drop-shadow(0 7px 4px rgba(61, 52, 40, .13));
}
.graph-empty p {
  max-width: 34em;
  color: var(--island-body);
  font-size: 14px;
  line-height: 1.75;
}
.graph-empty .btn-primary {
  margin-top: 4px;
}
.graph-empty .btn-primary::before {
  content: "";
  width: 22px;
  height: 22px;
  background: url("thiings/source.png") center / contain no-repeat;
}
.graph-fold {
  border-bottom: 1px solid rgba(121, 79, 39, .10);
  background: var(--island-warning-bg);
  color: var(--island-body);
}
.legend {
  gap: 7px 14px;
  padding: 10px 15px 0;
  color: var(--island-muted);
  font-size: 12px;
}
.swatch {
  width: 14px;
  height: 14px;
  border: 2px solid var(--island-line-strong);
  border-radius: 5px;
}
.sw-p { background: var(--node-primary-bg); border-color: var(--node-primary); }
.sw-j { background: var(--node-junior-bg); border-color: var(--node-junior); }
.sw-h { background: var(--node-senior-bg); border-color: var(--node-senior); }
.sw-c { background: var(--node-current-bg); border-color: var(--node-current-border); }
.line-hard { border-top: 2px solid var(--edge); }
.line-soft { border-top: 2px dashed var(--edge-soft); }
.graph-meta {
  padding: 5px 15px 12px;
  color: var(--island-muted);
  font-size: 12px;
}
.node-tip {
  border: 1.5px solid var(--island-line-strong);
  border-radius: 14px;
  background: #fffdf4;
  color: var(--island-ink);
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--island-shadow-lift);
}
.detail {
  padding: 20px 18px 28px;
  border-left: 1.5px solid rgba(121, 79, 39, .11);
  background: rgba(255, 253, 244, .92);
}
.detail h1 {
  color: var(--island-ink);
  font-size: 22px;
  font-weight: 800;
}
.detail h2 {
  margin-top: 23px;
  color: var(--island-ink);
  font-size: 16px;
  font-weight: 800;
}
.detail p {
  color: var(--island-body);
  font-size: 13.5px;
  line-height: 1.72;
}
.pills {
  margin: 10px 0 14px;
}
.pill {
  min-height: 27px;
  padding: 3px 10px;
  border: 1px solid rgba(121, 79, 39, .10);
  border-radius: 50px;
  color: var(--island-body);
  font-size: 11.5px;
  font-weight: 700;
}
.pill-p { background: var(--node-primary-bg); }
.pill-j { background: var(--node-junior-bg); }
.pill-h { background: var(--node-senior-bg); }
.alias-note {
  border: 1.5px solid #e6ca73;
  border-radius: 15px;
  background: var(--island-warning-bg);
  color: var(--island-body);
  font-size: 13px;
}
.diag-btn {
  display: flex;
  width: 100%;
  justify-content: center;
  margin: 13px 0;
}
.meta-grid {
  gap: 9px;
}
.meta-grid div {
  border: 1px solid rgba(121, 79, 39, .08);
  border-radius: 14px;
  background: #f7f3e6;
}
.meta-grid dt {
  color: var(--island-muted);
  font-size: 11px;
}
.meta-grid dd {
  color: var(--island-ink);
  font-size: 12.5px;
  font-weight: 700;
}
.std,
.sample-q {
  border: 1px solid rgba(121, 79, 39, .10);
  border-left: 4px solid var(--island-primary);
  border-radius: 14px;
  background: #f7f1e4;
}
.rel-row {
  padding: 8px 10px;
  border: 1px solid rgba(121, 79, 39, .10);
  border-radius: 14px;
  background: #fbf7eb;
}
.rel-name {
  color: #00897b;
}
.rel-where,
.why {
  color: var(--island-muted);
}
.id-code {
  color: var(--island-faint);
  font-family: var(--island-font);
  font-size: 11px;
}
.side::-webkit-scrollbar,
.detail::-webkit-scrollbar,
.list::-webkit-scrollbar {
  width: 8px;
}
.side::-webkit-scrollbar-thumb,
.detail::-webkit-scrollbar-thumb,
.list::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 10px;
  background: #cdbda5;
  background-clip: padding-box;
}

/* Diagnostics and results */
main#root {
  width: min(920px, 100%);
  padding: 28px 16px 64px;
}
.card {
  margin-bottom: 15px;
  padding: 22px;
  border: 1.5px solid rgba(121, 79, 39, .13);
  border-radius: 22px;
  background: rgba(255, 253, 244, .92);
  box-shadow: none;
}
.card h1,
.card h2 {
  color: var(--island-ink);
  font-size: 21px;
  font-weight: 800;
}
.card h3 {
  color: var(--island-ink);
  font-size: 16px;
  font-weight: 700;
}
.banner {
  position: relative;
  padding: 15px 17px 15px 58px;
  border: 1.5px solid #a5ddd2;
  border-radius: 18px;
  background: #e8f9f5;
  color: var(--island-body);
  font-size: 13.5px;
  line-height: 1.72;
}
.banner::before {
  content: "";
  position: absolute;
  width: 38px;
  height: 38px;
  left: 13px;
  top: 12px;
  background: url("thiings/note.png") center / contain no-repeat;
}
.banner.demo {
  border-color: #e5c66e;
  background: #fff4cb;
}
.banner.demo::before {
  background-image: url("thiings/mascot-timer.png");
}
.child-bar {
  border-color: #d4c4a8;
}
.chapter-browser > summary {
  color: var(--island-body);
  font-size: 13px;
}
.vol {
  border-color: rgba(121, 79, 39, .13);
  border-radius: 16px;
  background: #fffdf4;
}
.vol > summary {
  border-radius: 16px;
  background: #f4eddd;
  color: var(--island-ink);
}
.chap-head {
  border-bottom-color: rgba(121, 79, 39, .09);
  color: var(--island-body);
  font-size: 12.5px;
}
.topic-row {
  border-bottom-color: rgba(121, 79, 39, .08);
  color: var(--island-body);
  font-size: 13px;
}
.topic-row .nm {
  font-weight: 600;
}
.topic-row .sec {
  color: var(--island-muted);
}
#search {
  margin-top: 10px;
}
.progress {
  height: 11px;
  border: 1px solid rgba(121, 79, 39, .10);
  background: #eee4d3;
}
.progress > i {
  background: linear-gradient(90deg, var(--island-primary), #76d9c4);
}
.q-title {
  color: var(--island-ink);
  font-size: 22px;
  font-weight: 800;
}
.q-text {
  padding: 17px 18px;
  border: 1px solid rgba(121, 79, 39, .10);
  border-radius: 17px;
  background: #f8f2e5;
  color: var(--island-body);
  font-size: 16px;
  line-height: 1.75;
}
.reason {
  color: var(--island-muted);
}
.ans-input {
  font-size: 16px;
}
.notice {
  border: 1.5px solid #e5ca79;
  border-radius: 14px;
  background: #fff5d4;
  color: #8a6719;
  font-size: 12.5px;
  line-height: 1.65;
}
.verdict {
  padding: 13px 15px;
  border: 1.5px solid transparent;
  border-radius: 15px;
}
.verdict.ok {
  border-color: #a5d7a3;
  background: var(--island-success-bg);
  color: var(--island-success);
}
.verdict.no {
  border-color: #e5b1aa;
  background: var(--island-error-bg);
  color: var(--island-error);
}
.refans {
  border: 1.5px dashed #77bf73;
  border-radius: 15px;
  background: var(--island-success-bg);
  color: var(--island-body);
}
.explain {
  border: 1px solid rgba(121, 79, 39, .10);
  border-left: 4px solid #8398ce;
  border-radius: 15px;
  background: #edf1ff;
  color: var(--island-body);
}
.choices {
  gap: 10px;
}
button.choice {
  min-height: 53px;
  padding: 13px 17px;
  border: 1.5px solid var(--island-line);
  border-radius: 17px;
  background: #fffdf4;
  color: var(--island-body);
  font-size: 15px;
  font-weight: 600;
  box-shadow: 0 3px 0 #e1d6c2;
  transition: transform .2s var(--island-ease), border-color .2s var(--island-ease), background .2s var(--island-ease), box-shadow .2s var(--island-ease);
}
button.choice:hover {
  border-color: #7ad3c0;
  background: #f0fcf8;
  color: var(--island-ink);
  box-shadow: 0 5px 0 #c3e4da;
  transform: translateY(-2px);
}
button.choice:active {
  box-shadow: 0 1px 0 #d5c6af;
  transform: translateY(1px);
}
button.choice.picked {
  border-color: var(--island-primary);
  background: var(--island-mint);
  color: var(--island-ink);
  box-shadow: 0 3px 0 var(--island-primary);
  outline: 3px solid rgba(25, 200, 185, .12);
}
.tag {
  padding: 3px 9px;
  border: 1px solid rgba(121, 79, 39, .08);
  border-radius: 50px;
  background: #f1ece0;
  color: var(--island-body);
  font-size: 11px;
  font-weight: 700;
}
.tag.weak { border-color: #e6aaa4; background: var(--island-error-bg); color: var(--island-error); }
.tag.mastered { border-color: #9fd29a; background: var(--island-success-bg); color: var(--island-success); }
.tag.unknown { border-color: #d7d2c8; background: #f0ece2; color: var(--island-muted); }
.tag.shaky { border-color: #e5c978; background: var(--island-warning-bg); color: var(--island-warning); }
.tag.root { border-color: #c9564b; background: #dc7064; color: #fff; }
.tag.target { border-color: #7185c5; background: #7d90cc; color: #fff; }
.tag.ext { border-color: #b4c0e7; background: var(--island-blue); color: var(--island-body); }
.tag.diff-basic { border-color: #a8d5a4; background: var(--island-success-bg); color: var(--island-success); }
.tag.diff-standard { border-color: #bbc7e8; background: var(--island-blue); color: #536493; }
.tag.diff-advanced { border-color: #cfb7e1; background: var(--island-purple); color: #7e5795; }
.stats {
  gap: 10px;
}
.stat {
  min-height: 82px;
  padding: 13px 9px;
  border: 1px solid rgba(121, 79, 39, .10);
  border-radius: 16px;
  background: #f4eee1;
  color: var(--island-muted);
  font-size: 12px;
  font-weight: 600;
}
.stat b {
  margin-bottom: 5px;
  color: var(--island-ink);
  font-size: 26px;
  font-weight: 900;
}
.stat.ok { border-color: #abd5a8; background: #e8f7e9; color: var(--island-success); }
.stat.bad { border-color: #e7b6af; background: #fff0e9; color: var(--island-error); }
.stat.shaky { border-color: #e7cc80; background: #fff5d9; color: var(--island-warning); }
.stat.unk { border-color: #d7d1c6; background: #f1ece1; color: var(--island-muted); }
.stat.ask { border-color: #b9c6e9; background: #eef1ff; color: #536493; }
.details,
details.topic {
  border-bottom-color: rgba(121, 79, 39, .09);
}
details.topic > summary {
  color: var(--island-body);
  font-weight: 600;
}
.std {
  padding: 10px 12px;
  border-radius: 13px;
  border-left-width: 4px;
}
.std code {
  color: var(--island-body);
  font-family: var(--island-font);
}
ol.path {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
ol.path > li {
  padding: 10px 10px 10px 49px;
  border: 1px solid rgba(121, 79, 39, .10);
  border-radius: 16px;
  background: #fbf6e9;
}
ol.path > li::before {
  left: 10px;
  top: 12px;
  width: 28px;
  height: 28px;
  border-radius: 10px;
  background: var(--island-primary);
  color: #fff;
  font-weight: 900;
}
.chap-bar {
  height: 10px;
  border: 1px solid rgba(121, 79, 39, .08);
  border-radius: 50px;
  background: #eee4d3;
}
.chap-bar .m { background: #61b45e; }
.chap-bar .s { background: #e1b13d; }
.chap-bar .w { background: #dc8177; }
.chap-bar .u { background: #c8bca8; }
.path-tools button.on {
  border-color: transparent;
  background: var(--island-primary);
  color: #fff;
}
#path-cy {
  border: 1.5px solid var(--island-line);
  border-radius: 18px;
  background:
    radial-gradient(circle at 1px 1px, rgba(121, 79, 39, .07) 1.2px, transparent 1.3px),
    #f7f3df;
  background-size: 25px 25px;
}
.graph-fold {
  border: 1px solid #e7ce83;
  border-radius: 14px;
  background: var(--island-warning-bg);
}
.share-modal {
  background: rgba(61, 52, 40, .38);
  backdrop-filter: blur(5px);
}
.share-panel {
  border: 2px solid var(--island-line-strong);
  border-radius: 25px;
  background: var(--island-card);
  box-shadow: var(--island-shadow-lift);
}
.share-panel::before {
  content: "";
  display: block;
  flex: none;
  height: 66px;
  margin: -2px -2px 0;
  border-radius: 23px 23px 0 0;
  background:
    url("thiings/mascot.png") 26px 8px / 54px 54px no-repeat,
    radial-gradient(circle at 90% 38%, rgba(25, 200, 185, .15), transparent 26%),
    linear-gradient(135deg, #fff6d8, #e7f8f3);
  border-bottom: 1.5px solid rgba(121, 79, 39, .10);
}
.share-bar {
  padding-top: 10px;
}
.share-hint {
  color: #00897b;
}
.share-scroll img {
  border-radius: 16px;
  background: var(--island-content);
}
table.log {
  color: var(--island-body);
}
table.log th,
table.log td {
  border-bottom-color: rgba(121, 79, 39, .10);
}
table.log th {
  background: #f3ecdd;
  color: var(--island-muted);
}

/* Children profiles and history */
main.kids {
  width: min(820px, 100%);
  padding: 30px 18px 64px;
}
.kids h1 {
  color: var(--island-ink);
  font-size: 32px;
  font-weight: 900;
}
.kids h1::before {
  content: "";
  display: inline-block;
  width: 42px;
  height: 42px;
  margin-right: 10px;
  vertical-align: -9px;
  background: url("thiings/users.png") center / contain no-repeat;
  filter: drop-shadow(0 3px 2px rgba(61, 52, 40, .10));
}
.kids > .lede {
  max-width: 650px;
  margin-bottom: 22px;
  color: var(--island-body);
  font-size: 15px;
  line-height: 1.8;
}
.kids h2 {
  color: var(--island-ink);
  font-size: 19px;
  font-weight: 800;
}
.kid-card,
.kid-form,
.kid-section > .rec,
.kid-empty-card {
  border: 1.5px solid rgba(121, 79, 39, .13);
  border-radius: 21px;
  background: rgba(255, 253, 244, .92);
}
.kid-card {
  position: relative;
  min-height: 131px;
  padding: 20px 180px 18px 20px;
  border-top-width: 1.5px;
  overflow: hidden;
  margin-bottom: 14px;
}
.kid-card::after {
  content: "";
  position: absolute;
  width: 115px;
  height: 115px;
  right: 22px;
  top: 50%;
  transform: translateY(-50%);
  background: url("thiings/mascot.png") center / contain no-repeat;
  filter: drop-shadow(0 7px 4px rgba(61, 52, 40, .12));
}
.kid-card.is-current {
  border-color: #9edfd2;
  border-top-color: #9edfd2;
  background: #f3fcf9;
}
.kid-head h3 {
  color: var(--island-ink);
  font-size: 20px;
  font-weight: 800;
}
.kid-badge {
  border: 0;
  background: var(--island-primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
}
.kid-meta {
  color: var(--island-muted);
  font-size: 12px;
}
.kid-stat {
  margin: 9px 0 13px;
  color: var(--island-body);
  font-size: 13px;
}
.kid-actions {
  gap: 8px;
}
.kid-actions button,
.kid-actions a {
  min-height: 38px;
  padding: 6px 13px;
  font-size: 12px;
}
.kid-form {
  padding: 23px;
  background: rgba(255, 253, 244, .94);
}
.kid-form label {
  margin-top: 16px;
  color: var(--island-body);
  font-size: 13px;
  font-weight: 700;
}
.kid-form input,
.kid-form select {
  width: 100%;
  max-width: 100%;
}
.form-actions {
  gap: 10px;
}
.kid-note {
  border-left: 3px solid #e4c56c;
  padding: 8px 12px;
  border-radius: 0 10px 10px 0;
  background: rgba(255, 241, 196, .50);
}
.kid-picker {
  gap: 10px;
  padding: 13px 16px;
  border: 1.5px solid rgba(121, 79, 39, .12);
  border-radius: 18px;
  background: rgba(255, 253, 244, .87);
}
.wk-item {
  border-bottom-color: rgba(121, 79, 39, .09);
}
.wk-name,
.rec-topics a {
  color: #00897b;
}
.rec {
  overflow: hidden;
  border: 1.5px solid rgba(121, 79, 39, .12) !important;
  border-radius: 17px !important;
  background: #fffdf4;
}
.rec > summary {
  background: #fbf6e9;
}
.rec-body {
  border-top-color: rgba(121, 79, 39, .09);
}
.kid-tag {
  border: 1px solid rgba(121, 79, 39, .08);
  padding: 3px 9px;
  border-radius: 50px;
  font-size: 10.5px;
  font-weight: 700;
}
.kid-tag.weak { border-color: #e6aaa4; background: var(--island-error-bg); color: var(--island-error); }
.kid-tag.shaky { border-color: #e5c978; background: var(--island-warning-bg); color: var(--island-warning); }
.kid-tag.ok { border-color: #9fd29a; background: var(--island-success-bg); color: var(--island-success); }
.kid-tag.unk { background: #f0ece2; color: var(--island-muted); }
.kid-tag.root { background: #dc7064; color: #fff; }
.kid-tag.sub { background: var(--island-mint); color: #007c71; }

/* App installation surface */
.pwa-bar {
  border: 2px solid var(--island-line-strong);
  border-radius: 22px;
  background: var(--island-card);
  box-shadow: 0 7px 0 rgba(121, 79, 39, .10), 0 14px 34px rgba(61, 52, 40, .12);
}
.pwa-bar-icon {
  border-radius: 14px;
}
.pwa-bar-text b {
  color: var(--island-ink);
}
.pwa-bar-text span {
  color: var(--island-muted);
}
.pwa-sheet-wrap {
  background: rgba(61, 52, 40, .38);
  backdrop-filter: blur(5px);
}
.pwa-sheet {
  border: 2px solid var(--island-line-strong);
  border-radius: 26px 26px 0 0;
  background: var(--island-card);
  box-shadow: 0 -8px 32px rgba(61, 52, 40, .15);
}
.pwa-sheet-title {
  color: var(--island-ink);
  font-weight: 900;
}
.pwa-sheet-lead,
.pwa-step-note {
  color: var(--island-muted);
}
.pwa-step-no {
  border: 1px solid var(--island-primary-edge);
  border-radius: 10px;
  background: var(--island-primary);
  color: #fff;
  font-weight: 900;
}
.pwa-footer-link {
  color: #00897b;
  border-radius: 50px;
}

/* Subject accents remain gentle and never become a cold-blue UI. */
body.subject-physics .nav-link.subject-link.on,
body.subject-physics .btn-primary {
  color: #5c3c08;
  border-color: #f1c567;
  background: #f1c567;
  box-shadow: 0 5px 0 #c39032;
}
body.subject-chinese .nav-link.subject-link.on,
body.subject-chinese .btn-primary {
  color: #fffdf4;
  border-color: #e8979d;
  background: #d87985;
  box-shadow: 0 5px 0 #b65d6c;
}
body.subject-english .nav-link.subject-link.on,
body.subject-english .btn-primary {
  color: #fffdf4;
  border-color: #8c9ddd;
  background: #8293d5;
  box-shadow: 0 5px 0 #6577b7;
}

@keyframes island-orbit {
  to { transform: rotate(360deg); }
}
@keyframes mascot-float {
  0%, 100% { transform: translateY(0) rotate(1deg); }
  50% { transform: translateY(-7px) rotate(-1deg); }
}
@keyframes island-rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: no-preference) {
  .hero > .eyebrow,
  .hero > h1,
  .hero > .lede,
  .hero > .hero-actions,
  .hero > .quiet-link {
    animation: island-rise .55s var(--island-ease) both;
  }
  .hero > h1 { animation-delay: .04s; }
  .hero > .lede { animation-delay: .10s; }
  .hero > .hero-actions { animation-delay: .16s; }
  .hero > .quiet-link { animation-delay: .21s; }
}

@media (max-width: 1120px) {
  .site-header {
    padding-left: 20px;
    padding-right: 20px;
  }
  .brand-name {
    font-size: 17px;
  }
  .nav-link {
    padding: 0 10px;
    font-size: 13px;
  }
  .header-left {
    gap: 20px;
  }
  .subject-menu summary {
    min-width: 104px;
    padding: 0 13px;
  }
  .hero {
    padding: 37px 32px;
    gap: 22px;
  }
  .hero h1 {
    font-size: clamp(39px, 5vw, 59px);
  }
  .island-node {
    width: 93px;
    min-height: 96px;
  }
  .island-node img {
    width: 46px;
    height: 46px;
  }
  .island-mascot {
    width: 82px;
    height: 82px;
  }
}

@media (max-width: 900px) {
  .site-header {
    position: relative;
    padding: 10px 14px 9px;
  }
  .site-nav {
    flex: 0 1 auto;
    justify-content: flex-start;
    gap: 6px;
  }
  .header-left {
    gap: 13px;
  }
  .page-links {
    flex: 0 1 auto;
    justify-content: center;
  }
  .nav-link {
    min-height: 38px;
    padding: 0 10px;
  }
  .subject-switch {
    flex: 1 1 100%;
    justify-content: center;
  }
  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(290px, .8fr);
    min-height: 430px;
    padding: 30px 24px;
  }
  .hero h1 {
    font-size: clamp(35px, 6vw, 48px);
  }
  .knowledge-island {
    min-height: 338px;
  }
  .island-orbit {
    width: 275px;
  }
  .island-core {
    width: 151px;
    min-height: 151px;
    padding: 16px 10px;
  }
  .island-core img {
    width: 51px;
    height: 51px;
  }
  .island-core strong {
    font-size: 17px;
  }
  .island-node {
    width: 81px;
    min-height: 85px;
    border-radius: 18px;
    padding: 7px 4px;
    font-size: 11px;
  }
  .island-node img {
    width: 40px;
    height: 40px;
  }
  .island-node small {
    display: none;
  }
  .island-mascot {
    width: 76px;
    height: 76px;
    right: 4%;
  }
  .home {
    width: min(100% - 28px, 760px);
  }
  .section-title {
    margin-top: 36px;
  }
  .explore-mobile-bar {
    background: var(--island-paper);
  }
  .list-toggle {
    background: var(--island-card);
    box-shadow: 0 3px 0 #e1d6c2;
  }
  .side.open {
    border-bottom: 1.5px solid var(--island-line);
  }
  .graph-stage {
    min-height: 345px;
  }
  #cy {
    height: 345px;
  }
  .graph-empty {
    justify-content: flex-start;
    gap: 8px;
    padding: 18px 20px;
  }
  .graph-empty::before {
    width: 66px;
    height: 66px;
  }
  .graph-empty p {
    font-size: 12.5px;
    line-height: 1.68;
  }
  .graph-empty .btn-primary {
    min-height: 42px;
    margin-top: 1px;
  }
  .legend {
    padding-top: 7px;
    font-size: 11px;
    gap: 6px 11px;
  }
  .graph-meta {
    font-size: 11px;
  }
  .graph-empty {
    align-items: center;
    text-align: center;
  }
  .detail {
    border-top: 1.5px solid rgba(121, 79, 39, .11);
  }
}

@media (max-width: 700px) {
  .top-banner {
    min-height: 34px;
    font-size: 11.5px;
  }
  .top-banner::before {
    width: 19px;
    height: 19px;
  }
  .site-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 5px;
  }
  .header-left {
    display: contents;
  }
  .brand {
    order: 1;
    min-height: 44px;
  }
  .brand .logo {
    width: 38px;
    height: 38px;
  }
  .brand-name {
    font-size: 15px;
  }
  .brand-kicker {
    font-size: 9px;
  }
  .site-nav {
    order: 3;
    flex: 1 1 100%;
    min-width: 0;
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }
  .site-nav::-webkit-scrollbar {
    display: none;
  }
  .subject-menu {
    order: 2;
    margin-left: auto;
  }
  .subject-menu summary {
    min-width: 101px;
    min-height: 42px;
    padding: 0 12px;
  }
  .subject-dropdown {
    width: 180px;
    top: calc(100% + 7px);
  }
  .subject-switch {
    overflow-x: auto;
    justify-content: flex-start;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }
  .subject-switch::-webkit-scrollbar {
    display: none;
  }
  .nav-link.subject-link {
    flex: 1;
    min-width: 62px;
    padding: 0 12px;
  }
  .page-links {
    width: max-content;
    min-width: 100%;
    justify-content: flex-start;
    gap: 1px;
    padding: 2px;
  }
  .page-links .nav-link {
    min-height: 40px;
    padding: 0 9px;
    font-size: 12px;
  }
  .nav-link.resource-search-btn {
    min-height: 40px;
    margin-left: 0;
    padding: 0 10px;
  }
  .nav-link.resource-search-btn::before {
    width: 17px;
    height: 17px;
  }
  .home {
    width: calc(100% - 24px);
    padding: 16px 0 46px;
  }
  .hero {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 20px;
    min-height: 0;
    padding: 25px 18px 18px;
    border-radius: 25px;
  }
  .hero h1 {
    font-size: clamp(28px, 8.2vw, 36px);
    line-height: 1.08;
  }
  .hero h1::after {
    margin-top: 10px;
    width: 72%;
  }
  .hero .lede {
    font-size: 14px;
    line-height: 1.78;
    white-space: normal;
  }
  .eyebrow {
    font-size: 11.5px;
  }
  .eyebrow::before {
    width: 18px;
    height: 18px;
  }
  .hero-actions {
    flex-direction: column;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .quiet-link {
    margin-top: -4px;
    text-align: center;
    font-size: 12.5px;
  }
  .knowledge-island {
    width: 100%;
    min-height: 310px;
    margin: 6px 0 0;
  }
  .island-orbit {
    width: min(272px, 84vw);
  }
  .island-core {
    width: 143px;
    min-height: 143px;
  }
  .island-core img {
    width: 46px;
    height: 46px;
  }
  .island-core strong {
    font-size: 16px;
  }
  .island-core span {
    font-size: 10px;
  }
  .island-node {
    width: 80px;
    min-height: 82px;
    border-radius: 18px;
  }
  .island-node img {
    width: 37px;
    height: 37px;
  }
  .island-node-math { left: 0; top: 11%; }
  .island-node-chinese { right: -2px; top: 10%; }
  .island-node-english { left: -1px; bottom: 5%; }
  .island-node-physics { right: -2px; bottom: 4%; }
  .island-mascot {
    right: 2%;
    top: 39%;
    width: 64px;
    height: 64px;
  }
  .section-title {
    margin: 34px 0 14px;
    font-size: 21px;
  }
  .section-title::before {
    width: 9px;
    height: 23px;
  }
  .steps {
    gap: 12px;
  }
  .steps li {
    min-height: 0;
    padding: 19px;
  }
  .steps h3 {
    margin-top: 12px;
  }
  .stat-grid {
    gap: 10px;
  }
  .stat-card {
    min-height: 128px;
    padding: 18px 13px 14px;
    border-radius: 18px;
  }
  .stat-card::before {
    width: 37px;
    height: 37px;
    right: 9px;
    top: 10px;
  }
  .stat-num {
    font-size: 29px;
  }
  .stat-label {
    margin-top: 29px;
    font-size: 12px;
  }
  .stat-note {
    font-size: 11.5px;
  }
  .grade-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  a.grade-card {
    min-height: 125px;
    padding: 14px 13px;
  }
  a.grade-card strong {
    font-size: 17px;
  }
  a.iq-card {
    padding: 17px 72px 17px 17px;
    border-radius: 18px;
  }
  .card {
    padding: 17px 14px;
    border-radius: 19px;
  }
  .stage-tabs {
    gap: 3px;
    padding: 3px;
  }
  .stage-tab {
    flex: 0 1 auto;
    min-height: 36px;
    padding: 5px 12px;
    white-space: nowrap;
  }
  .depth,
  .zoom-tools,
  .seg {
    gap: 3px;
  }
  .graph-toolbar {
    padding: 7px 8px;
    gap: 5px;
  }
  .graph-toolbar button {
    min-height: 37px;
    padding: 5px 10px;
    font-size: 11.5px;
  }
  .graph-toolbar .seg,
  .graph-toolbar .seg button {
    border-radius: 50px !important;
  }
  .graph-toolbar .seg {
    padding: 2px;
    border: 0;
    background: transparent;
    gap: 3px;
  }
  .graph-toolbar .seg button {
    margin-left: 0;
    border: 1.5px solid var(--island-line);
  }
  .zoom-icon {
    display: none;
  }
  .graph-empty {
    min-height: 319px;
    padding: 18px 16px;
  }
  .graph-empty::before {
    width: 56px;
    height: 56px;
  }
  .graph-empty p:nth-of-type(2) {
    display: none;
  }
  .graph-empty p {
    font-size: 12px;
    line-height: 1.62;
  }
  .legend {
    gap: 5px 9px;
    padding: 7px 10px 2px;
    font-size: 10.5px;
  }
  .graph-meta {
    padding: 4px 10px 8px;
  }
  main#root {
    padding: 18px 11px 46px;
  }
  .banner {
    padding: 13px 14px 13px 52px;
    font-size: 12.5px;
  }
  .banner::before {
    width: 32px;
    height: 32px;
    left: 11px;
    top: 10px;
  }
  .q-title {
    font-size: 20px;
  }
  .q-text {
    padding: 14px;
    font-size: 15px;
  }
  button.choice {
    min-height: 53px;
    padding: 12px 14px;
    font-size: 14px;
  }
  .stat {
    flex: 1 1 100px;
    min-height: 76px;
  }
  .stat b {
    font-size: 23px;
  }
  .share-panel {
    border-radius: 23px 23px 0 0;
  }
  main.kids {
    padding: 23px 12px 48px;
  }
  .kids h1 {
    font-size: 27px;
  }
  .kids h1::before {
    width: 35px;
    height: 35px;
    vertical-align: -6px;
  }
  .kids > .lede {
    font-size: 14px;
  }
  .kid-card {
    min-height: 0;
    padding: 18px 93px 18px 17px;
  }
  .kid-card::after {
    width: 75px;
    height: 75px;
    right: 9px;
  }
  .kid-card .kid-actions {
    grid-column: 1 / -1;
    flex-direction: column;
  }
  .kid-actions button,
  .kid-actions a {
    width: 100%;
    justify-content: center;
  }
  .kid-form {
    padding: 18px 14px;
  }
  .kid-picker {
    padding: 12px;
  }
  .pwa-sheet {
    border-radius: 23px 23px 0 0;
  }
  .pwa-bar {
    border-radius: 20px;
  }
}

@media (max-width: 420px) {
  .brand-name {
    font-size: 14px;
  }
  .brand-kicker {
    display: none;
  }
  .page-links .nav-link {
    padding: 0 7px;
    font-size: 11.5px;
  }
  .subject-switch {
    justify-content: space-between;
  }
  .nav-link.subject-link {
    min-width: auto;
    padding: 0 8px;
    font-size: 12px;
  }
  .hero {
    padding: 22px 15px 14px;
  }
  .hero h1 {
    font-size: 30px;
  }
  .knowledge-island {
    min-height: 288px;
  }
  .island-orbit {
    width: 247px;
  }
  .island-core {
    width: 128px;
    min-height: 128px;
    padding: 13px 8px;
  }
  .island-core img {
    width: 43px;
    height: 43px;
  }
  .island-node {
    width: 75px;
    min-height: 78px;
    padding: 6px 3px;
  }
  .island-node img {
    width: 35px;
    height: 35px;
  }
  .island-mascot {
    width: 59px;
    height: 59px;
  }
  .stat-card {
    min-height: 120px;
  }
  .stat-card::before {
    width: 32px;
    height: 32px;
  }
  .stat-num {
    font-size: 25px;
  }
  .stat-label {
    margin-top: 25px;
    font-size: 11.5px;
  }
  .kid-card {
    padding-right: 15px;
  }
  .kid-card::after {
    display: none;
  }
}

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

/* Homepage value-first refresh: one promise, one path, four subject doors. */
.page-home .home {
  width: min(1180px, calc(100% - 40px));
  padding-top: 36px;
}
.page-home .hero {
  grid-template-columns: minmax(0, 1.08fr) minmax(390px, .92fr);
  gap: 28px;
  min-height: 520px;
  padding: 46px 48px;
}
.hero-copy {
  position: relative;
  z-index: 8;
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.hero-brand-lockup {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
  color: var(--island-ink);
}
.hero-brand-lockup > img {
  width: 68px;
  height: 68px;
  object-fit: contain;
  padding: 4px;
  border: 2px solid #84664b;
  border-radius: 50%;
  background: #fff8dc;
  box-shadow: 0 5px 0 rgba(121, 79, 39, .18), 0 12px 24px rgba(61, 52, 40, .08);
  filter: drop-shadow(0 3px 2px rgba(61, 52, 40, .09));
}
.hero-brand-lockup span,
.hero-brand-lockup strong,
.hero-brand-lockup small {
  display: block;
}
.hero-brand-lockup strong {
  font-size: 30px;
  font-weight: 900;
  letter-spacing: -.035em;
  line-height: 1.05;
}
.hero-brand-lockup small {
  margin-top: 5px;
  color: #00897b;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: .055em;
}
.page-home .hero .eyebrow {
  width: max-content;
  margin: 0 0 16px;
  padding: 7px 13px 7px 10px;
  border: 1.5px solid #b9dfb0;
  border-radius: 999px;
  background: #eef8df;
  color: #4b9137;
  box-shadow: 0 3px 0 #d4e7c0;
  font-size: 13px;
  line-height: 1.2;
}
.page-home .hero .eyebrow::before {
  width: 22px;
  height: 22px;
}
.page-home .hero h1 {
  max-width: 590px;
  margin: 0;
  font-size: clamp(42px, 3.7vw, 52px);
  line-height: 1.06;
  letter-spacing: -.058em;
  white-space: nowrap;
}
.page-home .hero h1::after {
  width: min(300px, 56%);
  margin-top: 12px;
}
.page-home .hero .lede {
  max-width: 570px;
  margin: 17px 0 0;
  color: var(--island-body);
  font-size: 17px;
  line-height: 1.65;
  white-space: normal;
}
.page-home .hero-actions {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 24px;
}
.page-home .hero-actions .btn,
.graph-picker > summary {
  min-width: 166px;
  min-height: 52px;
}
.page-home .quiet-link {
  margin-top: 17px;
}

.graph-picker {
  position: relative;
  z-index: 20;
}
.graph-picker > summary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  list-style: none;
  cursor: pointer;
}
.graph-picker > summary::-webkit-details-marker {
  display: none;
}
.graph-picker > summary::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform .2s var(--island-ease);
}
.graph-picker[open] > summary::after {
  transform: translateY(2px) rotate(225deg);
}
.graph-subjects {
  position: absolute;
  z-index: 30;
  left: calc(100% + 4px);
  top: 50%;
  width: 344px;
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 11px;
  border: 1.5px solid var(--island-line);
  border-radius: 20px;
  background: rgba(255, 253, 244, .98);
  box-shadow: 0 16px 36px rgba(61, 52, 40, .17);
  transform: translateY(-50%);
  backdrop-filter: blur(14px);
}
.graph-picker::after {
  content: "";
  position: absolute;
  left: 100%;
  top: -12px;
  width: 12px;
  height: calc(100% + 24px);
}
.graph-picker[open] > .graph-subjects,
.graph-picker:focus-within > .graph-subjects {
  display: grid;
}
@media (hover: hover) and (pointer: fine) {
  .graph-picker:hover > .graph-subjects {
    display: grid;
  }
}
.graph-subject-link {
  min-width: 0;
  min-height: 66px;
  display: grid;
  grid-template-columns: 43px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1.5px solid transparent;
  border-radius: 15px;
  color: var(--island-ink);
  text-decoration: none;
  transition: transform .18s var(--island-ease), border-color .18s var(--island-ease), box-shadow .18s var(--island-ease);
}
.graph-subject-link.tone-mint { background: #e5f8f3; }
.graph-subject-link.tone-pink { background: #fde7e9; }
.graph-subject-link.tone-blue { background: #e8edff; }
.graph-subject-link.tone-yellow { background: #fff1be; }
.graph-subject-link:hover,
.graph-subject-link:focus-visible {
  border-color: #84664b;
  color: var(--island-ink);
  box-shadow: 0 3px 0 rgba(121, 79, 39, .13);
  transform: translateY(-1px);
}
.graph-subject-link img {
  width: 43px;
  height: 43px;
  object-fit: contain;
  filter: drop-shadow(0 3px 2px rgba(61, 52, 40, .12));
}
.graph-subject-link span,
.graph-subject-link strong,
.graph-subject-link small {
  display: block;
}
.graph-subject-link strong {
  font-size: 14px;
  font-weight: 900;
}
.graph-subject-link small {
  margin-top: 2px;
  color: var(--island-muted);
  font-size: 9px;
  font-weight: 700;
}

.page-home .knowledge-island {
  grid-column: 2;
  grid-row: 1;
  min-height: 430px;
  margin: -4px -10px -4px 0;
}

.journey-section,
.subjects-section {
  margin-top: 56px;
}
.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 26px;
  margin-bottom: 20px;
}
.section-heading > div {
  min-width: 0;
}
.section-heading > p {
  max-width: 390px;
  margin: 0 0 3px;
  color: var(--island-muted);
  font-size: 14px;
  line-height: 1.6;
  text-align: right;
}
.section-kicker {
  display: block;
  margin: 0 0 5px 24px;
  color: #00897b;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .18em;
}
.section-heading .section-title {
  margin: 0;
  font-size: 29px;
}

.page-home .steps {
  position: relative;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 34px;
}
.page-home .steps::before {
  content: "";
  position: absolute;
  left: 14%;
  right: 14%;
  top: 50%;
  border-top: 2px dashed rgba(25, 200, 185, .35);
}
.page-home .steps li {
  position: relative;
  z-index: 1;
  min-height: 142px;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  align-items: center;
  gap: 0 16px;
  padding: 20px 18px;
  overflow: visible;
  border: 2px solid #765941;
  border-radius: 22px;
  box-shadow: 0 6px 0 #d8c9ae;
}
.page-home .steps li::after {
  content: "›";
  position: absolute;
  z-index: 3;
  right: -27px;
  top: 50%;
  width: 22px;
  height: 36px;
  border: 0;
  border-radius: 0;
  background: none;
  color: #19a99b;
  font-size: 34px;
  font-weight: 900;
  line-height: 1;
  transform: translateY(-50%);
  opacity: .72;
}
.page-home .steps li:last-child::after {
  display: none;
}
.page-home .steps li:hover {
  transform: translateY(-3px);
  box-shadow: 0 9px 0 #d8c9ae;
}
.step-icon {
  grid-row: 1 / span 2;
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border: 1.5px solid rgba(121, 79, 39, .12);
  border-radius: 19px;
  background: rgba(255, 253, 244, .72);
}
.step-icon img {
  width: 53px;
  height: 53px;
  object-fit: contain;
  filter: drop-shadow(0 4px 3px rgba(61, 52, 40, .13));
}
.page-home .step-no {
  position: absolute;
  right: 14px;
  top: 12px;
  width: auto;
  height: auto;
  border: 0;
  background: transparent;
  color: rgba(121, 79, 39, .45);
  font-size: 12px;
  letter-spacing: .08em;
}
.page-home .steps h3 {
  margin: 7px 0 4px;
  font-size: 20px;
  font-weight: 900;
}
.page-home .steps p {
  max-width: 18em;
  font-size: 13px;
  line-height: 1.5;
}

.subject-catalog {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.subject-card {
  min-width: 0;
  min-height: 202px;
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr);
  grid-template-rows: auto 1fr auto;
  align-items: center;
  gap: 8px 12px;
  padding: 18px 17px 16px;
  border: 2px solid #765941;
  border-radius: 22px;
  color: var(--island-ink);
  text-decoration: none;
  box-shadow: 0 6px 0 #d8c9ae;
  transition: transform .18s var(--island-ease), box-shadow .18s var(--island-ease);
}
.subject-card.tone-mint { background: #e2f7ef; }
.subject-card.tone-pink { background: #ffe6ef; }
.subject-card.tone-blue { background: #e1efff; }
.subject-card.tone-yellow { background: #fff1b9; }
.subject-card:hover,
.subject-card:focus-visible {
  color: var(--island-ink);
  transform: translateY(-3px);
  box-shadow: 0 9px 0 #765941, 0 15px 24px rgba(61, 52, 40, .08);
}
.subject-card:active {
  transform: translateY(4px);
  box-shadow: 0 2px 0 #765941;
}
.subject-card > img {
  grid-row: 1 / span 2;
  width: 60px;
  height: 60px;
  object-fit: contain;
  filter: drop-shadow(0 4px 3px rgba(61, 52, 40, .14));
}
.subject-card > span,
.subject-card > span > * {
  display: block;
}
.subject-card > span > small {
  color: #00897b;
  font-size: 12px;
  font-weight: 900;
}
.subject-card > span > strong {
  margin-top: 2px;
  font-size: 18px;
  font-weight: 900;
}
.subject-card > span > em {
  margin-top: 8px;
  color: var(--island-body);
  font-size: 11px;
  font-style: normal;
  line-height: 1.45;
}
.subject-card > b {
  grid-column: 1 / span 2;
  display: flex;
  align-items: baseline;
  gap: 5px;
  padding-top: 10px;
  border-top: 1px dashed rgba(121, 79, 39, .2);
  color: #6e5846;
  font-size: 24px;
  font-weight: 900;
}
.subject-card > b small {
  font-size: 10px;
}
.subject-card > i {
  display: none;
}
.coverage-strip {
  margin-top: 20px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 15px 18px;
  border: 1.5px solid rgba(121, 79, 39, .14);
  border-radius: 20px;
  background: rgba(255, 253, 244, .72);
  box-shadow: 0 4px 0 rgba(121, 79, 39, .08);
}
.coverage-strip > div {
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border-left: 1px dashed rgba(121, 79, 39, .20);
}
.coverage-strip > div:first-child {
  border-left: 0;
}
.coverage-strip strong {
  color: var(--island-ink);
  font-size: 25px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}
.coverage-strip span {
  color: var(--island-muted);
  font-size: 12px;
  font-weight: 700;
}

@media (prefers-reduced-motion: no-preference) {
  .hero-copy > * {
    animation: island-rise .55s var(--island-ease) both;
  }
  .hero-copy > :nth-child(2) { animation-delay: .05s; }
  .hero-copy > :nth-child(3) { animation-delay: .10s; }
  .hero-copy > :nth-child(4) { animation-delay: .15s; }
  .hero-copy > :nth-child(5) { animation-delay: .20s; }
  .hero-copy > :nth-child(6) { animation-delay: .25s; }
}

@media (max-width: 1050px) {
  .page-home .hero {
    grid-template-columns: minmax(0, 1fr) minmax(300px, .78fr);
    padding: 38px 32px;
  }
  .page-home .hero h1 {
    font-size: clamp(37px, 4.3vw, 46px);
  }
  .hero-brand-lockup > img {
    width: 60px;
    height: 60px;
  }
  .hero-brand-lockup strong {
    font-size: 27px;
  }
  .graph-subjects {
    left: auto;
    right: 0;
    top: calc(100% + 8px);
    transform: none;
  }
  .subject-catalog {
    grid-template-columns: 1fr 1fr;
  }
  .subject-card {
    min-height: 168px;
  }
}

@media (max-width: 760px) {
  .page-home .home {
    width: calc(100% - 24px);
    padding-top: 16px;
  }
  .page-home .hero {
    display: flex;
    flex-direction: column;
    gap: 22px;
    min-height: 0;
    padding: 24px 18px 20px;
    border-radius: 26px;
  }
  .hero-copy {
    width: 100%;
    align-items: stretch;
  }
  .hero-brand-lockup {
    width: max-content;
    margin: 0 auto 22px;
  }
  .hero-brand-lockup > img {
    width: 58px;
    height: 58px;
  }
  .hero-brand-lockup strong {
    font-size: 26px;
  }
  .hero-brand-lockup small {
    font-size: 12px;
  }
  .page-home .hero .eyebrow {
    margin: 0 auto 16px;
  }
  .page-home .hero h1 {
    max-width: none;
    font-size: clamp(30px, 8.4vw, 39px);
    text-align: center;
    white-space: normal;
  }
  .page-home .hero h1::after {
    margin-right: auto;
    margin-left: auto;
  }
  .page-home .hero .lede {
    max-width: 500px;
    margin-right: auto;
    margin-left: auto;
    font-size: 15px;
    line-height: 1.65;
    text-align: center;
  }
  .page-home .hero-actions {
    width: 100%;
    flex-direction: column;
    margin-top: 21px;
  }
  .page-home .hero-actions .btn,
  .graph-picker,
  .graph-picker > summary {
    width: 100%;
  }
  .graph-subjects {
    position: static;
    width: 100%;
    margin-top: 10px;
    transform: none;
  }
  .graph-picker::after {
    display: none;
  }
  .page-home .quiet-link {
    text-align: center;
  }
  .page-home .knowledge-island {
    display: none;
  }
  .journey-section,
  .subjects-section {
    margin-top: 40px;
  }
  .section-heading {
    display: block;
    margin-bottom: 16px;
  }
  .section-heading > p {
    margin: 9px 0 0 21px;
    max-width: 32em;
    font-size: 12.5px;
    text-align: left;
  }
  .section-kicker {
    margin-left: 20px;
  }
  .section-heading .section-title {
    font-size: 23px;
  }
  .page-home .steps {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .page-home .steps::before {
    left: 46px;
    right: auto;
    top: 12%;
    bottom: 12%;
    border-top: 0;
    border-left: 2px dashed rgba(25, 200, 185, .35);
  }
  .page-home .steps li {
    min-height: 112px;
    grid-template-columns: 64px minmax(0, 1fr);
    padding: 16px;
  }
  .page-home .steps li::after {
    display: none;
  }
  .step-icon {
    width: 64px;
    height: 64px;
  }
  .step-icon img {
    width: 47px;
    height: 47px;
  }
  .page-home .steps h3 {
    margin-top: 4px;
    font-size: 18px;
  }
  .subject-catalog {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .subject-card {
    min-height: 118px;
    grid-template-columns: 58px minmax(0, 1fr) auto;
    grid-template-rows: 1fr;
    gap: 10px;
    padding: 14px;
  }
  .subject-card > img {
    grid-row: 1;
    width: 55px;
    height: 55px;
  }
  .subject-card > span > em {
    margin-top: 5px;
  }
  .subject-card > b {
    grid-column: 3;
    display: block;
    min-width: 52px;
    padding: 0;
    border: 0;
    text-align: right;
    font-size: 21px;
  }
  .subject-card > b small {
    display: block;
    margin-top: 2px;
  }
  .coverage-strip {
    grid-template-columns: 1fr 1fr;
    padding: 8px;
  }
  .coverage-strip > div {
    min-height: 62px;
    border-left: 0;
  }
  .coverage-strip > div:nth-child(even) {
    border-left: 1px dashed rgba(121, 79, 39, .20);
  }
  .coverage-strip > div:nth-child(n+3) {
    border-top: 1px dashed rgba(121, 79, 39, .20);
  }
  .coverage-strip strong {
    font-size: 22px;
  }
}

@media (max-width: 420px) {
  .hero-brand-lockup {
    gap: 10px;
  }
  .hero-brand-lockup > img {
    width: 52px;
    height: 52px;
  }
  .hero-brand-lockup strong {
    font-size: 23px;
  }
  .hero-brand-lockup small {
    font-size: 10.5px;
  }
  .page-home .hero .eyebrow {
    padding-right: 10px;
    font-size: 11px;
  }
  .graph-subjects {
    grid-template-columns: 1fr;
  }
  .graph-subject-link {
    min-height: 58px;
  }
  .subject-card > span > strong {
    font-size: 16px;
  }
  .subject-card > span > em {
    font-size: 10px;
  }
}

@media print {
  :root {
    --island-paper: #fff;
    --island-card: #fff;
    --island-content: #f8f5ed;
    --island-ink: #4f3d2d;
    --island-body: #5d4d3c;
    --island-muted: #746756;
    --island-line: #d8ccb8;
  }
  body {
    background: #fff;
  }
  .top-banner,
  .site-header,
  .site-footer,
  .pwa-bar,
  .pwa-sheet-wrap {
    display: none !important;
  }
  .card,
  .kid-card,
  .kid-form,
  .rec {
    break-inside: avoid;
    box-shadow: none;
  }
}
