/* =============================================================
   나노웹 · Component Layer v2
   ============================================================= */

/* ---------- Reset / Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--lh-normal);
  color: var(--text);
  background: var(--paper);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
button { font-family: inherit; cursor: pointer; }
::selection { background: var(--brand); color: #fff; }

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-5);
}
.container--narrow { max-width: var(--container-narrow); }
.section { padding-block: var(--space-9); }
.section--tight { padding-block: var(--space-8); }
.section--paper2 { background: var(--paper-2); }
.section--dark { background: var(--ink-bg); color: var(--on-dark); }

/* ---------- Typography ---------- */
.display {
  font-family: var(--font-display);
  font-size: var(--display);
  font-weight: var(--fw-bold);      /* 실측: 3사 헤딩 3/3이 700 */
  line-height: var(--lh-tight);
  letter-spacing: var(--track-tight);
  color: var(--ink);
  margin: 0;
}
.h2 {
  font-family: var(--font-display);
  font-size: var(--display-sm);
  font-weight: var(--fw-bold);      /* 실측: 3사 헤딩 3/3이 700 */
  line-height: var(--lh-tight);
  letter-spacing: var(--track-tight);
  color: var(--ink);
  margin: 0;
}
.h3 { font-size: var(--text-xl); font-weight: var(--fw-semibold); line-height: var(--lh-snug); letter-spacing: var(--track-snug); margin: 0; color: var(--ink); }
.h4 { font-size: var(--text-md); font-weight: var(--fw-semibold); line-height: var(--lh-snug); margin: 0; color: var(--ink); }
.lead { font-size: var(--text-lg); color: var(--muted); line-height: 1.55; margin: 0; }
.eyebrow {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: var(--text-sm); font-weight: var(--fw-semibold);
  letter-spacing: 0.02em; color: var(--muted);
}
.eyebrow::before { content: ""; width: 18px; height: 1.5px; background: var(--brand); }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; letter-spacing: -0.01em; }
.center { text-align: center; }
.accent { color: var(--brand); }

.section-head { max-width: 640px; }
.section-head.center { margin-inline: auto; }
.section-head .h2 { margin: var(--space-4) 0; }
.section-head .lead { max-width: 52ch; }
.section-head.center .lead { margin-inline: auto; }

/* ---------- Button ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  font-size: var(--text-base); font-weight: var(--fw-semibold); line-height: 1;
  padding: 0.875rem 1.5rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  transition: background-color .18s ease, color .18s ease, border-color .18s ease, opacity .18s ease;
}
.btn svg { width: 17px; height: 17px; }
.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { background: var(--brand-strong); }
.btn--dark { background: var(--ink); color: var(--paper); }
.btn--dark:hover { background: var(--ink-2); }
.btn--outline { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--outline:hover { border-color: var(--ink); }
.btn--ghost { background: transparent; color: var(--ink); padding-inline: 0; }
.btn--ghost:hover { color: var(--brand); }
.btn--on-dark { background: var(--ink); color: var(--paper); }
.btn--on-dark:hover { opacity: .88; }
.btn--lg { padding: 1.0625rem 1.875rem; font-size: var(--text-md); }
.btn--block { display: flex; width: 100%; }

/* ---------- Tag / Badge ---------- */
.tag {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: var(--text-sm); font-weight: var(--fw-medium);
  padding: 0.3125rem 0.75rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  color: var(--muted);
  background: var(--paper-2);
}
.tag .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--viz-green); }
.tag--solid { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.tag--brand { background: var(--brand); color: #fff; border-color: var(--brand); }

/* ---------- Cards ---------- */
.card {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}
.card--flush { padding: 0; overflow: hidden; }
.card--dark { background: var(--ink-bg); color: var(--on-dark); border-color: var(--ink-bg-2); }
.card--shadow { box-shadow: var(--shadow-sm); border-color: var(--line-soft); }

/* ---------- Bento grid ---------- */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: var(--space-4); }
.bento > .span-6 { grid-column: span 6; }
.bento > .span-4 { grid-column: span 4; }
.bento > .span-3 { grid-column: span 3; }
.bento > .span-2 { grid-column: span 2; }
.bento .tall { min-height: 340px; }

.feature {
  display: flex; flex-direction: column;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  overflow: hidden;
}
.feature__kicker { font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--brand); margin-bottom: var(--space-3); }
.feature .h3 { margin-bottom: var(--space-2); }
.feature p { margin: 0; color: var(--muted); }
.feature__viz { margin-top: auto; padding-top: var(--space-5); }

/* ---------- Generic grids ---------- */
.grid { display: grid; gap: var(--space-5); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.cols-split { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-8); align-items: center; }

/* ---------- Logo strip ---------- */
.logostrip { display: flex; align-items: center; justify-content: center; gap: var(--space-7); flex-wrap: wrap; }
.logostrip img { height: 26px; width: auto; opacity: .85; }
.logostrip .sep { width: 1px; height: 28px; background: var(--line); }

/* ---------- Pipeline (Meta → Sheets → Dashboard) ---------- */
.pipeline { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: stretch; gap: var(--space-4); }
.pipe-node {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  background: var(--paper-2);
  display: flex; flex-direction: column; gap: var(--space-3);
}
.pipe-node.is-final { background: var(--ink-bg); color: var(--on-dark); border-color: var(--ink-bg); }
.pipe-node img { height: 34px; width: auto; }
.pipe-node .h4 { color: inherit; }
.pipe-node p { margin: 0; font-size: var(--text-sm); color: var(--muted); }
.pipe-node.is-final p { color: var(--on-dark-muted); }
.pipe-arrow { align-self: center; color: var(--faint); }

/* ---------- Problem list (no boxes, editorial) ---------- */
.painlist { display: grid; gap: 0; }
.painlist li {
  display: grid; grid-template-columns: auto 1fr; gap: var(--space-4); align-items: baseline;
  padding: var(--space-5) 0;
  border-top: 1px solid var(--line);
  font-size: var(--text-md); color: var(--ink-2);
}
.painlist li:last-child { border-bottom: 1px solid var(--line); }
.painlist .idx { font-family: var(--font-mono); font-size: var(--text-sm); color: var(--faint); }
.painlist b { font-weight: var(--fw-semibold); color: var(--ink); }

/* ---------- Metric ---------- */
.metric__value { font-family: var(--font-mono); font-size: var(--text-4xl); font-weight: var(--fw-bold); line-height: 1; color: var(--ink); letter-spacing: var(--track-tight); }
.metric__value .u { font-family: var(--font-sans); font-size: var(--text-xl); color: var(--faint); margin-left: 2px; }
.metric__label { margin-top: var(--space-3); color: var(--muted); }

