/* Theme tokens */
:root {
  --bg: #070a0f;
  --panel: #0b1017;
  --panel-2: #0d1320;
  --text: #e7eef7;
  --muted: #a7b3c1;
  --primary: #ffd166;
  --primary-ink: #231800;
  --accent: #66e1ff;
  --border: rgba(255, 255, 255, 0.12);
  --glass: rgba(255, 255, 255, 0.06);
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  --radius: 14px;
  --radius-sm: 10px;
  --container: 1180px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  background: radial-gradient(1200px 800px at 80% -10%, rgba(255, 209, 102, 0.10), transparent 50%),
              radial-gradient(1000px 700px at 10% 110%, rgba(102, 225, 255, 0.08), transparent 55%),
              var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }

/* Top nav */
.nav-header {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(12px);
  background: linear-gradient(to bottom, rgba(7, 10, 15, 0.9), rgba(7, 10, 15, 0.6));
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand-logo { width: 28px; height: 28px; border-radius: 8px; }
.brand-name { font-weight: 800; letter-spacing: .2px; }
.nav { display: flex; align-items: center; gap: 18px; }
.nav a { color: var(--muted); transition: color .15s ease; }
.nav a:hover { color: var(--text); }
.nav .dropdown { display: flex; align-items: center; }

/* Dropdown styles */
.dropdown { position: relative; display: inline-flex; align-items: center; gap: 6px; }
.dropdown-toggle { 
  background: transparent; 
  border: none; 
  color: var(--muted); 
  cursor: pointer; 
  padding: 0; 
  font-size: inherit; 
  font-family: inherit;
  display: flex; 
  align-items: center; 
  gap: 4px;
  transition: color .15s ease;
}
.dropdown-link { color: var(--muted); transition: color .15s ease; }
.dropdown-link:hover { color: var(--text); }
.dropdown-toggle:hover { color: var(--text); }
.dropdown-arrow { 
  font-size: 10px; 
  transition: transform .2s ease; 
}
.dropdown.active .dropdown-arrow { transform: rotate(180deg); }
.dropdown-menu { 
  position: absolute; 
  top: 100%; 
  left: 0; 
  background: var(--panel); 
  border: 1px solid var(--border); 
  border-radius: var(--radius-sm); 
  padding: 8px 0; 
  min-width: 180px; 
  box-shadow: var(--shadow);
  opacity: 0; 
  visibility: hidden; 
  transform: translateY(-8px);
  transition: all .2s ease;
  z-index: 1000;
}
.dropdown.active .dropdown-menu { 
  opacity: 1; 
  visibility: visible; 
  transform: translateY(0); 
}
.dropdown-menu a { 
  display: block; 
  padding: 8px 16px; 
  color: var(--muted); 
  transition: all .15s ease;
}
.dropdown-menu a:hover { 
  background: rgba(255,255,255,.06); 
  color: var(--text); 
}

.nav-toggle { display: none; width: 40px; height: 40px; background: transparent; border: 1px solid var(--border); border-radius: 8px; color: var(--text); align-items: center; justify-content: center; }
.nav-toggle span { display: block; width: 18px; height: 2px; background: var(--text); margin: 3px auto; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 18px; border-radius: var(--radius-sm); border: 1px solid var(--border); color: var(--text); background: transparent; transition: transform .06s ease, background .2s ease, color .2s ease, border-color .2s ease; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: linear-gradient(180deg, #66e1ff, #2aa6ff); color: #ffffff; border-color: rgba(0,0,0,.25); box-shadow: 0 8px 18px rgba(102,225,255,.24); }
.nav .btn-primary { color: #ffffff; }
.btn-ghost { background: rgba(255,255,255,.06); }
.btn-small { padding: 10px 14px; }

/* Sections */
.section { padding: 110px 0; position: relative; }
#tradesync-go { padding-bottom: 16px; }
.section h1, .section h2, .section h3 { line-height: 1.2; }
.display { font-size: clamp(36px, 5.4vw, 62px); margin: 0 0 10px; letter-spacing: -0.02em; }
.display { word-break: break-word; overflow-wrap: anywhere; white-space: normal; }
.headline { font-size: clamp(28px, 4.4vw, 42px); margin: 0 0 8px; }
.eyebrow { color: var(--accent); font-size: 12px; letter-spacing: .2px; text-transform: uppercase; margin-bottom: 6px; }
.lead { color: var(--muted); font-size: 18px; }
.center { text-align: center; }

/* About page tweaks */
.about .section { padding: 48px 0; }
.about .section:first-of-type { padding-top: 32px; padding-bottom: 12px; }
/* Pull the Team block closer to the intro */
.about [aria-label="Team"] { padding-top: 24px; }
.about .section p { margin: 0 0 16px; }
.about .section h2 { margin: 0 0 8px; }
.about .section h3 { margin: 12px 0 8px; }
.about .grid-2 { gap: 32px; }
.about .grid-2 > :first-child { margin-bottom: 12px; }
/* Extra space between the end of a bullets list and the next H2 (e.g., before "What we care about") */
.about .section .bullets + h2 { margin-top: 26px; }
/* Extra space after the last intro paragraph before the next H2 */
.about [aria-label="Team"] p + h2 { margin-top: 26px; }
/* Extra space after the final bullets list (after "Results, not hype…") */
.about [aria-label="Team"] .bullets:last-of-type { margin-bottom: 18px; }

/* Hero */
.hero { padding-top: 120px; overflow: hidden; position: relative; }
.hero-inner { display: flex; flex-direction: column; align-items: center; text-align: center; max-width: 800px; margin: 0 auto; }
.hero-title { margin-bottom: 20px; }
.hero .cta-group { display: flex; gap: 12px; margin: 18px 0 10px; flex-wrap: wrap; }
.hero-highlights { margin: 18px 0 0; padding: 0; list-style: none; color: var(--muted); display: grid; gap: 6px; }
.hero-bg { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.hero-inner, .hero-title, .hero-copy, .hero-media { position: relative; z-index: 1; }
.grid-overlay { position: absolute; inset: 0; background: linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px); background-size: 80px 80px, 80px 80px; mask-image: radial-gradient(1000px 600px at 80% 30%, black, transparent 70%); }
.orb { position: absolute; border-radius: 999px; filter: blur(40px); opacity: .6; }
.orb-a { width: 420px; height: 420px; background: radial-gradient(circle at 30% 30%, #ffd166, transparent 60%); top: -120px; right: -120px; }
.orb-b { width: 360px; height: 360px; background: radial-gradient(circle at 70% 70%, #66e1ff, transparent 60%); bottom: -100px; left: -80px; }
.orb-c { width: 260px; height: 260px; background: radial-gradient(circle at 40% 40%, #ffd166, transparent 60%); bottom: 20%; right: 10%; opacity: .35; }

/* Cards */
.card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.glass { background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.03)); }
.panel { background: var(--panel-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.panel-title { color: var(--accent); font-size: 12px; letter-spacing: .2px; text-transform: uppercase; margin-bottom: 8px; }
.card-kicker { color: var(--accent); font-size: 12px; letter-spacing: .2px; text-transform: uppercase; }
.card-title { margin: 6px 0 12px; font-size: 18px; }

/* HS table */
.hs-suggestion { display: grid; gap: 8px; margin-bottom: 12px; }
.hs-row { display: grid; grid-template-columns: 100px 1fr 60px; gap: 10px; align-items: center; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, 'Liberation Mono', monospace; }
.hs-code { color: var(--text); }
.hs-desc { color: var(--muted); }
.hs-conf { text-align: right; color: var(--accent); }
.evidence { border-top: 1px dashed var(--border); padding-top: 10px; }
.evidence ul { margin: 8px 0 0; padding-left: 18px; color: var(--muted); }

/* Product interface mock */
.ui-frame { background: #0d1118; border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.ui-topbar { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; background: #0f151f; border-bottom: 1px solid var(--border); }
.ui-left { display: flex; align-items: center; gap: 10px; }
.ui-logo-dot { width: 18px; height: 18px; border-radius: 6px; background: linear-gradient(180deg, var(--primary), #f6c046); box-shadow: 0 0 0 2px rgba(0,0,0,.35); }
.ui-title { font-weight: 800; letter-spacing: .3px; font-size: 12px; color: var(--muted); }
.ui-right { display: flex; align-items: center; gap: 8px; }
.ui-btn { font-size: 12px; padding: 8px 10px; border-radius: 8px; background: rgba(255,255,255,.06); color: var(--text); border: 1px solid var(--border); }
.ui-btn.ui-primary { background: linear-gradient(180deg, var(--primary), #f6c046); color: var(--primary-ink); border-color: rgba(0,0,0,.25); }
.ui-user { width: 28px; height: 28px; border-radius: 999px; background: #1b2230; display: grid; place-items: center; font-weight: 700; }
.ui-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-bottom: 1px solid var(--border); }
.ui-search { display: flex; flex: 1; background: #0f151f; border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; }
.ui-search input { flex: 1; background: transparent; border: none; color: var(--text); outline: none; font-size: 14px; }
.ui-search-icn { color: var(--muted); font-size: 14px; }

/* TradeSync Go specific interface styles */
.ui-content { display: grid; grid-template-columns: 200px 1fr; gap: 0; }
.ui-main { padding: 20px; display: grid; grid-template-columns: minmax(0,1fr) 240px; grid-template-rows: auto 1fr; gap: 16px; }
.ui-header { margin-bottom: 20px; }
.ui-classification { grid-column: 1; grid-row: 2; }
.response-main { position: relative; }
/* Move scrolling to the whole conversation (response + agentic) */
.response-scroll { max-height: 360px; overflow-y: auto; padding-right: 10px; }
.response-main h4 { color: var(--text); margin: 16px 0 8px; font-size: 14px; font-weight: 600; }
.response-main p { color: var(--muted); margin: 0 0 12px; line-height: 1.5; }
.ui-classification .justification p { margin: 0 0 8px; font-size: 13px; }
.justification p { margin: 0 0 8px; font-size: 13px; }
.ui-leftbar { background: #0f151f; border-right: 1px solid var(--border); padding: 20px; }
.ui-rightbar { background: #0f151f; border-left: 1px solid var(--border); padding: 20px; }
.sidebar-section h5 { color: var(--accent); font-size: 12px; letter-spacing: .2px; text-transform: uppercase; margin: 0 0 16px; }
.history-item { padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.1); }
.history-item:last-child { border-bottom: none; }
.history-item span { display: block; color: var(--text); font-size: 13px; font-weight: 500; margin-bottom: 4px; }
.history-item small { color: var(--muted); font-size: 11px; }

/* Chatbar */
.ui-chatbar { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px; padding: 8px 14px; background: #0f151f; margin-left: 200px; width: calc(100% - 200px); border-left: 1px solid var(--border); }
.ui-content + .ui-chatbar { margin-top: auto; }
.ui-chat-input { display: flex; background: #0d131d; border: none; border-radius: 10px; padding: 8px 10px; }
.ui-main .ui-chatbar { grid-template-columns: 1fr auto; }
.ui-chat-input input { flex: 1; background: transparent; border: none; color: var(--text); outline: none; font-size: 14px; }

/* Chatbar layout to not extend under leftbar */
.ui-leftbar + .ui-main + .ui-rightbar + .ui-chatbar { grid-column: 2 / 3; }

/* Pipeline */
.agentic-box { margin-top: 0; background: #0f151f; border: 1px solid var(--border); border-radius: 10px; padding: 14px; position: sticky; top: 0; align-self: start; grid-column: 2; grid-row: 1 / 3; }
.agentic-title { color: var(--accent); font-size: 12px; letter-spacing: .2px; text-transform: uppercase; margin-bottom: 8px; }
.pipeline-step { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
.pipeline-step:last-child { border-bottom: none; }
.pipeline-step .dot { width: 10px; height: 10px; border-radius: 999px; background: #6a87ff; margin-top: 6px; }
.pipeline-step.done .dot { background: #12d47a; }
.pipeline-step.active .dot { background: #ffd166; }
.step-content { flex: 1; }
.step-title { color: var(--text); font-weight: 600; font-size: 13px; }
.step-sub { color: var(--muted); font-size: 12px; margin-top: 2px; }
.step-sublist { margin: 6px 0 0 0; padding-left: 0; color: var(--muted); font-size: 12px; list-style: disc; }

.ui-meta { color: var(--muted); font-size: 12px; }
.ui-table { display: grid; gap: 0; overflow-x: auto; }
.ui-thead, .ui-row { display: grid; grid-template-columns: 40px 200px 1fr 100px 120px 60px; align-items: stretch; min-width: 820px; }
.ui-thead { background: #0f151f; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.th, .td { padding: 10px 12px; border-bottom: 1px solid var(--border); }
.th { color: var(--muted); font-size: 11px; letter-spacing: .3px; }
.td { color: var(--text); font-size: 13px; }
.name { font-weight: 700; }
.sub { color: var(--muted); font-size: 12px; margin-top: 4px; }
.longtext { color: var(--muted); max-height: 260px; overflow: auto; padding-right: 6px; overflow-wrap: anywhere; word-break: break-word; white-space: normal; }
.longtext h4 { color: var(--text); margin: 8px 0 4px; font-size: 12px; letter-spacing: .2px; text-transform: uppercase; }
.longtext p { margin: 0 0 6px; }
.longtext ul { margin: 0 0 8px 18px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, 'Liberation Mono', monospace; }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 4px 8px; border-radius: 999px; border: 1px solid var(--border); background: rgba(0,255,120,.06); }
.pill-success .dot { width: 8px; height: 8px; border-radius: 999px; background: #12d47a; display: inline-block; }
.kebab { color: var(--muted); }

/* Split */
.split-inner { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 40px; align-items: center; }
#tradesync-go .split-inner { grid-template-columns: 0.6fr 1.4fr; gap: 32px; }
.bullets { margin: 12px 0 0 18px; color: var(--muted); display: grid; gap: 6px; }
.bullets--product { margin-bottom: 20px; }

/* Pro CTA vertical stack */
#tradesync-pro .cta-group { display: grid; gap: 10px; justify-content: start; }

/* Interface demo in split layout */
.split-media .ui-frame { 
  width: 100%; 
  height: 580px; 
  min-height: 580px;
}
.split-media .ui-table { 
  max-height: 360px; 
  overflow-y: auto; 
}
.split-media .longtext { 
  max-height: 240px; 
  overflow-y: auto; 
}

/* Tighten TradeSync Pro mock height: remove extra space below scrollbar */
#tradesync-pro .split-media .ui-frame {
  height: auto;
  min-height: 0;
}

/* Features Section */
.features-section { 
  margin-top: 60px; 
  text-align: center; 
}
.features-title { 
  font-size: 28px; 
  margin-bottom: 40px; 
  color: var(--text); 
}
.features-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
  gap: 24px; 
  margin-top: 30px; 
}
.feature-card { 
  background: var(--panel); 
  border: 1px solid var(--border); 
  border-radius: var(--radius); 
  padding: 24px; 
  text-align: center; 
  transition: transform .2s ease, box-shadow .2s ease; 
}
.feature-card:hover { 
  transform: translateY(-4px); 
  box-shadow: 0 15px 35px rgba(0,0,0,0.3); 
}
.feature-icon { 
  font-size: 32px; 
  margin-bottom: 16px; 
  display: block; 
}
.feature-card h4 { 
  color: var(--text); 
  margin: 0 0 12px; 
  font-size: 18px; 
  font-weight: 600; 
}
.feature-card p { 
  color: var(--muted); 
  margin: 0; 
  line-height: 1.5; 
  font-size: 14px; 
}

/* Platform */
.cards-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 12px; }

/* Solutions */
.tiles { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; margin-top: 14px; }
.tile { background: var(--panel); border: 1px solid var(--border); border-radius: 12px; padding: 18px; text-align: center; color: var(--muted); }

/* KPIs */
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; position: relative; z-index: 1; }
.kpi { background: var(--glass); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; text-align: center; position: relative; z-index: 1; }
.kpi-value { font-size: 28px; font-weight: 800; }
.kpi-label { color: var(--muted); }

/* Security */
.security .grid-2 { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 40px; }

/* Results section seam fix */
.results { position: relative; }
.results::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; height: 120px;
  background: linear-gradient(to bottom, rgba(7,10,15,0.9), rgba(7,10,15,0));
  z-index: 0;
  pointer-events: none;
}

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 22px 0; background: rgba(0,0,0,.2); position: relative; z-index: 1; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.footer-nav { display: flex; gap: 14px; color: var(--muted); }
.legal { color: var(--muted); font-size: 14px; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* Responsive */
@media (max-width: 1100px) {
  .hero-inner, .split-inner, .security .grid-2 { grid-template-columns: 1fr; }
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .tiles { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 720px) {
  .nav-toggle { display: inline-flex; }
  .nav { position: absolute; top: 72px; left: 0; right: 0; background: rgba(7,10,15,.98); display: none; flex-direction: column; align-items: flex-start; gap: 10px; padding: 12px 20px; border-bottom: 1px solid var(--border); }
  .nav.open { display: flex; }
  
  /* Mobile dropdown adjustments */
  .dropdown { width: 100%; }
  .dropdown-toggle { 
    width: 100%; 
    justify-content: space-between; 
    padding: 8px 0; 
    border-bottom: 1px solid rgba(255,255,255,.1);
  }
  .dropdown-menu { 
    position: static; 
    opacity: 0; 
    visibility: hidden; 
    transform: none; 
    background: transparent; 
    border: none; 
    box-shadow: none; 
    padding: 0 0 0 20px; 
    margin-top: 8px;
    min-width: auto;
  }
  .dropdown.active .dropdown-menu { 
    opacity: 1; 
    visibility: visible; 
    transform: none; 
  }
  .dropdown-menu a { 
    padding: 8px 0; 
    border-bottom: 1px solid rgba(255,255,255,.1);
  }
  
  /* Mobile features adjustments */
  .features-grid { 
    grid-template-columns: 1fr; 
    gap: 20px; 
  }
  .features-section { 
    margin-top: 40px; 
  }
  .features-title { 
    font-size: 24px; 
    margin-bottom: 30px; 
  }
  
  /* Mobile TradeSync Go interface adjustments */
  .ui-content { 
    grid-template-columns: 1fr; 
  }
  .ui-leftbar { 
    border: none; 
    border-top: 1px solid var(--border); 
  }
  .ui-classification { grid-template-columns: 1fr; }
  .ui-chatbar { 
    flex-direction: column; 
    align-items: stretch; 
    gap: 8px; 
  }
  
  .cards-grid { grid-template-columns: 1fr; }
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .hero-inner { grid-template-columns: 1fr; }
  .split-inner { grid-template-columns: 1fr; }
  .security .grid-2 { grid-template-columns: 1fr; }
  .hero .lead { font-size: 16px; }
  .hero .cta-group { margin-top: 14px; }
}

@media (max-width: 380px) {
  .display { font-size: 30px; }
}

/* Accessibility */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }


