/* Riffalong: the app's Stage Lights theme (App/Theme/theme.json in the app repo). */
@font-face {
  font-family: "Archivo";
  src: url("/assets/fonts/archivo-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --ground: #0F1226;
  --surface: #181C38;
  --raised: #232850;
  --ink: #F5F1E8;
  --muted: #A9AECB;
  --mark: #FFB23E;
  --on-mark: #0F1226;
  --accent: #E8457A;
  --measure: 38rem;
  --gutter: 1.25rem;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
}

* { box-sizing: border-box; }
html {
  background: var(--ground);
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}
body {
  margin: 0;
  font: 400 1.0625rem/1.6 "Archivo", system-ui, -apple-system, sans-serif;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}
::selection { background: var(--mark); color: var(--on-mark); }
p, li { text-wrap: pretty; }
h1, h2 { text-wrap: balance; }
a {
  color: var(--mark);
  text-underline-offset: 0.2em;
  text-decoration-thickness: 0.07em;
  touch-action: manipulation;
}
a:focus-visible { outline: 2px solid var(--mark); outline-offset: 3px; border-radius: 4px; }
/* Addresses never break on their own; let them wrap rather than push the page sideways. */
a[href^="mailto:"] { overflow-wrap: anywhere; }

.wrap {
  width: 100%;
  max-width: 64rem;
  margin: 0 auto;
  padding: 0 max(var(--gutter), env(safe-area-inset-right)) 0 max(var(--gutter), env(safe-area-inset-left));
}
.skip { position: absolute; left: -999px; top: 0.5rem; z-index: 1; background: var(--mark); color: var(--on-mark); padding: 0.5rem 0.75rem; border-radius: 6px; }
.skip:focus { left: 1rem; }

/* Controls: no long-press text selection, and a press you can feel (pressed state on touch-down). */
.wordmark, .site-header nav a, .site-footer nav a, .contact a {
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  transition: color 150ms ease, background-color 150ms ease, transform 160ms var(--ease-out);
}
.wordmark:active, .site-header nav a:active, .contact a:active { transform: scale(0.97); }

.site-header { display: flex; align-items: center; justify-content: space-between; padding-top: 1rem; padding-bottom: 1rem; }
/* Hit areas reach 44px tall; negative margins keep the visual alignment unchanged. */
.wordmark { display: inline-flex; align-items: center; gap: 0.55rem; min-height: 2.75rem; color: var(--ink); text-decoration: none; font-weight: 750; font-size: 1.25rem; letter-spacing: -0.01em; }
.site-header nav a { display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0 0.75rem; margin-right: -0.75rem; border-radius: 999px; color: var(--muted); text-decoration: none; font-weight: 600; }
.site-header nav a[aria-current] { color: var(--ink); }

main { flex: 1; }

/* Home */
.hero { display: grid; gap: 2.5rem; align-items: center; padding: 3rem 0 4rem; }
@media (min-width: 52rem) { .hero { grid-template-columns: 1.15fr 1fr; padding: 6rem 0 7rem; } }
.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2.6rem, 6vw + 1rem, 4.75rem);
  line-height: 1.02;
  font-weight: 800;
  font-stretch: 112%;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.hero h1 em { font-style: normal; color: var(--mark); }
/* Balanced, so the last line never ends on a stray word or two. */
.hero p { margin: 0 0 2rem; max-width: 30rem; color: var(--muted); font-size: 1.2rem; text-wrap: balance; }
/* A status, not a button: no fill, so it doesn't promise a tap it can't keep. */
.soon {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.55rem 1rem 0.55rem 0.85rem;
  border: 1px solid var(--raised); border-radius: 999px;
  color: var(--ink); font-weight: 600; font-size: 0.95rem;
}
.soon::before {
  content: ""; flex: none; width: 0.5rem; height: 0.5rem; border-radius: 50%;
  background: var(--mark); box-shadow: 0 0 0 3px rgba(255, 178, 62, 0.18);
}
.stage { position: relative; display: grid; place-items: center; aspect-ratio: 1; max-width: 17rem; justify-self: center; width: 100%; }
@media (min-width: 52rem) { .stage { max-width: 26rem; } }
.stage::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(closest-side, rgba(255, 178, 62, 0.28), rgba(232, 69, 122, 0.10) 55%, transparent 72%);
}
.stage img { position: relative; width: 58%; height: auto; filter: drop-shadow(0 18px 36px rgba(0, 0, 0, 0.45)); }

/* Text pages */
.page { max-width: var(--measure); padding: 3rem 0 5rem; }
.page h1 { font-size: clamp(2rem, 3vw + 1rem, 2.75rem); line-height: 1.1; letter-spacing: -0.025em; margin: 0 0 0.5rem; font-weight: 800; }
.page h2 { font-size: 1.25rem; line-height: 1.3; margin: 2.5rem 0 0.5rem; letter-spacing: -0.01em; }
.page p, .page li { color: var(--ink); }
.page .lede { color: var(--muted); margin-bottom: 2rem; }
.page ul { padding-left: 1.2rem; }
.page li { margin: 0.35rem 0; }
/* The whole card is the target, not just the line of text inside it. */
.contact { margin-top: 1.5rem; background: var(--surface); border-radius: 14px; }
.contact p { margin: 0; }
.contact a { display: block; padding: 1.25rem 1.4rem; border-radius: inherit; }
.contact a:active { background: var(--raised); }

/* The rule sits on the content edge, not the padding edge, so it lines up with the text above it. */
.site-footer { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1.5rem; justify-content: space-between; padding-top: 1.5rem; padding-bottom: max(2rem, env(safe-area-inset-bottom)); color: var(--muted); font-size: 0.9rem; }
.site-footer::before { content: ""; position: absolute; top: 0; left: max(var(--gutter), env(safe-area-inset-left)); right: max(var(--gutter), env(safe-area-inset-right)); height: 1px; background: var(--raised); }
.site-footer p { margin: 0; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 0 1.25rem; }
.site-footer nav a { display: inline-flex; align-items: center; min-height: 2.75rem; color: var(--muted); }
.site-footer a[aria-current] { color: var(--ink); }

/* Hover only where there is a real pointer, so a tap never leaves a stuck highlight. */
@media (hover: hover) and (pointer: fine) {
  .site-header nav a:hover { color: var(--ink); background: var(--surface); }
  .site-footer a:hover { color: var(--ink); }
  .contact a:hover { background: var(--raised); }
}

/* One-time entrance on the home page: short, ease-out, staggered. Only for people who haven't asked for less motion. */
@media (prefers-reduced-motion: no-preference) {
  .hero > div:first-child > * { animation: rise 520ms var(--ease-out) both; }
  .hero > div:first-child > :nth-child(2) { animation-delay: 60ms; }
  .hero > div:first-child > :nth-child(3) { animation-delay: 120ms; }
  .stage { animation: settle 700ms var(--ease-out) 80ms both; }
  @keyframes rise { from { opacity: 0; transform: translateY(10px); } }
  @keyframes settle { from { opacity: 0; transform: scale(0.96); } }
}
@media (prefers-reduced-motion: reduce) {
  .wordmark:active, .site-header nav a:active, .contact a:active { transform: none; }
}
