/* ============================================================
   Tabletop Innovations LLP — tabletopinnovations.com
   Palette (brand guide, Mar 2026): #193C40 dark slate green,
   #FCC4CF apricot peach, white, black.
   Type: Marcellus (display, substituting licensed Chaste),
   Poppins (body / UI).
   ============================================================ */

:root {
  --bg-950: #0B1D20;
  --bg-900: #10262A;
  --slate: #193C40;
  --slate-600: #24494E;
  --line: rgba(244, 247, 246, 0.12);
  --line-soft: rgba(244, 247, 246, 0.07);
  --peach: #FCC4CF;
  --peach-dim: rgba(252, 196, 207, 0.55);
  --peach-faint: rgba(252, 196, 207, 0.12);
  --ivory: #F4F7F6;
  --muted: #9DB4B6;
  --max: 1180px;
  --nav-h: 76px;
  --radius: 6px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg-950);
  color: var(--ivory);
  font-family: 'Poppins', system-ui, sans-serif;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--peach); color: var(--slate); }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 28px; }

/* ---------- Type ---------- */
h1, h2, h3, .display {
  font-family: 'Marcellus', serif;
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: 0.005em;
}

h1 { font-size: clamp(2.4rem, 5.4vw, 4.35rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.9rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.45rem); line-height: 1.3; }

.eyebrow {
  font-family: 'Poppins', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--peach);
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 26px;
}
.eyebrow::before {
  content: "";
  width: 34px;
  height: 1px;
  background: var(--peach-dim);
}

.lede {
  color: var(--muted);
  font-size: clamp(1rem, 1.45vw, 1.2rem);
  line-height: 1.85;
  max-width: 46em;
}

.accent { color: var(--peach); }

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--nav-h);
  z-index: 100;
  display: flex;
  align-items: center;
  transition: background 0.35s ease, border-color 0.35s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(11, 29, 32, 0.92);
  backdrop-filter: blur(12px);
  border-bottom-color: var(--line-soft);
}
.nav .wrap {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand { display: flex; align-items: center; gap: 13px; }
.brand img.mark { height: 30px; width: auto; }
.brand img.wordmark { height: 26px; width: auto; }

.nav-links { display: flex; align-items: center; gap: 36px; }
.nav-links a {
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--muted);
  transition: color 0.25s ease;
  position: relative;
  padding: 6px 0;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--peach);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.nav-links a:hover, .nav-links a.active { color: var(--ivory); }
.nav-links a:hover::after, .nav-links a.active::after { transform: scaleX(1); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'Poppins', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  padding: 13px 28px;
  border-radius: var(--radius);
  border: 1px solid var(--peach-dim);
  color: var(--ivory);
  background: transparent;
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.3s var(--ease);
  cursor: pointer;
}
.btn:hover { background: var(--peach); color: var(--slate); border-color: var(--peach); transform: translateY(-2px); }
.btn.solid { background: var(--peach); color: var(--slate); border-color: var(--peach); }
.btn.solid:hover { background: var(--ivory); border-color: var(--ivory); }
.btn.ghost { border-color: var(--line); color: var(--muted); }
.btn.ghost:hover { border-color: var(--peach-dim); background: transparent; color: var(--ivory); transform: translateY(-2px); }
.btn .arr { transition: transform 0.3s var(--ease); }
.btn:hover .arr { transform: translateX(4px); }

.nav-cta { flex-shrink: 0; }

.burger {
  display: none;
  background: none;
  border: none;
  width: 40px; height: 40px;
  cursor: pointer;
  position: relative;
  z-index: 120;
}
.burger span {
  display: block;
  width: 22px; height: 1.5px;
  background: var(--ivory);
  margin: 5px auto;
  transition: transform 0.3s var(--ease), opacity 0.3s ease;
}
.burger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  min-height: 92vh;
  display: flex;
  align-items: center;
  position: relative;
  padding: calc(var(--nav-h) + 60px) 0 90px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 45% at 78% 18%, rgba(25, 60, 64, 0.85), transparent 70%),
    radial-gradient(ellipse 50% 40% at 8% 85%, rgba(252, 196, 207, 0.05), transparent 70%);
  pointer-events: none;
}
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, black 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, black 20%, transparent 75%);
  opacity: 0.5;
  pointer-events: none;
}
.hero .wrap { position: relative; z-index: 2; width: 100%; }
.hero h1 { max-width: 15em; margin-bottom: 30px; }
.hero .lede { margin-bottom: 44px; }
.hero-ctas { display: flex; gap: 16px; flex-wrap: wrap; }

