/* =====================================================
   Extropic AI Ventures — main.css
   Theme: dark | Accent: #e74c3c
   ===================================================== */

/* ---------- CSS Variables ---------- */
:root {
  --accent:        #e74c3c;
  --accent-dark:   #c0392b;
  --bg:            #0d1117;
  --bg-alt:        #161b22;
  --surface:       #1c2128;
  --surface2:      #21262d;
  --border:        rgba(255,255,255,0.10);
  --text:          #e6edf3;
  --text-muted:    #8b949e;
  --nav-height:    72px;
  --sidebar-w:     280px;
  --radius:        8px;
}

/* ---------- Reset & Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
img { max-width: 100%; display: block; }

body {
  font-family: 'Roboto', system-ui, sans-serif;
  font-size: 18px !important;
  line-height: 1.9;
  color: var(--text) !important;
  background-color: var(--bg) !important;
  overflow-x: hidden;
}

/* ---------- Typography ---------- */
h1 { font-size: 61px !important; line-height: 1.1; font-weight: 800; color: #ffffff; }
h2 { font-size: 43px !important; line-height: 1.2; font-weight: 700; color: #ffffff; }
h3 { font-size: 28px !important; line-height: 1.3; font-weight: 600; color: #ffffff; }
h4 { font-size: 19px !important; font-weight: 600; color: #ffffff; }
h5, h6 { color: #ffffff; }

p { color: rgba(255,255,255,0.88); line-height: 1.9; margin-bottom: 1rem; }
a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-dark); }
ul { list-style: none; padding: 0; margin: 0; }

/* ---------- Funding Bar (index.html ONLY, position:fixed) ---------- */
#funding-bar {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1100;
  background: var(--accent-dark);
  color: #ffffff;
  padding: 10px 5%;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
}
#funding-bar a, #funding-bar strong, #funding-bar span { color: #ffffff !important; }
#funding-bar a { text-decoration: underline; }
#funding-bar button {
  color: rgba(255,255,255,0.85) !important;
  background: transparent;
  border: none;
  font-size: 18px;
  cursor: pointer;
  line-height: 1;
  padding: 0 4px;
}

/* ---------- Navigation Sidebar ---------- */
.responsive-nav { position: relative; }

#menu-toggle {
  z-index: 1050;
  cursor: pointer;
  position: fixed;
  top: 0; left: 0;
  color: #ffffff;
  background-color: var(--accent);
  width: 66px;
  height: 66px;
  line-height: 66px;
  text-align: center;
  display: none;
  font-size: 23px !important;
}

#menu-close {
  cursor: pointer;
  text-align: center;
  color: #ffffff;
  background-color: var(--accent);
  width: 100%;
  height: 66px;
  line-height: 66px;
  display: none;
  font-size: 23px !important;
}

#menu {
  position: fixed !important;
  top: 0; left: 0;
  width: var(--sidebar-w);
  height: 100vh;
  max-height: 100vh;
  background-color: var(--bg-alt);
  border-right: 1px solid var(--border);
  z-index: 1000;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0;
  box-sizing: border-box;
}

#menu .menu-inner {
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

#menu .brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 0 2rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
}

#menu .brand img { width: 140px; height: auto; }

.main-nav { flex: 1; }
.main-nav ul { display: block; }
.main-nav ul li { display: block; margin-bottom: 0.25rem; }
.main-nav ul li a {
  display: block;
  padding: 0.65rem 1rem;
  font-size: 15px !important;
  font-weight: 600;
  color: rgba(255,255,255,0.80);
  border-radius: 6px;
  transition: all 0.2s;
  letter-spacing: 0.3px;
}
.main-nav ul li a:hover,
.main-nav ul li.active a {
  background: var(--accent);
  color: #ffffff;
}

.menu-footer {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 12px !important;
  color: var(--text-muted);
}

/* ---------- Content Area ---------- */
.page-top {
  padding-top: 0;
}

