/* MIT-OX Nutrition System — styles */

:root {
  --bg: #f6f6f3;
  --bg-soft: #ecede7;
  --ink: #0a0a0a;
  --ink-soft: #1f1f1f;
  --muted: #6b6b6b;
  --line: rgba(10, 10, 10, 0.12);
  --green: #7cc142;
  --green-deep: #5fa531;
  --blue: #2ea9df;
  --yellow: #f6d041;
  --white: #ffffff;

  --container: 1280px;
  --radius: 14px;
  --radius-lg: 22px;

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --shadow-1: 0 1px 2px rgba(0,0,0,0.04), 0 8px 24px rgba(0,0,0,0.06);
  --shadow-2: 0 24px 60px rgba(10,10,10,0.18);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: clamp(15px, 1vw + 0.5rem, 17px);
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

.skip {
  position: absolute; left: -9999px; top: 8px;
  background: var(--ink); color: var(--white);
  padding: 8px 12px; border-radius: 6px; z-index: 1000;
}
.skip:focus { left: 8px; }

.mono { font-family: var(--font-mono); letter-spacing: 0.02em; }

/* ---------- NAV ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(246,246,243,0.85);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, background .3s ease;
}
.nav.is-scrolled { border-bottom-color: var(--line); background: rgba(246,246,243,0.92); }
.nav__inner {
  max-width: var(--container); margin: 0 auto; padding: 14px 28px;
  display: flex; align-items: center; gap: 28px;
}
.nav__brand img { height: 26px; }
.nav__links { display: flex; gap: 24px; margin-left: 12px; flex: 1; }
.nav__links a {
  font-size: 14px; font-weight: 500; color: var(--ink-soft);
  position: relative; padding: 8px 2px;
}
.nav__links a:hover { color: var(--green-deep); }
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 2px;
  background: var(--green); transform: scaleX(0); transform-origin: left;
  transition: transform .25s ease;
}
.nav__links a:hover::after { transform: scaleX(1); }

.nav__cta {
  font-size: 14px; font-weight: 600;
  padding: 10px 16px; border-radius: 999px;
  background: var(--ink); color: var(--white);
  transition: transform .2s ease, background .2s ease;
}
.nav__cta:hover { background: var(--green-deep); transform: translateY(-1px); }

.nav__burger {
  display: none; background: none; border: 0; width: 40px; height: 40px;
  padding: 0; align-items: center; justify-content: center; flex-direction: column; gap: 5px;
}
.nav__burger span { display: block; width: 22px; height: 2px; background: var(--ink); transition: transform .2s ease; }
.nav__burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav__mobile {
  display: none; flex-direction: column; padding: 12px 28px 22px;
  border-top: 1px solid var(--line); background: var(--bg);
}
.nav__mobile a {
  padding: 12px 0; font-size: 16px; font-weight: 500;
  border-bottom: 1px solid var(--line);
}
.nav__mobile a:last-child { border-bottom: 0; }
.nav__mobile-cta {
  margin-top: 12px; background: var(--ink); color: var(--white);
  text-align: center; padding: 14px; border-radius: 999px;
  border-bottom: 0 !important;
}

/* ---------- HERO ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: clamp(56px, 7vw, 96px) 28px clamp(72px, 8vw, 120px);
  max-width: var(--container); margin: 0 auto;
  display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.hero__grid {
  position: absolute; inset: 0; pointer-events: none; opacity: 0.5;
  background-image:
    linear-gradient(to right, rgba(10,10,10,0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(10,10,10,0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at 30% 40%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at 30% 40%, #000 30%, transparent 75%);
}
.hero__content { position: relative; z-index: 2; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 12px;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--muted); margin-bottom: 28px;
  padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--white);
}
.eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--green);
  box-shadow: 0 0 0 4px rgba(124,193,66,0.22);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(124,193,66,0.22); }
  50%      { box-shadow: 0 0 0 8px rgba(124,193,66,0.05); }
}

.hero h1 {
  font-size: clamp(40px, 5.6vw, 76px);
  line-height: 1.02; letter-spacing: -0.025em;
  font-weight: 700; margin: 0 0 24px;
}
.hero h1 .accent { color: var(--green-deep); }
.hero__lede {
  font-size: clamp(16px, 1.2vw + 0.6rem, 19px);
  color: var(--muted); max-width: 54ch; margin: 0 0 36px;
}
.hero__cta { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 48px; }

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 22px; border-radius: 999px;
  font-weight: 600; font-size: 15px;
  transition: transform .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
  border: 1px solid transparent;
}
.btn--primary { background: var(--ink); color: var(--white); }
.btn--primary:hover { background: var(--green-deep); transform: translateY(-1px); }
.btn--ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn--ghost:hover { border-color: var(--ink); background: var(--white); }

.hero__stats {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
  border-top: 1px solid var(--line); padding-top: 24px;
}
.hero__stats li { display: flex; flex-direction: column; gap: 4px; }
.hero__stats strong {
  font-size: clamp(20px, 2vw, 28px); font-weight: 700; letter-spacing: -0.01em;
}
.hero__stats span {
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--muted);
}

.hero__visual { position: relative; z-index: 2; }
.hero__visual img {
  width: 100%; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-2);
  background: linear-gradient(180deg, #f8f8f6, #e8e8e3);
}
.hero__chip {
  position: absolute; left: -18px; padding: 10px 14px;
  background: var(--white); border-radius: 999px;
  font-family: var(--font-mono); font-size: 12px; font-weight: 500;
  display: inline-flex; align-items: center; gap: 10px;
  box-shadow: var(--shadow-1); border: 1px solid var(--line);
  white-space: nowrap;
}
.hero__chip--1 { top: 8%; }
.hero__chip--2 { top: 44%; left: auto; right: -18px; }
.hero__chip--3 { bottom: 8%; }
.swatch { width: 12px; height: 12px; border-radius: 3px; flex: none; }
.swatch--green { background: var(--green); }
.swatch--blue { background: var(--blue); }
.swatch--yellow { background: var(--yellow); }

/* ---------- SECTIONS ---------- */
.section {
  max-width: var(--container);
  margin: 0 auto;
  padding: clamp(72px, 9vw, 140px) 28px;
}
.section__head { max-width: 760px; margin: 0 auto clamp(40px, 5vw, 72px); text-align: center; }
.section__head--split {
  display: flex; align-items: end; justify-content: space-between; gap: 32px;
  text-align: left; max-width: none;
}
.section__head--split > div { max-width: 720px; }
.kicker {
  font-family: var(--font-mono); font-size: 12px; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--green-deep); display: inline-block; margin-bottom: 16px;
}
.section h2 {
  font-size: clamp(32px, 4vw, 56px); line-height: 1.05;
  letter-spacing: -0.02em; font-weight: 700; margin: 0 0 18px;
}
.section__sub { color: var(--muted); font-size: clamp(16px, 1vw + 0.5rem, 19px); margin: 0; }
.section__meta { font-size: 12px; color: var(--muted); margin: 0; }

