/* ============ Elston Labs — design tokens ============
   Modeled on corolam.com: Poppins headings, Open Sans body,
   ink-slate text, pill buttons. Accent swapped to a deep teal
   so the brand reads as a sibling, not a clone. Change the
   accent in one place below. */
:root {
  --accent: #0e7d6f;        /* primary brand color (Corolam uses #ba181d red) */
  --accent-dark: #0a5f55;
  --ink: #434354;           /* heading / dark text, matched to reference */
  --body: rgba(0, 0, 0, 0.78);
  --muted: #6b6b7a;
  --bg: #ffffff;
  --bg-soft: #f6f7f8;
  --border: #e6e7ea;
  --radius: 14px;
  --font-head: "Poppins", sans-serif;
  --font-body: "Open Sans", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  font-family: var(--font-body);
  color: var(--body);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

h1, h2, h3 { font-family: var(--font-head); color: var(--ink); line-height: 1.25; }
h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); font-weight: 600; }
h1 em { font-style: normal; color: var(--accent); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 600; margin-bottom: 12px; }
h3 { font-size: 1.15rem; font-weight: 600; }
section { padding: 88px 0; }
.section-sub { max-width: 560px; margin-bottom: 40px; color: var(--muted); }

/* ============ Buttons (pill, like reference) ============ */
.btn {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 12px 26px;
  border-radius: 999px;
  border: 2px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}
.btn-lg { padding: 15px 32px; font-size: 1.02rem; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); }
.btn-ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-ghost:hover { background: var(--ink); color: #fff; }

/* ============ Header ============ */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; gap: 32px; height: 72px; }
.logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-head); font-weight: 700; font-size: 1.35rem;
  color: var(--ink); text-decoration: none; letter-spacing: -0.01em;
}
.logo-mark { width: 30px; height: 30px; fill: var(--accent); }
.site-nav { margin-left: auto; }
.nav-menu { display: flex; gap: 28px; list-style: none; }
.nav-menu a {
  font-size: 0.95rem; color: var(--ink); text-decoration: none;
  padding-bottom: 6px; border-bottom: 2px solid transparent;
}
.nav-menu a:hover, .nav-menu a.active { border-bottom-color: var(--accent); }
.nav-toggle { display: none; }

/* ============ Hero ============ */
.hero { padding: 120px 0 100px; }
.hero-sub { max-width: 640px; margin: 24px 0 36px; font-size: 1.12rem; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* ============ Thesis ============ */
.thesis { background: var(--bg-soft); }
.thesis-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 40px; }
.thesis-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px 28px;
}
.thesis-num { font-family: var(--font-head); font-weight: 700; color: var(--accent); font-size: 0.95rem; margin-bottom: 12px; }
.thesis-card h3 { margin-bottom: 10px; }

/* ============ Process ============ */
.process-steps { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 8px; }
.process-steps li {
  counter-increment: step;
  padding: 28px;
  border: 1px solid var(--border); border-radius: var(--radius);
}
.process-steps li::before {
  content: counter(step);
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--accent); color: #fff;
  font-family: var(--font-head); font-weight: 600;
  margin-bottom: 16px;
}
.process-steps h3 { margin-bottom: 8px; }
.outcomes { margin-top: 56px; text-align: center; }
.outcomes-title { font-size: 1.05rem; margin-bottom: 6px; }
.outcomes-sub { color: var(--muted); font-size: 0.95rem; margin-bottom: 24px; }
.outcomes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.outcome {
  position: relative;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 20px; font-family: var(--font-head); color: var(--ink);
  cursor: pointer; transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}
