/* ————————————————————————————————————————————————————————————————
   TermiForge site — single stylesheet, system-font stack, no deps.
   Design principles:
     • Use typography and whitespace for hierarchy; avoid decorative flourish.
     • Stay close to iOS/macOS type conventions so the site looks like an
       extension of the app, not a marketing microsite.
     • Accessible contrast, responsive at every breakpoint.
   ———————————————————————————————————————————————————————————————— */

:root {
  /* Palette */
  --ink:         #0B0D10;     /* near-black for text */
  --ink-2:       #2A2F37;     /* secondary text */
  --ink-3:       #5D6672;     /* tertiary / meta */
  --ink-4:       #9AA4B1;     /* very muted */

  --paper:       #FFFFFF;
  --paper-2:     #F6F7F9;     /* section alt */
  --paper-3:     #ECEEF2;     /* borders / hair lines */
  --paper-4:     #E2E6EC;

  --accent:      #2E6CFF;     /* primary action */
  --accent-ink:  #1F4FCC;
  --accent-tint: #E7EEFE;

  --radius-s: 8px;
  --radius-m: 14px;
  --radius-l: 22px;

  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.04), 0 1px 3px rgba(16, 24, 40, 0.08);
  --shadow-md: 0 8px 24px rgba(16, 24, 40, 0.08), 0 2px 6px rgba(16, 24, 40, 0.05);
  --shadow-lg: 0 24px 48px -12px rgba(16, 24, 40, 0.14);

  --step: 1rem;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-rendering: optimizeLegibility; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  font-feature-settings: "ss01", "ss02";
}

img, svg, picture { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-ink); }
code {
  font-family: "SF Mono", "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  background: var(--paper-3);
  padding: 0.1em 0.35em;
  border-radius: 4px;
  font-size: 0.92em;
}
em { font-style: normal; color: var(--ink); font-weight: 600; }

/* ——————————————————————————————————————————————————— Layout ——— */
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }

/* ——————————————————————————————————————————————————— Nav ———— */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255,255,255,0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--paper-3);
}
.nav__row {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.nav__brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--ink); font-weight: 600; letter-spacing: -0.01em;
}
.nav__logo {
  width: 22px; height: 22px; border-radius: 6px;
  background: linear-gradient(135deg, #3D7BFF 0%, #7A3CFF 60%, #FF4D8F 100%);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.05);
}
.nav__name { font-size: 17px; }
.nav__links {
  display: flex; align-items: center; gap: 28px;
}
.nav__links a {
  color: var(--ink-2); font-size: 15px;
}
.nav__links a:hover { color: var(--ink); }

/* ——————————————————————————————————————————————————— Buttons —— */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 18px;
  border-radius: 999px; font-weight: 500; font-size: 15px;
  transition: transform 0.08s ease, background-color 0.15s ease, box-shadow 0.2s ease;
  border: 1px solid transparent;
  line-height: 1;
}
.btn svg { width: 18px; height: 18px; }
.btn--primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 1px 0 rgba(255,255,255,0.2) inset, 0 4px 12px rgba(46,108,255,0.25);
}
.btn--primary:hover { background: var(--accent-ink); color: #fff; }
.btn--ghost {
  color: var(--ink); background: transparent;
  border-color: var(--paper-4);
}
.btn--ghost:hover { background: var(--paper-2); color: var(--ink); }
.btn--lg { height: 48px; padding: 0 24px; font-size: 16px; }

/* ——————————————————————————————————————————————————— Hero ————— */
.hero {
  padding: 80px 0 60px;
  background:
    radial-gradient(1200px 520px at 80% -10%, rgba(46,108,255,0.08), transparent 70%),
    radial-gradient(800px 320px at 10% 20%, rgba(124,60,255,0.06), transparent 70%);
}
.hero__inner {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 56px; align-items: center;
}
.eyebrow {
  text-transform: uppercase; letter-spacing: 0.12em;
  font-size: 12px; font-weight: 600; color: var(--accent);
  margin: 0 0 14px;
}
.hero h1 {
  font-size: clamp(36px, 5.2vw, 60px);
  line-height: 1.06; letter-spacing: -0.02em;
  font-weight: 700;
  margin: 0 0 20px;
  color: var(--ink);
}
.hero .lede {
  font-size: 19px; color: var(--ink-2);
  max-width: 580px; margin: 0 0 28px;
}
.cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__note {
  margin-top: 18px; font-size: 13px; color: var(--ink-3);
}
.hero__art img {
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 3; object-fit: cover; object-position: center top;
  background: var(--paper-3);
}

/* ——————————————————————————————————————————————— Sections ——— */
section { padding: 96px 0; }
.section-title {
  font-size: clamp(30px, 3.6vw, 40px);
  line-height: 1.1; letter-spacing: -0.02em;
  font-weight: 700; margin: 0 0 14px;
}
.section-sub {
  color: var(--ink-2); font-size: 18px;
  max-width: 680px; margin: 0 0 48px;
}

.grid { display: grid; gap: 24px; }
.grid--2 { grid-template-columns: 1fr 1fr; align-items: center; }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Cards */
.card {
  background: var(--paper);
  border: 1px solid var(--paper-3);
  border-radius: var(--radius-m);
  padding: 24px 22px 22px;
  transition: transform 0.15s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.card:hover {
  transform: translateY(-2px);
  border-color: var(--paper-4);
  box-shadow: var(--shadow-md);
}
.card__icon {
  width: 40px; height: 40px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px;
  background: var(--accent-tint); color: var(--accent);
  margin-bottom: 16px;
}
.card__icon svg { width: 22px; height: 22px; }
.card h3 { margin: 0 0 8px; font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
.card p  { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.6; }

/* Performance section — lighter, benchmark-feel */
.perf {
  background: var(--paper);
  position: relative;
}
.perf::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(700px 320px at 90% 0%, rgba(46,108,255,0.06), transparent 70%),
    radial-gradient(600px 280px at 5% 90%, rgba(255,77,143,0.04), transparent 70%);
  pointer-events: none;
}
.perf .wrap { position: relative; }

/* All-in-one section */
.all-in-one { background: var(--paper-2); }

/* Featured card (RD flagship) */
.card--feature {
  background: linear-gradient(160deg, #0B0D10 0%, #1A1F2A 60%, #2A1F4A 100%);
  color: #fff;
  border-color: transparent;
  position: relative;
}
.card--feature .card__icon {
  background: rgba(46,108,255,0.2);
  color: #9BB8FF;
}
.card--feature h3 { color: #fff; }
.card--feature p  { color: rgba(255,255,255,0.72); }
.card__badge {
  position: absolute; top: 18px; right: 18px;
  font-size: 10px; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #FFB4D0;
  background: rgba(255,180,208,0.12);
  border: 1px solid rgba(255,180,208,0.3);
  padding: 3px 8px; border-radius: 999px;
}
.card--feature:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }

/* Screenshot strip under features */
.shots {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px; margin-top: 48px;
}
.shots figure { margin: 0; }
.shots img {
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-md);
  aspect-ratio: 4 / 3; object-fit: cover; object-position: center top;
  background: var(--paper-3);
  width: 100%;
}
.shots figcaption {
  margin-top: 12px; text-align: center;
  font-size: 13px; color: var(--ink-3);
  letter-spacing: 0.02em;
}
@media (max-width: 780px) {
  .shots { grid-template-columns: 1fr; gap: 16px; }
}

/* System requirements list in download card */
.reqs {
  margin: 24px 0 0; padding: 0;
  display: grid; gap: 10px;
}
.reqs > div {
  display: grid; grid-template-columns: 90px 1fr;
  gap: 16px; align-items: baseline;
  padding: 10px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.reqs dt {
  font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em;
  color: rgba(255,255,255,0.5); margin: 0;
}
.reqs dd {
  margin: 0; font-size: 14px; color: rgba(255,255,255,0.85);
  line-height: 1.5;
}
@media (max-width: 560px) {
  .reqs > div { grid-template-columns: 1fr; gap: 4px; }
}

/* Showcase */
.showcase { background: var(--paper); border-top: 1px solid var(--paper-3); }
.showcase .section-title { margin-bottom: 18px; }
.showcase .list {
  list-style: none; padding: 0; margin: 20px 0 0;
  display: grid; gap: 14px;
}
.showcase .list li {
  padding-left: 28px; position: relative;
  color: var(--ink-2); font-size: 16px;
}
.showcase .list li::before {
  content: ""; position: absolute; left: 0; top: 10px;
  width: 14px; height: 2px; background: var(--accent);
  border-radius: 2px;
}
.showcase__art img {
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 3; object-fit: cover;
  background: var(--paper-3);
}

/* Download */
.download { background: var(--paper); }
.download__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}
.download__card--ipad {
  background: linear-gradient(160deg, #2D1B4E 0%, #1D2A4F 55%, #0B1D36 100%);
}
.download__card--ipad::before {
  background: radial-gradient(closest-side, rgba(255,77,143,0.35), transparent) !important;
}
.download__card--ipad .eyebrow { color: #FFB4D0 !important; }
.download__card--ipad h2 { color: #fff; }
@media (max-width: 900px) {
  .download__grid { grid-template-columns: 1fr; }
}
.download__card {
  background: linear-gradient(160deg, #0B0D10 0%, #1A1F2A 60%, #2A1F4A 100%);
  color: #fff;
  border-radius: var(--radius-l);
  padding: 64px clamp(28px, 6vw, 72px);
  box-shadow: var(--shadow-lg);
  position: relative; overflow: hidden;
}
.download__card::before {
  content: ""; position: absolute;
  right: -20%; top: -40%; width: 70%; height: 180%;
  background: radial-gradient(closest-side, rgba(46,108,255,0.35), transparent);
  pointer-events: none;
}
.download__copy { position: relative; max-width: 720px; }
.download h2 {
  font-size: clamp(30px, 3.8vw, 44px); margin: 0 0 18px;
  letter-spacing: -0.02em; font-weight: 700;
}
.download .eyebrow { color: #8CB4FF; }
.download p { color: rgba(255,255,255,0.78); font-size: 17px; max-width: 620px; }
.steps {
  list-style: none; padding: 0; margin: 24px 0;
  counter-reset: step;
  display: grid; gap: 10px;
}
.steps li {
  counter-increment: step;
  padding: 12px 16px 12px 56px;
  position: relative;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  font-size: 15px; color: rgba(255,255,255,0.88);
}
.steps li::before {
  content: counter(step);
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  width: 26px; height: 26px; border-radius: 50%;
  background: rgba(46,108,255,0.25);
  color: #AFC7FF;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600;
}
.steps strong { color: #fff; font-weight: 600; margin-right: 2px; }
.download .btn--primary {
  background: #fff; color: var(--ink);
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}
.download .btn--primary:hover { background: var(--paper-2); }
.download .btn--ghost {
  color: rgba(255,255,255,0.9); border-color: rgba(255,255,255,0.25);
}
.download .btn--ghost:hover { background: rgba(255,255,255,0.08); color: #fff; }
.meta { margin-top: 18px !important; font-size: 13px; color: rgba(255,255,255,0.55); }

/* Privacy */
.privacy { background: var(--paper-2); }
.privacy .section-title { margin-bottom: 48px; }
.feature {
  background: var(--paper);
  border: 1px solid var(--paper-3);
  border-radius: var(--radius-m);
  padding: 28px 26px;
}
.feature h3 { margin: 0 0 10px; font-size: 18px; letter-spacing: -0.01em; font-weight: 600; }
.feature p  { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.6; }

/* ————————————————————————————————————————————————— Footer ——— */
.foot {
  border-top: 1px solid var(--paper-3);
  padding: 32px 0 48px;
  color: var(--ink-3);
}
.foot__row {
  display: flex; align-items: center; gap: 24px;
  flex-wrap: wrap;
}
.foot__brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; }
.foot__links { display: flex; gap: 20px; margin-left: auto; }
.foot__links a { color: var(--ink-3); font-size: 14px; }
.foot__links a:hover { color: var(--ink); }
.foot__copy { width: 100%; font-size: 13px; margin: 0; color: var(--ink-4); }

/* ————————————————————————————————————————————— Responsive ——— */
@media (max-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 780px) {
  section { padding: 64px 0; }
  .hero { padding: 48px 0 40px; }
  .hero__inner { grid-template-columns: 1fr; gap: 32px; }
  .grid--2 { grid-template-columns: 1fr; }
  .grid--3 { grid-template-columns: 1fr; }
  .nav__links a:not(.btn) { display: none; }
  .download__card { padding: 40px 22px; }
}
