/* ============================================================
   PolarCurve LLC — SaaS studio site (v3)
   Design system per GPT-5.5 brand spec.
   Fonts: Space Grotesk (display) · Plus Jakarta Sans (body) · JetBrains Mono
   ============================================================ */

:root {
  /* color */
  --ink: #17161A;
  --ink-soft: #2A2830;
  --muted: #625D66;
  --bg: #FEFDFB;
  --surface: #FFFFFF;
  --surface-warm: #F7F4EF;
  --surface-coral: #FFF1EC;
  --border: #E7E1D8;
  --border-strong: #D7CEC2;
  --accent: #F0502E;
  --accent-hover: #D94425;
  --accent-active: #BF351E;
  --dark: #111014;
  --dark-surface: #1C1A21;
  --dark-border: #343039;
  --dark-muted: #B9B2BF;

  /* fonts */
  --f-display: "Space Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --f-body: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* radius */
  --r-xs: 6px; --r-sm: 10px; --r-md: 12px; --r-lg: 16px; --r-xl: 20px; --r-2xl: 24px; --r-round: 999px;

  /* shadow */
  --sh-xs: 0 1px 2px rgba(23,22,26,0.05);
  --sh-sm: 0 1px 2px rgba(23,22,26,0.04), 0 8px 20px rgba(23,22,26,0.05);
  --sh-md: 0 1px 2px rgba(23,22,26,0.04), 0 12px 32px rgba(23,22,26,0.06);
  --sh-lg: 0 2px 4px rgba(23,22,26,0.05), 0 18px 44px rgba(23,22,26,0.09);

  --nav-h: 76px;
}

/* reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 28px;
  font-weight: 400;
  color: var(--ink-soft);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--ink); text-decoration: none; transition: color .16s; }
a:hover { color: var(--accent); }
button { font: inherit; cursor: pointer; }

/* type */
h1,h2,h3,h4 { font-family: var(--f-display); color: var(--ink); margin: 0; font-weight: 600; }
h1 { font-size: 72px; line-height: 76px; letter-spacing: -0.045em; }
h2 { font-size: 48px; line-height: 54px; letter-spacing: -0.035em; }
h3 { font-size: 32px; line-height: 40px; letter-spacing: -0.025em; }
h4 { font-size: 24px; line-height: 32px; letter-spacing: -0.015em; }
p { margin: 0 0 16px; }
.lede { font-size: 20px; line-height: 30px; color: var(--muted); }
.small { font-size: 14px; line-height: 22px; }
.caption { font-size: 12px; line-height: 18px; letter-spacing: 0.02em; }
.accent-text { color: var(--accent); }

@media (max-width: 767px) {
  h1 { font-size: 42px; line-height: 48px; letter-spacing: -0.04em; }
  h2 { font-size: 34px; line-height: 40px; letter-spacing: -0.035em; }
  h3 { font-size: 26px; line-height: 34px; letter-spacing: -0.025em; }
  h4 { font-size: 21px; line-height: 30px; }
  body { font-size: 16px; line-height: 26px; }
  .lede { font-size: 18px; line-height: 28px; }
}

/* layout */
.container { width: min(100% - 48px, 1160px); margin-inline: auto; }
.section { padding-block: 112px; }
.section-tight { padding-block: 72px; }
.section-warm { background: var(--surface-warm); }
@media (max-width: 767px) {
  .container { width: min(100% - 32px, 1160px); }
  .section { padding-block: 72px; }
  .section-tight { padding-block: 48px; }
}

/* centered section header */
.section-header { max-width: 760px; margin-inline: auto; text-align: center; margin-bottom: 56px; }
.section-header p { max-width: 640px; margin-inline: auto; color: var(--muted); margin-top: 16px; }
@media (max-width: 767px){ .section-header { margin-bottom: 40px; } }