.outcome:hover { border-color: var(--accent); }
.outcome[aria-pressed="true"] {
  border-color: var(--accent);
  background: #eef5f3;
  box-shadow: 0 0 0 1px var(--accent);
}
/* checkbox in the corner signals the cards are clickable */
.outcome::after {
  content: "";
  position: absolute; top: 12px; right: 12px;
  width: 17px; height: 17px;
  border: 1.5px solid #c3c6cc; border-radius: 4px;
  background: #fff;
  font-size: 12px; line-height: 17px; text-align: center;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.outcome:hover::after { border-color: var(--accent); }
.outcome[aria-pressed="true"]::after {
  content: "✓";
  color: #fff; font-weight: 700;
  background: var(--accent); border-color: var(--accent);
}
.outcome svg {
  width: 30px; height: 30px; margin-bottom: 4px;
  fill: none; stroke: var(--accent-dark);
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.outcome strong { font-weight: 600; font-size: 1rem; }
.outcome span { font-family: var(--font-body); font-size: 0.85rem; color: var(--muted); }
.section-cta { text-align: center; margin-top: 48px; }

/* ============ Work ============ */
.work { background: var(--bg-soft); }
.work-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.work-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; padding-bottom: 24px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.work-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(20, 20, 40, 0.08); }
.work-thumb {
  aspect-ratio: 16 / 10; background: linear-gradient(135deg, #e8f0ee, #d3e4e0);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent-dark); font-family: var(--font-head); font-weight: 600;
  margin-bottom: 20px;
}
.work-card h3, .work-card p, .work-card .tags { padding: 0 24px; }
.work-card h3 { margin-bottom: 6px; }
.work-card p { font-size: 0.95rem; margin-bottom: 14px; }
.tags { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li {
  font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase;
  font-family: var(--font-head); font-weight: 600; color: var(--accent-dark);
  background: #e8f0ee; border-radius: 999px; padding: 4px 12px;
}

/* ============ Testimonials ============ */
.testimonial-track {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(420px, 85%);
  gap: 24px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 8px 4px 24px;
}
.testimonial {
  scroll-snap-align: start;
  background: var(--bg-soft); border-radius: var(--radius); padding: 32px 28px;
}
.testimonial p { font-size: 1.02rem; margin-bottom: 20px; }
.testimonial footer { display: flex; flex-direction: column; }
.testimonial footer strong { font-family: var(--font-head); color: var(--ink); }
.testimonial footer span { font-size: 0.88rem; color: var(--muted); }

/* ============ Team ============ */
.team { background: var(--bg-soft); }
.team-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 420px)); gap: 28px; justify-content: center; }
.team-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 36px 32px; text-align: center;
}
.team-photo, .team-card img {
  width: 128px; height: 128px; border-radius: 50%; margin: 0 auto 20px; object-fit: cover;
}
.team-photo {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-family: var(--font-head); font-weight: 600; font-size: 2rem;
}
.team-role { color: var(--accent-dark); font-family: var(--font-head); font-weight: 600; font-size: 0.9rem; margin: 2px 0 14px; }

/* ============ Contact ============ */
.contact-inner { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: start; }
.contact-copy p { margin: 16px 0 28px; max-width: 400px; }
.contact-form { display: flex; flex-direction: column; gap: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.contact-form label {
  display: flex; flex-direction: column; gap: 6px;
  font-family: var(--font-head); font-size: 0.88rem; font-weight: 500; color: var(--ink);
}
.contact-form input, .contact-form textarea {
  font-family: var(--font-body); font-size: 1rem; color: var(--body);
  padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px;
  background: var(--bg-soft);
}
.contact-form input:focus, .contact-form textarea:focus {
  outline: 2px solid var(--accent); outline-offset: 0; border-color: var(--accent);
}
.contact-form button { align-self: flex-start; }
.form-goals {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-family: var(--font-head); font-size: 0.88rem; font-weight: 500; color: var(--ink);
}
.form-goals .chip {
  background: #e8f0ee; color: var(--accent-dark); border-radius: 999px;
  padding: 3px 12px; font-size: 0.78rem; font-weight: 600;
}

/* ============ Footer ============ */
.site-footer { border-top: 1px solid var(--border); padding: 32px 0; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.footer-inner p { font-size: 0.9rem; color: var(--muted); }
.footer-inner nav { display: flex; gap: 22px; }
.footer-inner a { font-size: 0.9rem; color: var(--ink); text-decoration: none; }
.footer-inner a:hover { color: var(--accent); }

/* ============ Mobile ============ */
@media (max-width: 860px) {
  section { padding: 64px 0; }
  .hero { padding: 72px 0 64px; }
  .thesis-grid, .process-steps, .outcomes-grid, .work-grid { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: 1fr; }
  .contact-inner { grid-template-columns: 1fr; gap: 40px; }
  .header-cta { display: none; }

  .nav-toggle {
    display: flex; flex-direction: column; gap: 5px;
    background: none; border: none; padding: 8px; cursor: pointer;
  }
  .nav-toggle span { width: 24px; height: 2px; background: var(--ink); transition: transform 0.2s ease, opacity 0.2s ease; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .nav-menu {
    display: none;
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; gap: 0;
    background: #fff; border-bottom: 1px solid var(--border);
    padding: 12px 24px 20px;
  }
  .nav-menu.open { display: flex; }
  .nav-menu li { padding: 10px 0; }
}
