/* 교습소철거허가 — 표 중심, Q&A 스타일 */

:root {
  --primary: #023047;
  --primary-dark: #011c2b;
  --accent: #8ECAE6;
  --accent-soft: #E4F3FA;
  --ink: #10242F;
  --paper: #F5FAFC;
  --card-bg: #FFFFFF;
  --line: #C7E5F1;
  --header-h: 60px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "IBM Plex Sans KR", -apple-system, "Malgun Gothic", sans-serif;
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.7;
  padding-top: var(--header-h);
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: "IBM Plex Sans KR", sans-serif;
  font-weight: 700;
  color: var(--primary);
  line-height: 1.4;
}

img { max-width: 100%; display: block; }

a { color: var(--primary); }
a:hover { color: var(--primary-dark); }

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ===== Header ===== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  background: rgba(245, 250, 252, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  z-index: 200;
}

.brand {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--primary);
  text-decoration: none;
}

.nav-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 44px;
  min-height: 44px;
  padding: 8px 12px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 0.9rem;
  cursor: pointer;
}
.nav-toggle svg { stroke: #fff; }

/* ===== Slide nav ===== */
.site-nav {
  position: fixed;
  top: 0; right: 0;
  height: 100%;
  width: min(300px, 84vw);
  background: var(--card-bg);
  border-left: 1px solid var(--line);
  z-index: 300;
  transform: translateX(100%);
  transition: transform 0.25s ease;
  padding: 20px;
  overflow-y: auto;
}
.site-nav.open { transform: translateX(0); }

.nav-close {
  min-width: 44px;
  min-height: 44px;
  background: var(--accent-soft);
  border: none;
  border-radius: 4px;
  color: var(--primary);
  cursor: pointer;
  margin-bottom: 16px;
}

.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav li { border-bottom: 1px solid var(--accent-soft); }
.site-nav a {
  min-height: 44px;
  display: flex;
  align-items: center;
  padding: 10px 4px;
  text-decoration: none;
  color: var(--ink);
  font-size: 0.98rem;
}
.site-nav a[aria-current="page"] { color: var(--primary); font-weight: 700; }

/* ===== Layout ===== */
.page {
  max-width: 760px;
  margin: 0 auto;
  padding: 20px 16px 48px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* ===== Hero ===== */
.hero {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
}
.hero-media picture, .hero-media img { width: 100%; height: auto; }
.hero-text { padding: 20px; }

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--primary);
  background: var(--accent-soft);
  padding: 5px 12px;
  border-radius: 3px;
  margin: 0 0 12px;
  border: 1px solid var(--accent);
}

h1 {
  font-size: 1.7rem;
  margin: 0 0 12px;
}

h2 {
  font-size: 1.25rem;
  margin: 0 0 14px;
  padding-left: 12px;
  border-left: 5px solid var(--accent);
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 22px 20px;
}

.card p { margin: 0 0 12px; }
.card p:last-child { margin-bottom: 0; }

/* ===== Table (centerpiece) ===== */
.table-note {
  font-size: 0.88rem;
  color: #3B5A6A;
}
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 4px; }
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  min-width: 560px;
}
th, td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
thead th {
  background: var(--primary);
  color: #fff;
  font-weight: 700;
}
tbody tr:last-child td { border-bottom: none; }
tbody tr:nth-child(even) { background: var(--accent-soft); }

.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}
.badge.low { background: var(--accent-soft); color: var(--primary); border: 1px solid var(--accent); }
.badge.high { background: #FDEAEA; color: #A1281F; border: 1px solid #F0B4AE; }
.badge.check { background: #FFF6DE; color: #8A6300; border: 1px solid #F0D98C; }

/* ===== Q&A ===== */
.qna-item {
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 4px;
  margin-bottom: 12px;
  background: var(--accent-soft);
}
.qna-item:last-child { margin-bottom: 0; }
.qna-item h3 {
  font-size: 1.02rem;
  margin: 0 0 8px;
  color: var(--primary);
}
.qna-item p { margin: 0; font-size: 0.96rem; }

/* ===== Gallery ===== */
.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.gallery-grid figure { margin: 0; }
.gallery-grid img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid var(--line);
}

/* ===== CTA ===== */
.cta-card {
  background: var(--primary);
  border-color: var(--primary);
}
.cta-card h2 { color: #fff; border-left-color: var(--accent); }
.cta-card p { color: #E4F3FA; }

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 26px;
  background: var(--accent);
  color: var(--primary-dark);
  border-radius: 4px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
}
.cta-btn:hover { background: #A9DBEE; color: var(--primary-dark); }

/* ===== Footer ===== */
footer {
  background: var(--primary-dark);
  color: #CFE7F1;
  padding: 32px 16px 24px;
}
footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  max-width: 760px;
  margin: 0 auto 20px;
}
footer nav a {
  color: #CFE7F1;
  text-decoration: none;
  font-size: 0.9rem;
  min-height: 44px;
  display: flex;
  align-items: center;
}
footer nav a:hover { text-decoration: underline; }
footer address {
  max-width: 760px;
  margin: 0 auto;
  font-style: normal;
  font-size: 0.88rem;
  line-height: 1.8;
  color: #A9CBDA;
  border-top: 1px solid rgba(142, 202, 230, 0.3);
  padding-top: 16px;
}
footer address a { color: #8ECAE6; font-weight: 700; }
footer p {
  max-width: 760px;
  margin: 16px auto 0;
  font-size: 0.8rem;
  color: #7FA5B6;
}

/* ===== Breakpoints ===== */
@media (min-width: 480px) {
  h1 { font-size: 1.9rem; }
}

@media (min-width: 768px) {
  .page { max-width: 820px; padding: 32px 24px 56px; }
  .hero { display: flex; align-items: stretch; }
  .hero-media { width: 45%; }
  .hero-media picture, .hero-media img { height: 100%; object-fit: cover; }
  .hero-text { width: 55%; padding: 32px; display: flex; flex-direction: column; justify-content: center; }
  .card { padding: 28px 32px; }
  h1 { font-size: 2.15rem; }
  h2 { font-size: 1.4rem; }
}

@media (min-width: 1024px) {
  .page { max-width: 900px; }
}

@media (min-width: 1280px) {
  .page { max-width: 980px; }
}

@media (max-width: 479px) {
  .gallery-grid { grid-template-columns: 1fr; }
}
