/* ==========================================================
   Whistworks — shared styles
   ========================================================== */

:root {
  /* Surfaces */
  --bg:        #0E1217;
  --bg-2:      #14181F;
  --bg-3:      #181D26;

  /* Ink */
  --paper:     #EFE8DA;
  --paper-90:  rgba(239, 232, 218, .90);
  --paper-70:  rgba(239, 232, 218, .68);
  --paper-50:  rgba(239, 232, 218, .48);
  --paper-30:  rgba(239, 232, 218, .28);

  /* Gold */
  --gold:      #C9A861;
  --gold-2:    #E2C988;
  --gold-deep: #B9902F;

  /* Hairlines */
  --rule:        rgba(185, 144, 47, .18);
  --rule-strong: rgba(185, 144, 47, .42);
  --rule-soft:   rgba(239, 232, 218, .10);

  /* Type */
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans:  'Geist', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --mono:  'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;

  /* Layout */
  --container-max: 1320px;
  --container-pad: 64px;
}

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

html, body { min-height: 100%; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--paper);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html {
  overflow-x: visible;
}

/* Top hairline brand mark */
body::before {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, var(--gold-deep) 18%, var(--gold-2) 50%, var(--gold-deep) 82%, transparent 100%);
  z-index: 100;
  pointer-events: none;
}

a { color: inherit; text-decoration: none; }

/* ---------- Layout primitives ---------- */

.page {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  max-width: 100vw;
}

.page > * {
  min-width: 0;
  max-width: 100vw;
}

main {
  min-width: 0;
  max-width: 100vw;
}

main > * {
  min-width: 0;
  max-width: 100vw;
}

.container {
  width: min(100% - 64px, var(--container-max));
  margin: 0 auto;
}

.container-narrow {
  width: min(100% - 64px, 980px);
  margin: 0 auto;
}

/* ---------- Header ---------- */

/* ---------- Header ---------- */

header.site {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--rule);
  background: rgba(14, 18, 23, .82);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.nav {
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 0 0 auto;
}

.brand .logo {
  width: 52px;
  height: 52px;
  object-fit: contain;
  flex: 0 0 auto;
}

.brand-text {
  display: grid;
  gap: 5px;
  line-height: 1;
}

.wordmark {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: .26em;
  text-transform: lowercase;
  color: var(--paper);
  white-space: nowrap;
}

.tagline {
  font-family: var(--mono);
  color: var(--gold-2);
  font-size: .68rem;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  white-space: nowrap;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.top-nav a {
  position: relative;
  display: inline-block;
  padding: 8px 14px;
  color: var(--paper-70);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  transition: color .18s ease;
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 6px;
  padding: 10px 16px;
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
  color: var(--gold-2) !important;
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
}

/* ---------- Footer ---------- */

/* ---------- Footer ---------- */

footer.site {
  border-top: 1px solid var(--rule);
  background: var(--bg-2);
  color: var(--paper-50);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  align-items: center;
  justify-items: center;
  padding: 18px 0 16px;
  text-align: center;
}

.footer-grid .left {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .07em;
}

.footer-grid .left .dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--paper-30);
  display: inline-block;
}

.footer-grid a {
  color: var(--paper-70);
  transition: color .18s ease;
}

.footer-grid a:hover {
  color: var(--gold-2);
}

.footer-grid .right {
  font-family: var(--mono);
  color: var(--gold-2);
  font-size: .72rem;
  letter-spacing: .06em;
  text-transform: none;
  line-height: 1.45;
}