/* ---------- SYSTEM ---------- */
.system {
  background: var(--ink); color: var(--bg); max-width: none;
  margin: 0; padding-left: 0; padding-right: 0;
}
.system .section__head { color: var(--bg); }
.system h2 { color: var(--white); }
.system .section__sub { color: rgba(246,246,243,0.7); }
.system .kicker { color: var(--green); }
.system__steps {
  list-style: none; padding: 0; margin: 0 auto;
  max-width: var(--container); padding-inline: 28px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
}
.system__steps li {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  padding: 28px 24px; position: relative;
  transition: background .25s ease, border-color .25s ease, transform .25s ease;
}
.system__steps li:hover {
  background: rgba(124,193,66,0.08);
  border-color: rgba(124,193,66,0.4);
  transform: translateY(-3px);
}
.step__num {
  font-family: var(--font-mono); font-size: 12px; font-weight: 500;
  color: var(--green); letter-spacing: 0.14em;
}
.system__steps h3 {
  margin: 16px 0 10px; font-size: 22px; font-weight: 600;
  letter-spacing: -0.01em;
}
.system__steps p { color: rgba(246,246,243,0.65); font-size: 14px; margin: 0; line-height: 1.55; }

/* ---------- GELS ---------- */
.gels__grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px;
}
.gel {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 32px 28px;
  display: flex; flex-direction: column; gap: 18px;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  position: relative; overflow: hidden;
}
.gel::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at top right, rgba(124,193,66,0.08), transparent 60%);
  opacity: 0; transition: opacity .3s ease;
}
.gel:hover { transform: translateY(-4px); box-shadow: var(--shadow-2); border-color: rgba(10,10,10,0.18); }
.gel:hover::before { opacity: 1; }
.gel header { display: flex; align-items: center; gap: 14px; position: relative; z-index: 1; }
.gel header h3 {
  font-size: clamp(36px, 4vw, 52px); font-weight: 700;
  letter-spacing: -0.02em; margin: 0;
}
.gel header .swatch { width: 14px; height: 14px; border-radius: 4px; }
.gel__formula {
  font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.02em;
  color: var(--muted); margin: 0; position: relative; z-index: 1;
}
.gel__desc { margin: 0; color: var(--ink-soft); position: relative; z-index: 1; }
.gel__facts {
  list-style: none; padding: 18px 0 0; margin: auto 0 0;
  display: flex; flex-direction: column; gap: 10px;
  border-top: 1px dashed var(--line); position: relative; z-index: 1;
}
.gel__facts li {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 14px;
}
.gel__facts li span {
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.14em; color: var(--muted);
}
.gel__facts li strong { font-weight: 600; }
.gel--featured {
  background: var(--ink); color: var(--bg); border-color: var(--ink);
}
.gel--featured .gel__formula { color: rgba(246,246,243,0.7); }
.gel--featured .gel__desc { color: rgba(246,246,243,0.85); }
.gel--featured .gel__facts { border-top-color: rgba(255,255,255,0.16); }
.gel--featured .gel__facts li span { color: rgba(246,246,243,0.5); }