#content-area {
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  padding-right: calc(var(--sidebar-w) * 0.5);
}
#content-area .container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 48px;
  padding-right: 48px;
  box-sizing: border-box;
}

/* ---------- Funding bar body offset ---------- */
body.has-funding-bar #content-area { /* JS applies margin-top via funding bar height */ }

/* ---------- Container ---------- */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem;
  box-sizing: border-box;
}

/* ---------- Sections ---------- */
.section {
  padding: 120px 0;
  width: 100% !important;
  left: auto !important;
  right: auto !important;
  position: static !important;
  min-height: auto !important;
  border-bottom: none !important;
}
.section-sm { padding: 72px 0; }

.section-header {
  text-align: center;
  margin-bottom: 64px;
}
.section-label {
  display: inline-block;
  font-size: 12px !important;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.section-title { margin-bottom: 1rem; }
.section-subtitle {
  color: var(--text-muted);
  font-size: 16px !important;
  max-width: 600px;
  margin: 0 auto;
}

/* ---------- Page Hero (inner pages) ---------- */
.page-hero {
  position: relative;
  min-height: 340px;
  display: flex;
  align-items: center;
  background-color: var(--bg-alt);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.62);
  z-index: 0;
  pointer-events: none;
}
.page-hero > * { position: relative; z-index: 1; }
.page-hero h1 { color: #ffffff; }
.page-hero p { color: rgba(255,255,255,0.82); }

/* ---------- Hero (index.html) ---------- */
#hero-main {
  position: relative;
  min-height: 620px;
  display: flex;
  align-items: center;
  background-color: rgba(5,10,30,0.35);
  background-image: url('../images/hero-main.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-blend-mode: multiply;
}
#hero-main::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 0;
  pointer-events: none;
}
#hero-main > * { position: relative; z-index: 2; }

.hero-content h1 { color: #ffffff; margin-bottom: 1rem; }
.hero-content p { color: rgba(255,255,255,0.88); font-size: 18px !important; max-width: 600px; margin-bottom: 2rem; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(231,76,60,0.18);
  border: 1px solid rgba(231,76,60,0.40);
  border-radius: 20px;
  padding: 0.35rem 1rem;
  font-size: 13px !important;
  font-weight: 600;
  color: #e74c3c;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.5rem;
}

.hero-stats {
  display: flex;
  gap: 3rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.15);
}
.hero-stat-val {
  font-size: 32px !important;
  font-weight: 800;
  color: #ffffff;
  display: block;
}
.hero-stat-lbl {
  font-size: 13px !important;
  color: rgba(255,255,255,0.65);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ---------- Buttons ---------- */
.btn-primary-custom, .btn-accent {
  display: inline-block;
  background: var(--accent);
  color: #ffffff !important;
  padding: 0.75em 2em;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 15px !important;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}
.btn-accent:hover { background: var(--accent-dark); transform: translateY(-1px); }

.btn-outline-light {
  display: inline-block;
  background: transparent;
  color: #ffffff !important;
  padding: 0.75em 2em;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 15px !important;
  border: 2px solid rgba(255,255,255,0.65);
  cursor: pointer;
  transition: all 0.2s;
}
.btn-outline-light:hover {
  background: rgba(255,255,255,0.10);
  border-color: #ffffff;
}

.btn-group { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ---------- Cards ---------- */
.card-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  margin-top: 48px;
}
.card-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 40px;
  margin-top: 48px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.25);
}
.card-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(231,76,60,0.12);
  border-radius: 10px;
  margin-bottom: 1.25rem;
  color: var(--accent);
  font-size: 21px !important;
}
.card h3 { margin-bottom: 0.75rem; }
.card p { color: var(--text-muted); margin: 0; font-size: 15px !important; }

/* ---------- About Page ---------- */
.spotlight-section {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 4em;
  align-items: start;
  max-width: 1100px;
  margin: 0 auto;
  padding: 4em 2em;
}
@media (max-width: 768px) { .spotlight-section { grid-template-columns: 1fr; } }

