:root {
  --ink: #173c45;
  --muted: #668086;
  --paper: #fffdf8;
  --cream: #fff7e9;
  --line: #e7ece8;
  --coral: #ff7657;
  --coral-dark: #e6533b;
  --yellow: #ffd66b;
  --mint: #76d8ca;
  --mint-dark: #178f82;
  --blue: #6c8cff;
  --purple: #a56ae8;
  --pink: #ef6f9a;
  --shadow: 0 16px 45px rgba(33, 74, 72, 0.12);
  --shadow-soft: 0 8px 24px rgba(33, 74, 72, 0.08);
  color-scheme: light;
  font-family: Pretendard, "Apple SD Gothic Neo", "Noto Sans KR", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { min-height: 100%; overflow-x: hidden; background: var(--cream); }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 5% 8%, rgba(255, 214, 107, .4), transparent 24rem),
    radial-gradient(circle at 95% 18%, rgba(118, 216, 202, .28), transparent 25rem),
    var(--cream);
}

button, input, textarea { font: inherit; }
button { color: inherit; }
button, [role="button"], label[for] { -webkit-tap-highlight-color: transparent; }
button:focus-visible, input:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 4px solid rgba(108, 140, 255, .32);
  outline-offset: 2px;
}

img { display: block; max-width: 100%; }

.boot-screen {
  min-height: 100vh;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 14px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 16px;
  background: var(--coral);
  box-shadow: 0 8px 0 rgba(181, 65, 43, .15);
  font-size: 25px;
  transform: rotate(-3deg);
}
.brand-mark--large { width: 76px; height: 76px; border-radius: 24px; font-size: 40px; }

.toast {
  position: fixed;
  z-index: 100;
  left: 50%;
  bottom: 90px;
  width: max-content;
  max-width: calc(100vw - 32px);
  padding: 13px 20px;
  border-radius: 999px;
  color: white;
  background: var(--ink);
  box-shadow: var(--shadow);
  font-weight: 800;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 15px);
  transition: .25s ease;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.perfect-celebration { position: fixed; z-index: 220; inset: 0; display: grid; place-items: center; overflow: hidden; padding: 22px; background: radial-gradient(circle at 50% 38%, rgba(56, 92, 161, .5), rgba(7, 27, 52, .94) 72%); opacity: 0; pointer-events: none; transition: opacity .28s ease; }
