:root {
  color-scheme: light;
  --ink: #17201d;
  --muted: #606861;
  --paper: #f3f0e8;
  --card: #faf8f2;
  --line: rgba(23, 32, 29, .14);
  --green: #1f5b42;
  --radius: 28px;
  --shadow: 0 24px 60px rgba(35, 38, 31, .12);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Segoe UI Variable", "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  transition: background-color .2s ease, color .2s ease;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 3px solid #2871ff; outline-offset: 4px; border-radius: 4px; }

.site-header,
.hero,
.apps,
footer {
  width: min(1180px, calc(100% - 48px));
  margin-inline: auto;
}

.site-header {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.brand { display: inline-flex; align-items: center; gap: 11px; font-size: 14px; font-weight: 700; letter-spacing: -.01em; }
.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
  font-family: Georgia, serif;
  font-size: 0;
  font-style: italic;
}
.brand-mark::before {
  content: "G";
  font-size: 19px;
  line-height: 1;
  transform: translate(-1px, 4px);
}

nav { display: flex; align-items: center; gap: 30px; font-size: 13px; font-weight: 600; }
nav a { transition: opacity .2s ease; }
nav a:hover { opacity: .55; }
.nav-contact { padding: 10px 16px; border: 1px solid var(--line); border-radius: 999px; }

.hero {
  min-height: 0;
  padding: 78px 0 68px;
}
.hero-copy { max-width: 760px; margin-inline: auto; text-align: center; }

.eyebrow {
  margin: 0 0 18px;
  color: var(--green);
  font-size: 11px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }
h1 {
  max-width: 700px;
  margin-bottom: 26px;
  font-size: clamp(52px, 7.2vw, 92px);
  line-height: .93;
  letter-spacing: -.065em;
}
h1 em {
  font-family: Georgia, serif;
  font-weight: 500;
  color: var(--green);
  letter-spacing: -.04em;
}
.hero-intro {
  max-width: 530px;
  margin-bottom: 32px;
  margin-inline: auto;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.65;
}
.button {
  display: inline-flex;
  align-items: center;
  gap: 26px;
  padding: 15px 20px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  transition: transform .2s ease, background .2s ease, color .2s ease;
}
.button:hover { transform: translateY(-2px); background: var(--ink); color: var(--paper); }

.apps { padding: 48px 0 110px; }
.app-card {
  margin-bottom: 24px;
  display: grid;
  grid-template-columns: .82fr 1.18fr;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
}
.app-copy { padding: clamp(34px, 4.5vw, 56px); display: flex; flex-direction: column; align-items: flex-start; }
.app-title-row { margin-bottom: 30px; display: flex; align-items: center; gap: 17px; }
.app-title-row > div { min-width: 0; }
.app-icon { width: 64px; height: 64px; object-fit: contain; }
.app-icon.elementary-icon { width: 58px; height: 58px; }
.app-kicker { margin-bottom: 5px; color: var(--muted); font-size: 10px; line-height: 1.35; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
h3 { margin-bottom: 0; font-size: 34px; line-height: 1; letter-spacing: -.045em; }
.app-lead { margin-bottom: 15px; font-size: 22px; line-height: 1.25; font-weight: 600; letter-spacing: -.025em; }
.app-copy > p:not(.app-lead) { color: var(--muted); font-size: 14px; line-height: 1.65; }
.feature-list {
  width: 100%;
  margin: auto 0 28px;
  padding: 18px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border-top: 1px solid var(--line);
  list-style: none;
}
.feature-list li { padding: 7px 11px; border: 1px solid var(--line); border-radius: 99px; font-size: 10px; font-weight: 600; }
.text-link { border-bottom: 1px solid currentColor; font-size: 12px; font-weight: 700; line-height: 1.8; }
.text-link:hover { opacity: .55; }
.app-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; }
.store-badge-link { display: block; border-radius: 5px; line-height: 0; transition: opacity .2s ease, transform .2s ease; }
.store-badge-link:hover { opacity: .82; transform: translateY(-1px); }
.store-badge-link img,
.store-badge-disabled img { width: 161px; height: 44px; }
.store-badge-disabled { display: flex; align-items: center; gap: 10px; cursor: not-allowed; }
.store-badge-disabled img { opacity: .35; filter: grayscale(1); }
.store-badge-disabled span { color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.source-link { margin-top: 17px; }
.store-badges { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.store-badges a { display: block; border-radius: 4px; }
.store-badges a:hover { opacity: .78; }
.store-badges img { width: auto; height: 46px; }
.product-stage { position: relative; min-height: 400px; display: grid; place-items: center; overflow: hidden; }

.sawmill-stage { background: #efb943; }
.sawmill-stage .sawmill-screenshot { width: 94%; transform: rotate(2deg) translateY(8px); }

.elementary-stage { background: #164d86; }
.app-screenshot { width: 88%; border-radius: 8px; box-shadow: var(--shadow); transform: rotate(-2deg) translateY(8px); }
.elementary-stage .app-screenshot { width: 96%; }

.drip-stage {
  background:
    radial-gradient(circle at 30% 20%, rgba(255,255,255,.7), transparent 35%),
    linear-gradient(135deg, #a6e6ff, #c6a5ff);
}
.dfwp-stage {
  background:
    radial-gradient(circle at 18% 22%, rgba(255,255,255,.12), transparent 34%),
    linear-gradient(135deg, #20252c, #101419);
}
.dfwp-screenshot { width: 94%; transform: rotate(1.5deg) translateY(8px); }
.timer-card { width: min(320px, 78%); padding: 26px; border: 1px solid rgba(255,255,255,.55); border-radius: 28px; background: rgba(255,255,255,.72); box-shadow: var(--shadow); text-align: center; backdrop-filter: blur(14px); transform: rotate(2deg); }
.timer-top, .timer-footer { display: flex; align-items: center; justify-content: space-between; color: #5f5d7a; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.timer-top i { width: 8px; height: 8px; border-radius: 50%; background: #35b67a; box-shadow: 0 0 0 4px rgba(53,182,122,.12); }
.timer-card > p { margin: 46px 0 5px; color: #635f80; font-size: 13px; }
.timer-card > strong { display: block; margin-bottom: 30px; color: #29263f; font-size: 58px; letter-spacing: -.07em; }
.timer-controls { margin-bottom: 45px; display: flex; justify-content: center; gap: 10px; }
.timer-controls span { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: #5d54c9; color: #fff; font-size: 14px; box-shadow: 0 10px 20px rgba(93,84,201,.25); }
.timer-controls span + span { background: rgba(93,84,201,.11); color: #5d54c9; box-shadow: none; }
.timer-footer { padding-top: 18px; border-top: 1px solid rgba(41,38,63,.12); }
.timer-footer b { color: #29263f; }

footer { min-height: 140px; display: grid; grid-template-columns: 1fr 1fr 1fr; align-items: center; font-size: 11px; }
.footer-center { display: grid; justify-items: center; gap: 12px; }
.footer-center > p { margin: 0; text-align: center; color: var(--muted); }
.footer-links { display: flex; justify-content: flex-end; gap: 22px; color: var(--muted); }
.footer-links a:hover { color: var(--ink); }
.theme-picker {
  padding: 3px;
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--card);
}
.theme-picker button {
  min-height: 28px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.theme-picker button:hover { color: var(--ink); }
.theme-picker button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.theme-picker button:focus-visible { outline: 3px solid #2871ff; outline-offset: 2px; }

@media (max-width: 900px) {
  .app-card { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .site-header, .hero, .apps, footer { width: min(100% - 28px, 1180px); }
  .site-header { min-height: 72px; }
  nav a:not(.nav-contact) { display: none; }
  .hero { min-height: auto; padding-top: 54px; padding-bottom: 50px; }
  h1 { font-size: clamp(48px, 15vw, 70px); }
  .apps { padding-top: 32px; }
  .product-stage { min-height: 300px; }
  .store-badges img { height: 42px; }
  .log-lines { padding: 20px; font-size: 9px; }
  footer { padding: 36px 0; grid-template-columns: 1fr; gap: 18px; text-align: center; }
  .footer-brand, .footer-links { justify-content: center; }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #eef2ed;
  --muted: #a8b2ab;
  --paper: #111816;
  --card: #18211f;
  --line: rgba(238, 242, 237, .14);
  --green: #78cda3;
  --shadow: 0 24px 60px rgba(0, 0, 0, .32);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --ink: #eef2ed;
    --muted: #a8b2ab;
    --paper: #111816;
    --card: #18211f;
    --line: rgba(238, 242, 237, .14);
    --green: #78cda3;
    --shadow: 0 24px 60px rgba(0, 0, 0, .32);
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
