/* shffflr — marketing site
   Tokens lifted from Shffflr/UI/Design/Tokens.swift via the design canvas.
   Site-only additions are marked "new". */

:root {
  /* Colour */
  --bg: #0b0b0d;
  --accent: #ec008c;
  --accent-bright: #ff4fb5;
  --accent-warm: #fc6767;
  --danger: #f87171;

  --ink-strong: rgba(255, 255, 255, 0.95);
  --ink: rgba(255, 255, 255, 0.92);
  --ink-dim: rgba(255, 255, 255, 0.5);
  --ink-faint: rgba(255, 255, 255, 0.4); /* glyphs and rules only, never body copy */

  --surface: rgba(255, 255, 255, 0.08);
  --surface-soft: rgba(255, 255, 255, 0.03);
  --hairline: rgba(255, 255, 255, 0.08);
  --hairline-soft: rgba(255, 255, 255, 0.06);
  --mini: rgba(40, 40, 44, 0.96);
  --cell-played: rgba(255, 255, 255, 0.72); /* new — light grey fill for a played square */

  --accent-wash: rgba(236, 0, 140, 0.06);
  --accent-edge: rgba(236, 0, 140, 0.3);
  --artwork-fallback: linear-gradient(153deg, #ec008c 0%, #fc6767 100%);

  /* Metrics */
  --gutter: 24px; /* new — site gutter, phone */
  --gutter-wide: 80px; /* new — site gutter, desktop */
  --content-max: 1120px; /* new */
  --section: 96px;
  --radius-card: 16px;
  --radius-pill: 999px;
  --tap: 44px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--ink-strong);
}

p {
  margin: 0;
}

a {
  color: var(--accent-bright);
  text-decoration: none;
}

a:hover {
  color: var(--accent);
  text-decoration: underline;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent-bright);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Layout ------------------------------------------------------------------ */

.page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.wrap {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 10;
  padding: 12px 20px;
  background: var(--accent);
  color: var(--bg);
  font-weight: 700;
}

.skip-link:focus {
  left: 0;
  text-decoration: none;
  color: var(--bg);
}

/* Nav --------------------------------------------------------------------- */

.nav {
  border-bottom: 1px solid var(--hairline-soft);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 20px;
  padding-bottom: 20px;
}

.nav__logo img {
  height: 56px;
  width: auto;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav__link {
  display: none;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.nav__link[aria-current="page"] {
  color: var(--accent);
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap);
  padding: 0 24px;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: var(--bg);
  font-size: 14px;
  font-weight: 700;
}

.pill:hover {
  background: var(--accent-bright);
  color: var(--bg);
  text-decoration: none;
}

/* Section furniture -------------------------------------------------------- */

.section {
  padding-top: 56px;
  padding-bottom: 56px;
}

.section--banded {
  background: var(--surface-soft);
  border-top: 1px solid var(--hairline-soft);
  border-bottom: 1px solid var(--hairline-soft);
}

.section__title {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.section__title--sm {
  font-size: 24px;
  letter-spacing: -0.01em;
}

.section__lead {
  margin-top: 14px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-dim);
  max-width: 640px;
}

.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

.eyebrow--accent {
  color: var(--accent);
}

/* Hero -------------------------------------------------------------------- */

.hero {
  padding-top: 48px;
  padding-bottom: 56px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.hero__title {
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.06;
}

.hero__lead {
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-dim);
  max-width: 480px;
}

.hero__requirements {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  color: var(--ink-dim);
}

.hero__requirements svg {
  flex-shrink: 0;
}

.hero__cta {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

/* Apple's "Download on the App Store" badge.
   The artwork is unmodified per Apple's marketing guidelines: only its size
   changes, and the 14px clear space is a quarter of the badge height. */
.badge {
  display: inline-block;
  padding: 14px 14px 14px 0;
  margin: -14px 0 -14px 0;
}

.badge img {
  height: 56px;
  width: auto;
}

.badge:hover {
  opacity: 0.85;
  text-decoration: none;
}

/* Phone screenshot -------------------------------------------------------- */

.phone {
  align-self: center;
  width: 240px;
  margin-top: 16px;
  padding: 10px;
  border-radius: 32px;
  background: var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
}

/* The screen's radius is the frame's radius less the 10px bezel, so the two
   curves stay concentric. Same relationship at the desktop size below. */
.phone__shot {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 22px;
}

/* Cycle demo -------------------------------------------------------------- */

.cycle {
  display: flex;
  flex-direction: column;
  gap: 32px;
  margin-top: 32px;
}

.cycle__col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1 1 0;
  min-width: 0;
}

.cycle__grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 6px;
}

.cycle__cell {
  aspect-ratio: 1;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-faint);
  background-color: transparent;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: background-color 0.4s ease, border-color 0.4s ease, color 0.4s ease;
}

/* A played square inverts: light grey fill, background-coloured count.
   The repeat counts are the whole point of this grid, so they carry the
   contrast (10:1) rather than sitting dim on a dark fill. */
