/* ============================================================
   GlycoNex — Shared site CSS
   Inherits design tokens from tokens.css.
   Loaded by every page. Page-specific styles stay inline.
   ============================================================ */

/* ---------- RESET / BASE ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  color: var(--color-text-main);
  background: var(--color-bg-main);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  font-weight: 700;
  letter-spacing: -0.015em;
  margin: 0;
  color: var(--color-text-main);
}
h1 { font-size: clamp(40px, 5vw, 60px); line-height: 1.05; letter-spacing: -0.025em; }
h2 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.15; }
h3 { font-size: 22px; line-height: 1.3; font-weight: 600; }
p  { margin: 0; }
a  { color: inherit; text-decoration: none; }

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-brand-deep);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* ---------- TYPE UTILITIES ---------- */
.mono {
  font-family: "JetBrains Mono", ui-monospace, monospace;
}
.eyebrow {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-text-muted);
  font-weight: 500;
  font-family: "Inter", sans-serif;
}

/* ---------- LAYOUT ---------- */
.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 32px;
}

.section { padding: 80px 0; }
.section.alt { background: var(--color-bg-alt); }
.section-head { text-align: center; margin-bottom: 56px; }
.section-head .eyebrow { display: block; margin-bottom: 14px; }
.section-head h2 { max-width: 720px; margin: 0 auto; }

/* ---------- NAV ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: transparent;
  transition: background 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled,
.nav.solid {
  background: var(--color-bg-main);
  box-shadow: var(--shadow-sm);
  border-bottom-color: var(--color-border);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  height: 92px;
}
.nav-logo {
  display: flex;
  align-items: center;
  padding: 8px 16px 8px 0;
}
.nav-logo img { height: 60px; width: auto; display: block; }
.nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
  list-style: none;
  padding: 0; margin: 0;
  font-size: 15px;
  font-weight: 500;
}
.nav-links a {
  color: var(--color-text-main);
  transition: color 150ms ease;
  padding: 8px 0;
  position: relative;
}
.nav-links a:hover { color: var(--color-brand-deep); }
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 2px;
  height: 2px;
  background: var(--color-brand-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 200ms ease;
}
.nav-links a:hover::after { transform: scaleX(1); }
.nav-links a.current { color: var(--color-brand-deep); }
.nav-links a.current::after { transform: scaleX(1); }

.nav-right { display: flex; align-items: center; gap: 16px; }

.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--color-text-muted);
  font-weight: 500;
}
.lang-toggle button {
  background: none;
  border: none;
  padding: 4px 6px;
  color: inherit;
  cursor: pointer;
  font: inherit;
  border-radius: var(--radius-sm);
}
.lang-toggle button.active { color: var(--color-text-main); font-weight: 600; }
.lang-toggle .sep { opacity: 0.5; }

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: 15px;
  padding: 11px 20px;
  border-radius: var(--radius-md);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: all 180ms ease;
  line-height: 1;
  white-space: nowrap;
}
.btn-outline {
  border-color: var(--color-brand-primary);
  color: var(--color-brand-deep);
  background: transparent;
}
.btn-outline:hover {
  background: var(--color-brand-primary);
  color: white;
}
.btn-primary {
  background: var(--color-brand-primary);
  color: white;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: var(--color-brand-deep);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.btn-on-amber {
  background: var(--color-brand-primary);
  color: white;
  box-shadow: var(--shadow-md);
  padding: 16px 36px;
  font-size: 16px;
  border-radius: var(--radius-md);
}
.btn-on-amber:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  background: var(--color-brand-deep);
}
.btn-ghost {
  background: transparent;
  color: var(--color-text-main);
  border-color: rgba(28,28,28,0.25);
  padding: 16px 28px;
  font-size: 16px;
}
.btn-ghost:hover {
  border-color: var(--color-text-main);
  background: rgba(255,255,255,0.4);
}

/* ---------- ARROW LINK ---------- */
.arrow-link {
  color: var(--color-brand-deep);
  font-weight: 600;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 200ms ease;
}
.arrow-link:hover { gap: 10px; }
.arrow-link.aqua { color: var(--color-accent-aqua); }

/* ---------- PILL ---------- */
.pill {
  display: inline-block;
  background: var(--color-brand-light);
  color: var(--color-brand-deep);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}
.pill.aqua { background: rgba(13, 148, 136, 0.12); color: var(--color-accent-aqua); }

/* ---------- BADGE ---------- */
.badge {
  display: inline-block;
  background: var(--color-status-milestone);
  color: white;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
}

/* ---------- CTA BAND (champagne gradient) ---------- */
.cta-band {
  background: linear-gradient(135deg, var(--color-brand-light) 0%, #F5DBA0 100%);
  color: var(--color-text-main);
  padding: 96px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='40' height='35' viewBox='0 0 40 35'><polygon points='20,1 38,11 38,27 20,37 2,27 2,11' fill='none' stroke='%23B8730E' stroke-width='1'/></svg>");
  opacity: 0.08;
  pointer-events: none;
}
.cta-inner {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
}
.cta-band h2 {
  color: var(--color-text-main);
  font-size: 40px;
  margin-bottom: 20px;
  font-weight: 600;
}
.cta-band p {
  color: var(--color-text-muted);
  font-size: 18px;
  line-height: 1.5;
  margin-bottom: 36px;
}
.cta-buttons {
  display: inline-flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ---------- FOOTER ---------- */
footer {
  background: var(--color-text-main);
  color: rgba(255,255,255,0.7);
  padding: 64px 0 24px;
  font-size: 14px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
}
.footer-grid h4 {
  color: white;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 18px;
  font-family: "Inter", sans-serif;
  font-weight: 600;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 10px; }
.footer-grid a {
  color: rgba(255,255,255,0.7);
  transition: color 150ms ease;
}
.footer-grid a:hover { color: var(--color-brand-primary); }
.footer-logo img {
  height: 36px;
  margin-bottom: 16px;
  display: block;
}
.footer-tagline {
  color: rgba(255,255,255,0.85);
  font-size: 14px;
  margin-bottom: 16px;
  line-height: 1.5;
}
.footer-address {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  line-height: 1.6;
}
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 13px;
  color: rgba(255,255,255,0.5);
}
.footer-bottom .dot { opacity: 0.4; margin: 0 8px; }

/* ---------- ANIMATIONS ---------- */
.fade-up {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 600ms ease-out, transform 600ms ease-out;
}
.fade-up.show {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- RESPONSIVE (shared chrome) ---------- */
@media (max-width: 1024px) {
  .nav-links { display: none; }
}
@media (max-width: 768px) {
  .container { padding: 0 20px; }
  .section { padding: 48px 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; }
  .cta-band { padding: 64px 0; }
  .cta-band h2 { font-size: 28px; }
}

/* ---------- PRINT (shared) ---------- */
@media print {
  .nav, .cta-band, footer { display: none !important; }
  body { background: white; color: black; }
  a { color: black; text-decoration: none; }
}
