/* ═══════════════════════════════════════════════════════════════
   VERSIONARY — GLASS MODAL + WALKTHROUGH SYSTEM  (v2)
   Direction 15B. Generated from "Glass Modal System.dc.html".

   REPLACES in css/v1-main.css:
     .v-modal-*      lines 4928–5083
     .onboarding-*   lines 5086–5320

   Recipe is lifted verbatim from the homepage chat-input console:
     rgba(255,255,255,.55) + blur(20px) saturate(1.2) + 28px radius
     + 0 20px 60px rgba(0,0,0,.22)

   Values are LITERAL, not var(--th-*), on purpose — see HANDOFF.md
   "Why this system does not use --th-* tokens".

   Dark variant keys off body.dark-mode (the app's real selector).
   ═══════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════
   VERSIONARY — GLASS MODAL SYSTEM  (direction 15B)
   Replaces .v-modal-* in v1-main.css (lines 4928–5083).
   Recipe lifted from the homepage chat-input console:
   rgba(255,255,255,.55) + blur(20px) saturate(1.2) + 28px radius.
   ═══════════════════════════════════════════════════════════════ */

.v-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(20,16,12,0.42);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none; align-items: center; justify-content: center;
  z-index: 99999; opacity: 0;
  transition: opacity .24s cubic-bezier(.4,0,.2,1);
  pointer-events: none;
}
.v-modal-overlay.active { opacity: 1; pointer-events: auto; }

.v-modal {
  width: 90%; max-width: 420px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(255,255,255,0.4);
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  border-radius: 28px;
  padding: 26px 26px 18px 26px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.22);
  font-family: 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  transform: scale(.97) translateY(10px);
  transition: transform .28s cubic-bezier(.34,1.35,.64,1);
}
.v-modal-overlay.active .v-modal { transform: scale(1) translateY(0); }

/* Dark surface variant — for Pipeline view, where a white glass panel
   over the dark canvas reads milky. Same geometry, inverted values. */
.dark-mode .v-modal {
  background: rgba(22,22,30,0.62);
  border-color: rgba(255,255,255,0.11);
  backdrop-filter: blur(24px) saturate(1.3);
  -webkit-backdrop-filter: blur(24px) saturate(1.3);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.07), 0 22px 60px rgba(0,0,0,.55);
}

