/* Tokens: see DESIGN.md */
:root {
  --color-jet: #000000;
  --color-coal: #141414;
  --color-shade: #1f1f1f;
  --color-iron: #292929;
  --color-smoke: #3a3a3a;
  --color-cinder: #474747;
  --color-pewter: #a9b2bc;
  --color-silver: #cccccc;
  --color-white: #ffffff;
  --color-cobalt: #0055ff;
  --color-blue-500: #3080ff;
  --color-blue-600: #155dfc;

  /* LP background: the exact backdrop of the android video */
  --color-stage: #121309;

  --color-background: var(--color-stage);
  --color-foreground: var(--color-white);
  --color-primary: var(--color-white);
  --color-primary-hover: var(--color-silver);
  --color-secondary: rgb(255 255 255 / .6);
  --color-muted: rgb(255 255 255 / .55);
  --color-accent: var(--color-cobalt);
  --color-accent-hover: var(--color-blue-600);
  --color-accent-text: var(--color-blue-500);
  --color-soft: var(--color-smoke);
  --color-soft-hover: var(--color-cinder);
  --color-on-primary: var(--color-jet);
  --color-on-accent: var(--color-white);

  --font-sans: 'Geist', 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --text-xs: .75rem;
  --text-sm: .875rem;
  --text-base: 1rem;
  --text-xl: 1.25rem;
  --text-caption: .8125rem;
  --leading-body: 1.5rem;
  --leading-ui: 1.25rem;
  --tracking-label: .02em;

  --spacing: .25rem;
  --container: 80rem;
  --gutter: 1rem;
  --header-h: 4rem;
  --btn-h: 2rem;

  --radius: 0px;
  --ease-default: cubic-bezier(.4, 0, .2, 1);
  --ease-settle: cubic-bezier(.22, 1, .36, 1);
  --duration: .15s;

  /* shared inline edge: 1280px container + gutter */
  --edge: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
}
@media (min-width: 1024px) { :root { --gutter: 1.5rem; } }

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  background: var(--color-background);
  color: var(--color-foreground);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* header / footer */
.site-header, .site-footer {
  position: absolute; left: 0; right: 0; z-index: 3;
  display: flex; align-items: center; justify-content: space-between; gap: calc(var(--spacing) * 4);
  height: var(--header-h);
  padding-inline: var(--edge);
}
.site-header { top: 0; }
.site-footer { bottom: 0; }

.label {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 500;
  line-height: var(--leading-body);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-secondary);
}

/* ---------- brand: eye mark (blinks, iris follows the pointer) + wordmark ---------- */
.brand {
  --icon-h: 26px;
  --brand-gap: 10px;
  display: inline-flex; align-items: center; gap: var(--brand-gap);
  text-decoration: none;
}
.brand-mark {
  display: block;
  width: var(--icon-h); height: var(--icon-h);   /* square box, 512 x 512 */
  overflow: visible;
}
/* blink every 2s: the almond squashes into the line where the two colors meet */
.brand-mark .eye-lid {
  transform-box: view-box;
  transform-origin: 256px 256px;
  animation: blink 2s ease-in-out infinite;
}
@keyframes blink {
  0%, 86%, 100% { transform: scaleY(1); }
  92% { transform: scaleY(.04); }
}
@media (prefers-reduced-motion: reduce) { .brand-mark .eye-lid { animation: none; } }
.brand-name {
  font-family: var(--font-sans);
  font-size: 1.1875rem;   /* 19 */
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.02em;
  color: #ffffff;
}
@media (min-width: 768px) {
  .brand { --icon-h: 30px; --brand-gap: 12px; }
  .brand-name { font-size: 1.375rem; }   /* 22 */
}

