:root {
  --ink: #152033;
  --muted: #5d6878;
  --paper: #f8fbff;
  --surface: #ffffff;
  --line: #dbe6f2;
  --teal: #2563eb;
  --teal-dark: #1e3a8a;
  --mint: #e8f1ff;
  --coral: #c95d43;
  --gold: #d59f2f;
  --lime: #38bdf8;
  --shadow: 0 18px 48px rgba(21, 32, 51, 0.12);
  --radius: 8px;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family:
    "Pretendard",
    "Noto Sans KR",
    "Apple SD Gothic Neo",
    "Malgun Gothic",
    system-ui,
    sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  overflow-x: hidden;
}

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

a {
  color: inherit;
}

h1,
h2,
h3,
p,
li,
a,
button,
dd {
  overflow-wrap: break-word;
}

button,
input {
  font: inherit;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 1000;
  transform: translateY(-140%);
  padding: 10px 14px;
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.container {
  width: min(100% - 40px, var(--max));
  margin: 0 auto;
}

.site-header {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  transition:
    background 160ms ease,
    color 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease;
}

.site-header.is-scrolled,
.site-header.is-open {
  background: rgba(248, 251, 255, 0.96);
  color: var(--ink);
  border-color: var(--line);
  box-shadow: 0 8px 28px rgba(21, 32, 51, 0.09);
  backdrop-filter: blur(14px);
}

.nav-shell {
  width: min(100% - 32px, var(--max));
  min-height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  min-width: 0;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: var(--teal);
  color: #fff;
  font-weight: 900;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-links a {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 6px;
  color: inherit;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 700;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  background: rgba(37, 99, 235, 0.12);
  outline: none;
}

.menu-toggle {
  display: none;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid currentColor;
  border-radius: var(--radius);
  background: transparent;
  color: inherit;
  font-weight: 800;
}

.hero {
  position: relative;
  min-height: 82svh;
  display: grid;
  align-items: center;
  overflow: hidden;
  color: #fff;
}

.hero-media {
  position: absolute;
  inset: 0;
  background-image: url("assets/suneung-hero.png");
  background-size: cover;
  background-position: center;
  transform: scale(1.02);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8, 19, 46, 0.88) 0%, rgba(8, 19, 46, 0.68) 42%, rgba(8, 19, 46, 0.2) 100%),
    linear-gradient(180deg, rgba(8, 19, 46, 0.4) 0%, rgba(8, 19, 46, 0.16) 54%, rgba(248, 251, 255, 0.9) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 118px 0 64px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--coral);
  font-size: 0.82rem;
  font-weight: 900;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #f1b85d;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.2;
}

h1 {
  max-width: 760px;
  font-size: 3.7rem;
  font-weight: 900;
}

h1 span {
  display: inline;
}

h2 {
  font-size: 2.15rem;
  font-weight: 900;
}

h3 {
  font-size: 1.18rem;
  font-weight: 900;
}

.hero-copy {
  max-width: min(680px, 100%);
  margin: 22px 0 0;
  font-size: 1.12rem;
  color: rgba(255, 255, 255, 0.88);
  overflow-wrap: anywhere;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 32px 0 0;
}

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: var(--radius);
  font-weight: 900;
  text-decoration: none;
}

.button.primary {
  background: var(--teal);
  color: #fff;
}

.button.secondary {
  border: 1px solid rgba(255, 255, 255, 0.62);
  color: #fff;
}

.section .button.secondary,
.subpage .button.secondary {
  border-color: rgba(37, 99, 235, 0.35);
  color: var(--teal-dark);
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
  outline: none;
}

