:root {
  --bg: #ffffff;
  --ink: #3d3a4a;
  --muted: #9a97a8;
  --purple: #6f5f97;
  --purple-2: #8a7ab5;
  --lav: #f5f2fb;
  --lav-2: #efe9f8;
  --line: #ece9f3;
  --shadow: 0 6px 24px rgba(111, 95, 151, 0.08);
  --radius: 18px;
  --max: 1080px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  /* 어떤 요소가 삐져나오더라도 페이지가 가로로 밀리지 않게 하는 최종 방어선.
     clip은 스크롤 컨테이너를 만들지 않아 sticky 헤더가 그대로 동작함
     (hidden으로 하면 sticky가 깨질 수 있어 clip만 씀 — 미지원 브라우저는
      .hero / .two-col 쪽 개별 처리로 커버). */
  overflow-x: clip;
}

body {
  font-family: "Noto Sans KR", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ===== 공통 ===== */
.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 32px 24px;
}

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px;
}

.section-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 24px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, var(--purple-2), var(--purple));
  color: #fff;
  font-size: 0.95rem;
  font-weight: 500;
  padding: 12px 24px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(111, 95, 151, 0.28);
}

/* ===== 헤더 ===== */
.header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  position: relative;
  max-width: var(--max);
  margin: 0 auto;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 24px;
}
.logo {
  display: inline-flex;
  align-items: center;
  line-height: 1;
}
.logo-img {
  display: block;
  height: 40px;
  width: auto;
}
.btn-login {
  position: absolute;
  right: 24px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--lav-2);
  color: var(--purple);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 8px 16px;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn-login:hover { background: #e6def5; }
.btn-login__icon { display: inline-flex; }
/* 좁은 화면: 헤더의 로고(가운데)와 버튼(오른쪽)이 겹치지 않게 버튼을 조금 줄임 */
@media (max-width: 480px) {
  .btn-login { right: 16px; padding: 6px 12px; font-size: 0.82rem; gap: 4px; }
}
@media (max-width: 380px) {
  .btn-login { padding: 5px 10px; font-size: 0.76rem; }
  .btn-login__icon svg { width: 14px; height: 14px; }
}

/* ===== 히어로 ===== */
.hero {
  max-width: var(--max);
  margin: 0 auto;
  padding: 64px 24px 48px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 40px;
  /* 장식 아크(.hero-arc)는 회전 때문에 실제 박스가 원보다 훨씬 커서(337px → 472px)
     좁은 화면에서 좌우로 삐져나가 페이지에 가로 스크롤이 생겼음.
     clip은 스크롤 컨테이너를 만들지 않아 세로 스크롤·sticky에 영향이 없음.
     (구형 브라우저용으로 hidden을 먼저 두고 clip으로 덮어씀) */
  overflow-x: hidden;
  overflow-x: clip;
}
.hero-title {
  font-weight: 700;
  line-height: 1.35;
  color: var(--ink);
  margin-bottom: 20px;
}
/* 2줄 고정(각 줄 nowrap) + 2줄 유지 가능한 최대 크기로 유동 */
.hero-title > span {
  display: block;
  white-space: nowrap;
  font-size: clamp(2rem, 4vw, 2.75rem);
}
.hero-name {
  color: var(--purple-2);
  font-weight: 700;
}
.hero-sub {
  color: var(--muted);
  font-weight: 300;
  font-size: clamp(0.92rem, 1.6vw, 1rem);
  line-height: 1.75;
  max-width: 28em;
  margin-bottom: 32px;
}
.br-mob { display: none; }

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* 비율 기반 스테이지 — 컨테이너 너비에 맞춰 전체가 비례 축소 */
.hero-stage {
  position: relative;
  width: min(100%, 452px);
  aspect-ratio: 1 / 1.1;
}

/* 뒤 은은한 그라데이션 원 (부드러운 후광) */
.hero-glow {
  position: absolute;
  inset: 3%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 38%, #f3ecfc 0%, #e7dcf7 52%, #dccdf2 100%);
  box-shadow: 0 30px 60px rgba(111, 95, 151, 0.16);
}

/* 얇은 장식 링 — 살짝 크게, 사진을 감싸는 테두리 */
.hero-ring {
  position: absolute;
  inset: -1.5%;
  border-radius: 50%;
  border: 1.5px solid #d9cef1;
}

/* 브랜드 컬러 아크 — 원의 일부만 진하게 (포인트) */
.hero-arc {
  position: absolute;
  inset: -1.5%;
  border-radius: 50%;
  border: 2.5px solid transparent;
  border-top-color: var(--purple-2);
  border-right-color: var(--purple-2);
  transform: rotate(28deg);
}

/* 사진 — 살짝 찌그러진 타원 프레임, 전면 */
.hero-photo {
  position: absolute;
  inset: 3%;
  z-index: 2;
  border-radius: 49% 51% 48% 52% / 45% 46% 54% 55%;
  overflow: hidden;
  background: linear-gradient(160deg, #f0ebfa 0%, #e4d9f5 100%);
  box-shadow: 0 26px 52px rgba(111, 95, 151, 0.22);
}
.hero-photo__img {
  position: absolute;
  left: 50%;
  top: 0;
  width: 108%;
  height: 108%;
  transform: translateX(-42%);
  object-fit: cover;
  object-position: 50% 4%;
}

/* 얼굴 근처 반짝임 — 4각 스파클, 불규칙 배치 */
.hero-sparkles {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}
.hero-sparkle {
  position: absolute;
  opacity: 0;
  animation: hero-sparkle 4.8s ease-in-out infinite;
}
.hero-sparkle::before,
.hero-sparkle::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: linear-gradient(90deg, transparent, #fff 48%, #fff 52%, transparent);
  box-shadow: 0 0 5px rgba(255, 255, 255, 0.8), 0 0 10px rgba(186, 168, 228, 0.4);
}
.hero-sparkle::before {
  width: 100%;
  height: 18%;
}
.hero-sparkle::after {
  width: 18%;
  height: 100%;
  background: linear-gradient(180deg, transparent, #fff 48%, #fff 52%, transparent);
}

/* 크기·위치·회전 — 이목구비 기준 왼쪽/오른쪽 머리카락 */
.hero-sparkle--1 { --sz: 14px; --rot: -22deg; top: 15%; left: 41%; animation-delay: 0s;    animation-duration: 5.6s; }
.hero-sparkle--2 { --sz: 11px; --rot: 16deg;  top: 24%; left: 44%; animation-delay: 1.4s;  animation-duration: 4.2s; }
.hero-sparkle--3 { --sz: 16px; --rot: 20deg;  top: 11%; left: 71%; animation-delay: 2.6s;  animation-duration: 5.1s; }
.hero-sparkle--5 { --sz: 7px;  --rot: 12deg;  top: 26%; left: 70%; animation-delay: 3.2s;  animation-duration: 6s;   }
.hero-sparkle--6 { --sz: 6px;  --rot: -14deg; top: 31%; left: 37%; animation-delay: 1.2s;  animation-duration: 5.3s; }
.hero-sparkle--7 { --sz: 5px;  --rot: 20deg;  top: 33%; left: 47%; animation-delay: 2.4s;  animation-duration: 4.9s; }

.hero-sparkle--1,
.hero-sparkle--2,
.hero-sparkle--3,
.hero-sparkle--5,
.hero-sparkle--6,
.hero-sparkle--7 {
  width: var(--sz);
  height: var(--sz);
}

@keyframes hero-sparkle {
  0%, 100% { opacity: 0; transform: rotate(var(--rot)) scale(0.6); }
  20% { opacity: 0.55; transform: rotate(var(--rot)) scale(1); }
  45% { opacity: 0.85; transform: rotate(var(--rot)) scale(1.08); }
  70% { opacity: 0.35; transform: rotate(var(--rot)) scale(0.92); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-sparkle { animation: none; opacity: 0.35; }
}

/* ===== 수업 시간표 ===== */
.table-wrap { overflow-x: auto; }
.timetable {
  width: 100%;
  border-collapse: separate;
  border-spacing: 6px;
  text-align: center;
}
.timetable th {
  background: var(--lav);
  color: var(--ink);
  font-weight: 500;
  font-size: 0.9rem;
  padding: 12px 8px;
  border-radius: 10px;
}
/* 한 블록을 반 칸 2줄로 그리므로 한 줄은 블록 높이의 절반 (반 칸 단위 배치용) */
.timetable td {
  height: 32px;
  padding: 0;
  border-radius: 10px;
  vertical-align: middle;
}
.timetable .col-time {
  background: var(--lav);
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 500;
  width: 52px;
  min-width: 52px;
  min-height: 60px;
  padding: 10px 2px; /* 좌우는 최소로, 위아래로 여유 */
  white-space: nowrap;
  line-height: 1.35;
}
/* 시각 / - / 시각 을 세 줄로 — 가로 폭을 아끼려고 */
.timetable .col-time__t { display: block; }
.timetable .col-time__d { display: block; opacity: 0.5; }
/* 요일 칸은 좁아져도 60px 아래로는 안 줄어들고, 넘치면 표가 가로로 스크롤됨 */
.timetable th:not(.col-time),
.timetable td:not(.col-time) { min-width: 60px; }
.timetable thead .col-time { color: var(--ink); }

.table-empty {
  text-align: center;
  color: var(--muted);
  padding: 24px 12px;
  font-size: 0.9rem;
}

.lesson {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  height: 100%;
  padding: 8px 6px;
  border-radius: 10px;
  transition: transform 0.12s ease, filter 0.12s ease;
}
.lesson:hover { transform: translateY(-1px); filter: brightness(0.97); }
.lesson__name { font-size: 0.85rem; font-weight: 500; }
.lesson__academy { font-size: 0.72rem; opacity: 0.7; }
/* 여러 시간 블록에 걸친(rowspan) 수업도 칸을 꽉 채우게 — 한 칸에 하나일 때만 */
.timetable td > .lesson:only-child { height: 100%; }
.timetable td > .lesson + .lesson { margin-top: 4px; }

.lesson--lav   { background: #ece7f8; color: #6f5f97; }
.lesson--pink  { background: #f7e9f2; color: #a85f88; }
.lesson--blue  { background: #e7eef8; color: #5f7ba8; }
.lesson--amber { background: #f7f0e3; color: #a8895f; }
.lesson--green { background: #e7f1e9; color: #5f8f6f; }
.lesson--teal  { background: #e2eff0; color: #4f8a8f; }

.table-note {
  margin-top: 20px;
  font-size: 0.85rem;
  color: var(--muted);
}
.table-note__icon { color: var(--purple-2); margin-right: 4px; }

/* ===== 2단 (경력 / 홍보 채널) ===== */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
/* grid 자식은 기본 min-width가 auto라 내용의 최소 너비 아래로 안 줄어듦.
   그 탓에 좁은 화면(320px)에서 카드가 화면보다 넓어져 가로 스크롤이 생겼음. */
.two-col > * { min-width: 0; }
/* 줄바꿈할 공백이 없는 긴 문자열(블로그 주소 등)이 칸을 밀어내지 않게 */
.channel__text { min-width: 0; }
.channel__handle,
.material__title,
.timeline__date,
.timeline__desc { overflow-wrap: anywhere; }

.timeline { position: relative; padding-left: 20px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--line);
}
.timeline__item {
  position: relative;
  display: flex;
  gap: 16px;
  padding: 8px 0;
}
.timeline__item::before {
  content: "";
  position: absolute;
  left: -20px;
  top: 15px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--purple-2);
}
.timeline__date {
  min-width: 130px;
  font-size: 0.85rem;
  color: var(--purple);
  font-weight: 500;
}
.timeline__desc { font-size: 0.92rem; color: var(--ink); }

.channels { display: flex; flex-direction: column; gap: 12px; }
.channel {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.channel:hover { background: var(--lav); border-color: #ddd4ee; }
.channel__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  color: #fff;
  flex-shrink: 0;
}
.channel__icon--insta { background: linear-gradient(135deg, #b07db4, #8574b0); }
.channel__icon--yt { background: #c07777; }
.channel__icon--blog {
  background: #74a487;
  font-family: "Nanum Pen Script", cursive;
  font-size: 1.2rem;
}
.channel__text { display: flex; flex-direction: column; flex: 1; }
.channel__name { font-size: 0.92rem; font-weight: 500; }
.channel__handle { font-size: 0.8rem; color: var(--muted); }
.channel__arrow { color: var(--muted); }

/* ===== 홍보 자료 (게시판 목록 — 제목 + 날짜) ===== */
.materials { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.material {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 11px 8px;
  border-bottom: 1px solid var(--line);
  font-size: 0.92rem;
  color: var(--ink);
  transition: color 0.12s ease, padding-left 0.12s ease;
}
.material__title { flex: 1; min-width: 0; }
.material__title::before { content: "· "; color: var(--purple-2); }
/* 날짜는 줄바꿈 없이 오른쪽 고정 */
.material__date {
  flex: none;
  font-size: 0.8rem;
  color: var(--muted);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.material:hover { color: var(--purple); padding-left: 14px; }
.material:hover .material__date { color: var(--purple-2); }

/* 페이지 이동 (홍보 자료 — 5개씩) */
.pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4px;
  margin-top: 16px;
}
.pager:empty { display: none; } /* 1페이지뿐이면 공간도 차지하지 않음 */
.pager__btn {
  min-width: 30px;
  height: 30px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: none;
  color: var(--muted);
  font-family: inherit;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.12s ease, color 0.12s ease;
}
.pager__btn:hover:not(:disabled) { background: var(--lav-soft, #f3effa); color: var(--purple); }
.pager__btn.is-active {
  background: var(--purple);
  color: #fff;
  font-weight: 500;
}
.pager__btn:disabled { opacity: 0.3; cursor: default; }
.pager__btn--nav { font-size: 1rem; line-height: 1; }

/* ===== 푸터 ===== */
.footer {
  margin-top: 40px;
  background: var(--purple);
  color: rgba(255, 255, 255, 0.85);
}
.footer-inner {
  position: relative;
  max-width: var(--max);
  margin: 0 auto;
  padding: 24px;
  text-align: center;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
}
.to-top {
  position: absolute;
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  transition: background 0.12s ease;
}
.to-top:hover { background: rgba(255, 255, 255, 0.28); }

.footer-links { margin-top: 6px; }
.footer-links a {
  color: rgba(255, 255, 255, 0.95);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.footer-links a:hover { color: #fff; }

/* ===== 반응형 ===== */
@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 40px 24px 24px;
    gap: 24px;
  }
  .hero-visual { order: -1; justify-content: center; }
  .hero-stage { width: min(100%, 340px); }
  .hero-title > span { font-size: clamp(1.5rem, 7.2vw, 2.6rem); }
  .hero-sub { margin: 0 auto 24px; max-width: 26em; }
  .br-mob { display: block; }
  .two-col { grid-template-columns: 1fr; }
}
