@font-face { font-family: "Gotham"; src: url("assets/fonts/gotham-book.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Gotham"; src: url("assets/fonts/gotham-medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Gotham"; src: url("assets/fonts/gotham-bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --ink: #000;
  --paper: #fff;
  --mist: #e8e8e8;
  --backdrop: #a7a7a7;
  --new: #e0183c;
  --muted: #6b6b6b;
  --gold: #a88a4f;
  --radius: 7px;
  --pad: 26px;
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --dur: 420ms;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --topbar: calc(76px + var(--safe-top));
}

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; margin: 0; }

body {
  font-family: "Gotham", "Montserrat", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--mist);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  -webkit-text-size-adjust: 100%;
  overscroll-behavior: none;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
img { display: block; max-width: 100%; }

:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

/* ---------- Device frame ---------- */

.device {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background: var(--mist);
  transition: background-color var(--dur) var(--ease);
}
.device[data-tone="light"] { background: var(--paper); }

@media (min-width: 640px) {
  body {
    display: grid;
    place-items: center;
    background: var(--backdrop);
    min-height: 100vh;
  }
  .device {
    width: 400px;
    height: min(860px, calc(100vh - 64px));
    border-radius: 28px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(0, 0, 0, 0.06);
  }
}

/* ---------- Top bar ---------- */

.topbar {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 30;
  height: var(--topbar);
  padding: calc(18px + var(--safe-top)) var(--pad) 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  pointer-events: none;
}
.topbar > * { pointer-events: auto; }

.logo { display: block; width: 40px; height: 40px; }
.logo img { width: 40px; height: 40px; }

.menu-btn {
  position: relative;
  width: 44px;
  height: 40px;
  margin-right: -8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}
.menu-btn span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ink);
  transition: transform 300ms var(--ease);
}
.menu-btn:active span { transform: scale(0.8); }

/* ---------- Stage + screens ---------- */

.stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.screen {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  background: var(--mist);
  padding: var(--topbar) var(--pad) calc(20px + var(--safe-bottom));
  display: flex;
  flex-direction: column;
  will-change: transform;
}
.screen[data-tone="light"] { background: var(--paper); }

/* Screen transitions: push from the right, pop back to the right */
.screen.enter-push { animation: push-in var(--dur) var(--ease) both; z-index: 2; box-shadow: -12px 0 30px rgba(0, 0, 0, 0.08); }
.screen.leave-push { animation: push-out var(--dur) var(--ease) both; z-index: 1; }
.screen.enter-pop  { animation: pop-in var(--dur) var(--ease) both; z-index: 1; }
.screen.leave-pop  { animation: pop-out var(--dur) var(--ease) both; z-index: 2; box-shadow: -12px 0 30px rgba(0, 0, 0, 0.08); }

@keyframes push-in  { from { transform: translateX(100%); } to { transform: translateX(0); } }
@keyframes push-out { from { transform: translateX(0); filter: brightness(1); } to { transform: translateX(-28%); filter: brightness(0.92); } }
@keyframes pop-in   { from { transform: translateX(-28%); filter: brightness(0.92); } to { transform: translateX(0); filter: brightness(1); } }
@keyframes pop-out  { from { transform: translateX(0); } to { transform: translateX(100%); } }

.screen.is-dragging { transition: none; animation: none; }

/* ---------- Shared type ---------- */

.label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  line-height: 1.35;
}

/* ---------- Home ---------- */

