/* ===========================================================
   Tsalach Ventures — "Frontier dark + gold"
   =========================================================== */

:root {
  /* Brand tokens: gold #C6A15B · ink #10141B · cream #F7F4EC · muted #B9B6AE */
  --bg:        #0B0E13;
  --bg-elev:   #10141B;
  --bg-card:   #12161F;
  --bg-card-2: #171C26;
  --line:      rgba(247, 244, 236, 0.09);
  --line-gold: rgba(198, 161, 91, 0.30);

  --gold:        #C6A15B;
  --gold-bright: #E2C079;
  --gold-deep:   #9C7A30;

  --ink:        #F7F4EC;
  --ink-soft:   #D7D3C9;
  --muted:      #9A968D;
  --muted-dim:  #6E6B63;

  --serif: "Fraunces", Georgia, serif;
  --sans:  "Hanken Grotesk", system-ui, sans-serif;
  --mono:  "IBM Plex Mono", ui-monospace, monospace;

  --maxw: 1180px;
  --pad: clamp(1.25rem, 4vw, 3rem);
  --r: 14px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--gold); color: #0B0B0D; }

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

.wrap { max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad); }

.skip {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--gold); color: #0B0B0D; padding: .6rem 1rem; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; }

/* ---------- Atmosphere ---------- */
.aurora {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(60% 50% at 78% -5%, rgba(198,161,91,0.18), transparent 60%),
    radial-gradient(45% 40% at 8% 8%, rgba(198,161,91,0.08), transparent 65%),
    radial-gradient(80% 60% at 50% 115%, rgba(156,122,48,0.12), transparent 60%);
  animation: drift 22s var(--ease) infinite alternate;
}
@keyframes drift {
  from { transform: translate3d(0,0,0) scale(1); }
  to   { transform: translate3d(-2%, 1.5%, 0) scale(1.06); }
}
.grain {
  position: fixed; inset: -50%; z-index: -1; pointer-events: none; opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  border-bottom: 1px solid transparent;
  transition: background .4s var(--ease), border-color .4s var(--ease), backdrop-filter .4s;
}
.nav.is-scrolled {
  background: rgba(11,11,13,0.72);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom-color: var(--line);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; height: 78px; }

.brand { display: inline-flex; align-items: center; }
.brand__logo { height: 38px; width: auto; display: block; transition: opacity .3s var(--ease); }
.brand:hover .brand__logo { opacity: .82; }
.brand__name { font-family: var(--serif); font-size: 1.18rem; font-weight: 600; letter-spacing: .01em; }
.brand__name em { font-style: italic; font-weight: 400; color: var(--gold); }
.footer__logo { height: 34px; width: auto; display: block; }

.nav__links { display: flex; gap: 2rem; }
.nav__links a {
  font-size: .82rem; letter-spacing: .04em; color: var(--ink-soft); position: relative; padding: .2rem 0;
  transition: color .3s;
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; bottom: -2px; width: 0; height: 1px; background: var(--gold);
  transition: width .35s var(--ease);
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { width: 100%; }

.nav__right { display: flex; align-items: center; gap: 1rem; }

/* ---------- Chips (locked / status) ---------- */
.chip {
  display: inline-flex; align-items: center; gap: .45rem;
  font-family: var(--mono); font-size: .68rem; letter-spacing: .03em;
  padding: .42rem .7rem; border-radius: 999px;
  border: 1px dashed var(--line-gold); color: var(--gold-bright);
  background: rgba(198,161,91,0.05); white-space: nowrap;
}
.chip--locked { color: var(--muted); border-color: var(--line); }
.chip__lock { font-size: .72rem; filter: grayscale(1) brightness(1.4); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--mono); font-size: .8rem; letter-spacing: .04em;
  padding: .8rem 1.3rem; border-radius: 999px; border: 1px solid transparent;
  cursor: pointer; transition: transform .25s var(--ease), background .3s, color .3s, box-shadow .3s, border-color .3s;
}
.btn--solid {
  background: var(--gold); color: #0B0B0D; font-weight: 500;
  box-shadow: 0 1px 0 rgba(255,255,255,.25) inset, 0 8px 30px -10px rgba(198,161,91,.6);
}
.btn--solid:hover { background: var(--gold-bright); transform: translateY(-2px); box-shadow: 0 14px 40px -12px rgba(198,161,91,.75); }
.btn--ghost { color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--line-gold); color: var(--gold-bright); transform: translateY(-2px); }
.btn--lg { padding: 1rem 1.8rem; font-size: .9rem; }

