/* ============================================================
   CloutView Website — High-Finance Dark Design System
   Aesthetic: Deep Midnight Black, Space Grotesk & IBM Plex,
   Amber Gold Accents, Clean Technical Grid, Precision Lines.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=IBM+Plex+Sans:wght@400;500;600&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
    --bg: #06070A;
    --panel: #0A0C10;
    --panel-raised: #0E1116;
    --line: rgba(230,230,225,0.09);
    --line-strong: rgba(230,230,225,0.18);
    --ink: #ECEDE8;
    --ink-dim: #8B8F94;
    --ink-faint: #54585D;
    --amber: #E8A33D;
    --amber-dim: rgba(232,163,61,0.13);
    --green: #3FAE72;
    --red: #C75C4A;
    --r: 3px;
    --maxw: 1220px;

    /* Aliases for backwards/component compatibility */
    --bg-dark: #06070A;
    --bg-surface: #0A0C10;
    --bg-card: #0E1116;
    --bg-card-hover: #13171F;
    --bg-glass: rgba(230, 230, 225, 0.03);
    
    --sky-blue: #E8A33D;
    --sky-glow: transparent;

    --primary: #E8A33D;
    --primary-glow: transparent;
    --primary-light: #F3C276;
    --primary-dark: #C9821E;

    --accent: #E8A33D;
    --accent-glow: transparent;

    --secondary: var(--panel-raised);
    
    --border-color: rgba(230, 230, 225, 0.09);
    --border-highlight: rgba(232, 163, 61, 0.35);
    
    --text-main: #ECEDE8;
    --text-muted: #8B8F94;
    --text-dim: #54585D;
    --text-brand: #E8A33D;
    
    --danger: #C75C4A;
    --warning: #E8A33D;
    --success: #3FAE72;
    --info: #E8A33D;
    
    --max-width: 1220px;
    --radius-sm: 3px;
    --radius-md: 4px;
    --radius-lg: 6px;
    --radius-xl: 8px;
    --radius-pill: 9999px;
    
    --transition: all 0.2s ease;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 15.5px;
    overflow-x: hidden;
    max-width: 100%;
    width: 100%;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'IBM Plex Sans', sans-serif;
    background-color: var(--bg);
    color: var(--ink);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    max-width: 100%;
    width: 100%;
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Space Grotesk', sans-serif;
    color: var(--ink);
    margin: 0;
    font-weight: 600;
    letter-spacing: -0.005em;
    line-height: 1.2;
}

p {
    margin: 0;
    color: var(--ink-dim);
}

.mono, code, pre {
    font-family: 'IBM Plex Mono', monospace;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--ink);
}

.wrap, .container {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 28px;
}

.container-narrow {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 24px;
}

section {
    position: relative;
}

/* ---------- 1. TICKER TAPE ---------- */
.ticker {
    background: var(--panel);
    border-bottom: 1px solid var(--line);
    overflow: hidden;
    white-space: nowrap;
    padding: 9px 0;
}
.ticker-inner {
    display: inline-flex;
    animation: tickerscroll 38s linear infinite;
}
.ticker-item {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12.5px;
    color: var(--ink-dim);
    padding: 0 26px;
    border-right: 1px solid var(--line);
    display: inline-flex;
    gap: 8px;
    align-items: center;
}
.ticker-item .up { color: var(--green); }
.ticker-item .down { color: var(--red); }
@keyframes tickerscroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media(prefers-reduced-motion:reduce){ .ticker-inner { animation: none; } }

