/* 한글닷 소개 사이트 — 독립 신규 디자인 (website-claude-fresh 전용) */

@font-face {
  font-family: "Paperlogy";
  src: url("/fonts/Paperlogy-5Medium.ttf") format("truetype");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "Paperlogy";
  src: url("/fonts/Paperlogy-3Light.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Noto Serif KR";
  src: url("/fonts/NotoSerifKR-Medium.ttf") format("truetype");
  font-weight: 600;
  font-display: swap;
}

:root {
  --teal-100: #B1D7D7;
  --teal-300: #6FD2D7;
  --teal-600: #3B9D99;
  --coral-100: #E8B4B0;
  --coral-300: #D76F6A;
  --coral-600: #9D3B40;
  --pink-100: #F0C2D4;
  --pink-300: #D76F9E;
  --pink-600: #9D3B6E;
  --gold-100: #F0DFB0;
  --gold-300: #EDBE45;
  --gold-600: #B8901F;

  --ink: #241F19;
  --ink-soft: #5E594E;
  --ink-faint: #8B8577;
  --paper: #FBF6EA;
  --paper-alt: #FFFDF8;
  --line: rgba(36, 31, 25, .12);

  --font-display: "Paperlogy", "Apple SD Gothic Neo", sans-serif;
  --font-body: "Paperlogy", "Apple SD Gothic Neo", sans-serif;
  --font-serif: "Noto Serif KR", serif;
  --font-label: "Dotum", "돋움", "Apple SD Gothic Neo", sans-serif;

  --container: 1120px;
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; text-decoration: none; }

.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;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: var(--paper-alt);
  padding: 12px 18px;
  border-radius: 0 0 10px 0;
  z-index: 1000;
}
.skip-link:focus {
  left: 0;
}

.icon-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

.icon {
  width: 22px;
  height: 22px;
  fill: currentColor;
  stroke: currentColor;
  flex-shrink: 0;
}
.icon-sm { width: 17px; height: 17px; }
.icon-flip { transform: scaleX(-1); }

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(251, 246, 234, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
}
.brand-mark {
  width: 32px;
  height: 32px;
  border-radius: 9px;
}

.logo-kr {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--ink);
  letter-spacing: -.01em;
}
.logo-kr .dot { color: var(--coral-600); }

.logo-en {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--ink);
}
.logo-en .o-accent { color: var(--coral-600); }

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 0;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  margin: 0 auto;
  transition: transform .25s ease, opacity .25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.site-nav {
  position: absolute;
  top: 64px;
  left: 0;
  right: 0;
  background: var(--paper-alt);
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 8px 20px 20px;
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}
.site-nav.is-open { max-height: 320px; }
.site-nav a {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-weight: 600;
  color: var(--ink-soft);
}
.site-nav a:last-child { border-bottom: 0; }

@media (min-width: 860px) {
  .nav-toggle { display: none; }
  .site-nav {
    position: static;
    flex-direction: row;
    max-height: none;
    overflow: visible;
    background: none;
    border: 0;
    padding: 0;
    gap: 28px;
  }
  .site-nav a {
    padding: 0;
    border: 0;
    font-weight: 500;
    color: var(--ink-soft);
  }
  .site-nav a:hover { color: var(--coral-600); }
}

/* ---------- Reveal on scroll ---------- */

[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}
[data-reveal].in-view {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .98rem;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.btn-primary {
  background: var(--coral-600);
  color: var(--paper-alt);
  box-shadow: 0 10px 24px -10px rgba(157, 59, 64, .55);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 28px -10px rgba(157, 59, 64, .6); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--line);
}
.btn-ghost:hover { border-color: var(--coral-600); color: var(--coral-600); }
.btn-lg { padding: 16px 34px; font-size: 1.05rem; }

/* ---------- Section shells ---------- */

section { padding: 72px 0; }

.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.5rem, 4.5vw, 2.1rem);
  letter-spacing: -.01em;
  margin: 0 0 12px;
}
.section-lede {
  color: var(--ink-soft);
  font-size: 1.02rem;
  max-width: 46ch;
  margin: 0 0 28px;
}

/* ---------- Hero ---------- */

.hero {
  padding-top: 52px;
  padding-bottom: 60px;
  background:
    radial-gradient(120% 90% at 85% -10%, rgba(111, 210, 215, .28), transparent 60%),
    var(--paper);
}

