﻿/*!
 * main.css — Haelixa (haelisa.com)
 * Biotech / Life Sciences — DNA Molecular Traceability
 */

/* ============================
   CSS Variables
   ============================ */
:root {
  --bg: #0b1220;
  --surface: #111c30;
  --surface-alt: #172035;
  --surface-hover: #1e2d47;
  --text: #dde4ee;
  --text-muted: #7e90a8;
  --accent: #059669;
  --accent-hover: #047857;
  --accent-light: rgba(5,150,105,0.12);
  --border: rgba(255,255,255,0.08);
  --border-accent: rgba(5,150,105,0.35);
  --radius: 10px;
  --radius-sm: 6px;
  --gap: 2.5rem;
  --nav-height: 4.5rem;
  --funding-bar-h: 0px;
}

/* ============================
   Reset & Base
   ============================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Segoe UI', 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 1rem;
  line-height: 1.75;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-hover); }

h1, h2, h3, h4, h5 {
  font-weight: 700;
  line-height: 1.2;
  color: #ffffff;
  margin-bottom: 0.75em;
}
h1 { font-size: 2.6rem; }
h2 { font-size: 1.9rem; }
h3 { font-size: 1.35rem; }
h4 { font-size: 1.1rem; }

p { margin-bottom: 1.2em; color: var(--text); }
p:last-child { margin-bottom: 0; }

ul, ol { padding-left: 1.5em; }
li { margin-bottom: 0.4em; }

img { max-width: 100%; height: auto; display: block; }

/* ============================
   Nav
   ============================ */
#nav {
  position: fixed;
  top: var(--funding-bar-h, 0px);
  left: 0;
  right: 0;
  width: 100%;
  height: var(--nav-height);
  background: rgba(11,18,32,0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2.5rem;
  z-index: 10000;
  box-sizing: border-box;
}

.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.logo img { height: 34px; width: auto; display: block; }

nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0;
  margin: 0;
  padding: 0;
}

nav ul li a {
  display: flex;
  align-items: center;
  height: var(--nav-height);
  padding: 0 1.1rem;
  color: rgba(255,255,255,0.7);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: color 0.2s;
}
nav ul li a:hover { color: #ffffff; }
nav ul li.active > a { color: var(--accent); }

.nav-cta a {
  background: var(--accent) !important;
  color: #fff !important;
  border-radius: var(--radius-sm) !important;
  padding: 0.5rem 1.2rem !important;
  height: auto !important;
  margin-left: 0.8rem;
}
.nav-cta a:hover { background: var(--accent-hover) !important; }

#page-wrapper {
  padding-top: calc(var(--nav-height) + var(--funding-bar-h, 0px));
}

/* Mobile nav */
#nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
}
#nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.8);
  border-radius: 2px;
  transition: all 0.25s;
}

@media (max-width: 900px) {
  #nav-toggle { display: flex; }
  nav ul {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0; right: 0;
    background: rgba(11,18,32,0.98);
    flex-direction: column;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border);
    gap: 0;
  }
  nav ul.open { display: flex; }
  nav ul li a { height: auto; padding: 0.75rem 2rem; width: 100%; }
  .nav-cta a { margin: 0.5rem 2rem; width: calc(100% - 4rem) !important; text-align: center; display: block !important; }
}

/* ============================
   Hero
   ============================ */

.hero {
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 2rem;
  position: relative;
  overflow: hidden;
  background: linear-gradient(160deg, #0b1220 0%, #0e1e35 50%, #0a1a10 100%);
  background-image: url('../images/hero-main.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: rgba(5,25,15,0.30);
  background-blend-mode: multiply;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 30% 50%, rgba(5,150,105,0.12) 0%, transparent 70%),
    radial-gradient(ellipse 50% 60% at 70% 30%, rgba(5,150,105,0.06) 0%, transparent 70%);
  pointer-events: none;
}
.hero > * {
  position: relative;
  z-index: 2;
}


.hero-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(5,150,105,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(5,150,105,0.06) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 820px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent-light);
  border: 1px solid var(--border-accent);
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  margin-bottom: 1.8rem;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  color: #ffffff;
  margin-bottom: 1.2rem;
  font-weight: 800;
  line-height: 1.1;
}
.hero h1 .accent { color: var(--accent); }

.hero p {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto 2.4rem;
  line-height: 1.75;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}