.link-list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.pill {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 11px 46px;
  border-radius: var(--radius);
  background: var(--paper);
  text-align: center;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  transition: transform 160ms var(--ease), background-color 160ms ease, opacity 160ms ease;
}
.pill:active { transform: scale(0.97); background: #f4f4f4; }

.pill--dark { background: var(--ink); color: var(--paper); }
.pill--dark:active { background: #222; }

.pill .new {
  color: var(--new);
  font-size: 8.5px;
  letter-spacing: 0.1em;
  margin-left: 10px;
  vertical-align: 1px;
}

.pill .trail {
  position: absolute;
  right: 18px;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
}

.home-foot {
  margin-top: auto;
  padding-top: 28px;
  display: grid;
  gap: 16px;
}

.socials {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
}
.socials a {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  transition: transform 160ms var(--ease), background-color 160ms ease;
}
.socials a:active { transform: scale(0.9); background: rgba(0, 0, 0, 0.06); }

/* ---------- Sub-screen header ---------- */

.subhead {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin: 18px -8px 0;
  padding: 0 44px;
  text-align: center;
}
.back {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  color: var(--muted);
  border-radius: 50%;
  transition: background-color 160ms ease;
}
.back:active { background: rgba(0, 0, 0, 0.06); }
.back svg { width: 11px; height: 18px; }
.subhead h1 { margin: 0; font-size: 12px; }

/* ---------- Grid (customize) ---------- */

.tiles {
  list-style: none;
  margin: 34px 0 0;
  padding: 0 4px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  row-gap: 36px;
  column-gap: 16px;
}
.tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
  transition: transform 160ms var(--ease);
}
.tile:active { transform: scale(0.95); }
.tile-ring {
  width: 86px;
  height: 86px;
  border: 1.75px solid var(--ink);
  border-radius: 50%;
  background: var(--paper);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.tile-ring img { width: 74%; height: 74%; object-fit: contain; }
.tile .label { font-size: 10.5px; max-width: 17ch; }

/* ---------- Buttons (support) ---------- */

.button-list { margin-top: 28px; gap: 18px; }

/* ---------- Plain list (setup guides) ---------- */

.rows {
  list-style: none;
  margin: 26px 0 0;
  padding: 0;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}
.rows a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 54px;
  padding: 0 4px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  transition: background-color 140ms ease;
}
.rows a:active { background: rgba(0, 0, 0, 0.04); }
.rows svg { width: 16px; height: 16px; flex: none; }

/* ---------- Contact ---------- */

.intro {
  margin: 26px 8px 0;
  text-align: center;
  font-size: 14px;
  line-height: 1.6;
  color: #333;
}

/* ---------- Address block ---------- */

.address {
  font-style: normal;
  text-align: center;
  font-size: 11.5px;
  line-height: 1.95;
  font-weight: 500;
}
.address strong { font-weight: 700; display: block; }
.address a { color: var(--gold); font-weight: 400; }
.address a:active { opacity: 0.6; }

.sub-foot {
  margin-top: auto;
  padding-top: 48px;
  display: grid;
  gap: 26px;
}

/* ---------- Menu overlay ---------- */

.menu {
  position: absolute;
  inset: 0;
  z-index: 20;
  background: var(--mist);
  padding: var(--topbar) var(--pad) calc(80px + var(--safe-bottom));
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transition: opacity 260ms ease, visibility 0s linear 260ms;
}
.menu[hidden] { display: flex; }
.menu.is-open {
  opacity: 1;
  visibility: visible;
  transition: opacity 260ms ease, visibility 0s;
}
.menu-links { list-style: none; margin: 18px 0 0; padding: 0; }
.menu-links li {
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 260ms ease, transform 360ms var(--ease);
}
.menu.is-open .menu-links li { opacity: 1; transform: none; }
.menu.is-open .menu-links li:nth-child(2) { transition-delay: 50ms; }
.menu.is-open .menu-links li:nth-child(3) { transition-delay: 100ms; }
.menu-links a {
  display: inline-block;
  padding: 7px 0;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.menu-links a:active { opacity: 0.5; }
.menu-address { margin-top: auto; }

/* ---------- Misc ---------- */

.noscript { padding: 24px; text-align: center; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (prefers-reduced-motion: reduce) {
  :root { --dur: 1ms; }
  .menu, .menu-links li { transition-duration: 1ms !important; transition-delay: 0s !important; }
}

.menu .address a { color: #333; }