/* ---------- CARBS ---------- */
.carbs { background: var(--bg-soft); max-width: none; margin: 0; }
.carbs__layout {
  max-width: var(--container); margin: 0 auto; padding: 0 28px;
  display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(40px, 6vw, 96px);
  align-items: center;
}
.carbs__copy h2 { margin-bottom: 24px; }
.carbs__visual {
  margin: 36px 0 0; border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-1); background: var(--white);
}
.carbs__visual img { width: 100%; display: block; }
.ingredient-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
}
.ingredient {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 28px 24px;
  transition: transform .2s ease, border-color .2s ease;
}
.ingredient:hover { transform: translateY(-3px); border-color: var(--ink); }
.ingredient__index {
  font-family: var(--font-mono); font-size: 11px; color: var(--green-deep);
  letter-spacing: 0.16em;
}
.ingredient h3 {
  margin: 12px 0 8px; font-size: 22px; font-weight: 600; letter-spacing: -0.01em;
}
.ingredient p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.55; }

/* ---------- CARDS (Nutrition / Ergogenic) ---------- */
.card-grid {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px;
}
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px; display: flex; flex-direction: column; gap: 12px;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
  position: relative;
}
.card:hover { transform: translateY(-4px); border-color: var(--ink); box-shadow: var(--shadow-1); }
.card__tag {
  align-self: flex-start;
  font-family: var(--font-mono); font-size: 10.5px; text-transform: uppercase;
  letter-spacing: 0.14em; color: var(--green-deep);
  padding: 5px 10px; border-radius: 999px;
  background: rgba(124,193,66,0.12);
}
.card h3 { margin: 4px 0 0; font-size: 22px; font-weight: 600; letter-spacing: -0.01em; }
.card p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.55; }

