/* ============================================================
   benjirosenthal.com — v1
   Palette carried over from the resume: cream / forest / ember
   ============================================================ */

:root {
  --cream: #F4F0E6;
  --cream-deep: #ECE6D6;
  --ink: #20261E;
  --ink-soft: #4A5244;
  --green: #2C5540;
  --green-deep: #1E3C2D;
  --ember: #D9782D;
  --line: rgba(32, 38, 30, 0.16);
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --pad: clamp(1.25rem, 5vw, 4rem);
  --max: 1120px;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--ember); color: var(--cream); }

a { color: inherit; }

/* ---------- Nav ---------- */

.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem var(--pad);
  transition: background 0.35s ease, box-shadow 0.35s ease;
}
.nav.is-scrolled {
  background: color-mix(in srgb, var(--cream) 88%, transparent);
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 var(--line);
}
.nav__mark {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.3rem;
  color: var(--green);
  text-decoration: none;
  letter-spacing: 0.02em;
}
.nav__links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  font-size: 0.92rem;
  font-weight: 500;
}
.nav__links a { text-decoration: none; color: var(--ink-soft); transition: color 0.2s; }
.nav__links a:hover { color: var(--green); }
.nav__cta {
  color: var(--cream) !important;
  background: var(--green);
  padding: 0.45rem 1.1rem;
  border-radius: 99px;
  transition: background 0.2s, transform 0.2s;
}
.nav__cta:hover { background: var(--green-deep); transform: translateY(-1px); }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 7rem var(--pad) 5rem;
  max-width: var(--max);
  margin-inline: auto;
}
.hero__eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ember);
  margin-bottom: 1.4rem;
}
.hero__name {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(3.2rem, 11vw, 7.6rem);
  line-height: 1.02;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin-bottom: 1.1rem;
}
.hero__role {
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  font-weight: 500;
  color: var(--green);
  letter-spacing: 0.01em;
  margin-bottom: 1.6rem;
}
.hero__role .amp { font-family: var(--serif); font-style: italic; color: var(--ember); }
.hero__lede {
  max-width: 44rem;
  font-size: clamp(1rem, 1.9vw, 1.2rem);
  color: var(--ink-soft);
  margin-bottom: 2.4rem;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.9rem; }

.hero__ghost {
  position: absolute;
  right: -0.06em;
  bottom: -0.14em;
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(6rem, 22vw, 17rem);
  line-height: 1;
  letter-spacing: 0.02em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(44, 85, 64, 0.14);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.7rem;
  border-radius: 99px;
  font-weight: 600;
  font-size: 0.98rem;
  text-decoration: none;
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), background 0.25s, color 0.25s, border-color 0.25s;
  will-change: transform;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--green); color: var(--cream); }
.btn--primary:hover { background: var(--green-deep); }
.btn--ghost { border: 1px solid var(--line); color: var(--ink); }
.btn--ghost:hover { border-color: var(--green); color: var(--green); }
.btn--light { background: var(--cream); color: var(--green-deep); }
.btn--light:hover { background: #fff; }
.btn--outline { border: 1px solid rgba(244, 240, 230, 0.5); color: var(--cream); }
.btn--outline:hover { border-color: var(--cream); }
.btn__arrow { transition: transform 0.25s; }
.btn:hover .btn__arrow { transform: translateY(3px); }

/* ---------- Marquee ---------- */

.marquee {
  border-block: 1px solid var(--line);
  padding: 1.4rem 0 1.6rem;
  overflow: hidden;
  background: var(--cream-deep);
}
.marquee__label {
  text-align: center;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}
.marquee__track {
  display: flex;
  width: max-content;
  gap: 3.5rem;
  animation: marquee 36s linear infinite;
}
.marquee__list {
  display: flex;
  gap: 3.5rem;
  list-style: none;
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--green);
  white-space: nowrap;
}
.marquee__list li::after {
  content: "◆";
  font-size: 0.55rem;
  color: var(--ember);
  vertical-align: middle;
  margin-left: 3.5rem;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-50% - 1.75rem)); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee__track { animation: none; flex-wrap: wrap; width: auto; justify-content: center; }
  .marquee__list { flex-wrap: wrap; justify-content: center; row-gap: 0.5rem; }
}

/* ---------- Stats ---------- */

.stats { background: var(--green-deep); color: var(--cream); }
.stats__grid {
  max-width: var(--max);
  margin-inline: auto;
  padding: clamp(3rem, 7vw, 5rem) var(--pad);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem;
}
.stat__value {
  font-family: var(--serif);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 500;
  line-height: 1;
  margin-bottom: 0.6rem;
}
.stat__unit { font-size: 0.5em; color: var(--ember); font-weight: 600; }
.stat__label {
  font-size: 0.92rem;
  color: rgba(244, 240, 230, 0.72);
  max-width: 15rem;
}
@media (max-width: 860px) {
  .stats__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 460px) {
  .stats__grid { grid-template-columns: 1fr; }
}

