:root {
  color: #16213b;
  background: #fbfaf8;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background: #fbfaf8;
  -webkit-font-smoothing: antialiased;
}

button,
input { font: inherit; }

button,
a { -webkit-tap-highlight-color: transparent; }

button { color: inherit; }

img { display: block; max-width: 100%; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-shell {
  --accent: #5f8ee6;
  --tint: #edf4ff;
  min-height: 100vh;
  background: #fbfaf8;
  color: #17213a;
}

#top,
#discover { scroll-margin-top: 72px; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: 62px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 32px;
  padding: 8px clamp(24px, 4vw, 68px);
  border-bottom: 1px solid rgba(31, 43, 73, 0.08);
  background: rgba(251, 250, 248, 0.94);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  width: max-content;
  color: #1c2947;
  text-decoration: none;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(21px, 2vw, 29px);
  letter-spacing: 0.08em;
}

.brand i { color: #e58dac; }

.main-nav {
  display: flex;
  align-items: center;
  gap: 34px;
}

.main-nav a {
  position: relative;
  padding: 10px 0;
  color: #4e566b;
  text-decoration: none;
  font-size: 14px;
  font-weight: 650;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 50%;
  right: 50%;
  bottom: 2px;
  height: 2px;
  background: #e47c9f;
  transition: left 180ms ease, right 180ms ease;
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after,
.main-nav a.is-active::after { left: 0; right: 0; }

.header-actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 10px;
}

.search-box {
  position: relative;
  width: min(260px, 23vw);
  height: 42px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 13px;
  border: 1px solid rgba(35, 46, 72, 0.13);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 8px 30px rgba(45, 56, 86, 0.06);
}

.search-box:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}

.search-box input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #26324a;
  background: transparent;
  font-size: 13px;
}