.btn-primary { background: var(--accent); color: #ffffff; }
.btn-primary:hover { background: var(--accent-hover); color: #ffffff; transform: translateY(-1px); box-shadow: 0 8px 24px rgba(5,150,105,0.3); }
.btn-outline { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }

.hero-cta { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-top: 4rem;
  flex-wrap: wrap;
}
.hero-stat { text-align: center; }
.hero-stat .num {
  font-size: 2rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
  margin-bottom: 0.3rem;
}
.hero-stat .num span { color: var(--accent); }
.hero-stat .label { font-size: 0.78rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.1em; }

/* ============================
   Sections
   ============================ */
section { padding: 5.5rem 2rem; }
.section-alt { background: var(--surface); }

.container { max-width: 1100px; margin: 0 auto; }
.container-sm { max-width: 820px; margin: 0 auto; }

.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-header .eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.section-header h2 { font-size: 2.1rem; color: #fff; margin-bottom: 0.75rem; }
.section-header p { color: var(--text-muted); font-size: 1.05rem; max-width: 580px; margin: 0 auto; }

/* ============================
   Cards / Grids
   ============================ */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--gap);
  align-items: stretch;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  transition: border-color 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
}
.card:hover { border-color: var(--border-accent); transform: translateY(-3px); }

.card-icon {
  width: 48px; height: 48px;
  background: var(--accent-light);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.25rem;
  flex-shrink: 0;
}
.card-icon svg { width: 24px; height: 24px; stroke: var(--accent); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.card h3 { font-size: 1.1rem; color: #fff; margin-bottom: 0.6rem; }
.card p { font-size: 0.92rem; color: var(--text-muted); line-height: 1.65; flex: 1; }

/* ============================
   Team
   ============================ */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
}

.team-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-align: center;
  transition: border-color 0.2s, transform 0.2s;
}
.team-card:hover { border-color: var(--border-accent); transform: translateY(-3px); }

.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-body { padding: 1.4rem 1.2rem; }
.team-card h3 { font-size: 1rem; color: #fff; margin-bottom: 0.25rem; }
.team-card .role { font-size: 0.82rem; color: var(--accent); font-weight: 600; margin-bottom: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; }
.team-card p { font-size: 0.85rem; color: var(--text-muted); line-height: 1.6; }

/* ============================
   News / Articles
   ============================ */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

.article-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.8rem;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s, transform 0.2s;
}
.article-card:hover { border-color: var(--border-accent); transform: translateY(-2px); }

.article-card.pinned {
  border-left: 3px solid var(--accent, #059669);
  background: rgba(5,150,105,0.06);
}

.tag {
  display: inline-block;
  background: var(--surface-alt);
  color: var(--text-muted);
  padding: 0.2em 0.65em;
  border-radius: 3px;
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 0.9rem;
}
.tag.funding {
  background: var(--accent, #059669);
  color: #fff;
  padding: 0.2em 0.6em;
  border-radius: 3px;
  font-size: 0.75em;
  font-weight: 700;
  text-transform: uppercase;
}

.article-card h2 { font-size: 1.08rem; color: #ffffff; line-height: 1.4; margin-bottom: 0.6rem; }
.article-card h2 a { color: inherit; }
.article-card h2 a:hover { color: var(--accent); }
.article-card .excerpt { font-size: 0.88rem; color: var(--text-muted); line-height: 1.65; flex: 1; margin-bottom: 1rem; }
.article-card time { font-size: 0.78rem; color: var(--text-muted); display: block; margin-bottom: 0; }
.article-card .read-more { font-size: 0.82rem; color: var(--accent); font-weight: 600; margin-top: 1rem; display: inline-flex; align-items: center; gap: 0.3rem; }

/* Article page */
.article-page { max-width: 760px; margin: 0 auto; padding: 3rem 2rem 5rem; }
.article-page .article-meta { display: flex; align-items: center; gap: 1rem; margin-bottom: 2rem; flex-wrap: wrap; }
.article-page time { font-size: 0.85rem; color: var(--text-muted); }
.article-page h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); color: #fff; margin-bottom: 1rem; }
.article-page .lead { font-size: 1.1rem; color: var(--text-muted); line-height: 1.75; margin-bottom: 2rem; border-left: 3px solid var(--accent); padding-left: 1.2rem; }
.article-page h2 { font-size: 1.45rem; margin-top: 2.5rem; margin-bottom: 0.8rem; }
.article-page h3 { font-size: 1.15rem; margin-top: 2rem; margin-bottom: 0.6rem; }
.article-page p { color: var(--text); margin-bottom: 1.4em; }
.article-page ul, .article-page ol { color: var(--text); margin-bottom: 1.4em; }
.article-page li { margin-bottom: 0.5em; }
.article-back { display: inline-flex; align-items: center; gap: 0.4rem; color: var(--text-muted); font-size: 0.88rem; margin-bottom: 2rem; }
.article-back:hover { color: var(--accent); }
.article-divider { border: none; border-top: 1px solid var(--border); margin: 2.5rem 0; }

/* ============================
   Cookie Banner
   ============================ */
#cookie-banner {
  background: var(--surface);
  color: var(--text);
  padding: 1.2rem 2rem;
  border-top: 1px solid var(--border);
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 9999;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.3);
  flex-wrap: wrap;
}
#cookie-banner p { margin: 0; font-size: 0.88rem; color: var(--text-muted); flex: 1; min-width: 200px; }
#cookie-banner a { color: var(--accent); }
.cookie-buttons { display: flex; gap: 0.75rem; flex-shrink: 0; }
#cookie-banner button { border: none; padding: 0.5rem 1.3rem; border-radius: var(--radius-sm); cursor: pointer; font-size: 0.85rem; font-weight: 600; }
#cookie-accept { background: var(--accent); color: #fff; }
#cookie-accept:hover { background: var(--accent-hover); }
#cookie-decline { background: transparent; color: var(--text-muted); border: 1px solid var(--border) !important; }
#cookie-decline:hover { border-color: var(--accent) !important; color: var(--accent); }

/* ============================
   Footer
   ============================ */
#footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 4rem 2rem 2rem;
}
#footer .inner {
  padding: 0 4em;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  gap: 3rem;
  flex-wrap: wrap;
}
#footer .footer-brand { flex: 2; min-width: 220px; }
#footer .footer-brand .logo { margin-bottom: 1rem; }
#footer .footer-brand p { font-size: 0.88rem; color: var(--text-muted); line-height: 1.7; max-width: 280px; }
#footer section { flex: 1; min-width: 160px; }
#footer section h4 { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; color: rgba(255,255,255,0.5); margin-bottom: 1.2rem; }
.footer-nav { list-style: none; padding: 0; margin: 0; }
.footer-nav li { margin-bottom: 0; }
.footer-nav a { color: var(--text-muted); font-size: 0.88rem; display: block; padding: 0.3rem 0; transition: color 0.2s; }
.footer-nav a:hover { color: var(--accent); }
.copyright {
  max-width: 1100px;
  margin: 2.5rem auto 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
}

