/* ==========================================================================
   総合型選抜ラボ LP
   ========================================================================== */

:root {
  --paper: #f6f3ec;
  --paper-deep: #eee9dd;
  --white: #fffdf8;
  --navy: #1b2a3a;
  --navy-soft: #2c3e52;
  --ink: #23262b;
  --ink-sub: #5a5f66;
  --line: #d9d2c3;
  --shu: #bf4630;
  --shu-soft: rgba(191, 70, 48, 0.12);
  --gold: #e2c766;

  --serif: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --sans: "Noto Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;

  --gutter: 16px;
  --radius: 4px;
  --header-h: 56px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 8px);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: 0.02em;
  overflow-wrap: anywhere;
  word-break: normal;
  line-break: strict;
}

img { max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-family: var(--serif); font-weight: 700; line-height: 1.5; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* Utilities ------------------------------------------------------------- */
.container { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 var(--gutter); }
.container--narrow { max-width: 720px; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--navy); color: #fff; padding: 8px 16px; }
.skip-link:focus { left: 8px; top: 8px; }
.pc-only { display: none; }
@media (min-width: 768px) {
  .pc-only { display: inline; }
  .sp-only { display: none; }
}
.note { margin-top: 20px; font-size: 13px; color: var(--ink-sub); line-height: 1.8; }

/* Buttons --------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 12px 28px;
  border: 1px solid transparent; border-radius: var(--radius);
  font-family: var(--sans); font-size: 15px; font-weight: 700; letter-spacing: 0.08em;
  text-decoration: none; cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s;
}
.btn--primary { background: var(--shu); color: #fff; }
.btn--primary:hover { background: #a63a27; }
.btn--light { background: var(--paper); color: var(--navy); }
.btn--light:hover { background: #fff; }
.btn--sm { min-height: 38px; padding: 6px 16px; font-size: 13px; }
.btn--lg { min-height: 56px; padding: 14px 40px; font-size: 16px; }
.btn--block { display: flex; width: 100%; }
.btn:focus-visible, a:focus-visible, summary:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--gold); outline-offset: 2px;
}

/* Header ---------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(246, 243, 236, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(6px);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand { display: flex; flex-direction: column; text-decoration: none; line-height: 1.2; }
.brand__ja { font-family: var(--serif); font-weight: 700; font-size: 17px; color: var(--navy); letter-spacing: 0.08em; }
.brand__en { font-size: 9px; letter-spacing: 0.2em; color: var(--ink-sub); margin-top: 3px; }

/* Hero ------------------------------------------------------------------ */
.hero {
  position: relative; overflow: hidden;
  padding: 64px 0 72px;
  background:
    linear-gradient(var(--paper), rgba(246,243,236,0.85)),
    repeating-linear-gradient(0deg, transparent 0 31px, rgba(27,42,58,0.06) 31px 32px);
}
.hero__eyebrow { font-size: 13px; color: var(--ink-sub); letter-spacing: 0.08em; }
.hero__title {
  margin-top: 20px;
  font-size: clamp(34px, 9vw, 64px); line-height: 1.45; color: var(--navy); letter-spacing: 0.06em;
}
.shu { font-style: normal; color: var(--shu); background: linear-gradient(transparent 72%, var(--shu-soft) 72%); }
.hero__lead { margin-top: 28px; max-width: 40em; font-size: 15px; line-height: 2.1; }
.hero__cta { margin-top: 36px; }
.hero__note { margin-top: 12px; font-size: 13px; color: var(--ink-sub); }
@media (min-width: 768px) {
  .hero { padding: 120px 0 128px; }
  .hero__lead { font-size: 16px; }
}

/* Section --------------------------------------------------------------- */
.section { padding: 72px 0; }
.section--paper { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section--navy { background: var(--navy); color: #e8e6e0; }
.section--navy .section__title { color: #fff; }
.section--navy .section__label { color: var(--gold); }
.section__label { font-size: 12px; font-weight: 700; letter-spacing: 0.24em; color: var(--shu); }
.section__title { margin-top: 10px; font-size: clamp(22px, 5.6vw, 32px); color: var(--navy); letter-spacing: 0.04em; }
.section__lead { margin-top: 24px; max-width: 44em; }
@media (min-width: 768px) {
  .section { padding: 112px 0; }
}

/* Worries --------------------------------------------------------------- */
.worries { margin-top: 32px; display: grid; gap: 10px; }
.worries li {
  position: relative; padding: 14px 16px 14px 44px;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  line-height: 1.7;
}
.worries li::before {
  content: ""; position: absolute; left: 16px; top: 50%; width: 14px; height: 14px; margin-top: -7px;
  border: 1.5px solid var(--navy); border-radius: 2px;
}
.worries__after { margin-top: 32px; font-family: var(--serif); font-size: 17px; line-height: 2; }
.worries__after strong { color: var(--navy); background: linear-gradient(transparent 70%, rgba(226,199,102,0.45) 70%); }
@media (min-width: 768px) {
  .worries { grid-template-columns: 1fr 1fr; }
}

/* Concept / flow -------------------------------------------------------- */
.flow { margin-top: 40px; display: grid; gap: 0; counter-reset: flow; }
.flow__item {
  position: relative; display: grid; grid-template-columns: 44px 1fr; grid-template-rows: auto auto; column-gap: 12px;
  padding: 14px 0 26px;
}
.flow__item:not(:last-child)::after {
  content: ""; position: absolute; left: 21px; top: 50px; bottom: 0; width: 1px; background: var(--line);
}
.flow__num {
  grid-row: 1 / 3; width: 44px; height: 44px; display: grid; place-items: center;
  border: 1px solid var(--navy); border-radius: 50%; font-size: 12px; font-weight: 700; color: var(--navy); background: var(--white);
}
.flow__name { font-family: var(--serif); font-weight: 700; font-size: 19px; color: var(--navy); line-height: 1.4; padding-top: 2px; }
.flow__desc { font-size: 13px; color: var(--ink-sub); line-height: 1.6; }
.flow__item--key .flow__num { background: var(--shu); border-color: var(--shu); color: #fff; }
.flow__item--key .flow__name { color: var(--shu); }
.concept__goal { margin-top: 24px; padding: 24px; border-left: 3px solid var(--shu); background: var(--paper); font-family: var(--serif); line-height: 2; }
.concept__goal strong { color: var(--navy); }
@media (min-width: 900px) {
  .flow { grid-template-columns: repeat(6, 1fr); }
  .flow__item { grid-template-columns: 1fr; grid-template-rows: auto; justify-items: center; text-align: center; padding: 0 4px; row-gap: 8px; }
  .flow__num { grid-row: auto; }
  .flow__item:not(:last-child)::after { left: calc(50% + 30px); right: calc(-50% + 30px); top: 22px; bottom: auto; width: auto; height: 1px; }
  .concept__goal { margin-top: 56px; }
}

/* Before / After -------------------------------------------------------- */
.ba { margin-top: 36px; display: grid; gap: 16px; }
.ba__card { margin: 0; padding: 28px 20px 24px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); position: relative; }
.ba__tag { position: absolute; top: -11px; left: 16px; padding: 0 10px; font-size: 12px; font-weight: 700; letter-spacing: 0.2em; background: var(--paper); }
.ba__card--before .ba__tag { color: var(--ink-sub); }
.ba__card--after { border-color: var(--navy); }
.ba__card--after .ba__tag { color: var(--navy); }
.ba__text { font-family: var(--serif); font-size: 16px; line-height: 2.1; }
.mark { text-decoration: underline wavy var(--shu); text-decoration-thickness: 1px; text-underline-offset: 6px; }
.mark--good { text-decoration: none; background: linear-gradient(transparent 65%, rgba(226,199,102,0.5) 65%); }
.ba__comment {
  margin-top: 16px; padding: 12px 14px; display: flex; gap: 10px; align-items: flex-start;
  color: var(--shu); border: 1px dashed var(--shu); border-radius: var(--radius); font-size: 14px; line-height: 1.8;
}
.ba__comment-label {
  flex: none; width: 24px; height: 24px; display: grid; place-items: center;
  background: var(--shu); color: #fff; border-radius: 50%; font-family: var(--serif); font-size: 12px; line-height: 1;
}
.ba__arrow { text-align: center; font-size: 13px; color: var(--ink-sub); letter-spacing: 0.1em; }
.ba__arrow::after { content: "↓"; display: block; font-size: 18px; color: var(--shu); line-height: 1.4; }
@media (min-width: 900px) {
  .ba { grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; }
  .ba__arrow::after { content: "→"; }
}

/* Features -------------------------------------------------------------- */
.features { margin-top: 40px; display: grid; gap: 1px; background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.12); }
.feature { padding: 28px 20px; background: var(--navy); }
.feature__num { font-family: var(--serif); font-size: 14px; color: var(--gold); letter-spacing: 0.1em; }
.feature__title { margin-top: 6px; font-size: 19px; color: #fff; }
.feature p { margin-top: 12px; font-size: 15px; line-height: 1.9; color: #cfd3d8; }
@media (min-width: 768px) {
  .features { grid-template-columns: repeat(2, 1fr); }
  .feature { padding: 36px 32px; }
  .feature:last-child { grid-column: 1 / -1; }
}
@media (min-width: 1000px) {
  .features { grid-template-columns: repeat(6, 1fr); }
  .feature { grid-column: span 2; }
  .feature:nth-child(4), .feature:nth-child(5) { grid-column: span 3; }
  .feature:last-child { grid-column: span 3; }
}

/* Steps ----------------------------------------------------------------- */
.steps { margin-top: 40px; display: grid; gap: 20px; }
.step { padding: 28px 20px; background: var(--white); border: 1px solid var(--line); border-top: 3px solid var(--navy); border-radius: var(--radius); }
.step__label { font-size: 12px; font-weight: 700; letter-spacing: 0.2em; color: var(--shu); }
.step__title { margin-top: 6px; font-size: 20px; color: var(--navy); }
.step p:last-child { margin-top: 12px; font-size: 15px; }
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; }
}

/* Support --------------------------------------------------------------- */
.support { margin-top: 36px; display: grid; gap: 16px; }
.support__group { padding: 24px 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.support__heading { font-size: 17px; color: var(--navy); padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.support__list { margin-top: 12px; display: grid; gap: 4px; }
.support__list li { position: relative; padding-left: 18px; font-size: 15px; }
.support__list li::before { content: ""; position: absolute; left: 2px; top: 0.85em; width: 7px; height: 7px; background: var(--shu); border-radius: 50%; }
@media (min-width: 768px) {
  .support { grid-template-columns: repeat(3, 1fr); }
}

/* Tutors ---------------------------------------------------------------- */
.fields { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 8px; }
.fields li { padding: 6px 16px; border: 1px solid var(--navy); border-radius: 999px; font-size: 14px; color: var(--navy); background: var(--white); line-height: 1.6; }

/* Online ---------------------------------------------------------------- */
.merits { margin-top: 36px; display: grid; gap: 16px; }
.merit { padding: 24px 20px; background: var(--paper); border-radius: var(--radius); }
.merit__title { font-size: 17px; color: var(--navy); }
.merit p { margin-top: 8px; font-size: 15px; }
@media (min-width: 768px) {
  .merits { grid-template-columns: repeat(3, 1fr); }
}

/* Price ----------------------------------------------------------------- */
.price {
  margin-top: 36px; padding: 36px 20px; text-align: center;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
}
.price__amount { font-family: var(--serif); color: var(--navy); line-height: 1.2; }
.price__num { font-size: clamp(44px, 12vw, 64px); font-weight: 700; letter-spacing: 0.02em; }
.price__unit { font-size: 22px; font-weight: 700; margin-left: 4px; }
.price__tax { font-size: 14px; font-family: var(--sans); color: var(--ink-sub); margin-left: 6px; }
.price__tax-note { margin-top: 6px; font-size: 14px; color: var(--ink-sub); }
.price__desc { margin-top: 16px; font-weight: 700; color: var(--navy); }
.price__body { margin: 20px auto 28px; max-width: 36em; text-align: left; font-size: 15px; color: var(--ink-sub); }
@media (min-width: 768px) {
  .price { padding: 56px 48px; }
  .price__body { text-align: center; }
}

/* Contact / form -------------------------------------------------------- */
.consult-flow { margin-top: 28px; display: grid; gap: 8px; }
.consult-flow li { display: flex; align-items: center; gap: 12px; font-size: 15px; }
.consult-flow span {
  flex: none; width: 28px; height: 28px; display: grid; place-items: center;
  border-radius: 50%; background: var(--navy); color: #fff; font-size: 13px; font-weight: 700;
}
@media (min-width: 768px) {
  .consult-flow { grid-template-columns: repeat(4, 1fr); }
  .consult-flow li { flex-direction: column; text-align: center; gap: 8px; font-size: 14px; line-height: 1.6; }
}

.consult-cta { margin-top: 36px; padding: 28px 20px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.form { margin-top: 36px; padding: 28px 20px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.form__row { margin: 0 0 22px; padding: 0; border: 0; min-width: 0; }
.form__label { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; padding: 0; font-weight: 700; font-size: 15px; }
.req, .opt { font-size: 11px; font-weight: 700; padding: 1px 8px; border-radius: 2px; letter-spacing: 0.05em; }
.req { background: var(--shu); color: #fff; }
.opt { background: var(--line); color: var(--ink-sub); }
.form__input {
  width: 100%; min-height: 48px; padding: 10px 12px;
  font: inherit; font-size: 16px; /* iOSのズーム防止 */
  color: var(--ink); background: #fff; border: 1px solid #c8c0ae; border-radius: var(--radius);
  appearance: none;
}
select.form__input {
  background-image: linear-gradient(45deg, transparent 50%, var(--navy) 50%), linear-gradient(135deg, var(--navy) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%;
  background-size: 6px 6px; background-repeat: no-repeat; padding-right: 40px;
}
textarea.form__input { min-height: 140px; resize: vertical; line-height: 1.7; }
.form__choices { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.choice { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 15px; cursor: pointer; }
.choice input { width: 20px; height: 20px; margin: 0; accent-color: var(--shu); }
.choice--agree a { color: var(--navy); }
.form__note { margin-top: 14px; font-size: 13px; color: var(--ink-sub); text-align: center; }
@media (min-width: 768px) {
  .form, .consult-cta { padding: 40px; }
}

/* FAQ ------------------------------------------------------------------- */
.faq { margin-top: 32px; border-top: 1px solid var(--line); }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary {
  position: relative; padding: 20px 36px 20px 32px; cursor: pointer; list-style: none;
  font-family: var(--serif); font-weight: 700; color: var(--navy); line-height: 1.7;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::before { content: "Q"; position: absolute; left: 4px; top: 20px; color: var(--shu); font-family: var(--serif); }
.faq__item summary::after { content: "+"; position: absolute; right: 8px; top: 18px; font-size: 20px; color: var(--ink-sub); }
.faq__item[open] summary::after { content: "−"; }
.faq__item p { padding: 0 8px 24px 32px; font-size: 15px; }

/* Final CTA ------------------------------------------------------------- */
.final-cta { padding: 80px 0; background: var(--navy); color: #e8e6e0; text-align: center; }
.final-cta__title { font-size: clamp(22px, 6vw, 34px); color: #fff; letter-spacing: 0.06em; }
.final-cta__lead { margin: 20px auto 32px; max-width: 34em; font-size: 15px; }
.final-cta__note { margin-top: 12px; font-size: 13px; color: #b9bec5; }
@media (min-width: 768px) {
  .final-cta { padding: 112px 0; }
}

/* Footer ---------------------------------------------------------------- */
.site-footer { padding: 48px 0 112px; background: #13202d; color: #b9bec5; font-size: 13px; }
.brand--footer .brand__ja { color: #fff; }
.brand--footer .brand__en { color: #8a929b; }
.footer-nav { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer-nav a { text-decoration: none; }
.footer-nav a:hover { text-decoration: underline; }
.copyright { margin-top: 24px; color: #8a929b; }
@media (min-width: 768px) {
  .site-footer { padding-bottom: 48px; }
}

/* Sticky CTA (mobile) --------------------------------------------------- */
.sticky-cta {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
  background: rgba(246, 243, 236, 0.96); border-top: 1px solid var(--line);
  transform: translateY(110%); transition: transform .25s ease;
}
.sticky-cta.is-visible { transform: none; }
@media (min-width: 768px) {
  .sticky-cta { display: none; }
}

/* Sub pages (legal etc.) ------------------------------------------------ */
.page { padding: 56px 0 80px; }
.page h1 { font-size: clamp(22px, 5.6vw, 30px); color: var(--navy); }
.page h2 { margin-top: 40px; font-size: 18px; color: var(--navy); }
.page p, .page ul { margin-top: 12px; }
.page ul { list-style: disc; padding-left: 1.5em; }
.page .updated { margin-top: 8px; font-size: 13px; color: var(--ink-sub); }
.table { width: 100%; margin-top: 28px; border-collapse: collapse; font-size: 15px; }
.table th, .table td { display: block; padding: 12px 0; text-align: left; vertical-align: top; line-height: 1.8; }
.table th { padding-bottom: 0; color: var(--navy); }
.table tr { border-bottom: 1px solid var(--line); }
.todo { background: #fff4c2; padding: 0 4px; }
@media (min-width: 768px) {
  .table th, .table td { display: table-cell; padding: 16px 12px; }
  .table th { width: 30%; padding-bottom: 16px; }
}
.back-link { display: inline-block; margin-top: 48px; }
