/* ==========================================================================
   Forma Consulting - Airtable Starter Base (subpage-specific)
   Tokens, nav, footer, closer and buttons come from styles.css. This file
   holds only what's unique here: the narrow hero copy, the live base
   preview, the "what's inside" grid, the steps and the lead-capture panel.
   ========================================================================== */

.atpl-hero-inner { max-width: 660px; }

.atpl { background: var(--offwhite); padding: clamp(64px, 8vw, 108px) 0 clamp(90px, 10vw, 140px); }
.atpl-shell-narrow { max-width: 860px; margin: 0 auto; }

/* ---------- Step 1: email gate (comes first, drives the unlock) ---------- */
.atpl-gate { background: var(--navy); color: var(--paper-ink); border-radius: 8px; padding: clamp(30px, 4.5vw, 40px); text-align: center; }
.atpl-gate-kicker { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; }
.atpl-gate h2 { font-family: var(--font-display); font-weight: 700; font-size: 1.6rem; color: var(--offwhite); margin-bottom: 8px; }
.atpl-gate p { color: var(--paper-dim); font-size: 0.95rem; margin-bottom: 20px; max-width: 52ch; margin-left: auto; margin-right: auto; }
.atpl-form { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; max-width: 520px; margin: 0 auto; }
.atpl-form input[type=email] {
  flex: 1; min-width: 220px; border: 1.5px solid var(--hairline-dark); background: rgba(244, 241, 236, 0.06);
  color: var(--offwhite); border-radius: 7px; padding: 14px 16px; font: inherit; font-size: 0.95rem;
}
.atpl-form input[type=email]::placeholder { color: var(--paper-dim); }
.atpl-form input[type=email]:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.atpl-done { color: var(--gold); font-weight: 700; margin-top: 14px; display: none; max-width: 52ch; margin-left: auto; margin-right: auto; }
.atpl-err { color: #E8B98A; font-weight: 700; margin-top: 12px; font-size: 0.85rem; display: none; }

/* ---------- Step 2: the live base preview, locked until the gate passes ---------- */
.atpl-preview {
  margin-top: clamp(20px, 3vw, 28px);
  background: var(--white); border: 1px solid var(--hairline-light); border-radius: 8px;
  box-shadow: 0 1px 2px rgba(4, 12, 22, 0.06), 0 24px 56px -34px rgba(4, 12, 22, 0.28);
  overflow: hidden;
}
.atpl-pv-bar { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--hairline-light); background: rgba(14, 42, 71, 0.02); }
.atpl-pv-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--teal); flex: none; }
.atpl-preview.is-locked .atpl-pv-dot { background: var(--hairline-light); }
.atpl-pv-name { font-weight: 700; color: var(--navy); font-size: 0.9rem; }
.atpl-pv-copy {
  margin-left: 4px; font-weight: 700; font-size: 0.82rem; color: var(--teal);
  text-decoration: none; border-bottom: 1.5px solid transparent; transition: border-color 0.2s;
}
.atpl-pv-copy:hover { border-color: var(--teal); }
.atpl-pv-live { margin-left: auto; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--teal); }
.atpl-preview.is-locked .atpl-pv-live { color: var(--ink-soft); }
.atpl-pv-frame { position: relative; }
.atpl-embed { display: block; width: 100%; border: 0; background: transparent; }
.atpl-preview.is-locked .atpl-embed { pointer-events: none; filter: blur(2px) saturate(0.7); user-select: none; }
.atpl-lock {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  background: rgba(244, 241, 236, 0.82); text-align: center; padding: 24px;
}
.atpl-lock svg { width: 28px; height: 28px; color: var(--navy); opacity: 0.5; }
.atpl-lock p { max-width: 34ch; color: var(--ink-soft); font-size: 0.88rem; line-height: 1.5; }
.atpl-lock p b { color: var(--navy); }
.atpl-preview:not(.is-locked) .atpl-lock { display: none; }

/* ---------- What's inside ---------- */
.atpl-inside { margin-top: clamp(44px, 5vw, 60px); }
.atpl-inside h2 { font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; color: var(--navy); margin-bottom: 6px; }
.atpl-inside-sub { color: var(--ink-soft); font-size: 0.95rem; margin-bottom: 22px; max-width: 56ch; }
.atpl-igrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.atpl-icard { background: var(--white); border: 1px solid var(--hairline-light); border-radius: 8px; padding: 16px; }
.atpl-icard b { display: block; color: var(--navy); font-size: 0.9rem; margin-bottom: 4px; }
.atpl-icard span { color: var(--ink-soft); font-size: 0.8rem; line-height: 1.5; }

/* ---------- How it works ---------- */
.atpl-plug { margin-top: clamp(36px, 4vw, 48px); background: var(--white); border: 1px solid var(--hairline-light); border-radius: 8px; padding: clamp(26px, 4vw, 32px); }
.atpl-plug h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; color: var(--navy); margin-bottom: 18px; }
.atpl-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.atpl-step { position: relative; padding-top: 22px; border-top: 1px solid var(--hairline-light); }
.atpl-step-n { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--teal); margin-bottom: 10px; }
.atpl-step b { display: block; color: var(--navy); font-size: 0.95rem; margin-bottom: 4px; }
.atpl-step span { color: var(--ink-soft); font-size: 0.85rem; line-height: 1.5; }

.atpl-foot { text-align: center; color: var(--ink-soft); font-size: 0.85rem; margin-top: clamp(36px, 4vw, 48px); }
.atpl-foot b { color: var(--navy); }

@media (max-width: 780px) {
  .atpl-igrid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .atpl-igrid { grid-template-columns: 1fr; }
  .atpl-steps { grid-template-columns: 1fr; }
  .atpl-pv-bar { flex-wrap: wrap; row-gap: 8px; }
  .atpl-pv-copy { order: 3; flex: 1 1 100%; margin-left: 0; }
}