/* ---------- Testimonials ---------- */
.quote {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: var(--space-6); background: var(--paper-2);
}
.quote p { margin: 0 0 var(--space-5); font-size: var(--text-md); line-height: 1.6; color: var(--ink-2); }
.quote--feature { background: var(--ink-bg); color: var(--on-dark); border-color: var(--ink-bg); }
.quote--feature p { color: #fff; font-size: var(--text-xl); line-height: 1.5; font-weight: var(--fw-medium); }
.byline { display: flex; align-items: center; gap: var(--space-3); }
.byline .who { width: 40px; height: 40px; border-radius: 50%; background: var(--paper-3); color: var(--ink); display: grid; place-items: center; font-weight: var(--fw-semibold); font-size: var(--text-sm); }
.quote--feature .who { background: rgba(255,255,255,.14); color: #fff; }
.byline b { display: block; font-weight: var(--fw-semibold); color: inherit; font-size: var(--text-sm); }
.byline span.role { font-size: var(--text-sm); color: var(--faint); }
.quote--feature .byline span.role { color: var(--on-dark-muted); }

/* ---------- Comparison ---------- */
.compare { width: 100%; border-collapse: separate; border-spacing: 0; }
.compare th, .compare td { padding: var(--space-4) var(--space-5); text-align: left; vertical-align: middle; }
.compare thead th { font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--muted); padding-bottom: var(--space-3); }
.compare tbody tr { border-top: 1px solid var(--line); }
.compare .rowh { font-weight: var(--fw-medium); color: var(--muted); width: 22%; }
.compare .them { color: var(--muted); }
.compare .us { color: var(--ink); font-weight: var(--fw-medium); }
.compare col.c-us { background: var(--paper-2); }
.compare .us-head { color: var(--ink); font-weight: var(--fw-bold); display: inline-flex; align-items: center; gap: var(--space-2); }
.compare .us-wrap { border: 1px solid var(--ink); border-radius: var(--radius-lg); overflow: hidden; }
.compare td.us, .compare th.us-cell { background: var(--paper-2); }
.ck { color: var(--viz-green); }
.xk { color: var(--faint); }

/* ---------- Pricing ---------- */
.price-card {
  display: flex; flex-direction: column;
  border: 1px solid var(--line); border-radius: var(--radius-xl);
  padding: var(--space-7) var(--space-6); background: var(--paper-2);
}
.price-card--featured { background: var(--ink-bg); color: var(--on-dark); border-color: var(--ink-bg); }
.price-card__tag { font-size: var(--text-sm); color: var(--faint); }
.price-card--featured .price-card__tag { color: var(--on-dark-muted); }
.price-card .h3 { margin: var(--space-2) 0 var(--space-5); color: inherit; }
.price-amount { display: flex; align-items: baseline; gap: var(--space-2); flex-wrap: wrap; }
.price-amount .was { font-size: var(--text-base); color: var(--faint); text-decoration: line-through; }
.price-amount .now { font-family: var(--font-mono); font-size: var(--text-3xl); font-weight: var(--fw-bold); color: inherit; letter-spacing: var(--track-tight); }
.price-amount .per { color: var(--muted); font-size: var(--text-sm); }
.price-card--featured .price-amount .per { color: var(--on-dark-muted); }
.price-feat { margin: var(--space-6) 0; display: grid; gap: var(--space-3); }
.price-feat li { display: flex; gap: var(--space-3); font-size: var(--text-sm); color: var(--text); }
.price-card--featured .price-feat li { color: rgba(255,255,255,.86); }
.price-feat svg { width: 16px; height: 16px; color: var(--viz-green); flex: none; margin-top: 3px; }
.price-card .btn { margin-top: auto; }
.price-pill {
  align-self: flex-start; font-size: var(--text-xs); font-weight: var(--fw-semibold);
  padding: .25rem .625rem; border-radius: var(--radius-pill);
  background: var(--brand); color: #fff; margin-bottom: var(--space-3);
}

/* ---------- FAQ ---------- */
.accordion { display: grid; }
.faq { border-top: 1px solid var(--line); }
.faq:last-child { border-bottom: 1px solid var(--line); }
.faq > summary {
  list-style: none; cursor: pointer; padding: var(--space-5) 0;
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
  font-weight: var(--fw-semibold); font-size: var(--text-md); color: var(--ink);
}
.faq > summary::-webkit-details-marker { display: none; }
.faq .chev { color: var(--faint); transition: transform .2s ease; flex: none; }
.faq[open] .chev { transform: rotate(45deg); }
.faq__body { padding: 0 0 var(--space-5); color: var(--muted); max-width: 60ch; }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: #000; border-bottom: 1px solid rgba(255,255,255,.08); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 66px; }
.brand { display: flex; align-items: center; gap: var(--space-2); font-weight: var(--fw-bold); font-size: var(--text-md); color: var(--ink); letter-spacing: -0.01em; }
.brand img { height: 22px; width: auto; }
.nav__links { display: flex; align-items: center; gap: var(--space-6); }
.nav__links a { font-size: var(--text-sm); font-weight: var(--fw-medium); color: var(--muted); }
.nav__links a:hover { color: var(--ink); }

/* nav: dark bar overrides (footer .brand stays unaffected) */
.nav .brand { color: #fff; }
.nav .brand img { height: 26px; }
.nav .nav__links a { color: rgba(255,255,255,.66); }
.nav .nav__links a:hover { color: #fff; }

/* ---------- Dark section helpers ---------- */
.section--dark .h2, .section--dark .display { color: #fff; }
.section--dark .lead { color: var(--on-dark-muted); }
.section--dark .eyebrow { color: var(--on-dark-muted); }

/* ---------- Misc ---------- */
.countdown { display: inline-flex; align-items: center; gap: var(--space-2); font-family: var(--font-mono); font-size: var(--text-sm); color: var(--muted); }
.countdown b { color: var(--ink); }
.divider { height: 1px; background: var(--line); border: 0; margin: 0; }
.footer { padding-block: var(--space-7); border-top: 1px solid var(--line); color: var(--faint); }
.footer__links { display: flex; flex-wrap: wrap; gap: var(--space-5); }
.footer__links a { font-size: var(--text-sm); color: var(--muted); }
.shot { border-radius: var(--radius-lg); border: 1px solid var(--line); overflow: hidden; box-shadow: var(--shadow-md); background: var(--paper-2); }
.eshot { border: 1px solid var(--line); border-radius: var(--radius-md); overflow: hidden; }
.lift { transition: border-color .18s ease; }
.lift:hover { border-color: var(--ink); }

/* ---------- Hero (real screenshot + abstract bg + layered) ---------- */
.hero { position: relative; padding-top: var(--space-8); padding-bottom: var(--space-9); overflow: hidden; }
.hero__bg {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 60px 60px;
  -webkit-mask-image: radial-gradient(125% 75% at 50% 0%, #000 30%, transparent 72%);
          mask-image: radial-gradient(125% 75% at 50% 0%, #000 30%, transparent 72%);
}
.hero > .container { position: relative; z-index: 1; }
.hero__cta { display: flex; gap: var(--space-3); justify-content: center; flex-wrap: wrap; margin: var(--space-6) 0 var(--space-3); }
.hero__shot { position: relative; max-width: 1000px; margin: var(--space-8) auto 0; }
.hero__shot .shot img { display: block; width: 100%; }
.floatcard {
  position: absolute; z-index: 2;
  background: var(--paper-2); border: 1px solid var(--line);
  border-radius: var(--radius-md); box-shadow: var(--shadow-md);
  padding: 12px 14px; display: flex; align-items: center; gap: 10px;
  font-size: var(--text-sm);
}
.floatcard--tl { top: 11%; left: clamp(-2%, -1.5vw, 0%); }
.floatcard--br { bottom: 9%; right: clamp(-2%, -1.5vw, 0%); }
.floatcard .who { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: var(--paper-3); flex: none; }
.floatcard .who img { width: 18px; height: 18px; }
.floatcard b { color: var(--ink); font-weight: var(--fw-semibold); }
@media (max-width: 600px) { .floatcard { display: none; } }

/* ---------- Blog ---------- */
.page-paper { background: var(--paper); }
.crumbs { display: flex; flex-wrap: wrap; gap: var(--space-2); font-size: var(--text-sm); color: var(--faint); padding-top: var(--space-6); }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--ink); }
.post-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-6) var(--space-5); }
.post-card { display: flex; flex-direction: column; }
.post-card__thumb {
  aspect-ratio: 16 / 10; border-radius: var(--radius-md);
  border: 1px solid var(--line); overflow: hidden;
  background: var(--paper-3);
  display: grid; place-items: center;
  font-size: var(--text-xs); color: var(--faint); font-family: var(--font-mono);
  margin-bottom: var(--space-4);
}
.post-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 900px) { .post-list { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .post-list { grid-template-columns: 1fr; } }
.post-card .h3 { font-size: var(--text-lg); margin: var(--space-2) 0; transition: color .15s ease; }
.post-card:hover .h3 { color: var(--brand); }
.post-card p { margin: 0; color: var(--muted); font-size: var(--text-sm); }
.article__thumb {
  aspect-ratio: 21 / 9; border-radius: var(--radius-lg);
  border: 1px solid var(--line); overflow: hidden;
  background: var(--paper-3);
  display: grid; place-items: center;
  font-size: var(--text-xs); color: var(--faint); font-family: var(--font-mono);
  margin-bottom: var(--space-6);
}
.article__thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-card__meta { display: flex; gap: var(--space-3); align-items: center; font-size: var(--text-sm); color: var(--faint); }
.post-card__meta .cat { color: var(--brand); font-weight: var(--fw-medium); }
.article { max-width: var(--container-narrow); }
.article h1 { font-family: var(--font-display); font-size: var(--text-3xl); font-weight: var(--fw-semibold); line-height: var(--lh-snug); letter-spacing: var(--track-tight); color: var(--ink); margin: var(--space-4) 0; }
.article h2 { font-size: var(--text-xl); font-weight: var(--fw-semibold); line-height: var(--lh-snug); color: var(--ink); margin: var(--space-7) 0 var(--space-4); }
.article p, .article li { color: var(--text); line-height: var(--lh-normal); }
.article ul { list-style: disc; padding-left: 1.25rem; display: grid; gap: var(--space-2); }
.article a { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.article .article-meta { display: flex; gap: var(--space-3); font-size: var(--text-sm); color: var(--faint); margin-bottom: var(--space-6); }
.article .cta-inline {
  margin: var(--space-7) 0; padding: var(--space-6);
  background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--radius-lg);
}
.article .cta-inline p { margin: 0 0 var(--space-4); color: var(--ink-2); }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .bento { grid-template-columns: repeat(2, 1fr); }
  .bento > .span-6, .bento > .span-4, .bento > .span-3, .bento > .span-2 { grid-column: span 2; }
  .pipeline { grid-template-columns: 1fr; }
  .pipe-arrow { transform: rotate(90deg); justify-self: center; }
}
@media (max-width: 820px) {
  .cols-split { grid-template-columns: 1fr; gap: var(--space-6); }
  .grid-3 { grid-template-columns: 1fr; }
  .bento { grid-template-columns: 1fr; }
  .nav__links { display: none; }
  .section { padding-block: var(--space-8); }
  .hero-grid { grid-template-columns: 1fr !important; }
}

/* -------------------------------------------------------------
   Course (AI 교육) — 리스트 카드 + 싱글 상세
   그리드/카드 골격은 .post-list / .post-card 재사용, 여기선 차이만 정의
   ------------------------------------------------------------- */
.course-art {
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-md);
  background: var(--art, var(--ink-bg));
  color: #fff;
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}
.course-art__kicker { font-size: var(--text-xs); font-weight: var(--fw-semibold); letter-spacing: .04em; text-transform: uppercase; color: rgba(255,255,255,.72); }
.course-art__line { font-family: var(--font-display); font-size: var(--text-lg); font-weight: var(--fw-bold); line-height: 1.3; letter-spacing: var(--track-snug); white-space: pre-line; }
.course-art img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius-md); }

.badges { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-3); }
.badge {
  font-size: var(--text-xs); font-weight: var(--fw-semibold);
  padding: 2px 8px; border-radius: 6px;
  background: var(--paper-3); color: var(--muted);
}
.badge--new { background: var(--brand); color: #fff; }
.badge--live { background: var(--ink); color: var(--paper); }

.course-price { display: flex; align-items: baseline; gap: var(--space-2); margin-top: var(--space-3); }
.course-price .off { font-weight: var(--fw-bold); color: var(--viz-coral); }
.course-price .now { font-family: var(--font-mono); font-weight: var(--fw-bold); color: var(--ink); }
.course-price .was { font-size: var(--text-sm); color: var(--faint); text-decoration: line-through; }

/* 와이드 featured 카드 — 그리드와 리듬을 다르게 */
.course-feature {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: var(--space-7);
  align-items: center; padding: var(--space-6);
  border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper-2);
}
.course-feature .course-art { aspect-ratio: 16 / 9; }
.course-feature .h2 { margin: var(--space-3) 0 var(--space-4); }
@media (max-width: 820px) { .course-feature { grid-template-columns: 1fr; gap: var(--space-5); } }

/* ---- 싱글 상세 ---- */
.course-hero { background: var(--art, var(--ink-bg)); color: #fff; padding-block: var(--space-8); }
.course-hero h1 { font-family: var(--font-display); font-size: var(--display-sm); font-weight: var(--fw-bold); line-height: var(--lh-tight); letter-spacing: var(--track-tight); margin: var(--space-3) 0 var(--space-4); white-space: pre-line; }
.course-hero p { margin: 0; color: rgba(255,255,255,.78); max-width: 46ch; }
.course-hero .badge { background: rgba(255,255,255,.16); color: #fff; }


.spec { width: 100%; margin-top: var(--space-5); border-top: 1px solid var(--line); font-size: var(--text-sm); }
.spec th { text-align: left; color: var(--faint); font-weight: var(--fw-regular); white-space: nowrap; padding: var(--space-3) var(--space-4) var(--space-3) 0; vertical-align: top; }
.spec td { color: var(--text); padding: var(--space-3) 0; vertical-align: top; }

.anchor-tabs { display: flex; gap: var(--space-6); border-bottom: 1px solid var(--line); overflow-x: auto; }
.anchor-tabs a { font-size: var(--text-sm); font-weight: var(--fw-medium); color: var(--muted); padding: var(--space-4) 0; white-space: nowrap; }
.anchor-tabs a:hover { color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); }

/* 싱글 상세 — 왼쪽 본문을 경계 있는 패널로 (배경 톤 차이로 컨테이너가 보이게) */
.course-page { background: var(--paper); }
@media (max-width: 600px) {
    }

/* -------------------------------------------------------------
   무드 — 다크 + 도트 텍스처 (나노웹 로고의 도트매트릭스에서 가져옴)
   이미지 에셋 없이 CSS만으로. --art 는 강의별 포인트 컬러.
   ------------------------------------------------------------- */
.dots { position: relative; isolation: isolate; }
.dots::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image: radial-gradient(rgba(255,255,255,.16) 1px, transparent 1px);
  background-size: 10px 10px;
  mask-image: radial-gradient(120% 90% at 82% 8%, #000 10%, transparent 72%);
}

/* 히어로: 다크 바탕 + 강의 컬러 글로우 + 도트 */
.course-hero {
  background:
    radial-gradient(900px 420px at 78% -10%, color-mix(in srgb, var(--art) 62%, transparent), transparent 70%),
    radial-gradient(600px 300px at 8% 110%, color-mix(in srgb, var(--art) 24%, transparent), transparent 70%),
    var(--ink-bg);
}
.course-art { position: relative; isolation: isolate; }
.course-art::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background-image: radial-gradient(rgba(255,255,255,.18) 1px, transparent 1px);
  background-size: 10px 10px;
  mask-image: radial-gradient(110% 80% at 85% 10%, #000 5%, transparent 70%);
}

/* 파일 형태 에셋 패널 */
.asset-panel {
  margin-top: var(--space-7);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  color: var(--on-dark);
  background:
    radial-gradient(700px 260px at 85% -20%, color-mix(in srgb, var(--art) 45%, transparent), transparent 70%),
    var(--ink-bg);
}
.asset-panel__lead { margin: 0 0 var(--space-5); font-size: var(--text-md); line-height: 1.55; color: rgba(255,255,255,.72); }
.asset-panel__lead b { color: #fff; font-weight: var(--fw-semibold); }
.asset-panel__note { margin: var(--space-5) 0 0; font-size: var(--text-xs); color: rgba(255,255,255,.42); }
.asset-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); }
.asset-card {
  display: grid; gap: var(--space-3); justify-items: center; text-align: center;
  padding: var(--space-5) var(--space-3);
  border: 1px solid var(--on-dark-line); border-radius: var(--radius-md);
  background: rgba(255,255,255,.04);
  font-size: var(--text-sm); font-weight: var(--fw-medium); color: rgba(255,255,255,.88);
}
/* 문서 목업 — 접힌 모서리 + 본문 줄 */
.asset-card__file {
  position: relative; width: 46px; height: 60px; border-radius: 4px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(0,0,0,.35);
  background-image: linear-gradient(var(--faint) 1.5px, transparent 1.5px);
  background-size: 100% 9px; background-position: 0 22px;
  background-repeat: repeat-y;
  background-clip: content-box; padding: 0 9px;
}
.asset-card__file::after {
  content: ""; position: absolute; top: 0; right: 0;
  border-width: 0 0 13px 13px; border-style: solid;
  border-color: transparent transparent var(--paper-3) transparent;
}
@media (max-width: 600px) { .asset-row { grid-template-columns: 1fr; } .asset-card { grid-auto-flow: column; justify-items: start; align-items: center; text-align: left; } }