/* Telemetry signature */
.telemetry {
  margin-top: 84px;
  border-top: 1px solid var(--line-soft);
  padding-top: 0;
  position: relative;
}
.telemetry svg { width: 100%; height: 110px; display: block; }
.telemetry .tline {
  fill: none;
  stroke: var(--peach);
  stroke-width: 1.5;
  opacity: 0.85;
  stroke-dasharray: 3000;
  stroke-dashoffset: 3000;
  animation: draw 4.5s var(--ease) 0.4s forwards;
  filter: drop-shadow(0 0 6px rgba(252, 196, 207, 0.45));
}
.telemetry .tbase { fill: none; stroke: var(--line); stroke-width: 1; stroke-dasharray: 2 6; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.telemetry-tags {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 6px;
}
.telemetry-tags span b { color: var(--peach); font-weight: 500; }

/* ---------- Sections ---------- */
section.block { padding: 110px 0; position: relative; }
section.block.alt { background: var(--bg-900); border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.section-head { max-width: 760px; margin-bottom: 64px; }
.section-head h2 { margin-bottom: 22px; }

/* ---------- Stats ---------- */
.stats {
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  background: var(--bg-900);
}
.stats .wrap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.stat {
  padding: 52px 32px;
  border-left: 1px solid var(--line-soft);
}
.stat:first-child { border-left: none; }
.stat .num {
  font-family: 'Marcellus', serif;
  font-size: clamp(2.1rem, 3.4vw, 3rem);
  color: var(--ivory);
  line-height: 1;
  margin-bottom: 12px;
  display: flex;
  align-items: baseline;
  gap: 2px;
}
.stat .num .suffix, .stat .num .prefix { color: var(--peach); font-size: 0.62em; }
.stat .label {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
  background: linear-gradient(160deg, var(--slate) 0%, var(--bg-900) 90%);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 44px 36px 40px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: border-color 0.35s ease, transform 0.4s var(--ease);
}
.card::before {
  content: "";
  position: absolute;
  top: 0; left: 36px; right: 36px;
  height: 1px;
  background: linear-gradient(90deg, var(--peach), transparent);
  opacity: 0;
  transition: opacity 0.35s ease;
}
.card:hover { border-color: rgba(252, 196, 207, 0.3); transform: translateY(-6px); }
.card:hover::before { opacity: 1; }
.card .tag {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--peach);
  margin-bottom: 22px;
}
.card h3 { margin-bottom: 16px; }
.card p { color: var(--muted); font-size: 0.94rem; flex: 1; }
.card .more {
  margin-top: 30px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--ivory);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.card .more .arr { color: var(--peach); transition: transform 0.3s var(--ease); }
.card:hover .more .arr { transform: translateX(5px); }

/* ---------- Split layout ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
.split.narrow-gap { gap: 56px; }

/* ---------- Feature list (prose rows) ---------- */
.rows { border-top: 1px solid var(--line-soft); }
.row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 48px;
  padding: 42px 0;
  border-bottom: 1px solid var(--line-soft);
}
.row h3 { color: var(--ivory); }
.row p { color: var(--muted); max-width: 44em; }
.row .k {
  font-family: 'Marcellus', serif;
  font-size: 1.25rem;
  color: var(--peach);
}

/* ---------- Statement ---------- */
.statement {
  border-left: 2px solid var(--peach);
  padding: 10px 0 10px 38px;
  max-width: 820px;
}
.statement p {
  font-family: 'Marcellus', serif;
  font-size: clamp(1.3rem, 2.4vw, 1.85rem);
  line-height: 1.5;
  color: var(--ivory);
}
.statement .note { font-family: 'Poppins', sans-serif; font-size: 0.9rem; color: var(--muted); margin-top: 18px; line-height: 1.75; }

/* ---------- Principles / values ---------- */
.principles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); }
.principle { background: var(--bg-950); padding: 42px 38px; }
.principle h3 { margin-bottom: 14px; }
.principle p { color: var(--muted); font-size: 0.94rem; }

/* ---------- Leadership ---------- */
.people { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.person {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 40px 34px;
  background: var(--bg-900);
}
.person .initials {
  width: 62px; height: 62px;
  border-radius: 50%;
  border: 1px solid var(--peach-dim);
  color: var(--peach);
  font-family: 'Marcellus', serif;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
}
.person h3 { font-size: 1.15rem; margin-bottom: 6px; }
.person .role { font-size: 0.76rem; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }

/* ---------- CTA band ---------- */
.cta-band {
  padding: 120px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--line-soft);
}
.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 55% 65% at 50% 100%, rgba(252, 196, 207, 0.08), transparent 70%);
  pointer-events: none;
}
.cta-band h2 { max-width: 17em; margin: 0 auto 26px; }
.cta-band .lede { margin: 0 auto 44px; }
.cta-band .wrap { position: relative; }

