/* Cyberport Vertiport Reservation System — aligned to Mary's first-draft hero */

:root {
  --navy: rgb(11, 42, 74);
  --navy-muted: rgba(11, 42, 74, 0.784);
  --slate: rgb(70, 88, 104);
  --cyan: rgb(25, 161, 215);
  --cyan-hover: rgb(18, 140, 188);
  --wash: rgb(238, 242, 246);
  --white: #ffffff;
  --page-max: 1920px;
  --text-left: 88px;
  --logo-top: 48px; /* compose y_base = MT 44 + 4 */
}

@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/IBMPlexSans-Variable.woff2") format("woff2-variations"),
       url("/fonts/IBMPlexSans-Variable.woff2") format("woff2");
  font-weight: 100 700;
  font-stretch: 75% 100%;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-Variable.woff2") format("woff2-variations"),
       url("/fonts/SourceSans3-Variable.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  background: var(--wash);
  color: var(--navy);
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---- Front page hero ---- */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--wash);
  overflow: hidden;
}

.hero-photo {
  position: absolute;
  inset: 0;
  background-image: url("/assets/cyberport-photo.jpg");
  background-size: cover;
  background-position: right center;
  background-repeat: no-repeat;
  /* Horizontal alpha from compose_frontpage.py:
     t = clip((x/W - 0.20) / 0.48, 0, 1), smootherstep ease,
     alpha = 0.10 + 0.90 * ease */
  --mask: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.10) 0%,
    rgba(0, 0, 0, 0.10) 20%,
    rgba(0, 0, 0, 0.1077) 24.8%,
    rgba(0, 0, 0, 0.1521) 29.6%,
    rgba(0, 0, 0, 0.2468) 34.4%,
    rgba(0, 0, 0, 0.3857) 39.2%,
    rgba(0, 0, 0, 0.55) 44%,
    rgba(0, 0, 0, 0.7143) 48.8%,
    rgba(0, 0, 0, 0.8532) 53.6%,
    rgba(0, 0, 0, 0.9479) 58.4%,
    rgba(0, 0, 0, 0.9923) 63.2%,
    rgba(0, 0, 0, 1) 68%,
    rgba(0, 0, 0, 1) 100%
  );
  -webkit-mask-image: var(--mask);
  mask-image: var(--mask);
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}

.logo-bar {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: var(--logo-top) 24px 0 var(--text-left);
}

.logo-bar img {
  display: block;
  width: auto;
}

.logo-lscm { height: 70px; }
.logo-lasa { height: 48px; }
.logo-cp { height: 58px; }

.logo-divider {
  display: block;
  width: 1px;
  height: 54px;
  background: rgba(11, 42, 74, 0.216);
  flex: 0 0 1px;
  align-self: center;
}

.copy {
  position: absolute;
  z-index: 1;
  left: var(--text-left);
  top: 340px;
  max-width: 760px;
  padding-right: 24px;
  padding-bottom: 64px;
}

.eyebrow {
  margin: 0;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 15px;
  font-weight: 560;
  font-stretch: 100%;
  line-height: 1.2;
  letter-spacing: 0;
  color: var(--navy-muted);
  text-transform: none;
}

.title {
  margin: 28px 0 0;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 64px;
  font-weight: 620;
  font-stretch: 100%;
  line-height: 73px; /* compose: int(ascent * 1.12) between line tops at 64px */
  color: var(--navy);
}

.title span {
  display: block;
}

.rule {
  display: block;
  width: 220px;
  height: 4px;
  margin: 22px 0 0;
  border: 0;
  border-radius: 2px;
  background: var(--cyan);
}

.subtitle {
  margin: 28px 0 0;
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  font-size: 22px;
  font-weight: 400;
  line-height: 1.4;
  color: var(--slate);
  max-width: 34em;
}

.cta {
  display: inline-block;
  margin-top: 36px;
  padding: 14px 28px;
  border: 0;
  border-radius: 6px;
  background: var(--cyan);
  color: var(--white);
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 17px;
  font-weight: 560;
  font-stretch: 100%;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}