/* 상단 섹션 탭 활성 상태 */
.anchor-tabs a.is-active { color: var(--ink); font-weight: var(--fw-semibold); box-shadow: inset 0 -2px 0 var(--ink); }

/* 하단 고정 CTA — 컨테이너 폭만큼 떠 있는 흰 바 (다크 배경과 분리) */
.cta-bar {
  /* 흰 면 위에서는 토큰을 라이트로 되돌린다 — 자식(.btn·가격)이 자동으로 따라온다 */
  --ink: #0d0d0f; --text: #33333a; --muted: #6c6c74; --faint: #9b9ba3;
  --brand: #1463ff; --brand-strong: #0b4fd8;
  position: fixed; z-index: 60;
  left: 50%; transform: translateX(-50%);
  bottom: calc(var(--space-4) + env(safe-area-inset-bottom));
  width: min(var(--container), calc(100% - var(--space-5) * 2));
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 40px rgba(0,0,0,.55);
}
.cta-bar__inner {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-5);
  padding: var(--space-4) var(--space-4) var(--space-4) var(--space-6);
}
.cta-bar__title { font-size: var(--text-sm); color: var(--muted); margin: 0 0 2px; }
.cta-bar__price { display: flex; align-items: baseline; gap: var(--space-2); }
.cta-bar__price .off { font-weight: var(--fw-bold); color: #e0353b; }
.cta-bar__price .now { font-family: var(--font-mono); font-weight: var(--fw-bold); color: var(--ink); font-size: var(--text-lg); }
.cta-bar__price .was { font-size: var(--text-sm); color: var(--faint); text-decoration: line-through; }
.cta-bar .btn { flex: none; }
.course-page { padding-bottom: 120px; }
@media (max-width: 700px) {
  .cta-bar__title { display: none; }
  .cta-bar .btn { white-space: nowrap; padding: .875rem 1.25rem; font-size: var(--text-base); }
  .cta-bar__price { white-space: nowrap; }
  .cta-bar__price .now { font-size: var(--text-md); }
  .cta-bar__price .was { display: none; }
  .cta-bar__inner { padding: var(--space-3) var(--space-3) var(--space-3) var(--space-5); gap: var(--space-3); }
}

/* 섹션 앵커 탭 — 풀와이드 sticky 바 */
.tabbar {
  position: sticky; top: 66px; z-index: 40;
  background: rgba(11,12,15,.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.course-page section[id] { scroll-margin-top: 130px; }

/* nav 링크가 1개뿐이라 모바일에서도 그대로 노출 (햄버거 불필요) */
@media (max-width: 820px) {
  .nav__links { display: flex; gap: var(--space-4); }
}

/* 싱글 상세 — 풀와이드 섹션 요소들 */
.hero-meta { display: flex; flex-wrap: wrap; gap: var(--space-5); margin-top: var(--space-6); font-size: var(--text-sm); color: rgba(255,255,255,.62); }
.hero-meta b { color: #fff; font-weight: var(--fw-semibold); }
.sec-head { max-width: 640px; margin-bottom: var(--space-6); }

.gain-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); }
.gain-card { padding: var(--space-6); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.gain-card__no { font-family: var(--font-mono); font-size: var(--text-sm); color: var(--brand); }
.gain-card b { display: block; margin: var(--space-3) 0 var(--space-2); color: var(--ink); font-size: var(--text-md); font-weight: var(--fw-semibold); }
.gain-card p { margin: 0; color: var(--muted); font-size: var(--text-sm); }
/* 가운데 카드만 한 칸 내려 균일 그리드 깨기 */
.gain-grid > .gain-card:nth-child(2) { transform: translateY(var(--space-4)); }
@media (max-width: 820px) { .gain-grid { grid-template-columns: 1fr; } .gain-grid > .gain-card:nth-child(2) { transform: none; } }

.price-split { display: grid; grid-template-columns: 1.15fr .85fr; gap: var(--space-8); align-items: start; }
.price-box { padding: var(--space-6); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); box-shadow: var(--shadow-sm); }
@media (max-width: 820px) { .price-split { grid-template-columns: 1fr; gap: var(--space-6); } }

/* -------------------------------------------------------------
   강의 미리보기 — 플레이어 + 회차 리스트 (클래스유), 스펙 바 (베어유)
   ------------------------------------------------------------- */
.specbar {
  display: flex; flex-wrap: wrap; gap: var(--space-6);
  padding: var(--space-4) var(--space-5); margin-bottom: var(--space-5);
  border: 1px solid var(--line); border-radius: var(--radius-md);
  font-size: var(--text-sm); color: var(--muted);
}
.specbar b { color: var(--ink); font-weight: var(--fw-semibold); }

.preview-split { display: grid; grid-template-columns: minmax(0, 2.55fr) minmax(0, 1fr); gap: var(--space-5); align-items: start; }
@media (max-width: 900px) { .preview-split { grid-template-columns: 1fr; } }

.player__stage {
  position: relative; aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg); overflow: hidden;
  display: grid; place-items: center;
  background:
    radial-gradient(700px 320px at 70% 10%, color-mix(in srgb, var(--art) 45%, transparent), transparent 70%),
    var(--ink-bg);
}
.player__play {
  width: 68px; height: 68px; border-radius: 50%; border: 0;
  background: rgba(255,255,255,.92); color: #0b0c0f;
  display: grid; place-items: center;
  transition: transform .15s ease;
}
.player__play svg { width: 30px; height: 30px; margin-left: 3px; }
.player__play:hover { transform: scale(1.06); }
.player__label {
  position: absolute; left: var(--space-4); bottom: var(--space-4);
  font-size: var(--text-xs); font-weight: var(--fw-semibold);
  padding: 4px 10px; border-radius: var(--radius-pill);
  background: rgba(0,0,0,.55); color: #fff;
}

.lessons { border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper-2); padding: var(--space-5); }
.lessons__head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-3); margin: 0 0 var(--space-3); font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--ink); }
.lessons__head .faint { font-weight: var(--fw-regular); font-size: var(--text-xs); }
.lessons__note { margin: var(--space-4) 0 0; font-size: var(--text-xs); color: var(--faint); }
.lesson {
  display: grid; grid-template-columns: 18px 32px 1fr auto; align-items: center; gap: var(--space-3);
  padding: var(--space-3) 0; border-top: 1px solid var(--line-soft);
  font-size: var(--text-sm); color: var(--faint);
}
.lesson__ico { width: 16px; height: 16px; }
.lesson__no { font-family: var(--font-mono); font-size: var(--text-xs); }
.lesson__name { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lesson time { font-family: var(--font-mono); font-size: var(--text-xs); }
.lesson.is-free { cursor: pointer; color: var(--brand); }
.lesson.is-free .lesson__name { color: var(--ink); }
.lesson.is-free:hover .lesson__name { color: var(--brand); }

/* 재생 모달 — 네이티브 <dialog> */
.player-modal { width: min(960px, 92vw); padding: 0; border: 0; border-radius: var(--radius-lg); background: var(--ink-bg); color: var(--ink); overflow: visible; }
.player-modal::backdrop { background: rgba(0,0,0,.78); }
.player-modal__body { aspect-ratio: 16 / 9; display: grid; place-items: center; border-radius: var(--radius-lg); overflow: hidden; }
.player-modal__body iframe { width: 100%; height: 100%; border: 0; }
.player-modal__empty { margin: 0; color: var(--muted); font-size: var(--text-sm); }
.player-modal__close { position: absolute; top: -40px; right: 0; background: none; border: 0; color: #fff; font-size: var(--text-lg); }

/* 기수(코호트) — 작게 나눠 모집, 잔여석 표시 (클래스유 참고) */
.seat-badge { display: inline-flex; align-items: center; gap: var(--space-2); color: #fff !important; }
.seat-badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--viz-green); box-shadow: 0 0 0 3px color-mix(in srgb, var(--viz-green) 25%, transparent); }
.seat-badge b { font-weight: var(--fw-bold); }

.cohorts { display: grid; margin: 0 0 var(--space-6); border-top: 1px solid var(--line); }
.cohort {
  display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: var(--space-4);
  padding: var(--space-4) 0; border-bottom: 1px solid var(--line);
  font-size: var(--text-sm);
}
.cohort__no { font-family: var(--font-mono); font-weight: var(--fw-bold); color: var(--faint); }
.cohort__date { color: var(--muted); }
.cohort__state { color: var(--faint); }
.cohort.is-closed .cohort__date { text-decoration: line-through; text-decoration-color: var(--line); }
.cohort.is-open { background: color-mix(in srgb, var(--brand) 8%, transparent); margin-inline: calc(var(--space-4) * -1); padding-inline: var(--space-4); border-radius: var(--radius-sm); }
.cohort.is-open .cohort__no, .cohort.is-open .cohort__date { color: var(--ink); }
.cohort.is-open .cohort__state { color: var(--brand); font-weight: var(--fw-semibold); }
.cohort.is-open .cohort__state b { font-size: var(--text-md); }

/* 문제 제기 → 원인 재정의 (판정 블록) · VOC 인용 · 강사 */
.verdict {
  margin-top: var(--space-7); padding: var(--space-7) var(--space-6);
  border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper);
}
.verdict__lead { margin: 0; color: var(--muted); font-size: var(--text-md); }
.verdict__head { margin: var(--space-2) 0 var(--space-6); font-family: var(--font-display); font-size: var(--display-sm); font-weight: var(--fw-bold); line-height: var(--lh-tight); letter-spacing: var(--track-tight); color: var(--ink); }
.verdict__head b { color: var(--brand); font-weight: inherit; }
.verdict__tail { margin: var(--space-6) 0 0; color: var(--text); max-width: 60ch; }
.verdict__tail b { color: var(--ink); font-weight: var(--fw-semibold); }

