/* ModelPricer — design system
   Palette: bg #08080d · text #ECEDF2 · accent #5B7CFF · green #3DDC97 */

:root {
  --accent: #5B7CFF;
  --bg: #08080d;
  --text: #ECEDF2;
  --green: #3DDC97;
  --amber: #FFC24B;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  min-height: 100vh;
  background:
    radial-gradient(1100px 600px at 50% -140px, color-mix(in oklab, var(--accent) 15%, transparent), transparent 70%),
    radial-gradient(700px 420px at 88% 12%, color-mix(in oklab, var(--accent) 6%, transparent), transparent 70%),
    var(--bg);
}

a { text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
.spacer { flex: 1; }

.page { max-width: 1040px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 32px); }

/* Nav */
.nav { display: flex; align-items: center; gap: 24px; padding: 20px 0; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--text); font-weight: 600; font-size: 21px; letter-spacing: -0.01em; }
.brand-mark-img { width: 32px; height: 32px; display: block; }
.brand-accent { color: #9DB1FF; }
.nav-links { display: flex; align-items: center; gap: clamp(14px, 3vw, 26px); font-size: 14px; font-weight: 500; }
.nav-links a { color: rgba(236,237,242,.65); transition: color .15s; }
.nav-links a:hover { color: var(--text); }

/* Hero */
.hero { text-align: center; padding: clamp(36px, 7vw, 72px) 0 clamp(28px, 4vw, 44px); }
.hero h1 { font-size: clamp(34px, 7vw, 62px); line-height: 1.05; font-weight: 700; letter-spacing: -0.02em; }
.hero p {
  margin: 18px auto 0; max-width: 560px;
  font-size: clamp(15px, 2.4vw, 17px); line-height: 1.55; color: rgba(236,237,242,.6);
}

.verified-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px; border-radius: 999px;
  border: 1px solid rgba(61,220,151,.25); background: rgba(61,220,151,.07);
  font-size: 13px; font-weight: 600; color: var(--green); margin-bottom: 22px;
}
.pulse-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); animation: mp-pulse 2s ease-in-out infinite; }
@keyframes mp-pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

/* Sample data banner */
.sample-banner {
  max-width: 760px; margin: 0 auto 16px;
  border: 1px solid rgba(255,194,75,.35); background: rgba(255,194,75,.08);
  color: var(--amber); border-radius: 12px; padding: 10px 16px;
  font-size: 13.5px; font-weight: 600; text-align: center;
}

/* Calculator card */
.calc {
  max-width: 760px; margin: 0 auto;
  border: 1px solid rgba(255,255,255,.09); border-radius: 20px;
  background: rgba(255,255,255,.035); backdrop-filter: blur(20px);
  box-shadow: 0 24px 70px rgba(0,0,0,.5);
  padding: clamp(16px, 3vw, 26px);
  display: flex; flex-direction: column; gap: 20px;
}
.calc-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.muted-note { font-size: 12.5px; color: rgba(236,237,242,.4); font-weight: 500; }
.summary { font-size: 15px; font-weight: 600; }
.divider { height: 1px; background: rgba(255,255,255,.07); }

.field { display: flex; flex-direction: column; gap: 8px; }
.field-label {
  font-size: 12px; font-weight: 600; letter-spacing: .08em;
  text-transform: uppercase; color: rgba(236,237,242,.4);
}
.param-row { display: flex; gap: clamp(16px, 4vw, 32px); flex-wrap: wrap; }

