/* =========================================================
   BeiCheck — Regional Price Checker
   Builds on the tokens in styles.css (white / navy / electric blue).
   ========================================================= */

.pc-nav { display: flex; gap: 4px; }
.pc-nav a {
  font-size: 14px; font-weight: 500; color: var(--muted); text-decoration: none;
  padding: 8px 12px; border-radius: 8px; transition: color .2s, background-color .2s;
}
.pc-nav a:hover { color: var(--navy); background: var(--offwhite); }
.pc-nav a[aria-current="page"] { color: var(--navy); background: var(--blue-tint); display: inline-flex; align-items: center; gap: 6px; }
.pc-nav .nav__ico { width: 14px; height: 14px; color: var(--blue); }
@media (max-width: 560px) { .pc-nav a:not([aria-current]):not([href="/"]) { display: none; } .pc-nav a { padding: 8px 10px; font-size: 13.5px; } }

/* ---------- Intro ---------- */
.pc-hero { position: relative; isolation: isolate; overflow: hidden; padding: 40px 0 32px; border-bottom: 1px solid var(--line); }
.pc-hero__bg {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(255,255,255,.97) 0%, rgba(255,255,255,.9) 45%, rgba(255,255,255,.55) 100%),
    url("../assets/img/photos/qs-desk.jpg") right center / cover no-repeat,
    linear-gradient(180deg, var(--offwhite), var(--white));
}
.pc-hero__bg::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(20,43,69,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20,43,69,.06) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(70% 90% at 85% 0%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(70% 90% at 85% 0%, #000 20%, transparent 75%);
}
.pc-hero .eyebrow { margin-bottom: 14px; }
.pc-hero__title {
  font-size: clamp(32px, 7.4vw, 60px); font-weight: 800; font-stretch: 112%;
  letter-spacing: -.035em; line-height: 1.02; max-width: 16ch; text-wrap: balance;
}
.pc-hero__title span { color: var(--blue); }
.pc-hero__sub { margin-top: 14px; color: var(--muted); font-size: clamp(16px, 2vw, 19px); max-width: 52ch; }
@media (min-width: 768px) { .pc-hero { padding: 64px 0 44px; } }

.pc-progress { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.pc-progress li {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px 6px 6px; border-radius: 999px;
  font-size: 13px; font-weight: 500; color: var(--muted);
  background: var(--white); border: 1px solid var(--line);
  transition: color .2s, border-color .2s, background-color .2s;
}
.pc-progress li span {
  display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  font: 600 11px/1 var(--mono); color: var(--muted); background: var(--offwhite);
  transition: background-color .2s, color .2s;
}
.pc-progress li.is-done { color: var(--navy); border-color: rgba(40,120,240,.35); }
.pc-progress li.is-done span { background: var(--navy); color: #fff; font-size: 0; }
.pc-progress li.is-done span::before {
  content: ""; width: 10px; height: 6px; border-left: 2px solid #fff; border-bottom: 2px solid #fff;
  transform: rotate(-45deg) translate(1px, -1px);
}

/* ---------- Layout ---------- */
.pc-main { padding: 28px 0 120px; background: var(--white); }
.pc-layout { display: grid; gap: 24px; align-items: start; }
@media (min-width: 1000px) {
  .pc-main { padding: 48px 0 96px; }
  .pc-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: 40px; }
}

/* ---------- Steps ---------- */
.pc-form { display: grid; gap: 16px; }
.pc-step {
  margin: 0; min-width: 0; padding: 20px 16px 22px;
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--offwhite);
  transition: border-color .25s;
  scroll-margin-top: calc(var(--header-h) + 16px);
}
@media (min-width: 600px) { .pc-step { padding: 26px 26px 28px; } }
.pc-step.is-done { border-color: rgba(40,120,240,.25); }
.pc-step.has-error { border-color: var(--error); animation: pcShake .4s var(--ease); }
@keyframes pcShake { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }

.pc-step__head { display: flex; align-items: center; gap: 12px; padding: 0; margin-bottom: 18px; float: left; width: 100%; }
.pc-step > *:not(.pc-step__head) { clear: both; }
.pc-step__num {
  flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px;
  font: 500 13px/1 var(--mono); color: #fff; background: var(--navy);
  transition: background-color .25s;
}
.pc-step.is-done .pc-step__num { background: var(--blue); }
.pc-step__title { font-size: 18px; font-weight: 700; color: var(--navy); letter-spacing: -.01em; }
@media (min-width: 600px) { .pc-step__title { font-size: 20px; } }
.pc-step__error { clear: both; margin-top: 14px; font-size: 14px; font-weight: 500; color: var(--error); display: flex; gap: 8px; align-items: center; }
.pc-step__error[hidden] { display: none; }
.pc-step__error::before { content: "!"; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--error); color: #fff; font-size: 12px; font-weight: 700; flex: none; }
.pc-hint { color: var(--dim); font-size: 14.5px; padding: 14px 16px; border: 1px dashed var(--line-2); border-radius: 12px; background: var(--white); }

/* ---------- Option cards (radio) ---------- */
.pc-grid { display: grid; gap: 10px; }
.pc-grid--regions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 600px) { .pc-grid--regions { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.pc-grid--items { grid-template-columns: 1fr; }
@media (min-width: 560px) { .pc-grid--items { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.pc-opt { position: relative; display: block; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pc-opt input, .pc-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.pc-opt__box {
  position: relative; display: flex; align-items: center; gap: 12px;
  min-height: 56px; padding: 12px 40px 12px 14px;
  background: var(--white); border: 1.5px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow-sm);
  transition: border-color .18s, box-shadow .18s, transform .18s var(--ease), background-color .18s;
}
.pc-opt:hover .pc-opt__box { border-color: rgba(40,120,240,.45); }
.pc-opt:active .pc-opt__box { transform: scale(.985); }
.pc-opt input:focus-visible + .pc-opt__box { outline: 2px solid var(--blue); outline-offset: 2px; }
.pc-opt input:checked + .pc-opt__box {
  border-color: var(--blue); background: #F7FAFF;
  box-shadow: 0 0 0 3px rgba(40,120,240,.14), var(--shadow-sm);
}
.pc-opt__name { font-size: 15.5px; font-weight: 600; color: var(--navy); line-height: 1.25; }
.pc-opt__spec { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; line-height: 1.35; }
.pc-opt__text { min-width: 0; }
.pc-opt__pin { flex: none; width: 20px; height: 20px; color: var(--dim); transition: color .18s; }
.pc-opt__pin svg { width: 20px; height: 20px; }
.pc-opt input:checked + .pc-opt__box .pc-opt__pin { color: var(--blue); }
.pc-opt__icon {
  flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px;
  color: var(--navy); background: var(--offwhite); border: 1px solid var(--line);
  transition: background-color .18s, color .18s, border-color .18s;
}
.pc-opt__icon svg { width: 22px; height: 22px; }
.pc-opt input:checked + .pc-opt__box .pc-opt__icon { background: var(--navy); color: #fff; border-color: var(--navy); }
.pc-opt__check {
  position: absolute; right: 14px; top: 50%; width: 18px; height: 18px; margin-top: -9px;
  border-radius: 50%; border: 1.5px solid var(--line-2); background: var(--white);
  transition: background-color .18s, border-color .18s;
}
.pc-opt input:checked + .pc-opt__box .pc-opt__check {
  border-color: var(--blue);
  background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='M5 9.3l2.6 2.6L13 6.5' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/18px no-repeat;
}

/* ---------- Tabs ---------- */
.pc-tabs {
  display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; margin-bottom: 14px;
  background: var(--white); border: 1px solid var(--line); border-radius: 12px;
}
@media (min-width: 600px) { .pc-tabs { display: inline-grid; } }
.pc-tab {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 16px; border: 0; border-radius: 9px; cursor: pointer;
  font: 600 14px/1.2 var(--font); color: var(--muted); background: transparent;
  transition: background-color .2s, color .2s;
}
.pc-tab:hover { color: var(--navy); }
.pc-tab[aria-selected="true"] { background: var(--navy); color: #fff; box-shadow: 0 6px 16px -8px rgba(20,43,69,.6); }
.pc-tab__count { font: 500 11px/1 var(--mono); padding: 3px 6px; border-radius: 6px; background: var(--offwhite); color: var(--muted); }
.pc-tab[aria-selected="true"] .pc-tab__count { background: rgba(255,255,255,.16); color: #fff; }
.pc-tab:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

/* ---------- Chips (sizes + units) ---------- */
.pc-sub { margin-top: 18px; padding-top: 18px; border-top: 1px dashed var(--line-2); animation: pcIn .3s var(--ease); }
.pc-sub__label { font-size: 14px; font-weight: 600; color: var(--navy); margin-bottom: 10px; }
.pc-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.pc-chip { position: relative; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pc-chip span {
  display: inline-flex; flex-direction: column; justify-content: center; align-items: flex-start;
  min-width: 84px; min-height: 52px; padding: 8px 16px;
  font-size: 15px; font-weight: 700; color: var(--navy); line-height: 1.2;
  background: var(--white); border: 1.5px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-sm);
  transition: border-color .18s, background-color .18s, color .18s, transform .18s var(--ease);
}
.pc-chip small { font-size: 11.5px; font-weight: 500; color: var(--muted); margin-top: 2px; }
.pc-chip:hover span { border-color: rgba(40,120,240,.45); }
.pc-chip:active span { transform: scale(.97); }
.pc-chip input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }
.pc-chip input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.pc-chip input:checked + span small { color: #B9C8DC; }
.pc-chip--unit span { min-width: 110px; }
#unit-options:not(:empty) { animation: pcIn .3s var(--ease); }
@keyframes pcIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- Summary ---------- */
.pc-summary { display: none; }
@media (min-width: 1000px) {
  .pc-summary { display: block; position: sticky; top: calc(var(--header-h) + 24px); }
}
.pc-summary__card {
  padding: 24px; border-radius: var(--radius-lg); background: var(--white);
  border: 1px solid var(--line); border-top: 5px solid var(--navy); box-shadow: var(--shadow-lg);
}
.pc-summary__title { font-size: 18px; margin-bottom: 16px; }
.pc-summary__list { margin: 0 0 20px; display: grid; gap: 0; }
.pc-summary__list > div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.pc-summary__list > div:last-child { border-bottom: 0; }
.pc-summary__list dt { font: 500 11px/1.6 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.pc-summary__list dd { margin: 0; text-align: right; font-size: 14.5px; font-weight: 600; color: var(--navy); }
.pc-summary__list dd.is-empty { color: var(--dim); font-weight: 400; }
.pc-check svg { width: 18px; height: 18px; }
.pc-check:hover svg { transform: none; }
.pc-reset {
  display: block; margin: 12px auto 0; padding: 6px 10px; border: 0; background: none; cursor: pointer;
  font: 500 13.5px/1 var(--font); color: var(--muted); text-decoration: underline; text-underline-offset: 3px;
}
.pc-reset:hover { color: var(--navy); }

/* ---------- Mobile bottom bar ---------- */
.pc-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; align-items: center; gap: 12px;
  padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom));
  background: rgba(255,255,255,.96); border-top: 1px solid var(--line);
  box-shadow: 0 -10px 30px -18px rgba(20,43,69,.35);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.pc-bar__text { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.pc-bar__label { font: 500 10.5px/1.4 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.pc-bar__value { font-size: 14px; font-weight: 600; color: var(--navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pc-bar__btn { flex: none; --h: 48px; }
@media (min-width: 1000px) { .pc-bar { display: none; } }

.pc-page .footer { padding-bottom: calc(48px + 80px); }
@media (min-width: 1000px) { .pc-page .footer { padding-bottom: 48px; } }

/* ---------- Modal ---------- */
.pc-modal {
  width: min(440px, calc(100vw - 32px)); max-height: calc(100vh - 32px);
  padding: 0; border: 0; border-radius: var(--radius-lg);
  background: var(--white); color: var(--text);
  box-shadow: 0 40px 100px -20px rgba(20,43,69,.45);
  overflow: hidden;
}
.pc-modal[open] { animation: pcModalIn .28s var(--ease); }
.pc-modal::backdrop { background: rgba(20,43,69,.55); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.pc-modal[open]::backdrop { animation: pcFade .28s ease; }
@keyframes pcModalIn { from { opacity: 0; transform: translateY(16px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes pcFade { from { opacity: 0; } to { opacity: 1; } }
.pc-modal__inner { padding: 32px 24px 24px; text-align: center; border-top: 5px solid var(--navy); }
@media (min-width: 480px) { .pc-modal__inner { padding: 36px 32px 28px; } }
.pc-modal__icon {
  display: grid; place-items: center; width: 60px; height: 60px; margin: 0 auto 18px;
  border-radius: 50%; color: #B4570F; background: #FFF3E3; box-shadow: 0 0 0 8px #FFF9F1;
}
.pc-modal__icon svg { width: 30px; height: 30px; }
.pc-modal__title { font-size: 22px; font-stretch: 108%; letter-spacing: -.02em; margin-bottom: 10px; }
.pc-modal__desc { color: var(--muted); font-size: 15.5px; line-height: 1.55; }
.pc-modal__sel { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin: 18px 0 24px; }
.pc-modal__sel span {
  font-size: 12.5px; font-weight: 600; color: var(--navy);
  padding: 6px 10px; border-radius: 999px; background: var(--offwhite); border: 1px solid var(--line);
}
body.modal-open { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  .pc-step.has-error, .pc-modal[open], .pc-modal[open]::backdrop, .pc-sub, #unit-options:not(:empty) { animation: none; }
}