.voc { margin: 0; padding: var(--space-5); border-radius: var(--radius-md); background: var(--paper-2); border: 1px solid var(--line-soft); }
.voc p { margin: 0 0 var(--space-3); color: var(--ink-2); font-size: var(--text-md); line-height: 1.55; }
.voc p b { color: var(--brand); font-weight: var(--fw-semibold); }
.voc cite { font-style: normal; font-size: var(--text-xs); color: var(--faint); }
.voc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); }
.voc-grid > .voc:nth-child(2) { transform: translateY(var(--space-4)); }
@media (max-width: 820px) { .voc-grid { grid-template-columns: 1fr; } .voc-grid > .voc:nth-child(2) { transform: none; } }

.tutor { display: grid; grid-template-columns: 148px 1fr; gap: var(--space-6); align-items: start; }
.tutor__face { aspect-ratio: 1; border-radius: var(--radius-lg); background: var(--ink-bg); --art: var(--brand); }
.tutor__name { margin: 0; font-family: var(--font-display); font-size: var(--text-xl); font-weight: var(--fw-bold); color: var(--ink); }
.tutor__role { margin: var(--space-1) 0 var(--space-4); font-size: var(--text-sm); color: var(--brand); }
.tutor__list { display: grid; gap: var(--space-3); }
.tutor__list li { position: relative; padding-left: var(--space-4); color: var(--text); font-size: var(--text-sm); }
.tutor__list li::before { content: ""; position: absolute; left: 0; top: .6em; width: 4px; height: 4px; border-radius: 50%; background: var(--faint); }
.tutor__list b { color: var(--ink); font-weight: var(--fw-semibold); }
@media (max-width: 600px) { .tutor { grid-template-columns: 96px 1fr; gap: var(--space-4); } }

