:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-top: #ffffff;
  --bg-bottom: #f9f7f2;
  --panel: #f8f7f3;
  --text: #302f37;
  --muted: #6d6a78;
  --accent: #0b74de;
  --accent-strong: #005bb8;
  --border: #ded9cf;
  --shadow: rgba(48, 47, 55, 0.08);
  --heading: #111013;
  --field-bg: rgba(255, 255, 255, 0.82);
  --field-bg-strong: #fff;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #13151a;
  --bg-top: #171a20;
  --bg-bottom: #111318;
  --panel: #1b1f26;
  --text: #ece7dd;
  --muted: #aba5b4;
  --accent: #66a9ff;
  --accent-strong: #9ac8ff;
  --border: #343944;
  --shadow: rgba(0, 0, 0, 0.36);
  --heading: #f7f3ea;
  --field-bg: rgba(26, 29, 37, 0.9);
  --field-bg-strong: #1e222a;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Hanken Grotesk Variable", "Hanken Grotesk", Inter, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top, color-mix(in srgb, var(--accent) 10%, transparent), transparent 32%),
    linear-gradient(180deg, var(--bg-top) 0%, var(--bg-bottom) 100%);
  color: var(--text);
}

a {
  color: var(--accent);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 2px;
}

a:hover {
  color: var(--accent-strong);
}

main {
  width: min(980px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 64px;
}

.site-shell {
  display: grid;
  gap: 24px;
}

.site-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 4px 0 0;
}

.hero {
  padding: 8px 0 4px;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 28px;
  align-items: start;
}

.hero-top {
  display: none;
}

.hero-visual {
  display: flex;
  justify-content: flex-end;
  align-items: flex-start;
}

.hero-icon {
  display: block;
  width: 180px;
  height: 180px;
  filter: drop-shadow(0 18px 28px rgba(48, 47, 55, 0.16));
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-size: 1.05rem;
  font-weight: 600;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--field-bg);
  color: var(--text);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  box-shadow: 0 8px 20px var(--shadow);
  cursor: pointer;
}

.theme-toggle-compact {
  padding-inline: 9px;
}

.theme-toggle:hover {
  background: var(--field-bg-strong);
}

.theme-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.theme-toggle-icon {
  display: none;
  width: 16px;
  height: 16px;
}

.theme-toggle-icon svg {
  display: block;
  width: 15px;
  height: 15px;
}

html[data-theme="dark"] .theme-toggle-icon-dark,
html:not([data-theme="dark"]) .theme-toggle-icon-light {
  display: inline-flex;
}

.brand-icon {
  display: block;
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  filter: drop-shadow(0 6px 10px rgba(48, 47, 55, 0.12));
}

h1 {
  margin: 0 0 18px;
  max-width: 14ch;
  font-size: clamp(3.25rem, 6.2vw, 5.25rem);
  line-height: 0.92;
  letter-spacing: -0.05em;
  color: var(--heading);
}

.lede {
  max-width: 66ch;
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.72;
  color: var(--muted);
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.8);
  color: var(--text);
  text-decoration: none;
  box-shadow: 0 8px 20px var(--shadow);
}

.chip.primary {
  background: linear-gradient(180deg, #0b74de, #005bb8);
  color: #fff;
  border-color: transparent;
}

.email-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--accent) 8%, var(--field-bg-strong));
  color: var(--text);
  text-decoration: none;
  text-underline-offset: 0;
  line-height: 1.05;
  box-shadow: 0 8px 20px var(--shadow);
  position: relative;
  top: -2px;
  transition:
    transform 0.16s ease,
    box-shadow 0.16s ease,
    background-color 0.16s ease,
    border-color 0.16s ease,
    color 0.16s ease;
}

.email-button:hover {
  color: var(--heading);
  background: color-mix(in srgb, var(--accent) 14%, var(--field-bg-strong));
  border-color: color-mix(in srgb, var(--accent) 28%, var(--border));
  box-shadow: 0 12px 28px var(--shadow);
  transform: translateY(-1px);
}

.email-button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.email-button strong {
  font-weight: 700;
  line-height: 1;
}

.section {
  padding-top: 18px;
}

.section-title {
  margin: 0 0 12px;
  font-size: clamp(1.9rem, 3.1vw, 2.65rem);
  line-height: 1;
  font-weight: 600;
  letter-spacing: -0.04em;
}