/* ---------- 2. STICKY NAV ---------- */
header.nav, .site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(6,7,10,0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
}
.nav-inner, .navbar {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 16px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.brand, .brand-logo {
    display: inline-flex;
    align-items: center;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 800;
    font-size: 20px;
    letter-spacing: -0.02em;
    color: var(--ink);
    text-decoration: none;
}
.brand-text {
    display: inline-block;
    letter-spacing: -0.02em;
    font-weight: 800;
}
.brand-mark {
    width: 9px;
    height: 18px;
    background: var(--amber);
    flex-shrink: 0;
    display: inline-block;
    border-radius: 1px;
}
nav.links, .nav-links {
    display: flex;
    gap: 28px;
    font-size: 13.5px;
    color: var(--ink-dim);
    align-items: center;
    list-style: none;
}
nav.links a, .nav-links a {
    color: var(--ink-dim);
    transition: var(--transition);
}
nav.links a:hover, .nav-links a:hover, .nav-links a.active {
    color: var(--ink);
}
.nav-actions, .nav-auth {
    display: flex;
    gap: 12px;
    align-items: center;
}
.nav-login {
    font-size: 13.5px;
    color: var(--ink-dim);
    padding: 8px 12px;
    transition: var(--transition);
}
.nav-login:hover {
    color: var(--ink);
}
.nav-cta {
    font-size: 13.5px;
    font-weight: 600;
    padding: 9px 18px;
    border: 1px solid var(--amber);
    color: var(--amber);
    border-radius: var(--r);
    transition: var(--transition);
    display: inline-block;
}
.nav-cta:hover {
    background: var(--amber);
    color: #221602;
}
@media(max-width:860px){
    nav.links, .nav-links { display: none; }
}

/* ---------- 3. BUTTONS ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 14.5px;
    font-weight: 600;
    border-radius: var(--r);
    cursor: pointer;
    border: none;
    transition: var(--transition);
    font-family: 'IBM Plex Sans', sans-serif;
}
.btn-primary {
    background: var(--amber);
    color: #221602 !important;
    font-weight: 600;
    font-size: 14.5px;
    padding: 13px 26px;
    border-radius: var(--r);
    border: none;
}
.btn-primary:hover {
    opacity: 0.9;
    color: #221602 !important;
    transform: translateY(-1px);
}
.btn-ghost, .btn-secondary {
    background: transparent;
    color: var(--ink);
    font-weight: 500;
    font-size: 14.5px;
    padding: 13px 20px;
    border-radius: var(--r);
    border: 1px solid var(--line-strong);
}
.btn-ghost:hover, .btn-secondary:hover {
    border-color: var(--ink);
    color: var(--ink);
    transform: translateY(-1px);
}
.btn-sm {
    padding: 7px 14px;
    font-size: 12.5px;
}
.btn-lg {
    padding: 14px 32px;
    font-size: 15.5px;
}
.btn-block {
    display: flex;
    width: 100%;
}

/* ---------- 4. HERO SECTION ---------- */
.hero {
    padding: 64px 0 72px;
    border-bottom: 1px solid var(--line);
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: center;
}
.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    color: var(--amber);
    margin-bottom: 22px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.hero-eyebrow .dot {
    width: 6px;
    height: 6px;
    background: var(--amber);
    flex-shrink: 0;
    border-radius: 50%;
}
.hero h1 {
    font-size: clamp(36px, 4.8vw, 56px);
    line-height: 1.08;
    max-width: 14ch;
}
.hero-sub {
    margin-top: 22px;
    max-width: 480px;
    font-size: 16.5px;
    color: var(--ink-dim);
    line-height: 1.65;
}
.hero-ctas {
    display: flex;
    gap: 12px;
    margin-top: 32px;
    flex-wrap: wrap;
}
.hero-disclaimer {
    margin-top: 20px;
    font-size: 12px;
    color: var(--ink-faint);
    max-width: 440px;
    line-height: 1.6;
    display: flex;
    align-items: center;
    gap: 6px;
}
.typing-cursor {
    display: inline-block;
    width: 3px;
    height: 1em;
    background-color: var(--amber);
    margin-left: 4px;
    vertical-align: -2px;
    animation: blinkCursor 0.8s infinite;
}
@keyframes blinkCursor {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Candlestick Terminal Card */
.chart-terminal-card {
    background: var(--panel);
    border: 1px solid var(--line-strong);
    border-radius: var(--r);
    overflow: hidden;
    position: relative;
    box-shadow: 0 20px 50px rgba(0,0,0,0.6);
}
.term-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px 12px;
    border-bottom: 1px solid var(--line);
}
.term-metrics {
    margin: 12px 20px;
    background: var(--panel-raised);
    border: 1px solid var(--line);
    border-radius: var(--r);
    padding: 12px 16px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    text-align: center;
}
.term-pills {
    padding: 0 20px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}
@media(max-width:900px){
    .hero-grid { grid-template-columns: 1fr; }
}

/* ---------- 5. SECTIONS SHARED ---------- */
.section {
    padding: 84px 0;
    border-bottom: 1px solid var(--line);
}
.section-head {
    max-width: 680px;
    margin-bottom: 48px;
}
.section-num {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12.5px;
    color: var(--amber);
    margin-bottom: 14px;
    letter-spacing: 0.04em;
}
.section-head h2 {
    font-size: clamp(26px, 3.6vw, 38px);
    line-height: 1.14;
}
.section-head p {
    margin-top: 14px;
    font-size: 16px;
    color: var(--ink-dim);
    line-height: 1.65;
}

/* ---------- 6. METHOD TABLE (4 ROWS) ---------- */
.method-table {
    border: 1px solid var(--line);
    border-radius: var(--r);
    overflow: hidden;
    background: var(--panel);
}
.method-row {
    display: grid;
    grid-template-columns: 70px 190px 1fr;
    gap: 24px;
    padding: 26px 28px;
    border-bottom: 1px solid var(--line);
}
.method-row:last-child {
    border-bottom: none;
}
.method-row .idx {
    font-family: 'IBM Plex Mono', monospace;
    color: var(--amber);
    font-size: 14px;
    font-weight: 600;
}
.method-row .label {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12.5px;
    color: var(--ink-faint);
    padding-top: 2px;
}
.method-row h3 {
    font-size: 17.5px;
    margin-bottom: 8px;
}
.method-row p {
    font-size: 14px;
    color: var(--ink-dim);
    line-height: 1.65;
    max-width: 640px;
}
@media(max-width:720px){
    .method-row { grid-template-columns: 1fr; gap: 8px; }
}

/* ---------- 7. FLOW STEPS (3 COLUMNS) ---------- */
.flow {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border: 1px solid var(--line);
    border-radius: var(--r);
    overflow: hidden;
    background: var(--panel);
}
.flow-step {
    padding: 28px 26px;
    border-right: 1px solid var(--line);
}
.flow-step:last-child {
    border-right: none;
}
.flow-step .idx {
    font-family: 'IBM Plex Mono', monospace;
    color: var(--amber);
    font-size: 13px;
    font-weight: 600;
}
.flow-step h3 {
    font-size: 17.5px;
    margin-top: 12px;
}
.flow-step p {
    font-size: 13.5px;
    color: var(--ink-dim);
    margin-top: 9px;
    line-height: 1.65;
}
@media(max-width:800px){
    .flow { grid-template-columns: 1fr; }
    .flow-step { border-right: none; border-bottom: 1px solid var(--line); }
    .flow-step:last-child { border-bottom: none; }
}

/* ---------- 8. AI SECTION ---------- */
.ai-box {
    background: var(--panel);
    border: 1px solid var(--line-strong);
    border-radius: var(--r);
    padding: 28px 30px;
}
.ai-toggle {
    display: inline-flex;
    gap: 6px;
    background: var(--panel-raised);
    border: 1px solid var(--line);
    padding: 4px;
    border-radius: var(--r);
    margin-bottom: 18px;
}
.ai-btn {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    padding: 6px 14px;
    border-radius: var(--r);
    background: transparent;
    border: none;
    color: var(--ink-dim);
    cursor: pointer;
}
.ai-btn.active {
    background: var(--amber);
    color: #221602;
    font-weight: 600;
}
.ai-content {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 13px;
    color: var(--ink);
    line-height: 1.7;
}

/* ---------- 9. PRICING GRID ---------- */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border: 1px solid var(--line);
    border-radius: var(--r);
    overflow: hidden;
    background: var(--panel);
}
.price-card {
    padding: 32px 28px;
    border-right: 1px solid var(--line);
    display: flex;
    flex-direction: column;
}
.price-card:last-child {
    border-right: none;
}
.price-card.feature {
    background: var(--amber-dim);
    border: 1px solid var(--amber);
}
.price-name {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 13px;
    color: var(--ink-dim);
    margin-bottom: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.price-value {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 36px;
    font-weight: 600;
    color: var(--ink);
}
.price-value span {
    font-size: 13px;
    color: var(--ink-faint);
    font-weight: 400;
}
.price-desc {
    font-size: 13.5px;
    color: var(--ink-dim);
    margin-top: 10px;
    margin-bottom: 22px;
    line-height: 1.6;
}
.price-features {
    list-style: none;
    padding: 0;
    margin: 0 0 26px;
    flex: 1;
}
.price-features li {
    font-size: 13.5px;
    color: var(--ink-dim);
    padding: 9px 0;
    border-top: 1px solid var(--line);
    display: flex;
    align-items: center;
    gap: 8px;
}
.price-features li:first-child {
    border-top: none;
}
.price-btn {
    text-align: center;
    padding: 12px;
    border-radius: var(--r);
    font-weight: 600;
    font-size: 13.5px;
    border: 1px solid var(--line-strong);
    display: block;
}
.price-card.feature .price-btn {
    background: var(--amber);
    color: #221602;
    border: none;
}
@media(max-width:900px){
    .pricing-grid { grid-template-columns: 1fr; }
    .price-card { border-right: none; border-bottom: 1px solid var(--line); }
    .price-card:last-child { border-bottom: none; }
}

/* ---------- 10. FAQ ACCORDION ---------- */
.faq-list {
    max-width: 760px;
}
.faq-item {
    border-top: 1px solid var(--line);
}
.faq-item:last-child {
    border-bottom: 1px solid var(--line);
}
.faq-item summary {
    padding: 20px 4px;
    cursor: pointer;
    font-size: 15.5px;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
    list-style: none;
    font-family: 'Space Grotesk', sans-serif;
    color: var(--ink);
}
.faq-item summary::-webkit-details-marker {
    display: none;
}
.faq-item summary::after {
    content: '+';
    color: var(--amber);
    font-size: 19px;
    font-weight: 300;
}
.faq-item[open] summary::after {
    content: '−';
}
.faq-item p {
    padding: 0 4px 22px;
    color: var(--ink-dim);
    font-size: 14px;
    max-width: 640px;
    line-height: 1.65;
}

/* ---------- 11. FINAL CTA ---------- */
.final-cta {
    padding: 90px 28px;
    text-align: center;
    border-bottom: 1px solid var(--line);
    background: var(--panel);
}
.final-cta .section-num {
    display: flex;
    justify-content: center;
}
.final-cta h2 {
    font-size: clamp(28px, 4.6vw, 44px);
    max-width: 18ch;
    margin: 0 auto;
    line-height: 1.12;
}
.final-cta p {
    margin-top: 16px;
    color: var(--ink-dim);
    font-size: 16px;
}
.final-cta .hero-ctas {
    justify-content: center;
    margin-top: 28px;
}

/* ---------- 12. GLOBAL FOOTER ---------- */
footer, .site-footer {
    padding: 50px 0 32px;
    background: var(--bg);
    border-top: 1px solid var(--line);
}
.footer-top {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
    margin-bottom: 36px;
}
.footer-brand p {
    color: var(--ink-faint);
    font-size: 13.5px;
    margin-top: 12px;
    max-width: 280px;
    line-height: 1.6;
}
.footer-cols {
    display: flex;
    gap: 60px;
    flex-wrap: wrap;
}
.footer-col h4 {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    color: var(--ink-faint);
    font-weight: 400;
    margin-bottom: 14px;
    text-transform: uppercase;
}
.footer-col a {
    display: block;
    font-size: 13.5px;
    color: var(--ink-dim);
    margin-bottom: 10px;
}
.footer-col a:hover {
    color: var(--ink);
}
.footer-bottom {
    border-top: 1px solid var(--line);
    padding-top: 22px;
    font-size: 12px;
    color: var(--ink-faint);
    line-height: 1.7;
}

/* ---------- 13. FORMS & INPUTS ---------- */
.form-group {
    margin-bottom: 18px;
}
.form-label {
    display: block;
    margin-bottom: 6px;
    font-size: 13.5px;
    color: var(--ink-dim);
    font-weight: 500;
}
.form-control {
    width: 100%;
    padding: 11px 14px;
    background: var(--panel-raised);
    border: 1px solid var(--line);
    border-radius: var(--r);
    color: var(--ink);
    font-family: inherit;
    font-size: 14.5px;
    transition: var(--transition);
}
.form-control:focus {
    outline: none;
    border-color: var(--amber);
}

/* Toast Container */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.toast {
    background: var(--panel-raised);
    border: 1px solid var(--line);
    color: var(--ink);
    padding: 12px 18px;
    border-radius: var(--r);
    font-size: 13.5px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
}
.toast-success { border-color: var(--green); }
.toast-error { border-color: var(--red); }
.toast-close { background: none; border: none; color: var(--ink-faint); cursor: pointer; }
