/* Trebune site: "Asphalt and Rust", dark first. Tokens match the app (tailwind.config.js). */

@font-face {
  font-family: 'Space Grotesk';
  src: url('assets/fonts/space-grotesk-latin.woff2') format('woff2');
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('assets/fonts/inter-latin.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #131313;
  --bg-lowest: #0e0e0e;
  --surface: #1a1a1a;
  --surface-2: #222222;
  --surface-3: #2a2a2a;
  --surface-4: #353534;
  --text: #F2F2F2;
  --muted: #b6b5b5;
  --dim: #8a8a8a;
  --primary: #ffb68a;
  --primary-deep: #e4700c;
  --on-primary: #522300;
  --atlantic: #8FB3B5;
  --atlantic-bg: #1E2E2F;
  --on-atlantic: #DDEBEC;
  --head: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; border-radius: 0 !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--primary); }
h1, h2, h3 { font-family: var(--head); font-weight: 700; letter-spacing: -0.03em; margin: 0; text-wrap: balance; }
p { margin: 0; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

.label {
  font-family: var(--body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(19, 19, 19, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--surface-3);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand img { width: 30px; height: 30px; }
.brand span { font-family: var(--head); font-weight: 700; font-size: 19px; letter-spacing: 0.1em; text-transform: uppercase; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { color: var(--muted); text-decoration: none; font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; }
.nav a:hover { color: var(--text); }
.nav .btn { color: var(--on-primary); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  font-family: var(--head); font-weight: 700; font-size: 14px;
  letter-spacing: 0.12em; text-transform: uppercase; text-decoration: none;
  background: var(--primary-deep); color: #fff;
  border: 0; cursor: pointer;
  transition: background 0.15s;
}
.btn:hover { background: #f07c14; }
.btn-sm { padding: 10px 16px; font-size: 12px; background: var(--primary); color: var(--on-primary); }
.btn-sm:hover { background: #ffc6a1; }
.btn-atlantic { background: transparent; color: var(--atlantic); box-shadow: inset 0 0 0 2px var(--atlantic); }
.btn-atlantic:hover { background: var(--atlantic-bg); }

/* Store badges: same footprint as the official ones, so the real artwork drops in later. */
.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store {
  display: flex; align-items: center; gap: 12px;
  min-width: 180px; height: 56px; padding: 0 18px;
  background: var(--bg-lowest); color: var(--text); text-decoration: none;
  box-shadow: inset 0 0 0 1px var(--surface-4);
}
.store svg { width: 24px; height: 24px; flex-shrink: 0; fill: var(--text); }
.store small { display: block; font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--primary); font-weight: 600; line-height: 1.3; }
.store b { display: block; font-family: var(--head); font-size: 17px; font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; }
.store[aria-disabled="true"] { cursor: default; }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; border-bottom: 6px solid var(--primary-deep); }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0.05;
  background-image: radial-gradient(circle at 1px 1px, #fff 1px, transparent 0);
  background-size: 4px 4px;
}
.hero .wrap {
  position: relative;
  display: grid; grid-template-columns: 1.7fr 1fr; gap: 48px; align-items: center;
  padding-top: 72px; padding-bottom: 80px;
}
.hero .label { color: var(--primary); }
.hero h1 {
  margin-top: 18px;
  font-size: clamp(44px, 6.4vw, 84px);
  line-height: 0.92;
  text-transform: uppercase;
  letter-spacing: -0.045em;
}
.hero h1 em { font-style: normal; color: var(--primary); }
.hero .lede { margin-top: 26px; max-width: 34em; color: var(--muted); font-size: 19px; }
.hero .stores { margin-top: 34px; }
.hero .note { margin-top: 14px; font-size: 14px; color: var(--dim); }

/* ---------- phone frame + screenshot slot ---------- */
.phone {
  position: relative;
  width: 100%; max-width: 300px; margin: 0 auto;
  aspect-ratio: 828 / 1792;
  background: var(--bg-lowest);
  box-shadow: 0 0 0 10px #050505, 0 0 0 11px var(--surface-4);
  overflow: hidden;
}
.phone > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 1; }
/* Shown when there's no screenshot yet (the img removes itself if the file is missing). */
.phone .slot {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 28px 22px;
  background:
    linear-gradient(45deg, rgba(255,182,138,0.10), rgba(228,112,12,0.02) 60%),
    var(--surface);
}
.phone .slot .num { font-family: var(--head); font-weight: 700; font-size: 120px; line-height: 0.8; color: transparent; -webkit-text-stroke: 2px var(--primary-deep); letter-spacing: -0.06em; }
.phone .slot .word { font-family: var(--head); font-weight: 700; font-size: 34px; line-height: 0.95; text-transform: uppercase; letter-spacing: -0.03em; }
.phone .slot .mark { width: 56px; height: 56px; }
.phone .slot::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 8px;
  background: linear-gradient(90deg, var(--primary), var(--primary-deep));
}
.hero .phone .slot .word { font-size: 42px; }
.phone.tilt { transform: rotate(3deg); }

/* ---------- features ---------- */
.features { padding: 96px 0 40px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-bottom: 56px; }
.section-head h2 { font-size: clamp(32px, 4.6vw, 56px); text-transform: uppercase; line-height: 0.95; }
.section-head p { color: var(--muted); max-width: 30em; }

.feature {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center;
  padding: 56px 0;
  border-top: 1px solid var(--surface-3);
}
.feature:nth-of-type(even) .feature-media { order: -1; }
.feature .phone { max-width: 250px; }
.feature .num { font-family: var(--head); font-weight: 700; font-size: 15px; color: var(--primary); letter-spacing: 0.1em; }
.feature.social .num { color: var(--atlantic); }
.feature h3 { margin-top: 10px; font-size: clamp(30px, 3.6vw, 46px); line-height: 0.98; text-transform: uppercase; }
.feature p { margin-top: 18px; color: var(--muted); max-width: 30em; }
.feature ul { margin: 22px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.feature li { position: relative; padding-left: 20px; font-size: 16px; }
.feature li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 8px; height: 8px; background: var(--primary-deep); }
.feature.social li::before { background: var(--atlantic); }
.feature li strong { font-weight: 600; color: var(--text); }

/* Weather panel: the app's three real states. */
.weather { display: grid; gap: 10px; max-width: 380px; margin: 0 auto; width: 100%; }
.wx {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 20px; background: var(--surface);
}
.wx .temp { font-family: var(--head); font-weight: 700; font-size: 30px; letter-spacing: -0.03em; }
.wx .chip { font-size: 12px; font-weight: 600; letter-spacing: 0.16em; padding: 6px 10px; }
.wx.send .chip { background: rgba(255,182,138,0.15); color: var(--primary); }
.wx.send { box-shadow: inset 4px 0 0 var(--primary); }
.wx.dry .chip { background: rgba(143,179,181,0.15); color: var(--atlantic); }
.wx.dry { box-shadow: inset 4px 0 0 var(--atlantic); }
.wx.rain .chip { background: rgba(143,179,181,0.08); color: var(--muted); }
.wx.rain { box-shadow: inset 4px 0 0 var(--surface-4); }
.wx .where { font-size: 13px; color: var(--dim); }

.also {
  margin-top: 8px; padding: 28px 0 0;
  border-top: 1px solid var(--surface-3);
  display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center;
}
.also .label { margin-right: 6px; }
.tag { font-size: 14px; font-weight: 600; padding: 7px 12px; background: var(--surface-2); color: var(--text); }

/* ---------- community ---------- */
.community { margin-top: 80px; background: var(--atlantic-bg); }
.community .wrap { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center; padding-top: 64px; padding-bottom: 64px; }
.community .label { color: var(--atlantic); }
.community h2 { margin-top: 12px; font-size: clamp(30px, 4.2vw, 52px); text-transform: uppercase; line-height: 0.95; color: var(--on-atlantic); }
.community p { margin-top: 16px; color: var(--on-atlantic); opacity: 0.8; max-width: 32em; }
.community .actions { justify-self: end; }

/* ---------- final CTA ---------- */
.cta { padding: 104px 0; text-align: left; }
.cta h2 { font-size: clamp(40px, 7vw, 96px); text-transform: uppercase; line-height: 0.9; letter-spacing: -0.045em; max-width: 11em; }
.cta h2 em { font-style: normal; color: var(--primary); }
.cta p { margin-top: 22px; color: var(--muted); max-width: 32em; }
.cta .stores { margin-top: 32px; }

/* ---------- footer ---------- */
.site-footer { background: var(--bg-lowest); border-top: 1px solid var(--surface-3); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; padding-top: 40px; padding-bottom: 48px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 10px 28px; }
.site-footer a { color: var(--muted); text-decoration: none; font-size: 15px; }
.site-footer a:hover { color: var(--text); }
.site-footer .fine { width: 100%; font-size: 13px; color: var(--dim); }

/* ---------- small screens ---------- */
@media (max-width: 860px) {
  .nav a:not(.btn) { display: none; }
  .hero .wrap { grid-template-columns: 1fr; gap: 56px; padding-top: 48px; padding-bottom: 64px; }
  .hero .phone { max-width: 240px; }
  .feature { grid-template-columns: 1fr; gap: 36px; padding: 44px 0; }
  .feature:nth-of-type(even) .feature-media { order: 0; }
  .feature .phone { max-width: 240px; }
  .community .wrap { grid-template-columns: 1fr; }
  .community .actions { justify-self: start; }
  .features { padding-top: 72px; }
  .cta { padding: 80px 0; }
}
@media (max-width: 420px) {
  .store { flex: 1 1 100%; }
  .hero .lede { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
