/* HB Funded shared layout styles — moved from base.html inline <style> blocks (2026-11-04).
   Same rules, same order. Served as a cached file instead of inside every page. */

/* ── block 1 (was base.html line 59) ── */
  /* ── Page transition ── */
  body { opacity: 1; }
  body.js-fade { opacity: 0; transition: opacity 220ms ease; }
  body.loaded { opacity: 1; }
  /* ── Scroll reveal ── */
  .reveal { opacity: 0; transform: translateY(22px); transition: opacity 420ms ease, transform 420ms ease; }
  .reveal.visible { opacity: 1; transform: translateY(0); }
  /* ── Hover effects (were inline onmouseover/onmouseout; CSP stage 3) ── */
  .hbf-hov-grey:hover { background: rgba(255,255,255,0.05) !important; }
  .hbf-hov-cyan-bg:hover { background: rgba(0,193,245,0.08) !important; }
  .hbf-hov-red-bg:hover { background: rgba(239,68,68,0.08) !important; }
  .hbf-hov-cyan-text:hover { color: #00c1f5 !important; }
  /* ── Sticky sign-up bar showing: keep chat + back-to-top above it ── */
  body.hbf-sticky-on { padding-bottom: var(--hbf-bar-h, 64px); }  /* footer + risk warning stay readable */
  body.hbf-sticky-on #hb-chat-btn { bottom: calc(var(--hbf-bar-h, 64px) + 0.75rem); }
  body.hbf-sticky-on #hb-chat-window { bottom: calc(var(--hbf-bar-h, 64px) + 4.25rem); max-height: calc(100vh - var(--hbf-bar-h, 64px) - 6rem); }
  body.hbf-sticky-on #scroll-top-btn { bottom: calc(var(--hbf-bar-h, 64px) + 4.75rem) !important; }

/* ── block 2 (was base.html line 78) ── */
  :root {
    --accent: #00c1f5;
    --accent-glow: rgba(0,193,245,0.15);
    --accent-glow-strong: rgba(0,193,245,0.3);
    --green: #00d97e;
    --green-glow: rgba(0,217,126,0.15);
    --gold: #f5c518;
    --surface-950: #080b0e;
    --surface-900: #0d1117;
    --surface-800: #131920;
    --surface-700: #1a2230;
    --border: rgba(255,255,255,0.07);
    --border-accent: rgba(0,193,245,0.3);
    --text: #e8edf2;
    --text-muted: #7a8a99;
    --text-faint: #445566;
    --font-body: 'Inter', system-ui, sans-serif;
    --font-display: 'Space Grotesk', 'Inter', sans-serif;
  }
  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
  body {
    font-family: var(--font-body);
    background: var(--surface-950);
    color: var(--text);
    min-height: 100dvh;
  }
  .font-display { font-family: var(--font-display); }

  /* Glowing accent text */
  .text-accent { color: var(--accent); }
  .text-green { color: var(--green); }
  .text-gold { color: var(--gold); }

  /* Glow effects */
  .glow-accent {
    text-shadow: 0 0 30px var(--accent-glow-strong), 0 0 60px var(--accent-glow);
  }
  .glow-green {
    text-shadow: 0 0 30px var(--green-glow), 0 0 60px rgba(0,217,126,0.1);
  }

  /* Gradient hero background */
  .hero-bg {
    background:
      radial-gradient(ellipse 80% 50% at 50% -10%, rgba(0,193,245,0.12) 0%, transparent 70%),
      radial-gradient(ellipse 50% 40% at 80% 50%, rgba(0,145,199,0.06) 0%, transparent 60%),
      var(--surface-950);
  }

  /* Card styles */
  .card {
    background: var(--surface-800);
    border: 1px solid var(--border);
    border-radius: 16px;
    transition: border-color 200ms ease, transform 200ms ease, box-shadow 200ms ease;
  }
  .card:hover {
    border-color: rgba(0,193,245,0.25);
    box-shadow: 0 0 0 1px rgba(0,193,245,0.1), 0 8px 32px rgba(0,0,0,0.4);
  }
  .card-featured {
    background: linear-gradient(135deg, rgba(0,193,245,0.08) 0%, var(--surface-800) 100%);
    border-color: var(--accent) !important;
    box-shadow: 0 0 0 1px rgba(0,193,245,0.2), 0 0 40px rgba(0,193,245,0.08);
  }

  /* Buttons */
  .btn-primary {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    background: var(--accent);
    color: #000;
    font-weight: 700;
    font-family: var(--font-display);
    padding: 12px 24px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 180ms ease;
    text-decoration: none;
    font-size: 0.9375rem;
    letter-spacing: -0.01em;
    box-shadow: 0 0 20px rgba(0,193,245,0.3);
  }
  .btn-primary:hover {
    background: #33d0ff;
    box-shadow: 0 0 30px rgba(0,193,245,0.5);
    transform: translateY(-1px);
  }
  .btn-secondary {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    background: transparent;
    color: var(--text);
    font-weight: 600;
    font-family: var(--font-display);
    padding: 11px 22px;
    border-radius: 12px;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: all 180ms ease;
    text-decoration: none;
    font-size: 0.9375rem;
  }
  .btn-secondary:hover {
    border-color: rgba(0,193,245,0.3);
    background: rgba(0,193,245,0.05);
    color: var(--accent);
  }

  /* Nav */
  .nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 160ms ease;
    padding: 4px 2px;
  }
  .nav-link:hover { color: var(--text); }

  /* Badge */
  .badge {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 0.75rem; font-weight: 600; letter-spacing: 0.04em;
    padding: 4px 12px;
    border-radius: 100px;
    border: 1px solid;
  }
  .badge-accent {
    background: rgba(0,193,245,0.08);
    border-color: rgba(0,193,245,0.25);
    color: var(--accent);
  }
  .badge-green {
    background: rgba(0,217,126,0.08);
    border-color: rgba(0,217,126,0.25);
    color: var(--green);
  }

  /* Divider line */
  .divider { border: none; border-top: 1px solid var(--border); }

  /* Section padding */
  .section { padding-block: clamp(3rem, 6vw, 6rem); }

  /* Stat number */
  .stat-num {
    font-family: var(--font-display);
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1;
  }

  /* Animated counter glow */
  @keyframes pulse-glow {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
  }
  .pulse { animation: pulse-glow 2s ease-in-out infinite; }

  /* Ticker strip */
  .ticker-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 8px var(--green);
    animation: pulse-glow 1.5s ease-in-out infinite;
  }

  /* Feature check list */
  .check-item {
    display: flex; align-items: flex-start; gap: 10px;
    font-size: 0.9375rem; color: var(--text-muted);
    line-height: 1.5;
  }
  .check-item .check-icon {
    flex-shrink: 0; margin-top: 2px;
    color: var(--green);
    font-size: 1rem;
  }

  /* Step number */
  .step-num {
    width: 40px; height: 40px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,193,245,0.1);
    border: 1px solid rgba(0,193,245,0.25);
    border-radius: 12px;
    font-family: var(--font-display);
    font-weight: 800; font-size: 1rem;
    color: var(--accent);
    flex-shrink: 0;
  }

  /* Responsive util */
  @media (max-width: 640px) {
    .hide-mobile { display: none !important; }
    #nav-toggle { display: flex !important; align-items: center; justify-content: center; }
  }