/* ---------- media (android video) ---------- */
.media {
  position: relative;
  aspect-ratio: 9 / 16;
  /* feathered edges so the frame melts into the page */
  -webkit-mask-image:
    linear-gradient(to right, transparent 0, #000 14%, #000 86%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 7%, #000 86%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(to right, transparent 0, #000 14%, #000 86%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 7%, #000 86%, transparent 100%);
  mask-composite: intersect;
}
.media-video, .media-still, .media-noscript {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.media-still { opacity: 0; transition: opacity .4s var(--ease-default); }
.media.is-still .media-still { opacity: 1; }
.media.is-still .media-video { visibility: hidden; }

/* ---------- hero: mobile first, media on top, copy below ---------- */
.hero {
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; align-items: center;
  padding-top: calc(var(--header-h) - 1rem);   /* clears the header logo */
}
.hero .media {
  height: 58svh;
  max-width: 100%;
  flex-shrink: 0;
}
.copy {
  position: relative; z-index: 1;
  width: 100%;
  max-width: calc(34rem + var(--gutter) * 2);
  margin-top: -2svh;
  padding: 0 var(--gutter) calc(var(--spacing) * 6);
  text-align: left;
}

.heading {
  font-size: var(--text-xl);      /* 20 */
  font-weight: 500;
  line-height: 1.75rem;
  text-wrap: balance;
}
.lead {
  margin-top: calc(var(--spacing) * 3);
  font-size: var(--text-base);    /* 16 */
  line-height: 1.75rem;
  color: var(--color-secondary);
  text-wrap: pretty;
}
.actions {
  margin-top: calc(var(--spacing) * 6);
  display: flex; flex-direction: column; align-items: flex-start; gap: calc(var(--spacing) * 3);
}
.caption {
  font-size: var(--text-caption);
  line-height: 1.625;
  color: var(--color-muted);
}

/* stacked layout: footer flows after the content */
.site-footer { position: static; }

/* ---------- side layout: landscape screens from 768px ---------- */
/* Two columns inside the 1280px container. The video is centred in the right
   column and slightly taller than the screen (106%) so the head and chip fill it. */
@media (min-width: 768px) and (min-aspect-ratio: 1 / 1) {
  .label { font-size: var(--text-sm); }
  .site-footer { position: absolute; }

  .hero {
    height: 100vh; height: 100svh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: calc(var(--gutter) * 2);
    align-items: center;
    padding-block: 0;
    padding-inline: var(--edge);
    overflow: hidden;
  }
  .copy {
    grid-column: 1; grid-row: 1;
    max-width: 34rem;
    margin: 0;
    padding: 0;
  }
  .hero .media {
    grid-column: 2; grid-row: 1;
    justify-self: center; align-self: start;
    height: 106svh;
    margin-top: -3svh;
    max-width: none;
    -webkit-mask-image:
      linear-gradient(to right, transparent 0, #000 14%, #000 86%, transparent 100%),
      linear-gradient(to bottom, transparent 0, #000 4%, #000 91%, transparent 100%);
    mask-image:
      linear-gradient(to right, transparent 0, #000 14%, #000 86%, transparent 100%),
      linear-gradient(to bottom, transparent 0, #000 4%, #000 91%, transparent 100%);
  }
}

/* ---------- button ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: calc(var(--spacing) * 1.5);
  height: var(--btn-h);
  padding: 5px 13px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 500;
  line-height: var(--leading-ui);
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--duration) var(--ease-default), background-color var(--duration) var(--ease-default);
}
.btn:has(> [data-arrow]:last-child) { padding-right: 5px; }
.btn [data-arrow] { width: 16px; height: 16px; transition: transform var(--duration) var(--ease-default); }
.btn:hover [data-arrow] { transform: translateX(2px); }
.btn:focus-visible { outline: 2px solid var(--color-accent-text); outline-offset: 2px; }
.btn-accent { background: var(--color-accent); color: var(--color-on-accent); }
.btn-accent:hover { background: var(--color-accent-hover); }

/* ---------- entrance ---------- */
.reveal { opacity: 0; transform: translateY(12px); animation: rise .9s var(--ease-settle) forwards; animation-delay: var(--d, 0s); }
@keyframes rise { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .reveal { animation-duration: .01s; }
}
