/* Reusable UI primitives: kickers, bylines, cards, reveal animations, buttons. */

/* ---------- EDITORIAL PRIMITIVES ---------- */
.kicker {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--green-700);
}
.kicker.inverse { color: var(--green-500); }

.meta-small {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}

.link-underline {
  background-image: linear-gradient(currentColor, currentColor);
  background-size: 100% 1px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size .3s var(--ease);
}
.link-underline:hover { background-size: 100% 1.5px; }

/* ---------- REVEAL ON SCROLL ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .5s var(--ease), transform .5s var(--ease);
}
[data-reveal].in {
  opacity: 1;
  transform: none;
}
[data-reveal-delay="1"].in { transition-delay: .15s; }
[data-reveal-delay="2"].in { transition-delay: .3s; }

/* ---------- BYLINE / META ROW ---------- */
.byline {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.byline .sep {
  width: 3px; height: 3px;
  border-radius: 50%;
  background: var(--rule);
  flex: none;
}

/* ---------- STORY CARD (shared on rails + masonry) ---------- */
.card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform .4s var(--ease);
}
.card:hover { transform: translateY(-4px); }

.card .ph {
  aspect-ratio: 4/5;
  overflow: hidden;
  background: var(--stone);
  position: relative;
}
.card.feature .ph { aspect-ratio: 3/4; }
.card.wide .ph { aspect-ratio: 5/4; }
.card.square .ph { aspect-ratio: 1/1; }

.card .ph img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.01);
  transition: transform 1s var(--ease);
  filter: saturate(1.05);
}
.card:hover .ph img { transform: scale(1.03); }

.card .kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.card .kicker::before {
  content: "";
  width: 18px; height: 1px;
  background: var(--green-700);
  flex: none;
}

.card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(18px, 1.35vw, 22px);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0;
  transition: color .2s var(--ease);
}
.card.feature h3 { font-size: clamp(28px, 2.4vw, 36px); }
.card:hover h3 { color: var(--green-700); }

.card .excerpt {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.5;
}

/* ---------- WORTH CARD (sidebar-style story list) ---------- */
.worth-card {
  display: grid;
  grid-template-columns: 1fr 120px;
  gap: 18px;
  padding-top: 20px;
  border-top: 1px solid var(--ink);
  transition: transform .4s var(--ease);
}
.worth-card:hover { transform: translateY(-3px); }
.worth-card .kicker {
  display: block;
  margin-bottom: 10px;
}
.worth-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 22px;
  line-height: 1.14;
  letter-spacing: -0.01em;
  margin: 0 0 10px;
  transition: color .2s var(--ease);
}
.worth-card:hover h3 { color: var(--green-700); }
.worth-card .thumb {
  width: 120px;
  height: 140px;
  overflow: hidden;
  background: var(--stone);
}
.worth-card .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .9s var(--ease);
}
.worth-card:hover .thumb img { transform: scale(1.05); }

/* ---------- RAIL HEAD (shared across all section rails) ---------- */
.rail-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.rail-head .lead {
  display: flex;
  align-items: baseline;
  gap: 20px;
}
.rail-head .num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  color: var(--muted);
  letter-spacing: .02em;
  font-feature-settings: "lnum";
}
.rail-head h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(36px, 4vw, 56px);
  letter-spacing: -0.02em;
  line-height: 1;
  margin: 0;
  text-wrap: balance;
}
.rail-head h2 em {
  color: var(--green-700);
  font-style: italic;
}
.rail-head .subtitle {
  font-family: var(--serif);
  font-style: italic;
  font-size: 17px;
  line-height: 1.4;
  color: var(--muted);
  max-width: 44ch;
  text-align: right;
  margin: 0;
}
.rail-head .subtitle a {
  color: var(--green-700);
  font-weight: 500;
  font-family: var(--sans);
  font-style: normal;
  font-size: 13px;
  letter-spacing: .02em;
  display: inline-block;
  margin-top: 4px;
}

/* ---------- BUTTONS ---------- */
.btn-primary {
  background: var(--pink);
  color: #fff;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: .02em;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  transition: background .2s var(--ease), transform .25s var(--ease);
  align-self: flex-start;
}
.btn-primary:hover {
  background: var(--pink-deep);
  transform: translateY(-1px);
  color: #fff;
}
.btn-primary .wc-icon {
  width: 16px; height: 16px;
  transition: transform .3s var(--ease);
}
.btn-primary:hover .wc-icon { transform: translateX(4px); }

/* ---------- STICKY MOBILE CTA ---------- */
.sticky-cta {
  position: fixed;
  left: 16px; right: 16px; bottom: 16px;
  z-index: 60;
  background: var(--ink);
  color: var(--cream);
  border-radius: 999px;
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 10px 10px 10px 18px;
  box-shadow: 0 20px 40px -18px rgba(0, 0, 0, .35);
  font-size: 13px;
  letter-spacing: .02em;
  transform: translateY(120%);
  transition: transform .4s var(--ease), opacity .3s;
  opacity: 0;
}
.sticky-cta.is-on {
  transform: translateY(0);
  opacity: 1;
}
.sticky-cta .inner {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sticky-cta .inner .wc-icon { width: 14px; height: 14px; }
.sticky-cta .right {
  display: flex;
  align-items: center;
  gap: 6px;
}
.sticky-cta .go {
  background: var(--pink);
  color: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 500;
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.sticky-cta .close {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(246, 241, 232, .1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.sticky-cta .close .wc-icon { width: 14px; height: 14px; }

@media (max-width: 1024px) {
  .sticky-cta { display: flex; }
}