.hero-grid {
  display: grid;
  gap: 44px;
}

.eyebrow {
  font-family: var(--font-label);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .06em;
  color: var(--coral-600);
  text-transform: uppercase;
  margin: 0 0 14px;
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.1rem, 8vw, 3.1rem);
  line-height: 1.28;
  letter-spacing: -.02em;
  margin: 0 0 20px;
}
.hero-title .ink-alt { color: var(--teal-600); }

.hero-lede {
  font-size: 1.06rem;
  color: var(--ink-soft);
  max-width: 46ch;
  margin: 0 0 30px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.assembly-caption {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-label);
  font-size: .88rem;
  color: var(--ink-soft);
  background: var(--paper-alt);
  border: 1px solid var(--line);
  padding: 8px 16px;
  border-radius: 999px;
}
.assembly-caption .icon { width: 14px; height: 14px; color: var(--coral-600); }

/* ---------- Phone frames ---------- */

.phone-frame {
  width: min(280px, 72vw);
  aspect-ratio: 430 / 932;
  border-radius: 34px;
  overflow: hidden;
  background: var(--ink);
  padding: 8px;
  box-shadow: 0 30px 60px -24px rgba(36, 31, 25, .35);
}
.phone-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  border-radius: 26px;
}
.phone-frame--sm { width: min(220px, 62vw); border-radius: 28px; padding: 7px; }
.phone-frame--sm img { border-radius: 21px; }
.phone-frame--card {
  width: min(300px, 78vw);
  border-radius: 34px;
}

@media (min-width: 640px) {
  .hero-grid { grid-template-columns: 1.1fr .9fr; align-items: center; }
}

/* ---------- Principles ---------- */

.principles { background: var(--paper-alt); }

.principle-row {
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .principle-row { grid-template-columns: repeat(3, 1fr); }
}

.principle-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 26px 24px;
}
.principle-num {
  display: inline-block;
  font-family: var(--font-serif);
  font-size: .82rem;
  color: var(--teal-600);
  border: 1px solid var(--teal-100);
  border-radius: 999px;
  padding: 3px 10px;
  margin-bottom: 14px;
}
.principle-card h3 {
  font-family: var(--font-display);
  font-size: 1.12rem;
  margin: 0 0 8px;
}
.principle-card p {
  color: var(--ink-soft);
  margin: 0;
  font-size: .96rem;
}

/* ---------- Story gallery ---------- */

.story {
  background: var(--gold-100);
  clip-path: polygon(0 3%, 100% 0, 100% 97%, 0 100%);
}

.story-track {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 8px 20px 12px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.story-track::-webkit-scrollbar { display: none; }

.story-slide {
  flex: 0 0 auto;
  scroll-snap-align: center;
  margin: 0;
  width: min(240px, 68vw);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.story-slide figcaption {
  text-align: center;
  font-size: .92rem;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 8px;
}
.story-step {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: var(--coral-600);
  color: var(--paper-alt);
  font-family: var(--font-display);
  font-size: .74rem;
  font-weight: 600;
}

.story-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 8px;
}
.story-btn {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper-alt);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.story-btn:hover { border-color: var(--coral-600); color: var(--coral-600); }
.story-dots {
  display: flex;
  gap: 8px;
}
.story-dots button {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--ink-faint);
  border: 0;
  padding: 0;
  cursor: pointer;
}
.story-dots button.is-active {
  background: var(--coral-600);
  width: 22px;
}

/* ---------- Cheonjiin ---------- */

.cheonjiin { background: var(--paper-alt); }

.cheonjiin-grid {
  display: grid;
  gap: 40px;
}
@media (min-width: 760px) {
  .cheonjiin-grid { grid-template-columns: .9fr 1.1fr; align-items: start; }
}

.cheonjiin-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.cheonjiin-steps li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.cj-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cj-icon--gold { background: var(--gold-100); color: var(--gold-600); }
.cj-icon--teal { background: var(--teal-100); color: var(--teal-600); }
.cj-icon--coral { background: var(--coral-100); color: var(--coral-600); }
.cheonjiin-steps strong {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.02rem;
}
.cheonjiin-steps p {
  margin: 4px 0 0;
  color: var(--ink-soft);
  font-size: .95rem;
}

