:root {
  --fondo: #ffffff;
  --inchiostro: #0b0b0c;
  --grigio: #71717a;
  --grigio-chiaro: #a1a1aa;
  --pista: rgba(255, 255, 255, 0.34);
  --cielo: #2f6bff;
  --cielo-chiaro: #8fb0ff;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: var(--fondo);
  color: var(--inchiostro);
  font-family: "Mona Sans Variable", "Mona Sans", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

.stage {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 16px;
}

.checkin {
  display: grid;
  justify-items: center;
  gap: 18px;
  min-width: min(300px, calc(100vw - 32px));
}

/* the flight line above the button */
.flight {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--grigio);
  white-space: nowrap;
}
.flight__dot { width: 3px; height: 3px; border-radius: 2px; background: var(--grigio-chiaro); opacity: 0.7; }
.flight__arrow { width: 14px; height: 9px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }

/* the wrap holds the pill and the plane that flies out of it (the plane is outside the pill, so it is not clipped) */
.wrap { position: relative; display: grid; place-items: center; }

.pill {
  position: relative;
  width: 172px;
  height: 52px;
  border-radius: 26px;
  overflow: hidden;
  isolation: isolate;
  color: #fff;
  box-shadow: 0 1px 2px rgba(11, 11, 12, 0.2), 0 10px 22px -10px rgba(11, 11, 12, 0.55);
  -webkit-tap-highlight-color: transparent;
}
.pill:focus-visible { outline: 2px solid var(--cielo); outline-offset: 3px; }
.pill__ink { position: absolute; inset: 0; background: var(--inchiostro); z-index: 0; }
.pill__fill {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--cielo) 0%, #3f78ff 70%, var(--cielo-chiaro) 100%);
  transform-origin: 0 50%;
  transform: scaleX(0);
  z-index: 1;
}
/* the runway: a dashed centre line low in the pill */
.pill__runway {
  position: absolute;
  left: 16px; right: 16px; bottom: 9px;
  height: 1.5px;
  background: repeating-linear-gradient(90deg, var(--pista) 0 7px, transparent 7px 13px);
  opacity: 0;
  z-index: 2;
}

.face {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  gap: 10px;
  white-space: nowrap;
  z-index: 3;
}
.face__label { font-size: 15.5px; font-weight: 600; font-variation-settings: "wdth" 100; letter-spacing: -0.005em; }
.face__plane { width: 18px; height: 18px; fill: #fff; }
.face--done { opacity: 0; gap: 11px; }
.done__text { display: flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 500; }
.done__text b { font-weight: 650; }
.done__sep { width: 3px; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, 0.6); }

.seats { width: 30px; height: 20px; overflow: visible; }
.seat { fill: rgba(255, 255, 255, 0.28); }
.seat--mine { fill: #fff; }

/* the plane that taxis and takes off: absolutely placed over the pill by the script */
.plane {
  position: absolute;
  left: 0; top: 0;
  width: 22px; height: 22px;
  fill: #fff;
  opacity: 0;
  pointer-events: none;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.18));
}
.shadow {
  position: absolute;
  left: 0; top: 0;
  width: 14px; height: 4px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
  filter: blur(1.5px);
  opacity: 0;
  pointer-events: none;
}

.note {
  display: flex; align-items: center; gap: 6px;
  font-size: 12.5px;
  color: var(--grigio);
  opacity: 0;
  white-space: nowrap;
}
.note svg { width: 14px; height: 14px; fill: none; stroke: var(--cielo); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

.ghost {
  position: absolute;
  left: 0; top: 0;
  width: 22px; height: 22px;
  fill: var(--inchiostro);
  stroke: #fff;
  stroke-width: 1.4;
  stroke-linejoin: round;
  opacity: 0;
  pointer-events: none;
  z-index: 10;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.2));
}

@media (max-width: 360px) {
  .flight { font-size: 11px; gap: 5px; }
}
