/* 이음학원 홈페이지 공통 스타일
   레이아웃 개념: 학교 알림장처럼 담백한 흰 바탕 + 이음 청록 띠, 금색은 '지금 알릴 것'에만 사용 */
:root {
  --teal: #003E4D;        /* 메인 브랜드색 (로고) */
  --teal-deep: #00252E;   /* 푸터 */
  --teal-soft: #E9EFEF;   /* 연한 청록 바탕 */
  --teal-mid: #3D6B75;    /* 보조 라벨 */
  --gold: #C9A66B;        /* 강조 (공지·개강) */
  --gold-ink: #7A5A1E;    /* 흰 바탕 위 금색 글자 */
  --paper: #F6F6F3;       /* 섹션 바탕 */
  --white: #FFFFFF;
  --ink: #111D20;         /* 본문 글자 */
  --muted: #5E6B6E;       /* 보조 글자 */
  --line: #DCDFDD;        /* 구분선 */
  --on-teal: #A9C3C8;     /* 청록 위 보조 글자 */
  --kor: #E2202C; --math: #EDAFAD; --eng: #F9B823;  /* 이음국어·수학·영어 */
  --todo-bg: #FFF6DA; --todo-line: #C99A1E;

  --font: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  --wrap: 1120px;
  --gutter-l: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--white); color: var(--ink);
  font-family: var(--font); font-size: 17px; line-height: 1.7; letter-spacing: -0.01em;
  word-break: keep-all; overflow-wrap: break-word;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.3; letter-spacing: -0.035em; text-wrap: balance; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }
.num { font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding-left: var(--gutter-l); padding-right: var(--gutter-r); }

/* ---------- 헤더 ---------- */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 60; background: var(--white); }
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50; background: var(--white); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex: none; }
.brand .sym { height: 38px; width: auto; }
.brand .word { height: 22px; width: auto; }
.nav-toggle { display: none; }
.site-nav ul { list-style: none; display: flex; gap: 4px; align-items: center; }
.site-nav a { display: block; padding: 10px 12px; border-radius: 8px; text-decoration: none; font-size: 15.5px; font-weight: 600; color: var(--teal); white-space: nowrap; }
.site-nav a:hover { background: var(--teal-soft); }
.site-nav a[aria-current="page"] { background: var(--teal); color: var(--white); }
.site-nav .nav-call { margin-left: 8px; border: 1.5px solid var(--teal); }
.site-nav .nav-call:hover { background: var(--teal); color: var(--white); }

@media (max-width: 1100px) {
  .nav-toggle { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1.5px solid var(--teal); border-radius: 8px; background: var(--white); color: var(--teal); font: 600 15px var(--font); cursor: pointer; }
  .nav-toggle .bars { width: 18px; height: 12px; position: relative; border-top: 2px solid currentColor; border-bottom: 2px solid currentColor; }
  .nav-toggle .bars::after { content: ""; position: absolute; left: 0; right: 0; top: 3px; border-top: 2px solid currentColor; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-bottom: 1px solid var(--line); box-shadow: 0 12px 24px rgba(17,29,32,0.08); }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; padding: 8px var(--gutter-r) 16px var(--gutter-l); gap: 2px; }
  .site-nav a { padding: 13px 12px; font-size: 16.5px; }
  .site-nav .nav-call { margin: 8px 0 0; text-align: center; }
}