/* 미끼상품 프로모 — 목록 그리드 중간 스트립 + 목록 끝 밴드 */
.promo-strip {
  grid-column: 1 / -1;
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-6);
  padding: var(--space-6);
  border: 1px solid var(--brand); border-radius: var(--radius-lg);
  background:
    radial-gradient(700px 240px at 85% -30%, color-mix(in srgb, var(--art) 30%, transparent), transparent 70%),
    var(--paper-2);
}
.promo-strip__kicker { margin: 0 0 var(--space-2); font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--brand); }
.promo-strip__head { margin: 0; font-family: var(--font-display); font-size: var(--text-xl); font-weight: var(--fw-bold); line-height: 1.35; color: var(--ink); }
.promo-strip__buy { display: grid; gap: var(--space-3); justify-items: end; flex: none; }
.promo-strip__note { margin: 0; font-size: var(--text-xs); color: var(--faint); }

.promo-band {
  display: grid; grid-template-columns: 1fr auto; gap: var(--space-7); align-items: center;
  padding: var(--space-8) var(--space-7);
  border-radius: var(--radius-xl);
  background:
    radial-gradient(800px 320px at 80% -20%, color-mix(in srgb, var(--art) 42%, transparent), transparent 70%),
    var(--ink-bg);
}
.promo-band__buy { display: grid; gap: var(--space-4); justify-items: end; }
@media (max-width: 820px) {
  .promo-strip, .promo-band { grid-template-columns: 1fr; flex-direction: column; align-items: flex-start; }
  .promo-strip__buy, .promo-band__buy { justify-items: start; width: 100%; }
}

/* 썸네일 도구 칩 — 무엇으로 만드는지 한눈에 (라이클리온 참고) */
.course-art__tools { display: flex; flex-wrap: wrap; gap: 6px; margin-top: var(--space-3); }
.course-art__tools i {
  font-style: normal; font-size: var(--text-xs); font-weight: var(--fw-medium);
  padding: 3px 8px; border-radius: var(--radius-sm);
  background: rgba(0,0,0,.28); color: rgba(255,255,255,.92);
  backdrop-filter: blur(2px);
}
.course-feature .course-art__tools i { font-size: var(--text-sm); padding: 4px 10px; }

/* 문제 인지 — 상황을 그룹으로 묶고 그룹마다 전환 문장 (스파르타 구조) */
.who-groups { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-5); }
.who-group { padding: var(--space-6); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.who-group__tag { margin: 0 0 var(--space-4); font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--brand); }
.who-group ul { display: grid; gap: var(--space-3); }
.who-group li { position: relative; padding-left: var(--space-5); color: var(--text); font-size: var(--text-sm); line-height: 1.5; }
.who-group li::before { content: ""; position: absolute; left: 0; top: .55em; width: 10px; height: 2px; background: var(--faint); }
.who-group__turn {
  margin: var(--space-5) 0 0; padding-top: var(--space-4); border-top: 1px solid var(--line-soft);
  font-family: var(--font-display); font-size: var(--text-md); font-weight: var(--fw-bold); color: var(--ink);
}
.who-group__turn b { color: var(--brand); font-weight: inherit; }
.who-groups + .verdict { margin-top: var(--space-6); }
@media (max-width: 820px) { .who-groups { grid-template-columns: 1fr; } }

/* 푸터 — 사업자 정보 */
.footer { padding-block: var(--space-8) var(--space-7); border-top: 1px solid var(--line); background: var(--paper); }
.footer__top { display: flex; align-items: center; justify-content: space-between; gap: var(--space-5); flex-wrap: wrap; margin-bottom: var(--space-7); }
.footer .brand img { height: 22px; opacity: .85; }
.footer__links { display: flex; flex-wrap: wrap; gap: var(--space-5); }
.footer__links a { font-size: var(--text-sm); color: var(--muted); }
.footer__links a:hover { color: var(--ink); }
.biz { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2) var(--space-6); margin: 0; }
.biz div { display: flex; gap: var(--space-3); font-size: var(--text-xs); }
.biz dt { color: var(--faint); min-width: 84px; flex: none; }
.biz dd { margin: 0; color: var(--muted); }
.biz a { color: var(--muted); }
.biz a:hover { color: var(--brand); }
.footer__copy { margin: var(--space-6) 0 0; font-size: var(--text-xs); color: var(--faint); }
@media (max-width: 700px) { .biz { grid-template-columns: 1fr; } }
.tutor__note { margin: var(--space-5) 0 0; padding-top: var(--space-4); border-top: 1px solid var(--line-soft); color: var(--muted); font-size: var(--text-sm); max-width: 56ch; }

/* 썸네일 실제 이미지 */
.course-art.has-img { position: relative; }
.course-art.has-img > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; z-index: -2; }
.course-art.has-img::before { opacity: .35; }

/* 활용 사례 — 예제 1 + 응용 4 (균일 그리드 회피) */
.usecase-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-4); }
.usecase-grid > .usecase:first-child { grid-column: span 4; background: var(--paper-2); border-color: var(--brand); }
.usecase { padding: var(--space-5); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.usecase__no { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--brand); }
.usecase b { display: block; margin: var(--space-3) 0 var(--space-2); color: var(--ink); font-size: var(--text-md); font-weight: var(--fw-semibold); }
.usecase p { margin: 0; color: var(--muted); font-size: var(--text-sm); }
@media (max-width: 900px) { .usecase-grid { grid-template-columns: repeat(2, 1fr); } .usecase-grid > .usecase:first-child { grid-column: span 2; } }
@media (max-width: 560px) { .usecase-grid { grid-template-columns: 1fr; } .usecase-grid > .usecase:first-child { grid-column: span 1; } }
.tutor__face { overflow: hidden; border: 1px solid var(--line); }
.tutor__face img { width: 100%; height: 100%; object-fit: cover; }

/* -------------------------------------------------------------
   로그인 · 내 강의실
   ------------------------------------------------------------- */
