@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

:root {
  --navy: #1b3568;
  --navy-deep: #142a54;
  --cream: #f6f4f0;
  --ink: #111827;
  --text: #475569;
  --text-dim: #64748b;
  --border: rgba(27, 53, 104, 0.14);
  --radius: 10px;
  --ui: "Poppins", system-ui, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --dur-fast: 180ms;
  --dur-slow: 720ms;
}

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

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  background: var(--cream);
  color: var(--text);
  font-family: var(--ui);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.gate {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(24px, 5vw, 48px) 20px;
  overflow: hidden;
  background:
    radial-gradient(ellipse 70% 50% at 50% 100%, rgba(27, 53, 104, 0.1), transparent 55%),
    linear-gradient(180deg, #f6f4f0 0%, #ffffff 100%);
}

.gate__inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 440px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(32px, 5vw, 44px) clamp(24px, 4vw, 36px);
  background: #fff;
  border: 1px solid var(--border);
  border-top: 3px solid var(--navy);
  box-shadow: 0 24px 64px rgba(27, 53, 104, 0.1);
}

.gate__logo {
  display: block;
  width: 72px;
  height: 72px;
  object-fit: contain;
  margin-bottom: 20px;
}

.gate__eyebrow {
  margin: 0 0 10px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--navy);
}

.gate__headline {
  margin: 0;
  font-size: clamp(1.75rem, 5vw, 2.15rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.gate__question {
  margin: 14px 0 26px;
  max-width: 34ch;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text);
}

.gate__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.btn-yes {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 50px;
  padding: 14px 24px;
  border: none;
  border-radius: var(--radius);
  font-family: var(--ui);
  font-size: 0.92rem;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  background: var(--navy);
  transition:
    transform var(--dur-fast) var(--ease-out),
    background var(--dur-fast) var(--ease-out);
}

.btn-yes:hover {
  background: var(--navy-deep);
  transform: translateY(-1px);
}

.btn-yes:active { transform: scale(0.98); }

.link-no {
  appearance: none;
  width: 100%;
  min-height: 46px;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius);
  background: transparent;
  font-family: var(--ui);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
}

.link-no:hover {
  border-color: var(--navy);
  color: var(--navy);
}

.gate__denied {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.gate__denied h2 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--ink);
}

.gate__denied p {
  margin: 0;
  max-width: 30ch;
  font-size: 0.92rem;
  color: var(--text);
}

.btn-leave {
  appearance: none;
  width: 100%;
  min-height: 46px;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius);
  background: transparent;
  font-family: var(--ui);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
  cursor: pointer;
}

.back-link {
  appearance: none;
  border: none;
  background: none;
  padding: 0;
  font-family: var(--ui);
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.gate__note {
  margin: 18px 0 0;
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.5;
}

body.is-denied .gate__eyebrow,
body.is-denied .gate__headline,
body.is-denied .gate__question,
body.is-denied .gate__actions,
body.is-denied .gate__note { display: none; }

body.is-denied .gate__denied { display: flex; }

.enter-veil {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--navy);
  transform: translateY(100%);
  transition: transform var(--dur-slow) var(--ease-out);
  pointer-events: none;
}

.enter-veil.show {
  transform: translateY(0);
  pointer-events: auto;
}

.enter-veil__text {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
}

.enter-veil__sub {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
}

@media (prefers-reduced-motion: no-preference) {
  .reveal { animation: rise 560ms var(--ease-out) both; }
  .reveal.d1 { animation-delay: 40ms; }
  .reveal.d2 { animation-delay: 140ms; }

  @keyframes rise {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
  }
}