.cycle__cell.is-played {
  background-color: var(--cell-played);
  border-color: transparent;
  color: var(--bg);
}

.cycle__cell.is-lit {
  background-color: var(--accent);
  border-color: transparent;
}

.cycle__caption {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-dim);
}

.cycle__caption--strong {
  color: var(--ink);
}

/* Cards ------------------------------------------------------------------- */

.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 24px;
}

.card {
  padding: 22px;
  border-radius: 14px;
  background: var(--surface-soft);
  border: 1px solid var(--hairline);
}

.card--accent {
  background: var(--accent);
  border-color: var(--accent);
}

.card__title {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--ink-strong);
}

.card__body {
  font-size: 14px;
  line-height: 1.7;
  color: var(--ink-dim);
}

.card--accent .card__title {
  color: var(--bg);
}

.card--accent .card__body {
  color: rgba(11, 11, 13, 0.75);
}

/* Accent panel ------------------------------------------------------------ */

.panel {
  padding: 28px 24px;
  border-radius: var(--radius-card);
  border: 1px solid var(--accent-edge);
  background: var(--accent-wash);
}

.panel__title {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 14px;
}

.panel__body {
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink);
  margin-bottom: 18px;
  max-width: 620px;
}

.panel__link {
  font-size: 14px;
  font-weight: 700;
}

.dashlist {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink);
  margin: 0;
  padding: 0;
  list-style: none;
}

.dashlist li {
  display: flex;
  gap: 12px;
}

.dashlist li::before {
  content: "—";
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
}

/* Requirements ------------------------------------------------------------ */

.requirements {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 28px;
}

.requirement {
  padding-top: 20px;
  border-top: 2px solid var(--accent);
}

.requirement__title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--ink-strong);
}

.requirement__body {
  font-size: 14px;
  line-height: 1.7;
  color: var(--ink-dim);
}

/* Page headers (Support, Privacy) ----------------------------------------- */

.pagehead {
  padding-top: 56px;
  padding-bottom: 40px;
}

.pagehead__title {
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-bottom: 16px;
}

.pagehead__lead {
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink-dim);
  max-width: 520px;
}

.pagehead__date {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

/* Support ----------------------------------------------------------------- */

.contact-card {
  margin-top: 32px;
  padding: 28px 24px;
  border-radius: var(--radius-card);
  border: 1px solid var(--accent-edge);
  background: var(--accent-wash);
}

.contact-card__address {
  display: inline-block;
  margin-top: 14px;
  font-size: 22px;
  font-weight: 700;
  color: var(--ink-strong);
  letter-spacing: -0.01em;
}

.contact-card__address:hover {
  color: var(--accent-bright);
}

.contact-card__note {
  margin-top: 18px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--ink-dim);
}

.faq-section {
  padding-bottom: 64px;
}

.faq {
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  margin-top: 32px;
}

.faq__q {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
}

.faq__a {
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink-dim);
}

/* Privacy ----------------------------------------------------------------- */

.policy {
  display: flex;
  flex-direction: column;
  gap: 40px;
  padding-bottom: 64px;
}

.policy__toc {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 24px;
  border-radius: 14px;
  background: var(--surface-soft);
  border: 1px solid var(--hairline);
}

.policy__toc a {
  font-size: 14px;
  color: var(--ink);
}

.policy__body {
  max-width: 720px;
  display: flex;
  flex-direction: column;
  gap: 44px;
}

.policy__intro {
  font-size: 17px;
  line-height: 1.75;
  color: var(--ink);
}

.policy h2 {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin-bottom: 16px;
}

.policy p {
  font-size: 15px;
  line-height: 1.75;
  color: var(--ink);
}

.policy p + p,
.policy ul + p,
.policy p + ul {
  margin-top: 16px;
}

.policy ul {
  margin: 0;
  padding-left: 22px;
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink);
}

.policy__summary {
  padding: 28px 24px;
  border-radius: var(--radius-card);
  border: 1px solid var(--accent-edge);
  background: var(--accent-wash);
}

.policy__summary p:first-of-type {
  font-size: 17px;
  line-height: 1.7;
  font-weight: 600;
  color: var(--ink-strong);
}

.policy__email {
  font-weight: 700;
}

.policy__contact {
  padding-top: 36px;
  border-top: 1px solid var(--hairline);
}

.datalist {
  border-top: 1px solid var(--hairline);
  margin-top: 20px;
}

.datalist__row {
  display: flex;
  gap: 32px;
  padding: 14px 0;
  border-bottom: 1px solid var(--hairline);
  font-size: 15px;
}

.datalist__what {
  width: 300px;
  flex-shrink: 0;
  font-weight: 600;
}

.datalist__why {
  color: var(--ink-dim);
}

.neverlist {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px 28px;
  margin-bottom: 18px !important;
}