.auth-list { display: grid; gap: var(--space-3); margin-top: var(--space-7); max-width: 420px; }
.auth-btn {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-4) var(--space-5); border-radius: var(--radius-md);
  border: 1px solid var(--line); font-size: var(--text-sm); font-weight: var(--fw-semibold);
  transition: transform .12s ease;
}
.auth-btn:hover { transform: translateY(-1px); }
.auth-btn b { font-weight: inherit; }
.auth-btn em { margin-left: auto; font-style: normal; font-size: var(--text-xs); font-weight: var(--fw-regular); opacity: .6; }
.auth-btn.is-off { opacity: .45; cursor: not-allowed; }
.auth-btn.is-off:hover { transform: none; }
.auth-btn.is-dev { border-style: dashed; color: var(--muted); }
.auth-err {
  margin: var(--space-5) 0 0; padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md); background: color-mix(in srgb, var(--viz-coral) 14%, transparent);
  color: var(--ink); font-size: var(--text-sm);
}
.auth-ok {
  margin: var(--space-5) 0 0; padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md); background: color-mix(in srgb, var(--viz-green) 14%, transparent);
  color: var(--ink); font-size: var(--text-sm);
}

/* 이메일 로그인 · 회원가입 */
.auth-tabs {
  display: flex; gap: var(--space-1); max-width: 420px; margin-top: var(--space-7);
  padding: var(--space-1); background: var(--paper-2);
  border: 1px solid var(--line); border-radius: var(--radius-md);
}
.auth-tab {
  flex: 1; padding: var(--space-3) var(--space-4); border: 0; cursor: pointer;
  border-radius: calc(var(--radius-md) - 5px); background: transparent; color: var(--muted);
  font-family: inherit; font-size: var(--text-sm); font-weight: var(--fw-semibold);
  transition: background .12s ease, color .12s ease;
}
.auth-tab.is-on { background: var(--paper-3); color: var(--ink); }
.auth-form { display: grid; gap: var(--space-4); max-width: 420px; margin-top: var(--space-5); }
.auth-field { display: grid; gap: var(--space-2); }
.auth-field[hidden] { display: none; }   /* display:grid가 hidden을 이기므로 명시 */
.auth-field > span { font-size: var(--text-xs); font-weight: var(--fw-semibold); color: var(--muted); }
.auth-field input {
  width: 100%; padding: var(--space-4) var(--space-5);
  border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--paper-2); color: var(--ink);
  font-family: inherit; font-size: var(--text-sm);
}
.auth-field input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint); }
.auth-field input::placeholder { color: var(--faint); }
.auth-form .btn { width: 100%; justify-content: center; text-align: center; }
.auth-form .btn[aria-busy="true"] { opacity: .6; pointer-events: none; }
.auth-hint { margin: 0; font-size: var(--text-xs); color: var(--faint); }
.auth-or {
  display: flex; align-items: center; gap: var(--space-4);
  max-width: 420px; margin-top: var(--space-6);
  color: var(--faint); font-size: var(--text-xs);
}
.auth-or::before, .auth-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.auth-or + .auth-list { margin-top: var(--space-4); }

.mypage-user { display: flex; align-items: center; gap: var(--space-5); flex-wrap: wrap; }
.mypage-user .btn { margin-left: auto; }
.mypage-avatar {
  width: 64px; height: 64px; border-radius: 50%; flex: none; overflow: hidden;
  background: var(--paper-3); color: var(--ink);
  display: grid; place-items: center; font-size: var(--text-xl); font-weight: var(--fw-bold);
}
.mypage-avatar img { width: 100%; height: 100%; object-fit: cover; }

.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-4); margin-top: var(--space-7); }
.stat { padding: var(--space-5); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper-2); }
.stat b { display: block; font-family: var(--font-mono); font-size: var(--text-2xl); font-weight: var(--fw-bold); color: var(--ink); }
.stat span { font-size: var(--text-sm); color: var(--muted); }
@media (max-width: 700px) { .stat-row { grid-template-columns: repeat(2, 1fr); } }

.my-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); }
.my-card { padding: var(--space-5); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper-2); transition: border-color .15s ease; }
.my-card:hover { border-color: var(--brand); }
.my-card__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--space-3); }
.progress { height: 4px; border-radius: 2px; background: var(--paper-3); overflow: hidden; margin-top: var(--space-4); }
.progress i { display: block; height: 100%; background: var(--brand); }
@media (max-width: 900px) { .my-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .my-grid { grid-template-columns: 1fr; } }

/* 썸네일 이미지 위 카피 가독성 — 왼쪽만 어둡게 덮는 스크림 */
.course-art.has-img::after {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: linear-gradient(100deg, rgba(11,12,15,.94) 0%, rgba(11,12,15,.78) 42%, rgba(11,12,15,0) 78%);
}