/* ---------- Hero ---------- */
.hero { padding-top: clamp(4rem, 11vw, 9rem); padding-bottom: clamp(3rem, 7vw, 6rem); }
.eyebrow {
  font-family: var(--mono); font-size: .76rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 1.6rem;
}
.eyebrow span { color: var(--gold); font-style: italic; }

.hero__title {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(2.7rem, 8.2vw, 6.2rem); line-height: 0.98; letter-spacing: -0.02em;
  font-optical-sizing: auto;
}
.hero__title span { display: block; }
.hero__title em { font-style: italic; font-weight: 400; color: var(--gold); }

.hero__sub {
  max-width: 56ch; margin-top: 2rem; font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  color: var(--ink-soft); line-height: 1.6;
}
.hero__cta { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.6rem; }

/* ---------- Trust strip ---------- */
.trust { border-block: 1px solid var(--line); margin-top: clamp(2rem, 6vw, 4.5rem); }
.trust__grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding-block: clamp(1.6rem, 3vw, 2.4rem);
}
.trust__item { text-align: center; padding-inline: .5rem; border-left: 1px solid var(--line); }
.trust__item:first-child { border-left: 0; }
.trust__item b {
  display: block; font-family: var(--serif); font-weight: 500; font-size: clamp(1.5rem, 3vw, 2.2rem);
  color: var(--gold-bright); letter-spacing: -.01em;
}
.trust__item span { font-family: var(--mono); font-size: .68rem; letter-spacing: .06em; color: var(--muted); }

/* ---------- Sections ---------- */
.section { padding-block: clamp(4.5rem, 10vw, 8rem); }
.section--alt { background: linear-gradient(180deg, transparent, rgba(255,255,255,0.012), transparent); }
.section__head { max-width: 60ch; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section__index {
  font-family: var(--mono); font-size: .76rem; letter-spacing: .2em; color: var(--gold);
  display: inline-block; margin-bottom: 1rem;
}
.section__index::before { content: "/ "; color: var(--muted-dim); }
.section__title { font-family: var(--serif); font-weight: 500; font-size: clamp(2rem, 5vw, 3.4rem); letter-spacing: -.02em; line-height: 1.04; }
.section__lead { margin-top: 1rem; color: var(--muted); font-size: 1.05rem; max-width: 52ch; }

/* ---------- Work grid ---------- */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.card {
  position: relative; display: flex; flex-direction: column;
  background: linear-gradient(180deg, var(--bg-card-2), var(--bg-card));
  border: 1px solid var(--line); border-radius: var(--r);
  padding: 1.6rem 1.5rem 1.4rem; min-height: 230px;
  transition: transform .4s var(--ease), border-color .4s, box-shadow .4s;
  overflow: hidden;
}
.card::before {
  content: ""; position: absolute; inset: 0; border-radius: var(--r);
  background: radial-gradient(120% 80% at 100% 0%, rgba(198,161,91,0.10), transparent 55%);
  opacity: 0; transition: opacity .4s var(--ease);
}
.card:hover { transform: translateY(-5px); border-color: var(--line-gold); box-shadow: 0 24px 50px -28px rgba(0,0,0,0.9); }
.card:hover::before { opacity: 1; }
.card__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; margin-bottom: .9rem; }
.card__name { font-family: var(--serif); font-weight: 500; font-size: 1.4rem; letter-spacing: -.01em; }
.card__desc { color: var(--ink-soft); font-size: .95rem; line-height: 1.6; flex: 1; }