/* eyebrow */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--f-mono); font-size: 12px; line-height: 18px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 7px; height: 7px; border-radius: 999px; background: var(--accent); }
.section-header .eyebrow { justify-content: center; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 22px; border-radius: var(--r-md);
  border: 1px solid transparent; font-family: var(--f-body); font-size: 15px;
  line-height: 20px; font-weight: 600; text-decoration: none; transition: all .16s;
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn-primary:active { background: var(--accent-active); border-color: var(--accent-active); }
.btn-secondary { background: var(--surface); border-color: var(--border-strong); color: var(--ink); }
.btn-secondary:hover { border-color: var(--ink); background: var(--surface-warm); color: var(--ink); }
.btn-small { min-height: 38px; padding: 0 16px; border-radius: var(--r-sm); font-size: 14px; }
.btn-group { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.arrow { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 15px; color: var(--accent); }
.arrow svg { transition: transform .16s; }
.arrow:hover { color: var(--accent-hover); }
.arrow:hover svg { transform: translateX(3px); }

/* nav */
.nav {
  position: sticky; top: 0; z-index: 50; height: var(--nav-h);
  background: rgba(254,253,251,0.85); backdrop-filter: saturate(150%) blur(12px);
  -webkit-backdrop-filter: saturate(150%) blur(12px); border-bottom: 1px solid var(--border);
}
.nav-inner { width: min(100% - 48px, 1160px); margin-inline: auto; height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo { display: inline-flex; align-items: center; gap: 11px; }
.logo svg { width: 34px; height: 34px; flex: 0 0 auto; }
.logo .word { font-family: var(--f-display); font-size: 22px; font-weight: 600; letter-spacing: -0.025em; color: var(--ink); }
.nav-center { display: flex; gap: 32px; }
.nav-center a { font-size: 15px; font-weight: 500; color: var(--ink-soft); }
.nav-center a:hover { color: var(--accent); }
.nav-toggle { display: none; background: var(--ink); color: var(--bg); border: 0; border-radius: var(--r-sm); padding: 9px 14px; font-size: 14px; font-weight: 600; }
@media (max-width: 920px) {
  .nav-center { position: absolute; top: var(--nav-h); left: 0; right: 0; flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--border); padding: 8px 24px; box-shadow: var(--sh-md); display: none; }
  .nav-center.open { display: flex; }
  .nav-center a { padding: 14px 0; border-bottom: 1px solid var(--border); }
  .nav-center a:last-child { border-bottom: 0; }
  .nav .btn { display: none; }
  .nav-toggle { display: inline-block; }
}

/* hero */
.hero { padding-block: 112px 96px; text-align: center; }
.hero .eyebrow { justify-content: center; }
.hero h1 { max-width: 880px; margin-inline: auto; }
.hero .lede { max-width: 660px; margin: 24px auto 0; }
.hero .btn-group { margin-top: 36px; }
.trust-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 40px; }
.trust-pill {
  display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500;
  color: var(--ink-soft); background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-round); padding: 8px 16px;
}
.trust-pill::before { content: ""; width: 6px; height: 6px; border-radius: 999px; background: var(--accent); flex: 0 0 auto; }
.hero-visual { margin-top: 64px; border-radius: var(--r-2xl); overflow: hidden; border: 1px solid var(--border); box-shadow: var(--sh-lg); aspect-ratio: 16 / 7; background: var(--surface-warm); }
.hero-visual img { width: 100%; height: 100%; object-fit: cover; }
.hero-micro { margin-top: 24px; font-family: var(--f-mono); font-size: 12px; letter-spacing: 0.03em; color: var(--muted); }
@media (max-width: 767px){ .hero { padding-block: 64px 56px; } .hero-visual { margin-top: 40px; aspect-ratio: 4 / 3; } }

/* reality cards (3-up) */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
@media (max-width: 920px){ .grid-3 { grid-template-columns: 1fr; } .grid-2 { grid-template-columns: 1fr; } }

.feature {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl); padding: 28px;
}
.feature h3 { font-family: var(--f-body); font-size: 19px; font-weight: 600; letter-spacing: -0.01em; margin-bottom: 10px; color: var(--ink); }
.feature p { color: var(--muted); font-size: 16px; line-height: 26px; margin: 0; }