/* ── block 3 (was base.html line 515) ── */
  @keyframes mktTickerScroll { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
  @media (prefers-reduced-motion: reduce) { .mkt-ticker-track { animation: none !important; } }

/* ── block 4 (was base.html line 521) ── */
  @media (max-width: 640px) {
    #nav-toggle { display: block !important; }
    .hide-mobile { display: none !important; }
    #mobile-menu.open { display: flex !important; }
  }

/* ── block 5 (was base.html line 654) ── */
@media (max-width: 640px) {
  #cookie-banner { padding: 0.75rem 1rem !important; }
  #cookie-banner p { font-size: 0.75rem !important; }
  #cookie-banner .cookie-inner { flex-direction: column !important; gap: 0.625rem !important; }
  #cookie-banner .cookie-btns { width: 100%; justify-content: flex-end; }
  body.cookie-visible { padding-bottom: 110px; }
}

/* ── block 6 (was base.html line 729) ── */
#hb-chat-btn{position:fixed;bottom:1.5rem;right:1.25rem;z-index:8100;width:54px;height:54px;border-radius:50%;background:linear-gradient(135deg,#00c1f5,#0099cc);border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 4px 20px rgba(0,193,245,0.45);transition:transform 200ms ease,box-shadow 200ms ease;}
#hb-chat-btn:hover{transform:scale(1.08);box-shadow:0 6px 28px rgba(0,193,245,0.6);}
#hb-chat-btn svg{width:24px;height:24px;fill:white;}
#hb-chat-badge{position:absolute;top:-2px;right:-2px;width:18px;height:18px;border-radius:50%;background:#ef4444;color:white;font-size:10px;font-weight:700;display:none;align-items:center;justify-content:center;border:2px solid #080b0e;}
#hb-chat-window{position:fixed;bottom:5rem;right:1.25rem;z-index:8099;width:360px;max-width:calc(100vw - 2rem);height:520px;max-height:calc(100vh - 7rem);background:#0d1117;border:1px solid rgba(0,193,245,0.2);border-radius:16px;display:none;flex-direction:column;box-shadow:0 8px 40px rgba(0,0,0,0.7);overflow:hidden;font-family:inherit;}
#hb-chat-header{background:linear-gradient(135deg,#00c1f5 0%,#0099cc 100%);padding:14px 16px;display:flex;align-items:center;gap:10px;flex-shrink:0;}
#hb-chat-header-icon{width:36px;height:36px;border-radius:50%;background:rgba(255,255,255,0.2);display:flex;align-items:center;justify-content:center;flex-shrink:0;}
#hb-chat-header-icon svg{width:20px;height:20px;fill:white;}
.hb-chat-header-info{flex:1;min-width:0;}
.hb-chat-header-name{color:white;font-weight:700;font-size:0.9rem;line-height:1.2;}
.hb-chat-header-status{color:rgba(255,255,255,0.85);font-size:0.72rem;display:flex;align-items:center;gap:4px;}
.hb-chat-status-dot{width:7px;height:7px;border-radius:50%;background:#00d97e;flex-shrink:0;}
#hb-chat-close{background:none;border:none;cursor:pointer;color:rgba(255,255,255,0.8);font-size:1.3rem;line-height:1;padding:4px;transition:color 150ms;flex-shrink:0;}
#hb-chat-close:hover{color:white;}
#hb-chat-disclaimer{background:rgba(0,193,245,0.06);border-bottom:1px solid rgba(0,193,245,0.12);padding:8px 14px;font-size:0.7rem;color:rgba(255,255,255,0.5);text-align:center;flex-shrink:0;line-height:1.4;}
#hb-chat-messages{flex:1;overflow-y:auto;padding:14px 14px 8px;display:flex;flex-direction:column;gap:10px;scrollbar-width:thin;scrollbar-color:rgba(0,193,245,0.2) transparent;}
#hb-chat-messages::-webkit-scrollbar{width:4px;}
#hb-chat-messages::-webkit-scrollbar-thumb{background:rgba(0,193,245,0.2);border-radius:2px;}
.hb-msg{display:flex;gap:8px;max-width:100%;animation:hbMsgIn 200ms ease;}
@keyframes hbMsgIn{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}
.hb-msg-user{flex-direction:row-reverse;}
.hb-msg-avatar{width:28px;height:28px;border-radius:50%;flex-shrink:0;display:flex;align-items:center;justify-content:center;font-size:0.7rem;font-weight:700;margin-top:2px;}
.hb-msg-bot .hb-msg-avatar{background:rgba(0,193,245,0.15);border:1px solid rgba(0,193,245,0.25);color:#00c1f5;}
.hb-msg-user .hb-msg-avatar{background:rgba(0,217,126,0.15);border:1px solid rgba(0,217,126,0.25);color:#00d97e;}
.hb-msg-bubble{max-width:82%;padding:10px 13px;border-radius:12px;font-size:0.82rem;line-height:1.55;word-break:break-word;}
.hb-msg-bot .hb-msg-bubble{background:#1a2332;border:1px solid rgba(0,193,245,0.12);color:#e2e8f0;border-bottom-left-radius:4px;}
.hb-msg-user .hb-msg-bubble{background:linear-gradient(135deg,#00c1f5,#0099cc);color:white;border-bottom-right-radius:4px;}
.hb-msg-time{font-size:0.65rem;color:rgba(255,255,255,0.3);margin-top:3px;text-align:right;}
.hb-msg-bot .hb-msg-time{text-align:left;}
.hb-typing{display:flex;gap:8px;align-items:center;padding:0 2px;opacity:0;transition:opacity 200ms;}
.hb-typing.visible{opacity:1;}
.hb-typing-dots{display:flex;gap:4px;align-items:center;}
.hb-typing-dot{width:7px;height:7px;border-radius:50%;background:rgba(0,193,245,0.5);animation:hbDot 1.2s ease-in-out infinite;}
.hb-typing-dot:nth-child(2){animation-delay:0.2s;}
.hb-typing-dot:nth-child(3){animation-delay:0.4s;}
@keyframes hbDot{0%,60%,100%{transform:translateY(0);opacity:0.4}30%{transform:translateY(-5px);opacity:1}}
#hb-chat-human-btn{margin:0 14px 10px;padding:9px 14px;border-radius:10px;background:rgba(245,197,24,0.08);border:1px solid rgba(245,197,24,0.25);color:#f5c518;font-size:0.78rem;font-weight:600;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:6px;transition:background 160ms,border-color 160ms;flex-shrink:0;}
#hb-chat-human-btn:hover{background:rgba(245,197,24,0.14);border-color:rgba(245,197,24,0.4);}
#hb-chat-human-btn svg{width:14px;height:14px;fill:currentColor;flex-shrink:0;}
#hb-chat-input-row{padding:10px 12px 12px;border-top:1px solid rgba(0,193,245,0.1);display:flex;gap:8px;align-items:flex-end;flex-shrink:0;background:#0d1117;}
#hb-chat-input{flex:1;background:#1a2332;border:1px solid rgba(0,193,245,0.15);border-radius:10px;padding:9px 12px;color:#e2e8f0;font-size:0.82rem;resize:none;outline:none;max-height:100px;transition:border-color 160ms;font-family:inherit;line-height:1.4;scrollbar-width:thin;}
#hb-chat-input:focus{border-color:rgba(0,193,245,0.4);}
#hb-chat-input::placeholder{color:rgba(255,255,255,0.3);}
#hb-chat-send{width:38px;height:38px;border-radius:10px;border:none;cursor:pointer;background:linear-gradient(135deg,#00c1f5,#0099cc);display:flex;align-items:center;justify-content:center;flex-shrink:0;transition:transform 150ms,box-shadow 150ms;box-shadow:0 2px 10px rgba(0,193,245,0.3);}
#hb-chat-send:hover{transform:scale(1.06);box-shadow:0 4px 16px rgba(0,193,245,0.45);}
#hb-chat-send:disabled{opacity:0.4;cursor:not-allowed;transform:none;}
#hb-chat-send svg{width:16px;height:16px;fill:white;}
@media(max-width:480px){#hb-chat-window{right:0.75rem;width:calc(100vw - 1.5rem);}#hb-chat-input{font-size:16px;}}

/* Cookie banner showing: chat button and window sit above it (2026-11-09) */
body.hbf-cookie-on #hb-chat-btn{bottom:calc(var(--hbf-cookie-h,150px) + 0.75rem);}
body.hbf-cookie-on #hb-chat-window{bottom:calc(var(--hbf-cookie-h,150px) + 4.25rem);max-height:calc(100vh - var(--hbf-cookie-h,150px) - 6rem);}
body.hbf-cookie-on #scroll-top-btn{bottom:calc(var(--hbf-cookie-h,150px) + 4.75rem) !important;}