/* ============================
   Page-specific
   ============================ */
/* About */
.about-hero { padding: 5rem 2rem 4rem; text-align: center; }
.about-hero h1 { font-size: clamp(2rem, 4.5vw, 3rem); }
.about-body { padding: 0 2rem 5rem; }

/* Product */
.product-hero {
  padding: 5rem 2rem;
  background: linear-gradient(160deg, var(--bg), var(--surface));
  text-align: center;
}

/* Stat Bar */
.stat-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.stat-bar-item {
  padding: 2.5rem 2rem;
  text-align: center;
  border-right: 1px solid var(--border);
}
.stat-bar-item:last-child { border-right: none; }
.stat-bar-item .num { font-size: 2.1rem; font-weight: 800; color: #fff; line-height: 1; }
.stat-bar-item .num span { color: var(--accent); }
.stat-bar-item .label { font-size: 0.82rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.1em; margin-top: 0.4rem; }

/* Process steps */
.steps { counter-reset: step; display: flex; flex-direction: column; gap: 2rem; }
.step { display: flex; gap: 1.5rem; align-items: flex-start; }
.step-num {
  width: 40px; height: 40px;
  background: var(--accent-light);
  border: 1px solid var(--border-accent);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; font-weight: 700; color: var(--accent);
  flex-shrink: 0;
  counter-increment: step;
}
.step-content h3 { font-size: 1.05rem; margin-bottom: 0.4rem; }
.step-content p { font-size: 0.9rem; color: var(--text-muted); margin: 0; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.contact-info h2 { margin-bottom: 1rem; }
.contact-info p { color: var(--text-muted); }
.contact-details { margin-top: 2rem; display: flex; flex-direction: column; gap: 1.2rem; }
.contact-detail { display: flex; gap: 1rem; align-items: flex-start; }
.contact-detail-icon { width: 40px; height: 40px; background: var(--accent-light); border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.contact-detail-icon svg { width: 18px; height: 18px; stroke: var(--accent); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.contact-detail-body .label { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); margin-bottom: 0.2rem; }
.contact-detail-body .value { font-size: 0.95rem; color: var(--text); }

/* Legal */
.legal-page { max-width: 780px; margin: 0 auto; padding: 3rem 2rem 5rem; }
.legal-page h1 { font-size: 2rem; margin-bottom: 0.5rem; }
.legal-page .last-updated { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 2.5rem; }
.legal-page h2 { font-size: 1.3rem; margin-top: 2.5rem; margin-bottom: 0.8rem; color: #fff; }
.legal-page h3 { font-size: 1.05rem; margin-top: 1.8rem; margin-bottom: 0.6rem; }
.legal-page p { color: var(--text-muted); margin-bottom: 1.2em; }
.legal-page ul { color: var(--text-muted); margin-bottom: 1.2em; }
.legal-page table { width: 100%; border-collapse: collapse; margin-bottom: 1.5em; font-size: 0.9rem; }
.legal-page th, .legal-page td { padding: 0.75rem 1rem; border: 1px solid var(--border); text-align: left; }
.legal-page th { background: var(--surface-alt); color: rgba(255,255,255,0.8); font-weight: 600; }
.legal-page td { color: var(--text-muted); }

/* Testimonials */
.testimonials { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.testimonial {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
}
.testimonial blockquote { font-size: 0.95rem; color: var(--text); line-height: 1.75; margin-bottom: 1.2rem; font-style: italic; }
.testimonial cite { display: flex; align-items: center; gap: 0.75rem; font-style: normal; }
.testimonial cite img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; object-position: 50% 20%; }
.testimonial cite .cite-info .name { font-size: 0.88rem; font-weight: 700; color: #fff; }
.testimonial cite .cite-info .title { font-size: 0.78rem; color: var(--text-muted); }

/* CTA Section */
.cta-section {
  background: linear-gradient(135deg, rgba(5,150,105,0.15) 0%, var(--surface) 100%);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius);
  padding: 4rem 3rem;
  text-align: center;
  margin: 4rem 0;
}
.cta-section h2 { font-size: 2rem; margin-bottom: 0.75rem; }
.cta-section p { color: var(--text-muted); margin-bottom: 2rem; }

/* Highlights / Feature list */
.feature-list { display: flex; flex-direction: column; gap: 1.2rem; }
.feature-list-item { display: flex; gap: 1rem; align-items: flex-start; }
.feature-list-item .check { width: 22px; height: 22px; background: var(--accent-light); border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 2px; }
.feature-list-item .check::after { content: '✓'; font-size: 0.7rem; font-weight: 700; color: var(--accent); }
.feature-list-item p { color: var(--text-muted); font-size: 0.92rem; margin: 0; }

/* Pill badges */
.pill { display: inline-block; background: var(--accent-light); color: var(--accent); border: 1px solid var(--border-accent); padding: 0.3em 0.9em; border-radius: 20px; font-size: 0.78rem; font-weight: 600; letter-spacing: 0.05em; }

/* Two-col layout */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.two-col.reverse .col-img { order: -1; }

/* Responsive */
@media (max-width: 768px) {
  h1 { font-size: 1.9rem; }
  h2 { font-size: 1.5rem; }
  section { padding: 4rem 1.5rem; }
  .two-col { grid-template-columns: 1fr; gap: 2.5rem; }
  .two-col.reverse .col-img { order: 0; }
  .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .stat-bar { grid-template-columns: 1fr 1fr; }
  .stat-bar-item { border-right: none; border-bottom: 1px solid var(--border); }
  .hero-stats { gap: 2rem; }
  .cta-section { padding: 2.5rem 1.5rem; }
  #nav { padding: 0 1.5rem; }
  .news-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .stat-bar { grid-template-columns: 1fr; }
  .hero h1 { font-size: 1.75rem; }
}




/* Hero contrast overlay — WCAG AA (R-IMG8) */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 0;
  pointer-events: none;
}

/* Hero text contrast — force readable white (R-IMG8) */
.hero p,
.hero .hero-stat .label,
.hero .stat-label,
.hero .hero-subtitle,
.hero .text-muted {
  color: rgba(255,255,255,0.82);
}