/* process */
.process-card { background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-xl); padding: 28px; }
.process-num { font-family: var(--f-mono); font-size: 12px; line-height: 18px; letter-spacing: 0.06em; color: var(--accent); margin-bottom: 14px; }
.process-card h3 { font-family: var(--f-body); font-size: 20px; font-weight: 600; letter-spacing: -0.01em; margin-bottom: 10px; color: var(--ink); }
.process-card p { color: var(--muted); font-size: 16px; line-height: 26px; }
.process-card ul { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 8px; }
.process-card li { font-size: 14px; color: var(--ink-soft); padding-left: 18px; position: relative; }
.process-card li::before { content: ""; position: absolute; left: 0; top: 9px; width: 6px; height: 6px; border-radius: 999px; background: var(--border-strong); }

/* case-study cards */
.case-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-2xl); padding: 28px;
  box-shadow: var(--sh-md); transition: transform .18s, box-shadow .18s, border-color .18s;
  display: flex; flex-direction: column;
}
.case-card:hover { transform: translateY(-3px); border-color: var(--border-strong); box-shadow: var(--sh-lg); }
.case-card .cat { font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); background: var(--surface-coral); align-self: flex-start; padding: 5px 11px; border-radius: var(--r-round); margin-bottom: 18px; }
.case-card h3 { font-size: 26px; margin-bottom: 12px; }
.case-card .role { font-size: 13px; color: var(--muted); margin-bottom: 16px; font-weight: 500; }
.case-card p { color: var(--muted); font-size: 15px; line-height: 25px; margin: 0 0 16px; }
.case-card .caps { list-style: none; padding: 16px 0 0; margin: auto 0 0; border-top: 1px solid var(--border); display: flex; flex-wrap: wrap; gap: 8px; }
.case-card .caps li { font-family: var(--f-mono); font-size: 11px; color: var(--ink-soft); background: var(--surface-warm); border: 1px solid var(--border); border-radius: var(--r-round); padding: 4px 10px; }

/* credibility blocks */
.cred-block { padding: 24px 0; border-top: 1px solid var(--border); }
.cred-block:last-child { border-bottom: 1px solid var(--border); }
.cred-block h3 { font-family: var(--f-body); font-size: 18px; font-weight: 600; color: var(--ink); margin-bottom: 8px; }
.cred-block p { color: var(--muted); font-size: 16px; line-height: 26px; margin: 0; }

/* services capability list */
.cap { padding: 28px; border: 1px solid var(--border); border-radius: var(--r-xl); background: var(--surface); }
.cap h3 { font-family: var(--f-body); font-size: 19px; font-weight: 600; color: var(--ink); margin-bottom: 10px; letter-spacing: -0.01em; }
.cap p { color: var(--muted); font-size: 15px; line-height: 25px; margin: 0 0 16px; }
.cap ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 7px; }
.cap li { font-size: 14px; color: var(--ink-soft); padding-left: 18px; position: relative; }
.cap li::before { content: ""; position: absolute; left: 0; top: 9px; width: 5px; height: 5px; border-radius: 999px; background: var(--accent); }

/* FAQ accordion */
.faq { max-width: 760px; margin-inline: auto; }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 40px 22px 0; position: relative; font-family: var(--f-display); font-size: 19px; font-weight: 500; letter-spacing: -0.01em; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 24px; color: var(--accent); font-family: var(--f-body); transition: transform .2s; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { color: var(--muted); font-size: 16px; line-height: 27px; padding: 0 40px 24px 0; margin: 0; }