.ergogenic { background: var(--ink); color: var(--bg); max-width: none; margin: 0; }
.ergogenic .section__head { color: var(--bg); }
.ergogenic h2 { color: var(--white); }
.ergogenic .section__sub { color: rgba(246,246,243,0.7); }
.ergogenic .kicker { color: var(--green); }
.card-grid--dark { max-width: var(--container); margin: 0 auto; }
.card--dark {
  background: rgba(255,255,255,0.03);
  border-color: rgba(255,255,255,0.08); color: var(--bg);
}
.card--dark:hover { background: rgba(124,193,66,0.06); border-color: rgba(124,193,66,0.4); box-shadow: none; }
.card--dark .card__tag { background: rgba(124,193,66,0.18); color: var(--green); }
.card--dark p { color: rgba(246,246,243,0.65); }

/* ---------- CTA ---------- */
.cta { text-align: center; }
.cta__inner { max-width: 740px; margin: 0 auto; }
.cta__inner h2 { margin-top: 16px; }
.cta__actions { display: inline-flex; gap: 14px; flex-wrap: wrap; margin-top: 32px; }

/* ---------- FOOTER ---------- */
.footer { background: var(--ink); color: var(--bg); padding: 64px 28px 28px; }
.footer__inner {
  max-width: var(--container); margin: 0 auto;
  display: grid; grid-template-columns: 1fr 2fr; gap: 48px; padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer__brand img { height: 28px; filter: brightness(0) invert(1); margin-bottom: 14px; }
.footer__tag { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.14em; color: rgba(246,246,243,0.5); text-transform: uppercase; margin: 0; }
.footer__nav {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
}
.footer__nav h4 {
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.16em; color: rgba(246,246,243,0.5); margin: 0 0 14px;
}
.footer__nav a {
  display: block; padding: 6px 0; font-size: 14px;
  color: rgba(246,246,243,0.8); transition: color .2s ease;
}
.footer__nav a:hover { color: var(--green); }
.footer__bottom {
  max-width: var(--container); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 24px; font-size: 12px; color: rgba(246,246,243,0.5); gap: 16px; flex-wrap: wrap;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1080px) {
  .hero { grid-template-columns: 1fr; gap: 48px; }
  .hero__chip--2 { right: -8px; }
  .gels__grid { grid-template-columns: 1fr 1fr; }
  .gel--featured { grid-column: 1 / -1; }
  .system__steps { grid-template-columns: 1fr 1fr; }
  .card-grid { grid-template-columns: 1fr 1fr; }
  .carbs__layout { grid-template-columns: 1fr; }
  .ingredient-grid { grid-template-columns: 1fr 1fr; }
  .footer__inner { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .nav__links, .nav__cta { display: none; }
  .nav__burger { display: inline-flex; }
  .nav__mobile.is-open { display: flex; }
  .section__head--split { flex-direction: column; align-items: flex-start; }
  .hero__stats { grid-template-columns: 1fr 1fr; gap: 18px; }
  .hero__chip { font-size: 11px; padding: 8px 12px; }
  .hero__chip--1 { left: 8px; }
  .hero__chip--2 { right: 8px; left: auto; }
  .hero__chip--3 { left: 8px; bottom: 4%; }
  .gels__grid { grid-template-columns: 1fr; }
  .gel--featured { grid-column: auto; }
  .ingredient-grid, .card-grid, .system__steps, .footer__nav {
    grid-template-columns: 1fr;
  }
  .footer__bottom { justify-content: flex-start; }
}

/* ---------- MOTION / A11Y ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  html { scroll-behavior: auto; }
}

:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
  border-radius: 4px;
}
