/* The Scratch Project website. One stylesheet for every page. Colours follow the app's dark
   theme and the store feature graphic: deep navy, white type, the app's blue. */
:root {
  --bg: #0b1220;
  --bg-2: #111a2e;
  --card: #151f35;
  --rule: #24304a;
  --text: #eef1f6;
  --muted: #a3adc2;
  --blue: #2f6bff;
  --blue-soft: #5b8cff;
  --green: #2fbf71;
  --amber: #e0a526;
  --radius: 16px;
  --max: 1120px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--blue-soft); }
img { max-width: 100%; height: auto; display: block; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(11, 18, 32, 0.85);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--rule);
}
.site-header .inner {
  max-width: var(--max); margin: 0 auto; padding: 12px 20px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px;
}
.brand { flex: none; display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; }
/* The header carries the app's logo artwork too, never the name typed out. */
.brand-icon { width: 32px; height: 32px; border-radius: 8px; }
/* The name in the page's own type, the same as the tagline under the logo (owner's pick). */
.brand-name { font-weight: 600; font-size: 20px; line-height: 1; }
.nav { display: flex; gap: 20px; }
.nav a { color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }

/* Hero */
.hero {
  background: radial-gradient(1200px 600px at 70% -10%, #1b2a55 0%, transparent 60%), var(--bg);
  padding: 48px 20px 40px;
}
.hero .inner {
  max-width: var(--max); margin: 0 auto;
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center;
}
/* The app's own logo artwork (logo_scratch_project.png), never retyped in a web font. */
.wordmark { margin: 0 0 24px; line-height: 0; }
.wordmark img { width: 100%; max-width: 460px; }
/* The hero phone is sized by the window's height too, so the words beside it stay in view. */
.hero .phone { width: min(300px, calc(76vh * 0.46)); }
.tagline { font-size: clamp(20px, 2.4vw, 26px); font-weight: 600; margin: 0 0 16px; }
.lede { color: var(--muted); font-size: 18px; margin: 0 0 28px; max-width: 34em; }
.stores { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.store-btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 52px; padding: 8px 18px;
  border-radius: 12px; background: #000; color: #fff; text-decoration: none;
  border: 1px solid #3a4560; font-weight: 600; line-height: 1.15;
}
.store-btn small { display: block; font-size: 11px; font-weight: 500; opacity: 0.85; }
.store-btn svg { width: 26px; height: 26px; flex: none; }
.store-btn:hover { border-color: var(--blue-soft); }
.store-btn.soon { opacity: 0.7; cursor: default; }
.store-btn.soon:hover { border-color: #3a4560; }
.free-note { color: var(--muted); font-size: 14px; margin: 14px 0 0; }

.phone {
  border-radius: 36px; overflow: hidden;
  border: 1px solid #2a3654;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 0 8px #0f1626;
  max-width: 320px; margin: 0 auto;
}

/* Sections */
section { padding: 72px 20px; }
section .inner { max-width: var(--max); margin: 0 auto; }
.alt { background: var(--bg-2); }
h2 { font-size: clamp(28px, 3.4vw, 38px); line-height: 1.2; margin: 0 0 12px; }
h3 { font-size: 21px; margin: 0 0 8px; }
.section-lede { color: var(--muted); font-size: 18px; max-width: 40em; margin: 0 0 40px; }

.feature {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center;
  padding: 40px 0;
}
.feature + .feature { border-top: 1px solid var(--rule); }
.feature.flip .copy { order: 2; }
.feature .copy p { color: var(--muted); margin: 0; font-size: 18px; }
.feature .phone { max-width: 280px; }
.eyebrow { color: var(--blue-soft); font-size: 13px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; margin: 0 0 8px; }

.grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.card {
  background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 24px;
}
.card p { color: var(--muted); margin: 0; }

.shots {
  display: grid; grid-auto-flow: column; grid-auto-columns: 220px; gap: 20px;
  overflow-x: auto; padding: 8px 4px 20px; scroll-snap-type: x mandatory;
}
.shots img { border-radius: 24px; border: 1px solid #2a3654; scroll-snap-align: start; }

.cta { text-align: center; }
.cta .stores { justify-content: center; }
.cta p { color: var(--muted); }

/* Text pages (privacy, support) */
.doc { max-width: 720px; margin: 0 auto; padding: 48px 20px 72px; }
.doc h1 { font-size: 34px; margin: 0 0 4px; }
.doc h2 { font-size: 21px; margin: 36px 0 8px; }
.doc p, .doc li { color: #d3d9e4; margin: 0 0 12px; }
.doc .updated { color: var(--muted); margin-bottom: 28px; }
.doc hr { border: 0; border-top: 1px solid var(--rule); margin: 36px 0; }
.doc .card { margin: 24px 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--rule); padding: 32px 20px; color: var(--muted); font-size: 14px; }
.site-footer .inner {
  max-width: var(--max); margin: 0 auto;
  display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; align-items: center;
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 20px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }

@media (max-width: 860px) {
  .hero { padding-top: 40px; }
  .hero .inner, .feature { grid-template-columns: 1fr; gap: 32px; }
  .feature.flip .copy { order: 0; }
  .grid { grid-template-columns: 1fr; }
  .hero .phone { max-width: 260px; }
  section { padding: 56px 20px; }
}
@media (max-width: 480px) {
  .nav { gap: 14px; }
  .brand-icon { width: 28px; height: 28px; }
  .brand-name { font-size: 18px; }
  .site-header .inner { padding: 12px 16px; }
  .brand { gap: 8px; }
  /* Features only scrolls the home page; on a phone it would push the bar onto two lines. */
  .nav a[href$="#features"] { display: none; }
}