/* ---------- Sections ---------- */

.section {
  max-width: var(--max);
  margin-inline: auto;
  padding: clamp(4.5rem, 10vw, 7.5rem) var(--pad);
}
.section--alt { max-width: none; background: var(--cream-deep); }
.section--alt > * { max-width: var(--max); margin-inline: auto; }
.section__head { margin-bottom: clamp(2.5rem, 6vw, 4rem); }
.section__eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ember);
  margin-bottom: 0.9rem;
}
.section__title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.1rem, 5.5vw, 3.6rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
}

/* ---------- Timeline entries ---------- */

.timeline { display: flex; flex-direction: column; }
.entry {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2rem;
  padding: 2.4rem 0;
  border-top: 1px solid var(--line);
}
.entry__dates {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ember);
  letter-spacing: 0.04em;
}
.entry__loc { font-size: 0.85rem; color: var(--ink-soft); margin-top: 0.3rem; }
.entry__role {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(1.35rem, 2.6vw, 1.8rem);
  line-height: 1.2;
  margin-bottom: 0.7rem;
}
.entry__at { color: var(--ember); }
.entry__summary { color: var(--ink-soft); max-width: 46rem; margin-bottom: 0.9rem; }
.entry__points {
  list-style: none;
  max-width: 46rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.entry__points li {
  padding-left: 1.15rem;
  position: relative;
  font-size: 0.97rem;
  color: var(--ink);
}
.entry__points li::before {
  content: "◆";
  position: absolute;
  left: 0;
  top: 0.42em;
  font-size: 0.5rem;
  color: var(--ember);
}
@media (max-width: 720px) {
  .entry { grid-template-columns: 1fr; gap: 0.6rem; }
}

/* ---------- Earlier cards ---------- */

.earlier { margin-top: clamp(2.5rem, 6vw, 4rem); }
.earlier__label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1.4rem;
}
.earlier__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.2rem;
}
.card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.5rem 1.6rem;
  background: rgba(255, 255, 255, 0.35);
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.3s;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px -18px rgba(30, 60, 45, 0.35);
}
.card__title { font-family: var(--serif); font-weight: 500; font-size: 1.15rem; margin-bottom: 0.2rem; }
.card__dates { font-size: 0.82rem; font-weight: 600; color: var(--ember); margin-bottom: 0.6rem; }
.card__text { font-size: 0.95rem; color: var(--ink-soft); }
@media (max-width: 720px) {
  .earlier__grid { grid-template-columns: 1fr; }
}

/* ---------- Quote ---------- */

.quote {
  background: var(--cream);
  max-width: var(--max);
  margin-inline: auto;
  padding: clamp(4rem, 9vw, 6.5rem) var(--pad);
  border-top: 1px solid var(--line);
}
.quote__text {
  font-family: var(--serif);
  font-weight: 400;
  font-style: italic;
  font-size: clamp(1.45rem, 3.4vw, 2.3rem);
  line-height: 1.35;
  color: var(--green-deep);
  max-width: 56rem;
}
.quote__attr {
  margin-top: 1.8rem;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ember);
}

/* ---------- Skills ---------- */

.chips {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}
.chip {
  border: 1px solid var(--line);
  border-radius: 99px;
  padding: 0.55rem 1.2rem;
  font-size: 0.93rem;
  font-weight: 500;
  background: rgba(255, 255, 255, 0.4);
  transition: border-color 0.2s, transform 0.2s;
}
.chip:hover { border-color: var(--green); transform: translateY(-2px); }
.chip em {
  font-style: normal;
  color: var(--ember);
  font-weight: 600;
  font-size: 0.82em;
  margin-left: 0.35rem;
}
.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  border-top: 1px solid var(--line);
  padding-top: 2.2rem;
}
.fact__label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ember);
  margin-bottom: 0.4rem;
}
.fact__value { font-size: 0.98rem; }
@media (max-width: 720px) {
  .facts { grid-template-columns: 1fr; }
}

/* ---------- Outro / contact ---------- */

.outro {
  background: var(--green-deep);
  color: var(--cream);
  padding: clamp(5rem, 11vw, 8rem) var(--pad);
  text-align: center;
}
.outro__eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ember);
  margin-bottom: 1.2rem;
}
.outro__title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(1.9rem, 5vw, 3.4rem);
  line-height: 1.15;
  max-width: 52rem;
  margin-inline: auto;
  margin-bottom: 2.4rem;
}
.outro__actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.9rem; }

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

.footer {
  background: var(--green-deep);
  color: rgba(244, 240, 230, 0.55);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 1.4rem var(--pad) 1.8rem;
  font-size: 0.85rem;
  border-top: 1px solid rgba(244, 240, 230, 0.12);
}
.footer__top { color: inherit; text-decoration: none; }
.footer__top:hover { color: var(--cream); }

/* ---------- Split-text scaffolding (JS adds spans) ---------- */

.split-line-mask { overflow: hidden; display: block; }
