/* B안 '3단계 바로 견적' (quick.html) 전용 스타일.
   11-23 사용자 지시: 이벤트 페이지 스타일(흰 시트를 연회색 바탕에 쌓고, 큰 검정 제목 + 꽉 찬 검정 + 연회색 상자
   + 작은 회색 점 목록 + 어두운 바닥글). 색은 "타시오 A 색상" = 메인 styles.css의 파랑·네온.
   12-01: 첫 화면을 차 고르기(국산·수입 탭 + 브랜드 칸 + 차 사진 카드)로 바꿈. 입체 아이콘·진행 상자는 뺌 */
:root {
  --blue: #2B7FF2;
  --blue-deep: #1D62CC;
  --blue-text: #1D62CC; /* 흰 바탕 작은 글씨용 */
  --sky: #E4EFFF;
  --neon: #6CF25C;
  --green: #45D160;
  --green-ink: #0C1F10;
  --page: #F1F3F6;
  --white: #FFFFFF;
  --panel: #F5F7FA;
  --ink: #111317;
  --ink-soft: #5E6772;
  --ink-faint: #8B939D;
  --line: #E3E8EE;
  --line-hover: #C9D2DC;
  --dark: #15171A;
  --on-dark-soft: #A6AEB8;
  --error: #D92D30;
  --focus: #FFD43B;

  --font: "Pretendard Variable", Pretendard, -apple-system, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --text-xs: 0.8125rem;
  --text-sm: 0.9375rem;
  --text-base: 1.0625rem;
  --text-title: clamp(1.625rem, 1.3rem + 1.6vw, 2rem);

  --radius: 18px;
  --radius-sm: 12px;
  --duration: 220ms;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--page); color: var(--ink);
  font-family: var(--font); font-size: var(--text-base); line-height: 1.6; letter-spacing: -0.02em;
  word-break: keep-all; -webkit-font-smoothing: antialiased;
}
.wrap { max-width: 560px; margin: 0 auto; padding-inline: 16px; }
.num { font-variant-numeric: tabular-nums; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 8px; }
p { margin: 0; }

/* 상단: 브랜드 + 진행 */
.top { position: sticky; top: 0; z-index: 5; background: rgba(255, 255, 255, .94); backdrop-filter: blur(8px); }
.top-in { display: flex; justify-content: space-between; align-items: center; height: 52px; }
.brand { display: inline-flex; align-items: center; font-weight: 800; color: var(--ink); letter-spacing: -0.04em; }
.count { font-size: var(--text-sm); font-weight: 800; color: var(--blue-text); }
.bar { height: 3px; background: var(--line); }
.bar i { display: block; height: 100%; background: var(--blue); transform-origin: left; transform: scaleX(0); transition: transform var(--duration) var(--ease-out); }

/* 흰 시트를 연회색 바탕에 쌓음. 폰에서는 화면 끝까지, 넓은 화면에서는 둥근 카드 */
.sheets { max-width: 560px; margin: 0 auto; padding-bottom: 12px; min-height: 70vh; }
.sheet { background: var(--white); padding: 36px 20px 32px; }
.start > .sheet + .sheet { margin-top: 10px; }
@media (min-width: 560px) {
  .sheets { padding-top: 14px; }
  .sheet { border-radius: 22px; padding-inline: 28px; }
}