strong {
  font-weight: 600;
  color: var(--ink-strong);
}

/* Footer ------------------------------------------------------------------ */

.footer {
  margin-top: auto;
  border-top: 1px solid var(--hairline);
}

.footer__inner {
  padding-top: 32px;
  padding-bottom: 32px;
  display: flex;
  flex-direction: column-reverse; /* on phones the links sit above the mark */
  gap: 20px;
}

.footer__links {
  display: flex;
  gap: 28px;
  font-size: 14px;
  font-weight: 600;
}

.footer__links a {
  color: var(--ink);
}

.footer__brand {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer__brand img {
  height: 24px;
  width: auto;
  opacity: 0.85;
}

.footer__credit {
  font-size: 13px;
  color: var(--ink-dim);
}

/* Tablet ------------------------------------------------------------------ */

@media (min-width: 720px) {
  .wrap {
    padding-left: 40px;
    padding-right: 40px;
  }

  .nav__link {
    display: inline-flex;
  }

  .nav__links {
    gap: 36px;
  }

  .section {
    padding-top: 72px;
    padding-bottom: 72px;
  }

  .section__title {
    font-size: 36px;
    letter-spacing: -0.02em;
  }

  .section__title--sm {
    font-size: 24px;
  }

  .section__lead {
    font-size: 18px;
    margin-top: 20px;
  }

  .hero__title {
    font-size: 56px;
  }

  .hero__lead {
    font-size: 20px;
    line-height: 1.55;
  }

  .pagehead {
    padding-top: 72px;
    padding-bottom: 48px;
  }

  .pagehead__title {
    font-size: 56px;
  }

  .pagehead__lead {
    font-size: 20px;
  }

  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
  }

  .card {
    padding: 28px;
    border-radius: var(--radius-card);
  }

  .card__title {
    font-size: 18px;
    margin-bottom: 12px;
  }

  .requirements {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .faq {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 48px 64px;
  }

  .neverlist {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .panel,
  .contact-card,
  .policy__summary {
    padding: 32px 36px;
  }

  .panel__title {
    font-size: 32px;
  }

  .cycle {
    flex-direction: row;
    gap: 48px;
    margin-top: 52px;
  }

  .cycle__grid {
    gap: 8px;
  }
}

/* Desktop ----------------------------------------------------------------- */

@media (min-width: 1000px) {
  .wrap {
    padding-left: var(--gutter-wide);
    padding-right: var(--gutter-wide);
  }

  .nav__inner {
    padding-top: 28px;
    padding-bottom: 28px;
  }

  .nav__logo img {
    height: 72px;
  }

  .section {
    padding-top: var(--section);
    padding-bottom: var(--section);
  }

  .hero {
    flex-direction: row;
    align-items: center;
    gap: 80px;
    padding-top: 88px;
    padding-bottom: var(--section);
  }

  .hero__copy {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 28px;
  }

  .hero__title {
    font-size: 64px;
    line-height: 1.04;
  }

  .hero__cta {
    margin-top: -4px;
  }

  .phone {
    align-self: auto;
    width: 320px;
    margin-top: 0;
    padding: 14px;
    border-radius: 40px;
    box-shadow: 0 40px 90px rgba(0, 0, 0, 0.6);
  }

  .phone__shot {
    border-radius: 26px;
  }

  .cycle {
    gap: 64px;
  }

  .cards {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .pagehead {
    padding-top: 88px;
    padding-bottom: 56px;
  }

  .support-head {
    display: flex;
    gap: 80px;
    align-items: flex-start;
  }

  .support-head__copy {
    flex-grow: 1;
  }

  .contact-card {
    width: 420px;
    flex-shrink: 0;
    margin-top: 0;
    padding: 32px;
  }

  .panel {
    display: flex;
    gap: 64px;
    align-items: flex-start;
    padding: 52px 56px;
    border-radius: 20px;
  }

  .panel__main {
    flex-grow: 1;
  }

  .panel .dashlist {
    width: 300px;
    flex-shrink: 0;
  }

  .policy {
    flex-direction: row;
    gap: 72px;
    align-items: flex-start;
    padding-bottom: 72px;
  }

  .policy__toc {
    width: 220px;
    flex-shrink: 0;
    position: sticky;
    top: 32px;
    padding: 0;
    background: none;
    border: none;
  }

  .policy__body {
    flex-grow: 1;
  }

  .footer__inner {
    padding-top: 44px;
    padding-bottom: 44px;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .footer__brand img {
    height: 28px;
    align-self: flex-start;
  }

  .footer__links {
    gap: 32px;
  }
}

/* Narrow phones ------------------------------------------------------------ */

@media (max-width: 480px) {
  .datalist__row {
    flex-direction: column;
    gap: 4px;
  }

  .datalist__what {
    width: auto;
  }
}

/* The site never animates on scroll; the only motion is the cycle demo,
   which stops entirely when reduced motion is requested. */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .cycle__cell {
    transition: none;
  }
}