.story-img {
  width: 100%;
  overflow: hidden;
  border-radius: var(--radius);
}
.story-img img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  object-position: center;
  border-radius: var(--radius);
  display: block;
}

.about-hero {
  background-image: url('../images/about-hero.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: rgba(5,10,30,0.35);
  background-blend-mode: multiply;
}
.about-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 0;
  pointer-events: none;
}

/* ---------- Stats / Pillars ---------- */
.stats-bar {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 3rem 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 2rem;
  text-align: center;
}
.stat-value {
  font-size: 35px !important;
  font-weight: 800;
  color: var(--accent);
  display: block;
  line-height: 1.1;
}
.stat-label {
  font-size: 13px !important;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 0.4rem;
}

/* ---------- Team ---------- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.team-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2em 1.5em;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}
.team-card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(0,0,0,0.3); }

.team-card img {
  width: 100%;
  max-width: 160px;
  aspect-ratio: 1/1;
  border-radius: 8px;
  object-fit: cover;
  object-position: 50% 10%;
  display: block;
  margin: 0 auto 1.2rem;
}

.team-card h3 { margin-bottom: 0.25rem; font-size: 19px !important; }
.team-role {
  color: var(--accent);
  font-size: 14px !important;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.75rem;
}
.team-bio { color: var(--text-muted); font-size: 14px !important; line-height: 1.65; margin: 0; }

/* ---------- Portfolio ---------- */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.portfolio-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: transform 0.2s, box-shadow 0.2s;
}
.portfolio-card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(0,0,0,0.3); }

.portfolio-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}
.portfolio-company-name {
  font-size: 20px !important;
  font-weight: 700;
  color: #ffffff;
}
.portfolio-amount {
  font-size: 16px !important;
  font-weight: 700;
  color: var(--accent);
}
.portfolio-meta {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}
.portfolio-tag {
  background: rgba(231,76,60,0.12);
  color: var(--accent);
  border-radius: 4px;
  padding: 0.15rem 0.6rem;
  font-size: 12px !important;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.portfolio-stage {
  background: rgba(255,255,255,0.06);
  color: var(--text-muted);
  border-radius: 4px;
  padding: 0.15rem 0.6rem;
  font-size: 12px !important;
  font-weight: 600;
}
.portfolio-desc { color: var(--text-muted); font-size: 15px !important; line-height: 1.65; margin: 0; }

/* ---------- Insights Listing ---------- */
.insights-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  margin-top: 48px;
}
.insight-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}
.insight-card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(0,0,0,0.3); }
.insight-card-thumb {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  object-position: center;
  display: block;
}
.insight-card-body { padding: 1.25rem; }
.insight-card-meta { font-size: 12px !important; color: var(--text-muted); margin-bottom: 0.5rem; }
.insight-card-title {
  font-size: 16px !important;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.4;
  margin-bottom: 0.5rem;
}
.insight-card-excerpt { font-size: 14px !important; color: var(--text-muted); margin: 0; }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } }

.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.contact-info-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(231,76,60,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 16px !important;
  flex-shrink: 0;
}
.contact-info-text h4 { font-size: 14px !important; font-weight: 700; color: #ffffff; margin-bottom: 0.2rem; text-transform: uppercase; letter-spacing: 0.04em; }
.contact-info-text p { color: var(--text-muted); font-size: 15px !important; margin: 0; line-height: 1.5; }

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: var(--text);
  font-size: 15px !important;
  margin-bottom: 1rem;
  outline: none;
  transition: border-color 0.2s;
}
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
}
.contact-form textarea { min-height: 130px; resize: vertical; }
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: var(--text-muted); }

/* ---------- Section: Alternating ---------- */
.section-alt { background: var(--bg-alt); }
.section-dark { background: var(--surface); }

/* ---------- Horizontal Divider ---------- */
.line-dec {
  width: 60px;
  height: 3px;
  background: var(--accent);
  margin: 1rem 0;
}

/* ---------- Anchor chip ---------- */
.vc-anchor {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.4rem 0.9rem;
  font-size: 13px !important;
  color: var(--text-muted);
  font-weight: 600;
}