.hero-facts {
  max-width: 860px;
  margin: 44px 0 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.hero-facts div {
  min-height: 94px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.hero-facts dt {
  margin: 0 0 6px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.85rem;
  font-weight: 800;
}

.hero-facts dd {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 900;
}

.quick-band {
  margin-top: -38px;
  position: relative;
  z-index: 2;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.quick-item {
  min-height: 178px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.quick-label {
  display: block;
  margin-bottom: 10px;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.quick-item strong {
  display: block;
  font-size: 1.5rem;
  line-height: 1.24;
}

.quick-item p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.section {
  padding: 96px 0;
  scroll-margin-top: 82px;
}

.section.tinted {
  background: #eef5ff;
}

.subpage .site-header {
  position: sticky;
  background: rgba(248, 251, 255, 0.96);
  color: var(--ink);
  border-color: var(--line);
  box-shadow: 0 8px 28px rgba(21, 32, 51, 0.09);
}

.subpage-main {
  padding-top: 34px;
}

.page-hero {
  padding: 74px 0 52px;
  background: #e8f1ff;
}

.page-hero h1 {
  max-width: 920px;
}

.page-hero p {
  max-width: 780px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 800;
}

.breadcrumb a {
  color: var(--teal-dark);
  text-decoration: none;
}

.breadcrumb a:hover,
.breadcrumb a:focus-visible {
  text-decoration: underline;
  outline: none;
}

.section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.topic-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.topic-link {
  min-height: 150px;
  display: block;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
}

.topic-link strong {
  display: block;
  color: var(--teal-dark);
  font-size: 1.08rem;
}

.topic-link span {
  display: block;
  margin-top: 8px;
  color: var(--muted);
}

.topic-link:hover,
.topic-link:focus-visible {
  border-color: rgba(37, 99, 235, 0.36);
  box-shadow: var(--shadow);
  outline: none;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(260px, 0.82fr) minmax(0, 1.18fr);
  gap: 54px;
  align-items: start;
}

.section-intro p:not(.eyebrow),
.section-heading p {
  margin: 18px 0 0;
  color: var(--muted);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(260px, 0.75fr) minmax(0, 1fr);
  gap: 48px;
  align-items: end;
  margin-bottom: 34px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.info-card,
.panel,
.rule-card,
.strategy-item,
.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.info-card {
  min-height: 220px;
  padding: 24px;
}

.info-card p,
.panel p,
.rule-card p,
.strategy-item p {
  margin: 12px 0 0;
  color: var(--muted);
}

.timeline {
  position: relative;
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 24px;
  bottom: 24px;
  left: 91px;
  width: 2px;
  background: var(--line);
}

.timeline li {
  position: relative;
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 26px;
  align-items: start;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.timeline time {
  width: 132px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: var(--mint);
  color: var(--teal-dark);
  font-weight: 900;
  white-space: nowrap;
}

.timeline strong {
  display: block;
  font-size: 1.05rem;
}

.timeline p {
  margin: 6px 0 0;
  color: var(--muted);
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

caption {
  padding: 18px;
  text-align: left;
  font-weight: 900;
}

th,
td {
  padding: 15px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

thead th {
  background: #e8f1ff;
  color: var(--teal-dark);
  font-size: 0.9rem;
}

tbody tr:last-child th,
tbody tr:last-child td {
  border-bottom: 0;
}

tbody th {
  color: var(--teal-dark);
}

.tabs {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.tab-list {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
}

.tab-list button {
  min-height: 56px;
  padding: 10px 12px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-weight: 900;
  cursor: pointer;
}

.tab-list button:last-child {
  border-right: 0;
}

.tab-list button[aria-selected="true"] {
  background: var(--teal);
  color: #fff;
}

.tab-list button:focus-visible {
  outline: 3px solid rgba(201, 93, 67, 0.35);
  outline-offset: -3px;
}

.tab-panel {
  padding: 32px;
}

.subject-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.1fr);
  gap: 34px;
}

.subject-layout p {
  margin: 14px 0 0;
  color: var(--muted);
}

.detail-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.detail-list li {
  display: grid;
  grid-template-columns: 126px 1fr;
  gap: 12px;
  padding: 14px;
  border-radius: 6px;
  background: #f7fbff;
}

.detail-list strong {
  color: var(--teal-dark);
}

.split-panels,
.rule-grid,
.strategy-grid,
.score-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.rule-grid,
.strategy-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.score-grid {
  margin-bottom: 18px;
}

.panel,
.rule-card,
.strategy-item {
  padding: 24px;
}

.check-list,
.rule-card ul {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.check-list li,
.rule-card li {
  position: relative;
  padding-left: 20px;
  color: var(--muted);
}

.check-list li::before,
.rule-card li::before {
  content: "";
  position: absolute;
  top: 0.78em;
  left: 0;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--lime);
}

.rule-card.warning {
  border-color: rgba(201, 93, 67, 0.42);
  background: #fff7f3;
}

.rule-card.warning li::before {
  background: var(--coral);
}

.table-grid {
  display: grid;
  gap: 18px;
}

.small-table table {
  min-width: 860px;
}

.formula-note {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f7fbff;
}

.formula-note strong {
  color: var(--teal-dark);
  font-size: 1.06rem;
}

.formula-note p {
  margin: 0;
  color: var(--muted);
}

.formula-process {
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
  padding: 24px;
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: var(--radius);
  background: #ffffff;
}

.formula-process h3 {
  color: var(--teal-dark);
}

.formula-process p {
  margin: 0;
  color: var(--muted);
}

.formula-process ol {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 22px;
  color: var(--muted);
}

.formula-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.formula-card,
.formula-legend {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.formula-card {
  min-height: 330px;
  padding: 24px;
}

.formula-tag {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  margin-bottom: 12px;
  padding: 0 10px;
  border-radius: 6px;
  background: var(--mint);
  color: var(--teal-dark);
  font-size: 0.82rem;
  font-weight: 900;
}

.formula-box {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.formula-equation,
.formula-example {
  max-width: 100%;
  overflow-x: auto;
  border-radius: 6px;
}

.formula-equation {
  padding: 10px 12px;
  background: #f7fbff;
  border: 1px solid var(--line);
}

.formula-note .formula-equation {
  background: #fff;
}

.formula-example {
  padding: 12px;
  background: #fff7f3;
  border: 1px solid rgba(201, 93, 67, 0.25);
}

.formula-example strong {
  display: block;
  margin-bottom: 8px;
  color: var(--coral);
  font-size: 0.92rem;
}

.formula-example p {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.94rem;
}

.formula-equation mjx-container,
.formula-example mjx-container {
  margin: 0 !important;
  min-width: max-content;
}

.formula-card p {
  margin: 0;
  color: var(--muted);
}

.absolute-grade-panel {
  display: grid;
  gap: 14px;
  margin-top: 14px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.absolute-grade-panel p {
  margin: 0;
  color: var(--muted);
}

.formula-legend {
  margin-top: 14px;
  padding: 24px;
}

.formula-legend ul {
  display: grid;
  gap: 8px;
  margin: 14px 0 0;
  padding-left: 20px;
  color: var(--muted);
}

.seo-summary {
  display: grid;
  grid-template-columns: minmax(260px, 0.95fr) minmax(0, 1.35fr);
  gap: 14px;
  margin-bottom: 18px;
}

.seo-summary .panel {
  display: grid;
  gap: 10px;
}

.seo-summary .panel p {
  margin: 0;
}

.distribution-tool {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
}

.distribution-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 22px;
  border-bottom: 1px solid var(--line);
  background: #f7fbff;
}

.distribution-controls label {
  display: grid;
  gap: 8px;
  color: var(--teal-dark);
  font-weight: 900;
}

.distribution-controls select {
  min-height: 48px;
  width: 100%;
  padding: 0 42px 0 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  font-weight: 800;
}

.distribution-controls select:focus {
  outline: 3px solid rgba(37, 99, 235, 0.18);
  border-color: var(--teal);
}

.distribution-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 22px;
  border-bottom: 1px solid var(--line);
}

.distribution-stat {
  min-height: 94px;
  padding: 16px;
  border-radius: 6px;
  background: #f8fbff;
}

.distribution-stat span {
  display: block;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 800;
}

.distribution-stat strong {
  display: block;
  margin-top: 4px;
  font-size: 1.22rem;
  line-height: 1.25;
}

.distribution-stat a {
  color: var(--teal-dark);
}

.distribution-chart-panel {
  padding: 22px;
  border-bottom: 1px solid var(--line);
}

.distribution-chart-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.distribution-chart-heading p {
  margin: 8px 0 0;
  color: var(--muted);
}

.distribution-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 900;
}

.distribution-legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.distribution-legend i {
  display: inline-block;
}

.legend-bar {
  width: 16px;
  height: 10px;
  border-radius: 3px;
  background: var(--teal);
}

.legend-line {
  width: 20px;
  height: 3px;
  border-radius: 999px;
  background: var(--coral);
}

.distribution-chart {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f8fbff;
}

.distribution-chart svg {
  width: 100%;
  min-width: 820px;
  height: auto;
  display: block;
}

.chart-grid {
  stroke: #dbe6f2;
  stroke-width: 1;
}

.chart-axis {
  stroke: #94a3b8;
  stroke-width: 1.2;
}

.chart-bar {
  fill: rgba(37, 99, 235, 0.72);
}

.chart-bar:hover {
  fill: var(--teal-dark);
}

.chart-line {
  fill: none;
  stroke: var(--coral);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chart-label {
  fill: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.chart-axis-title {
  fill: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.distribution-table-toggle {
  padding: 18px 22px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #f7fbff;
}

.distribution-table-toggle button {
  min-height: 46px;
  width: 100%;
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: 6px;
  background: #fff;
  color: var(--teal-dark);
  font-weight: 900;
  cursor: pointer;
}

.distribution-table-toggle button::after {
  content: "▼";
  display: inline-block;
  margin-left: 10px;
  font-size: 0.78rem;
  transition: transform 160ms ease;
}

.distribution-table-toggle button[aria-expanded="true"]::after {
  transform: rotate(180deg);
}

.distribution-table-toggle button:focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.2);
  outline-offset: 2px;
}

.distribution-table-wrap {
  border: 0;
  border-radius: 0;
}

.distribution-table {
  min-width: 720px;
}

.distribution-table th,
.distribution-table td {
  text-align: right;
}

.distribution-table th:first-child,
.distribution-table td:first-child {
  text-align: left;
}

.trend-tool {
  display: grid;
  gap: 18px;
  margin-top: 22px;
}

.trend-panel {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.trend-panel .distribution-chart-heading {
  margin: 0;
  padding: 22px;
  border-bottom: 1px solid var(--line);
}

.trend-panel .distribution-controls {
  border-bottom: 1px solid var(--line);
}

.trend-chart {
  border: 0;
  border-radius: 0;
}

.trend-bar {
  fill: rgba(56, 189, 248, 0.76);
}

.trend-line {
  fill: none;
  stroke: var(--coral);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.trend-dot {
  fill: var(--surface);
  stroke: var(--coral);
  stroke-width: 3;
}

.trend-value {
  fill: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.trend-empty {
  margin: 0;
  padding: 24px;
  color: var(--muted);
  font-weight: 800;
}

.trend-table-wrap {
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
}

.trend-table {
  min-width: 980px;
}

.trend-table th,
.trend-table td {
  text-align: right;
  white-space: nowrap;
}

.trend-table th:first-child,
.trend-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  text-align: left;
  background: #f8fbff;
}

.trend-table thead th:first-child {
  z-index: 2;
  background: #e8f1ff;
}

.sitemap-page {
  min-height: calc(100svh - 96px);
}

.sitemap-page h1 {
  max-width: 820px;
  margin: 0;
}

.sitemap-lead {
  max-width: 860px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.sitemap-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 34px;
}

.sitemap-card {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.sitemap-card h2 {
  margin-bottom: 16px;
  font-size: 1.28rem;
}

.sitemap-card ul {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.sitemap-card li {
  display: grid;
  gap: 4px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.sitemap-card li:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.sitemap-card a {
  color: var(--teal-dark);
  font-weight: 900;
  text-decoration: none;
}

.sitemap-card a:hover,
.sitemap-card a:focus-visible {
  text-decoration: underline;
  outline: none;
}

.sitemap-card span {
  color: var(--muted);
  font-size: 0.94rem;
}

.sitemap-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.sitemap-actions .button.secondary {
  border-color: rgba(37, 99, 235, 0.35);
  color: var(--teal-dark);
}

.omr-guide {
  display: grid;
  gap: 18px;
}

.omr-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 24px;
  align-items: center;
  padding: 28px;
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: var(--radius);
  background: var(--surface);
}

.omr-hero h3 {
  max-width: 760px;
  font-size: 1.72rem;
}

.omr-hero p {
  max-width: 840px;
  margin: 12px 0 0;
  color: var(--muted);
}

.omr-actions {
  display: grid;
  gap: 10px;
}

.omr-actions .button {
  width: 100%;
  justify-content: center;
}

.omr-actions .button.secondary {
  border-color: rgba(37, 99, 235, 0.35);
  background: #fff;
  color: var(--teal-dark);
}

.omr-actions .button.secondary:hover,
.omr-actions .button.secondary:focus-visible {
  background: #f7fbff;
}

.omr-grid,
.omr-feature-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.omr-feature-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.omr-card {
  min-height: 230px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.omr-badge {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  border-radius: 7px;
  background: var(--teal);
  color: #fff;
  font-weight: 900;
}

.omr-card p,
.omr-feature-grid p {
  margin: 12px 0 0;
  color: var(--muted);
}

.omr-note {
  padding: 24px;
  border: 1px solid rgba(201, 93, 67, 0.28);
  border-radius: var(--radius);
  background: #fff7f3;
}

.omr-note strong {
  color: var(--coral);
  font-size: 1.05rem;
}

.omr-note ul {
  display: grid;
  gap: 8px;
  margin: 14px 0 0;
  padding-left: 20px;
  color: var(--muted);
}

.strategy-item span {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  border-radius: 7px;
  background: var(--gold);
  color: #1f1a10;
  font-weight: 900;
}

.search-box {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
  font-weight: 900;
}

.search-box input {
  width: 100%;
  min-height: 58px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
}

.search-box input:focus {
  outline: 3px solid rgba(37, 99, 235, 0.18);
  border-color: var(--teal);
}

.search-results {
  min-height: 28px;
  color: var(--muted);
}

.search-result-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.search-result-list a {
  min-height: 104px;
  display: block;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-decoration: none;
}

.search-result-list strong {
  display: block;
  margin-bottom: 6px;
}

.search-result-list span {
  color: var(--muted);
  font-size: 0.93rem;
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-item {
  overflow: hidden;
}

.faq-item button {
  width: 100%;
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 20px;
  border: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
  font-weight: 900;
  cursor: pointer;
}

.faq-item button span {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--mint);
  color: var(--teal-dark);
  font-weight: 900;
}

.faq-answer {
  padding: 0 20px 20px;
  color: var(--muted);
}

.faq-answer p {
  margin: 0;
}

.sources {
  padding-top: 76px;
}

.source-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.source-list li {
  display: grid;
  grid-template-columns: minmax(220px, 0.38fr) minmax(0, 1fr);
  gap: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.source-list a,
.source-list strong {
  color: var(--teal-dark);
  font-weight: 900;
}

.source-list span {
  color: var(--muted);
}

.site-footer {
  padding: 30px 0;
  background: var(--ink);
  color: rgba(255, 255, 255, 0.78);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.footer-inner p {
  margin: 0;
}

.footer-links {
  display: inline-flex;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-links a {
  color: #fff;
  font-weight: 800;
  text-decoration: none;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  text-decoration: underline;
  outline: none;
}

.top-button {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 40;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: var(--radius);
  background: var(--teal);
  color: #fff;
  font-size: 1.3rem;
  font-weight: 900;
  box-shadow: var(--shadow);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.top-button.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

@media (max-width: 1060px) {
  .quick-grid,
  .rule-grid,
  .strategy-grid,
  .omr-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tab-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .tab-list button:nth-child(3) {
    border-right: 0;
  }

  .tab-list button:nth-child(-n + 3) {
    border-bottom: 1px solid var(--line);
  }

  .split-panels,
  .score-grid,
  .formula-grid,
  .sitemap-grid,
  .topic-links,
  .omr-feature-grid,
  .seo-summary,
  .distribution-summary,
  .search-result-list {
    grid-template-columns: 1fr;
  }

  .distribution-chart-heading {
    display: grid;
  }

  .trend-table th:first-child,
  .trend-table td:first-child {
    position: static;
  }
}

@media (max-width: 820px) {
  .container {
    width: min(100% - 28px, var(--max));
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
  }

  .nav-shell {
    min-height: 62px;
    flex-wrap: wrap;
  }

  .nav-links {
    width: 100%;
    display: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 0 0 14px;
  }

  .nav-links.is-open {
    display: grid;
  }

  .nav-links a {
  background: rgba(37, 99, 235, 0.1);
  }

  .hero {
    min-height: 86svh;
  }

  .hero-media {
    background-position: 58% center;
  }

  .hero-overlay {
    background:
      linear-gradient(90deg, rgba(8, 19, 46, 0.9) 0%, rgba(8, 19, 46, 0.72) 100%),
      linear-gradient(180deg, rgba(8, 19, 46, 0.3) 0%, rgba(248, 251, 255, 0.88) 100%);
  }

  .hero-content {
    padding-top: 104px;
  }

  h1 {
    font-size: 2.65rem;
  }

  h2 {
    font-size: 1.85rem;
  }

  .hero-facts,
  .quick-grid,
  .two-column,
  .section-heading,
  .info-grid,
  .subject-layout,
  .omr-hero,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    display: grid;
  }

  .section {
    padding: 72px 0;
  }

  .quick-band {
    margin-top: -22px;
  }

  .timeline::before {
    display: none;
  }

  .timeline li {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .timeline time {
    width: fit-content;
    padding: 0 14px;
  }

  .source-list li {
    grid-template-columns: 1fr;
  }

}

@media (max-width: 560px) {
  .hero {
    min-height: 88svh;
  }

  .hero-actions {
    display: grid;
  }

  h1 {
    font-size: 2rem;
  }

  h1 span {
    display: block;
  }

  .hero-copy {
    font-size: 1rem;
  }

  .quick-item,
  .info-card,
  .panel,
  .rule-card,
  .strategy-item,
  .tab-panel {
    padding: 20px;
  }

  .tab-list {
    grid-template-columns: 1fr 1fr;
  }

  .distribution-controls {
    grid-template-columns: 1fr;
  }

  .tab-list button {
    border-bottom: 1px solid var(--line);
  }

  .tab-list button:nth-child(2n) {
    border-right: 0;
  }

  .detail-list li {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .rule-grid,
  .strategy-grid,
  .omr-grid {
    grid-template-columns: 1fr;
  }
}