.cta:hover,
.cta:focus-visible {
  background: var(--cyan-hover);
}

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

/* ---- Inner pages (apply / confirmation) ---- */

.page {
  min-height: 100vh;
  background: var(--wash);
}

.page-main {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 0 auto;
  padding: 48px 88px 96px;
}

.page-kicker {
  margin: 0;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 15px;
  font-weight: 560;
  color: var(--navy-muted);
}

.page-title {
  margin: 16px 0 0;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 40px;
  font-weight: 620;
  line-height: 1.2;
  color: var(--navy);
}

.page-lead {
  margin: 16px 0 0;
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.5;
  color: var(--slate);
}

.page-main .rule {
  margin-top: 20px;
}

form.application {
  margin-top: 36px;
}

.field {
  margin: 0 0 20px;
}

.field label {
  display: block;
  margin: 0 0 6px;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 14px;
  font-weight: 560;
  color: var(--navy);
}

.field .hint {
  display: block;
  margin: 0 0 6px;
  font-size: 13px;
  color: var(--slate);
}

.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field input[type="date"],
.field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(11, 42, 74, 0.22);
  border-radius: 6px;
  background: var(--white);
  color: var(--navy);
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.4;
}

.field textarea {
  min-height: 120px;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid var(--cyan);
  outline-offset: 1px;
  border-color: var(--cyan);
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  margin-top: 28px;
}

button.cta {
  appearance: none;
  -webkit-appearance: none;
}

.back-link {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 15px;
  font-weight: 560;
  color: var(--navy);
  text-decoration: none;
  border-bottom: 1px solid rgba(11, 42, 74, 0.35);
}

.back-link:hover,
.back-link:focus-visible {
  color: var(--cyan-hover);
  border-bottom-color: var(--cyan);
}

.summary {
  margin-top: 32px;
  padding: 24px;
  background: var(--white);
  border-radius: 8px;
  border: 1px solid rgba(11, 42, 74, 0.12);
}

.summary dl {
  margin: 0;
}

.summary dt {
  margin-top: 14px;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 13px;
  font-weight: 560;
  color: var(--slate);
}

.summary dt:first-child {
  margin-top: 0;
}

.summary dd {
  margin: 4px 0 0;
  font-size: 16px;
  color: var(--navy);
  white-space: pre-wrap;
}

.note {
  margin-top: 28px;
  font-size: 14px;
  color: var(--slate);
}

@media (max-width: 900px) {
  .logo-bar {
    padding: 28px 24px 0;
    flex-wrap: wrap;
    gap: 14px;
  }

  .logo-lscm { height: 52px; }
  .logo-lasa { height: 36px; }
  .logo-cp { height: 44px; }
  .logo-divider { height: 40px; }

  .copy {
    position: relative;
    left: auto;
    top: auto;
    margin-top: 72px;
    padding: 0 24px 72px;
    max-width: 40rem;
  }

  .title {
    font-size: 40px;
    line-height: 1.15;
  }

  .subtitle { font-size: 18px; }

  .page-main {
    padding: 32px 24px 72px;
  }

  .page-title { font-size: 32px; }
}

/* ---- Navigation, choice, full form, staff ---- */

.site-nav {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 22px;
  padding: 20px 24px 0 var(--text-left);
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 14px;
  font-weight: 560;
}

.site-nav a {
  color: var(--navy);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--cyan-hover);
  border-bottom-color: var(--cyan);
}

.nav-user {
  color: var(--slate);
  font-weight: 400;
}

.nav-form { display: inline; margin: 0; }

button.linkish {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 14px;
  font-weight: 560;
  color: var(--navy);
  cursor: pointer;
  border-bottom: 1px solid rgba(11, 42, 74, 0.35);
}

button.linkish:hover { color: var(--cyan-hover); border-bottom-color: var(--cyan); }

.page-main-wide { max-width: 960px; }

.choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 36px;
}