.search-box input::placeholder { color: #a1a6b1; }

.search-box > button {
  display: grid;
  place-items: center;
  padding: 4px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 70;
  padding: 7px;
  border: 1px solid rgba(35, 46, 72, 0.12);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 55px rgba(35, 44, 71, 0.16);
}

.search-results button {
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.search-results button:hover,
.search-results button:focus-visible { background: #f5f4f2; }
.search-results small { color: #8b909c; }
.search-results p { margin: 8px; color: #777e8d; font-size: 12px; }

.icon-button,
.profile-button {
  position: relative;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(35, 46, 72, 0.12);
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
}

.profile-button {
  color: #fff;
  border-color: #2f3f64;
  background: #2f3f64;
  font-family: Georgia, serif;
}

.notification-wrap { position: relative; }

.notification-dot {
  position: absolute;
  top: 7px;
  right: 6px;
  width: 7px;
  height: 7px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #ec6d8d;
}

.notification-card {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 245px;
  padding: 15px;
  border: 1px solid rgba(35, 46, 72, 0.12);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 55px rgba(35, 44, 71, 0.16);
}

.notification-card strong { font-size: 13px; }
.notification-card p { margin: 5px 0 0; color: #747b8a; font-size: 12px; line-height: 1.6; }

.hero {
  min-height: 258px;
  display: grid;
  grid-template-columns: minmax(500px, 0.9fr) minmax(620px, 1.15fr);
  align-items: center;
  gap: clamp(22px, 2.3vw, 36px);
  padding: 14px clamp(24px, 4vw, 68px) 12px;
  overflow: hidden;
  border-bottom: 1px solid rgba(31, 43, 73, 0.08);
  background: #fffdfa;
}

.hero-copy { max-width: 560px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 9px;
  color: #d86891;
  font-size: 14px;
  font-weight: 750;
  letter-spacing: 0.08em;
}

.hero h1 {
  margin: 0;
  color: #1b2a49;
  font-family: "Noto Serif SC", "Songti SC", STSong, Georgia, serif;
  font-size: clamp(40px, 3.7vw, 56px);
  font-weight: 550;
  line-height: 1.1;
  letter-spacing: -0.045em;
}

.hero-copy > p:not(.hero-note) {
  margin: 11px 0 17px;
  color: #697184;
  font-size: clamp(15px, 1.25vw, 19px);
  line-height: 1.55;
}

.primary-button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 24px;
  border: 0;
  border-radius: 14px;
  color: #fff;
  background: var(--accent);
  box-shadow: 0 10px 28px color-mix(in srgb, var(--accent) 28%, transparent);
  cursor: pointer;
  font-weight: 750;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.primary-button:hover { transform: translateY(-2px); box-shadow: 0 14px 34px color-mix(in srgb, var(--accent) 34%, transparent); }
.primary-button:active { transform: translateY(0); }

.hero-note {
  margin: 8px 0 0;
  color: #959aa6;
  font-size: 11px;
}

.photocard-deck {
  position: relative;
  min-height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 0;
}

.photo-card {
  position: relative;
  flex: 0 0 clamp(126px, 9.5vw, 140px);
  height: clamp(218px, 16.5vw, 240px);
  margin-left: 4px;
  padding: 8px 8px 54px;
  overflow: hidden;
  border: 1px solid rgba(33, 45, 76, 0.11);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 45px rgba(40, 50, 80, 0.13);
  cursor: pointer;
  transform-origin: center 85%;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.photo-card:first-child { margin-left: 0; }
.photo-card-1 { transform: rotate(-4deg) translateY(8px); }
.photo-card-2 { transform: rotate(2deg) translateY(-8px); }
.photo-card-3 { transform: rotate(-1deg) translateY(3px); }
.photo-card-4 { transform: rotate(3deg) translateY(-4px); }
.photo-card-5 { transform: rotate(-2deg) translateY(7px); }

.photo-card:hover,
.photo-card:focus-visible,
.photo-card.is-active {
  z-index: 4;
  transform: translateY(-16px) rotate(0);
  border-color: var(--accent);
  box-shadow: 0 24px 52px rgba(40, 50, 80, 0.2);
  outline: none;
}

.photo-card > img {
  width: 100%;
  height: calc(100% - 48px);
  object-fit: cover;
  border-radius: 4px;
  background: #eef0f3;
}

.photo-card-meta {
  position: absolute;
  left: 13px;
  right: 11px;
  bottom: 10px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  text-align: left;
}

.photo-card-meta strong {
  max-width: 100%;
  overflow: hidden;
  color: #263657;
  font-family: Georgia, serif;
  font-size: clamp(13px, 1vw, 16px);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.photo-card-meta small {
  max-width: 100%;
  margin-top: 3px;
  overflow: hidden;
  color: #858b98;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-arrow {
  position: absolute;
  top: 14px;
  right: 10px;
  bottom: auto;
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(34, 46, 76, 0.15);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 4px 12px rgba(31, 42, 68, 0.12);
}

.themes {
  padding: 18px clamp(24px, 4vw, 68px) 24px;
  scroll-margin-top: 76px;
}

.section-heading {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.section-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--accent);
  background: var(--tint);
}

.section-heading p { margin: 0 0 2px; color: #a0a4ae; font-size: 10px; letter-spacing: 0.16em; }
.section-heading h2 { margin: 0; color: #26324b; font-size: 19px; }
.section-heading .section-aside { align-self: end; margin-bottom: 3px; color: #9a9faa; letter-spacing: 0; }

.theme-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 10px;
}

.theme-tabs button {
  min-width: 0;
  min-height: 48px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 13px;
  background: var(--group-tint);
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease, background 160ms ease;
}

.theme-tabs button:hover { transform: translateY(-2px); }
.theme-tabs button.is-active { border-color: var(--group-color); background: #fff; }
.theme-tabs button:focus-visible { outline: 3px solid color-mix(in srgb, var(--group-color) 24%, transparent); outline-offset: 2px; }
.theme-tabs button > span:nth-child(2) { overflow: hidden; color: var(--group-color); font-family: Georgia, serif; font-size: clamp(14px, 1.35vw, 20px); font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.tab-mark { display: grid; place-items: center; color: var(--group-color); }
.tab-arrow { color: var(--group-color); }

.lesson-preview {
  min-height: 390px;
  display: grid;
  grid-template-columns: 1fr 1.06fr;
  overflow: hidden;
  border: 1px solid rgba(34, 46, 76, 0.12);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 18px 60px rgba(43, 53, 79, 0.08);
}

.lesson-copy { padding: clamp(22px, 2.2vw, 30px); }

.lesson-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.lesson-kicker { margin: 0 0 7px; color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: 0.12em; }

.lesson-title-row h2 {
  margin: 0;
  color: #24406f;
  font-family: Georgia, "Noto Serif SC", serif;
  font-size: clamp(27px, 2.7vw, 42px);
  line-height: 1.1;
}

.lesson-title-row h2 span { color: #4f5b70; font-family: inherit; font-size: 0.58em; font-weight: 550; }

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  border-radius: 999px;
  color: var(--accent);
  background: var(--tint);
  font-size: 11px;
  white-space: nowrap;
}

.live-pill > span { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.lesson-intro { margin: 13px 0 20px; color: #7b8190; font-size: 13px; line-height: 1.7; }

.phrase-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 100px auto;
  align-items: center;
  gap: 16px;
  min-height: 96px;
  padding: 17px;
  border: 1px solid rgba(35, 47, 77, 0.1);
  border-radius: 18px;
  background: #fefefe;
  box-shadow: 0 8px 28px rgba(44, 55, 82, 0.05);
}

.sound-button {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: var(--accent);
  background: var(--tint);
  cursor: pointer;
}

.phrase-text { min-width: 0; display: flex; flex-direction: column; }
.phrase-text strong { overflow: visible; color: #19233a; font-size: clamp(17px, 1.5vw, 22px); line-height: 1.35; text-overflow: clip; white-space: normal; }
.phrase-text span { margin-top: 5px; color: #747b8a; font-size: 13px; }
.phrase-text small { margin-top: 4px; color: #adb0b8; font-size: 9px; }

.waveform { color: color-mix(in srgb, var(--accent) 65%, #fff); }
.phrase-card.is-playing .waveform { animation: wave 650ms ease-in-out infinite alternate; }

@keyframes wave { to { transform: scaleX(0.88); opacity: 0.58; } }

.save-button { padding: 6px; border: 0; color: #8d93a1; background: transparent; cursor: pointer; }
.save-button.is-saved { color: #e87095; }

.feature-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
  margin-top: 14px;
}

.feature-row button {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 10px;
  border: 1px solid rgba(35, 47, 77, 0.08);
  border-radius: 13px;
  background: #faf9f7;
  cursor: pointer;
  text-align: left;
}

.feature-row button > span:first-child {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--accent);
  background: var(--tint);
}

.feature-row button > span:last-child { min-width: 0; display: flex; flex-direction: column; }
.feature-row strong { font-size: 12px; }
.feature-row small { margin-top: 2px; overflow: hidden; color: #9b9faa; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }

.lesson-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 14px;
}

.weekly-stat { display: flex; align-items: baseline; gap: 6px; color: #858b98; }
.weekly-stat span, .weekly-stat small { font-size: 12px; }
.weekly-stat strong { color: var(--accent); font-family: Georgia, serif; font-size: 31px; }
.lesson-button { min-width: 220px; }

.lesson-photo { position: relative; min-height: 100%; overflow: hidden; background: #eef0f2; }
.lesson-photo > img { width: 100%; height: 100%; min-height: 390px; object-fit: cover; transition: opacity 160ms ease; }
.photo-caption {
  position: absolute;
  left: 22px;
  bottom: 22px;
  min-width: 190px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 14px;
  color: #1d2943;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
}
.photo-caption span, .photo-caption small { display: block; }
.photo-caption span { color: var(--accent); font-size: 9px; font-weight: 800; letter-spacing: 0.14em; }
.photo-caption strong { display: block; margin: 3px 0 4px; font-family: Georgia, serif; font-size: 21px; }
.photo-caption small { color: #727988; font-size: 9px; }

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px clamp(24px, 4vw, 68px) 28px;
  color: #9a9fa9;
  font-size: 10px;
}

.footer-brand { display: flex; align-items: center; gap: 8px; font-family: Georgia, serif; letter-spacing: 0.12em; }
.footer-brand i { color: var(--accent); }

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(20, 28, 46, 0.5);
  backdrop-filter: blur(8px);
}

.lesson-modal {
  position: relative;
  width: min(520px, 100%);
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(20, 29, 50, 0.3);
}

.modal-close { position: absolute; top: 18px; right: 18px; width: 36px; height: 36px; display: grid; place-items: center; border: 0; border-radius: 50%; background: #f3f2ef; cursor: pointer; }
.modal-step { margin: 0 0 10px; color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: 0.1em; }
.lesson-modal h2 { margin: 0 0 26px; font-family: Georgia, "Noto Serif SC", serif; font-size: 30px; }
.modal-korean { margin: 0; color: #19233a; font-size: clamp(24px, 4vw, 35px); font-weight: 750; line-height: 1.35; }
.modal-translation { margin: 9px 0 22px; color: #737a89; }
.modal-audio-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; padding: 14px; border-radius: 16px; background: var(--tint); }
.modal-audio-row button { width: 43px; height: 43px; display: grid; place-items: center; border: 0; border-radius: 50%; color: #fff; background: var(--accent); cursor: pointer; }
.modal-audio-row > i { width: 100%; color: color-mix(in srgb, var(--accent) 60%, #fff); font-size: 44px; text-align: center; }

.feature-row button.is-selected {
  border-color: color-mix(in srgb, var(--accent) 45%, #fff);
  background: var(--tint);
}

[hidden] { display: none !important; }
.modal-audio-row small { color: #747b89; }
.record-button { width: 100%; min-height: 52px; display: flex; align-items: center; justify-content: center; gap: 9px; margin-top: 18px; border: 0; border-radius: 14px; color: #fff; background: var(--accent); cursor: pointer; font-weight: 750; }
.lesson-success { display: flex; align-items: center; gap: 12px; margin-top: 18px; padding: 14px; border: 1px solid color-mix(in srgb, var(--accent) 32%, #fff); border-radius: 14px; color: var(--accent); background: var(--tint); }
.lesson-success div { display: flex; flex-direction: column; gap: 3px; }
.lesson-success span { color: #687082; font-size: 12px; }
.modal-note { margin: 12px 0 0; color: #a0a4ae; font-size: 10px; text-align: center; }

@media (max-width: 1180px) {
  .topbar { grid-template-columns: auto 1fr auto; }
  .main-nav { justify-self: center; gap: 20px; }
  .search-box { width: 44px; }
  .search-box input { display: none; }
  .search-box:focus-within { position: absolute; right: 124px; width: min(280px, calc(100vw - 160px)); }
  .search-box:focus-within input { display: block; }
  .hero { grid-template-columns: minmax(430px, 0.82fr) minmax(560px, 1.18fr); gap: 20px; }
  .photo-card { flex-basis: 145px; height: 260px; margin-left: -34px; }
  .phrase-card { grid-template-columns: auto minmax(0, 1fr) auto; }
  .waveform { display: none; }
  .feature-row button > span:last-child small { display: none; }
}

@media (max-width: 900px) {
  .topbar { grid-template-columns: 1fr auto; }
  .main-nav { display: none; }
  .hero { grid-template-columns: 1fr; padding-top: 42px; }
  .hero-copy { max-width: 670px; }
  .hero h1 br { display: none; }
  .photocard-deck { justify-content: flex-start; min-height: 294px; overflow-x: auto; padding: 18px 22px 30px; scrollbar-width: none; }
  .photocard-deck::-webkit-scrollbar { display: none; }
  .photo-card { flex-basis: 170px; height: 270px; margin-left: 10px; transform: none; }
  .photo-card:first-child { margin-left: 0; }
  .photo-card:hover, .photo-card:focus-visible, .photo-card.is-active { transform: translateY(-8px); }
  .theme-tabs { display: flex; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
  .theme-tabs::-webkit-scrollbar { display: none; }
  .theme-tabs button { flex: 0 0 170px; }
  .lesson-preview { grid-template-columns: 1fr; }
  .lesson-photo { min-height: 360px; order: -1; }
  .lesson-photo > img { min-height: 360px; max-height: 520px; }
}

@media (max-width: 600px) {
  .topbar { min-height: 64px; padding: 10px 16px; }
  .brand { font-size: 20px; }
  .header-actions { gap: 7px; }
  .profile-button { display: none; }
  .search-box:focus-within { right: 60px; width: calc(100vw - 76px); }
  .hero { min-height: auto; padding: 38px 18px 25px; }
  .hero h1 { font-size: 39px; }
  .hero-copy > p:not(.hero-note) { margin: 15px 0 23px; font-size: 14px; }
  .photocard-deck { margin-inline: -18px; min-height: 250px; padding-inline: 18px; }
  .photo-card { flex-basis: 145px; height: 230px; }
  .themes { padding: 26px 16px; }
  .section-heading { grid-template-columns: auto 1fr; }
  .section-aside { display: none; }
  .theme-tabs button { flex-basis: 154px; }
  .lesson-preview { border-radius: 18px; }
  .lesson-photo { min-height: 250px; }
  .lesson-photo > img { min-height: 250px; max-height: 320px; }
  .lesson-copy { padding: 22px 18px; }
  .lesson-title-row { align-items: flex-end; }
  .lesson-title-row h2 { font-size: 29px; }
  .live-pill { display: none; }
  .phrase-card { grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; padding: 13px; }
  .sound-button { width: 44px; height: 44px; }
  .phrase-text strong { font-size: 17px; }
  .phrase-text small { display: none; }
  .feature-row { grid-template-columns: 1fr; }
  .feature-row button > span:last-child small { display: block; }
  .lesson-footer { align-items: stretch; flex-direction: column; }
  .lesson-button { width: 100%; min-width: 0; }
  footer { align-items: flex-start; flex-direction: column; padding-inline: 18px; }
  footer p { margin: 0; line-height: 1.6; }
  .lesson-modal { padding: 26px 20px; }
}

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

/* Restored visual direction from the approved dreamy collage concept. */
body {
  background:
    radial-gradient(circle at 7% 8%, rgba(255, 214, 229, 0.45), transparent 26%),
    radial-gradient(circle at 92% 12%, rgba(202, 224, 255, 0.5), transparent 28%),
    #fffdfc;
}

.site-shell {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 8% 43%, rgba(255, 228, 220, 0.42), transparent 20%),
    radial-gradient(circle at 94% 58%, rgba(221, 218, 255, 0.38), transparent 24%),
    linear-gradient(180deg, #fffdfc 0%, #fff 63%, #fffafc 100%);
}

.topbar {
  min-height: 64px;
  border-bottom-color: rgba(115, 96, 145, 0.08);
  background: rgba(255, 253, 253, 0.82);
  box-shadow: 0 8px 35px rgba(118, 95, 150, 0.04);
}

.brand {
  font-size: clamp(23px, 2vw, 30px);
}

.brand i,
.footer-brand i {
  color: #dd8cad;
  filter: drop-shadow(0 0 7px rgba(238, 157, 198, 0.55));
}

.hero {
  position: relative;
  isolation: isolate;
  min-height: 390px;
  grid-template-columns: minmax(500px, 0.88fr) minmax(740px, 1.32fr);
  gap: 8px;
  padding: 28px clamp(34px, 3.8vw, 58px) 26px;
  border-bottom: 0;
  background:
    linear-gradient(104deg, rgba(255, 253, 250, 0.96) 0%, rgba(255, 251, 253, 0.82) 35%, rgba(244, 248, 255, 0.58) 100%),
    radial-gradient(circle at 14% 28%, rgba(255, 203, 222, 0.58), transparent 28%),
    radial-gradient(circle at 72% 18%, rgba(204, 219, 255, 0.66), transparent 29%);
}

.hero::before {
  content: "";
  position: absolute;
  z-index: -2;
  inset: 0;
  opacity: 0.82;
  background:
    linear-gradient(120deg, transparent 0 54%, rgba(202, 224, 255, 0.28) 54% 58%, transparent 58%),
    linear-gradient(14deg, transparent 0 67%, rgba(255, 209, 231, 0.3) 67% 71%, transparent 71%),
    repeating-linear-gradient(138deg, transparent 0 48px, rgba(255, 255, 255, 0.48) 49px 51px, transparent 52px 96px);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 93%);
}

.hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  right: -7%;
  bottom: -84px;
  width: 76%;
  height: 190px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  background: linear-gradient(108deg, rgba(205, 228, 255, 0.3), rgba(255, 213, 231, 0.42), rgba(222, 214, 255, 0.34));
  box-shadow: inset 0 0 45px rgba(255, 255, 255, 0.75), 0 0 45px rgba(178, 202, 255, 0.18);
  transform: rotate(-4deg);
  clip-path: polygon(0 20%, 16% 0, 42% 28%, 61% 5%, 78% 25%, 100% 7%, 96% 86%, 72% 100%, 38% 85%, 9% 100%);
}

.hero-copy {
  position: relative;
  z-index: 4;
  align-self: center;
  max-width: 520px;
}

.eyebrow {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 0 0 8px;
  color: #e66f9e;
  letter-spacing: normal;
}

.eyebrow-script {
  position: relative;
  font-family: "Segoe Print", "Bradley Hand", cursive;
  font-size: clamp(30px, 3.1vw, 46px);
  font-weight: 500;
  font-style: italic;
  line-height: 1;
  transform: rotate(-5deg);
}

.eyebrow-script::before {
  content: "✦";
  position: absolute;
  left: -30px;
  top: 8px;
  color: #f0a4c0;
  font-size: 20px;
}

.eyebrow small {
  color: #5b6680;
  font-size: 16px;
  font-weight: 700;
}

.hero h1 {
  color: #172440;
  font-size: clamp(46px, 3.8vw, 56px);
  font-weight: 520;
  line-height: 1.08;
  letter-spacing: -0.055em;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.88);
  white-space: nowrap;
}

.hero h1::after {
  content: "";
  display: inline-block;
  width: 76px;
  height: 15px;
  margin-left: -64px;
  border-top: 5px solid #f082aa;
  border-radius: 50%;
  transform: translate(54px, 16px) rotate(-8deg);
}

.hero-copy > p:not(.hero-note, .hero-handnote) {
  margin: 14px 0 22px;
  color: #707a92;
  font-size: clamp(15px, 1.35vw, 19px);
}

.primary-button {
  min-height: 56px;
  padding: 0 34px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 999px;
  background: linear-gradient(105deg, #f39ac0 0%, #bd93f5 48%, #6ec8f4 100%);
  box-shadow: 0 12px 28px rgba(141, 139, 226, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.primary-button:hover {
  box-shadow: 0 16px 34px rgba(141, 139, 226, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.hero-note {
  margin: 8px 0 0;
  color: #a8a5b1;
}

.hero-handnote,
.deck-note,
.lesson-handnote {
  font-family: "Segoe Print", "Bradley Hand", cursive;
  font-style: italic;
  line-height: 1.25;
}

.hero-handnote {
  position: absolute;
  right: 8px;
  bottom: 0;
  margin: 0;
  color: #9f95aa;
  font-size: 14px;
  text-align: center;
  transform: rotate(-8deg);
}

.hero-crystal {
  position: absolute;
  z-index: 1;
  display: block;
  border: 1px solid rgba(255, 255, 255, 0.86);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.7), rgba(199, 217, 255, 0.28), rgba(255, 200, 226, 0.3));
  box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.7), 0 12px 40px rgba(143, 159, 210, 0.14);
  clip-path: polygon(50% 0, 100% 28%, 78% 100%, 15% 83%, 0 26%);
  pointer-events: none;
}

.hero-crystal-one {
  top: -34px;
  left: 27%;
  width: 96px;
  height: 130px;
  transform: rotate(-21deg);
}

.hero-crystal-two {
  right: 18%;
  bottom: -54px;
  width: 125px;
  height: 150px;
  transform: rotate(34deg);
}

.hero-sparkle {
  position: absolute;
  z-index: 2;
  color: #86aef4;
  text-shadow: 0 0 15px currentColor;
  pointer-events: none;
}

.hero-sparkle-one { left: 31%; top: 45%; font-size: 23px; }
.hero-sparkle-two { right: 2.8%; bottom: 16%; color: #f09dbd; font-size: 30px; }

.photocard-deck {
  z-index: 3;
  min-height: 330px;
  justify-content: flex-start;
  padding: 22px 2px 5px 15px;
  overflow: visible;
}

.deck-note {
  position: absolute;
  top: -2px;
  right: 4px;
  z-index: 8;
  margin: 0;
  color: #84889c;
  font-size: 12px;
  text-align: right;
  transform: rotate(4deg);
}

.photo-card {
  flex-basis: clamp(142px, 11vw, 164px);
  height: clamp(286px, 22vw, 318px);
  margin-left: -11px;
  padding: 10px 10px 69px;
  overflow: visible;
  border: 1px solid rgba(255, 255, 255, 0.92);
  border-radius: 3px;
  background: linear-gradient(155deg, #fff 58%, var(--card-tint) 100%);
  box-shadow: 0 20px 42px rgba(68, 62, 102, 0.18), 0 2px 0 rgba(255, 255, 255, 0.9) inset;
}

.photo-card::before {
  content: "";
  position: absolute;
  z-index: 4;
  top: -9px;
  left: 50%;
  width: 68px;
  height: 20px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: linear-gradient(90deg, rgba(223, 226, 255, 0.52), rgba(255, 255, 255, 0.78), rgba(255, 212, 228, 0.48));
  box-shadow: 0 3px 10px rgba(95, 93, 130, 0.09);
  transform: translateX(-50%) rotate(-3deg);
  backdrop-filter: blur(3px);
}

.photo-card:first-child { margin-left: 0; }
.photo-card-1 { z-index: 5; transform: rotate(2.5deg) translateY(3px); }
.photo-card-2 { z-index: 4; transform: rotate(-2.2deg) translateY(18px); }
.photo-card-3 { z-index: 3; transform: rotate(1.8deg) translateY(5px); }
.photo-card-4 { z-index: 2; transform: rotate(-1.7deg) translateY(20px); }
.photo-card-5 { z-index: 1; transform: rotate(2.6deg) translateY(10px); }

.photo-card:hover,
.photo-card:focus-visible,
.photo-card.is-active {
  z-index: 10;
  border-color: color-mix(in srgb, var(--card-accent) 45%, #fff);
  transform: translateY(-9px) rotate(0deg) scale(1.025);
  box-shadow: 0 27px 55px rgba(79, 68, 118, 0.24), 0 0 0 2px color-mix(in srgb, var(--card-accent) 16%, transparent);
}

.photo-card > img {
  height: calc(100% - 55px);
  border-radius: 1px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

.photo-card-meta {
  left: 13px;
  right: 10px;
  bottom: 12px;
}

.photo-card-meta strong {
  color: var(--card-accent);
  overflow: visible;
  font-size: clamp(14px, 1.08vw, 16px);
  text-overflow: clip;
}

.photo-card-meta small {
  max-width: calc(100% - 34px);
  color: #9295a3;
  font-size: 9px;
}

.card-arrow {
  top: auto;
  right: 11px;
  bottom: 15px;
  width: 29px;
  height: 29px;
  color: var(--card-accent);
  border-color: color-mix(in srgb, var(--card-accent) 30%, #fff);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: none;
}

.themes {
  position: relative;
  z-index: 4;
  padding: 8px clamp(30px, 3vw, 44px) 18px;
  background:
    radial-gradient(circle at 2% 30%, rgba(255, 218, 224, 0.32), transparent 20%),
    radial-gradient(circle at 98% 62%, rgba(212, 222, 255, 0.38), transparent 22%),
    rgba(255, 255, 255, 0.74);
}

.section-heading {
  min-height: 34px;
  margin-bottom: 3px;
}

.section-icon {
  color: #6a9bec;
  background: transparent;
  filter: drop-shadow(0 0 8px rgba(108, 159, 235, 0.35));
}

.section-heading > div > p { display: none; }
.section-heading h2 { color: #24304b; font-size: 20px; }

.section-heading .section-aside {
  color: #9b92aa;
  font-family: "Segoe Print", "Bradley Hand", cursive;
  font-size: 12px;
  font-style: italic;
  transform: rotate(-3deg);
}

.theme-tabs {
  gap: 7px;
  margin-bottom: 10px;
}

.theme-tabs button {
  min-height: 52px;
  padding: 0 18px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 12px;
  background: linear-gradient(110deg, rgba(255, 255, 255, 0.46), var(--group-tint));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85), 0 8px 22px rgba(95, 89, 135, 0.06);
}

.theme-tabs button.is-active {
  border-color: var(--group-color);
  background: linear-gradient(110deg, #fff, var(--group-tint));
  box-shadow: 0 8px 26px color-mix(in srgb, var(--group-color) 16%, transparent), inset 0 1px 0 #fff;
}

.theme-tabs button > span:nth-child(2) {
  font-size: clamp(15px, 1.5vw, 22px);
}

.tab-mark {
  font-size: 18px;
  filter: drop-shadow(0 0 6px color-mix(in srgb, var(--group-color) 44%, transparent));
}

.lesson-preview {
  min-height: 410px;
  grid-template-columns: 0.98fr 1.08fr;
  overflow: visible;
  border: 1px solid rgba(255, 255, 255, 0.92);
  border-radius: 25px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 22px 64px rgba(97, 82, 130, 0.12), 0 0 0 7px rgba(255, 255, 255, 0.44);
}

.lesson-copy {
  position: relative;
  z-index: 3;
  padding: clamp(24px, 2vw, 28px);
  overflow: hidden;
  border-radius: 25px 0 0 25px;
  background:
    radial-gradient(circle at 0 100%, rgba(255, 227, 217, 0.25), transparent 24%),
    rgba(255, 255, 255, 0.96);
}

.lesson-copy::after {
  content: "✦";
  position: absolute;
  right: 24px;
  bottom: 18px;
  color: color-mix(in srgb, var(--accent) 38%, #fff);
  font-size: 33px;
  opacity: 0.55;
}

.lesson-kicker { display: none; }

.lesson-title-row h2 {
  color: #244477;
  font-size: clamp(28px, 2.8vw, 43px);
}

.lesson-title-row h2::before {
  content: "✦";
  margin-right: 12px;
  color: var(--accent);
  font-size: 0.8em;
  filter: drop-shadow(0 0 8px color-mix(in srgb, var(--accent) 38%, transparent));
}

.lesson-title-row h2 span {
  color: #4a5771;
  font-size: 0.63em;
}

.live-pill { display: none; }

.lesson-intro {
  margin: 9px 0 14px;
  font-size: 13px;
}

.phrase-card {
  min-height: 104px;
  grid-template-columns: auto minmax(0, 1fr) 70px auto;
  gap: 16px;
  padding: 18px 20px;
  border-color: rgba(96, 112, 150, 0.12);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 30px rgba(81, 89, 122, 0.06), inset 0 1px 0 #fff;
}

.sound-button {
  width: 62px;
  height: 62px;
  font-size: 21px;
  box-shadow: 0 8px 20px color-mix(in srgb, var(--accent) 14%, transparent);
}

.phrase-text strong { font-size: clamp(18px, 1.65vw, 24px); }
.phrase-text span { font-size: 14px; }

.feature-row { margin-top: 12px; }
.feature-row { margin-top: 10px; }

.feature-row button {
  padding: 9px 12px;
  border-color: rgba(113, 105, 143, 0.08);
  background: linear-gradient(115deg, #fff, rgba(248, 246, 250, 0.88));
}

.feature-row button > span:first-child {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.lesson-footer { margin-top: 11px; }
.lesson-footer { min-height: 50px; margin-top: 9px; }
.lesson-button { min-width: 250px; }

.lesson-photo {
  min-height: 410px;
  overflow: hidden;
  border-radius: 0 25px 25px 0;
  background: #eef0f5;
}

.lesson-photo::before {
  content: "";
  position: absolute;
  z-index: 4;
  top: -9px;
  left: 44%;
  width: 118px;
  height: 27px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: linear-gradient(90deg, rgba(216, 223, 255, 0.45), rgba(255, 255, 255, 0.7), rgba(255, 211, 229, 0.4));
  transform: rotate(-4deg);
  backdrop-filter: blur(4px);
}

.lesson-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 220, 234, 0.05), transparent 42%, rgba(193, 218, 255, 0.1));
}

.lesson-photo > img {
  position: absolute;
  inset: 0;
  z-index: 0;
  height: 100%;
  min-height: 0;
}

.lesson-handnote {
  position: absolute;
  z-index: 5;
  top: 20px;
  right: 18px;
  margin: 0;
  color: rgba(255, 255, 255, 0.96);
  font-size: 13px;
  text-align: right;
  text-shadow: 0 2px 12px rgba(21, 27, 45, 0.58);
  transform: rotate(3deg);
}

.photo-caption {
  z-index: 4;
  left: 24px;
  bottom: 20px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 12px 28px rgba(24, 31, 54, 0.16);
}

footer {
  min-height: 52px;
  padding-top: 12px;
  padding-bottom: 14px;
  background: linear-gradient(90deg, rgba(255, 247, 249, 0.62), rgba(248, 250, 255, 0.7));
}

.modal-backdrop {
  background: rgba(43, 37, 66, 0.46);
}

.lesson-modal {
  border-color: rgba(255, 255, 255, 0.88);
  background:
    radial-gradient(circle at 100% 0, rgba(220, 218, 255, 0.55), transparent 34%),
    radial-gradient(circle at 0 100%, rgba(255, 218, 231, 0.45), transparent 34%),
    #fff;
}

@media (max-width: 1180px) {
  .hero {
    min-height: 370px;
    grid-template-columns: minmax(390px, 0.74fr) minmax(560px, 1.2fr);
    padding-inline: 30px;
  }
  .hero h1 { font-size: 50px; }
  .photo-card { flex-basis: 134px; height: 282px; margin-left: -18px; }
  .photocard-deck { min-height: 310px; padding-left: 5px; }
  .hero-handnote, .deck-note { display: none; }
  .lesson-button { min-width: 210px; }
}

@media (max-width: 900px) {
  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 22px;
    padding-top: 44px;
  }
  .hero-copy { max-width: 720px; }
  .hero h1 { white-space: normal; }
  .hero-handnote { display: block; right: 10%; bottom: 2px; }
  .photocard-deck {
    min-height: 315px;
    justify-content: flex-start;
    margin-inline: -30px;
    padding: 30px 30px 38px;
    overflow-x: auto;
  }
  .photo-card { flex-basis: 158px; height: 292px; margin-left: 10px; }
  .theme-tabs button { flex-basis: 178px; }
  .lesson-preview { grid-template-columns: 1fr; }
  .lesson-photo { min-height: 365px; order: -1; border-radius: 25px 25px 0 0; }
  .lesson-photo > img { min-height: 365px; max-height: 500px; }
  .lesson-photo > img { position: relative; height: 100%; min-height: 365px; }
  .lesson-copy { border-radius: 0 0 25px 25px; }
}

@media (max-width: 600px) {
  .hero { padding: 36px 18px 22px; }
  .eyebrow { gap: 9px; }
  .eyebrow-script { font-size: 31px; }
  .eyebrow small { font-size: 13px; }
  .hero h1 { font-size: 40px; }
  .hero h1::after { display: none; }
  .hero-copy > p:not(.hero-note, .hero-handnote) { font-size: 14px; }
  .hero-handnote { display: none; }
  .primary-button { min-height: 52px; padding-inline: 27px; }
  .photocard-deck { min-height: 270px; margin-inline: -18px; padding-inline: 18px; }
  .photo-card { flex-basis: 145px; height: 252px; }
  .themes { padding: 22px 16px; }
  .section-heading .section-aside { display: none; }
  .lesson-photo { min-height: 265px; }
  .lesson-photo > img { min-height: 265px; max-height: 330px; }
  .lesson-copy { padding: 24px 18px; }
  .lesson-title-row h2::before { margin-right: 6px; }
  .phrase-card { min-height: 96px; padding: 13px; }
  .sound-button { width: 48px; height: 48px; }
  .lesson-button { min-width: 0; }
}