/* ---------- 공통 섹션 ---------- */
.section { padding-block: 88px; }
.section.paper { background: var(--paper); }
.section.tight { padding-block: 56px; }
.eyebrow { display: block; font-size: 14px; font-weight: 700; letter-spacing: 0.08em; color: var(--teal-mid); margin-bottom: 14px; }
.section-head { display: flex; flex-direction: column; gap: 14px; max-width: 720px; margin-bottom: 44px; }
.section-head h2 { font-size: clamp(28px, 3.4vw, 38px); font-weight: 750; }
.section-head p { color: var(--muted); font-size: 17.5px; }
.lede { font-size: 18.5px; color: var(--muted); max-width: 680px; }
.prose { max-width: 680px; display: flex; flex-direction: column; gap: 16px; }
.prose p { color: #34413F; }
.prose strong { color: var(--teal); font-weight: 650; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 22px; border-radius: 10px; font-weight: 650; font-size: 16px; text-decoration: none; border: 1.5px solid transparent; transition: background .15s, color .15s; }
.btn-gold { background: var(--gold); color: var(--teal-deep); }
.btn-gold:hover { background: #D8B985; }
.btn-line-light { border-color: rgba(255,255,255,0.5); color: var(--white); }
.btn-line-light:hover { background: rgba(255,255,255,0.1); }
.btn-teal { background: var(--teal); color: var(--white); }
.btn-teal:hover { background: var(--teal-deep); }
.btn-line { border-color: var(--teal); color: var(--teal); }
.btn-line:hover { background: var(--teal-soft); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- 메인 히어로 ---------- */
.hero { background: var(--teal); color: var(--white); overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); align-items: center; gap: 48px; padding-block: 84px 76px; }
.hero-copy { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.hero .kicker { font-size: 15px; font-weight: 600; letter-spacing: 0.04em; color: var(--gold); }
.hero h1 { font-size: clamp(40px, 6.2vw, 72px); font-weight: 780; line-height: 1.16; letter-spacing: -0.05em; }
.hero p { font-size: 18.5px; color: #CFE0E3; max-width: 34em; }
.hero-mark { justify-self: end; width: min(100%, 330px); opacity: 0.95; }
.hero-mark img { width: 100%; }

.notice-strip { background: var(--gold); color: var(--teal-deep); }
.notice-strip .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 24px; padding-block: 16px; }
.notice-strip .items { display: flex; flex-wrap: wrap; gap: 6px 28px; font-weight: 650; }
.notice-strip .items span b { font-weight: 800; }
.notice-strip a { font-weight: 700; text-decoration: none; white-space: nowrap; border-bottom: 2px solid currentColor; }

/* ---------- 페이지 머리 (서브 페이지) ---------- */
.page-head { background: var(--teal); color: var(--white); }
.page-head .wrap { padding-block: 64px 56px; display: flex; flex-direction: column; gap: 14px; }
.page-head .crumb { font-size: 14px; color: var(--on-teal); }
.page-head .crumb a { color: var(--on-teal); text-decoration: none; }
.page-head h1 { font-size: clamp(32px, 4.6vw, 48px); font-weight: 780; }
.page-head p { color: #CFE0E3; font-size: 18px; max-width: 40em; }

/* ---------- 특징 (이음의 방식) ---------- */
.ways { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border-top: 2px solid var(--ink); }
.way { padding: 28px 28px 32px 0; display: flex; flex-direction: column; gap: 12px; border-bottom: 1px solid var(--line); }
.way + .way { padding-left: 28px; border-left: 1px solid var(--line); }
.way .tag { font-size: 14px; font-weight: 700; color: var(--teal-mid); letter-spacing: 0.02em; }
.way h3 { font-size: 23px; font-weight: 720; }
.way p { color: var(--muted); font-size: 16.5px; }

/* ---------- 과목 띠 ---------- */
.subjects { background: var(--teal); color: var(--white); }
.subjects .section-head h2 { color: var(--white); }
.subjects .section-head p { color: var(--on-teal); }
.subjects .eyebrow { color: var(--gold); }
.subject-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.subject { background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.14); border-radius: 16px; padding: 28px; display: flex; flex-direction: column; gap: 14px; }
.subject .name { display: flex; align-items: center; gap: 12px; font-size: 24px; letter-spacing: -0.03em; }
.subject .name img { height: 36px; width: auto; }
.subject .name b { font-weight: 800; }
.subject .name span { font-weight: 400; }
.subject p { color: #CFE0E3; font-size: 16.5px; }
.subject ul { list-style: none; display: flex; flex-direction: column; gap: 6px; font-size: 15.5px; color: var(--white); }
.subject li::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--dot, var(--gold)); margin-right: 10px; vertical-align: middle; }
.subject.kor { --dot: var(--kor); } .subject.math { --dot: var(--math); } .subject.eng { --dot: var(--eng); }

/* ---------- 바로가기 ---------- */
.quick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.quick a { display: flex; flex-direction: column; justify-content: space-between; gap: 28px; min-height: 148px; padding: 22px 22px 20px; background: var(--white); border: 1px solid var(--line); border-radius: 14px; text-decoration: none; transition: border-color .15s, transform .15s; }
.quick a:hover { border-color: var(--teal); transform: translateY(-3px); }
.quick .q-title { font-size: 19px; font-weight: 720; color: var(--teal); letter-spacing: -0.03em; }
.quick .q-desc { font-size: 14.5px; color: var(--muted); line-height: 1.55; }
.quick .q-arrow { align-self: flex-end; width: 28px; height: 28px; color: var(--teal); }

/* ---------- 연락 띠 ---------- */
.contact-band { background: var(--paper); border-top: 1px solid var(--line); }
.contact-band .wrap { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 48px; align-items: center; padding-block: 52px; }
.contact-band h2 { font-size: 26px; font-weight: 750; }
.contact-band .phone { font-size: clamp(32px, 4.4vw, 44px); font-weight: 800; color: var(--teal); letter-spacing: -0.03em; text-decoration: none; }
.contact-band p { color: var(--muted); }

/* ---------- 정보 표 (라벨 / 값) ---------- */
.facts { display: grid; grid-template-columns: 160px minmax(0, 1fr); border-top: 2px solid var(--ink); }
.facts dt, .facts dd { margin: 0; padding: 16px 0; border-bottom: 1px solid var(--line); }
.facts dt { font-weight: 650; color: var(--teal-mid); font-size: 15.5px; }
.facts dd { color: var(--ink); }

/* ---------- 표 ---------- */
.table-box { overflow-x: auto; border-top: 2px solid var(--ink); }
table { width: 100%; border-collapse: collapse; font-size: 16px; }
th, td { text-align: left; padding: 14px 16px 14px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-weight: 650; color: var(--teal-mid); font-size: 14.5px; white-space: nowrap; }
td b { font-weight: 650; }
.table-note { margin-top: 14px; font-size: 14.5px; color: var(--muted); }

/* ---------- 리스트 행 (반 구성, 로드맵) ---------- */
.rows { border-top: 2px solid var(--ink); }
.row { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 20px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.row .k { font-weight: 720; color: var(--teal); font-size: 18px; }
.row .v { display: flex; flex-direction: column; gap: 8px; color: #34413F; }
.row .v b { color: var(--ink); font-weight: 650; }

.steps { list-style: none; counter-reset: s; border-top: 2px solid var(--ink); }
.steps li { counter-increment: s; display: grid; grid-template-columns: 52px minmax(0, 220px) minmax(0, 1fr); gap: 16px; align-items: baseline; padding: 20px 0; border-bottom: 1px solid var(--line); }
.steps li::before { content: counter(s, decimal-leading-zero); font-weight: 700; color: var(--teal-mid); font-variant-numeric: tabular-nums; }
.steps b { font-size: 19px; font-weight: 720; }
.steps span { color: var(--muted); }
.steps li.goal { background: var(--teal); color: var(--white); border-radius: 12px; padding: 20px; margin-top: 12px; border: 0; }
.steps li.goal::before { color: var(--gold); }
.steps li.goal span { color: var(--on-teal); }

/* ---------- 두 칸 ---------- */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.stack { display: flex; flex-direction: column; gap: 22px; }
.stack-lg { display: flex; flex-direction: column; gap: 64px; }
h3.sub { font-size: 22px; font-weight: 720; }

/* ---------- 학교 칩 ---------- */
.school-group { display: flex; flex-direction: column; gap: 14px; }
.school-group h3 { font-size: 18px; font-weight: 700; color: var(--teal-mid); }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; }
.chips li { padding: 10px 18px; border: 1.5px solid var(--teal); border-radius: 999px; font-weight: 650; color: var(--teal); background: var(--white); }

/* ---------- 학습기록 예시 카드 ---------- */
.report { background: var(--white); border-radius: 18px; box-shadow: 0 1px 2px rgba(17,29,32,0.06), 0 14px 34px rgba(17,29,32,0.09); overflow: hidden; font-size: 15.5px; }
.report-top { background: var(--teal); color: var(--white); padding: 14px 22px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.report-top b { font-weight: 700; }
.report-top span { color: var(--on-teal); font-size: 13.5px; }
.report-who { padding: 14px 22px; border-bottom: 1px solid #E6E9E8; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.report-who b { font-size: 18px; }
.report-who span { color: var(--muted); }
.report-who em { font-style: normal; color: var(--teal); font-weight: 650; }
.report dl { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 8px 14px; margin: 0; padding: 16px 22px; }
.report dt { color: var(--muted); font-weight: 650; }
.report dd { margin: 0; }
.report .comment { border-top: 1.5px solid var(--ink); margin: 0 22px; padding: 14px 0 20px; }
.report .comment dl { padding: 8px 0 0; }
.report .comment dt { color: var(--teal); }
.report .label { font-size: 13px; font-weight: 700; color: var(--teal-mid); letter-spacing: 0.02em; }
.report .hl { background: var(--teal-soft); border-radius: 8px; padding: 8px 12px; color: var(--teal); font-weight: 600; }

/* ---------- 입력 필요 표시 (공개 전 반드시 채움) ---------- */
.todo { border: 2px dashed var(--todo-line); background: var(--todo-bg); color: #5A4300; border-radius: 12px; padding: 18px 20px; font-size: 15.5px; display: flex; flex-direction: column; gap: 6px; }
.todo b { font-weight: 750; }
.todo::before { content: "입력 필요"; font-size: 12.5px; font-weight: 800; letter-spacing: 0.08em; color: var(--todo-line); }

/* ---------- 탭 (시간표) ---------- */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.tabs button { min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1.5px solid var(--teal); background: var(--white); color: var(--teal); font: 650 15.5px var(--font); cursor: pointer; }
.tabs button[aria-selected="true"] { background: var(--teal); color: var(--white); }

/* ---------- 선생님 ---------- */
.teacher-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }

/* ---------- 연락처 ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.contact-card { border: 1px solid var(--line); border-radius: 14px; padding: 24px; display: flex; flex-direction: column; gap: 10px; background: var(--white); }
.contact-card .label { font-size: 14px; font-weight: 700; color: var(--teal-mid); }
.contact-card .big { font-size: 26px; font-weight: 800; color: var(--teal); letter-spacing: -0.03em; text-decoration: none; }
.contact-card p { color: var(--muted); font-size: 15.5px; }
.contact-card a.link { color: var(--teal); font-weight: 650; }

/* ---------- 푸터 ---------- */
.site-footer { background: var(--teal-deep); color: #9FB4B9; font-size: 14.5px; }
.site-footer .wrap { padding-block: 56px calc(48px + env(safe-area-inset-bottom, 0px)); display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 32px 56px; align-items: start; }
.foot-brand { display: flex; flex-direction: column; gap: 14px; }
.foot-brand .row-logo { display: flex; align-items: center; gap: 10px; }
.foot-brand .row-logo .sym { height: 44px; width: auto; }
.foot-brand .row-logo .word { height: 24px; width: auto; }
.foot-brand .slogan { color: #D3E0E3; }
.foot-info { display: flex; flex-direction: column; gap: 6px; line-height: 1.7; }
.foot-info .sep { margin: 0 8px; color: #4D6970; }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; }
.foot-links a { color: #D3E0E3; text-decoration: none; font-weight: 600; }
.foot-links a:hover { text-decoration: underline; }
.copy { margin-top: 12px; color: #6F888E; font-size: 13.5px; }

/* ---------- 반응형 ---------- */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; padding-block: 56px 52px; gap: 28px; }
  .hero-mark { display: none; }
  .ways { grid-template-columns: 1fr; }
  .way, .way + .way { padding: 24px 0; border-left: 0; }
  .subject-grid, .teacher-grid, .contact-grid { grid-template-columns: 1fr; }
  .quick { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; gap: 40px; }
  .contact-band .wrap { grid-template-columns: 1fr; }
  .site-footer .wrap { grid-template-columns: 1fr; }
  .section { padding-block: 64px; }
}
@media (max-width: 560px) {
  body { font-size: 16.5px; }
  .quick { grid-template-columns: 1fr; }
  .quick a { min-height: 0; gap: 10px; }
  .facts { grid-template-columns: 1fr; }
  .facts dt { padding-bottom: 0; border-bottom: 0; }
  .row { grid-template-columns: 1fr; gap: 6px; }
  .steps li { grid-template-columns: 40px minmax(0, 1fr); }
  .steps li span { grid-column: 2; }
  .brand .sym { height: 32px; } .brand .word { height: 19px; }
  .report dl { grid-template-columns: 1fr; gap: 2px; }
  .report dd { margin-bottom: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