/* ---------- Type building blocks ---------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--mono);
  color: var(--gold-2);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
}

.eyebrow .bar {
  display: inline-block;
  width: 28px;
  height: 1px;
  background: var(--gold-2);
}

.display {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.6rem, 6vw, 5.6rem);
  line-height: .94;
  letter-spacing: -.035em;
  color: var(--paper);
}

.display em {
  font-style: italic;
  font-weight: 400;
  color: var(--gold-2);
}

.lede {
  font-family: var(--sans);
  font-weight: 400;
  font-size: clamp(1.05rem, 1.3vw, 1.22rem);
  line-height: 1.55;
  color: var(--paper-70);
  max-width: 56ch;
  letter-spacing: -.005em;
}

.section-eyebrow {
  display: flex;
  align-items: center;
  gap: 18px;
  font-family: var(--mono);
  color: var(--gold-2);
  font-size: .74rem;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
}

.section-eyebrow::before,
.section-eyebrow::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--rule);
}

.section-eyebrow.left::before { display: none; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  border-radius: 999px;
  font-family: var(--sans);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  line-height: 1;
  cursor: pointer;
  transition: background .2s ease, border-color .2s ease, transform .2s ease, color .2s ease;
  border: 1px solid transparent;
  white-space: nowrap;
}

.btn .arrow {
  display: inline-block;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: 1.05rem;
  line-height: 1;
  transition: transform .25s cubic-bezier(.2,.8,.2,1);
}

.btn:hover .arrow { transform: translateX(4px); }

.btn-gold {
  background: var(--gold-2);
  color: var(--bg);
  border-color: var(--gold-2);
}

.btn-gold:hover {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--bg);
}

.btn-ghost {
  background: transparent;
  color: var(--gold-2);
  border-color: var(--rule-strong);
}

.btn-ghost:hover {
  border-color: var(--gold-2);
  background: rgba(201, 166, 72, .06);
}

/* ---------- Decorative pieces ---------- */

.divider-rule {
  display: block;
  height: 1px;
  background: var(--rule);
  border: 0;
}

.frame-corners {
  position: relative;
}

.frame-corners::before,
.frame-corners::after {
  content: '';
  position: absolute;
  width: 14px;
  height: 14px;
  border: 1px solid var(--gold-2);
}

.frame-corners::before { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
.frame-corners::after  { bottom: -1px; right: -1px; border-left: 0; border-top: 0; }

/* ---------- Manifesto / About section ---------- */

.manifesto-section {
  padding: clamp(56px, 7vw, 96px) 0;
}

.manifesto-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: clamp(48px, 6vw, 80px);
  align-items: start;
}

.manifesto-rail {
  max-width: 280px;
}

.manifesto-body {
  width: 100%;
  max-width: 1080px;
}

.manifesto-body p {
  max-width: none;
  font-family: var(--serif);
  font-size: clamp(1.45rem, 2vw, 2.2rem);
  line-height: 1.34;
  letter-spacing: -.02em;
  color: var(--paper);
  margin-bottom: 1.15em;
}

.manifesto-body p:first-child {
  color: var(--paper);
}

.manifesto-body em {
  color: var(--gold-2);
  font-style: italic;
}

.manifesto-body .credit {
  font-family: var(--mono);
  font-size: .78rem;
  line-height: 1.5;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--paper-50);
  margin-top: 2.5rem;
}

.manifesto-body .credit a {
  color: var(--gold-2);
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .container,
  .container-narrow {
    width: min(100% - 36px, var(--container-max));
  }

  .nav {
    height: auto;
    padding: 16px 0;
    flex-wrap: wrap;
    gap: 14px;
  }

  .brand .logo { width: 44px; height: 44px; }
  .wordmark { font-size: .95rem; letter-spacing: .22em; }
  .tagline  { font-size: .62rem; letter-spacing: .12em; }

  .top-nav {
    width: 100%;
    justify-content: space-between;
    gap: 4px;
    border-top: 1px solid var(--rule);
    padding-top: 12px;
  }

  .top-nav a {
    padding: 6px 8px;
    font-size: .68rem;
    letter-spacing: .14em;
  }

  .nav-cta {
    margin-left: 0;
    padding: 8px 12px;
    font-size: .64rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 18px 0;
  }

  .footer-grid .left { font-size: .68rem; gap: 10px; }
  .footer-grid .right { font-size: .68rem; }
}
