/*
 * interchange.travel — the channel's front door.
 *
 * Colours are the brand's own, and the only place they are written down twice:
 * `src/brand.js` has them for everything that renders, this file has them for the
 * one page that is not rendered. The selftest pins the two together.
 */
@font-face {
  font-family: "Space Grotesk";
  src: url("/fonts/SpaceGrotesk.ttf") format("truetype");
  font-weight: 300 700;
  font-display: swap;
}

:root {
  --bg: #000000;          /* the logo's own background */
  --ink: #f5f6f7;         /* the split-flap glyph */
  --flap: #1c1d1f;        /* the flap face */
  --edge: #3d3e42;        /* the flap edge */
  --red: #E30613;         /* house red — brand.js RED_HEX */
  --font: "Space Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 40px;
  padding: 56px 16px 32px;   /* 16px side gutter: no horizontal scroll on a phone */
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  text-align: center;
}

/* The mode tiles as a rule across the top, in the logo's order. */
.modes {
  position: fixed;
  inset: 0 0 auto;
  display: flex;
  height: 4px;
}
.modes span { flex: 1; }

main {
  width: 100%;
  max-width: 460px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
}

h1 { margin: 0; width: 100%; }

h1 img {
  display: block;
  width: 100%;
  height: auto;
}

.tagline {
  margin: 0;
  font-size: clamp(16px, 4.4vw, 19px);
  font-weight: 400;
  line-height: 1.45;
  color: #c7c8cc;
  letter-spacing: 0.01em;
  text-wrap: balance;
}

nav {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid var(--edge);
  border-radius: 14px;
  background: var(--flap);
  color: var(--ink);
  font-size: 17px;
  font-weight: 500;
  text-decoration: none;
  text-align: left;
  transition: border-color .15s ease, background .15s ease, transform .15s ease;
}

.link .glyph { color: var(--red); flex: none; }
.link .label { flex: 1; }

.link .handle {
  font-size: 13px;
  font-weight: 400;
  color: #8b8c92;
  white-space: nowrap;
}

.link:hover,
.link:focus-visible {
  background: #232427;
  border-color: var(--red);
  transform: translateY(-1px);
}

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

.link:active { transform: translateY(0); }

footer {
  font-size: 12.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #6b6c72;
}

@media (prefers-reduced-motion: reduce) {
  .link { transition: none; }
  .link:hover, .link:focus-visible { transform: none; }
}

/* A very small phone: the logo is wide, so let it have the width it needs. */
@media (max-width: 360px) {
  body { gap: 28px; padding-top: 40px; }
  .link { padding: 14px 15px; gap: 11px; }
  .link .handle { display: none; }
}
