/* Corporate Aviation Management — invite-only splash.
   Single card, centered. Dark blue canvas + subtle grid + soft
   accent glow. Mobile-first; 3 breakpoints (1024 / 768 / 640). */

:root {
  --bg: #080914;
  --bg-2: #0a0c1b;
  --card-border: rgba(120, 140, 210, 0.18);
  --chip: #161a32;
  --chip-border: rgba(120, 140, 210, 0.22);
  --accent: #6aa8ff;
  --text-primary: #e5ecff;
  --text-secondary: #9aa6c4;
  --text-muted: #626c89;
  --font-heading: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

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

html { overflow-x: hidden; -webkit-font-smoothing: antialiased; }

/* Mandatory backstops per ~/arkona/packages/cloudflare-domain-app-claude.md */
.mono, code, pre { font-family: var(--font-mono); overflow-wrap: anywhere; }
.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.table { min-width: 480px; }

/* [hidden] backstop — display:flex on .access-form etc. would otherwise
   shadow the UA stylesheet's [hidden]{display:none} (lower specificity). */
[hidden] { display: none !important; }

body {
  background:
    radial-gradient(900px 500px at 50% -10%, rgba(90,130,255,0.22), transparent 65%),
    radial-gradient(700px 500px at 85% 95%, rgba(140,110,255,0.18), transparent 70%),
    linear-gradient(180deg, var(--bg-2), var(--bg));
  background-attachment: fixed;
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: 16px; line-height: 1.5;
  min-height: 100svh;
  min-height: 100vh;
  position: relative;
}

/* Subtle grid lines, masked off at the edges so they feel painted, not tiled. */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none; z-index: 0;
  background-image:
    linear-gradient(rgba(120,140,210,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(120,140,210,0.06) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, rgba(0,0,0,.9), transparent 85%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, rgba(0,0,0,.9), transparent 85%);
  opacity: 0.7;
}

/* ─── Splash layout ─────────────────────────── */

.splash {
  position: relative; z-index: 1;
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: 32px 20px;
}

.card {
  width: 100%;
  max-width: 520px;
  padding: clamp(28px, 5vw, 44px) clamp(22px, 5vw, 40px) clamp(32px, 5vw, 44px);
  background: linear-gradient(180deg, rgba(22,26,52,0.85), rgba(14,17,38,0.85));
  border: 1px solid var(--card-border);
  border-radius: 22px;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.03) inset,
    0 30px 80px -30px rgba(10,18,50,0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  text-align: center;
}

/* Top label: C · A · M   L L C */
.eyebrow {
  display: inline-flex; gap: 4px; align-items: center; justify-content: center;
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.42em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 24px;
}
.eyebrow .dot { opacity: 0.6; }

/* Logo block */
.logo {
  width: 160px; height: 160px;
  margin: 0 auto 26px;
  filter: drop-shadow(0 14px 40px rgba(85, 120, 240, 0.35));
}
.logo svg { width: 100%; height: 100%; display: block; }

h1 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  font-weight: 700;
  font-size: clamp(26px, 4.6vw, 34px);
  line-height: 1.15;
  letter-spacing: -0.02em;
}
h1 .accent {
  background: linear-gradient(90deg, #93b5ff 0%, #6f9dff 55%, #4a7dff 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}

.lede {
  color: var(--text-secondary);
  margin: 18px auto 28px;
  max-width: 42ch;
  font-size: clamp(14px, 1.8vw, 16px);
}

/* AVIATION MRO pill */
.pill {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.22em;
  color: var(--accent);
  background: rgba(110, 150, 255, 0.10);
  border: 1px solid rgba(110, 150, 255, 0.25);
  padding: 8px 18px;
  border-radius: 999px;
  margin-bottom: 28px;
}

/* Feature chips */
.chips {
  list-style: none;
  display: flex; flex-direction: column; gap: 10px;
  margin: 0 auto 32px;
  max-width: 460px;
}
.chip {
  display: flex; align-items: center; gap: 10px;
  text-align: left;
  padding: 11px 18px;
  background: var(--chip);
  border: 1px solid var(--chip-border);
  border-radius: 999px;
  color: var(--text-secondary);
  font-size: 14px;
}
.chip strong { color: var(--text-primary); font-weight: 600; }
.chip svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--accent); }
.chip:nth-child(1) svg { color: #8ea8ff; }
.chip:nth-child(2) svg { color: #a8b8ff; }
.chip:nth-child(3) svg { color: #7ab0ff; }

/* CTA */
.enter {
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%; max-width: 380px;
  padding: 14px 28px;
  background: linear-gradient(90deg, #7da4ff, #a295ff);
  color: #0b1026;
  font-family: var(--font-heading);
  font-weight: 600; font-size: 17px;
  text-decoration: none;
  border: none;
  border-radius: 14px;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.35) inset,
    0 10px 30px -10px rgba(130, 150, 255, 0.6);
  transition: transform .08s ease, filter .12s ease;
}
.enter:hover { filter: brightness(1.05); }
.enter:active { transform: translateY(1px); }

/* Secondary CTA */
.request-link {
  display: inline-block;
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-muted);
  text-decoration: none;
  transition: color .12s ease;
}
.request-link:hover { color: var(--accent); }

/* ─── Access-request form (/request/) ───────── */

.request-title {
  font-size: clamp(22px, 3.6vw, 28px);
  margin-bottom: 12px;
}

.access-form {
  display: flex; flex-direction: column; gap: 14px;
  text-align: left;
  margin-top: 10px;
}
.field { display: flex; flex-direction: column; gap: 6px; }
.field-label {
  font-size: 11px; font-family: var(--font-mono);
  color: var(--text-muted); letter-spacing: 0.08em;
  text-transform: uppercase;
}
.field input,
.field textarea,
.field select {
  font-family: inherit; font-size: 15px;
  background: rgba(10,13,32,0.6);
  color: var(--text-primary);
  border: 1px solid var(--chip-border);
  border-radius: 10px;
  padding: 11px 14px;
  transition: border-color .12s ease, background .12s ease;
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
}
.field select {
  background-image: linear-gradient(45deg, transparent 50%, var(--text-muted) 50%),
                    linear-gradient(135deg, var(--text-muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
  padding-right: 32px;
  cursor: pointer;
}
.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: var(--accent);
  background-color: rgba(14,18,48,0.8);
}
.field textarea { resize: vertical; min-height: 96px; }

/* Submit button inside the form — width-aligned with the inputs. */
.access-form .enter { max-width: none; margin-top: 6px; }

/* Success state (replaces the form on submit). */
.access-success {
  text-align: center;
  padding: 28px 8px 12px;
}
.access-success .success-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(122,200,255,0.18), rgba(140,110,255,0.18));
  border: 1px solid rgba(140,180,255,0.35);
  color: var(--accent);
  font-size: 28px; font-weight: 700;
  margin-bottom: 14px;
}
.access-success h3 {
  color: var(--accent);
  margin: 0 0 8px;
  font-family: var(--font-heading);
  font-size: 18px;
}
.access-success p {
  color: var(--text-secondary);
  max-width: 38ch;
  margin: 0 auto;
  font-size: 14px;
}

/* ─── Portal (Sign In | Register tabs) ──────── */

.portal-card { padding-top: clamp(24px, 4vw, 36px); }
.portal-header { text-align: center; margin-bottom: 18px; }
.brand-row {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-heading); font-weight: 700; color: var(--text-primary);
  margin-bottom: 8px;
}
.brand-row .brand-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 7px;
  background: linear-gradient(135deg, var(--accent), #7c5cff);
  color: #fff; font-size: 11px; letter-spacing: 0.5px;
}
.brand-row .brand-name { font-size: 14px; }
.portal-lede { margin: 0 auto; max-width: 36ch; font-size: 13px; }