/* dark CTA band */
.cta-band { background: var(--dark); color: var(--bg); border-radius: var(--r-2xl); padding: 96px 48px; text-align: center; }
.cta-band h2 { color: #fff; max-width: 640px; margin: 0 auto 16px; }
.cta-band p { color: var(--dark-muted); font-size: 18px; max-width: 560px; margin: 0 auto 32px; }
.cta-band .micro { font-family: var(--f-mono); font-size: 12px; color: var(--dark-muted); margin-top: 24px; letter-spacing: 0.02em; }
@media (max-width: 767px){ .cta-band { padding: 64px 24px; } }

/* footer */
footer { background: var(--bg); border-top: 1px solid var(--border); padding: 80px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: 48px; margin-bottom: 56px; }
.footer-brand .logo { margin-bottom: 16px; }
.footer-descriptor { font-family: var(--f-body); font-size: 13px; line-height: 20px; font-weight: 500; color: var(--muted); max-width: 280px; }
footer h4 { font-family: var(--f-mono); font-size: 12px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px; }
footer ul { list-style: none; padding: 0; margin: 0; }
footer li { margin-bottom: 11px; }
footer .footer-grid a { color: var(--ink-soft); font-size: 15px; }
footer .footer-grid a:hover { color: var(--accent); }
.footer-email { font-family: var(--f-mono); font-size: 14px; color: var(--ink); }
.footer-email:hover { color: var(--accent); }
.footer-bottom { padding-top: 28px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-family: var(--f-mono); font-size: 12px; color: var(--muted); letter-spacing: 0.02em; }
.footer-bottom button { background: none; border: 0; font-family: var(--f-mono); font-size: 12px; color: var(--muted); letter-spacing: 0.02em; padding: 0; }
.footer-bottom button:hover { color: var(--accent); }
@media (max-width: 920px){ .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; } }
@media (max-width: 560px){ .footer-grid { grid-template-columns: 1fr; } }

/* page hero (subpages) */
.page-hero { padding-block: 96px 64px; text-align: center; border-bottom: 1px solid var(--border); }
.page-hero h1 { max-width: 820px; margin-inline: auto; }
.page-hero .lede { max-width: 680px; margin: 20px auto 0; }

/* detail blocks */
.detail { padding: 48px 0; border-bottom: 1px solid var(--border); }
.detail:last-child { border-bottom: 0; }
.detail .eyebrow { justify-content: flex-start; }
.detail h2 { margin-bottom: 16px; }
.detail p { font-size: 17px; line-height: 28px; max-width: 720px; color: var(--ink-soft); }
.detail .caps { list-style: none; padding: 0; margin: 20px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.detail .caps li { font-family: var(--f-mono); font-size: 12px; color: var(--ink-soft); background: var(--surface-warm); border: 1px solid var(--border); border-radius: var(--r-round); padding: 5px 12px; }

/* forms */
.form-card { max-width: 640px; margin-inline: auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-2xl); padding: 40px; box-shadow: var(--sh-sm); }
.field { margin-bottom: 20px; }
.field label { display: block; font-size: 14px; font-weight: 600; color: var(--ink); margin-bottom: 8px; }
.field input, .field select, .field textarea {
  width: 100%; font-family: var(--f-body); font-size: 16px; color: var(--ink);
  background: var(--bg); border: 1px solid var(--border-strong); border-radius: var(--r-md);
  padding: 13px 14px; transition: border-color .16s;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(240,80,46,0.12); }
.field textarea { min-height: 120px; resize: vertical; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--muted); line-height: 21px; }
.consent input { width: 18px; height: 18px; margin-top: 2px; flex: 0 0 auto; accent-color: var(--accent); }
.form-note { font-size: 13px; color: var(--muted); margin-top: 16px; text-align: center; }

/* contact split */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 48px; align-items: start; }
.contact-info .item { padding: 20px 0; border-bottom: 1px solid var(--border); }
.contact-info .item:first-child { padding-top: 0; }
.contact-info h3 { font-family: var(--f-body); font-size: 16px; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.contact-info p { color: var(--muted); font-size: 15px; margin: 0; }
.contact-info .email-chip { display: inline-flex; font-family: var(--f-mono); font-size: 15px; background: var(--surface-warm); border: 1px solid var(--border); border-radius: var(--r-md); padding: 12px 16px; margin-top: 6px; color: var(--ink); }
.contact-info .email-chip:hover { color: var(--accent); border-color: var(--accent); }
@media (max-width: 920px){ .contact-grid { grid-template-columns: 1fr; gap: 32px; } }

/* legal */
.legal { padding-block: 80px; }
.legal .container { max-width: 760px; }
.legal h1 { margin-bottom: 16px; }
.legal .effective { font-family: var(--f-mono); font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; padding-bottom: 24px; border-bottom: 1px solid var(--border); margin-bottom: 32px; }
.legal h2 { font-size: 24px; line-height: 32px; margin: 40px 0 14px; }
.legal h3 { font-family: var(--f-body); font-size: 18px; font-weight: 600; margin: 28px 0 10px; color: var(--ink); }
.legal p, .legal li { font-size: 16px; line-height: 27px; color: var(--ink-soft); }
.legal ul { padding-left: 20px; margin: 0 0 16px; }
.legal li { margin-bottom: 8px; }
.legal a { color: var(--accent); font-weight: 500; }
.legal .back { display: inline-flex; align-items: center; gap: 6px; font-family: var(--f-mono); font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); margin-bottom: 24px; }
.legal .back:hover { color: var(--accent); }
.legal table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 14px; }
.legal th, .legal td { text-align: left; padding: 12px; border: 1px solid var(--border); vertical-align: top; }
.legal th { background: var(--surface-warm); font-family: var(--f-body); font-weight: 600; color: var(--ink); }