/* 단계 공통 */
.step { display: grid; gap: 18px; animation: rise var(--duration) var(--ease-out); }
.step.sheet { min-height: calc(100svh - 160px); align-content: start; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.title { margin: 0; font-size: var(--text-title); font-weight: 800; line-height: 1.3; letter-spacing: -0.045em; text-align: center; outline: none; }
.title em { font-style: normal; color: var(--blue); }
.back { justify-self: start; border: 0; background: none; font: inherit; font-size: var(--text-sm); font-weight: 700; color: var(--ink-soft); padding: 4px 2px; cursor: pointer; margin-top: -16px; }
.back:hover { color: var(--ink); }
.picked { justify-self: center; font-size: var(--text-xs); font-weight: 700; color: var(--blue-text); background: var(--white); border: 1.5px solid var(--blue); border-radius: 999px; padding: 5px 14px; }
.picked:empty { display: none; }
.note { font-size: var(--text-xs); color: var(--ink-faint); text-align: center; }
.err { color: var(--error); font-size: var(--text-xs); font-weight: 500; }

/* 선택 질문: 연회색 칸 (보기가 많으면 2열). 누르면 바로 다음 질문 */
.opts { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 8px; }
.opts.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.opt-btn {
  width: 100%; min-height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 0 18px; border: 1.5px solid transparent; border-radius: var(--radius-sm); background: var(--panel);
  font: inherit; font-size: var(--text-base); font-weight: 700; color: var(--ink); text-align: left; cursor: pointer;
  transition: border-color var(--duration), background var(--duration), transform var(--duration) var(--ease-out);
}
.opt-btn::after { content: "›"; font-size: 1.3rem; font-weight: 400; color: var(--line-hover); transition: color var(--duration), transform var(--duration) var(--ease-out); }
.opts.two .opt-btn { padding: 0 14px; font-size: var(--text-sm); }
.opt-text { display: grid; gap: 1px; padding-block: 10px; }
.opt-text b { font-weight: inherit; }
.opt-text small { font-size: var(--text-xs); font-weight: 500; color: var(--ink-soft); }
.opt-btn:hover { border-color: var(--blue); background: var(--sky); }
.opt-btn:hover::after { color: var(--blue); transform: translateX(2px); }
.opt-btn:active { transform: scale(.98); }
.opt-btn.other { color: var(--ink-soft); font-weight: 600; background: var(--white); border: 1.5px dashed var(--line-hover); }
.opts.two li:has(.other):last-child:nth-child(odd) { grid-column: 1 / -1; }
.typed { display: flex; gap: 8px; }
.typed input, .field input {
  flex: 1; min-width: 0; min-height: 54px; padding: 0 16px; border: 1.5px solid transparent; border-radius: var(--radius-sm);
  background: var(--panel); font: inherit; color: var(--ink);
}
.typed input:focus, .field input:focus { border-color: var(--blue); background: var(--white); outline: none; }
.mini { flex: none; min-width: 76px; border: 0; border-radius: var(--radius-sm); background: var(--ink); color: var(--white); font: inherit; font-weight: 800; cursor: pointer; }

/* 견적 산출 중: 고른 차 + 진행 막대 + 체크 항목이 차례로 끝남 */
.calc-car { width: 78%; justify-self: center; animation: drive 1.6s var(--ease-out) infinite alternate; }
.calc-car img { width: 100%; height: auto; display: block; }
.calc-car:empty { display: none; }
@keyframes drive { from { transform: translateX(-4%); } to { transform: translateX(4%); } }
.calc-bar { height: 8px; border-radius: 999px; background: var(--panel); overflow: hidden; }
.calc-bar i { display: block; height: 100%; background: var(--blue); transform-origin: left; transform: scaleX(0); transition: transform var(--duration) var(--ease-out); }
.calc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.calc-list li {
  display: flex; align-items: center; gap: 10px; padding: 13px 16px; border-radius: var(--radius-sm); background: var(--panel);
  font-size: var(--text-sm); color: var(--ink-soft); opacity: .45; transition: opacity var(--duration), color var(--duration);
}
.calc-list li::before {
  content: ""; flex: none; width: 22px; height: 22px; border-radius: 50%;
  border: 2.5px solid var(--line-hover); box-sizing: border-box;
}
.calc-list li.on { opacity: 1; color: var(--ink); }
.calc-list li.on::before { border-color: var(--blue) transparent var(--blue) var(--blue); animation: spin .7s linear infinite; }
.calc-list li.done::before { content: "✓"; display: grid; place-items: center; border: 0; background: var(--neon); color: var(--green-ink); font-size: 12px; font-weight: 900; animation: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* 이름 단계 위: 차량 확인 완료 */
.ready { justify-self: center; font-size: var(--text-xs); font-weight: 800; color: var(--green-ink); background: var(--neon); border-radius: 999px; padding: 5px 14px; }

/* 연락처 폼 */
.form { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 800; font-size: var(--text-sm); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: var(--text-sm); }
.consent input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--blue); flex: none; }
.terms { margin-top: 8px; font-size: var(--text-xs); color: var(--ink-soft); }
.terms summary { cursor: pointer; }
.terms p { margin-top: 6px; line-height: 1.7; }
.terms a { color: var(--blue-text); }
.btn {
  min-height: 56px; border: 0; border-radius: var(--radius-sm); background: var(--ink); color: var(--white);
  font: inherit; font-size: 1.0625rem; font-weight: 800; cursor: pointer; text-decoration: none;
  display: grid; place-items: center;
  transition: transform var(--duration) var(--ease-out), background var(--duration);
}
.btn:hover { background: #2A2E35; }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .6; cursor: progress; }
.btn-block { width: 100%; margin-top: 18px; }

/* 완료 */
.done .check {
  justify-self: center; width: 60px; height: 60px; border-radius: 20px; display: grid; place-items: center;
  background: var(--neon); color: var(--green-ink); font-size: 28px; font-weight: 900;
  box-shadow: inset 0 -4px 0 rgba(12, 31, 16, .18), 0 12px 22px -8px rgba(69, 209, 96, .7);
}
.done-msg { color: var(--ink-soft); text-align: center; }
.summary { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: var(--text-sm); padding: 18px; background: var(--panel); border-radius: var(--radius-sm); }
.summary dt { color: var(--ink-soft); }
.summary dd { margin: 0; font-weight: 800; }

/* 어두운 바닥글 */
footer { background: var(--dark); color: var(--on-dark-soft); padding-block: 40px 44px; margin-top: 10px; }
footer .wrap { display: grid; gap: 6px; justify-items: center; text-align: center; font-size: var(--text-xs); }
.foot-logo { margin-bottom: 10px; color: var(--white); font-size: 1.75rem; font-weight: 900; letter-spacing: -0.03em; }
footer a { color: var(--on-dark-soft); }

/* ── 시작 화면 = 차 고르기 (12-01): 국산·수입 탭 → 브랜드 칸 → 차급 칩 → 차 사진 카드 ── */
.start { gap: 0; }
.pick { display: grid; padding-top: 26px; }
.start-kicker {
  justify-self: center; display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px;
  border: 1.5px solid var(--blue); border-radius: 999px; background: var(--white);
  font-size: var(--text-xs); font-weight: 700; color: var(--blue-text);
  box-shadow: 0 4px 12px rgba(43, 127, 242, .14);
}
.start-kicker::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--green); animation: blink 1.6s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .25; } }
.start-h { margin: 14px 0 0; font-size: clamp(1.75rem, 8vw, 2.25rem); font-weight: 900; line-height: 1.25; letter-spacing: -0.055em; text-align: center; outline: none; }
.start-h em { font-style: normal; color: var(--blue); }

