/* Hazel site: one stylesheet for every page. */

:root {
  --bg: #0a0a0a;
  --bg-2: #0f0f0f;
  --surface: #141414;
  --surface-2: #1b1b1b;
  --line: #232323;
  --line-2: #303030;
  --fg: #ededed;
  --fg-2: #a6a6a6;
  --fg-3: #6e6e6e;
  --accent: #00bcd4;
  --accent-ink: #001f24;
  --accent-soft: rgba(0, 188, 212, .1);
  --radius: 22px;
  --page: 1400px;
  --gutter: clamp(20px, 4vw, 64px);
  --display: "Inter Tight", "Inter", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f7f5f1; --bg-2: #f1eee9; --surface: #fdfcfa; --surface-2: #efebe5;
    --line: #e4e0d8; --line-2: #d4cfc5; --fg: #1f1d1a; --fg-2: #5e5a53; --fg-3: #8d8880;
    --accent: #00838f; --accent-ink: #ffffff; --accent-soft: rgba(0, 131, 143, .09);
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #f7f5f1; --bg-2: #f1eee9; --surface: #fdfcfa; --surface-2: #efebe5;
  --line: #e4e0d8; --line-2: #d4cfc5; --fg: #1f1d1a; --fg-2: #5e5a53; --fg-3: #8d8880;
  --accent: #00838f; --accent-ink: #ffffff; --accent-soft: rgba(0, 131, 143, .09);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; scroll-padding-top: 96px; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font: 400 17px/1.65 var(--body); -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }
.wrap { width: 100%; max-width: var(--page); margin: 0 auto; padding: 0 var(--gutter); }
.mono { font-family: var(--mono); font-size: 13px; letter-spacing: .02em; }
.eyebrow { font: 500 13px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--fg-3); }
.eyebrow.accent { color: var(--accent); }
.link { color: var(--fg); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; transition: text-decoration-color .15s; }
.link:hover { text-decoration-color: var(--accent); }
.dot { display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: var(--line-2); vertical-align: middle; margin: 0 12px; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  height: 44px; padding: 0 20px; border-radius: 999px;
  font: 500 15px/1 var(--body); white-space: nowrap; border: 1px solid transparent; cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-primary { background: var(--fg); color: var(--bg); }
.btn-primary:hover { background: color-mix(in srgb, var(--fg) 86%, var(--bg)); }
.btn-ghost { border-color: var(--line-2); background: transparent; }
.btn-ghost:hover { background: var(--surface); }
.btn-lg { height: 54px; padding: 0 26px; font-size: 16px; }
.icon-btn {
  display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px;
  background: transparent; border: 1px solid transparent; color: var(--fg-2); cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.icon-btn:hover { color: var(--fg); background: var(--surface); border-color: var(--line); }
.icon-btn svg { width: 20px; height: 20px; }

/* ── Nav ── */
.nav {
  position: sticky; top: 0; z-index: 30;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: saturate(140%) blur(16px); -webkit-backdrop-filter: saturate(140%) blur(16px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.nav.scrolled { border-bottom-color: var(--line); }
.nav .wrap { display: flex; align-items: center; height: 72px; gap: 40px; }
.brand { display: flex; align-items: center; gap: 11px; font: 600 19px/1 var(--display); letter-spacing: -.015em; }
.brand svg { width: 24px; height: 24px; }
.nav-links { display: flex; gap: 6px; font-size: 15px; color: var(--fg-2); }
.nav-links a { padding: 8px 12px; border-radius: 10px; transition: color .15s, background .15s; }
.nav-links a:hover { color: var(--fg); background: var(--surface); }
.nav-links a[aria-current="page"] { color: var(--fg); }
.nav-end { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.nav-end .btn { margin-left: 8px; }
.menu-btn { display: none; }
.theme-icon { display: none; }
:root:not([data-theme]) .theme-icon.auto,
:root[data-theme="light"] .theme-icon.light,
:root[data-theme="dark"] .theme-icon.dark { display: block; }
.mobile-menu { display: none; }

/* ── Page heads (guide, faq, support) ── */
.page-head { padding: 104px 0 64px; border-bottom: 1px solid var(--line); }
.page-head h1 { margin: 18px 0 0; font: 700 clamp(44px, 5.4vw, 76px)/1.02 var(--display); letter-spacing: -.045em; max-width: 16ch; }
.page-head p { margin: 22px 0 0; max-width: 640px; color: var(--fg-2); font-size: 19px; }

/* ── Footer ── */
footer { border-top: 1px solid var(--line); padding: 72px 0 56px; margin-top: 0; }
footer .grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 40px; }
footer .about p { color: var(--fg-3); font-size: 15px; margin: 16px 0 0; max-width: 34ch; }
footer h4 { margin: 0 0 16px; font: 500 12px/1 var(--mono); color: var(--fg-3); text-transform: uppercase; letter-spacing: .08em; }
footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 11px; font-size: 15px; color: var(--fg-2); }
footer ul a:hover { color: var(--fg); }
.legal { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 32px; margin-top: 56px; border-top: 1px solid var(--line); color: var(--fg-3); }

/* ── Reveal ── */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ── Responsive shell ── */
@media (max-width: 1080px) {
  .nav-links { display: none; }
  .menu-btn { display: inline-grid; }
  .mobile-menu { display: none; border-top: 1px solid var(--line); padding: 8px var(--gutter) 16px; }
  .mobile-menu.open { display: grid; }
  .mobile-menu a { padding: 14px 4px; border-bottom: 1px solid var(--line); color: var(--fg-2); font-size: 16px; }
  .mobile-menu a:last-child { border-bottom: 0; }
  footer .grid { grid-template-columns: 1fr 1fr 1fr; }
  footer .about { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .nav .wrap { height: 64px; gap: 16px; }
  .nav-end .gh-link { display: none; }
  .nav-end .btn { height: 38px; padding: 0 16px; font-size: 14px; }
  .page-head { padding: 72px 0 44px; }
  .page-head p { font-size: 17px; }
  footer .grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 360px) {
  .nav .wrap { gap: 10px; }
  .nav-end { gap: 2px; }
  .nav-end .btn { padding: 0 12px; margin-left: 4px; }
  .icon-btn { width: 38px; height: 38px; }
  .share div { font-size: 11px; }
}

/* ════════ Flat surfaces ════════
   No outlines anywhere: every card, button, chip and frame is told apart by its fill alone.
   Things that sit on a card use the page tone, so they read as set into it. */
:root { --surface: #151515; --surface-2: #1d1d1d; --surface-3: #242424; --fg-3: #8e8e8e; --fg-2: #b4b4b4; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) { --surface: #efebe4; --surface-2: #e6e1d8; --surface-3: #ddd7cc; }
}
:root[data-theme="light"] { --surface: #efebe4; --surface-2: #e6e1d8; --surface-3: #ddd7cc; }

.btn-ghost { border: 0; background: var(--surface); }
.btn-ghost:hover { background: var(--surface-2); }
.icon-btn, .icon-btn:hover { border: 0; }
.icon-btn:hover { background: var(--surface); }
.nav-links a:hover { background: var(--surface); }
.mobile-menu.open { background: var(--bg); box-shadow: 0 24px 40px -24px rgba(0,0,0,.5); }
.mobile-menu a { border-bottom: 0; border-radius: 12px; padding: 14px 12px; }
.mobile-menu a:hover { background: var(--surface); }
.nav.scrolled { border-bottom-color: transparent; background: color-mix(in srgb, var(--bg) 92%, transparent); }
footer { border-top: 0; background: var(--bg-2); }
.legal { border-top: 0; }
.page-head { border-bottom: 0; }

/* ════════ Screenshot viewer ════════ */
.device.zoomable { cursor: zoom-in; transition: transform .2s ease, background .2s; }
.device.zoomable:hover { transform: translateY(-3px); }
.device.zoomable:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
html.viewer-open { overflow: hidden; }
.viewer {
  position: fixed; inset: 0; z-index: 100; display: grid; grid-template-columns: 72px 1fr 72px; align-items: center;
  padding: 24px; background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  opacity: 0; transition: opacity .18s ease;
}
.viewer[hidden] { display: none; }
.viewer.on { opacity: 1; }
.v-stage { margin: 0; grid-column: 2; display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; min-height: 0; }
.v-stage img {
  max-height: calc(100vh - 140px); max-height: calc(100dvh - 140px); max-width: 100%; width: auto; height: auto;
  border-radius: 28px; background: var(--surface-2); padding: 8px;
  transform: scale(.97); transition: transform .2s ease;
}
.viewer.on .v-stage img { transform: none; }
.v-stage figcaption { margin-top: 16px; color: var(--fg-2); font-size: 15px; text-align: center; }
.viewer button {
  width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--surface); color: var(--fg);
  display: grid; place-items: center; cursor: pointer; transition: background .15s;
}
.viewer button:hover { background: var(--surface-2); }
.viewer button svg { width: 22px; height: 22px; }
.v-prev { grid-column: 1; justify-self: center; }
.v-next { grid-column: 3; justify-self: center; }
.v-close { position: absolute; top: 20px; right: 20px; }
.v-count { position: absolute; top: 36px; left: 28px; color: var(--fg-3); }
.viewer.single .v-prev, .viewer.single .v-next, .viewer.single .v-count { display: none; }
@media (max-width: 640px) {
  .viewer { grid-template-columns: 1fr; padding: 72px 16px 88px; }
  .v-stage { grid-column: 1; }
  .v-stage img { max-height: calc(100dvh - 190px); border-radius: 22px; padding: 6px; }
  .v-prev, .v-next { position: absolute; bottom: 24px; }
  .v-prev { left: calc(50% - 64px); }
  .v-next { left: calc(50% + 12px); }
  .v-close { top: 14px; right: 14px; }
  .v-count { top: 30px; left: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .viewer, .v-stage img, .device.zoomable { transition: none; }
  .device.zoomable:hover { transform: none; }
}