.section-copy {
  max-width: 68ch;
  margin: 0 0 18px;
  line-height: 1.7;
  color: var(--muted);
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.card {
  background: linear-gradient(180deg, #fff, var(--panel));
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 12px 28px var(--shadow);
}

.card-link {
  display: block;
  color: inherit;
  text-decoration: none;
  transition:
    transform 0.16s ease,
    box-shadow 0.16s ease,
    border-color 0.16s ease,
    background-color 0.16s ease;
}

.card-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 34px var(--shadow);
  border-color: color-mix(in srgb, var(--accent) 30%, var(--border));
}

.card-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.page-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.card-title-row {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
}

.page-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: rgba(11, 116, 222, 0.08);
  color: var(--accent-strong);
  flex: 0 0 auto;
}

.page-card-icon svg {
  width: 20px;
  height: 20px;
}

.card h3 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--heading);
}

.card p {
  margin: 0;
  line-height: 1.65;
  color: var(--muted);
}

.card ul,
.prose ul,
.prose ol {
  margin: 0;
  padding-left: 20px;
  line-height: 1.7;
}

.prose {
  background: linear-gradient(180deg, #fff, var(--panel));
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 12px 28px var(--shadow);
}

.prose h2,
.prose h3 {
  margin-top: 24px;
  margin-bottom: 12px;
}

.prose h2:first-child,
.prose h3:first-child {
  margin-top: 0;
}

.prose p {
  line-height: 1.7;
  color: var(--text);
}

.meta {
  color: var(--muted);
  font-size: 0.95rem;
}

.footer-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.page-footer {
  display: flex;
  justify-content: center;
  padding-top: 2px;
  text-align: center;
}

.prose h2 + p {
  margin-top: 0;
}

.prose h2 + p .email-button {
  vertical-align: middle;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.showcase {
  display: grid;
  gap: 18px;
}

.showcase-copy {
  display: grid;
  gap: 16px;
  align-content: start;
}

.showcase-copy .screenshot-grid {
  margin-top: 2px;
}

.showcase-badge {
  display: inline-flex;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(11, 116, 222, 0.08);
  color: var(--accent-strong);
  font-size: 0.9rem;
  font-weight: 600;
}

.screenshot-grid {
  display: grid;
  gap: 14px;
}

.screenshot-frame {
  display: grid;
  gap: 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #fff, #f7f5ef);
  box-shadow: 0 18px 40px rgba(48, 47, 55, 0.12);
  padding: 18px;
}

.screenshot-topline {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--muted);
}

.screenshot-pill {
  display: inline-flex;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(11, 116, 222, 0.08);
  color: var(--accent-strong);
  font-size: 0.82rem;
  font-weight: 600;
}

.screenshot-title {
  margin: 0;
  font-size: 1.18rem;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--heading);
}

.screenshot-copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.screenshot-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.screenshot-chip {
  display: inline-flex;
  padding: 6px 9px;
  border-radius: 10px;
  background: var(--field-bg-strong);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.85rem;
}

.screenshot-icon {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #111827 0%, #0b1219 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.screenshot-icon img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

html[data-theme="dark"] .card,
html[data-theme="dark"] .prose,
html[data-theme="dark"] .screenshot-frame {
  background: linear-gradient(180deg, #1d2129, #181c22);
}

html[data-theme="dark"] .card-link:hover {
  border-color: color-mix(in srgb, var(--accent) 38%, var(--border));
}

html[data-theme="dark"] .chip,
html[data-theme="dark"] .screenshot-chip {
  background: var(--field-bg-strong);
}

html[data-theme="dark"] .email-button:hover {
  border-color: color-mix(in srgb, var(--accent) 38%, var(--border));
}

html[data-theme="dark"] .email-button {
  background: color-mix(in srgb, var(--accent) 20%, var(--field-bg-strong));
  border-color: color-mix(in srgb, var(--accent) 30%, var(--border));
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.42);
}

html[data-theme="dark"] .email-button:hover {
  background: color-mix(in srgb, var(--accent) 28%, var(--field-bg-strong));
  border-color: color-mix(in srgb, var(--accent) 48%, var(--border));
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.5);
}

html[data-theme="dark"] .theme-toggle {
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.34);
}

@media (max-width: 760px) {
  .site-bar {
    align-items: flex-start;
  }

  .hero-layout {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    justify-content: flex-start;
    order: -1;
  }

  .hero-icon {
    width: 136px;
    height: 136px;
  }

  .showcase {
    gap: 14px;
  }
}
