/* conspand-site UI kit */
@import url("colors_and_type.css");

html, body { margin: 0; padding: 0; background: var(--c-paper); color: var(--fg-1); font-family: var(--font-body); }
* { box-sizing: border-box; }

/* All interactive elements get pointer cursor */
button, [role="button"], a, label[for], summary { cursor: pointer; }
button:disabled, [aria-disabled="true"] { cursor: not-allowed; }

.container { max-width: 1200px; margin: 0 auto; padding-left: 32px; padding-right: 32px; }
.measure { max-width: 680px; }

.section { padding-top: 96px; padding-bottom: 96px; }
.section-tight { padding-top: 64px; padding-bottom: 64px; }

/* ---- Nav ---- */
.cs-nav {
  position: sticky; top: 0; z-index: 50;
  background: var(--c-paper);
  border-bottom: 1px solid var(--c-ink);
}
.cs-nav-inner {
  display:flex; align-items:center; justify-content:space-between;
  height: 80px;
}
.cs-brand { display:flex; align-items:center; gap:12px; text-decoration:none; color:inherit; }
.cs-brand-mark { height: 32px; width: 32px; }
.cs-brand-word { font-family: var(--font-display); font-weight: 300; font-size: 24px; letter-spacing: -0.01em; }
.cs-nav-links { display:flex; align-items:center; gap:32px; font-size: 14px; }
.cs-nav-link {
  background: none; border: 0; padding: 0; cursor: pointer;
  font: inherit; color: var(--fg-1); text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out);
}
.cs-nav-link:hover { color: var(--fg-accent); }
.cs-nav-link.is-active { color: var(--fg-1); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 6px; }

/* ---- Mobile nav toggle + overlay ---- */
.cs-nav-toggle {
  display: none;                /* shown via media query below */
  background: none; border: 0;
  width: 40px; height: 40px;
  padding: 0;
  cursor: pointer;
  position: relative;
  z-index: 50;                  /* sit above the .cs-nav-overlay (z:49) so the button stays clickable while menu is open */
  margin-right: -8px;           /* optical alignment with right edge */
}
.cs-nav-toggle:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--c-lavender-200); border-radius: 2px; }
.cs-nav-toggle span {
  display: block;
  position: absolute;
  left: 9px; right: 9px;
  height: 1.5px;
  background: var(--c-ink);
  transition: transform var(--dur-base) var(--ease-out),
              top var(--dur-base) var(--ease-out),
              opacity var(--dur-fast) var(--ease-out);
}
.cs-nav-toggle span:nth-child(1) { top: 16px; }
.cs-nav-toggle span:nth-child(2) { top: 22px; }
.cs-nav-toggle.is-open span:nth-child(1) { top: 19px; transform: rotate(45deg); }
.cs-nav-toggle.is-open span:nth-child(2) { top: 19px; transform: rotate(-45deg); }

.cs-nav-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 49;                  /* sits below the sticky nav bar (z:50) */
  background: var(--c-paper);
  padding: calc(64px + 48px) 24px 48px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  overflow-y: auto;
  animation: cs-nav-fade var(--dur-base) var(--ease-out);
}
@keyframes cs-nav-fade { from { opacity: 0; } to { opacity: 1; } }
.cs-nav-overlay-inner {
  display: flex; flex-direction: column;
  gap: 4px;
  align-items: flex-start;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
}
.cs-nav-overlay-link {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(36px, 9vw, 52px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--c-ink);
  text-decoration: none;
  padding: 10px 0;
}
.cs-nav-overlay-link.is-active {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 10px;
}
.cs-nav-overlay-cta {
  margin-top: 32px;
  align-self: flex-start;
}

