/* =========================
   ROOT + GLOBAL FIXES
========================= */
:root {
  --primary: #1f5fbf;
  --primary-dark: #144a96;
  --primary-light: #2f7de1;

  --bg: #f6f9ff;
  --card: #ffffff;
  --text: #0f172a;
}

html {
  scroll-behavior: smooth;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

/* =========================
   CONTAINER SYSTEM
========================= */
.container {
  width: 100%;
  max-width: min(1440px, 92vw);
  margin: 0 auto;
  padding: 0 clamp(16px, 3vw, 40px);
}

/* =========================
   HEADER
========================= */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;

  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

.header-inner {
  width: 100%;
  max-width: min(1440px, 92vw);
  display: flex;
  justify-content: space-between;
  align-items: center;

  padding: clamp(10px, 1.2vw, 18px) clamp(16px, 3vw, 40px);
}

/* LOGO */

.logo {
  display: flex;
  align-items: center;
  max-width: 160px; /* prevents stretching */
  flex-shrink: 0;
}

.logo img {
  height: 40px;
  width: auto;
  max-width: 100%;
  display: block;
}


/* NAV */
.nav {
  display: flex;
  gap: 12px;
}

.nav-btn {
  padding: 12px 20px;
  text-decoration: none;
  color: var(--primary-dark);
  font-weight: 600;
  border-radius: 12px;
  transition: 0.25s;
}

.nav-btn:hover {
  background: var(--primary);
  color: white;
}

/* HAMBURGER */
.nav-toggle {
  display: none;
  width: 28px;
  height: 22px;
  position: relative;
  cursor: pointer;
}

.nav-toggle span,
.nav-toggle::before,
.nav-toggle::after {
  content: "";
  position: absolute;
  width: 100%;
  height: 2px;
  background: var(--primary-dark);
  left: 0;
  transition: all 0.3s ease;
}

.nav-toggle::before { top: 0; }
.nav-toggle span { top: 50%; transform: translateY(-50%); }
.nav-toggle::after { bottom: 0; }

.nav-toggle.active::before {
  transform: rotate(45deg);
  top: 50%;
}

.nav-toggle.active span {
  opacity: 0;
}

.nav-toggle.active::after {
  transform: rotate(-45deg);
  bottom: 50%;
}

/* =========================
   HERO
========================= */
.hero {
  padding: clamp(20px, 5vw, 20px) 0;
}

.hero .container {
  max-width: 1440px;
  margin: 0 auto;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
}

.hero-text {
  max-width: 1200px;
  margin: 0 auto;
}

.hero h2 {
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.1;
  color: var(--primary-dark);
}

.hero p {
  font-size: clamp(16px, 2vw, 20px);
  padding-bottom: 20px;
  color: #475569;
}

.btn {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: white;
  padding: 14px 26px;
  border-radius: 14px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 40px rgba(31, 95, 191, 0.35);
}

/* CANVAS */
.hero-canvas {
  width: 100%;
  display: flex;
  justify-content: flex-start;
}

#protein-canvas {
  width: min(500px, 100%);
  height: clamp(260px, 40vw, 420px);
}

#protein-canvas canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
}

/* =========================
   ABOUT SECTION
========================= */
.about {
  padding: 40px 0;
}
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start; /* IMPORTANT */
}

.about-text {
  max-width: 600px;
}

.about-text h3 {
  margin-bottom: 20px;
}

.about-text p {
  margin-bottom: 16px;
  line-height: 1.6;
  color: #475569;
}

/* MEDIA */
.about-media {
  padding-top: 60px;
  width: 100%;
  display: block; /* IMPORTANT: remove centering behaviour */
}

/* GOALS SECTION */
.goals {
  position: relative;
  min-height: 500px; /* ensures presence even with little content */
  padding: 100px 0; /* vertical breathing space */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Overlay */
.goals-overlay {
  background: rgba(0, 0, 0, 0.65);
  padding: 60px 0;
  height: 100%;
}

/* GRID */
.goals-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  align-items: stretch;
}

/* CARDS */
.goal-card {
  border: 1.5px solid #ffffff;
  border-radius: 18px;
  padding: 40px 25px;
  text-align: center;
  color: #ffffff;
  background: transparent;

  min-height: 260px; /* ensures equal visual weight */
  display: flex;
  align-items: center;
  justify-content: center;

  transition: all 0.3s ease;
}

/* Hover */
.goal-card:hover {
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-6px);
}

/* CONTENT */
.goal-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}