/* 모바일 내비 — 링크가 4개라 줄바꿈이 나서, 한 줄 가로 스크롤로 (패캠·클래스유 방식) */
@media (max-width: 820px) {
  .nav__inner { gap: var(--space-3); }
  .nav__links {
    flex-wrap: nowrap; overflow-x: auto; white-space: nowrap;
    gap: var(--space-4); min-width: 0; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .nav__links::-webkit-scrollbar { display: none; }
  .nav__links a { font-size: var(--text-xs); }
  .nav .btn--primary { white-space: nowrap; flex: none; padding: .5rem .875rem !important; font-size: var(--text-xs); }
  .nav .brand { flex: none; }
  .nav .brand img { height: 18px; }
}


/* ---------- Admin dashboard ---------- */
.admin-body { background: var(--paper); color: var(--text); }
.admin-topbar { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(14px); }
.admin-topbar__inner { min-height: 66px; display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); }
.admin-topbar__meta { display: flex; align-items: center; justify-content: flex-end; gap: var(--space-3); font-size: var(--text-sm); }
.admin-badge { padding: var(--space-1) var(--space-3); border: 1px solid var(--brand); border-radius: var(--radius-pill); color: var(--brand-ink); font-weight: var(--fw-semibold); }
.admin-btn { padding: var(--space-3) var(--space-4); font-size: var(--text-sm); }
.admin-shell { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: var(--space-7); padding-block: var(--space-7) var(--space-9); }
.admin-nav { position: sticky; top: 98px; align-self: start; display: grid; gap: var(--space-2); }
.admin-nav__item { width: 100%; padding: var(--space-3) var(--space-4); border: 1px solid transparent; border-radius: var(--radius-sm); background: transparent; color: var(--muted); text-align: left; font-size: var(--text-sm); font-weight: var(--fw-semibold); }
.admin-nav__item:hover { color: var(--ink); background: var(--paper-2); }
.admin-nav__item.is-active { color: var(--on-dark); background: var(--brand); }
.admin-main { min-width: 0; }
.admin-view { display: none; }
.admin-view.is-active { display: grid; gap: var(--space-6); }
.admin-heading { display: flex; align-items: end; justify-content: space-between; gap: var(--space-5); padding-bottom: var(--space-5); border-bottom: 1px solid var(--line); }
.admin-heading .eyebrow { margin: 0 0 var(--space-3); }
.admin-heading .lead { margin-top: var(--space-3); font-size: var(--text-base); }
.admin-caption { margin: var(--space-2) 0 0; font-size: var(--text-sm); }
.admin-period-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); }
.admin-period-card, .admin-panel, .admin-cohort-card { border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--paper-2); }
.admin-period-card { padding: var(--space-5); }
.admin-period-card__label { margin: 0 0 var(--space-4); color: var(--muted); font-weight: var(--fw-semibold); }
.admin-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3); margin: 0; }
.admin-metrics div { min-width: 0; }
.admin-metrics dt { color: var(--muted); font-size: var(--text-xs); }
.admin-metrics dd { margin: var(--space-1) 0 0; color: var(--ink); font-family: var(--font-mono); font-size: var(--text-2xl); font-weight: var(--fw-bold); }
.admin-provider-chips { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-5); }
.admin-provider-chips span { padding: var(--space-1) var(--space-2); border-radius: var(--radius-pill); background: var(--paper-3); color: var(--muted); font-size: var(--text-xs); }
.admin-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); }
.admin-panel { min-width: 0; padding: var(--space-5); }
.admin-panel__head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); margin-bottom: var(--space-5); }
.admin-stat-list { display: grid; gap: var(--space-2); }
.admin-stat-list > div { display: grid; grid-template-columns: 1fr auto 42px; gap: var(--space-3); align-items: center; padding: var(--space-3) 0; border-bottom: 1px solid var(--line-soft); }
.admin-stat-list strong { color: var(--ink); font-family: var(--font-mono); }
.admin-stat-list small { color: var(--muted); text-align: right; }
.admin-chart { min-height: 230px; }
.admin-chart svg { width: 100%; height: auto; overflow: visible; }
.admin-chart text { fill: var(--faint); font-family: var(--font-mono); font-size: var(--text-xs); }
.admin-chart__axis { stroke: var(--line); }
.admin-chart__line { fill: none; stroke: var(--brand); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
.admin-chart__bar { fill: var(--viz-green); opacity: .75; }
.admin-chart__wish { fill: var(--viz-amber); }
.admin-chart__legend { display: flex; flex-wrap: wrap; gap: var(--space-4); color: var(--muted); font-size: var(--text-xs); }
.admin-chart__legend span::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: var(--space-2); border-radius: var(--radius-pill); background: var(--brand); }
.admin-chart__legend .is-enroll::before { background: var(--viz-green); }
.admin-chart__legend .is-wish::before { background: var(--viz-amber); }
.admin-table-wrap { width: 100%; overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }
.admin-table th, .admin-table td { padding: var(--space-3); border-bottom: 1px solid var(--line-soft); text-align: left; vertical-align: middle; white-space: nowrap; }
.admin-table th { color: var(--muted); font-size: var(--text-xs); font-weight: var(--fw-semibold); }
.admin-table td { color: var(--text); }
.admin-table td strong, .admin-table td small { display: block; }
.admin-table td small { margin-top: var(--space-1); color: var(--muted); }
.admin-table--clickable tbody tr { cursor: pointer; }
.admin-table--clickable tbody tr:hover, .admin-table--clickable tbody tr:focus { background: var(--paper-3); outline: none; }
.admin-empty { padding: var(--space-7) !important; color: var(--muted) !important; text-align: center !important; }
.admin-toolbar { display: flex; align-items: end; flex-wrap: wrap; gap: var(--space-3); padding: var(--space-4); border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--paper-2); }
.admin-field { display: grid; gap: var(--space-2); min-width: 140px; color: var(--muted); font-size: var(--text-xs); font-weight: var(--fw-semibold); }
.admin-field--grow { flex: 1; min-width: 220px; }
.admin-field input, .admin-field select, .admin-table select, .admin-progress { min-height: 42px; padding: var(--space-2) var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper-3); color: var(--ink); font: inherit; }
.admin-field input:focus, .admin-field select:focus, .admin-table select:focus, .admin-progress:focus { border-color: var(--brand); outline: none; }
.admin-progress { width: 70px; min-height: 36px; }
.admin-pager { display: flex; align-items: center; justify-content: flex-end; gap: var(--space-3); margin-top: var(--space-4); color: var(--muted); font-size: var(--text-sm); }
.admin-pager button:disabled { opacity: .4; cursor: not-allowed; }
.admin-cohort-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); }
.admin-cohort-card { padding: var(--space-4); }
.admin-cohort-card > strong, .admin-cohort-card > span, .admin-cohort-card > small { display: block; }
.admin-cohort-card > strong { color: var(--ink); }
.admin-cohort-card > span, .admin-cohort-card > small { margin-top: var(--space-1); color: var(--muted); font-size: var(--text-xs); }
.admin-cohort-card dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-2); margin: var(--space-4) 0; }
.admin-cohort-card dl div { padding: var(--space-2); border-radius: var(--radius-sm); background: var(--paper-3); }
.admin-cohort-card dt { color: var(--muted); font-size: var(--text-xs); }
.admin-cohort-card dd { margin: var(--space-1) 0 0; color: var(--ink); font-family: var(--font-mono); font-weight: var(--fw-bold); }
.admin-export { display: grid; align-content: start; gap: var(--space-4); }
.admin-export p { margin: 0; }
.admin-export .btn { justify-self: start; }
.admin-notice { margin-bottom: var(--space-5); padding: var(--space-3) var(--space-4); border: 1px solid var(--viz-coral); border-radius: var(--radius-sm); background: var(--paper-2); color: var(--text); }
.admin-notice--success { border-color: var(--viz-green); }
.admin-dialog { width: min(760px, calc(100% - var(--space-6))); max-height: calc(100vh - var(--space-6)); padding: var(--space-6); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper-2); color: var(--text); }
.admin-dialog::backdrop { background: color-mix(in srgb, var(--ink-bg) 84%, transparent); }
.admin-dialog__close { position: absolute; top: var(--space-4); right: var(--space-4); width: 40px; height: 40px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--paper-3); color: var(--ink); font-size: var(--text-xl); }
.admin-detail-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3); margin: var(--space-5) 0; }
.admin-detail-list div { padding: var(--space-3); border-radius: var(--radius-sm); background: var(--paper-3); }
.admin-detail-list dt { color: var(--muted); font-size: var(--text-xs); }
.admin-detail-list dd { margin: var(--space-1) 0 0; color: var(--ink); overflow-wrap: anywhere; }
.admin-subhead { margin-top: var(--space-6); }
.admin-wish-list { display: grid; gap: var(--space-2); margin-top: var(--space-3); }
.admin-wish-list li { padding: var(--space-3); border-bottom: 1px solid var(--line-soft); }
.admin-wish-list small { float: right; color: var(--muted); }

@media (max-width: 900px) {
  .admin-shell { grid-template-columns: 1fr; gap: var(--space-4); }
  .admin-nav { position: sticky; top: 66px; z-index: 15; display: flex; overflow-x: auto; padding-block: var(--space-2); background: var(--paper); }
  .admin-nav__item { flex: 0 0 auto; width: auto; white-space: nowrap; }
  .admin-period-grid, .admin-grid-2, .admin-cohort-grid { grid-template-columns: 1fr; }
  .admin-heading { align-items: start; flex-direction: column; }
}
@media (max-width: 560px) {
  .admin-topbar__meta .admin-badge, .admin-topbar__meta .muted { display: none; }
  .admin-shell { padding-inline: var(--space-3); }
  .admin-metrics, .admin-detail-list { grid-template-columns: 1fr; }
  .admin-toolbar { align-items: stretch; flex-direction: column; }
  .admin-field, .admin-field--grow { width: 100%; min-width: 0; }
  .admin-pager { justify-content: center; }
}