.choice-card {
  background: var(--white);
  border: 1px solid rgba(11, 42, 74, 0.12);
  border-radius: 8px;
  padding: 28px 24px 32px;
}

.choice-card h2 {
  margin: 0;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 22px;
  font-weight: 620;
  color: var(--navy);
}

.choice-card p { margin: 12px 0 0; color: var(--slate); line-height: 1.5; }

.choice-card .cta { margin-top: 24px; }

.choice-alt { font-size: 15px; }

.alert {
  margin-top: 24px;
  padding: 16px 18px;
  background: #fff4f0;
  border: 1px solid rgba(160, 40, 20, 0.25);
  border-radius: 8px;
  color: #7a1f12;
}

.alert ul { margin: 8px 0 0; padding-left: 1.2em; }

.form-section {
  margin-top: 40px;
  padding-top: 8px;
}

.section-title {
  margin: 0 0 8px;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 22px;
  font-weight: 620;
  color: var(--navy);
}

.sub-title {
  margin: 28px 0 8px;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 17px;
  font-weight: 600;
  color: var(--navy);
}

.section-lead {
  margin: 0 0 20px;
  color: var(--slate);
  line-height: 1.5;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px 20px;
}

.path-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px 20px;
}

.repeat-card {
  margin: 0 0 20px;
  padding: 16px 16px 8px;
  border: 1px solid rgba(11, 42, 74, 0.12);
  border-radius: 8px;
  background: var(--white);
}

.repeat-card legend {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 14px;
  font-weight: 560;
  padding: 0 6px;
}

.choice-set {
  margin: 0 0 20px;
  padding: 0;
  border: 0;
}

.choice-set legend {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 14px;
  font-weight: 560;
  color: var(--navy);
  margin-bottom: 8px;
}

.check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 8px;
  font-size: 15px;
  line-height: 1.4;
  color: var(--navy);
}

.check input { margin-top: 4px; }

.check.agree { margin: 20px 0; font-weight: 560; }

.cta.secondary {
  background: transparent;
  color: var(--navy);
  border: 1px solid rgba(11, 42, 74, 0.35);
  margin-top: 8px;
}

.cta.secondary:hover,
.cta.secondary:focus-visible {
  background: rgba(25, 161, 215, 0.08);
  color: var(--navy);
}

.field input[type="password"],
.field input[type="file"],
.field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(11, 42, 74, 0.22);
  border-radius: 6px;
  background: var(--white);
  color: var(--navy);
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.4;
}

.field input[type="file"] { padding: 8px 0; border: 0; background: transparent; }

.account-banner {
  padding: 20px 22px 24px;
  background: var(--white);
  border-radius: 8px;
  border: 1px solid rgba(11, 42, 74, 0.12);
}

.undertaking-text {
  background: var(--white);
  border: 1px solid rgba(11, 42, 74, 0.12);
  border-radius: 8px;
  padding: 20px 22px;
  max-height: 420px;
  overflow: auto;
}

.undertaking-text h3 { margin: 0 0 12px; font-size: 17px; }
.clause { margin: 0 0 12px; font-size: 15px; line-height: 1.5; color: var(--navy); }
.clause-list { margin: 0 0 12px 1.2em; font-size: 15px; line-height: 1.5; }
.agree-lead { font-weight: 560; }

.data-table {
  width: 100%;
  margin-top: 28px;
  border-collapse: collapse;
  background: var(--white);
  border-radius: 8px;
  overflow: hidden;
  font-size: 15px;
}

.data-table th,
.data-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(11, 42, 74, 0.1);
  vertical-align: top;
}

.data-table th {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 13px;
  font-weight: 560;
  color: var(--slate);
  background: rgba(11, 42, 74, 0.04);
}

.data-table a { color: var(--cyan-hover); }

.plain-list { margin: 0; padding-left: 1.2em; line-height: 1.5; }

.summary + .summary { margin-top: 20px; }

.summary .section-title { margin-bottom: 12px; }

@media (max-width: 900px) {
  .site-nav { padding-left: 24px; }
}
