/* ==========================================
   베르벤음악학원 홍보 페이지 (verveine.co.kr)
   색: 앱과 같은 톤 + 첫 화면에만 밤 외관에서 딴 어두운 색
   ========================================== */
:root {
  --ink: #592424;        /* 로고·제목 (앱 primary) */
  --clay: #A65E44;       /* 버튼·강조 */
  --clay-dark: #8E4B33;
  --clay-light: #E0A07E; /* 어두운 첫 화면 위 강조 (테라코타의 밝은 톤) */
  --cream: #FAF6F3;      /* 배경 */
  --sand: #E8DCD4;       /* 구분선 */
  --night: #1F1715;      /* 첫 화면 (밤 외관) */
  --text: #2C221E;
  --text-sub: #6E5C54;

  --font-display: 'Sora', 'Pretendard', sans-serif;
  --font-body: 'Pretendard', -apple-system, BlinkMacSystemFont, sans-serif;

  --gutter: clamp(16px, 5vw, 64px);
  --max: 1200px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body { background: var(--cream); color: var(--text); font-family: var(--font-body); font-size: 16px; line-height: 1.7; word-break: keep-all; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--clay); outline-offset: 3px; border-radius: 4px; }

.skip-link { position: absolute; left: 16px; top: -48px; padding: 8px 14px; background: var(--ink); color: #fff; border-radius: 6px; z-index: 100; }
.skip-link:focus { top: 12px; }

/* ---------- 머리글 ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 32px;
  height: 64px; padding: 0 var(--gutter);
  background: rgba(250, 246, 243, 0.94); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--sand);
}
.wordmark { font-family: var(--font-display); font-weight: 700; font-size: 21px; letter-spacing: -0.025em; color: var(--ink); text-decoration: none; white-space: nowrap; }
.site-nav { display: flex; gap: 28px; margin-left: auto; }
.site-nav a { font-size: 15px; font-weight: 600; color: var(--text-sub); text-decoration: none; }
.site-nav a:hover { color: var(--ink); }
.btn-login { font-size: 14px; font-weight: 700; color: var(--ink); text-decoration: none; padding: 8px 16px; border: 1px solid var(--ink); border-radius: 999px; white-space: nowrap; }
.btn-login:hover { background: var(--ink); color: #fff; }

/* ---------- 공통 ---------- */
.section { max-width: var(--max); margin: 0 auto; padding: clamp(72px, 10vw, 128px) var(--gutter) 0; }
h1, h2 { font-family: var(--font-display); font-weight: 700; letter-spacing: -0.03em; line-height: 1.25; }
h2 { font-size: clamp(28px, 3.6vw, 42px); color: var(--ink); }

.btn { display: inline-flex; align-items: center; justify-content: center; height: 50px; padding: 0 24px; border-radius: 999px; font-size: 15px; font-weight: 700; text-decoration: none; transition: background 0.2s, color 0.2s, border-color 0.2s; }
.btn-primary { background: var(--clay); color: #fff; }
.btn-primary:hover { background: var(--clay-dark); }
.btn-ghost { border: 1px solid rgba(255, 255, 255, 0.55); color: #fff; }
.btn-ghost:hover { border-color: #fff; background: rgba(255, 255, 255, 0.1); }

/* ---------- 첫 화면: 밤의 외관 ---------- */
.hero { position: relative; height: min(88svh, 860px); min-height: 520px; overflow: hidden; background: var(--night); }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 60%; animation: hero-settle 2.4s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes hero-settle { from { transform: scale(1.06); opacity: 0.4; } to { transform: scale(1); opacity: 1; } }
.hero-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(31, 23, 21, 0) 35%, rgba(31, 23, 21, 0.86) 100%); }
.hero-copy { position: absolute; left: var(--gutter); right: var(--gutter); bottom: clamp(40px, 8vh, 88px); max-width: 720px; color: #fff; }
.hero h1 { font-size: clamp(34px, 5.6vw, 68px); color: #fff; }
.hero h1 span { display: block; }
.hero-line { font-size: 0.7em; margin-bottom: 0.15em; } /* 70% 크기 */
.hero-name { color: var(--clay-light); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

/* ---------- 수업: 세로 목록 ---------- */
.section.lessons { padding-top: clamp(43px, 6vw, 77px); } /* 첫 화면과의 간격: 다른 영역보다 40% 좁게 */
.lesson-list { list-style: none; margin-top: 24px; }
.lesson { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 16px; padding: 18px 0; }
.lesson h3 { font-family: var(--font-display); font-weight: 700; font-size: clamp(22px, 2.4vw, 30px); letter-spacing: -0.03em; line-height: 1.3; color: var(--ink); }
.lesson .slash { margin: 0 0.35em; font-weight: 600; color: var(--clay); }
.soon { margin-left: 8px; font-family: var(--font-body); font-size: 0.55em; font-weight: 600; letter-spacing: 0; color: var(--text-sub); }
.genres { font-size: 16px; color: var(--text-sub); }

/* ---------- 로비 ---------- */
.lobby { display: grid; grid-template-columns: 1.35fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.lobby-main img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 4px; }
.lobby-text p { margin-top: 20px; color: var(--text-sub); }
.lobby-main img { transition: opacity 0.25s ease; }
.lobby-main img.is-swapping { opacity: 0; }

/* 작은 사진 띠: 옆으로 넘기고, 누르면 큰 사진이 바뀜 */
.thumb-strip { position: relative; margin-top: 32px; }
.thumb-track { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 4px 2px; }
.thumb-track::-webkit-scrollbar { display: none; }
.thumb { flex: 0 0 calc((100% - 20px) / 3); scroll-snap-align: start; padding: 0; border: none; border-radius: 6px; background: none; cursor: pointer; overflow: hidden; outline: 2px solid transparent; outline-offset: 2px; transition: outline-color 0.2s; }
.thumb img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; opacity: 0.6; transition: opacity 0.2s; }
.thumb:hover img, .thumb.is-active img { opacity: 1; }
.thumb.is-active { outline-color: var(--clay); }
/* 사진 위에 겹치는 화살표 (로그인 전 화면 배너와 같은 모양), 끝에 닿으면 숨김 */
.thumb-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 1;
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 48px; padding: 0; border: none; background: none;
  color: #fff; cursor: pointer;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.6)) drop-shadow(0 0 6px rgba(0, 0, 0, 0.3)); /* 밝은 사진 위에서도 보이게 */
  transition: opacity 0.2s, transform 0.2s;
}
.thumb-arrow svg { width: 30px; height: 30px; fill: none; stroke: currentColor; stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.thumb-arrow:hover { transform: translateY(-50%) scale(1.15); }
.thumb-arrow.prev { left: 4px; }
.thumb-arrow.next { right: 4px; }
.thumb-arrow:disabled { opacity: 0; pointer-events: none; }

/* ---------- 연습실 복도 (옆으로 넘기기) ---------- */
.rooms { max-width: none; padding-left: 0; padding-right: 0; }
.rooms-head { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.rooms-desc { margin-top: 16px; color: var(--text-sub); }
/* 연습실 띠 위에 겹치는 화살표 (로비 사진 띠와 같은 모양, 더 크게) */
.corridor-wrap { position: relative; }
.corridor-arrow { width: 56px; height: 80px; top: 42%; }
.corridor-arrow svg { width: 46px; height: 46px; stroke-width: 3; }
.corridor-arrow.prev { left: calc(var(--gutter) + 6px); }
.corridor-arrow.next { right: 6px; }

/* 같은 크기의 문이 복도처럼 이어짐: 문틀(샌드) 안에 방 사진 */
.corridor {
  list-style: none; display: flex; gap: clamp(14px, 2vw, 24px);
  margin-top: 40px; padding: 0 var(--gutter) 8px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 var(--gutter);
  scrollbar-width: none;
}
.corridor::-webkit-scrollbar { display: none; }
.door {
  position: relative; flex: 0 0 clamp(220px, 24vw, 300px);
  scroll-snap-align: start;
  padding: 10px 10px 28px; background: var(--sand); border-radius: 160px 160px 4px 4px; /* 아래 문턱은 두껍게 */
}
.door img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 150px 150px 2px 2px; }

/* ---------- 피아노 디테일 ---------- */
.details { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; margin-top: clamp(72px, 10vw, 128px); }
.details img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }

/* ---------- 오시는 길 ---------- */
.location { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(28px, 5vw, 72px); align-items: start; }
.info-list { list-style: none; margin: 28px 0 32px; border-top: 1px solid var(--sand); }
.info-list li { display: grid; grid-template-columns: 72px 1fr; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--sand); }
.info-label { font-size: 14px; font-weight: 700; color: var(--clay); }
.info-list a { text-decoration: none; font-weight: 600; }
.info-list a:hover { text-decoration: underline; }
.map { position: relative; z-index: 0; isolation: isolate; /* 지도 로고·축척이 고정 머리글 위로 올라오지 않게 */
  width: 100%; aspect-ratio: 4 / 3; border-radius: 4px; overflow: hidden; border: 1px solid var(--sand); }
.location-photo { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 4px; }
.map-label { padding: 6px 12px; font-size: 13px; font-weight: 700; color: #fff; white-space: nowrap; }

/* ---------- 공지 ---------- */
.notice-list { list-style: none; margin-top: 28px; border-top: 2px solid var(--ink); }
.notice-list button {
  display: flex; align-items: center; gap: 16px; width: 100%; padding: 18px 4px;
  background: none; border: none; border-bottom: 1px solid var(--sand); text-align: left; font: inherit; color: inherit; cursor: pointer;
}
.notice-list button:hover .notice-title { color: var(--ink); text-decoration: underline; }
.notice-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.notice-date { flex-shrink: 0; font-size: 14px; color: var(--text-sub); font-variant-numeric: tabular-nums; }
.notice-pin { flex-shrink: 0; padding: 1px 8px; border-radius: 4px; background: var(--ink); color: #fff; font-size: 12px; font-weight: 700; }

.notice-dialog { border: none; padding: 0; background: transparent; width: min(640px, calc(100% - 32px)); max-height: calc(100% - 64px); margin: auto; }
.notice-dialog::backdrop { background: rgba(31, 23, 21, 0.5); }
.notice-dialog-card { position: relative; padding: 36px 32px 32px; background: #fff; border-radius: 12px; max-height: calc(100vh - 64px); overflow-y: auto; }
.notice-dialog h3 { font-family: var(--font-display); font-size: 22px; letter-spacing: -0.02em; color: var(--ink); padding-right: 32px; }
.notice-dialog-date { font-size: 14px; color: var(--text-sub); margin-bottom: 6px; }
.notice-dialog-body { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--sand); white-space: pre-wrap; color: var(--text-sub); }
.dialog-close { position: absolute; top: 14px; right: 16px; width: 36px; height: 36px; border: none; background: none; font-size: 28px; line-height: 1; color: var(--text-sub); cursor: pointer; }

/* ---------- 바닥글 ---------- */
.site-footer { margin-top: clamp(96px, 12vw, 160px); padding: 48px var(--gutter) 56px; background: var(--ink); color: rgba(255, 255, 255, 0.72); font-size: 14px; }
.footer-name { font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.025em; color: #fff; margin-bottom: 14px; }
.site-footer a { color: #fff; white-space: nowrap; }

/* ---------- 모바일 ---------- */
@media (max-width: 860px) {
  .site-nav { display: none; }
  .site-header { justify-content: space-between; }
  .lobby, .location { grid-template-columns: 1fr; }
  .lesson { padding: 14px 0; }
  .details { grid-template-columns: repeat(2, 1fr); }
  .door { flex-basis: 68vw; }
  .notice-dialog-card { padding: 32px 20px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-img { animation: none; }
  .lobby-main img, .thumb, .thumb img { transition: none; }
}
