/* Pilot coming-soon page, Polytown Noir. Tokens from the leonardo kit (tokens.css); Hebrew falls back to Rubik. */
:root {
  --he: 'Rubik', system-ui, sans-serif;
  --display: 'Space Grotesk', var(--he);
  --sans: 'Geist', var(--he);
  --mono: 'Geist Mono', ui-monospace, monospace;
  --gutter: clamp(16px, 4vw, 56px);
  --pt-h: clamp(112px, 12.5vw, 184px);        /* the Polytown logotype's height: the dominant mark */
  --wm-h: clamp(30px, 3.3vw, 48px);           /* the Pilot wordmark's height: second, 25% under round 1c (Ronen) */
  --u: calc(var(--wm-h) * 0.139);             /* the mast's width: clear space is 2u */
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--table); color: var(--ink); }
body { font-family: var(--sans); font-size: var(--size-body); line-height: var(--lh-body); -webkit-font-smoothing: antialiased; }
img { display: block; }
a { color: inherit; }

.page {
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 560px) minmax(0, 1fr);
  grid-template-rows: auto auto 1fr auto;
  grid-template-areas: "bar hero" "brand hero" "copy hero" "foot hero";
  column-gap: clamp(24px, 4vw, 72px);
}

.bar { grid-area: bar; display: flex; align-items: center; justify-content: space-between; padding: var(--gutter) var(--gutter) 0; padding-inline-end: 0; }
.kicker { font-family: var(--mono); font-size: var(--size-mono); letter-spacing: var(--track-kicker); text-transform: uppercase; color: var(--accent);
  display: inline-flex; align-items: center; gap: .8em; }
.kicker::before { content: ""; width: 28px; height: 1px; background: var(--accent); }
.lang { font-family: var(--mono); font-size: var(--size-mono); letter-spacing: var(--track-mono); color: var(--ink-soft); background: none;
  border: 1px solid var(--line-strong); border-radius: var(--r-rail); padding: .55em 1.1em; cursor: pointer;
  transition: color var(--t-fast) var(--ease-settle), border-color var(--t-fast) var(--ease-settle); }
.lang:hover { color: var(--ink); border-color: var(--ink-faint); }
.lang:active { transform: translateY(1px); }
.lang:focus-visible, .btn:focus-visible, input:focus-visible, .polytown:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* Polytown leads, Pilot follows; both sit on plain Noir with clear space, nothing drawn behind them */
.brand { grid-area: brand; padding: calc(var(--gutter) * .5) var(--gutter) 0; padding-inline-end: 0; display: grid; gap: calc(2 * var(--u)); justify-items: start; }
.lockup { margin: 0 0 calc(var(--gutter) * .8); }
.lockup img { height: var(--pt-h); width: auto; margin-inline-start: calc(var(--pt-h) * -.07); } /* the logotype's view box has air at its left */
.pilot { margin: 0 0 calc(2 * var(--u) + .6em); padding-top: calc(2 * var(--u)); display: flex; } /* the wordmark after the intro title, with its 2u clear */
.pilot img { height: var(--wm-h); width: auto; }
[dir="rtl"] .lockup, [dir="rtl"] .pilot { direction: rtl; }
[dir="rtl"] .lockup img { margin-inline-start: 0; margin-inline-end: calc(var(--pt-h) * -.04); }

.hero { grid-area: hero; position: relative; min-height: 100svh; overflow: hidden; }
.hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
/* the field fades into the table on the side that faces the copy, so the two never touch */
.hero::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to right, var(--table) 0%, rgba(13,13,14,0) 22%), linear-gradient(to top, var(--table) 0%, rgba(13,13,14,0) 14%),
              linear-gradient(to bottom, var(--table) 0%, rgba(13,13,14,0) 12%); }
[dir="rtl"] .hero::after { background: linear-gradient(to left, var(--table) 0%, rgba(13,13,14,0) 22%), linear-gradient(to top, var(--table) 0%, rgba(13,13,14,0) 14%),
              linear-gradient(to bottom, var(--table) 0%, rgba(13,13,14,0) 12%); }

.copy { grid-area: copy; padding: 0 var(--gutter); padding-inline-end: 0; align-self: start; }
.title { font-family: var(--display); font-weight: 500; font-size: clamp(1.7rem, 2.6vw, 2.5rem); line-height: 1.05; letter-spacing: var(--track-title); margin: 0 0 .55em; text-wrap: balance; }
[lang="he"] .title { letter-spacing: 0; line-height: 1.12; }
.lede { font-weight: 300; font-size: var(--size-lede); line-height: 1.5; color: var(--ink-soft); margin: 0 0 2.2em; max-width: 46ch; text-wrap: pretty; }