.tabs {
  display: flex; gap: 4px;
  border-bottom: 1px solid var(--card-border);
  margin: 8px 0 18px;
}
.tab {
  flex: 1;
  background: transparent; border: none;
  color: var(--text-muted);
  font-family: inherit; font-size: 14px; font-weight: 600;
  padding: 12px 8px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color .12s ease, border-color .12s ease;
}
.tab:hover { color: var(--text-secondary); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }

/* Prominent "no invite? request →" banner under the tabs. */
.request-banner {
  display: flex; align-items: center; justify-content: center;
  text-align: center;
  margin: 0 0 16px;
  padding: 10px 14px;
  background: rgba(110, 150, 255, 0.08);
  border: 1px dashed rgba(110, 150, 255, 0.35);
  border-radius: 10px;
  color: var(--text-secondary);
  font-size: 13px;
  text-decoration: none;
  transition: background .12s ease, border-color .12s ease, color .12s ease;
}
.request-banner strong { color: var(--text-primary); font-weight: 600; }
.request-banner:hover {
  background: rgba(110, 150, 255, 0.14);
  border-color: var(--accent);
  color: var(--accent);
  opacity: 1;
}
.request-banner:hover strong { color: var(--accent); }

.portal-form { margin-top: 0; }
.portal-form .hint {
  color: var(--text-muted);
  font-size: 13px;
  margin: 0 0 6px;
  line-height: 1.5;
}

/* Security model panel — same shape as the benefits grid below /request/. */
.security-model {
  margin-top: 24px;
  padding: 16px 18px;
  background: rgba(14,18,48,0.5);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  text-align: left;
}
.security-model h4 {
  font-size: 12px; font-family: var(--font-mono);
  color: var(--text-muted); letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 10px;
}
.security-model ul {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
}
.security-model li {
  font-size: 13px; color: var(--text-secondary);
  display: flex; align-items: center; gap: 8px;
}

@media (max-width: 640px) {
  .security-model ul { grid-template-columns: 1fr; }
  .portal-form .hint { font-size: 12px; }
}

/* "What you'll get" panel below the form. */
.benefits {
  margin-top: 24px;
  padding: 16px 18px;
  background: rgba(14,18,48,0.5);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  text-align: left;
}
.benefits h4 {
  font-size: 12px; font-family: var(--font-mono);
  color: var(--text-muted); letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 10px;
}
.benefits ul {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
}
.benefits li {
  font-size: 13px; color: var(--text-secondary);
  display: flex; align-items: center; gap: 8px;
}
.dot-bullet {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); flex-shrink: 0;
}

/* ─── Responsive ────────────────────────────── */

@media (max-width: 768px) {
  .splash { padding: 24px 14px; }
  .logo { width: 140px; height: 140px; margin-bottom: 22px; }
  .eyebrow { letter-spacing: 0.36em; font-size: 10px; }
  .chips { max-width: 100%; }
  .enter { font-size: 16px; padding: 13px 24px; }
}
@media (max-width: 640px) {
  body::before { background-size: 40px 40px; }
  .card { padding: 26px 18px 28px; border-radius: 18px; }
  .logo { width: 124px; height: 124px; }
  .chip { font-size: 13px; padding: 10px 14px; }
  .benefits ul { grid-template-columns: 1fr; }
}