/* ---------- Eyebrow: mono, carries context + live counts ---------- */
.v-modal-eyebrow {
  display: flex; align-items: center; gap: 8px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: rgba(0,0,0,0.4);
  margin-bottom: 12px;
}
.dark-mode .v-modal-eyebrow { color: rgba(255,255,255,0.42); }
.v-modal-eyebrow i {
  width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0;
  background: var(--vm-accent, #6c5ce7);
  box-shadow: 0 0 8px var(--vm-accent, #6c5ce7);
}

/* ---------- Type ---------- */
.v-modal-title {
  font-size: 21px; font-weight: 600; letter-spacing: -.02em;
  line-height: 1.25; color: #1a1a1a;
  margin: 0 0 9px 0;
}
.dark-mode .v-modal-title { color: rgba(255,255,255,.95); }
.v-modal-text {
  font-size: 13.5px; line-height: 1.6;
  color: rgba(0,0,0,0.55);
  margin: 0 0 20px 0;
  text-wrap: pretty;
}
.dark-mode .v-modal-text { color: rgba(255,255,255,.5); }

/* ---------- Inputs: frosted, not sunken ---------- */
.v-modal-input {
  width: 100%; box-sizing: border-box;
  padding: 12px 15px; margin-bottom: 10px;
  border: 1px solid rgba(255,255,255,0.5);
  border-radius: 14px;
  background: rgba(255,255,255,0.4);
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 13px; color: #1a1a1a;
  outline: none;
  transition: background .18s, border-color .18s, box-shadow .18s;
}
.v-modal-input::placeholder { color: rgba(0,0,0,0.32); }
.v-modal-input:focus {
  background: rgba(255,255,255,0.72);
  border-color: rgba(255,255,255,0.9);
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}
.dark-mode .v-modal-input {
  background: rgba(0,0,0,0.26);
  border-color: rgba(255,255,255,0.09);
  color: rgba(255,255,255,.9);
}
.dark-mode .v-modal-input::placeholder { color: rgba(255,255,255,0.25); }
.dark-mode .v-modal-input:focus { background: rgba(0,0,0,0.38); border-color: rgba(255,255,255,0.18); }
.v-modal-row { display: flex; gap: 9px; }
.v-modal-row .v-modal-input { min-width: 0; }

/* ---------- Data block (resume summary, matrix) ---------- */
.v-modal-meta {
  border: 1px solid rgba(255,255,255,0.5);
  border-radius: 14px;
  background: rgba(255,255,255,0.4);
  padding: 13px 15px; margin-bottom: 20px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11.5px; line-height: 1.85;
  color: rgba(0,0,0,0.5);
}
.v-modal-meta b { color: #1a1a1a; font-weight: 600; }
.dark-mode .v-modal-meta {
  background: rgba(0,0,0,0.3); border-color: rgba(255,255,255,0.07);
  color: rgba(255,255,255,.5);
}
.dark-mode .v-modal-meta b { color: rgba(255,255,255,.9); }

/* ---------- Actions: pills, sized like the send key ---------- */
.v-modal-actions { display: flex; gap: 9px; align-items: center; }
.v-modal-btn {
  height: 42px; padding: 0 22px;
  border-radius: 9999px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Geist', -apple-system, sans-serif;
  font-size: 13px; font-weight: 500;
  cursor: pointer; border: 1px solid transparent;
  white-space: nowrap;
  transition: background .16s, border-color .16s, box-shadow .16s, transform .1s;
}
.v-modal-btn:active { transform: translateY(.5px); }
.v-modal-btn.secondary {
  flex: 1;
  background: rgba(255,255,255,0.35);
  border-color: rgba(0,0,0,0.14);
  color: #1a1a1a;
}
.v-modal-btn.secondary:hover { background: rgba(255,255,255,0.6); }
.dark-mode .v-modal-btn.secondary {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.14);
  color: rgba(255,255,255,.72);
}
.dark-mode .v-modal-btn.secondary:hover { background: rgba(255,255,255,0.1); }

/* Charcoal primary — the send-key treatment */
.v-modal-btn.primary {
  flex: 1;
  background: #2E2E2E; color: #fff; font-weight: 600;
}
.v-modal-btn.primary:hover { background: #1a1a1a; box-shadow: 0 4px 16px rgba(0,0,0,.22); }
.dark-mode .v-modal-btn.primary { background: #f4f4f6; color: #14141a; }
.dark-mode .v-modal-btn.primary:hover { background: #fff; box-shadow: 0 4px 18px rgba(255,255,255,.16); }

.v-modal-btn.danger {
  flex: 1;
  background: rgba(200,42,32,.94); color: #fff; font-weight: 600;
}
.v-modal-btn.danger:hover { background: rgba(178,32,24,1); box-shadow: 0 4px 18px rgba(200,42,32,.3); }

/* Quiet variant for a low-stakes dismiss that shouldn't take half the row */
.v-modal-btn.quiet { flex: 0 0 auto; background: transparent; border-color: rgba(0,0,0,.14); color: rgba(0,0,0,.5); }
.v-modal-btn.quiet:hover { background: rgba(255,255,255,.4); color: #1a1a1a; }
.dark-mode .v-modal-btn.quiet { border-color: rgba(255,255,255,.14); color: rgba(255,255,255,.5); }
.dark-mode .v-modal-btn.quiet:hover { background: rgba(255,255,255,.07); color: rgba(255,255,255,.85); }

/* ---------- Success stripe ---------- */
.v-modal-success {
  display: none; align-items: center; gap: 8px;
  padding: 11px 14px; margin-bottom: 16px;
  border-radius: 14px;
  background: rgba(52,211,153,.16);
  border: 1px solid rgba(52,211,153,.3);
  color: #0b7a58;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11px; font-weight: 600;
}
.v-modal-success.show { display: flex; }
.dark-mode .v-modal-success { color: #6ee7b7; background: rgba(52,211,153,.12); }


/* ═══════════════════════════════════════════════════════════════
   WALKTHROUGH — same glass, 5 screens
   Replaces .onboarding-* in v1-main.css (lines 5086–5320).
   ═══════════════════════════════════════════════════════════════ */
.onboarding-overlay {
  position: fixed; inset: 0;
  background: rgba(20,16,12,0.45);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: none; align-items: center; justify-content: center;
  z-index: 99998; opacity: 0;
  transition: opacity .3s cubic-bezier(.4,0,.2,1);
  font-family: 'Geist', -apple-system, sans-serif;
}
.onboarding-overlay.active { opacity: 1; }

.onboarding-screen {
  display: none; flex-direction: column;
  width: 92%; max-width: 452px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(255,255,255,0.4);
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  border-radius: 28px;
  padding: 22px 26px 18px 26px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.22);
  opacity: 0; transform: translateY(12px) scale(.98);
  transition: opacity .3s cubic-bezier(.4,0,.2,1), transform .3s cubic-bezier(.34,1.3,.64,1);
}
.onboarding-screen.active { opacity: 1; transform: translateY(0) scale(1); }
.dark-mode .onboarding-screen {
  background: rgba(22,22,30,0.62);
  border-color: rgba(255,255,255,0.11);
  backdrop-filter: blur(24px) saturate(1.3);
  -webkit-backdrop-filter: blur(24px) saturate(1.3);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.07), 0 22px 60px rgba(0,0,0,.55);
}

/* Progress: count + segment bars, clickable */
.onboarding-track { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.onboarding-count {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11px; letter-spacing: .1em; color: rgba(0,0,0,.4);
  flex-shrink: 0;
}
.dark-mode .onboarding-count { color: rgba(255,255,255,.42); }
.onboarding-segs { flex: 1; display: flex; gap: 4px; }
.onboarding-seg {
  flex: 1; height: 3px; border-radius: 2px; cursor: pointer;
  background: rgba(0,0,0,.13);
  transition: background .35s cubic-bezier(.4,0,.2,1), box-shadow .35s;
}
.dark-mode .onboarding-seg { background: rgba(255,255,255,.1); }
.onboarding-seg.done { background: rgba(0,0,0,.42); }
.dark-mode .onboarding-seg.done { background: rgba(255,255,255,.5); }
.onboarding-seg.on {
  background: var(--ob-accent, #6c5ce7);
  box-shadow: 0 0 9px var(--ob-accent, #6c5ce7);
}

.onboarding-title {
  font-size: 22px; font-weight: 600; letter-spacing: -.02em;
  line-height: 1.22; color: #1a1a1a; margin-bottom: 9px;
}
.dark-mode .onboarding-title { color: rgba(255,255,255,.95); }
.onboarding-text {
  font-size: 13.5px; line-height: 1.6;
  color: rgba(0,0,0,.55); margin-bottom: 16px; text-wrap: pretty;
}
.dark-mode .onboarding-text { color: rgba(255,255,255,.5); }

/* Frosted data panel */
.onboarding-panel {
  border-radius: 14px;
  background: rgba(255,255,255,0.4);
  border: 1px solid rgba(255,255,255,0.5);
  padding: 12px 15px; margin-bottom: 18px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 11px; line-height: 1.85; color: rgba(0,0,0,.5);
  overflow-x: auto;
}
.onboarding-panel .oh { color: rgba(0,0,0,.32); }
.dark-mode .onboarding-panel {
  background: rgba(0,0,0,.3); border-color: rgba(255,255,255,.07); color: rgba(255,255,255,.5);
}
.dark-mode .onboarding-panel .oh { color: rgba(255,255,255,.3); }
.onboarding-stat { font-size: 19px; font-weight: 700; line-height: 1; color: #1a1a1a; }
.dark-mode .onboarding-stat { color: rgba(255,255,255,.92); }

.onboarding-sample-btn {
  display: inline-flex; align-items: center; gap: 9px;
  height: 40px; padding: 0 18px; margin-bottom: 18px;
  border-radius: 9999px;
  border: 1px solid rgba(255,255,255,0.55);
  background: rgba(255,255,255,0.4);
  color: #1a1a1a;
  font-family: 'Geist', sans-serif; font-size: 12.5px; font-weight: 500;
  text-decoration: none;
  transition: background .16s;
}
.onboarding-sample-btn:hover { background: rgba(255,255,255,0.66); color: #1a1a1a; }
.dark-mode .onboarding-sample-btn {
  background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.14); color: rgba(255,255,255,.8);
}

.onboarding-actions { display: flex; gap: 9px; align-items: center; }
.onboarding-skip {
  height: 42px; padding: 0 20px; border-radius: 9999px;
  border: 1px solid rgba(0,0,0,.14);
  background: rgba(255,255,255,.3);
  font-family: 'Geist', sans-serif; font-size: 13px; font-weight: 500;
  color: rgba(0,0,0,.5); cursor: pointer;
  transition: background .16s, color .16s;
}
.onboarding-skip:hover { background: rgba(255,255,255,.55); color: #1a1a1a; }
.dark-mode .onboarding-skip {
  background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.14); color: rgba(255,255,255,.5);
}
.dark-mode .onboarding-skip:hover { background: rgba(255,255,255,.1); color: rgba(255,255,255,.85); }
.onboarding-next {
  flex: 1; height: 42px; border-radius: 9999px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  background: #2E2E2E; color: #fff; border: none;
  font-family: 'Geist', sans-serif; font-size: 13px; font-weight: 600;
  cursor: pointer;
  transition: background .16s, box-shadow .16s;
}
.onboarding-next:hover { background: #1a1a1a; box-shadow: 0 4px 16px rgba(0,0,0,.22); }
.dark-mode .onboarding-next { background: #f4f4f6; color: #14141a; }
.dark-mode .onboarding-next:hover { background: #fff; box-shadow: 0 4px 18px rgba(255,255,255,.16); }

/* Retired but kept so any stale JS can't crash */
.onboarding-dots { display: none; }
.onboarding-arrow { position: fixed; z-index: 99999; pointer-events: none; }
/* ═══════════════════════════════════════════════════════════════
   VERSIONARY — GLASS SYSTEM ADDITIONS: validated input + brand mark
   APPEND to css/glass-modals.css. Nothing here overrides an existing
   rule; these four are new selectors only.

   Added for the Airtable base-URL modal, but written generically so any
   future validated-input or third-party-integration modal can use them.
   ═══════════════════════════════════════════════════════════════ */

/* ─────────── NEW — validated-input additions ─────────── */

/* 1. Helper line under an input. Mono, so it reads as machine guidance
      rather than prose, and it doubles as the error slot. */
.v-modal-hint {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 10.5px; line-height: 1.5;
  color: rgba(0,0,0,0.38);
  margin: 0 0 20px 0;
  transition: color .18s;
  text-align: center;
}
.dark-mode .v-modal-hint { color: rgba(255,255,255,0.32); }
.v-modal-hint svg { flex-shrink: 0; opacity: .8; }

/* 2. Invalid state — border plus a soft ring, and the hint turns. No
      layout shift, because the hint slot is always occupied. */
.v-modal-input.invalid {
  border-color: rgba(200,42,32,.75);
  background: rgba(200,42,32,.07);
  box-shadow: 0 0 0 3px rgba(200,42,32,.13);
}
.dark-mode .v-modal-input.invalid {
  border-color: rgba(248,113,113,.6);
  background: rgba(248,113,113,.09);
  box-shadow: 0 0 0 3px rgba(248,113,113,.13);
}
.v-modal-hint.error { color: #b3261e; }
.dark-mode .v-modal-hint.error { color: #fca5a5; }

/* 3. Disabled primary — the Connect button is dead until the field has
      something in it, so the empty-submit error is unreachable. */
.v-modal-btn.primary[data-disabled="1"] {
  opacity: .38; pointer-events: none;
}

/* 4. Brand mark — for third-party integrations. No container: the logo
      sits bare and centred so the service reads immediately. Its own
      colours carry it, so it needs no dark-mode variant. */
.v-modal-brand {
  display: flex; justify-content: center;
  margin: 2px 0 18px 0;
}
.v-modal-brand svg {
  width: 52px; height: 44px; display: block;
  filter: drop-shadow(0 3px 8px rgba(0,0,0,0.14));
}