.signup { margin: 0 0 2em; max-width: 480px; }
.label { display: block; font-size: var(--size-body-sm); color: var(--ink); margin-bottom: .8em; }
.field { display: flex; gap: 8px; }
.field input { flex: 1; min-width: 0; font: inherit; font-size: 1rem; color: var(--ink); background: var(--surface); border: 1px solid var(--line-strong);
  border-radius: var(--r-chip); padding: .85em 1em; text-align: start; transition: border-color var(--t-fast) var(--ease-settle); }
[dir="rtl"] .field input:placeholder-shown { direction: rtl; }
.field input::placeholder { color: var(--ink-faint); }
.field input:hover { border-color: var(--ink-faint); }
.field input[aria-invalid="true"] { border-color: var(--accent); }
.btn { font-family: var(--sans); font-weight: 600; font-size: .95rem; color: var(--accent-ink); background: var(--accent); border: 0; border-radius: var(--r-chip);
  padding: .85em 1.4em; cursor: pointer; white-space: nowrap; transition: transform var(--t-fast) var(--ease-lift), opacity var(--t-fast); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .6; cursor: progress; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.human:not(:empty) { margin-top: 10px; }
.consent { font-size: .8rem; color: var(--ink-faint); margin: .9em 0 0; line-height: 1.45; }
.status { min-height: 1.4em; font-size: var(--size-body-sm); margin: .7em 0 0; color: var(--ink); }
.status[data-kind="error"] { color: var(--accent); }
.status .preview { display: block; font-family: var(--mono); font-size: var(--size-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-faint); margin-top: .4em; }
.contact { font-size: var(--size-body-sm); color: var(--ink-soft); margin: 0; }
.contact a { color: var(--ink); text-decoration-color: var(--line-strong); text-underline-offset: .25em; }
.contact a:hover { text-decoration-color: var(--ink); }
.contact a { white-space: nowrap; }
.contact .sep { color: var(--ink-faint); margin: 0 .35em; }

.foot { grid-area: foot; padding: clamp(28px, 4vh, 48px) var(--gutter) var(--gutter); padding-inline-end: 0; }
.meta { font-family: var(--mono); font-size: var(--size-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-faint); }

/* Phones (Ronen, 22 Nov): the iso world runs from the very top of the screen, no dark band; the bar and the Polytown
   logo, centred, sit over it; the copy moves up so the email field and its button are above the fold */
@media (max-width: 860px) {
  :root { --pt-h: 86px; }
  .page { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto auto; grid-template-areas: "top" "copy" "foot"; }
  .hero { grid-area: top; min-height: 0; height: 55svh; margin: 0; z-index: 0; }
  .hero::after, [dir="rtl"] .hero::after { background: linear-gradient(to top, var(--table) 0%, rgba(13,13,14,0) 26%); }
  .bar { grid-area: top; align-self: start; position: relative; z-index: 2; padding: max(14px, env(safe-area-inset-top, 0px)) var(--gutter) 0; }
  .brand { grid-area: top; align-self: start; position: relative; z-index: 1; padding: calc(max(14px, env(safe-area-inset-top, 0px)) + 46px) var(--gutter) 0;
    justify-items: center; pointer-events: none; }
  .brand a { pointer-events: auto; }
  .lockup { margin: 0; }
  .lockup img, [dir="rtl"] .lockup img { margin: 0 0 0 calc(var(--pt-h) * .05); filter: drop-shadow(0 2px 10px rgba(13,13,14,.55)); } /* centred by its marks, not its view box */
  .copy { padding: 0 var(--gutter); margin-top: -6px; position: relative; z-index: 1; }
  .title { font-size: 1.45rem; line-height: 1.12; margin-bottom: .35em; }
  .pilot { padding-top: 6px; margin-bottom: 12px; }
  .lede { font-size: 1rem; line-height: 1.45; margin-bottom: 1.1em; }
  .label { margin-bottom: .55em; }
  .foot { padding-inline-end: var(--gutter); }
}
@media (max-width: 420px) {
  .btn { padding: .85em 1.05em; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Hebrew in the mono slots (the language toggle, the kicker) takes the body's Hebrew face, Rubik, not a system mono */
.lang:lang(he), .kicker:lang(he) { font-family: var(--he); font-weight: 400; letter-spacing: .02em; font-size: .8rem; }

/* over the iso world on phones the pills need a backing to read */
@media (max-width: 860px) {
  .lang { background: rgba(13, 13, 14, 0.72); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
}