/* ---------- Curriculum ---------- */

.curriculum { background: var(--paper); }

.curr-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.curr-item {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper-alt);
  padding: 4px 18px;
}
.curr-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  flex-wrap: wrap;
}
.curr-item summary::-webkit-details-marker { display: none; }
.curr-item summary::after {
  content: "";
  margin-left: auto;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--ink-faint);
  border-bottom: 2px solid var(--ink-faint);
  transform: rotate(-45deg);
  transition: transform .2s ease;
}
.curr-item[open] summary::after { transform: rotate(45deg); }

.curr-num {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: var(--teal-100);
  color: var(--teal-600);
  font-family: var(--font-serif);
  font-size: .9rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.curr-sub {
  font-family: var(--font-label);
  font-weight: 400;
  font-size: .85rem;
  color: var(--ink-faint);
}
.curr-item p {
  margin: 0 0 16px 42px;
  color: var(--ink-soft);
  font-size: .93rem;
}

.curr-final {
  margin-top: 22px;
  padding: 28px 24px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--gold-100), var(--gold-300) 140%);
  border: 1px solid var(--gold-300);
}
.curr-final-badge {
  display: inline-block;
  font-family: var(--font-label);
  font-size: .78rem;
  font-weight: 700;
  color: var(--gold-600);
  background: var(--paper-alt);
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 10px;
}
.curr-final h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  margin: 0 0 8px;
}
.curr-final p {
  margin: 0;
  color: var(--ink);
  opacity: .82;
  max-width: 52ch;
}

/* ---------- Review modes ---------- */

.review-modes { background: #EAF5F4; }

.review-grid {
  display: grid;
  gap: 40px;
}
@media (min-width: 760px) {
  .review-grid { grid-template-columns: 1.1fr .9fr; align-items: center; }
}

.review-list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.review-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.review-list .icon { color: var(--teal-600); margin-top: 3px; }
.review-list strong {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
}
.review-list p {
  margin: 4px 0 0;
  color: var(--ink-soft);
  font-size: .93rem;
}
.review-icon-group {
  display: flex;
  gap: 4px;
  color: var(--teal-600);
  margin-top: 3px;
}

.review-note {
  font-size: .93rem;
  color: var(--ink-soft);
  border-top: 1px dashed var(--line);
  padding-top: 16px;
}

.review-visuals {
  display: flex;
  gap: 16px;
  justify-content: center;
}

/* ---------- Rewards ---------- */

.rewards { background: #FBEFF3; }

.rewards-grid {
  display: grid;
  gap: 40px;
}
@media (min-width: 760px) {
  .rewards-grid { grid-template-columns: .85fr 1.15fr; align-items: center; }
}

.rewards-visual { display: flex; justify-content: center; }

.rewards-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.rewards-list li {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: .98rem;
  color: var(--ink);
  padding-left: 18px;
  position: relative;
}
.rewards-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .55em;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--pink-600);
}
.rewards-list .icon-sm { color: var(--pink-600); }

.name-example {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  font-family: var(--font-serif);
  font-size: 1.05rem;
  background: var(--paper-alt);
  border: 1px solid var(--pink-100);
  padding: 8px 16px;
  border-radius: 999px;
}
.name-example .icon-sm { color: var(--pink-600); }

/* ---------- CTA ---------- */

.cta {
  background: var(--coral-600);
  color: var(--paper-alt);
}
.cta-inner {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.cta-inner h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.5rem, 5vw, 2rem);
  margin: 0;
}
.cta-inner p {
  margin: 0 0 10px;
  opacity: .9;
}
.cta .btn-primary {
  background: var(--paper-alt);
  color: var(--coral-600);
  box-shadow: none;
}
.cta .btn-primary:hover { background: var(--paper); }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--ink);
  color: var(--paper);
  padding: 44px 0;
}
.footer-grid {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.brand-footer .logo-en { color: var(--paper); }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: .9rem;
  color: rgba(251, 246, 234, .75);
}
.footer-links a:hover { color: var(--paper); }
.footer-copy {
  margin: 0;
  font-size: .82rem;
  color: rgba(251, 246, 234, .55);
}

@media (min-width: 760px) {
  .footer-grid {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}