.perfect-celebration.is-visible { opacity: 1; pointer-events: auto; }
.celebration-card { position: relative; z-index: 4; width: min(440px, 90vw); padding: 38px 28px 28px; border: 3px solid rgba(255,255,255,.86); border-radius: 32px; background: linear-gradient(145deg, #fffdf3, #fff 55%, #e7fbf6); box-shadow: 0 28px 80px rgba(0,0,0,.38), 0 0 0 10px rgba(255,255,255,.1); text-align: center; transform: translateY(28px) scale(.72) rotate(-2deg); transition: transform .55s cubic-bezier(.16, 1.32, .42, 1); }
.perfect-celebration.is-visible .celebration-card { transform: translateY(0) scale(1) rotate(0); }
.celebration-crown { display: block; margin-top: -12px; font-size: clamp(64px, 18vw, 92px); filter: drop-shadow(0 10px 0 rgba(236, 172, 37, .2)); animation: celebration-crown 1s ease-in-out infinite alternate; }
.celebration-stars { margin: -4px 0 8px; font-size: 24px; letter-spacing: 6px; }
.celebration-card > small { color: var(--coral-dark); font-size: 12px; font-weight: 1000; letter-spacing: .16em; }
.celebration-card h2 { margin: 7px 0 9px; color: var(--ink); font-size: clamp(30px, 8vw, 46px); letter-spacing: -.06em; }
.celebration-card p { margin: 0 0 23px; color: #47636a; font-size: 16px; line-height: 1.65; }
.celebration-card p strong { color: var(--mint-dark); font-size: 22px; }
.celebration-close { width: 100%; }
.celebration-confetti-layer { position: absolute; z-index: 2; inset: 0; pointer-events: none; }
.celebration-confetti { position: absolute; left: var(--left); top: -12vh; width: 10px; height: 20px; border-radius: 3px; background: var(--color); box-shadow: 0 0 8px rgba(255,255,255,.35); animation: celebration-confetti var(--duration) linear var(--delay) infinite; }
.celebration-firework { position: absolute; z-index: 3; left: var(--x); top: var(--y); width: 1px; height: 1px; pointer-events: none; }
.celebration-firework > i { position: absolute; left: 0; top: 0; width: 8px; height: 8px; border-radius: 50%; background: var(--color); box-shadow: 0 0 10px var(--color); opacity: 0; animation: celebration-firework 1.8s ease-out var(--delay) 3; }
@keyframes celebration-confetti { from { transform: translate3d(0, -10vh, 0) rotate(0); } to { transform: translate3d(var(--drift), 122vh, 0) rotate(var(--turn)); } }
@keyframes celebration-firework { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.15); } 14% { opacity: 1; } 72% { opacity: 1; transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(1); } 100% { opacity: 0; transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(.25); } }
@keyframes celebration-crown { from { transform: translateY(0) rotate(-4deg); } to { transform: translateY(-8px) rotate(4deg); } }
.audio-dock {
  position: fixed;
  z-index: 90;
  left: 50%;
  bottom: 24px;
  display: none;
  width: min(620px, calc(100vw - 28px));
  align-items: center;
  gap: 12px;
  padding: 11px 13px;
  border: 1px solid rgba(23, 60, 69, .12);
  border-radius: 18px;
  background: rgba(255, 255, 255, .96);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transform: translateX(-50%);
}
.audio-dock.is-visible { display: flex; }
.audio-dock > span { white-space: nowrap; font-size: 12px; font-weight: 900; }
.audio-dock audio { width: 100%; min-width: 120px; height: 38px; }
.audio-dock button { display: grid; width: 30px; height: 30px; flex: 0 0 auto; place-items: center; border: 0; border-radius: 10px; background: #edf2ef; font-size: 20px; cursor: pointer; }

.auth-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(320px, 1.05fr) minmax(360px, .95fr);
  align-items: center;
  gap: clamp(32px, 6vw, 100px);
  max-width: 1180px;
  margin: auto;
  padding: 52px 34px;
  overflow: hidden;
}

.auth-intro h1 {
  margin: 22px 0 12px;
  font-size: clamp(48px, 7vw, 84px);
  letter-spacing: -.07em;
  line-height: .96;
}
.auth-intro h1 em { color: var(--coral); font-style: normal; }
.auth-intro > p { max-width: 480px; margin: 0; color: var(--muted); font-size: 19px; line-height: 1.7; }
.auth-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.auth-badges span { padding: 9px 13px; border: 1px solid rgba(23, 60, 69, .08); border-radius: 999px; background: rgba(255, 255, 255, .7); font-size: 14px; font-weight: 800; }

.laptop { position: relative; width: min(100%, 570px); margin: 0 auto 50px; }
.laptop-screen {
  position: relative;
  z-index: 2;
  min-height: 540px;
  padding: 18px;
  border: 12px solid #284750;
  border-bottom-width: 20px;
  border-radius: 30px 30px 18px 18px;
  background: linear-gradient(155deg, #fffdf8, #fff8e9);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.laptop-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(125deg, rgba(255,255,255,.8), transparent 35%);
  pointer-events: none;
}
.laptop-base {
  position: absolute;
  z-index: 1;
  left: -8%;
  right: -8%;
  bottom: -34px;
  height: 56px;
  border-radius: 8px 8px 30px 30px;
  background: linear-gradient(#dce8e5, #a8bdbd);
  box-shadow: 0 18px 28px rgba(23, 60, 69, .17);
}
.laptop-base::after { content: ""; position: absolute; top: 0; left: 40%; width: 20%; height: 13px; border-radius: 0 0 12px 12px; background: #91a9a9; }

.auth-card { min-height: 496px; padding: clamp(18px, 4vw, 34px); }
.auth-card__eyebrow, .eyebrow { color: var(--coral-dark); font-size: 13px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.auth-card h2 { margin: 8px 0 6px; font-size: clamp(26px, 4vw, 36px); letter-spacing: -.04em; }
.auth-card > p { margin: 0 0 22px; color: var(--muted); line-height: 1.55; }

.profile-picker { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 18px; }
.profile-choice {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 2px solid transparent;
  border-radius: 18px;
  background: white;
  box-shadow: 0 4px 14px rgba(33, 74, 72, .06);
  cursor: pointer;
  transition: transform .18s, border-color .18s, box-shadow .18s;
}
.profile-choice > span:last-child { min-width: 0; }
.profile-choice:hover { transform: translateY(-2px); }
.profile-choice.is-selected { border-color: var(--coral); box-shadow: 0 7px 18px rgba(255, 118, 87, .16); }
.profile-choice strong { display: block; font-size: 15px; }
.profile-choice small { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; }

.avatar {
  flex: 0 0 auto;
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border: 3px solid white;
  border-radius: 18px;
  background: #ffb39e;
  box-shadow: 0 4px 10px rgba(23, 60, 69, .12);
  font-size: 27px;
  overflow: hidden;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.profile-character-sprite { position: relative; display: block; width: 100%; height: 100%; overflow: hidden; }
.profile-character-sprite > img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.profile-reporter-figure .profile-character-sprite > img, .profile-character-choice .profile-character-sprite > img { object-fit: contain; background: #edf3f0; }
.avatar .profile-character-sprite > img { object-position: center 24%; }
.avatar--small { width: 42px; height: 42px; border-radius: 14px; font-size: 22px; }
.avatar--mini { width: 28px; height: 28px; border-width: 2px; border-radius: 9px; font-size: 15px; }
.avatar--large { width: 104px; height: 104px; border-radius: 32px; font-size: 52px; }
.tone-0 { background: #ffb39e; }
.tone-1 { background: #aebdff; }
.tone-2 { background: #96e5d9; }
.tone-3 { background: #d0a9ef; }
.tone-4 { background: #ffe08d; }
.tone-5 { background: #f5a9c2; }

.field { display: grid; gap: 7px; margin: 14px 0; }
.field > span { font-size: 13px; font-weight: 900; }
.input {
  width: 100%;
  min-height: 50px;
  padding: 13px 15px;
  border: 2px solid var(--line);
  border-radius: 15px;
  color: var(--ink);
  background: white;
  transition: border-color .18s, box-shadow .18s;
}
.input:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(108, 140, 255, .12); outline: 0; }
textarea.input { min-height: 140px; resize: vertical; line-height: 1.6; }

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  border: 0;
  border-radius: 15px;
  background: var(--coral);
  color: white;
  box-shadow: 0 7px 0 #d94f37;
  font-weight: 900;
  cursor: pointer;
  transform: translateY(-2px);
  transition: filter .15s, transform .15s, box-shadow .15s;
}
.button:hover { filter: brightness(1.03); }
.button:active { transform: translateY(4px); box-shadow: 0 1px 0 #d94f37; }
.button:disabled { opacity: .55; cursor: not-allowed; }
.button--wide { width: 100%; }
.button--secondary { background: var(--ink); box-shadow: 0 7px 0 #09272e; }
.button--mint { background: var(--mint-dark); box-shadow: 0 7px 0 #0b6f65; }
.button--soft { background: white; color: var(--ink); border: 2px solid var(--line); box-shadow: 0 5px 0 #d8e1dc; }
.button--small { min-height: 40px; padding: 8px 13px; border-radius: 12px; font-size: 13px; box-shadow: none; transform: none; }
.text-button { padding: 8px; border: 0; color: var(--muted); background: transparent; font-weight: 800; cursor: pointer; }

.setup-members { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.setup-note { padding: 12px 14px; border-radius: 13px; background: #fff3c7; color: #785e12; font-size: 12px; line-height: 1.5; }
.error-message { min-height: 20px; margin: 8px 0; color: #c73e2a; font-size: 13px; font-weight: 800; }

.app-shell { min-height: 100vh; padding-bottom: 32px; }
.topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid rgba(23, 60, 69, .07);
  background: rgba(255, 253, 248, .88);
  backdrop-filter: blur(18px);
}
.topbar__inner { display: flex; max-width: 1180px; height: 78px; align-items: center; gap: 32px; margin: auto; padding: 0 24px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand strong { display: block; font-size: 20px; letter-spacing: -.04em; }
.brand small { display: block; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .05em; }
.desktop-nav { display: flex; gap: 8px; margin-left: auto; }
.nav-link { display: flex; align-items: center; gap: 7px; padding: 10px 14px; border: 0; border-radius: 13px; color: var(--muted); background: transparent; font-weight: 900; cursor: pointer; }
.nav-link.is-active { color: var(--coral-dark); background: #fff0eb; }
.profile-chip { display: flex; align-items: center; gap: 9px; margin-left: 10px; padding: 5px 10px 5px 5px; border: 1px solid var(--line); border-radius: 17px; background: white; cursor: pointer; }
.profile-chip strong { display: block; font-size: 13px; }
.profile-chip small { display: block; color: var(--muted); font-size: 10px; }

.page { max-width: 1180px; margin: auto; padding: 34px 24px 60px; }
.page-heading { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 23px; }
.page-heading h1, .page-heading h2 { margin: 5px 0 0; font-size: clamp(28px, 5vw, 42px); letter-spacing: -.05em; }
.page-heading p { max-width: 520px; margin: 6px 0 0; color: var(--muted); line-height: 1.6; }

.welcome-hero {
  position: relative;
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  min-height: 330px;
  align-items: center;
  margin-bottom: 36px;
  padding: clamp(28px, 5vw, 56px);
  border-radius: 34px;
  background: linear-gradient(135deg, #173c45, #285c62);
  box-shadow: var(--shadow);
  color: white;
  overflow: hidden;
}
.welcome-hero::before { content: ""; position: absolute; width: 260px; height: 260px; right: -40px; top: -80px; border-radius: 50%; background: rgba(118, 216, 202, .23); }
.welcome-hero::after { content: ""; position: absolute; width: 180px; height: 180px; left: 48%; bottom: -120px; border-radius: 50%; background: rgba(255, 214, 107, .18); }
.welcome-copy { position: relative; z-index: 2; }
.welcome-copy .eyebrow { color: var(--yellow); }
.welcome-copy h1 { max-width: 650px; margin: 10px 0 14px; font-size: clamp(37px, 5vw, 62px); line-height: 1.06; letter-spacing: -.06em; }
.welcome-copy p { max-width: 550px; margin: 0 0 25px; color: #d6e5e5; font-size: 17px; line-height: 1.65; }
.welcome-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.welcome-visual { position: relative; z-index: 2; display: grid; place-items: center; }
.newspaper-mascot { position: relative; width: 230px; height: 230px; border-radius: 42% 58% 55% 45%; background: var(--yellow); transform: rotate(4deg); box-shadow: 0 18px 0 rgba(5, 32, 38, .22); }
.newspaper-mascot::before { content: "📰"; position: absolute; left: 50%; top: 46%; font-size: 118px; transform: translate(-50%, -50%) rotate(-5deg); filter: drop-shadow(0 8px 0 rgba(134, 92, 14, .15)); }
.newspaper-mascot::after { content: "오늘도 멋진 기자!"; position: absolute; right: -28px; bottom: -13px; padding: 10px 14px; border-radius: 14px 14px 3px 14px; background: white; color: var(--ink); font-size: 13px; font-weight: 900; transform: rotate(-3deg); }

.home-summary-card { display: grid; grid-template-columns: minmax(240px, 1fr) auto; align-items: center; gap: 18px 26px; margin-bottom: 24px; padding: 22px 24px; border: 1px solid rgba(23,60,69,.08); border-radius: 26px; background: linear-gradient(125deg, #173c45, #285c62); color: white; box-shadow: var(--shadow); }
.home-summary-person { display: flex; min-width: 0; align-items: center; gap: 15px; }
.home-summary-person .avatar { border: 3px solid rgba(255,255,255,.7); }
.home-summary-person .eyebrow { color: var(--yellow); }
.home-summary-person h1 { margin: 3px 0; font-size: clamp(24px, 4vw, 34px); letter-spacing: -.05em; }
.home-summary-person p { margin: 0; color: #d6e5e5; font-size: 12px; }
.home-summary-stats { display: grid; grid-template-columns: repeat(4, minmax(72px, auto)); gap: 7px; }
.home-summary-stats > span { display: grid; min-height: 62px; place-items: center; align-content: center; padding: 7px 10px; border-radius: 15px; background: rgba(255,255,255,.1); text-align: center; }
.home-summary-stats b { font-size: 17px; }
.home-summary-stats small { margin-top: 2px; color: #d6e5e5; font-size: 8px; }
.home-summary-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 9px; }
.home-summary-actions .text-button { color: white; }
.home-summary-card--compact { display: block; min-height: 116px; margin-bottom: 14px; padding: 8px 14px 7px 0; overflow: hidden; }
.home-summary-card--compact .home-summary-person { min-height: 112px; align-self: stretch; gap: 14px; }
.home-summary-content { display: grid; min-width: 0; flex: 1; grid-template-columns: minmax(180px, 1fr) minmax(300px, 440px); align-items: center; gap: 15px; }
.home-summary-copy { min-width: 0; }
.home-summary-card--compact .home-summary-person h1 { font-size: clamp(19px, 3vw, 27px); }
.profile-reporter-figure { display: block; width: 120px; height: 150px; flex: 0 0 auto; border: 3px solid #e53e3e; border-radius: 25px; background: white; box-shadow: 0 10px 26px rgba(12,34,42,.2); overflow: hidden; }
.home-profile-reporter { align-self: center; width: 82px; height: 123px; margin-left: 9px; padding: 0; border: 2px solid rgba(255,255,255,.92); border-radius: 22px; background: rgba(255,255,255,.94); box-shadow: 0 7px 17px rgba(12,34,42,.15); }
.home-profile-reporter .profile-character-sprite, .home-profile-reporter .profile-character-sprite > img { width: 100%; height: 100%; }
.home-profile-reporter .profile-character-sprite > img { object-fit: cover; object-position: center; background: transparent; }
.home-summary-card--compact .home-summary-actions { display: grid; width: 100%; grid-template-columns: minmax(0, 1.15fr) minmax(82px, .85fr); align-self: center; }
.home-summary-card--compact .home-summary-actions .button { display: flex; min-height: 42px; align-items: center; justify-content: center; gap: 7px; padding: 7px 12px; text-align: center; box-shadow: 0 3px 0 rgba(0,0,0,.14); }
.home-summary-card--compact .home-summary-actions .button > span { font-size: 20px; }
.home-summary-card--compact .home-summary-actions .button b { font-size: 14px; white-space: nowrap; }
.home-summary-card--compact .home-summary-actions .button small { font-size: 9px; font-weight: 800; opacity: .82; }
.home-create-button { background: linear-gradient(135deg, #ff795a, #ff5f55); box-shadow: 0 7px 0 #c74334; }
.home-read-button { color: var(--ink) !important; }
.home-news-section { margin-top: 30px; }
.home-group-news-section { margin-top: 18px; }
.home-group-photo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.home-group-photo-card { position: relative; display: grid; min-width: 0; aspect-ratio: 4 / 3; place-items: center; padding: 0; overflow: hidden; border: 0; border-radius: 15px; background: linear-gradient(135deg, #b9e9df, #fff0be); box-shadow: var(--shadow-soft); color: var(--ink); font-size: 38px; cursor: pointer; }
.home-group-photo-card img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; transition: transform .2s ease; }
.home-group-photo-card:hover img { transform: scale(1.025); }
.home-story-read-badge { position: absolute; right: 5px; bottom: 5px; z-index: 1; padding: 3px 5px; border-radius: 7px; background: #486d75; color: white; font-size: 8px; font-weight: 1000; line-height: 1; }
.home-group-photo-card.is-read .home-story-read-badge { background: rgba(255,255,255,.92); color: #617174; }

.onboarding-guide { position: fixed; z-index: 300; inset: 0; display: grid; place-items: center; padding: 18px; background: rgba(10, 35, 42, .72); backdrop-filter: blur(7px); }
.onboarding-card { position: relative; width: min(520px, 100%); overflow: hidden; padding: 24px 28px 22px; border: 3px solid rgba(255,255,255,.86); border-radius: 30px; background: linear-gradient(155deg, #fffdf5, #fff 56%, #eef9f6); box-shadow: 0 28px 80px rgba(4,24,31,.35); animation: onboarding-enter .32s cubic-bezier(.2,.85,.35,1.15); }
.onboarding-close { position: absolute; right: 16px; top: 14px; display: grid; width: 34px; height: 34px; place-items: center; padding: 0; border: 0; border-radius: 50%; background: #edf3f1; color: #50666b; font-size: 24px; line-height: 1; cursor: pointer; }
.onboarding-progress { display: flex; align-items: baseline; gap: 3px; color: var(--muted); font-size: 11px; font-weight: 900; }
.onboarding-progress b { color: var(--coral-dark); font-size: 18px; }
.onboarding-visual { display: grid; min-height: 225px; margin: 12px 0 18px; place-items: center; overflow: hidden; border-radius: 23px; background: linear-gradient(135deg, #dff7f0, #fff2bd 58%, #f2eaff); }
.onboarding-copy { text-align: center; }
.onboarding-copy > small { color: var(--coral-dark); font-size: 10px; font-weight: 1000; letter-spacing: .13em; }
.onboarding-copy h2 { margin: 5px 0 9px; font-size: clamp(25px, 6vw, 34px); letter-spacing: -.05em; }
.onboarding-copy p { max-width: 420px; margin: 0 auto; color: #4b666b; font-size: 14px; line-height: 1.65; }
.onboarding-dots { display: flex; justify-content: center; gap: 7px; margin: 18px 0; }
.onboarding-dots button { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 99px; background: #cbd7d4; cursor: pointer; transition: width .2s ease, background .2s ease; }
.onboarding-dots button.is-active { width: 27px; background: var(--coral); }
.onboarding-actions { display: flex; min-height: 44px; align-items: center; justify-content: space-between; gap: 10px; }
.onboarding-actions .button { min-width: 112px; box-shadow: 0 3px 0 rgba(0,0,0,.12); }
.onboarding-camera-visual, .onboarding-reporter-visual { display: grid; place-items: center; }
.onboarding-camera-visual img { width: 112px; height: 112px; border-radius: 25px; box-shadow: 0 12px 25px rgba(30,91,96,.18); }
.onboarding-camera-visual > span { margin: -25px -115px 0 0; font-size: 45px; filter: drop-shadow(0 5px 6px rgba(0,0,0,.18)); }
.onboarding-camera-visual b { margin-top: 8px; color: #315d61; font-size: 13px; }
.onboarding-reporter-visual img { width: 132px; height: 198px; object-fit: cover; border-radius: 22px; box-shadow: 0 12px 28px rgba(30,91,96,.2); }
.onboarding-reporter-visual span { position: absolute; margin-top: 170px; padding: 7px 11px; border-radius: 99px; background: rgba(255,255,255,.94); color: #315d61; box-shadow: var(--shadow-soft); font-size: 10px; font-weight: 1000; }
.onboarding-group-visual { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; width: min(390px, 88%); }
.onboarding-group-visual > span { display: grid; min-height: 105px; place-items: center; align-content: center; gap: 5px; padding: 14px 8px; border: 2px solid white; border-radius: 21px; background: rgba(255,255,255,.8); box-shadow: var(--shadow-soft); font-size: 38px; }
.onboarding-group-visual > span b { font-size: 12px; }
.onboarding-group-visual > i { color: var(--coral-dark); font-size: 24px; font-style: normal; font-weight: 1000; }
.onboarding-group-visual > em { grid-column: 1 / -1; justify-self: center; padding: 7px 13px; border-radius: 99px; background: #284f55; color: white; font-size: 11px; font-style: normal; font-weight: 900; }
.onboarding-level-visual { display: flex; width: min(420px, 92%); align-items: center; justify-content: center; gap: 7px; }
.onboarding-level-visual > span { display: grid; min-width: 86px; min-height: 92px; place-items: center; align-content: center; gap: 5px; padding: 10px; border: 2px solid white; border-radius: 19px; background: rgba(255,255,255,.84); box-shadow: var(--shadow-soft); }
.onboarding-level-visual > span:nth-of-type(2) { background: #edf2ff; }
.onboarding-level-visual > span:nth-of-type(3) { background: #f4edff; }
.onboarding-level-visual b { font-size: 15px; }
.onboarding-level-visual small { color: var(--muted); font-size: 8px; }
.onboarding-level-visual > i { color: #78918e; font-style: normal; }
.onboarding-rank-visual { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; width: min(410px, 90%); }
.onboarding-rank-visual > span { display: grid; min-height: 86px; place-items: center; align-content: center; gap: 4px; border: 2px solid white; border-radius: 18px; background: rgba(255,255,255,.82); box-shadow: var(--shadow-soft); color: #d66570; font-size: 31px; }
.onboarding-rank-visual > span b { color: var(--ink); font-size: 10px; }
.onboarding-rank-visual > em { grid-column: 1 / -1; color: #345e63; font-size: 25px; font-style: normal; letter-spacing: 3px; text-align: center; }
.profile-title-row { display: flex; align-items: center; gap: 12px; }
.profile-title-row h2 { margin: 0; }
.onboarding-help-button { flex: 0 0 auto; margin-left: auto; padding: 6px 10px; border: 1px solid #b8d9d1; border-radius: 99px; background: #effaf7; color: #2f7167; font-size: 10px; font-weight: 1000; cursor: pointer; }
@keyframes onboarding-enter { from { opacity: 0; transform: translateY(22px) scale(.94); } to { opacity: 1; transform: translateY(0) scale(1); } }

.quick-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 36px; }
.stat-card { display: flex; align-items: center; gap: 15px; padding: 18px; border: 1px solid rgba(23, 60, 69, .06); border-radius: 21px; background: rgba(255,255,255,.76); box-shadow: var(--shadow-soft); }
.stat-icon { display: grid; width: 48px; height: 48px; flex: 0 0 auto; place-items: center; border-radius: 16px; background: #fff0eb; font-size: 24px; }
.stat-card:nth-child(2) .stat-icon { background: #e3f8f3; }
.stat-card:nth-child(3) .stat-icon { background: #fff4ce; }
.stat-card strong { display: block; font-size: 23px; letter-spacing: -.04em; }
.rank-stat-card { background: linear-gradient(135deg, #fff7d9, #fff 58%, #f0eaff); }
.rank-stat-card .stat-icon { background: #efe5ff !important; }
.rank-card { position: relative; overflow: hidden; margin-bottom: 18px; border: 2px solid #eadfff; background: linear-gradient(135deg, #fff9df 0%, #fff 44%, #efeaff 100%); }
.rank-card::after { content: "✨"; position: absolute; right: 24px; top: 18px; font-size: 38px; opacity: .34; transform: rotate(12deg); }
.rank-current { position: relative; z-index: 1; display: flex; align-items: center; gap: 19px; }
.rank-current__icon { display: grid; width: 92px; height: 92px; flex: 0 0 auto; place-items: center; border: 3px solid rgba(255,255,255,.9); border-radius: 30px; background: linear-gradient(145deg, #ffe98c, #f0ddff); box-shadow: 0 10px 22px rgba(103, 73, 157, .16); font-size: 50px; }
.rank-current small { color: #7957b2; font-size: 11px; font-weight: 1000; letter-spacing: .08em; }
.rank-current h2 { margin: 3px 0 5px; font-size: clamp(27px, 5vw, 40px); }
.rank-current p { margin: 0; color: var(--muted); }
.rank-current p strong { color: var(--coral-dark); }
.rank-progress-copy { display: flex; justify-content: space-between; gap: 12px; margin: 23px 2px 8px; color: #675779; font-size: 12px; }
.rank-progress-copy strong { color: #7c55b2; }
.rank-progress-copy b { color: #7c55b2; }
.rank-progress-bar { height: 13px; overflow: hidden; border: 2px solid white; border-radius: 999px; background: #e9e2f2; box-shadow: inset 0 2px 4px rgba(68, 48, 91, .1); }
.rank-progress-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #ff8a65, #ffd166 45%, #8e6bd8); transition: width .7s ease; }
.rank-ladder { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-top: 20px; }
.rank-step { display: grid; min-width: 0; min-height: 112px; place-items: center; align-content: center; gap: 2px; padding: 9px 5px; border: 1px solid #e9e3ef; border-radius: 15px; background: rgba(255,255,255,.7); color: #9a90a4; text-align: center; }
.rank-step > span { font-size: 25px; filter: grayscale(1); opacity: .55; }
.rank-step b { font-size: 9px; letter-spacing: .05em; }
.rank-step strong { max-width: 100%; font-size: 10px; line-height: 1.25; }
.rank-step small { font-size: 8px; }
.rank-step.is-earned { border-color: #bfe6d9; background: #effbf7; color: #2e7466; }
.rank-step.is-earned > span, .rank-step.is-current > span { filter: none; opacity: 1; }
.rank-step.is-current { border: 2px solid #8e6bd8; background: #f3edff; color: #68449f; box-shadow: 0 6px 0 rgba(108, 75, 158, .13); transform: translateY(-2px); }
.stat-card span { color: var(--muted); font-size: 12px; font-weight: 800; }
.leaderboard-card { margin-bottom: 30px; border-color: #e7ddfb; background: linear-gradient(145deg, #fff 52%, #faf7ff); }
.leaderboard-count { flex: 0 0 auto; padding: 7px 11px; border-radius: 99px; background: #f0e9ff; color: #6c4a9f; font-size: 11px; font-weight: 1000; }
.leaderboard-list { display: grid; gap: 9px; }
.leaderboard-row { display: grid; grid-template-columns: 46px auto minmax(140px, 1fr) minmax(170px, .72fr) auto; align-items: center; gap: 13px; padding: 12px 14px; border: 1px solid #ebe7ef; border-radius: 18px; background: rgba(255,255,255,.88); }
.leaderboard-row.is-me { border: 2px solid #9f7be2; background: linear-gradient(110deg, #f5efff, #fff); box-shadow: 0 5px 0 rgba(108, 75, 158, .1); }
.leaderboard-place { color: #7650a9; font-size: 21px; font-weight: 1000; text-align: center; }
.leaderboard-person { min-width: 0; }
.leaderboard-person strong { display: block; overflow: hidden; font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.leaderboard-person strong small { padding: 2px 6px; border-radius: 99px; background: #e6f7f2; color: #26766b; font-size: 9px; vertical-align: 2px; }
.leaderboard-person > span { display: block; overflow: hidden; margin-top: 2px; color: var(--muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.leaderboard-rank { display: flex; min-width: 0; align-items: center; gap: 8px; }
.leaderboard-rank > span { font-size: 27px; }
.leaderboard-rank b { overflow: hidden; color: #67459b; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.leaderboard-score { min-width: 76px; text-align: right; }
.leaderboard-score strong { display: block; font-size: 21px; }
.leaderboard-score span { color: var(--muted); font-size: 9px; font-weight: 800; }
.leaderboard-empty { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 17px; }
.leaderboard-empty > span { display: grid; width: 58px; height: 58px; place-items: center; border-radius: 19px; background: #f0e9ff; font-size: 30px; }
.leaderboard-empty h2 { margin: 2px 0 4px; }
.leaderboard-empty p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.55; }

.daily-banner { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; margin: -9px 0 21px; padding: 10px 12px; border: 1px solid #eadfff; border-radius: 17px; background: linear-gradient(120deg, #fff9d8, #fff 47%, #f1ebff); box-shadow: var(--shadow-soft); }
.daily-banner__icon { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 13px; background: linear-gradient(145deg, #ffdc78, #ffeeb3); box-shadow: 0 4px 0 rgba(174, 131, 29, .12); font-size: 23px; }
.daily-banner small, .daily-feature small, .daily-question-head small { color: #7650b0; font-size: 11px; font-weight: 1000; letter-spacing: .04em; }
.daily-banner h2 { margin: 2px 0 0; font-size: 15px; letter-spacing: -.04em; }
.daily-banner .button { min-width: 82px; padding: 8px 11px; box-shadow: none; }
.daily-banner p { margin: 0; color: var(--muted); font-size: 13px; }
.daily-compact-shelf { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; margin: -7px 0 18px; padding: 10px 13px; border: 1px solid #e8def8; border-radius: 17px; background: linear-gradient(110deg, #fff9df, #fff 55%, #f3edff); box-shadow: 0 7px 18px rgba(62,68,93,.06); }
.daily-compact-shelf__icon, .daily-compact-shelf > span:first-child { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 13px; background: #ffefad; font-size: 23px; }
.daily-compact-shelf div { min-width: 0; }
.daily-compact-shelf b, .daily-compact-shelf small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.daily-compact-shelf b { margin-top: 2px; font-size: 14px; }
.daily-compact-shelf small { color: #7650b0; font-size: 9px; font-weight: 900; }
.daily-challenge-section { margin-bottom: 30px; border-color: #eadfff; background: linear-gradient(150deg, #fffbeb 0%, #fff 46%, #f6f1ff 100%); }
.daily-count { flex: 0 0 auto; padding: 8px 12px; border-radius: 99px; background: #efe7ff; color: #6f4aa9; font-size: 12px; font-weight: 1000; }
.daily-feature { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 18px; margin: 20px 0 18px; padding: 19px; border: 1px solid #eee6d0; border-radius: 20px; background: rgba(255,255,255,.88); }
.daily-feature > span { display: grid; width: 62px; height: 62px; place-items: center; border-radius: 19px; background: #fff1b9; font-size: 34px; }
.daily-feature h3 { margin: 3px 0 5px; font-size: 21px; letter-spacing: -.035em; }
.daily-feature p { display: -webkit-box; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.daily-unlocked-list { display: flex; flex-wrap: wrap; gap: 8px; }
.daily-day { display: grid; width: 58px; min-height: 62px; place-items: center; align-content: center; gap: 1px; padding: 7px 4px; border: 2px solid #e5e2db; border-radius: 15px; background: white; color: var(--muted); cursor: pointer; }
.daily-day span { font-size: 19px; }
.daily-day b { font-size: 10px; }
.daily-day.is-completed { border-color: #a9ddce; color: #237568; background: #eaf9f5; }
.daily-day.is-today { border-color: #8c69d5; color: #654298; background: #f1eaff; box-shadow: 0 5px 0 rgba(101, 66, 152, .11); }
.daily-lock-note { margin: 14px 0 0 !important; color: var(--muted); font-size: 11px; }
.daily-question-card { max-width: 760px; margin: 0 auto; border: 2px solid #eadfff; background: linear-gradient(160deg, #fff 65%, #faf7ff); }
.daily-question-head { display: flex; align-items: center; gap: 18px; margin-bottom: 22px; }
.daily-question-head > span { display: grid; width: 84px; height: 84px; flex: 0 0 auto; place-items: center; border-radius: 27px; background: linear-gradient(145deg, #ffe383, #fff1bd); font-size: 46px; }
.daily-question-head h1 { margin: 4px 0; font-size: 31px; line-height: 1.15; letter-spacing: -.05em; }
.daily-question-head b { color: var(--mint-dark); font-size: 12px; }
.daily-passage { margin-bottom: 24px; padding: 20px; border-radius: 18px; background: #f2faf7; }
.daily-passage small { color: var(--mint-dark); font-size: 10px; font-weight: 1000; letter-spacing: .12em; }
.daily-passage p { margin: 6px 0 0; color: #36575e; font-family: ui-serif, Georgia, serif; font-size: 20px; line-height: 1.75; }

.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin: 0 2px 17px; }
.section-head h2 { margin: 0; font-size: 26px; letter-spacing: -.04em; }
.section-head p { margin: 4px 0 0; color: var(--muted); font-size: 14px; }
.section-head button { white-space: nowrap; }

.lesson-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.lesson-card { position: relative; min-width: 0; border: 0; border-radius: 24px; background: white; box-shadow: var(--shadow-soft); overflow: hidden; text-align: left; cursor: pointer; transition: transform .2s, box-shadow .2s; }
.lesson-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.lesson-image { position: relative; height: 185px; background: #eaf5f0; overflow: hidden; }
.lesson-image img { width: 100%; height: 100%; object-fit: contain; object-position: center; background: #eef4f1; transition: transform .35s; }
.lesson-card:hover .lesson-image img { transform: scale(1.035); }
.lesson-level { position: absolute; left: 13px; top: 13px; padding: 6px 9px; border-radius: 9px; background: rgba(255,255,255,.92); box-shadow: 0 3px 10px rgba(23,60,69,.1); font-size: 11px; font-weight: 900; }
.completed-badge { position: absolute; right: 13px; top: 13px; display: grid; width: 34px; height: 34px; place-items: center; border-radius: 50%; background: var(--mint-dark); color: white; font-weight: 900; }
.lesson-body { padding: 18px; }
.lesson-category { color: var(--coral-dark); font-size: 11px; font-weight: 900; letter-spacing: .08em; }
.lesson-body h3 { margin: 7px 0 8px; font-size: 21px; letter-spacing: -.035em; }
.lesson-body p { display: -webkit-box; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.5; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.lesson-meta { display: flex; align-items: center; justify-content: space-between; margin-top: 15px; color: var(--muted); font-size: 12px; font-weight: 800; }
.progress-track { width: 76px; height: 7px; border-radius: 99px; background: #edf1ef; overflow: hidden; }
.progress-track i { display: block; height: 100%; border-radius: inherit; background: var(--mint-dark); }
.progress-0 i { width: 0; }.progress-1 i { width: 33%; }.progress-2 i { width: 66%; }.progress-3 i { width: 100%; }

.back-button { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 18px; padding: 8px 0; border: 0; color: var(--muted); background: transparent; font-weight: 900; cursor: pointer; }
.article-layout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr); align-items: start; gap: 25px; }
.article-card, .quiz-card, .panel { border: 1px solid rgba(23, 60, 69, .06); border-radius: 28px; background: white; box-shadow: var(--shadow-soft); overflow: hidden; }
.article-cover { position: relative; height: clamp(230px, 36vw, 430px); background: #edf3f0; }
.article-cover img { width: 100%; height: 100%; object-fit: contain; object-position: center; background: #26383d; }
.article-cover__shade { position: absolute; inset: 40% 0 0; background: linear-gradient(transparent, rgba(6,31,38,.75)); }
.article-cover__title { position: absolute; left: clamp(20px, 5vw, 42px); right: 24px; bottom: 28px; color: white; }
.article-cover__title span { padding: 6px 9px; border-radius: 8px; background: var(--coral); font-size: 11px; font-weight: 900; }
.article-cover__title h1 { max-width: 680px; margin: 9px 0 0; font-size: clamp(29px, 5vw, 51px); line-height: 1.07; letter-spacing: -.05em; }
.article-content { padding: clamp(24px, 5vw, 45px); }
.article-tools { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 27px; }
.article-lede { margin: 0 0 23px; color: var(--ink); font-size: clamp(19px, 2.7vw, 24px); line-height: 1.65; font-weight: 800; }
.article-text { color: #36575e; font-family: ui-serif, Georgia, serif; font-size: 19px; line-height: 1.9; }
.article-text p { margin: 0 0 18px; }
.translation-box { margin-top: 25px; padding: 21px; border-radius: 18px; background: #f1faf7; color: #36575e; line-height: 1.75; }
.translation-box strong { display: block; margin-bottom: 7px; color: var(--mint-dark); }
.is-hidden { display: none !important; }
.vocab { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.vocab span { padding: 8px 11px; border: 1px solid #dce7e2; border-radius: 10px; background: var(--paper); font-size: 13px; }
.vocab b { color: var(--coral-dark); }

.quiz-card { position: sticky; top: 100px; padding: 24px; }
.quiz-card__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 20px; }
.quiz-card h2 { margin: 3px 0 0; font-size: 25px; letter-spacing: -.04em; }
.quiz-count { padding: 7px 10px; border-radius: 10px; color: #755900; background: #fff3c7; font-size: 12px; font-weight: 900; }
.question { padding: 19px 0; border-top: 1px solid var(--line); }
.question:first-of-type { border-top: 0; }
.question-title { margin: 0 0 13px; font-size: 15px; line-height: 1.45; }
.question-title b { color: var(--coral-dark); }
.options { display: grid; gap: 8px; }
.option { position: relative; }
.option input { position: absolute; opacity: 0; pointer-events: none; }
.option span { display: flex; min-height: 43px; align-items: center; gap: 10px; padding: 10px 12px; border: 2px solid var(--line); border-radius: 13px; color: #4e696f; font-size: 13px; font-weight: 800; cursor: pointer; }
.option span::before { content: ""; width: 15px; height: 15px; flex: 0 0 auto; border: 2px solid #c8d5d1; border-radius: 50%; background: white; }
.option input:checked + span { border-color: var(--blue); color: #304eae; background: #f1f4ff; }
.option input:checked + span::before { border: 5px solid var(--blue); }
.option.is-correct span { border-color: var(--mint-dark); color: #126e65; background: #eaf9f6; }
.option.is-wrong span { border-color: var(--coral); color: #ae3d28; background: #fff0eb; }
.answer-note { margin-top: 10px; padding: 11px; border-radius: 11px; background: #f3f6f5; color: var(--muted); font-size: 12px; line-height: 1.55; }
.score-celebration { padding: 20px; margin-bottom: 17px; border-radius: 18px; background: linear-gradient(135deg, #fff2c6, #ffe0a5); text-align: center; }
.score-celebration strong { display: block; font-size: 37px; }
.score-celebration span { font-size: 13px; font-weight: 900; }

.create-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, .82fr); gap: 22px; align-items: start; }
.panel { padding: clamp(20px, 4vw, 30px); }
.panel h2 { margin: 0 0 6px; font-size: 24px; letter-spacing: -.04em; }
.panel > p { margin: 0 0 20px; color: var(--muted); line-height: 1.55; }
.create-method-picker { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin: 0 0 18px; }
.create-method-picker button { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 2px 9px; padding: 13px; border: 2px solid var(--line); border-radius: 17px; background: white; color: var(--ink); text-align: left; cursor: pointer; }
.create-method-picker button > span { grid-row: 1 / 3; font-size: 28px; }
.create-method-picker button b { font-size: 13px; }
.create-method-picker button small { color: var(--muted); font-size: 9px; }
.create-method-picker button.is-active { border-color: var(--blue); background: #f0f4ff; box-shadow: 0 5px 0 rgba(83, 111, 210, .12); }
.selected-source-note { margin: -3px 0 13px; color: var(--mint-dark); font-size: 11px; font-weight: 900; }
.article-style-section { margin: 4px 0 20px; }
.article-style-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.article-style-heading strong { font-size: 13px; }
.article-style-heading small { color: var(--muted); font-size: 10px; text-align: right; }
.article-style-picker { display: grid; grid-template-columns: repeat(auto-fit, minmax(112px, 1fr)); gap: 8px; }
.article-style-choice { display: grid; min-width: 0; min-height: 98px; place-items: center; align-content: center; gap: 3px; padding: 10px 7px; border: 2px solid var(--line); border-radius: 16px; background: white; color: var(--ink); cursor: pointer; }
.article-style-choice > span { font-size: 25px; }
.article-style-choice strong { font-size: 12px; }
.article-style-choice small { color: var(--muted); font-size: 9px; line-height: 1.3; text-align: center; }
.article-style-choice.is-selected { border-color: var(--coral); background: #fff1ec; box-shadow: 0 5px 0 rgba(232, 101, 72, .12); }
.customization-panel { margin: 0 0 20px; border: 2px solid #dce8e4; border-radius: 20px; background: #fbfdfc; overflow: hidden; }
.customization-panel.is-open { border-color: #9ed9cc; background: #f5fcfa; }
.customization-toggle { display: flex; width: 100%; align-items: center; gap: 11px; padding: 15px; border: 0; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.customization-toggle > span:first-child { font-size: 27px; }
.customization-toggle > span:nth-child(2) { min-width: 0; flex: 1; }
.customization-toggle strong, .customization-toggle small { display: block; }
.customization-toggle small { margin-top: 2px; color: var(--muted); font-size: 10px; }
.customization-toggle > b { color: var(--mint-dark); font-size: 11px; white-space: nowrap; }
.customization-fields { padding: 0 15px 16px; border-top: 1px dashed #c9e1da; }
.customization-fields .article-style-section { margin-top: 16px; }
.basic-mode-note { margin: -4px 15px 14px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.create-article-button + .customization-panel { margin-top: 13px; }
.create-level-result { margin: 16px 0; padding: 15px; border: 1px solid #cfdcfb; border-radius: 18px; background: linear-gradient(135deg, #f2f6ff, #fbfaff); }
.create-level-result > div:first-child strong, .create-level-result > div:first-child small { display: block; }
.create-level-result > div:first-child small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.create-level-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; margin-top: 11px; }
.create-level-tabs button { display: grid; gap: 2px; padding: 9px 5px; border: 1px solid #d9e0f2; border-radius: 12px; background: white; color: var(--muted); cursor: pointer; }
.create-level-tabs button b { font-size: 11px; }
.create-level-tabs button small { font-size: 8px; }
.create-level-tabs button.is-active { border-color: var(--blue); color: #3852ad; background: #eaf0ff; box-shadow: inset 0 0 0 1px var(--blue); }
.reading-level-picker { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.reading-level-choice { display: grid; min-height: 94px; place-items: center; align-content: center; gap: 3px; padding: 9px 6px; border: 2px solid var(--line); border-radius: 15px; background: white; color: var(--ink); cursor: pointer; }
.reading-level-choice span { font-size: 22px; }
.reading-level-choice strong { font-size: 11px; }
.reading-level-choice small { color: var(--muted); font-size: 9px; text-align: center; }
.reading-level-choice.is-selected { border-color: var(--blue); background: #f0f4ff; }
.reading-level-choice.is-locked { opacity: .55; cursor: not-allowed; }
.custom-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
.inline-field { display: flex; align-items: center; gap: 8px; }
.inline-field .input { min-width: 0; }
.inline-field .text-button { flex: 0 0 auto; font-size: 10px; }
.article-region-field { grid-column: 1 / -1; padding: 13px; border: 1px solid #d9e8e3; border-radius: 16px; background: rgba(255,255,255,.72); }
.article-region-selects { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.article-region-selects label { display: grid; gap: 5px; }
.article-region-selects label > span { color: var(--muted); font-size: 9px; font-weight: 900; }
.article-region-help { display: flex; align-items: center; justify-content: space-between; gap: 9px; margin-top: 7px; }
.article-region-help small { color: var(--muted); line-height: 1.45; }
.article-region-help .text-button { flex: 0 0 auto; font-size: 10px; }
.photo-source-picker { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0 0 12px; }
.photo-source-button { position: relative; display: grid; min-height: 108px; place-items: center; align-content: center; gap: 2px; padding: 12px; border: 2px dashed #cddbd6; border-radius: 18px; background: #f9fbfa; color: var(--ink); text-align: center; cursor: pointer; }
.photo-source-button:hover { border-color: var(--mint-dark); background: #f3fbf8; }
.photo-source-button input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.photo-source-button span { font-size: 27px; }
.photo-source-button strong { font-size: 12px; }
.photo-source-button small { color: var(--muted); font-size: 9px; }
.photo-source-picker.is-analyzing { opacity: .65; pointer-events: none; }
.analyzing-status { margin: 0 0 12px; padding: 11px 13px; border-radius: 13px; background: #f0f4ff; color: #3f57a9; font-size: 11px; font-weight: 900; animation: ai-pulse 1.35s ease-in-out infinite; }
.article-generation-progress { margin: 2px 0 14px; padding: 14px; border: 1px solid #cfdafa; border-radius: 16px; background: linear-gradient(135deg, #f0f4ff, #f9f7ff); box-shadow: 0 8px 22px rgba(78,104,195,.1); }
.article-generation-progress > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; color: #3c56ad; font-size: 12px; font-weight: 1000; }
.article-generation-progress > div b { min-width: 38px; text-align: right; }
.article-generation-progress > em { display: block; height: 12px; padding: 2px; border-radius: 99px; background: #dfe5f9; overflow: hidden; }
.article-generation-progress > em > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--blue), var(--purple), var(--coral)); box-shadow: 0 0 12px rgba(108,140,255,.35); transition: width .45s ease; }
.article-generation-progress > small { display: block; margin-top: 7px; color: var(--muted); font-size: 9px; line-height: 1.45; }
.upload-drop { display: grid; min-height: 110px; place-items: center; padding: 15px; border: 2px dashed #cddbd6; border-radius: 18px; background: #f9fbfa; color: var(--muted); text-align: center; cursor: pointer; }
.upload-drop:hover { border-color: var(--mint-dark); }
.upload-drop input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.upload-drop strong { display: block; margin-top: 4px; color: var(--ink); }
.upload-drop.is-analyzing { border-color: var(--blue); background: #f0f4ff; cursor: wait; animation: ai-pulse 1.35s ease-in-out infinite; }
.analyze-again { display: block; margin: 8px auto 0; color: var(--blue); }
.ai-privacy-note { margin: 12px 0 20px; padding: 11px 13px; border-radius: 13px; background: #eef8f5; color: #42625d; font-size: 11px; line-height: 1.55; }
.button--translate { margin: 4px 0 12px; background: var(--blue); box-shadow: 0 7px 0 #4967cc; }
.translation-setup-note { margin: 0 0 16px; padding: 12px 13px; border-radius: 13px; background: #fff3c7; color: #715a17; font-size: 12px; line-height: 1.5; }
.translation-result { margin-top: 18px; padding: 15px; border-radius: 17px; background: #eff5ff; }
.translation-result .input { border-color: #cad5ff; }
.generated-quiz-note { display: grid; grid-template-columns: auto 1fr; column-gap: 10px; margin: 16px 0; padding: 14px; border: 1px solid #cde7dd; border-radius: 15px; background: #effbf7; }
.generated-quiz-note > span { grid-row: 1 / 3; align-self: center; font-size: 25px; }
.generated-quiz-note strong { color: #216c5d; font-size: 14px; }
.generated-quiz-note small { margin-top: 2px; color: var(--muted); line-height: 1.45; }
.visibility-picker { display: grid; gap: 9px; margin: 20px 0; padding: 0; border: 0; }
.visibility-picker legend { margin-bottom: 9px; font-size: 13px; font-weight: 900; }
.visibility-picker legend small { margin-left: 5px; color: var(--muted); font-size: 9px; font-weight: 700; }
.visibility-choice--public { border-color: #b9d7ff !important; background: linear-gradient(135deg, #f0f7ff, #f6fbff) !important; }
.visibility-choice--public:has(input:checked) { border-color: #5f88df !important; box-shadow: 0 0 0 2px rgba(95,136,223,.12); }
.visibility-choice { position: relative; }
.visibility-choice input { position: absolute; opacity: 0; pointer-events: none; }
.visibility-choice > span { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 14px; border: 2px solid var(--line); border-radius: 15px; background: white; cursor: pointer; }
.visibility-choice b { display: block; font-size: 13px; }
.visibility-choice small { color: var(--muted); font-size: 11px; text-align: right; }
.visibility-choice input:checked + span { border-color: var(--mint-dark); background: #effaf7; }
.visibility-choice input:disabled + span { opacity: .55; cursor: not-allowed; }
.visibility-private-note { margin: 1px 0 0; padding: 9px 11px; border-radius: 12px; background: #f3f6f5; color: var(--muted); font-size: 10px; }
.photo-privacy-lock { display: grid; gap: 3px; padding: 12px 13px; border: 1px solid #a8d6c8; border-radius: 14px; background: #effaf6; color: #245d55; }
.photo-privacy-lock b { font-size: 13px; }
.photo-privacy-lock span { font-size: 10px; line-height: 1.5; }
.create-method-help { max-width: 34em; margin: -4px 0 14px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.story-preview { position: sticky; top: 100px; min-height: 510px; padding: 0; }
.preview-photo { display: grid; height: 245px; place-items: center; background: linear-gradient(135deg, #b9e9df, #fff0be); font-size: 95px; overflow: hidden; }
.preview-photo img { width: 100%; height: 100%; object-fit: contain; object-position: center; background: #edf3f0; }
.preview-copy { padding: 25px; }
.preview-copy small { color: var(--coral-dark); font-weight: 900; }
.preview-copy h2 { margin: 8px 0 12px; font-size: 29px; }
.preview-copy p { margin: 0; color: #4c676d; font-family: ui-serif, Georgia, serif; line-height: 1.75; white-space: pre-wrap; }

.family-news-section { margin-top: 38px; }
.story-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.story-mini { display: grid; grid-template-columns: 100px 1fr; min-width: 0; border: 0; border-radius: 18px; background: white; box-shadow: var(--shadow-soft); overflow: hidden; }
.story-mini__image { position: relative; display: grid; min-height: 130px; padding: 0; place-items: center; border: 0; background: #e4f6f2; font-size: 38px; cursor: pointer; overflow: hidden; }
.story-mini__image img { width: 100%; height: 100%; object-fit: cover; object-position: center; background: #edf3f0; }
.story-mini__copy { min-width: 0; padding: 14px; }
.story-mini__open-copy { display: block; width: 100%; min-width: 0; padding: 0; border: 0; background: transparent; color: inherit; text-align: left; cursor: pointer; }
.story-mini h3 { margin: 0 0 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.story-korean-title { display: block; margin: -3px 0 5px; color: var(--mint-dark); font-weight: 900; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.story-mini p { display: -webkit-box; margin: 0; color: var(--muted); font-size: 12px; line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.story-byline { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 7px; color: var(--muted); font-size: 10px; font-weight: 900; }
.story-list-side { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 7px; }
.story-author { display: flex; min-width: 0; align-items: center; gap: 6px; }
.story-author b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.story-actions { display: flex; align-items: center; justify-content: space-between; margin-top: 4px; }
.story-actions .text-button { padding: 7px 0; font-size: 11px; }
.story-actions { flex-wrap: wrap; gap: 5px 11px; justify-content: flex-start; }
.story-meta-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 6px; }
.story-meta-row span { padding: 3px 7px; border-radius: 999px; background: #eef5f3; color: #4a6564; font-size: 9px; font-weight: 900; }
.story-meta-row b { margin-left: auto; color: #3852ad; font-size: 10px; }
.danger-text { color: #b94235 !important; }
.news-page-heading { align-items: center; }
.news-view-switch { display: flex; flex: 0 0 auto; align-items: center; margin-left: auto; padding: 3px; border: 1px solid #dfe4f7; border-radius: 11px; background: rgba(255,255,255,.9); box-shadow: var(--shadow-soft); }
.news-view-switch__label { display: grid; gap: 1px; padding-left: 7px; }
.news-view-switch__label b { font-size: 12px; }
.news-view-switch__label small { color: var(--muted); font-size: 9px; white-space: nowrap; }
.news-view-controls { display: flex; justify-content: flex-end; gap: 6px; margin: 0; }
.news-view-controls button { display: grid; width: 32px; height: 30px; min-width: 32px; place-items: center; padding: 0; border: 1px solid transparent; border-radius: 8px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 900; cursor: pointer; }
.news-view-controls button > span { align-self: center; font-size: 16px; line-height: 1; }
.news-view-controls button > b, .news-view-controls button > small { text-align: left; }
.news-view-controls button > small { font-size: 8px; font-weight: 700; }
.news-view-controls button.is-active { border-color: var(--blue); color: #3852ad; background: #eef3ff; box-shadow: inset 0 0 0 1px var(--blue); }
.news-source-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; margin: 0 0 25px; padding: 6px; border-radius: 18px; background: #e9efec; }
.news-source-tabs button { display: flex; min-width: 0; min-height: 48px; align-items: center; justify-content: center; gap: 8px; padding: 9px; border: 0; border-radius: 13px; background: transparent; color: var(--muted); cursor: pointer; }
.news-source-tabs button b { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.news-source-tabs button small { flex: 0 0 auto; padding: 2px 6px; border-radius: 99px; background: rgba(255,255,255,.7); font-size: 8px; }
.news-source-tabs button.is-active { color: var(--ink); background: white; box-shadow: 0 5px 14px rgba(23,60,69,.09); }
.news-source-section { min-height: 220px; }
.news-list { display: grid; gap: 13px; }
.news-list .lesson-card { display: grid; grid-template-columns: minmax(190px, 24%) minmax(0, 1fr); min-height: 170px; }
.news-list .lesson-image { height: 100%; }
.news-list .lesson-body { align-self: center; }
.news-list .lesson-body p { -webkit-line-clamp: 3; }
.news-story-list { grid-template-columns: 1fr; }
.news-story-list .story-mini { grid-template-columns: minmax(150px, 20%) minmax(0, 1fr); }
.news-photo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 15px; }
.news-photo-card, .news-photo-card__open { min-width: 0; border: 0; border-radius: 18px; background: white; box-shadow: var(--shadow-soft); overflow: hidden; }
.news-photo-card { position: relative; margin: 0; border: 0; }
.news-photo-card__open, button.news-photo-card { display: block; width: 100%; padding: 0; color: var(--ink); text-align: left; cursor: pointer; }
.news-photo-media { position: relative; display: block; width: 100%; height: 180px; overflow: hidden; background: #edf3f0; }
.news-photo-media > img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.story-read-badge { position: absolute; right: 9px; bottom: 9px; z-index: 1; padding: 5px 7px; border-radius: 8px; background: #486d75; color: white; box-shadow: 0 3px 10px rgba(23,60,69,.12); font-size: 9px; font-weight: 1000; line-height: 1; }
.is-read .story-read-badge { background: rgba(255,255,255,.94); color: #617174; }
.story-mini__image .story-read-badge { right: 7px; bottom: 7px; }
.news-photo-card strong { display: block; margin: 0; padding: 13px 14px 15px; font-size: 14px; line-height: 1.35; }
.news-photo-card__meta { display: flex; min-width: 0; align-items: flex-start; gap: 6px; padding: 11px 9px 12px 13px; }
.news-photo-card__title { min-width: 0; flex: 1; padding: 0; border: 0; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.news-photo-card__title h3 { display: -webkit-box; overflow: hidden; margin: 0; padding: 0; font-size: 14px; line-height: 1.35; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.news-photo-card__title small { display: block; overflow: hidden; margin-top: 5px; color: var(--muted); font-size: 9px; font-weight: 900; text-overflow: ellipsis; white-space: nowrap; }
.news-photo-card__emoji { display: grid; width: 100%; height: 100%; place-items: center; background: linear-gradient(135deg, #b9e9df, #fff0be); font-size: 55px; }
.story-heart-button { display: inline-grid; width: 32px; height: 30px; flex: 0 0 32px; place-items: center; padding: 0; border: 0; border-radius: 11px; background: transparent; color: #76666a; font: inherit; cursor: pointer; box-shadow: none; }
.heart-count-badge { position: relative; display: block; width: 30px; height: 28px; }
.heart-count-badge > span { position: absolute; inset: 0; color: #d66570; font-size: 26px; line-height: 28px; text-align: center; transform: scaleX(1.08); }
.heart-count-badge > b { position: absolute; inset: 9px 0 auto; z-index: 1; color: #8f4d55; font-size: 8px; line-height: 1; text-align: center; }
.story-heart-button:disabled { cursor: wait; opacity: .65; }
.story-heart-button--compact { width: 24px; height: 22px; flex-basis: 24px; }
.story-heart-button--compact .heart-count-badge { width: 24px; height: 22px; transform: none; }
.story-heart-button--compact .heart-count-badge > span { font-size: 21px; line-height: 22px; }
.story-heart-button--compact .heart-count-badge > b { inset: 7px 0 auto; font-size: 7px; }
.news-source-heading { display: grid; gap: 3px; margin-bottom: 17px; }
.news-source-heading > .eyebrow { margin: 0; }
.news-source-title-row { display: flex; min-width: 0; align-items: center; gap: 8px; }
.news-source-title-row h2 { min-width: 0; margin: 0; }
.news-source-heading > p { margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.local-news-section { padding-top: 4px; }
.family-story { max-width: 820px; margin: auto; padding: 0; }
.family-story__photo { display: grid; min-height: clamp(280px, 48vw, 480px); height: auto; place-items: center; background: linear-gradient(135deg, #b9e9df, #fff0be); font-size: 130px; overflow: hidden; }
.family-story__photo:has(img) { min-height: 0; background: #edf3f0; }
.family-story__photo img { display: block; width: 100%; height: auto; max-height: none; object-fit: contain; object-position: center; background: #edf3f0; }
.family-story__content { padding: clamp(24px, 6vw, 52px); }
.family-story__content h1 { margin: 12px 0 20px; font-size: clamp(32px, 6vw, 54px); line-height: 1.08; letter-spacing: -.055em; }
.family-story__korean-title { margin: -13px 0 20px; color: var(--muted); font-size: 16px; font-weight: 900; }
.family-story__article { margin-top: 28px; color: #36575e; font-family: ui-serif, Georgia, serif; font-size: clamp(18px, 3vw, 22px); line-height: 1.9; white-space: pre-wrap; }
.family-story__article.is-korean { font-family: inherit; font-size: clamp(16px, 2.7vw, 20px); word-break: keep-all; }
.story-language-switch { display: inline-grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; margin: 0 0 14px; padding: 5px; border-radius: 15px; background: #edf3f1; }
.story-language-switch button { min-height: 39px; padding: 8px 13px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); font-size: 11px; font-weight: 900; cursor: pointer; }
.story-language-switch button.is-active { background: white; color: var(--ink); box-shadow: 0 4px 12px rgba(23,60,69,.1); }
.story-vocabulary { margin-top: 30px; padding: 19px; border: 1px solid #dfeae6; border-radius: 21px; background: linear-gradient(145deg, #f0faf7, #fff); }
.story-vocabulary > div:first-child { display: flex; align-items: center; gap: 10px; }
.story-vocabulary > div:first-child > span { display: grid; width: 43px; height: 43px; place-items: center; border-radius: 14px; background: var(--mint); color: #174f49; font-size: 10px; font-weight: 1000; }
.story-vocabulary h2 { margin: 0; font-size: 18px; }
.story-vocabulary dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 15px 0 0; }
.story-vocabulary dl > div { min-width: 0; padding: 10px 12px; border-radius: 13px; background: white; }
.story-vocabulary dt { color: var(--coral-dark); font-family: ui-rounded, system-ui, sans-serif; font-size: 13px; font-weight: 1000; }
.story-vocabulary dd { margin: 3px 0 0; color: #4f6669; font-size: 11px; line-height: 1.45; }
.story-vocabulary > p { margin-bottom: 0; color: var(--muted); font-size: 12px; }
.story-learning-layout .family-story { width: 100%; max-width: none; }
.story-quiz-card { max-height: calc(100vh - 120px); overflow-y: auto; }

@keyframes ai-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(108, 140, 255, 0); }
  50% { box-shadow: 0 0 0 7px rgba(108, 140, 255, .12); }
}

.family-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 22px; align-items: start; }
.profile-panel { text-align: center; }
.profile-panel .avatar, .profile-panel .profile-reporter-figure { margin: 5px auto 16px; }
.profile-panel h2 { margin-bottom: 3px; }
.profile-panel .role { margin: 0 0 20px; color: var(--muted); }
.photo-label { display: inline-flex; cursor: pointer; }
.photo-label input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.privacy-note { margin-top: 18px; padding: 13px; border-radius: 13px; color: #5c6968; background: #f3f6f5; font-size: 11px; line-height: 1.5; text-align: left; }
.report-list { display: grid; gap: 11px; margin-top: 20px; }
.family-profile-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 18px 0 26px; }
.family-profile-card { display: flex; min-width: 0; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); }
.family-profile-card span:last-child { min-width: 0; }
.family-profile-card strong, .family-profile-card small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.family-profile-card small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.report-heading { margin-top: 6px !important; padding-top: 24px; border-top: 1px solid var(--line); }
.report-row { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 14px; padding: 13px 0; border-top: 1px solid var(--line); }
.report-row:first-child { border-top: 0; }
.report-row strong { display: block; }
.report-row small { color: var(--muted); }
.story-edit-link { color: #7650b0; }
.story-manage-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 18px; }
.story-manage-actions--bottom { margin: 16px 0 0; padding-top: 16px; border-top: 1px solid var(--line); }
.story-bottom-heart { display: inline-flex; align-items: center; margin-left: auto; }
.edit-story-panel { max-width: 820px; margin: 0 auto; }
.edit-story-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.edit-story-heading h1 { margin: 5px 0 7px; font-size: clamp(29px, 5vw, 42px); letter-spacing: -.05em; }
.edit-story-heading p { margin: 0; color: var(--muted); line-height: 1.6; }
.edit-story-heading > span { flex: 0 0 auto; padding: 9px 13px; border-radius: 99px; background: #f2ebff; color: #69459e; font-size: 12px; font-weight: 900; }
.edit-story-article { min-height: 280px; line-height: 1.75; resize: vertical; }
.edit-question-note { margin: -2px 0 18px; padding: 13px 15px; border-radius: 14px; background: #eef9f6; color: #2b7168; font-size: 12px; font-weight: 800; line-height: 1.55; }
.edit-story-buttons { display: flex; flex-wrap: wrap; gap: 10px; }
.danger-button { border-color: #f3c0b7; background: #fff1ee; color: #a93f2f; }
.danger-button:hover { background: #ffe4de; }
.admin-badge { display: inline-flex; align-items: center; margin: 1px 0 10px; padding: 7px 11px; border-radius: 99px; background: #eee7ff; color: #67449b; font-size: 12px; font-weight: 1000; }
.profile-panel .admin-note { max-width: 280px; margin: 0 auto 18px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.score-pill { padding: 8px 11px; border-radius: 11px; background: #eaf9f6; color: var(--mint-dark); font-size: 13px; font-weight: 900; }
.empty-state { padding: 40px 20px; border: 2px dashed #dce5e1; border-radius: 20px; color: var(--muted); text-align: center; }
.empty-state span { display: block; margin-bottom: 9px; font-size: 36px; }

.reading-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 22px; align-items: start; }
.reading-form-panel { padding: clamp(22px, 4vw, 34px); overflow: visible; }
.reading-form-title { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.reading-form-title > span { display: grid; width: 58px; height: 58px; flex: 0 0 auto; place-items: center; border-radius: 19px; background: #fff3c7; font-size: 31px; }
.reading-form-title h2, .reading-guide-card h2 { margin: 0 0 5px; letter-spacing: -.04em; }
.reading-form-title p, .reading-guide-card p { margin: 0; color: var(--muted); line-height: 1.55; }
.reading-meta-grid, .reading-settings { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.reading-meta-grid .field > span small { margin-left: 4px; color: var(--muted); font-size: 10px; font-weight: 700; }
.book-cover-upload { display: flex; align-items: center; gap: 13px; margin: -2px 0 18px; padding: 13px 15px; border: 2px dashed #c9c1ee; border-radius: 17px; background: #f7f4ff; cursor: pointer; }
.book-cover-upload input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.book-cover-preview { display: grid; width: 52px; height: 66px; flex: 0 0 auto; place-items: center; border-radius: 9px; background: white; box-shadow: 0 4px 12px rgba(23, 60, 69, .12); font-size: 27px; overflow: hidden; }
.book-cover-preview img { width: 100%; height: 100%; object-fit: cover; }
.book-cover-upload strong, .book-cover-upload small { display: block; }
.book-cover-upload strong { color: #58458f; }
.book-cover-upload small { margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.book-cover-upload.is-analyzing { cursor: wait; opacity: .75; }
.reading-language { display: flex; gap: 10px; margin: 2px 0 18px; padding: 0; border: 0; }
.reading-language legend { width: 100%; margin-bottom: 9px; color: var(--ink); font-size: 13px; font-weight: 900; }
.reading-language label { flex: 1; cursor: pointer; }
.reading-language input { position: absolute; opacity: 0; pointer-events: none; }
.reading-language span { display: block; padding: 12px 15px; border: 2px solid var(--line); border-radius: 14px; background: var(--paper); font-weight: 900; text-align: center; transition: border-color .16s, background .16s, transform .16s; }
.reading-language input:checked + span { border-color: var(--mint); background: #eaf9f6; color: var(--mint-dark); transform: translateY(-1px); }
.reading-note-field textarea { min-height: 185px; }
.voice-record-button { display: flex; width: 100%; align-items: center; gap: 13px; margin: -2px 0 18px; padding: 14px 16px; border: 2px dashed #9dd9cf; border-radius: 17px; background: #effbf7; color: var(--ink); text-align: left; cursor: pointer; }
.voice-record-button:disabled { cursor: not-allowed; opacity: .62; }
.voice-record-icon { display: grid; width: 44px; height: 44px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: var(--mint); font-size: 22px; }
.voice-record-button strong, .voice-record-button small { display: block; }
.voice-record-button small { margin-top: 3px; color: var(--muted); font-size: 11px; line-height: 1.4; }
.voice-record-button.is-listening { border-style: solid; border-color: #ff7657; background: #fff0eb; }
.voice-record-button.is-listening .voice-record-icon { background: #ff7657; animation: reading-mic-pulse 1.1s ease-in-out infinite; }
@keyframes reading-mic-pulse { 50% { box-shadow: 0 0 0 9px rgba(255, 118, 87, .16); transform: scale(1.05); } }
.reading-privacy-note { margin: 4px 0 15px; padding: 11px 13px; border-radius: 13px; background: #f5f7f6; color: var(--muted); font-size: 12px; line-height: 1.45; }
.reading-guide { position: sticky; top: 100px; display: grid; gap: 14px; }
.reading-guide-card { padding: 24px; border-radius: 24px; background: #fff8df; box-shadow: var(--shadow-soft); }
.reading-guide-card > span { display: block; margin-bottom: 11px; font-size: 35px; }
.reading-guide-card p + p { margin-top: 14px; padding-top: 14px; border-top: 1px dashed rgba(117, 89, 0, .2); color: #6a5622; font-family: ui-serif, Georgia, serif; }
.reading-guide-card--mint { background: #eaf9f6; }
.reading-guide-card ul { margin: 12px 0 0; padding-left: 21px; color: #38645c; line-height: 1.9; }
.reading-history { margin-top: 40px; }
.reading-count { padding: 8px 12px; border-radius: 12px; background: #fff3c7; color: #755900; font-size: 13px; font-weight: 900; }
.reading-note-list { display: grid; gap: 16px; }
.reading-note-card { padding: clamp(19px, 3vw, 28px); border: 1px solid rgba(23, 60, 69, .08); border-radius: 24px; background: white; box-shadow: var(--shadow-soft); }
.reading-note-head { display: flex; align-items: center; gap: 14px; }
.reading-book-icon { display: grid; width: 56px; height: 56px; flex: 0 0 auto; place-items: center; border-radius: 18px; background: #eef1ff; font-size: 29px; }
.reading-note-head small { color: var(--muted); font-size: 11px; font-weight: 800; }
.reading-note-head h3 { margin: 3px 0 0; font-size: 22px; letter-spacing: -.035em; }
.reading-note-head p { margin: 3px 0 0; color: var(--muted); font-size: 12px; }
.reading-summary { margin: 18px 0 14px; padding: 17px 18px; border-left: 5px solid var(--mint); border-radius: 4px 16px 16px 4px; background: #effbf7; }
.reading-summary strong { color: var(--mint-dark); font-size: 11px; letter-spacing: .08em; }
.reading-summary p { margin: 6px 0 4px; color: var(--ink); font-family: ui-serif, Georgia, serif; font-size: 16px; line-height: 1.55; }
.reading-summary small { color: var(--muted); line-height: 1.5; }
.reading-note-details > summary { padding: 10px 0; color: var(--coral-dark); font-weight: 900; cursor: pointer; }
.reading-note-details > section { margin: 8px 0 18px; padding: 17px; border-radius: 16px; background: var(--paper); }
.reading-note-details > section > p { white-space: pre-wrap; line-height: 1.65; }
.corrected-note { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.corrected-note p { font-family: ui-serif, Georgia, serif; line-height: 1.65; }
.reading-question-list { display: grid; gap: 10px; }
.reading-question { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.reading-question > summary { display: flex; gap: 10px; padding: 15px 16px; background: #fcfdfc; cursor: pointer; list-style: none; }
.reading-question > summary::-webkit-details-marker { display: none; }
.reading-question > summary b { color: var(--coral-dark); }
.reading-question > summary span { min-width: 0; font-weight: 900; line-height: 1.45; }
.reading-question > summary small, .reading-options small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; font-weight: 600; }
.reading-options { display: grid; gap: 7px; margin: 0; padding: 13px 16px; list-style: none; }
.reading-options li { display: flex; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--paper); }
.reading-options li > b { display: grid; width: 25px; height: 25px; flex: 0 0 auto; place-items: center; border-radius: 8px; background: #dff5f0; color: var(--mint-dark); }
.reading-answer { margin: 0 16px 16px; padding: 13px 14px; border-radius: 13px; background: #fff3c7; }
.reading-answer strong { color: #755900; }
.reading-answer p { margin: 6px 0 3px; line-height: 1.5; }
.reading-answer small { color: #6e6347; line-height: 1.45; }

.bottom-nav { display: none; }

@media (max-width: 900px) {
  .auth-page { grid-template-columns: 1fr; max-width: 620px; padding-top: 35px; }
  .auth-intro { text-align: center; }
  .auth-intro > p { margin-inline: auto; }
  .auth-badges { justify-content: center; }
  .laptop-screen { min-height: auto; }
  .desktop-nav { display: none; }
  .topbar__inner { height: 68px; }
  .profile-chip { margin-left: auto; }
  .welcome-hero { grid-template-columns: 1fr; }
  .welcome-visual { display: none; }
  .lesson-grid { grid-template-columns: repeat(2, 1fr); }
  .article-layout, .create-layout { grid-template-columns: 1fr; }
  .quiz-card, .story-preview { position: static; }
  .story-quiz-card { max-height: none; overflow: visible; }
  .family-grid { grid-template-columns: 1fr; }
  .bottom-nav {
    position: fixed;
    z-index: 30;
    left: 12px;
    right: 12px;
    bottom: max(10px, env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    padding: 7px;
    border: 1px solid rgba(23,60,69,.08);
    border-radius: 22px;
    background: rgba(255,255,255,.93);
    box-shadow: 0 10px 35px rgba(23,60,69,.18);
    backdrop-filter: blur(18px);
  }
  .bottom-nav .nav-link { min-width: 0; flex-direction: column; gap: 2px; padding: 6px 2px; font-size: 10px; }
  .bottom-nav .nav-link span { font-size: 20px; }
  .app-shell { padding-bottom: 88px; }
  .audio-dock { bottom: 92px; }
  .reading-layout { grid-template-columns: 1fr; }
  .reading-guide { position: static; grid-template-columns: 1fr 1fr; }
}

@media (max-width: 620px) {
  .onboarding-guide { padding: 10px; }
  .onboarding-card { padding: 18px 16px 16px; border-radius: 24px; }
  .onboarding-visual { min-height: 205px; margin: 11px 0 15px; }
  .onboarding-copy p { font-size: 12px; }
  .onboarding-actions .button { min-width: 96px; padding: 10px 12px; }
  .onboarding-level-visual { gap: 4px; }
  .onboarding-level-visual > span { min-width: 0; min-height: 82px; flex: 1; padding: 7px 3px; }
  .onboarding-level-visual > i { font-size: 11px; }
  .profile-title-row { gap: 7px; }
  .profile-title-row h2 { font-size: 20px; }
  .onboarding-help-button { padding: 5px 8px; font-size: 9px; }
  .auth-page { display: block; width: 100%; padding: 23px 14px 65px; }
  .auth-intro { margin-bottom: 27px; }
  .auth-intro h1 { font-size: 48px; }
  .auth-intro > p { font-size: 15px; }
  .auth-badges span { font-size: 11px; }
  .laptop { width: calc(100vw - 28px); max-width: calc(100vw - 28px); min-width: 0; margin-bottom: 38px; }
  .laptop-screen { padding: 8px; border-width: 8px; border-bottom-width: 13px; border-radius: 24px 24px 14px 14px; }
  .laptop-base { left: -3%; right: -3%; bottom: -25px; height: 40px; border-radius: 6px 6px 22px 22px; }
  .auth-card { min-height: auto; padding: 19px 15px; }
  .profile-picker { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .profile-choice { padding: 8px; overflow: hidden; }
  .profile-choice small { display: none; }
  .avatar { width: 45px; height: 45px; border-radius: 14px; font-size: 23px; }
  .setup-members { grid-template-columns: 1fr; }
  .topbar__inner { padding: 0 15px; }
  .brand small, .profile-chip small { display: none; }
  .reading-meta-grid, .reading-settings, .reading-guide { grid-template-columns: 1fr; }
  .reading-form-panel { padding: 19px 16px; }
  .reading-question > summary { padding: 13px; }
  .profile-chip { padding-right: 7px; }
  .page { padding: 23px 15px 44px; }
  .page-heading { align-items: start; flex-direction: column; }
  .welcome-hero { min-height: 0; padding: 28px 23px; border-radius: 27px; }
  .welcome-copy h1 { font-size: 38px; }
  .welcome-copy p { font-size: 14px; }
  .welcome-actions .button { width: 100%; }
  .quick-stats { grid-template-columns: 1fr; gap: 9px; }
  .daily-banner { grid-template-columns: auto minmax(0, 1fr) auto; margin-top: -6px; padding: 9px; }
  .daily-banner__icon { width: 38px; height: 38px; border-radius: 12px; font-size: 21px; }
  .daily-banner h2 { font-size: 13px; }
  .daily-banner p { font-size: 11px; }
  .daily-banner .button { grid-column: auto; width: auto; min-width: 68px; padding: 7px 8px; font-size: 9px; }
  .daily-feature { grid-template-columns: auto 1fr; padding: 15px; }
  .daily-feature > span { width: 52px; height: 52px; font-size: 29px; }
  .daily-feature h3 { font-size: 18px; }
  .daily-feature .button { grid-column: 1 / -1; width: 100%; }
  .daily-unlocked-list { flex-wrap: nowrap; margin-right: -17px; margin-left: -17px; padding: 3px 17px 10px; overflow-x: auto; }
  .daily-day { flex: 0 0 56px; }
  .daily-question-head { align-items: flex-start; gap: 13px; }
  .daily-question-head > span { width: 65px; height: 65px; border-radius: 21px; font-size: 35px; }
  .daily-question-head h1 { font-size: 25px; }
  .daily-passage { padding: 17px; }
  .daily-passage p { font-size: 18px; }
  .stat-card { padding: 13px 15px; }
  .rank-card { padding: 20px 16px; }
  .rank-card::after { right: 13px; top: 11px; font-size: 28px; }
  .rank-current { gap: 13px; }
  .rank-current__icon { width: 72px; height: 72px; border-radius: 24px; font-size: 39px; }
  .rank-current h2 { font-size: 25px; }
  .rank-current p { font-size: 12px; }
  .rank-progress-copy { align-items: flex-end; font-size: 10px; }
  .rank-ladder { display: flex; margin-right: -16px; margin-left: -16px; padding: 3px 16px 12px; overflow-x: auto; scroll-snap-type: x proximity; }
  .rank-step { flex: 0 0 112px; scroll-snap-align: start; }
  .leaderboard-row { grid-template-columns: 34px 45px minmax(0, 1fr) auto; gap: 9px; padding: 11px 10px; }
  .leaderboard-place { grid-column: 1; grid-row: 1 / 3; font-size: 17px; }
  .leaderboard-row > .avatar { grid-column: 2; grid-row: 1; }
  .leaderboard-person { grid-column: 3 / 5; grid-row: 1; }
  .leaderboard-rank { grid-column: 2 / 4; grid-row: 2; }
  .leaderboard-rank > span { font-size: 21px; }
  .leaderboard-score { grid-column: 4; grid-row: 2; }
  .leaderboard-score strong { display: inline; font-size: 16px; }
  .leaderboard-empty { grid-template-columns: auto 1fr; }
  .leaderboard-empty .button { grid-column: 1 / -1; width: 100%; }
  .lesson-grid { grid-template-columns: 1fr; gap: 14px; }
  .news-page-heading { gap: 13px; }
  .news-view-switch { width: 100%; justify-content: space-between; }
  .news-view-switch__label small { white-space: normal; }
  .news-view-controls { flex: 1 1 auto; }
  .news-view-controls button { min-width: 0; flex: 1 1 0; }
  .news-list .lesson-card { grid-template-columns: 128px 1fr; min-height: 145px; }
  .news-story-list .story-mini { grid-template-columns: 108px minmax(0, 1fr); }
  .edit-story-heading { flex-direction: column; }
  .edit-story-buttons { flex-direction: column; }
  .edit-story-buttons .button { width: 100%; }
  .lesson-card { display: grid; grid-template-columns: 128px 1fr; min-height: 145px; }
  .lesson-image { height: 100%; }
  .lesson-body { align-self: center; padding: 14px; }
  .lesson-body h3 { font-size: 18px; }
  .lesson-body p { -webkit-line-clamp: 2; }
  .lesson-meta { margin-top: 10px; }
  .progress-track { display: none; }
  .article-cover { height: 290px; }
  .article-cover__title { left: 20px; bottom: 20px; }
  .article-content { padding: 23px 18px; }
  .article-text { font-size: 17px; }
  .quiz-card, .panel { border-radius: 22px; padding: 20px 17px; }
  .article-style-picker { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-style-choice { min-height: 86px; }
  .visibility-choice > span { align-items: flex-start; flex-direction: column; gap: 4px; }
  .visibility-choice small { text-align: left; }
  .story-preview { padding: 0; }
  .story-list { grid-template-columns: 1fr; }
  .audio-dock > span { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* Personal accounts and family/friend groups */
.account-auth-card { min-height: 510px; }
.id-check-row { display: flex; align-items: stretch; gap: 8px; }
.id-check-row .input { min-width: 0; }
.id-check-row .button { flex: 0 0 auto; box-shadow: none; }
#user-id-status { display: block; margin-top: 5px; color: var(--muted); line-height: 1.4; }
#user-id-status.is-available { color: #147564; font-weight: 900; }
#user-id-status.is-taken { color: #b94235; font-weight: 900; }
.signup-locality-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field-help { margin: -9px 0 13px !important; color: var(--muted); font-size: 10px; line-height: 1.45; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 24px; padding: 5px; border-radius: 16px; background: #edf2ef; }
.auth-tabs button { min-height: 42px; border: 0; border-radius: 12px; background: transparent; color: var(--muted); font-weight: 900; cursor: pointer; }
.auth-tabs button.is-active { background: white; color: var(--ink); box-shadow: 0 4px 12px rgba(23, 60, 69, .09); }
.legacy-account-note { margin-top: 18px; padding: 14px; border: 1px solid #f1d59a; border-radius: 15px; background: #fff9e9; color: #5c4a27; font-size: 12px; line-height: 1.5; }
.legacy-account-note > p { margin: 5px 0 9px; }
.legacy-account-note > div { display: flex; flex-wrap: wrap; gap: 6px; }
.legacy-account-note span { padding: 5px 8px; border-radius: 999px; background: white; }
.account-layout { display: grid; grid-template-columns: minmax(240px, .75fr) minmax(320px, 1.25fr); gap: 22px; align-items: start; }
.account-id { margin: 4px 0 20px; color: var(--coral-dark); font-weight: 900; }
.profile-character-panel { position: relative; flex: 1 1 220px; min-width: min(220px, 100%); margin: 0; }
.reporter-picker-trigger { display: grid; width: 100%; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 2px 9px; padding: 11px 13px; border: 1px solid #f3b86b; list-style: none; background: linear-gradient(135deg, #fff5d8, #fff 60%, #fff0ea); color: var(--ink); text-align: left; box-shadow: 0 7px 18px rgba(196,119,47,.13); cursor: pointer; transition: transform .18s ease, box-shadow .18s ease; }
.reporter-picker-trigger:hover { transform: translateY(-1px); box-shadow: 0 10px 22px rgba(196,119,47,.18); }
.reporter-picker-trigger::-webkit-details-marker { display: none; }
.reporter-picker-icon { grid-row: 1 / 3; width: 42px; height: 48px; border-radius: 12px; background: #fff9ea; object-fit: cover; object-position: center 23%; box-shadow: inset 0 0 0 1px rgba(144,101,44,.1); }
.reporter-picker-trigger > b { font-size: 15px; }
.reporter-picker-trigger > small { color: var(--muted); font-size: 11px; }
.reporter-picker-trigger > em { grid-column: 3; grid-row: 1 / 3; padding: 7px 9px; border-radius: 999px; background: var(--coral); color: white; box-shadow: 0 4px 0 #cf6049; font-size: 11px; font-style: normal; font-weight: 1000; white-space: nowrap; }
.profile-character-panel[open] { flex-basis: 100%; }
.profile-character-panel[open] .reporter-picker-trigger { border-color: var(--coral); background: #fff7f2; }
.profile-character-picker-body { margin-top: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 19px; background: #f7faf8; box-shadow: 0 12px 28px rgba(23,60,69,.09); }
.profile-character-intro > p { color: var(--muted); font-size: 12px; line-height: 1.65; }
.profile-character-current { display: flex; align-items: center; gap: 14px; margin-top: 17px; padding: 13px; border-radius: 20px; background: #f4f8f6; }
.profile-character-current .profile-reporter-figure { width: 100px; height: 128px; border-color: #e53e3e; }
.profile-character-current .avatar { width: 82px; height: 82px; border-radius: 25px; }
.profile-character-current b, .profile-character-current small { display: block; }
.profile-character-current small { margin-top: 4px; color: var(--muted); font-size: 10px; }
.profile-character-groups { display: grid; gap: 13px; }
.profile-character-group { display: grid; grid-template-columns: 86px minmax(0, 1fr); align-items: start; gap: 10px; }
.profile-character-group h3 { margin: 9px 0 0; color: var(--muted); font-size: 11px; }
.profile-character-group > div { display: grid; grid-template-columns: repeat(5, minmax(60px, 1fr)); gap: 7px; }
.profile-character-choice { position: relative; display: grid; min-height: 0; aspect-ratio: 2 / 3; padding: 0; border: 2px solid #e0e9e6; border-radius: 15px; background: #f7faf8; overflow: hidden; cursor: pointer; }
.profile-character-choice .profile-character-sprite { grid-area: 1 / 1; }
.profile-character-choice small { z-index: 1; grid-area: 1 / 1; align-self: end; justify-self: stretch; padding: 5px 4px; background: rgba(255,255,255,.9); color: var(--ink); font-size: 7px; font-weight: 900; text-align: center; }
.profile-character-choice small b { display: block; margin-bottom: 1px; font-size: 8px; }
.profile-character-choice.is-selected { border-color: var(--coral); box-shadow: 0 0 0 3px rgba(255,118,87,.14), 0 7px 16px rgba(23,60,69,.1); transform: translateY(-2px); }
.profile-character-choice.is-locked { border-color: #dce4e1; cursor: not-allowed; filter: grayscale(.55); }
.profile-character-choice.is-locked .profile-character-sprite { opacity: .42; }
.profile-character-choice.is-locked small { opacity: .68; }
.character-lock { z-index: 2; grid-area: 1 / 1; align-self: center; justify-self: center; padding: 6px 8px; border-radius: 10px; background: rgba(26,49,52,.86); color: white; font-size: 9px; font-weight: 1000; box-shadow: 0 4px 12px rgba(12,37,41,.25); }
.use-photo-profile { justify-self: start; margin-top: 2px; }
.use-photo-profile input { display: none; }
.person-photo-safety-note { margin: 10px 0 2px; padding: 10px 12px; border: 1px solid #cfe5de; border-radius: 13px; background: #f1faf7; color: #356259; font-size: 10px; font-weight: 800; line-height: 1.5; }
.kakao-share-button { display: inline-flex; align-items: center; gap: 5px; }
.kakao-share-mark { position: relative; display: inline-grid; width: 24px; height: 20px; place-items: center; border-radius: 9px; background: #fee500; color: #332921; font-size: 8px; font-weight: 1000; line-height: 1; box-shadow: inset 0 0 0 1px rgba(51,41,33,.08); }
.kakao-share-mark::after { position: absolute; left: 4px; bottom: -3px; width: 7px; height: 7px; background: #fee500; content: ''; clip-path: polygon(0 0, 100% 0, 0 100%); }
.story-author-signoff { display: flex; align-items: center; gap: 9px; margin-top: 24px; padding-top: 15px; border-top: 1px dashed var(--line); color: var(--muted); }
.story-author-signoff small, .story-author-signoff b { display: block; }
.story-author-signoff small { margin-bottom: 2px; font-size: 9px; }
.story-author-signoff b { color: var(--ink); font-size: 12px; }
.create-article-button--bottom { display: grid; gap: 7px; margin: 18px 0 12px; padding-top: 17px; border-top: 1px dashed var(--line); }
.create-article-button--bottom > small { color: var(--muted); font-size: 10px; text-align: center; }
.group-builder, .groups-section, .learning-report { margin-top: 26px; }
.group-management-order { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(310px, .8fr); gap: 22px; align-items: start; }
.group-management-order > .group-builder, .group-management-order > .groups-section { margin-top: 0; }
.profile-management-panel { display: grid; grid-template-columns: minmax(220px, .55fr) minmax(0, 1.45fr); gap: 22px; align-items: center; margin-bottom: 26px; }
.profile-overview { display: flex; align-items: center; gap: 15px; }
.profile-overview .profile-reporter-figure { width: 88px; height: 132px; border-color: #e53e3e; }
.profile-overview h2 { margin: 0; }
.profile-overview .account-id { margin-bottom: 8px; }
.profile-action-toolbar { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 10px; }
.account-settings-panel { max-width: 900px; margin: 26px auto 0; }
.group-form-grid { display: grid; grid-template-columns: .7fr 1.3fr; gap: 12px; }
.group-builder textarea { resize: vertical; }
.group-builder .field > small { color: var(--muted); font-size: 11px; line-height: 1.5; }
.group-card-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.group-card { padding: 0; border: 1px solid var(--line); border-radius: 22px; background: white; box-shadow: 0 10px 25px rgba(23, 60, 69, .06); overflow: hidden; }
.group-card__head { display: flex; align-items: center; gap: 12px; padding: 16px 18px; list-style: none; cursor: pointer; }
.group-card__head::-webkit-details-marker { display: none; }
.group-card__head > div { min-width: 0; flex: 1; }
.group-card__expand { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 5px; padding: 6px 8px; border-radius: 999px; background: #edf4ff; color: var(--blue); font-size: 9px; font-weight: 900; }
.group-card__expand b { white-space: nowrap; }
.group-card__expand em { font-size: 15px; font-style: normal; line-height: 1; transition: transform .18s ease; }
.group-card[open] .group-card__expand { background: #eef3f1; color: var(--muted); }
.group-card[open] .group-card__expand em { transform: rotate(45deg); }
.group-card__body { padding: 0 18px 18px; border-top: 1px solid #edf1ef; }
.group-card__icon { display: grid; width: 50px; height: 50px; flex: 0 0 auto; place-items: center; border-radius: 16px; background: #effaf7; font-size: 25px; }
.group-card h3 { margin: 0 0 3px; }
.group-card p { margin: 0; color: var(--muted); font-size: 12px; }
.group-priority-picker { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 0 2px; }
.group-priority-picker > span { min-width: 0; }
.group-priority-picker b, .group-priority-picker small { display: block; }
.group-priority-picker small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.group-priority-picker .input { width: 105px; margin: 0; padding: 9px 10px; font-weight: 900; }
.group-members { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 13px; }
.group-member { display: flex; min-width: 0; align-items: center; gap: 8px; padding: 8px; border-radius: 13px; background: var(--paper); }
.group-member > span { min-width: 0; flex: 1; }
.group-member .text-button { flex: 0 0 auto; padding: 4px; font-size: 9px; }
.group-member b, .group-member small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.group-member b { font-size: 12px; }
.group-member small { margin-top: 2px; color: var(--muted); font-size: 10px; }
.group-add-member-form { margin-top: 13px; padding-top: 10px; border-top: 1px dashed var(--line); }
.group-rename-form { margin-top: 15px; padding-top: 12px; border-top: 1px dashed var(--line); }
.group-card__actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; padding-top: 10px; border-top: 1px dashed var(--line); }
.inline-form { display: flex; gap: 8px; }
.inline-form .input { min-width: 0; }
.group-target-field { padding: 0 4px 4px; }
.group-target-field > strong { display: block; margin: 4px 0 8px; font-size: 12px; }
.story-group-picker { display: grid; gap: 8px; }
.story-group-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.story-group-choice { position: relative; display: block; min-width: 0; cursor: pointer; }
.story-group-choice input { position: absolute; opacity: 0; pointer-events: none; }
.story-group-choice > span { display: grid; min-height: 62px; align-content: center; gap: 3px; padding: 9px; border: 1px solid #dce7e3; border-radius: 14px; background: white; box-shadow: 0 4px 10px rgba(23,60,69,.05); }
.story-group-choice b, .story-group-choice small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.story-group-choice b { font-size: 11px; }
.story-group-choice small { color: var(--muted); font-size: 8px; }
.story-group-choice input:checked + span { border-color: var(--blue); background: #f0f5ff; box-shadow: inset 0 0 0 1px var(--blue), 0 4px 12px rgba(73,101,190,.12); }
.story-group-choice input:checked + span::after { position: absolute; top: 6px; right: 7px; color: var(--blue); content: '✓'; font-size: 11px; font-weight: 1000; }
.story-group-more > summary { width: fit-content; padding: 6px 9px; border-radius: 999px; background: #eef4f2; color: var(--blue); font-size: 9px; font-weight: 900; list-style: none; cursor: pointer; }
.story-group-more > summary::-webkit-details-marker { display: none; }
.story-group-more > .story-group-card-grid { margin-top: 8px; }
.learning-report { margin-bottom: 25px; }
.group-news-fold-list { display: grid; gap: 12px; }
.group-news-fold { border: 1px solid #dfe9e5; border-radius: 20px; background: rgba(255,255,255,.82); box-shadow: var(--shadow-soft); overflow: hidden; }
.group-news-fold > summary { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 9px; padding: 14px 16px; list-style: none; cursor: pointer; }
.group-news-fold > summary::-webkit-details-marker { display: none; }
.group-news-fold > summary > span { font-size: 23px; }
.group-news-fold > summary > b { font-size: 16px; }
.group-news-fold > summary > small { color: var(--muted); font-size: 9px; font-weight: 800; }
.group-news-fold > summary > em { color: var(--blue); font-size: 9px; font-style: normal; font-weight: 900; }
.group-news-fold[open] > summary { background: #f3f8f6; }
.group-news-fold__body { padding: 14px; border-top: 1px solid #e5ece9; }
.group-news-preview-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.group-story-more { display: block; margin: 13px auto 0; }
.admin-users-panel { max-width: 900px; margin: 26px auto 0; }
.admin-counts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; margin-bottom: 14px; }
.admin-counts span { display: grid; padding: 12px; border-radius: 15px; background: #f2f7f5; text-align: center; }
.admin-counts b { font-size: 20px; }
.admin-counts small { color: var(--muted); font-size: 9px; }
.admin-user-list { display: grid; gap: 7px; }
.admin-user-list article { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid #e4ece9; border-radius: 14px; }
.admin-user-avatar { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 12px; background: #eef5f3; font-size: 21px; }
.admin-user-list b, .admin-user-list small, .admin-user-list em { display: block; }
.admin-user-list small, .admin-user-list em { overflow: hidden; color: var(--muted); font-size: 9px; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.admin-user-list > article > strong { color: var(--coral-dark); font-size: 14px; }
.admin-tier-badge { display: inline-flex; margin-left: 6px; padding: 3px 7px; border-radius: 999px; background: #edf3f1; color: #56706a; font-size: 8px; vertical-align: middle; }
.admin-tier-badge.is-special { background: #fff0bf; color: #8a6500; }
.admin-user-controls { grid-column: 2 / 4; width: 100%; }
.admin-user-controls > summary { width: fit-content; margin-left: auto; padding: 5px 8px; border-radius: 9px; background: #f2f7f5; color: #43645c; font-size: 9px; font-weight: 900; list-style: none; cursor: pointer; }
.admin-user-controls > summary::-webkit-details-marker { display: none; }
.admin-user-profile-form { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 9px; margin-top: 9px; padding: 11px; border-radius: 12px; background: #f7faf9; }
.admin-user-profile-form label > span { display: block; margin-bottom: 4px; color: var(--muted); font-size: 9px; font-weight: 900; }
.admin-user-profile-form textarea { min-height: 66px; resize: vertical; }
.admin-user-actions { grid-column: 1 / -1; display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.admin-user-profile-form .error-message { grid-column: 1 / -1; }
.admin-reset-password { padding: 6px 8px; border-radius: 10px; background: #fff5dd; font-size: 9px; white-space: nowrap; }
.story-author-place { display: block; margin-top: 2px; color: #668078; font-size: 8px; }
.story-public-location { width: fit-content; margin: 9px 0 0 43px; padding: 6px 9px; border-radius: 10px; background: #f1f7f5; color: #4a6e65; font-size: 10px; font-weight: 800; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.inquiry-panel { max-width: 900px; margin: 26px auto 0; }
.inquiry-compose > summary { width: fit-content; list-style: none; cursor: pointer; }
.inquiry-compose > summary::-webkit-details-marker { display: none; }
.inquiry-compose[open] > summary { background: #eef4f2; color: var(--ink); box-shadow: none; }
.inquiry-compose > form { margin-top: 12px; padding: 13px; border-radius: 15px; background: #f7faf9; }
.inquiry-list { display: grid; gap: 10px; margin-top: 18px; }
.inquiry-card { padding: 13px; border: 1px solid #e3ebe8; border-radius: 16px; background: #fafcfb; }
.inquiry-card__meta { display: flex; align-items: center; justify-content: space-between; gap: 9px; }
.inquiry-card__meta b { font-size: 11px; }
.inquiry-card__meta span { padding: 4px 7px; border-radius: 999px; background: #fff2d1; color: #8a671c; font-size: 8px; font-weight: 900; }
.inquiry-card.is-answered .inquiry-card__meta span { background: #e8f7f1; color: #227660; }
.inquiry-card > p, .inquiry-reply p { margin: 8px 0 0; color: #3f5559; font-size: 11px; line-height: 1.6; white-space: pre-wrap; }
.inquiry-reply { margin-top: 10px; padding: 10px; border-left: 3px solid var(--mint-dark); border-radius: 10px; background: #edf8f4; }
.inquiry-reply b { color: #27715e; font-size: 10px; }
.inquiry-reply-form { margin-top: 10px; }
.records-report { max-width: 860px; margin-right: auto; margin-left: auto; }
.records-report .empty-state .text-button { margin-top: 10px; }
.record-overview { display: grid; grid-template-columns: 190px minmax(0, 1fr); align-items: center; gap: 22px; margin-bottom: 20px; background: linear-gradient(135deg, #fff 55%, #f3f9f7); }
.record-accuracy { --accuracy: 0; display: grid; width: 150px; height: 150px; place-items: center; margin: auto; border-radius: 50%; background: conic-gradient(var(--mint-dark) calc(var(--accuracy) * 1%), #e5eeeb 0); }
.record-accuracy::before { content: ""; grid-area: 1 / 1; width: 112px; height: 112px; border-radius: 50%; background: white; box-shadow: inset 0 0 0 1px #e3ece9; }
.record-accuracy > span { position: relative; grid-area: 1 / 1; display: grid; place-items: center; }
.record-accuracy b { font-size: 27px; }
.record-accuracy small { color: var(--muted); font-size: 10px; }
.record-stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.record-stat-grid article { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 1px 8px; min-width: 0; padding: 11px; border: 1px solid #e2ebe8; border-radius: 15px; background: rgba(255,255,255,.86); }
.record-stat-grid article > span { grid-row: 1 / 3; font-size: 23px; }
.record-stat-grid b { font-size: 17px; }
.record-stat-grid small { overflow: hidden; color: var(--muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 900px) {
  .account-layout { grid-template-columns: 1fr; }
  .group-management-order, .profile-management-panel { grid-template-columns: 1fr; }
  .group-card-list { grid-template-columns: 1fr; }
  .news-photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-summary-card { grid-template-columns: 1fr; }
  .home-summary-content { grid-template-columns: minmax(150px, .75fr) minmax(270px, 1.25fr); }
  .home-summary-card--compact .home-summary-actions { width: 100%; grid-template-columns: minmax(0, 1.15fr) minmax(82px, .85fr); }
  .home-summary-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .record-overview { grid-template-columns: 150px minmax(0, 1fr); }
  .record-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.brand-mark > img { display: block; width: 100%; height: 100%; border-radius: inherit; object-fit: cover; }

@media (max-width: 620px) {
  .account-auth-card { min-height: auto; }
  .group-form-grid { grid-template-columns: 1fr; gap: 0; }
  .group-members { grid-template-columns: 1fr; }
  .group-priority-picker { align-items: stretch; flex-direction: column; }
  .group-priority-picker .input { width: 100%; }
  .inline-form { align-items: stretch; flex-direction: column; }
  .inline-form .button { width: 100%; }
  .reading-level-picker { grid-template-columns: 1fr; }
  .create-method-picker { grid-template-columns: 1fr; }
  .custom-grid, .signup-locality-grid { grid-template-columns: 1fr; gap: 0; }
  .article-region-selects { grid-template-columns: 1fr; }
  .photo-source-picker { grid-template-columns: 1fr 1fr; }
  .news-photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .group-news-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .group-news-fold > summary { grid-template-columns: auto minmax(0, 1fr) auto; padding: 12px; }
  .group-news-fold > summary > small { grid-column: 2; }
  .group-news-fold > summary > em { grid-column: 3; grid-row: 1 / 3; }
  .admin-user-list article { padding: 9px; }
  .admin-user-list article { grid-template-columns: auto minmax(0, 1fr) auto; }
  .admin-user-profile-form { grid-template-columns: 1fr; }
  .admin-user-actions, .admin-user-profile-form .error-message { grid-column: 1; }
  .admin-reset-password { grid-column: 2 / 4; justify-self: end; }
  .news-photo-media { height: 125px; }
  .home-summary-card { gap: 14px; padding: 18px 16px; border-radius: 22px; }
  .home-summary-person { align-items: center; }
  .home-summary-person h1 { font-size: 24px; }
  .home-summary-card--compact { min-height: 116px; padding: 9px 9px 7px 0; }
  .home-summary-card--compact .home-summary-person { min-height: 98px; gap: 9px; }
  .home-summary-card--compact .home-summary-person h1 { font-size: 19px; }
  .home-profile-reporter { width: 68px; height: 102px; margin-left: 7px; padding: 0; border-radius: 18px; }
  .home-summary-content { grid-template-columns: 1fr; gap: 7px; }
  .home-summary-copy .eyebrow { display: none; }
  .home-summary-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-summary-actions { display: grid; grid-template-columns: 1fr; }
  .home-summary-card--compact .home-summary-actions { grid-template-columns: minmax(0, 1.18fr) minmax(76px, .82fr); }
  .home-summary-card--compact .home-summary-actions .button { min-width: 0; padding: 8px 6px; }
  .home-summary-card--compact .home-summary-actions .button > span { font-size: 18px; }
  .home-summary-card--compact .home-summary-actions .button b { font-size: 12px; }
  .home-summary-card--compact .home-summary-actions .button small { display: none; }
  .profile-character-panel { flex-basis: 100%; }
  .profile-character-picker-body { padding: 12px; }
  .profile-action-toolbar, .profile-action-toolbar > .photo-label { width: 100%; }
  .profile-character-group { grid-template-columns: 1fr; }
  .profile-character-group > div { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .profile-character-choice { aspect-ratio: 2 / 3; }
  .story-language-switch { width: 100%; }
  .story-language-switch button { padding: 8px 4px; font-size: 10px; }
  .story-vocabulary dl { grid-template-columns: 1fr; }
  .article-region-help { align-items: flex-start; flex-direction: column; }
  .daily-compact-shelf { grid-template-columns: auto minmax(0, 1fr) auto; gap: 8px; padding: 9px; }
  .daily-compact-shelf__icon, .daily-compact-shelf > span:first-child { width: 36px; height: 36px; font-size: 20px; }
  .daily-compact-shelf .button { padding: 8px 9px; font-size: 9px; box-shadow: none; }
  .news-source-tabs { gap: 4px; padding: 4px; }
  .news-source-tabs button { display: grid; gap: 2px; padding: 7px 3px; text-align: center; }
  .news-source-tabs button b { font-size: 9px; }
  .news-source-title-row { min-width: 0; gap: 4px; }
  .news-source-title-row h2 { min-width: 0; flex: 1 1 auto; font-size: 20px; }
  .news-source-title-row .news-view-switch { width: auto; flex: 0 0 auto; margin-left: auto; padding: 2px; border-radius: 9px; }
  .news-source-heading .news-view-controls { width: auto; flex: 0 0 auto; gap: 2px; margin-left: auto; }
  .news-source-heading .news-view-controls button { width: 26px; height: 26px; min-width: 26px; flex: 0 0 26px; padding: 0; }
  .home-group-photo-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .home-group-photo-card { border-radius: 10px; }
  .record-overview { grid-template-columns: 1fr; padding: 18px 14px; }
  .record-accuracy { width: 132px; height: 132px; }
  .record-accuracy::before { width: 98px; height: 98px; }
  .record-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
  .record-stat-grid article { padding: 9px; }
}

.signup-consent, .public-policy-links { color: var(--muted); font-size: 10px; line-height: 1.5; }
.signup-consent a, .public-policy-links a, .account-delete-form a { color: var(--blue); font-weight: 900; }
.public-policy-links { margin: 14px 0 0; text-align: center; }
.account-delete-form { margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line); }
.account-delete-form h3 { margin: 0 0 5px; color: #a43b31; }
.account-delete-form > p { margin: 0 0 13px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.account-delete-form > a { display: inline-block; margin-left: 10px; font-size: 10px; }
.policy-page { width: min(820px, calc(100% - 28px)); margin: 28px auto; }
.policy-page h1 { margin: 12px 0 8px; font-size: clamp(29px, 6vw, 45px); }
.policy-page section { padding: 14px 0; border-top: 1px solid var(--line); }
.policy-page section h2 { margin: 0 0 7px; font-size: 18px; }
.policy-page p { color: #4d666b; line-height: 1.75; }
.policy-updated { color: var(--muted) !important; font-size: 12px; }
.public-delete-form { margin: 24px 0; padding: 20px; border-radius: 18px; background: #fff7f4; }
.delete-confirm-check { display: flex; align-items: flex-start; gap: 8px; margin: 4px 0 17px; color: #624b47; font-size: 12px; line-height: 1.5; }
.success-message { color: #147564; font-weight: 900; }