/* 국산차 · 수입차 탭 (꽉 찬 검정 = 고른 쪽) */
.seg { margin-top: 22px; display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border-radius: 14px; background: var(--panel); }
.seg-btn {
  min-height: 46px; border: 0; border-radius: 11px; background: transparent; color: var(--ink-soft);
  font: inherit; font-size: var(--text-base); font-weight: 800; cursor: pointer; transition: background var(--duration), color var(--duration);
}
.seg-btn[aria-pressed="true"] { background: var(--ink); color: var(--white); box-shadow: 0 4px 10px rgba(17, 19, 23, .18); }
.pick-label { margin: 22px 0 10px; font-size: var(--text-sm); font-weight: 800; color: var(--ink); scroll-margin-top: 70px; }

/* 브랜드 칸: 3열, 고르면 파랑 테두리 + 연파랑 */
.brands { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.brand-btn {
  width: 100%; min-height: 84px; display: grid; place-content: center; justify-items: center; gap: 6px; padding: 10px 4px;
  border: 1.5px solid transparent; border-radius: var(--radius-sm); background: var(--panel); color: var(--ink);
  font: inherit; text-align: center; cursor: pointer;
  transition: border-color var(--duration), background var(--duration), transform var(--duration) var(--ease-out);
}
.brand-btn b { font-size: var(--text-sm); font-weight: 800; letter-spacing: -0.04em; line-height: 1.3; }
/* 로고 자리: 높이를 고정해 로고 모양이 달라도 이름 줄이 나란히 */
.brand-logo { width: 58px; height: 30px; display: grid; place-items: center; font-size: 1.375rem; font-weight: 700; line-height: 1; color: var(--ink-faint); }
.brand-logo img { display: block; width: inherit; height: inherit; object-fit: contain; }
.brand-btn:hover { border-color: var(--line-hover); }
.brand-btn:active { transform: scale(.97); }
.brand-btn[aria-pressed="true"] { border-color: var(--blue); background: var(--sky); }
.brand-btn[aria-pressed="true"] .brand-logo { color: var(--blue-text); }
.brand-btn.other { background: var(--white); border: 1.5px dashed var(--line-hover); }

/* 고른 브랜드의 모델 */
.pick-models { margin-top: 8px; padding-top: 4px; border-top: 1px solid var(--line); scroll-margin-top: 56px; }
.pick-models .pick-label { margin-top: 20px; }
.classes { display: flex; gap: 6px; overflow-x: auto; margin: 0 -20px 12px; padding: 0 20px 2px; scrollbar-width: none; }
.classes::-webkit-scrollbar { display: none; }
.class-chip {
  flex: none; min-height: 38px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 999px; background: var(--white);
  font: inherit; font-size: var(--text-sm); font-weight: 700; color: var(--ink-soft); cursor: pointer;
}
.class-chip[aria-pressed="true"] { border-color: var(--blue); background: var(--blue); color: var(--white); }

/* 차 카드: 2열. 사진 있는 차는 사진 + 이름 + 차량가, 없는 차는 이름만 */
.models { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.model-btn {
  width: 100%; height: 100%; display: grid; align-content: start; justify-items: center; gap: 2px; padding: 12px 8px 14px;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: var(--white); color: var(--ink);
  font: inherit; text-align: center; cursor: pointer;
  transition: border-color var(--duration), background var(--duration), transform var(--duration) var(--ease-out), box-shadow var(--duration);
}
.model-pic { display: block; width: 100%; aspect-ratio: 2 / 1; margin-bottom: 6px; border-radius: 9px; background: linear-gradient(180deg, var(--panel), #E9EDF2); overflow: hidden; }
.model-pic img { display: block; width: 92%; height: 100%; margin-inline: auto; object-fit: contain; object-position: center 70%; }
.model-btn b { font-size: var(--text-sm); font-weight: 800; letter-spacing: -0.04em; line-height: 1.35; }
.model-btn small { font-size: var(--text-xs); font-weight: 700; color: var(--blue-text); }
.model-btn.no-pic { min-height: 58px; align-content: center; background: var(--panel); border-color: transparent; }
.model-btn.other { background: var(--white); border: 1.5px dashed var(--line-hover); }
.model-btn.other small { color: var(--ink-faint); }
.model-btn:hover { border-color: var(--blue); box-shadow: 0 8px 18px -10px rgba(29, 98, 204, .45); }
.model-btn:active { transform: scale(.97); }
.model-btn[aria-pressed="true"] { border-color: var(--blue); background: var(--sky); }
.pick-models .typed { margin-top: 10px; }
.pick-fine { margin-top: 12px; font-size: 0.6875rem; line-height: 1.5; color: var(--ink-faint); }

/* 작은 회색 점 목록 */
.dots-note { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 3px; font-size: var(--text-xs); color: var(--ink-faint); line-height: 1.5; text-align: left; }
.dots-note li { position: relative; padding-left: 11px; }
.dots-note li::before { content: ""; position: absolute; left: 0; top: .62em; width: 3px; height: 3px; border-radius: 50%; background: currentColor; }
.dots-left { margin-top: 18px; }

/* 시트 제목 */
.sheet-h { margin: 0; font-size: 1.5rem; font-weight: 900; line-height: 1.3; letter-spacing: -0.05em; text-align: center; }
.sheet-h-left { text-align: left; }

/* 꼭 알아두세요: 번호 목록 */
.must { list-style: none; counter-reset: must; margin: 18px 0 0; padding: 20px 18px; border-radius: var(--radius); background: var(--panel); display: grid; gap: 16px; }
.must li { counter-increment: must; position: relative; padding-left: 32px; font-size: var(--text-sm); line-height: 1.55; }
.must li::before {
  content: counter(must); position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center; background: var(--ink); color: var(--white); font-size: 12px; font-weight: 800;
}
.must b { font-weight: 800; }
.must sup { font-size: .7em; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chips i { font-style: normal; font-size: var(--text-xs); font-weight: 700; padding: 3px 10px; border-radius: 999px; border: 1.5px solid var(--blue); color: var(--blue-text); background: var(--white); }

/* 작은 폰(320px대) */
@media (max-width: 359px) {
  .pick { padding-top: 20px; }
  .start-h { font-size: 1.6rem; }
  .brand-btn { min-height: 74px; gap: 4px; }
  .brand-btn b { font-size: 0.8125rem; }
  .brand-logo { width: 48px; height: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .step { animation: none; }
  .bar i, .opt-btn, .btn, .calc-list li, .seg-btn, .brand-btn, .model-btn { transition: none; }
  .calc-car, .calc-list li.on::before, .start-kicker::before { animation: none; }
}