/* Segmented control + chips */
.segment {
  display: inline-flex; gap: 2px; padding: 3px; border-radius: 12px;
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.07);
  align-self: flex-start;
}
.segment button {
  border: 0; border-radius: 9px; padding: 8px 16px;
  font-size: 13.5px; font-weight: 600;
  background: transparent; color: rgba(236,237,242,.55);
  transition: all .15s;
}
.segment button.active { background: var(--accent); color: #06070f; }
.segment button:not(.active):hover { color: var(--text); }

.chip-row { display: flex; gap: 8px; flex-wrap: wrap; }
.chip-row button {
  border: 1px solid rgba(255,255,255,.09); border-radius: 10px;
  padding: 8px 14px; font-size: 13.5px; font-weight: 600;
  background: rgba(255,255,255,.03); color: rgba(236,237,242,.65);
  transition: all .15s;
}
.chip-row button.active {
  background: color-mix(in oklab, var(--accent) 18%, transparent);
  border-color: color-mix(in oklab, var(--accent) 55%, transparent);
  color: var(--text);
}
.chip-row button:not(.active):hover { border-color: rgba(255,255,255,.2); color: var(--text); }

/* Best offer card */
.best {
  border: 1px solid color-mix(in oklab, var(--accent) 50%, transparent);
  background: linear-gradient(180deg,
    color-mix(in oklab, var(--accent) 13%, transparent),
    color-mix(in oklab, var(--accent) 4%, transparent));
  border-radius: 16px; padding: clamp(14px, 3vw, 20px);
  display: flex; flex-direction: column; gap: 14px;
}
.best-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.best-tag {
  font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--accent); background: color-mix(in oklab, var(--accent) 18%, transparent);
  border-radius: 6px; padding: 4px 8px;
}
.best-mid { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.best-platform { font-size: clamp(20px, 4vw, 26px); font-weight: 700; }
.best-note { font-size: 13px; color: rgba(236,237,242,.55); margin-top: 3px; }
.best-price {
  font-size: clamp(30px, 6vw, 40px); font-weight: 700;
  letter-spacing: -0.02em; font-variant-numeric: tabular-nums; line-height: 1;
}
.best-save { font-size: 12.5px; font-weight: 600; color: var(--green); margin-top: 6px; }
.best-cta {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--accent); color: #06070f;
  font-weight: 700; font-size: 15px; border-radius: 12px; padding: 14px 20px;
  transition: filter .15s;
}
.best-cta:hover { filter: brightness(1.12); }

.verify-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--green); }
.verify-chip .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.verify-chip.unverified { color: var(--amber); }
.verify-chip.unverified .dot { background: var(--amber); }