.status {
  flex-shrink: 0; font-family: var(--mono); font-size: .62rem; letter-spacing: .05em; text-transform: uppercase;
  padding: .3rem .55rem; border-radius: 999px; display: inline-flex; align-items: center; gap: .35rem;
  border: 1px solid var(--line); color: var(--muted); white-space: nowrap;
}
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status--live   { color: var(--gold-bright); border-color: var(--line-gold); }
.status--live::before { box-shadow: 0 0 8px currentColor; animation: pulse 2.4s ease-in-out infinite; }
.status--pilot  { color: #D9B36A; }
.status--client { color: var(--ink-soft); }
@keyframes pulse { 50% { opacity: .35; } }

.tags { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; margin-top: 1.1rem; }
.tags li {
  font-family: var(--mono); font-size: .66rem; letter-spacing: .02em; color: var(--muted);
  padding: .25rem .55rem; border: 1px solid var(--line); border-radius: 6px; background: rgba(255,255,255,0.015);
}
.card__link {
  margin-top: 1.1rem; font-family: var(--mono); font-size: .74rem; color: var(--gold-bright);
  display: inline-flex; align-items: center; gap: .35rem; align-self: flex-start;
  transition: gap .3s var(--ease), color .3s;
}
.card__link:hover { gap: .6rem; color: var(--gold); }

/* ---------- Capabilities ---------- */
.caps { list-style: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; }
.cap {
  padding: 2rem 1.6rem; border-top: 1px solid var(--line); position: relative;
  transition: background .35s;
}
.cap:nth-child(odd) { border-right: 1px solid var(--line); }
.cap:last-child:nth-child(odd) { grid-column: 1 / -1; }
.cap:hover { background: rgba(198,161,91,0.035); }
.cap__num {
  font-family: var(--mono); font-size: .72rem; color: var(--gold); letter-spacing: .1em;
  display: block; margin-bottom: .9rem;
}
.cap h3 { font-family: var(--serif); font-weight: 500; font-size: 1.45rem; margin-bottom: .5rem; letter-spacing: -.01em; }
.cap p { color: var(--muted); font-size: .95rem; max-width: 42ch; }

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: 280px 1fr; gap: clamp(2rem, 5vw, 5rem); align-items: start; }
.about__head .section__title { margin-top: .6rem; }
.about__lead { font-family: var(--serif); font-size: clamp(1.4rem, 2.6vw, 2rem); line-height: 1.35; font-weight: 400; letter-spacing: -.01em; }
.about__lead strong { color: var(--gold-bright); font-weight: 500; }
.about__body p:not(.about__lead) { margin-top: 1.4rem; color: var(--ink-soft); font-size: 1.05rem; }
.about__body em { color: var(--gold); font-style: italic; }
.about__body .chip { margin-top: 2rem; }

/* ---------- CTA band ---------- */
.cta-band { border-top: 1px solid var(--line); }
.cta-band__inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2rem;
  padding-block: clamp(3.5rem, 8vw, 6rem);
}
.cta-band h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(1.8rem, 4.5vw, 3rem); letter-spacing: -.02em; max-width: 18ch; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); background: var(--bg-elev); }
.footer__inner {
  display: grid; grid-template-columns: 1fr auto auto; gap: 1.5rem 3rem; align-items: center;
  padding-block: 2.6rem;
}
.footer__brand .brand__name { font-size: 1.05rem; }
.footer__brand p { font-family: var(--mono); font-size: .74rem; color: var(--muted); margin-top: .4rem; }
.footer__contact a { font-family: var(--mono); font-size: .82rem; color: var(--gold-bright); transition: color .3s; }
.footer__contact a:hover { color: var(--gold); }
.footer__copy { font-family: var(--mono); font-size: .7rem; color: var(--muted-dim); }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(22px); }
.reveal.in {
  opacity: 1; transform: none;
  transition: opacity .8s var(--ease) var(--d, 0s), transform .8s var(--ease) var(--d, 0s);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .nav__links { display: none; }
  .chip { display: none; }
  .about { grid-template-columns: 1fr; }
  .footer__inner { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .grid { grid-template-columns: 1fr; }
  .caps { grid-template-columns: 1fr; }
  .cap:nth-child(odd) { border-right: 0; }
  .trust__grid { grid-template-columns: repeat(2, 1fr); gap: 1.5rem 0; }
  .trust__item:nth-child(3) { border-left: 0; }
  .nav__right .chip--locked { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .aurora, .status--live::before { animation: none; }
  html { scroll-behavior: auto; }
}