/* TITLE */
.goal-title {
  font-weight: bold;
  font-size: 1.3rem;
}

/* TEXT */
.goal-card p {
  font-size: 1rem;
  line-height: 1.5;
  max-width: 320px;
  opacity: 0.9;
}

/* VISUAL SECTION */
.visual {
  position: relative;
  min-height: 450px;
  padding: 100px 0;

  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* DARK OVERLAY */
.visual-overlay {
  background: rgba(0, 0, 0, 0.55);
  height: 100%;
  padding: 80px 0;
}

/* CENTER CONTENT */
.visual-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 25px;
  text-align: center;
  color: #ffffff;
}

/* ICON */
.visual-icon {
  width: 80px;
  height: 80px;
}

/* TEXT */
.visual-text h2 {
  font-size: 2rem;
  margin: 0;
  font-weight: bold;
}

.visual-text p {
  max-width: 600px;
  margin: 0 auto;
  font-size: 1.1rem;
  opacity: 0.9;
}

/* =========================
   PROTEIN VIEWER (3DMOL)
========================= */
#protein-viewer-about {
  width: 100%;
  height: 400px;
  display: block;
  position: relative;
}

#protein-viewer-about canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
  border-radius: 12px;
  overflow: hidden;
}


/* PLACEHOLDER */
.placeholder {
  width: 100%;
  height: 300px;
  background: #e2e8f0;
  border-radius: 16px;

  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
}




/* =========================
   SECTIONS + CARDS
========================= */
.section {
  padding: 80px 0;
}

.bg {
  background: #f3f4f6;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.card {
  background: var(--card);
  padding: 24px;
  border-radius: 16px;
  border: 1px solid rgba(31, 95, 191, 0.08);
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-6px);
  border-color: rgba(31, 95, 191, 0.25);
  box-shadow: 0 20px 40px rgba(31, 95, 191, 0.12);
}

/* =========================
   FOOTER BASE
========================= */
.footer {
  background: #ffffff;
  padding: 40px 0;
}

/* MAIN CONTAINER */
.footer-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 40px;
}

/* =========================
   LEFT SIDE
========================= */
.footer-left {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* LOGOS */
.footer-logos {
  display: flex;
  align-items: center;
  gap: 20px;
}

.footer-logos img {
  height: 30px;
  opacity: 0.8;
  transition: 0.3s;
}

.footer-logos img:hover {
  opacity: 1;
}

/* COPYRIGHT */
.footer-copy {
  font-size: 14px;
  color: #64748b;
}

/* =========================
   RIGHT SIDE
========================= */
.footer-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

/* TITLE */
.footer-title {
  font-size: 13px;
  letter-spacing: 1px;
}

/* =========================
   SOCIAL (ONE ROW)
========================= */
.social-grid {
  display: flex;
  align-items: center;
  gap: 10px;
}

.social-grid a {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 40px;
  height: 40px;

  border-radius: 10px;
  background: var(--card);
  color: var(--primary-dark);

  transition: 0.3s;
}

.social-grid a:hover {
  background: var(--primary);
  color: white;
}

/* =========================
   OPTIONAL DIVIDER
========================= */
.footer-divider {
  height: 2px;
  width: 100%;
  background: var(--primary);
  margin: 25px 0;
}

/* =========================
   TABLET
========================= */
@media (max-width: 1024px) {
  .hero-inner {
    align-items: center;
    text-align: center;
  }

  .hero-canvas {
    justify-content: center;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-text {
    max-width: 100%;
  }
}

/* =========================
   MOBILE
========================= */
@media (max-width: 768px) {
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;

    background: rgba(255,255,255,0.95);
    flex-direction: column;
    padding: 20px;

    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
  }

  .nav.open {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  .nav-toggle {
    display: block;
  }

  .hero {
    padding: 60px 0;
  }

  .hero h2 {
    font-size: 32px;
  }

  .hero p {
    font-size: 16px;
  }
 
   .footer-bar {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
	
 .footer-right {
    align-items: center;
  }
	
  .footer-logos {
    justify-content: center;
    flex-wrap: wrap;
  }

/* RESPONSIVE */

  .visual {
    min-height: 350px;
    padding: 60px 20px;
  }

  .visual-icon {
    width: 60px;
    height: 60px;
  }

  .visual-text h2 {
    font-size: 1.6rem;
  }
.goals {
    padding: 80px 20px;
  }

  .goals-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .goal-card {
    min-height: 220px;
  }
	
}