/* Other offers */
.others { display: flex; flex-direction: column; gap: 8px; }
.offer-row {
  display: flex; align-items: center; gap: 12px; padding: 13px 14px;
  border-radius: 12px; background: rgba(255,255,255,.025);
  border: 1px solid rgba(255,255,255,.06); color: var(--text);
  transition: background .15s;
}
.offer-row:hover { background: rgba(255,255,255,.06); }
.offer-initial {
  width: 30px; height: 30px; border-radius: 9px;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: rgba(236,237,242,.7); flex-shrink: 0;
}
.offer-main { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.offer-name { font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.offer-note { font-size: 12px; color: rgba(236,237,242,.45); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.offer-right { text-align: right; display: flex; flex-direction: column; gap: 2px; }
.offer-price { font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }
.offer-diff { font-size: 11.5px; font-weight: 600; color: rgba(236,237,242,.4); font-variant-numeric: tabular-nums; }
.offer-arrow { color: rgba(236,237,242,.3); font-size: 15px; }

/* Footer */
.tracking-note { text-align: center; padding: 26px 0 0; font-size: 13px; color: rgba(236,237,242,.35); }
.footer {
  margin-top: clamp(40px, 8vw, 80px);
  border-top: 1px solid rgba(255,255,255,.07);
  padding: 24px 0 36px;
  display: flex; gap: 16px; flex-wrap: wrap; align-items: center;
  font-size: 12.5px; color: rgba(236,237,242,.4);
}

/* Platform logos */
.offer-initial img { width: 18px; height: 18px; object-fit: contain; display: block; }
.best-logo {
  width: 26px; height: 26px; object-fit: contain;
  vertical-align: -4px; margin-right: 10px; display: inline-block;
}

/* Payment-type tags + compact verified tick */
.pay-tag {
  display: inline-block; margin-left: 8px; padding: 2px 6px;
  border-radius: 5px; font-size: 10px; font-weight: 700; letter-spacing: .08em;
  color: rgba(236,237,242,.5); background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.08); vertical-align: 1px;
}
.pay-tag.sub { color: color-mix(in oklab, var(--accent) 80%, white); background: color-mix(in oklab, var(--accent) 14%, transparent); border-color: color-mix(in oklab, var(--accent) 35%, transparent); }
.offer-verified { margin-left: 7px; color: var(--green); font-size: 12px; font-weight: 700; }
.best-note .pay-tag { vertical-align: 0; }

/* ---------- Mobile fixes ---------- */

/* Best card: keep price on the same row as platform name */
.best-mid { flex-wrap: nowrap; }
.best-mid > div:first-child { min-width: 0; }
.best-note { overflow-wrap: break-word; }

@media (max-width: 600px) {
  /* Nav: links wrap below the logo */
  .nav { flex-wrap: wrap; row-gap: 12px; padding: 16px 0 10px; }
  .nav .spacer { display: none; }
  .nav-links { width: 100%; gap: 20px; font-size: 13.5px; }

  .hero { padding-top: 26px; }

  /* Best card tighter */
  .best-price { font-size: 28px; }
  .best-platform { font-size: 19px; }
  .best-note { font-size: 12px; }

  /* Footer: stacked and centered */
  .footer { flex-direction: column; gap: 8px; text-align: center; align-items: center; padding: 20px 0 30px; }
  .footer .spacer { display: none; }
  .tracking-note { padding: 22px 8px 0; font-size: 12px; }
}

/* ---------- Doc pages (models/platforms/compare) ---------- */
.doc { max-width: 760px; margin: 0 auto; padding: clamp(20px, 4vw, 40px) 0; }
.doc h1 { font-size: clamp(26px, 5vw, 38px); letter-spacing: -0.02em; margin-bottom: 14px; }
.doc h2 { font-size: 19px; margin: 30px 0 10px; }
.doc p { color: rgba(236,237,242,.72); line-height: 1.6; margin-bottom: 12px; }
.doc a { color: #9DB1FF; }
.doc-muted { color: rgba(236,237,242,.42); font-size: 13.5px; }
.doc-table { width: 100%; border-collapse: collapse; margin: 14px 0 22px; font-size: 14.5px; }
.doc-table th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .07em;
  color: rgba(236,237,242,.45); padding: 8px 10px; border-bottom: 1px solid rgba(255,255,255,.12); }
.doc-table td { padding: 10px; border-bottom: 1px solid rgba(255,255,255,.06); }
.doc-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.doc-table a { color: var(--text); font-weight: 600; text-decoration: none; }
.doc-table a:hover { color: #9DB1FF; }
.doc-best { color: var(--green); font-weight: 700; font-size: 12.5px; }
.doc-list { list-style: none; display: flex; flex-direction: column; gap: 10px; margin: 18px 0; }
.doc-list a { color: var(--text); font-weight: 600; font-size: 16px; }
.doc-list a:hover { color: #9DB1FF; }
.doc-cta { display: inline-block; margin-top: 8px; font-weight: 700; }
@media (max-width: 600px) {
  .doc-table { font-size: 13px; }
  .doc-table td, .doc-table th { padding: 8px 6px; }
}

.pay-tag.direct { background: rgba(255,199,89,.14); color: #FFC759; border-color: rgba(255,199,89,.35); }

/* ---------- GPU break-even calculator ---------- */
.gpu-calc { background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.08); border-radius: 14px; padding: 18px; margin: 14px 0 10px; display: flex; flex-direction: column; gap: 14px; }
.gpu-calc select, .gpu-calc input { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); color: var(--text); border-radius: 8px; padding: 8px 10px; font: inherit; font-size: 14px; }
.gpu-calc input { width: 110px; }
.gpu-calc select { max-width: 100%; }
.gc-result { font-size: 15px; padding-top: 4px; border-top: 1px solid rgba(255,255,255,.08); line-height: 1.5; }
.gc-win { color: var(--green); }
