/* tale 정식 사이트 공통 스타일. 인스타(@tale_ai_class)와 같은 톤: 검정 + 틸, 동화 오브제.
   페이지별 고유 스타일은 각 페이지 <style> 에만 둔다. */
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
:root {
  --bg: #050807; --bg2: #0a1110; --card: #0d1715; --ink: #e9f4f2; --dim: #9fb7b2; --mute: #6f8a85;
  --accent: #4fd4c6; --accent-ink: #04201c; --line: rgba(233,244,242,.10); --line2: rgba(79,212,198,.35);
  --radius: 18px; --wrap: 1120px;
}
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--ink); font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.65; word-break: keep-all; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img { max-width: 100%; display: block; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }

/* ── 상단 바 + 상품 탭 ───────────────── */
.t-top { position: sticky; top: 0; z-index: 50; background: rgba(5,8,7,.86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top, 0px); }
.t-bar { display: flex; align-items: center; justify-content: space-between; height: 58px; }
.t-brand { font-weight: 800; font-size: 1.25rem; letter-spacing: -.04em; text-decoration: none; }
.t-brand span { color: var(--accent); }
.t-cta { background: var(--accent); color: var(--accent-ink); font-weight: 800; font-size: .88rem; padding: 9px 16px; border-radius: 99px; text-decoration: none; border: 0; cursor: pointer; font-family: inherit; }
.t-tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; padding-bottom: 10px; }
.t-tabs::-webkit-scrollbar { display: none; }
.t-tab { flex: none; text-decoration: none; font-weight: 700; font-size: .92rem; color: var(--dim); padding: 8px 14px; border-radius: 99px; border: 1px solid transparent; white-space: nowrap; }
.t-tab:hover { color: var(--ink); }
.t-tab[aria-current="page"] { color: var(--accent); border-color: var(--line2); background: rgba(79,212,198,.08); }
.t-tab small { font-weight: 600; font-size: .72rem; color: var(--mute); margin-left: 4px; }

/* ── 공통 블록 ─────────────────────── */
.hero { padding: 56px 0 40px; }
.eyebrow { display: inline-block; color: var(--accent); font-weight: 700; font-size: .85rem; letter-spacing: .02em; margin-bottom: 14px; }
.h1 { font-size: clamp(2rem, 5.4vw, 3.4rem); line-height: 1.2; letter-spacing: -.045em; font-weight: 800; }
.h1 em, .h2 em { font-style: normal; color: var(--accent); }
.lede { color: var(--dim); font-size: clamp(1rem, 2vw, 1.15rem); margin-top: 16px; max-width: 640px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.btn { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 800; padding: 14px 22px; border-radius: 14px; border: 1px solid var(--line); font-size: 1rem; cursor: pointer; font-family: inherit; background: transparent; color: var(--ink); }
.btn-p { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-top: 28px; }
.fact { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 13px 16px; }
.fact b { display: block; color: var(--mute); font-size: .76rem; font-weight: 600; }
.fact span { font-weight: 700; }
.sec { padding: 44px 0; border-top: 1px solid var(--line); }
.h2 { font-size: clamp(1.4rem, 3.2vw, 2rem); letter-spacing: -.04em; line-height: 1.3; font-weight: 800; }
.sub { color: var(--dim); margin-top: 8px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; margin-top: 22px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.card h3 { font-size: 1.08rem; letter-spacing: -.03em; margin-bottom: 6px; }
.card p { color: var(--dim); font-size: .94rem; }
.card .tag { display: inline-block; font-size: .74rem; font-weight: 700; color: var(--accent); border: 1px solid var(--line2); border-radius: 99px; padding: 2px 9px; margin-bottom: 10px; }
.steps { counter-reset: s; display: grid; gap: 10px; margin-top: 20px; }
.step { counter-increment: s; display: grid; grid-template-columns: 38px 1fr; gap: 12px; align-items: start; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }
.step::before { content: counter(s); width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-weight: 800; display: grid; place-items: center; }
.step b { display: block; }
.step span { color: var(--dim); font-size: .93rem; }
.tutors { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; margin-top: 18px; }
.tutor { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; }
.tutor b { color: var(--accent); font-size: 1.05rem; }
.tutor p { color: var(--dim); font-size: .9rem; margin-top: 4px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; margin-top: 10px; }
.faq summary { font-weight: 700; cursor: pointer; }
.faq p { color: var(--dim); margin-top: 8px; font-size: .94rem; }
.note { color: var(--mute); font-size: .86rem; margin-top: 12px; }

/* ── 상담 위젯 (챗봇 + 연락처) ────────── */
.consult { background: var(--bg2); border: 1px solid var(--line2); border-radius: 22px; padding: 20px; margin-top: 22px; }
.c-log { display: grid; gap: 10px; max-height: 420px; overflow-y: auto; padding: 4px 2px 10px; }
.c-msg { max-width: 86%; padding: 11px 14px; border-radius: 16px; font-size: .95rem; line-height: 1.6; white-space: pre-line; }
.c-bot { background: var(--card); border: 1px solid var(--line); border-top-left-radius: 4px; }
.c-me { background: var(--accent); color: var(--accent-ink); justify-self: end; border-top-right-radius: 4px; font-weight: 600; }
.c-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 10px; }
.c-chip { background: transparent; color: var(--ink); border: 1px solid var(--line2); border-radius: 99px; padding: 7px 12px; font: inherit; font-size: .86rem; cursor: pointer; }
.c-form { display: flex; gap: 8px; }
.c-form input { flex: 1; min-width: 0; background: var(--bg); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; font: inherit; font-size: 1rem; }
.c-form button { background: var(--accent); color: var(--accent-ink); border: 0; border-radius: 12px; padding: 0 16px; font: inherit; font-weight: 800; cursor: pointer; }
.c-lead-open { width: 100%; margin-top: 10px; background: transparent; color: var(--accent); border: 1px dashed var(--line2); border-radius: 12px; padding: 12px; font: inherit; font-weight: 800; cursor: pointer; }
.c-lead { display: grid; gap: 10px; margin-top: 12px; }
.c-lead input { width: 100%; background: var(--bg); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; font: inherit; font-size: 1rem; }
.c-lead label.chk { display: flex; gap: 8px; align-items: flex-start; color: var(--dim); font-size: .84rem; }
.c-lead label.chk input { width: auto; margin-top: 4px; }
.c-lead .btn-p { justify-content: center; }
.c-status { font-size: .86rem; color: var(--dim); min-height: 1.2em; }
.c-status.err { color: #ff9b9b; }
.c-quick { color: var(--mute); font-size: .84rem; margin-top: 10px; text-align: center; }
.c-quick button { background: none; border: 0; color: var(--dim); text-decoration: underline; font: inherit; cursor: pointer; }

/* ── 푸터 ─────────────────────────── */
.t-foot { border-top: 1px solid var(--line); margin-top: 40px; padding: 28px 0 calc(40px + env(safe-area-inset-bottom, 0px)); color: var(--mute); font-size: .82rem; }
.t-foot a { color: var(--mute); }
.t-foot .links { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-bottom: 14px; }
.t-foot .biz span { display: inline-block; margin-right: 10px; }

/* 모바일 하단 고정 신청 버튼 */
.sticky-cta { position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); z-index: 40; display: none; }
@media (max-width: 720px) {
  .sticky-cta { display: block; }
  .sticky-cta .btn { width: 100%; justify-content: center; box-shadow: 0 10px 30px rgba(0,0,0,.5); }
  .t-foot { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
}