/* ---- Button ---- */
.btn {
  font-family: var(--font-body); font-size: 14px; font-weight: 500;
  padding: 12px 22px; border-radius: 2px; cursor: pointer;
  border: 1px solid var(--c-ink); background: var(--c-ink); color: #fff;
  text-decoration: none; display: inline-flex; align-items: center; gap: 8px;
  transition: background var(--dur-fast) var(--ease-out), opacity var(--dur-fast) var(--ease-out);
}
.btn:hover { background: #2a2a2a; }
.btn:active { opacity: 0.85; }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--c-lavender-200); }
.btn-secondary { background: transparent; color: var(--c-ink); }
.btn-secondary:hover { background: var(--c-ink); color: #fff; }
.btn-accent { background: var(--c-lavender); border-color: var(--c-lavender); color: var(--c-ink); }
.btn-accent:hover { background: var(--c-lavender-600); color: #fff; border-color: var(--c-lavender-600); }
.btn-ghost { background: transparent; border: none; color: var(--c-ink); padding: 8px 4px; text-decoration: underline; text-underline-offset: 3px; }
.btn-ghost:hover { color: var(--fg-accent); background: transparent; }
.btn.on-dark { background: #fff; color: var(--c-ink); border-color: #fff; }
.btn.on-dark:hover { background: #e6e6e6; }

/* ---- Hero (minimal home) ---- */
.hero-min {
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
  padding: 80px 0;
}
.hero-min-inner {
  max-width: 880px;
  text-align: left;
}
.hero-min-eyebrow {
  font-size: 12px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: lowercase; color: var(--fg-2); margin: 0 0 28px;
}
.hero-min-headline {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(40px, 5.5vw, 76px); line-height: 1.08;
  letter-spacing: -0.025em; margin: 0 0 48px; color: var(--fg-1);
  text-wrap: balance;
}
.hero-min-actions { display: flex; gap: 16px; align-items: center; }

@media (max-width: 700px) {
  .hero-min { min-height: calc(100vh - 64px); padding: 48px 0; }
}

/* ---- Hero (legacy two-column; kept for reference, unused on home) ---- */
.hero {
  padding: 120px 0 96px;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 80px;
  align-items: center;
}
.hero-eyebrow {
  font-size: 12px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: lowercase; color: var(--fg-2); margin: 0 0 20px;
}
.hero-headline {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(48px, 6vw, 84px); line-height: 1.02;
  letter-spacing: -0.025em; margin: 0; color: var(--fg-1);
  text-wrap: balance;
}
.hero-headline em { font-style: normal; color: var(--c-lavender-600); }
.hero-sub {
  font-size: 18px; line-height: 1.6; color: var(--fg-2);
  max-width: 520px; margin: 24px 0 36px;
}
.hero-actions { display: flex; gap: 12px; align-items: center; }
.hero-mark-wrap {
  display: flex; align-items: center; justify-content: center;
  aspect-ratio: 1; max-width: 380px; margin-left: auto;
}
.hero-mark {
  width: 100%; height: auto;
}

/* ---- Eyebrow + heading pair ---- */
.eyebrow {
  font-size: 12px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: lowercase; color: var(--fg-2); margin: 0 0 16px;
}
.section-title {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(36px, 4vw, 52px); line-height: 1.05;
  letter-spacing: -0.02em; margin: 0 0 24px; color: var(--fg-1);
  text-wrap: balance;
}
.section-lead {
  font-size: 18px; line-height: 1.6; color: var(--fg-2); max-width: 680px; margin: 0 0 48px;
}

/* ---- Principles grid ---- */
.principles {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
  border-top: 1px solid var(--c-ink);
  border-left: 1px solid var(--c-ink);
}
.principle {
  padding: 32px;
  border-right: 1px solid var(--c-ink);
  border-bottom: 1px solid var(--c-ink);
  background: var(--c-paper);
  min-height: 280px;
  display: flex; flex-direction: column;
}
.principle-num { font-family: var(--font-mono); font-size: 12px; color: var(--fg-3); }
.principle-title { font-family: var(--font-display); font-weight: 400; font-size: 26px; line-height: 1.15; margin: 56px 0 12px; }
.principle.is-accent {
  background: var(--c-ink); color: #fff; position: relative;
}
.principle.is-accent .principle-title { color: #fff; }
.principle.is-accent .principle-num { color: #9a9a9a; }
.principle.is-accent .principle-body { color: #c8c8c8; }
.principle.is-accent .principle-mark { position: absolute; top: 24px; right: 24px; height: 28px; width: 28px; filter: invert(1); }
.principle-title { font-family: var(--font-display); font-weight: 400; font-size: 26px; line-height: 1.15; margin: 56px 0 12px; }
.principle-body { font-size: 14px; line-height: 1.6; color: var(--fg-2); }

/* ---- Pull quote (matches design system's Pull quote specimen) ---- */
.quote-section { padding-top: 32px; padding-bottom: 96px; }
.pullquote {
  margin: 0;
  padding: 40px 44px;
  background: var(--bg-2);
  display: flex;
  align-items: flex-start;
  gap: 24px;
  max-width: 880px;
}
.pullquote-mark {
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 300;
  font-size: 84px;
  line-height: 0.8;
  color: var(--c-gold-600);
  flex-shrink: 0;
}
.pullquote-body { flex: 1; min-width: 0; }
.pullquote-text {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(20px, 2.2vw, 26px);
  line-height: 1.4;
  color: var(--fg-1);
  margin: 0;
  text-wrap: pretty;
}
.pullquote-cite {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: lowercase;
  color: var(--fg-2);
  margin-top: 18px;
}

/* ---- Legacy quote-band (kept for any other surface still using it) ---- */
.quote-band {
  background: var(--c-gold);
  position: relative; overflow: hidden;
  padding: 96px 0;
}
.quote-band::before {
  content: ""; position: absolute; inset: 0;
  background-image: url("assets/mark-transparent.svg");
  background-size: 320px;
  opacity: 0.025;
  pointer-events: none;
}
.quote-inner { position: relative; max-width: 880px; margin: 0 auto; padding: 0 32px; text-align: left; }
.quote-mark {
  font-family: var(--font-display); font-weight: 300; font-size: 96px;
  line-height: 0.5;
  color: var(--c-ink);
  display: block;
  margin: 0 0 24px;
  text-align: left;
}
.quote-text {
  font-family: var(--font-display); font-weight: 400; font-size: clamp(28px, 3.4vw, 44px);
  line-height: 1.2; letter-spacing: -0.015em; color: var(--c-ink);
  text-wrap: balance; margin: 0 0 32px;
}
.quote-cite {
  font-size: 12px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: lowercase; color: var(--c-ink);
}

/* ---- Stat band ---- */
.stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--c-ink);
}
.stat { padding: 48px 32px; border-right: 1px solid var(--c-ink); }
.stat:last-child { border-right: none; }
.stat-big {
  font-family: var(--font-display); font-weight: 300;
  font-size: 88px; line-height: 0.9; letter-spacing: -0.03em; color: var(--c-ink);
}
.stat-label { font-size: 14px; font-weight: 500; margin-top: 20px; }
.stat-sub { font-size: 13px; color: var(--fg-2); margin-top: 4px; }

/* ---- Work feature (one or more project tiles) ---- */
.work-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.work-feature {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  align-items: stretch;
  width: 100%;
  min-width: 0;
  border: 1px solid var(--c-ink);
  background: var(--c-paper);
  text-decoration: none;
  color: inherit;
  transition: background var(--dur-base) var(--ease-out);
}
.work-feature:hover { background: var(--bg-2); }
.work-feature-mark {
  background: #e5dd40;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid var(--c-ink);
  padding: 32px;
  min-width: 0;
  overflow: hidden;
}
.work-feature-mark img {
  width: 60%;
  height: auto;
  display: block;
  filter: brightness(0);          /* render the sign as ink on the yellow */
}

/* Mystery variant — ink ground, paper-color mark. Used for the internal
   research tiles (telesis, axiom): no public site, no logo to show, held
   back by design. */
.work-feature.is-mystery .work-feature-mark {
  background: var(--c-ink);
}
.work-feature.is-mystery .work-feature-mark img {
  filter: brightness(0) invert(1);
  opacity: 0.85;
  width: 52%;
}
.work-feature.is-mystery .work-feature-mark img[src*="mark-transparent"] {
  transform: rotate(180deg);
}
.work-feature.is-mystery:hover .work-feature-mark img { opacity: 1; }

/* Service variant — paper ground, conspand mark rendered in ink at large
   scale. Used for consulting and any other tile where the offer is "from
   us, directly" rather than a hidden internal thread or a sub-brand. */
.work-feature.is-service .work-feature-mark {
  background: var(--c-paper);
}
.work-feature.is-service .work-feature-mark img {
  filter: none;
  opacity: 0.92;
  width: 48%;
}
.work-feature.is-service:hover .work-feature-mark img { opacity: 1; }
.work-feature-body {
  padding: 40px 44px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  justify-content: center;
}
.work-feature-meta {
  font-family: var(--font-mono); font-size: 12px; color: var(--fg-3);
}
.work-feature-title {
  font-family: var(--font-display); font-weight: 400;
  font-size: 36px; line-height: 1.1; margin: 0; color: var(--fg-1);
}
.work-feature-desc {
  font-size: 15px; line-height: 1.6; color: var(--fg-2);
  max-width: 520px; margin: 0;
}
.work-feature-link {
  font-size: 14px; font-weight: 700; color: var(--c-ink);
  margin-top: 8px;
}

@media (max-width: 720px) {
  /* (work-feature mobile rules consolidated into the main mobile breakpoint below) */
}

/* ---- Contact CTA / dark ---- */
.cta-dark {
  background: var(--c-ink); color: #fff;
  padding: 120px 0;
  text-align: center;
  position: relative; overflow: hidden;
}
.cta-dark::before {
  content: ""; position: absolute; inset: 0;
  background-image: url("assets/pattern.svg");
  background-size: 280px;
  opacity: 0.05;
  filter: invert(1);
  pointer-events: none;
}
.cta-dark .cta-inner { position: relative; max-width: 700px; margin: 0 auto; padding: 0 32px; }
.cta-eyebrow { color: #9a9a9a; }
.cta-title {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(40px, 5vw, 68px); line-height: 1.05; letter-spacing: -0.02em;
  margin: 16px 0 32px; color: #fff; text-wrap: balance;
}
.cta-sub { color: #c8c8c8; font-size: 18px; line-height: 1.6; margin: 0 0 32px; }

/* ---- Form ---- */
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.form-field { display: flex; flex-direction: column; gap: 6px; text-align: left; }
.form-field label { font-size: 13px; font-weight: 500; color: var(--fg-1); }
.form-field input, .form-field textarea {
  font-family: var(--font-body); font-size: 15px;
  padding: 12px 14px; background: #fff; color: var(--fg-1);
  border: 1px solid var(--c-ink); border-radius: 2px; outline: none;
}
.form-field input:focus, .form-field textarea:focus { box-shadow: 0 0 0 3px var(--c-lavender-200); }
.on-dark .form-field label { color: #fff; }
.on-dark .form-field input, .on-dark .form-field textarea {
  background: transparent; color: #fff; border-color: #fff;
}
.on-dark .form-field input::placeholder, .on-dark .form-field textarea::placeholder { color: #9a9a9a; }

/* ---- Footer ---- */
.cs-footer {
  background: var(--c-ink); color: #c8c8c8;
  padding: 48px 0 32px;
  border-top: 1px solid var(--c-ink);
}
.cs-footer-top { display: flex; justify-content: space-between; align-items: flex-start; padding-bottom: 32px; border-bottom: 1px solid #2a2a2a; }
.cs-footer-tag { font-size: 12px; letter-spacing: 0.18em; text-transform: lowercase; color: #9a9a9a; margin-top: 14px; }
.cs-footer-bottom { display: flex; justify-content: space-between; padding-top: 24px; font-size: 13px; color: #5a5a5a; }
.cs-footer-links { display: flex; gap: 24px; }
.cs-footer-links a { color: #c8c8c8; text-decoration: none; }
.cs-footer-links a:hover { color: #fff; }
.cs-footer .cs-brand-mark { filter: invert(1); }
.cs-footer .cs-brand-word { color: #fff; }

/* ---- Manifesto reading view ---- */
.manifesto-page { padding-top: 96px; padding-bottom: 64px; }
.manifesto-page p:not(.eyebrow) { font-size: 19px; line-height: 1.7; color: var(--fg-1); max-width: 680px; margin: 0 0 24px; }
.manifesto-page p.lead { font-family: var(--font-display); font-weight: 400; font-size: 28px; line-height: 1.35; color: var(--fg-1); margin-bottom: 40px; }
.manifesto-page hr { border: 0; border-top: 1px solid var(--c-ink); margin: 64px 0 48px; max-width: 80px; }

/* ---- Contact page ---- */
.contact-page { padding-top: 96px; padding-bottom: 96px; display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; }
.contact-page .info p:not(.eyebrow) { font-size: 18px; line-height: 1.6; color: var(--fg-2); max-width: 420px; }
.contact-page .info dl { display: grid; grid-template-columns: max-content 1fr; gap: 12px 24px; margin-top: 32px; font-size: 14px; }
.contact-page .info dt { font-size: 12px; font-weight: 500; letter-spacing: 0.18em; text-transform: lowercase; color: var(--fg-2); }
.contact-page .info dd { margin: 0; color: var(--fg-1); }

/* =========================================================
   Responsive
   =========================================================
   Two breakpoints:
   - 900px (tablet): collapse multi-column grids to fewer columns
   - 720px (mobile): switch to hamburger nav, shrink type,
     stack footer + contact + work, tighten paddings.
   ========================================================= */

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; gap: 48px; padding: 80px 0; }
  .hero-mark-wrap { max-width: 240px; margin: 0 auto; }
  .principles { grid-template-columns: 1fr 1fr; }
  .stats, .work-grid { grid-template-columns: 1fr; }
  .stat { border-right: none; border-bottom: 1px solid var(--c-ink); }
  .stat:last-child { border-bottom: none; }
  .contact-page { grid-template-columns: 1fr; gap: 48px; }
  .form-row { grid-template-columns: 1fr; }
  .cs-nav-links { gap: 22px; }
}

@media (max-width: 720px) {
  /* ---- Layout primitives ---- */
  .container { padding-left: 20px; padding-right: 20px; }
  .section { padding-top: 64px; padding-bottom: 64px; }
  .section-tight { padding-top: 48px; padding-bottom: 48px; }

  /* ---- Nav: swap to hamburger ---- */
  .cs-nav-inner { height: 64px; }
  .cs-brand-mark { height: 28px; width: 28px; }
  .cs-brand-word { font-size: 20px; }
  .cs-nav-links { display: none; }
  .cs-nav-toggle { display: block; }

  /* ---- Hero ---- */
  .hero-min {
    min-height: auto;
    padding-top: 96px;
    padding-bottom: 128px;
  }
  .hero-min-eyebrow { margin: 0 0 20px; }
  .hero-min-headline { font-size: clamp(34px, 8vw, 48px); margin: 0 0 32px; }
  .hero-min-actions { flex-wrap: wrap; row-gap: 8px; }

  /* ---- Section titles ---- */
  .section-title { font-size: clamp(30px, 8vw, 42px); }
  .section-lead { font-size: 16px; margin-bottom: 32px; }

  /* ---- Principles ---- */
  .principles { grid-template-columns: 1fr; }
  .principle {
    min-height: 0;
    padding: 24px 22px 28px;
  }
  .principle-title { margin: 24px 0 10px; font-size: 22px; }
  .principle.is-accent .principle-mark { top: 20px; right: 20px; }

  /* ---- Pull quote ---- */
  .quote-section { padding-top: 16px; padding-bottom: 64px; }
  .pullquote { padding: 28px 24px; gap: 16px; }
  .pullquote-mark { font-size: 60px; line-height: 0.8; }
  .pullquote-cite { margin-top: 14px; }

  /* ---- Legacy quote band ---- */
  .quote-band { padding: 64px 0; }
  .quote-inner { padding: 0 20px; }
  .quote-mark { font-size: 64px; margin: 0 0 16px; }
  .quote-text { font-size: clamp(22px, 5.5vw, 30px); }

  /* ---- Stats ---- */
  .stat { padding: 32px 22px; }
  .stat-big { font-size: 64px; }
  .stat-label { margin-top: 16px; }

  /* ---- Work feature ---- */
  .work-feature { grid-template-columns: minmax(0, 1fr); }
  .work-feature-mark {
    border-right: 0;
    border-bottom: 1px solid var(--c-ink);
    aspect-ratio: auto;               /* let the panel size by min-height, not ratio */
    min-height: 180px;
    padding: 32px 24px;
  }
  .work-feature-mark img { width: 32%; }
  .work-feature.is-mystery .work-feature-mark img { width: 28%; }
  .work-feature.is-service .work-feature-mark img { width: 26%; }
  .work-feature-body { padding: 28px 22px 32px; gap: 10px; }
  .work-feature-title { font-size: 28px; }

  /* ---- CTA dark band ---- */
  .cta-dark { padding: 72px 0; }
  .cta-dark .cta-inner { padding: 0 20px; }
  .cta-title { font-size: clamp(30px, 8vw, 44px); margin: 12px 0 24px; }
  .cta-sub { font-size: 16px; }

  /* ---- Contact page ---- */
  .contact-page { padding-top: 64px; padding-bottom: 56px; gap: 40px; }
  .contact-page .info p:not(.eyebrow) { font-size: 16px; }
  .contact-page .info dl { gap: 10px 20px; }
  .contact-page form { padding: 24px !important; }   /* override inline padding */

  /* ---- Manifesto ---- */
  .manifesto-page { padding-top: 64px; padding-bottom: 40px; }
  .manifesto-page p:not(.eyebrow) { font-size: 17px; line-height: 1.6; }
  .manifesto-page p.lead { font-size: 22px; line-height: 1.4; margin-bottom: 32px; }
  .manifesto-page hr { margin: 48px 0 32px; }

  /* ---- Footer: stack everything ---- */
  .cs-footer { padding: 40px 0 28px; }
  .cs-footer-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding-bottom: 24px;
  }
  .cs-footer-tag { margin-top: 0; }
  .cs-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding-top: 20px;
  }
  .cs-footer-links { flex-wrap: wrap; gap: 18px 22px; }
}

/* Very narrow phones — give the principle cards a touch more breathing room. */
@media (max-width: 380px) {
  .container { padding-left: 16px; padding-right: 16px; }
  .principle { padding: 22px 18px 26px; }
  .hero-min-headline { font-size: clamp(30px, 8.5vw, 40px); }
}
