/* ============================================================
   PassBy Resources — Shared components (header, footer, assistant)
   Brand-guide compliant: blue only on buttons; gradient = hero band
   only; icons & labels white/grey; real logo image; 15px radius.
   ============================================================ */

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  height: var(--nav-h); display: flex; align-items: center;
  background: rgba(24,24,24,.72);
  backdrop-filter: saturate(140%) blur(16px);
  -webkit-backdrop-filter: saturate(140%) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background .3s var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--border); background: rgba(22,22,22,.92); }
.site-header .inner { display: flex; align-items: center; gap: 30px; width: 100%; max-width: var(--maxw-wide); margin-inline: auto; padding-inline: 32px; }
.brand { display: flex; align-items: center; gap: 12px; flex: none; }
.brand img { height: 26px; width: auto; flex: none; }
.brand .sub { font-family: var(--mono); font-size: .62rem; letter-spacing: .1em; text-transform: lowercase; color: var(--text-3); border-left: 1px solid var(--border); padding-left: 11px; line-height: 1.15; }
.nav { display: flex; align-items: center; gap: 4px; margin-left: 6px; }
.nav a { font-size: .9rem; font-weight: 500; color: var(--text-2); padding: 8px 14px; border-radius: 9px; transition: color .2s, background .2s; }
.nav a:hover { color: #fff; background: rgba(255,255,255,.04); }
.nav a.active { color: #fff; }
.nav a.active::after { content:""; display:block; height:2px; border-radius:2px; background: var(--text); margin-top: 5px; }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 16px; }
.header-actions .back { font-size: .85rem; color: var(--text-3); display: inline-flex; align-items: center; gap: 6px; }
.header-actions .back:hover { color: #fff; }
.nav-toggle { display: none; background: none; border: 1px solid var(--border); border-radius: 10px; width: 42px; height: 42px; color: #fff; }

/* ---------- Mega menu ---------- */
.nav-item { position: relative; display: flex; align-items: center; }
.nav-trig { background: none; border: 0; color: var(--text-2); font: 500 .9rem/1 var(--font); cursor: pointer; padding: 8px 12px; border-radius: 9px; display: inline-flex; align-items: center; gap: 6px; transition: color .2s, background .2s; }
.nav-trig:hover, .nav-item:hover .nav-trig { color: #fff; background: rgba(255,255,255,.04); }
.nav-trig .chev { width: 12px; height: 12px; transition: transform .25s var(--ease); }
.nav-item:hover .nav-trig .chev { transform: rotate(180deg); }
.mega { position: absolute; top: calc(100% + 16px); left: 0; transform: translateY(8px);
  width: min(680px, 86vw); background: rgba(22,22,24,.98); backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid var(--border); border-radius: 18px; padding: 16px; box-shadow: 0 40px 100px -40px rgba(0,0,0,.9);
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 14px; opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .22s var(--ease), transform .22s var(--ease); z-index: 60; }
.nav-item:hover .mega, .mega:hover, .nav-item:focus-within .mega { opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0); }
.mega::before { content: ""; position: absolute; top: -16px; left: 0; right: 0; height: 16px; }
.mega-list { display: grid; gap: 2px; }
.nav .mega a { padding: 0; border-radius: 12px; background: none; }
.mega-link { display: flex; gap: 13px; padding: 12px; border-radius: 12px; transition: background .2s var(--ease); align-items: flex-start; }
.nav .mega a.mega-link:hover { background: rgba(255,255,255,.05); color: var(--text-2); }
.mega-ic { width: 38px; height: 38px; border-radius: 10px; flex: none; display: grid; place-items: center; background: var(--deep); border: 1px solid var(--border); color: #fff; }
.mega-ic svg { width: 19px; height: 19px; stroke: currentColor; fill: none; stroke-width: 1.6; }
.mega-tx { display: flex; flex-direction: column; }
.mega-link .mt { font-size: .92rem; font-weight: 600; color: #fff; }
.mega-link .md { font-size: .78rem; color: var(--text-3); margin-top: 2px; line-height: 1.4; }
.mega-new { border-radius: 14px; padding: 16px; position: relative; overflow: hidden;
  background: linear-gradient(145deg, rgba(26,94,169,.28), rgba(58,47,110,.22)); border: 1px solid rgba(120,160,255,.2); }
.mega-new .tag { font-size: .62rem; text-transform: uppercase; letter-spacing: .12em; color: #8fb8ff; font-weight: 700; }
.mega-new h4 { margin: 10px 0 6px; font-size: 1rem; color: #fff; }
.mega-new p { margin: 0 0 14px; font-size: .8rem; color: var(--text-2); font-weight: 300; line-height: 1.5; }
.nav .mega a.mn-link { font-size: .78rem; font-weight: 600; color: #fff; padding: 0; }
.mega-new .mn-link .arw { display: inline-block; transition: transform .2s var(--ease); }
.mega-new:hover .mn-link .arw { transform: translateX(4px); }

@media (max-width: 960px) {
  .nav { position: fixed; inset: var(--nav-h) 0 auto 0; flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--bg-alt); border-bottom: 1px solid var(--border); padding: 14px 22px 22px; margin: 0;
    transform: translateY(-130%); transition: transform .35s var(--ease); max-height: calc(100vh - var(--nav-h)); overflow-y: auto; }
  .nav.open { transform: none; }
  .nav a { padding: 13px 10px; }
  .nav-item { flex-direction: column; align-items: stretch; }
  .nav-trig { width: 100%; justify-content: space-between; padding: 13px 10px; border-radius: 0; }
  .nav-item:hover .nav-trig .chev { transform: none; }
  .mega { position: static; width: auto; opacity: 1; visibility: visible; pointer-events: auto; transform: none;
    display: block; background: none; border: 0; box-shadow: none; padding: 0 0 10px; backdrop-filter: none; }
  .mega-new { display: none; }
  .nav .mega a.mega-link { padding: 10px; }
  /* declutter the mobile bar: drop the passby.com link and the "resources" sublabel */
  .header-actions .back { display: none; }
  .brand .sub { display: none; }
  .header-actions { gap: 10px; }
  .site-header .inner { gap: 14px; }
  .header-actions .back span { display: none; }
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
}

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--bg); padding-block: 60px 34px; margin-top: 40px; }
.site-footer .cols { display: grid; grid-template-columns: 1.7fr 1fr 1fr 1fr; gap: 40px; }
@media (max-width: 820px) { .site-footer .cols { grid-template-columns: 1fr 1fr; gap: 30px; } }
@media (max-width: 460px) { .site-footer .cols { grid-template-columns: 1fr; } }
.site-footer h5 { font-family: var(--font); font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--text-3); font-weight: 600; margin-bottom: 16px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 11px; }
.site-footer a { color: var(--text-2); font-size: .92rem; }
.site-footer a:hover { color: #fff; }
.site-footer .foot-brand img { height: 24px; margin-bottom: 18px; }
.site-footer .foot-brand p { color: var(--text-3); font-size: .92rem; max-width: 300px; font-weight: 300; }
.site-footer .legal { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-top: 46px; padding-top: 24px; border-top: 1px solid var(--border); color: var(--text-4); font-size: .82rem; }
.site-footer .legal .mono-mark { font-family: var(--mono); }

/* ---------- Assistant (replaces the old widget) ---------- */
.pb-bot-launch {
  position: fixed; right: 24px; bottom: 24px; z-index: 80;
  display: inline-flex; align-items: center; gap: 11px;
  background: var(--bg-alt); color: #fff; border: 1px solid var(--border);
  padding: 12px 20px 12px 15px; border-radius: 100px; font-size: .9rem; font-weight: 500;
  box-shadow: 0 18px 50px -18px rgba(0,0,0,.85); transition: transform .25s var(--ease), border-color .25s;
}
.pb-bot-launch:hover { transform: translateY(-2px); border-color: #3a3a3a; }
.pb-bot-launch .pb-launch-ic { width: 24px; height: 24px; object-fit: contain; }
.pb-bot-launch.hidden { display: none; }
@media (max-width: 560px){ .pb-bot-launch span.lab { display:none; } .pb-bot-launch{ padding:13px; } }

.pb-bot {
  position: fixed; right: 24px; bottom: 24px; z-index: 90;
  width: min(410px, calc(100vw - 32px)); height: min(640px, calc(100vh - 48px));
  display: flex; flex-direction: column;
  background: var(--bg-alt); border: 1px solid var(--border); border-radius: 20px;
  box-shadow: 0 30px 80px -20px rgba(0,0,0,.9); overflow: hidden;
  opacity: 0; transform: translateY(16px) scale(.98); pointer-events: none;
  transition: opacity .28s var(--ease), transform .28s var(--ease);
}
.pb-bot.open { opacity: 1; transform: none; pointer-events: auto; }

/* dark header — the glowing Otto mark is the brand accent */
.pb-bot-head { display: flex; align-items: center; gap: 11px; padding: 15px 16px; position: relative; background: var(--deep); border-bottom: 1px solid var(--border); }
.pb-bot-head .avatar { width: 40px; height: 40px; object-fit: contain; flex: none; }
.pb-bot-head .who { line-height: 1.25; }
.pb-bot-head .who strong { font-weight: 700; color: #fff; font-size: .98rem; letter-spacing: -.01em; }
.pb-bot-head .who span { font-size: .74rem; color: var(--text-3); display: flex; align-items: center; gap: 6px; }
.pb-bot-head .who .dot { width: 7px; height: 7px; border-radius: 50%; background: #4ad07a; box-shadow: 0 0 0 3px rgba(74,208,122,.18); }
.pb-bot-head .close { margin-left: auto; background: transparent; border: none; color: var(--text-3); width: 30px; height: 30px; border-radius: 8px; font-size: 1.05rem; display: grid; place-items: center; }
.pb-bot-head .close:hover { background: rgba(255,255,255,.05); color: #fff; }

.pb-bot-body { flex: 1; overflow-y: auto; padding: 20px 18px; display: flex; flex-direction: column; gap: 14px; scrollbar-width: thin; }
.pb-msg { max-width: 90%; font-size: .92rem; line-height: 1.55; }
.pb-msg.bot { align-self: flex-start; background: var(--deep); border: 1px solid var(--border); padding: 12px 15px; border-radius: 4px 15px 15px 15px; color: var(--text-2); }
.pb-msg.user { align-self: flex-end; background: #202a3b; color: #fff; padding: 11px 15px; border-radius: 15px 15px 4px 15px; }
.pb-msg.bot strong { color: #fff; }
.pb-msg .intro-lbl { display:block; margin-bottom: 6px; }
.pb-suggest { display: flex; flex-wrap: wrap; gap: 8px; }
.pb-chip { font-size: .82rem; color: var(--text-2); border: 1px solid var(--border); background: transparent; padding: 8px 13px; border-radius: 100px; transition: all .2s; text-align: left; }
.pb-chip:hover { border-color: #4a4a4a; color: #fff; }
.pb-result { display: block; border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; margin-top: 8px; background: var(--deep); transition: border-color .2s, transform .2s; }
.pb-result:hover { border-color: #3a3a3a; transform: translateX(2px); }
.pb-result .r-kind { font-family: var(--font); font-size: .62rem; letter-spacing: .12em; text-transform: uppercase; color: var(--text-3); font-weight: 600; }
.pb-result .r-title { color: #fff; font-weight: 600; font-size: .9rem; margin: 3px 0; }
.pb-result .r-desc { color: var(--text-3); font-size: .82rem; line-height: 1.45; font-weight: 300; }
.pb-thinking { display: inline-flex; align-items: center; gap: 10px; padding: 8px 15px 8px 8px; background: var(--deep); border: 1px solid var(--border); border-radius: 4px 15px 15px 15px; align-self: flex-start; }
.pb-thinking img { width: 34px; height: 34px; object-fit: contain; mix-blend-mode: screen; }
.pb-thinking span { font-size: .86rem; color: var(--text-3); }

.pb-bot-foot { padding: 14px; border-top: 1px solid var(--border); background: var(--bg-alt); }
.pb-inputwrap { display: flex; align-items: center; gap: 8px; background: var(--deep); border: 1px solid var(--border); border-radius: 100px; padding: 6px 6px 6px 17px; transition: border-color .2s; }
.pb-inputwrap:focus-within { border-color: #4a4a4a; }
.pb-inputwrap input { flex: 1; background: none; border: none; outline: none; color: #fff; font-family: var(--font); font-size: .92rem; }
.pb-inputwrap input::placeholder { color: var(--text-4); }
.pb-send { width: 38px; height: 38px; flex: none; border: none; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; transition: background .2s; }
.pb-send:hover { background: var(--accent-hover); }
.pb-send svg { width: 16px; height: 16px; }
.pb-foot-note { text-align: center; font-size: .7rem; color: var(--text-4); margin-top: 9px; }
.pb-foot-note .mono { font-family: var(--mono); }

/* ============================================================
   Deck download gate — HubSpot lead capture overlay
   ============================================================ */
.pb-gate { position: fixed; inset: 0; z-index: 130; display: grid; place-items: center; padding: 24px;
  background: rgba(10,10,10,.72); backdrop-filter: blur(6px); opacity: 0; pointer-events: none; transition: opacity .25s var(--ease); }
.pb-gate.open { opacity: 1; pointer-events: auto; }
.pb-gate-card { position: relative; width: min(500px,100%); max-height: 90vh; overflow: auto;
  background: var(--bg-alt); border: 1px solid var(--border); border-radius: 20px; padding: 32px 30px;
  transform: translateY(14px) scale(.98); transition: transform .3s var(--ease); box-shadow: 0 40px 100px -30px rgba(0,0,0,.9); }
.pb-gate.open .pb-gate-card { transform: none; }
.pb-gate-close { position: absolute; top: 18px; right: 18px; background: none; border: 1px solid var(--border);
  color: var(--text-3); width: 34px; height: 34px; border-radius: 9px; font-size: 1.1rem; display: grid; place-items: center; cursor: pointer; }
.pb-gate-close:hover { color: #fff; border-color: #3a3a3a; }
.pb-gate .lbl { display: block; margin-bottom: 10px; }
.pb-gate h3 { font-size: 1.5rem; margin: 0 0 8px; color: #fff; }
.pb-gate-sub { color: var(--text-3); font-weight: 300; margin: 0 0 22px; font-size: .95rem; line-height: 1.5; }
.pb-gate-loading { color: var(--text-3); font-size: .9rem; padding: 8px 0; }
.pb-gate-fallback { margin-top: 14px; font-size: .82rem; color: var(--text-4); }
.pb-gate-fallback a { color: var(--text-2); text-decoration: underline; text-underline-offset: 3px; }

/* dark-theme overrides for the embedded HubSpot form */
.pb-gate .hs-form fieldset { max-width: none !important; border: 0; padding: 0; margin: 0; }
.pb-gate .hs-form fieldset .hs-form-field { width: 100% !important; float: none !important; padding: 0 !important; margin: 0 0 14px; }
.pb-gate .hs-form-field > label { display: block; font-size: .8rem; color: var(--text-2); margin-bottom: 6px; font-weight: 500; }
.pb-gate .hs-form-field > label .hs-form-required { color: var(--accent); margin-left: 3px; }
.pb-gate .inputs-list { list-style: none; padding: 0; margin: 0; }
.pb-gate .hs-input { width: 100% !important; box-sizing: border-box; background: var(--deep); border: 1px solid var(--border);
  border-radius: 10px; padding: 11px 13px; color: #fff; font-family: var(--font); font-size: .95rem; }
.pb-gate .hs-input:focus { outline: none; border-color: var(--accent); }
.pb-gate select.hs-input { appearance: none; }
.pb-gate .hs-input::placeholder { color: var(--text-4); }
.pb-gate .hs-button { width: 100%; background: var(--accent); color: #fff; border: none; border-radius: 10px;
  padding: 13px; font-weight: 700; font-family: var(--font); font-size: .9rem; cursor: pointer; margin-top: 8px;
  text-transform: uppercase; letter-spacing: .05em; transition: background .2s; }
.pb-gate .hs-button:hover { background: var(--accent-hover); }
.pb-gate .hs-error-msg, .pb-gate .hs-error-msgs { color: #ff8f8f; font-size: .78rem; list-style: none; padding: 0; margin: 6px 0 0; }
.pb-gate .legal-consent-container, .pb-gate .hs-richtext { font-size: .74rem; color: var(--text-4); margin-top: 10px; line-height: 1.5; }
.pb-gate .legal-consent-container a { color: var(--text-2); }
.pb-gate .hs-form-booleancheckbox label { display: flex; gap: 8px; align-items: flex-start; font-size: .78rem; color: var(--text-3); }
.pb-gate .submitted-message { color: var(--text-2); font-size: .95rem; }

/* self-hosted deck-gate form fields */
.pb-gate #pbGateForm label { display: block; font-size: .8rem; color: var(--text-2); margin-bottom: 7px; font-weight: 500; }
.pb-gate #pbGateForm input[type="email"] { width: 100%; box-sizing: border-box; background: var(--deep); border: 1px solid var(--border);
  border-radius: 10px; padding: 12px 14px; color: #fff; font-family: var(--font); font-size: .98rem; }
.pb-gate #pbGateForm input[type="email"]::placeholder { color: var(--text-4); }
.pb-gate #pbGateForm input[type="email"]:focus { outline: none; border-color: var(--accent); }
.pb-gate #pbGateSubmit { width: 100%; margin-top: 14px; justify-content: center; }
.pb-gate-err { color: #ff8f8f; font-size: .8rem; margin-top: 8px; }
.pb-gate-fine { font-size: .72rem; color: var(--text-4); margin-top: 12px; line-height: 1.5; }