/* ---------- Footer ---------- */
#footer {
  background-color: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 4em 2em 2em;
  width: 100%;
}
#footer .inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3em;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2em;
  align-items: start;
  box-sizing: border-box;
}
#footer h2 {
  color: #ffffff !important;
  font-size: 18px !important;
  font-weight: 600;
  margin: 0 0 1em;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
#footer p {
  color: var(--text-muted);
  font-size: 16px !important;
  line-height: 1.7;
  margin: 0;
}
.footer-nav { list-style: none; margin: 0; padding: 0; }
.footer-nav li { display: block; margin-bottom: 0.5em; }
.footer-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 16px !important;
  transition: color 0.2s;
}
.footer-nav a:hover { color: #ffffff; }
#footer .copyright {
  color: var(--text-muted);
  font-size: 15px !important;
  text-align: center;
  margin: 2.5em auto 0;
  padding-top: 1.5em;
  border-top: 1px solid var(--border);
  max-width: 1100px;
}
@media (max-width: 768px) { #footer .inner { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { #footer .inner { grid-template-columns: 1fr; } }

/* ---------- Cookie Banner ---------- */
#cookie-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 2000;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 1.25rem 2rem;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}
#cookie-banner p {
  color: var(--text-muted);
  font-size: 14px !important;
  margin: 0;
  flex: 1;
  min-width: 200px;
}
#cookie-banner a { color: var(--accent); }
.cookie-btn-group { display: flex; gap: 0.75rem; flex-shrink: 0; }

#cookie-accept, .cookie-btn {
  background: var(--accent);
  color: #fff !important;
  border: none;
  border-radius: 4px;
  padding: 0.5rem 1.25rem;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.cookie-btn.decline, #cookie-decline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted) !important;
}

/* ---------- Responsive: Mobile ---------- */
@media screen and (max-width: 845px) {
  #menu {
    width: 280px;
    transform: translateX(-100%);
    transition: transform 233ms cubic-bezier(0, 0, 0.21, 1);
  }
  #menu.open { transform: translateX(0); }
  #menu-toggle, #menu-close { display: block; }
  #content-area { margin-left: 0; padding-right: 0; }
  .hero-stats { flex-wrap: wrap; gap: 1.5rem; }
  h1 { font-size: 45px !important; }
  h2 { font-size: 32px !important; }
}

@media screen and (max-width: 480px) {
  body { font-size: 16px !important; }
  h1 { font-size: 35px !important; }
  h2 { font-size: 27px !important; }
  h3 { font-size: 21px !important; }
  #cookie-banner { flex-direction: column; align-items: flex-start; }
}

/* ---------- Overlay when sidebar open (mobile) ---------- */
#sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 999;
}
#sidebar-overlay.visible { display: block; }

/* ---------- CTA Section ---------- */
.cta-section {
  background: linear-gradient(135deg, var(--accent-dark) 0%, var(--accent) 100%);
  padding: 5rem 0;
  text-align: center;
}
.cta-section h2, .cta-section p { color: #ffffff !important; }
.cta-section h2 { color: #ffffff !important; }

/* ---------- Values / Pillars ---------- */
.pillars-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.pillar-item {
  text-align: center;
  padding: 2rem 1.5rem;
  background: var(--surface2);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.pillar-icon {
  font-size: 32px !important;
  color: var(--accent);
  margin-bottom: 1rem;
}
.pillar-item h3 { font-size: 18px !important; margin-bottom: 0.5rem; }
.pillar-item p { color: var(--text-muted); font-size: 14px !important; margin: 0; }

/* ---------- Image containers ---------- */
.feature-img-wrap {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  border-radius: var(--radius);
  display: block;
}
.feature-img-wrap img {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16/9;
  object-fit: cover;
}

/* ---------- Page-top offset for mobile (no sidebar) ---------- */
@media (max-width: 845px) {
  .page-hero { padding-top: 80px; }
}