/* ---------- Contact page ---------- */
.contact-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 80px; align-items: start; }
.contact-card {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--bg-900);
  padding: 48px 44px;
}
.contact-card .who { margin-bottom: 34px; }
.contact-card .who h3 { margin-bottom: 4px; }
.contact-card .who .role { font-size: 0.74rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
.contact-line { display: flex; gap: 18px; padding: 20px 0; border-top: 1px solid var(--line-soft); align-items: baseline; }
.contact-line .k { font-size: 0.68rem; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); width: 92px; flex-shrink: 0; }
.contact-line .v { font-size: 1rem; color: var(--ivory); }
.contact-line .v a { border-bottom: 1px solid var(--peach-dim); transition: color 0.25s ease; }
.contact-line .v a:hover { color: var(--peach); }

/* ---------- Footer ---------- */
footer {
  border-top: 1px solid var(--line-soft);
  background: var(--bg-900);
  padding: 80px 0 40px;
}
.foot-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 60px;
  padding-bottom: 60px;
  border-bottom: 1px solid var(--line-soft);
}
.foot-top img.footlogo { width: 190px; margin-bottom: 26px; }
.foot-top p { color: var(--muted); font-size: 0.88rem; max-width: 30em; }
.foot-col .head {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--peach);
  margin-bottom: 22px;
}
.foot-col a, .foot-col span { display: block; color: var(--muted); font-size: 0.88rem; padding: 6px 0; transition: color 0.25s ease; }
.foot-col a:hover { color: var(--ivory); }
.foot-bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding-top: 34px;
  font-size: 0.76rem;
  color: var(--muted);
  letter-spacing: 0.04em;
}

/* ---------- Reveal animations ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 0.1s; }
.reveal.d2 { transition-delay: 0.2s; }
.reveal.d3 { transition-delay: 0.3s; }
.reveal.d4 { transition-delay: 0.4s; }

/* ---------- Page hero (inner pages) ---------- */
.page-hero {
  padding: calc(var(--nav-h) + 110px) 0 90px;
  position: relative;
  overflow: hidden;
}
.page-hero h1 { max-width: 14em; margin-bottom: 28px; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .telemetry .tline { animation: none; stroke-dashoffset: 0; }
  * { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .cards, .people { grid-template-columns: 1fr 1fr; }
  .split, .contact-grid { grid-template-columns: 1fr; gap: 48px; }
  .stats .wrap { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: none; }
  .stat { border-top: 1px solid var(--line-soft); }
  .stat:nth-child(-n+2) { border-top: none; }
  .foot-top { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 760px) {
  .nav-links {
    position: fixed;
    inset: 0;
    background: var(--bg-950);
    flex-direction: column;
    justify-content: center;
    gap: 30px;
    transform: translateX(100%);
    transition: transform 0.4s var(--ease);
    z-index: 110;
  }
  .nav-links.open { transform: translateX(0); }
  .nav-links a { font-size: 1.1rem; }
  .nav-cta { display: none; }
  .burger { display: block; }
  .cards, .people, .principles { grid-template-columns: 1fr; }
  .row { grid-template-columns: 1fr; gap: 10px; padding: 34px 0; }
  .stats .wrap { grid-template-columns: 1fr; }
  .stat { border-left: none; border-top: 1px solid var(--line-soft); padding: 36px 28px; }
  .stat:first-child { border-top: none; }
  .telemetry-tags span:nth-child(n+4) { display: none; }
  section.block, .page-hero { padding-top: 80px; padding-bottom: 80px; }
  .page-hero { padding-top: calc(var(--nav-h) + 70px); }
  .brand img.wordmark { height: 20px; }
}

/* Contact link visible only in mobile menu */
.contact-link { display: none; }
@media (max-width: 760px) { .contact-link { display: block; } }

/* Contact page mobile fixes */
.contact-line .v { overflow-wrap: anywhere; }
@media (max-width: 760px) {
  .contact-card { padding: 36px 26px; }
  .contact-line { flex-direction: column; gap: 4px; }
  .contact-line .k { width: auto; }
}

/* Founder photos */
.person .photo {
  width: 200px;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line-soft);
  margin-bottom: 26px;
}
.person .photo img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: contrast(1.03);
}
.person .bio { margin-top: 16px; font-size: 0.88rem; color: var(--muted); line-height: 1.7; }
@media (max-width: 760px) { .person .photo { width: 180px; } }
