:root {
  color-scheme: light;
  --bg: #f1f4f9;
  --bg-elevated: #ffffff;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --text: #0f172a;
  --text-body: #334155;
  --muted: #64748b;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --blue-50: #eff6ff;
  --blue-100: #dbeafe;
  --blue-500: #3b82f6;
  --blue-600: #2563eb;
  --blue-700: #1d4ed8;
  --blue-800: #1e40af;
  --accent: #1e40af;
  --input-bg: #ffffff;
  --topbar-bg: rgba(255, 255, 255, 0.82);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius: 12px;
  --radius-xl: 20px;
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.07), 0 2px 4px -2px rgba(15, 23, 42, 0.05);
  --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.05);
  --shadow: var(--shadow-md);
  --ring-focus: 0 0 0 3px rgba(37, 99, 235, 0.22);
  --transition-fast: 0.15s ease;
  --transition-base: 0.2s ease;
  font-family:
    "Noto Sans KR",
    system-ui,
    -apple-system,
    "Segoe UI",
    sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #09090b;
  --bg-elevated: #0c0c0f;
  --surface: #141416;
  --surface-2: #1c1c21;
  --text: #fafafa;
  --text-body: #d4d4d8;
  --muted: #a1a1aa;
  --border: #2a2a2e;
  --border-strong: #3f3f46;
  --blue-50: rgba(59, 130, 246, 0.14);
  --blue-100: rgba(59, 130, 246, 0.22);
  --blue-500: #60a5fa;
  --blue-600: #3b82f6;
  --blue-700: #93c5fd;
  --blue-800: #bfdbfe;
  --accent: #93c5fd;
  --input-bg: #1a1a1d;
  --topbar-bg: rgba(12, 12, 15, 0.88);
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.35);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.5);
  --shadow: var(--shadow-md);
  --ring-focus: 0 0 0 3px rgba(96, 165, 250, 0.28);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
}

a {
  color: var(--blue-700);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover {
  color: var(--blue-600);
  text-decoration: underline;
}

.layout {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem 4rem;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--topbar-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
}

.topbar-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.7rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 0.85rem 1.25rem;
  flex-wrap: wrap;
}

.theme-toggle {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.42rem 0.8rem;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  cursor: pointer;
  transition:
    border-color var(--transition-fast),
    background var(--transition-fast),
    color var(--transition-fast);
}

.theme-toggle:hover {
  border-color: var(--blue-500);
  background: var(--blue-50);
  color: var(--blue-800);
}

html[data-theme="dark"] .theme-toggle {
  background: var(--surface-2);
}

html[data-theme="dark"] .theme-toggle:hover {
  border-color: var(--blue-500);
  background: rgba(59, 130, 246, 0.12);
  color: var(--accent);
}

.brand {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.brand:hover {
  text-decoration: none;
}

.brand-text {
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.04em;
  line-height: 1;
  background: linear-gradient(122deg, #1e40af 0%, #4338ca 48%, #7c3aed 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

html[data-theme="dark"] .brand-text {
  background: linear-gradient(122deg, #93c5fd 0%, #c4b5fd 55%, #f0abfc 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav-links {
  display: flex;
  gap: 0.2rem;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
}

.nav-links a {
  font-size: 0.8125rem;
  color: var(--muted);
  font-weight: 600;
  padding: 0.4rem 0.65rem;
  border-radius: var(--radius-sm);
  transition:
    background var(--transition-fast),
    color var(--transition-fast);
}

.nav-links a:hover {
  color: var(--blue-800);
  background: var(--blue-50);
  text-decoration: none;
}

html[data-theme="dark"] .nav-links a:hover {
  color: var(--text);
  background: rgba(59, 130, 246, 0.12);
}

section {
  scroll-margin-top: 5rem;
  padding-top: 2.75rem;
}

.section-title {
  font-size: 1.25rem;
  font-weight: 800;
  margin: 0 0 1rem;
  letter-spacing: -0.03em;
  color: var(--text);
}

.hero {
  padding-top: 2rem;
}

.hero-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--blue-700);
  background: var(--blue-50);
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  padding: 0.25rem 0.65rem;
  margin-bottom: 0.75rem;
}

.hero h1 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin: 0 0 0.5rem;
  line-height: 1.35;
}

.hero-lead {
  font-size: 1rem;
  color: var(--muted);
  margin: 0 0 1.25rem;
  max-width: 42rem;
}

.pitch-card {
  background: linear-gradient(135deg, #1e40af 0%, #2563eb 55%, #3b82f6 100%);
  color: #fff;
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  box-shadow: var(--shadow);
}

.pitch-card p {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 500;
}

.card-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 720px) {
  .card-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.2rem 1.35rem;
  box-shadow: var(--shadow-sm);
}

.card h3 {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  color: var(--blue-700);
}

.card .phase {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-body);
}

.bullets {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-body);
}

.bullets li {
  margin-bottom: 0.35rem;
}

.muted {
  color: var(--muted);
  font-size: 0.9rem;
}

.data-box {
  background: var(--blue-50);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.data-box dl {
  margin: 0;
  display: grid;
  gap: 0.5rem;
}

.data-box dt {
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--muted);
}

.data-box dd {
  margin: 0;
  font-size: 0.93rem;
}

.demo-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  margin-top: 1rem;
}

.demo-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-bottom: 0.75rem;
}

.demo-toolbar label {
  font-size: 0.85rem;
  color: var(--muted);
}

.demo-toolbar input[type="text"],
.demo-toolbar input[type="search"] {
  flex: 1;
  min-width: 140px;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  background: var(--input-bg);
  color: var(--text);
}

.primary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  background: linear-gradient(180deg, #3b82f6 0%, var(--blue-600) 100%);
  color: #fff;
  border: none;
  border-radius: var(--radius-md);
  padding: 0.5rem 1.15rem;
  min-height: 2.5rem;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  font-family: inherit;
  box-shadow: 0 1px 2px rgba(37, 99, 235, 0.35);
  transition:
    filter var(--transition-fast),
    box-shadow var(--transition-fast),
    transform var(--transition-fast);
}

.primary-btn:hover {
  filter: brightness(1.06);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.35);
}

.primary-btn:active {
  transform: translateY(1px);
}

.primary-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

th,
td {
  text-align: left;
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid var(--border);
}

th {
  background: var(--blue-50);
  font-weight: 600;
  color: var(--muted);
}

.ppt-list {
  margin: 0;
  padding-left: 1.2rem;
}

.ppt-list li {
  margin-bottom: 0.35rem;
}

.highlight {
  background: #fef9c3;
  border-left: 4px solid #eab308;
  padding: 0.75rem 1rem;
  margin: 1rem 0;
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 0.95rem;
}

footer.site-footer {
  margin-top: 3rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border);
  font-size: 0.8rem;
  color: var(--muted);
}

.status-pill {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
}

.error-msg {
  color: #b91c1c;
  font-size: 0.88rem;
  margin-top: 0.5rem;
}

.intro-line {
  color: var(--muted);
  margin: 0 0 2rem;
  max-width: 40rem;
  font-size: 0.96rem;
}

.demo-lead {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
}

.compact-block {
  margin: 0;
  max-width: 44rem;
  line-height: 1.55;
  font-size: 0.95rem;
  color: var(--text-body);
}

.footnote {
  margin: 0.75rem 0 0;
  font-size: 0.85rem;
}

.panel-tight {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
}

.schedule-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.65rem;
}

.link-btn {
  background: none;
  border: none;
  padding: 0;
  color: var(--blue-700);
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  text-decoration: underline;
}

.link-btn:hover {
  color: var(--accent);
}

.card-compact h3 {
  font-size: 0.92rem;
}

.card-compact p {
  font-size: 0.875rem;
}

.empty-hint {
  margin: 0.75rem 0 0;
  font-size: 0.88rem;
}

#demo {
  padding-top: 2rem;
}

.env-banner {
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  font-size: 0.88rem;
}

.env-banner-ok {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

.env-banner-warn {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}

.env-banner-meta,
.env-banner-hint {
  margin: 0.4rem 0 0;
  font-size: 0.86rem;
}

.env-checklist {
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
}

.env-checklist li[data-ok="true"]::marker {
  color: #059669;
}

.env-checklist li[data-ok="false"]::marker {
  color: #b91c1c;
}

.env-details {
  margin-top: 0.5rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.env-paths {
  margin: 0.35rem 0 0;
  padding: 0.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow-x: auto;
  font-size: 0.75rem;
  white-space: pre-wrap;
}

.mock-data-strip {
  margin: 0 0 0.75rem;
  padding: 0.5rem 0.65rem;
  background: #fef3c7;
  border: 1px solid #fcd34d;
  border-radius: 8px;
  font-size: 0.84rem;
  font-weight: 600;
  color: #92400e;
}

.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.45rem 1rem;
  min-height: 2.5rem;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  font-family: inherit;
  transition:
    background var(--transition-fast),
    border-color var(--transition-fast),
    color var(--transition-fast);
}

.secondary-btn:hover:not(:disabled) {
  background: var(--blue-50);
  border-color: var(--blue-500);
  color: var(--blue-800);
}

.secondary-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.schedule-pager-wrap {
  margin-bottom: 0.75rem;
}

.schedule-range {
  margin: 0 0 0.5rem;
  font-size: 0.86rem;
}

.schedule-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
}

.pager-info {
  font-size: 0.86rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

html[data-theme="dark"] .env-banner-ok {
  background: #064e3b;
  border-color: #059669;
  color: #a7f3d0;
}

html[data-theme="dark"] .env-banner-warn {
  background: #422006;
  border-color: #b45309;
  color: #fde68a;
}

html[data-theme="dark"] .mock-data-strip {
  background: #422006;
  border-color: #b45309;
  color: #fde68a;
}

html[data-theme="dark"] pre.env-paths {
  background: #0c0c0e;
}

html[data-theme="dark"] .secondary-btn:hover:not(:disabled) {
  background: rgba(59, 130, 246, 0.12);
}

html[data-theme="dark"] .schedule-range strong {
  color: var(--text);
}

.school-pick-hint {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
}

.school-table tbody tr.school-row {
  cursor: pointer;
}

.school-table tbody tr.school-row:hover {
  background: var(--blue-50);
}

html[data-theme="dark"] .school-table tbody tr.school-row:hover {
  background: rgba(59, 130, 246, 0.12);
}

.school-table tbody tr.school-row-selected {
  outline: 2px solid var(--blue-600);
  outline-offset: -2px;
  background: rgba(37, 99, 235, 0.06);
}

html[data-theme="dark"] .school-table tbody tr.school-row-selected {
  background: rgba(59, 130, 246, 0.14);
}

.school-pick-col,
.school-pick-cell {
  width: 3rem;
  text-align: center;
  font-size: 0.9rem;
}

.school-pick-dot {
  font-size: 1rem;
  line-height: 1;
}

.school-code {
  font-size: 0.82rem;
  padding: 0.1rem 0.35rem;
  background: var(--blue-50);
  border-radius: 4px;
  color: var(--blue-700);
}

html[data-theme="dark"] .school-code {
  background: rgba(59, 130, 246, 0.18);
  color: var(--accent);
}

.schedule-bar-meta em {
  font-style: normal;
  color: var(--muted);
}

/* 폼 컨트롤 포커스 */
.auth-form input:not([type="checkbox"]):not([type="radio"]),
.auth-form textarea,
.auth-form select,
.demo-toolbar input[type="text"],
.demo-toolbar input[type="search"] {
  transition:
    border-color var(--transition-fast),
    box-shadow var(--transition-fast);
}

.auth-form input:not([type="checkbox"]):not([type="radio"]):focus-visible,
.auth-form textarea:focus-visible,
.auth-form select:focus-visible,
.demo-toolbar input[type="text"]:focus-visible,
.demo-toolbar input[type="search"]:focus-visible {
  outline: none;
  border-color: var(--blue-500);
  box-shadow: var(--ring-focus);
}