/* cookie banner */
.cookie-banner {
  position: fixed; left: 24px; right: 24px; bottom: 24px; z-index: 100;
  max-width: 560px; margin-inline: auto; background: var(--dark); color: var(--bg);
  border: 1px solid var(--dark-border); border-radius: var(--r-xl); padding: 24px;
  box-shadow: var(--sh-lg); display: none;
}
.cookie-banner.show { display: block; }
.cookie-banner h4 { font-family: var(--f-display); font-size: 18px; color: #fff; margin-bottom: 8px; }
.cookie-banner p { font-size: 14px; line-height: 21px; color: var(--dark-muted); margin-bottom: 18px; }
.cookie-banner .actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cookie-banner .btn-small { min-height: 40px; }
.cookie-banner .btn-ghost { background: transparent; border: 1px solid var(--dark-border); color: var(--bg); }
.cookie-banner .btn-ghost:hover { background: var(--dark-surface); color: #fff; }
.cookie-modal-backdrop { position: fixed; inset: 0; z-index: 110; background: rgba(17,16,20,0.55); display: none; align-items: center; justify-content: center; padding: 24px; }
.cookie-modal-backdrop.show { display: flex; }
.cookie-modal { background: var(--surface); border-radius: var(--r-xl); max-width: 520px; width: 100%; padding: 32px; max-height: 85vh; overflow-y: auto; box-shadow: var(--sh-lg); }
.cookie-modal h3 { font-size: 24px; margin-bottom: 8px; }
.cookie-modal > p { color: var(--muted); font-size: 15px; margin-bottom: 24px; }
.cookie-cat { padding: 18px 0; border-top: 1px solid var(--border); display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.cookie-cat:last-of-type { border-bottom: 1px solid var(--border); margin-bottom: 24px; }
.cookie-cat h5 { font-family: var(--f-body); font-size: 15px; font-weight: 600; color: var(--ink); margin: 0 0 4px; }
.cookie-cat p { font-size: 13px; line-height: 19px; color: var(--muted); margin: 0; }
.cookie-cat .always { font-family: var(--f-mono); font-size: 11px; color: var(--accent); text-transform: uppercase; letter-spacing: 0.05em; white-space: nowrap; padding-top: 2px; }
.switch { position: relative; width: 44px; height: 26px; flex: 0 0 auto; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .track { position: absolute; inset: 0; background: var(--border-strong); border-radius: 999px; transition: .2s; }
.switch .track::before { content: ""; position: absolute; height: 20px; width: 20px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .2s; }
.switch input:checked + .track { background: var(--accent); }
.switch input:checked + .track::before { transform: translateX(18px); }
.cookie-modal .actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; }
@media (max-width: 560px){ .cookie-banner { left: 12px; right: 12px; bottom: 12px; padding: 20px; } .cookie-banner .actions, .cookie-modal .actions { flex-direction: column; } .cookie-banner .btn, .cookie-modal .actions .btn { width: 100%; } }

/* utilities */
.center { text-align: center; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mt-40 { margin-top: 40px; }
.section-cta { text-align: center; margin-top: 48px; }
