/* ═══════════════════════════════════════════════════════════
   YELLOW COWBOY LLC — yellowcowboy.com
   Palette sampled directly from the logo badge.
   ═══════════════════════════════════════════════════════════ */

:root {
  /* ink */
  --ink:      #14100d;
  --ink-2:    #1f1813;
  --char:     #3a312b;

  /* sun */
  --marigold: #e79b00;
  --amber:    #f2a83b;
  --gold:     #ffc53d;
  --rust:     #b4530f;
  --ember:    #8a3a12;

  /* paper */
  --cream:    #f2e2bd;
  --bone:     #fdf4e0;
  --sand:     #e6d2a8;

  --shadow-hard: 5px 5px 0 var(--ink);

  --wrap: 1120px;
  --pad: clamp(1.25rem, 5vw, 4rem);

  --font-display: "Rye", "Bitter", Georgia, serif;
  --font-body: "Bitter", Georgia, "Times New Roman", serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 5rem; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

/* ── Paleta cursor ─────────────────────────────────────────
   Only on real pointing devices — never fight a touchscreen,
   and never hide the caret in a text field.                  */
@media (pointer: fine) {
  body, .btn, a, button, summary {
    cursor: url("../assets/paleta-cursor.png") 10 3, auto;
  }
  a, .btn, button, summary, [role="button"] {
    cursor: url("../assets/paleta-cursor.png") 10 3, pointer;
  }
  input, textarea, select { cursor: auto; }
}

/* ── Paper grain, sitting over everything ──────────────────── */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
  opacity: 0.32;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='220' height='220' filter='url(%23n)' opacity='0.45'/%3E%3C/svg%3E");
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--gold); color: var(--ink);
  padding: 0.75rem 1.25rem; font-weight: 700; text-decoration: none;
}
.skip:focus { left: 0; }

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
  border-radius: 2px;
}

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

/* ═══ NAV ═══════════════════════════════════════════════════ */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem clamp(1rem, 4vw, 2.5rem);
  background: rgba(20, 16, 13, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid rgba(242, 226, 189, 0.16);
  transition: background 0.3s ease, border-color 0.3s ease;
}
.nav.is-stuck {
  background: rgba(20, 16, 13, 0.96);
  border-bottom-color: var(--marigold);
}

.nav__brand {
  display: flex; align-items: center; gap: 0.65rem;
  color: var(--cream); text-decoration: none;
  font-family: var(--font-display);
  font-size: 1.05rem; letter-spacing: 0.01em;
}
.nav__mark {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 2px solid var(--marigold);
}

.nav__links { display: flex; align-items: center; gap: clamp(0.85rem, 2.5vw, 1.75rem); }
.nav__links a {
  color: var(--cream); text-decoration: none;
  font-size: 0.875rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  white-space: nowrap;
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}
.nav__links a:hover { color: var(--gold); border-bottom-color: var(--gold); }

.nav__cta {
  background: var(--marigold); color: var(--ink) !important;
  padding: 0.5rem 0.95rem !important;
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  border-bottom-color: var(--ink) !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s;
}
.nav__cta:hover {
  background: var(--gold);
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 var(--ink);
}

/* The bar has to stay one line. Drop the wordmark first, then tighten
   the links, then shed "The Story" — it's a one-page site, scrolling
   still gets you everywhere. */
@media (max-width: 560px) {
  .nav { padding-inline: 0.75rem; }
  .nav__brand span { display: none; }
  .nav__links { gap: 0.7rem; }
  .nav__links a { font-size: 0.72rem; letter-spacing: 0.04em; }
  .nav__cta { padding: 0.45rem 0.7rem !important; }
}
@media (max-width: 400px) {
  .nav__links a[href="#story"] { display: none; }
}

/* ═══ BUTTONS ═══════════════════════════════════════════════ */
.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-size: clamp(0.95rem, 0.9rem + 0.2vw, 1.05rem);
  line-height: 1.2;
  padding: 0.95rem 1.75rem;
  text-decoration: none;
  border: 3px solid var(--ink);
  box-shadow: var(--shadow-hard);
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.2s ease;
}
.btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--ink);
}
.btn:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--ink); }

.btn--gold { background: var(--gold); color: var(--ink); }
.btn--gold:hover { background: #ffd76a; }

/* Sits on the bright part of the sunset, so it has to go dark
   rather than outlined — cream on gold is unreadable. */
.btn--ghost {
  background: var(--ink); color: var(--bone);
  border-color: var(--ink);
}
.btn--ghost:hover { background: var(--char); color: #fff; }

/* ═══ HERO ══════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: calc(100svh - 60px);
  display: grid;
  place-items: center;
  padding: clamp(2.5rem, 7vh, 5rem) var(--pad) clamp(7rem, 15vh, 10rem);
  overflow: hidden;
  isolation: isolate;
}

.hero__sky {
  position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(120% 85% at 50% 100%, #ffd166 0%, var(--amber) 22%, var(--rust) 48%, #5c250c 72%, var(--ink) 100%);
}

.hero__sun {
  position: absolute;
  left: 50%; bottom: 6%;
  width: min(46vw, 420px); aspect-ratio: 1;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle, #fff3c4 0%, #ffd166 45%, rgba(255, 197, 61, 0) 72%);
  filter: blur(2px);
  opacity: 0.9;
}

.hero__rays {
  position: absolute;
  left: 50%; bottom: 8%;
  width: 200vmax; aspect-ratio: 1;
  transform: translate(-50%, 50%);
  background: repeating-conic-gradient(
    from 0deg,
    rgba(255, 240, 190, 0.16) 0deg 2.2deg,
    rgba(255, 240, 190, 0) 2.2deg 9deg
  );
  -webkit-mask-image: radial-gradient(circle, #000 8%, transparent 42%);
  mask-image: radial-gradient(circle, #000 8%, transparent 42%);
  animation: spin 240s linear infinite;
}
@keyframes spin { to { transform: translate(-50%, 50%) rotate(360deg); } }

.hero__inner { position: relative; z-index: 1; text-align: center; max-width: 52rem; }

.hero__badge {
  width: clamp(190px, 30vw, 300px);
  aspect-ratio: 1;
  border-radius: 50%;
  margin: 0 auto clamp(1.25rem, 3vw, 2rem);
  border: 4px solid rgba(20, 16, 13, 0.85);
  box-shadow:
    0 0 0 6px rgba(242, 226, 189, 0.25),
    0 26px 60px rgba(20, 16, 13, 0.55);
  animation: badge-in 0.9s cubic-bezier(0.2, 0.8, 0.25, 1) both;
}
@keyframes badge-in {
  from { opacity: 0; transform: translateY(22px) scale(0.94); }
  to   { opacity: 1; transform: none; }
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 1.1rem + 2.9vw, 3.35rem);
  line-height: 1.12;
  text-wrap: balance;
  margin: 0 0 1rem;
  color: var(--bone);
  text-shadow: 0 3px 0 rgba(90, 36, 12, 0.55), 0 14px 34px rgba(20, 16, 13, 0.5);
}

/* Lands on the brightest part of the sunburst, so it needs a hard dark
   outline rather than a soft shadow — cream on gold washes out. */
.hero__sub {
  font-size: clamp(1.2rem, 1.05rem + 0.7vw, 1.6rem);
  font-weight: 600;
  line-height: 1.5;
  color: var(--bone);
  margin: 0 auto 2.25rem;
  max-width: 34rem;
  text-wrap: balance;
  text-shadow:
    -2px -2px 0 rgba(20, 16, 13, 0.92),  2px -2px 0 rgba(20, 16, 13, 0.92),
    -2px  2px 0 rgba(20, 16, 13, 0.92),  2px  2px 0 rgba(20, 16, 13, 0.92),
     0   -2px 0 rgba(20, 16, 13, 0.92),  0    2px 0 rgba(20, 16, 13, 0.92),
    -2px  0   0 rgba(20, 16, 13, 0.92),  2px  0   0 rgba(20, 16, 13, 0.92),
     0    5px 18px rgba(60, 22, 6, 0.6);
}

/* Where it's supported, a real stroke painted *behind* the glyphs gives a
   smoother edge than stacked shadows and keeps the letterforms full weight. */
@supports (paint-order: stroke) {
  .hero__sub {
    -webkit-text-stroke: 4px rgba(20, 16, 13, 0.92);
    paint-order: stroke fill;
    text-shadow: 0 5px 18px rgba(60, 22, 6, 0.6);
  }
}

.hero__sub strong { color: var(--gold); font-weight: 800; }

.hero__cta { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; }

/* Stacked buttons look ragged at different widths — match them. */
@media (max-width: 560px) {
  .hero__cta { flex-direction: column; align-items: center; }
  .hero__cta .btn { width: 100%; max-width: 20rem; text-align: center; }
}

.hero__desert {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  width: 100%; height: clamp(120px, 20vh, 230px);
  z-index: 0;
}
.dune--far  { fill: #7a3410; opacity: 0.85; }
.dune--mid  { fill: #4a1d09; opacity: 0.9; }
.dune--near { fill: var(--ink); }

/* ═══ TICKER ════════════════════════════════════════════════ */
.ticker {
  background: var(--marigold);
  border-block: 4px solid var(--ink);
  overflow: hidden;
  padding: 0.7rem 0;
}
.ticker__track { display: flex; width: max-content; animation: slide 46s linear infinite; }
.ticker__set {
  font-family: var(--font-display);
  font-size: clamp(0.95rem, 0.9rem + 0.4vw, 1.35rem);
  color: var(--ink);
  white-space: nowrap;
  padding-right: 2.5rem;
}
.ticker__set i { color: var(--bone); font-style: normal; padding: 0 0.6rem; }
@keyframes slide { to { transform: translateX(-50%); } }
.ticker:hover .ticker__track { animation-play-state: paused; }

/* ═══ SECTIONS ══════════════════════════════════════════════ */
.section { padding: clamp(3.5rem, 9vw, 7rem) 0; position: relative; }
.section--cream { background: var(--cream); }
.section--bone  { background: var(--bone); }
.section--dark  {
  background:
    radial-gradient(90% 70% at 50% 0%, #2b211a 0%, var(--ink) 62%);
  color: var(--cream);
}

.eyebrow {
  font-size: 0.78rem; letter-spacing: 0.22em; text-transform: uppercase;
  font-weight: 700; color: var(--ember);
  margin: 0 0 0.55rem; text-align: center;
}
.eyebrow--light { color: var(--amber); }

.section__title {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 1.2rem + 2.8vw, 3.2rem);
  line-height: 1.1;
  text-align: center;
  margin: 0;
  color: var(--ink);
}
.section__title--light { color: var(--bone); }

.rule {
  display: flex; align-items: center; gap: 0.9rem;
  max-width: 22rem; margin: 1.1rem auto 1.5rem;
  color: var(--ember);
}
.rule::before, .rule::after {
  content: ""; flex: 1; height: 3px;
  background: currentColor; opacity: 0.55;
}
.rule span { font-size: 1.1rem; }
.rule--light { color: var(--amber); }

.section__kicker {
  max-width: 42rem; margin: 0 auto clamp(2rem, 4vw, 3rem);
  text-align: center; color: rgba(242, 226, 189, 0.82);
}
.section__kicker--dark { color: rgba(20, 16, 13, 0.78); }

/* ═══ STORY ═════════════════════════════════════════════════ */
.story {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
@media (max-width: 820px) { .story { grid-template-columns: 1fr; } }

.story__body p { margin: 0 0 1.15rem; color: #3d3128; }
.lede {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 1.05rem + 0.8vw, 1.65rem);
  line-height: 1.4;
  color: var(--ink) !important;
}
.story__sign {
  font-style: italic;
  color: var(--ember) !important;
  margin-top: 1.6rem !important;
}

/* Wanted-poster card, stitched-leather border */
.poster {
  background: var(--ink);
  padding: 10px;
  box-shadow: var(--shadow-hard);
  transform: rotate(-1.2deg);
}
.poster__inner {
  border: 2px dashed rgba(242, 226, 189, 0.5);
  padding: clamp(1.5rem, 3vw, 2.25rem) 1.25rem;
  text-align: center;
  color: var(--cream);
}
.poster__top, .poster__bottom {
  font-size: 0.72rem; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--amber); margin: 0;
}
.poster__big {
  font-family: var(--font-display);
  font-size: clamp(2rem, 1.4rem + 2.6vw, 3rem);
  color: var(--gold);
  margin: 0.5rem 0 1rem;
  line-height: 1;
}
.poster__list {
  list-style: none; margin: 0 0 1.25rem; padding: 0;
  font-size: 0.94rem;
}
.poster__list li { padding: 0.5rem 0; border-top: 1px solid rgba(242, 226, 189, 0.18); }
.poster__list li:last-child { border-bottom: 1px solid rgba(242, 226, 189, 0.18); }

/* ═══ SPOTS ═════════════════════════════════════════════════ */
.spots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 1.25rem;
}
.spot {
  background: rgba(242, 226, 189, 0.05);
  border: 2px solid rgba(242, 226, 189, 0.22);
  padding: 1.5rem 1.4rem;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.spot:hover {
  transform: translateY(-4px);
  border-color: var(--marigold);
  background: rgba(231, 155, 0, 0.09);
}
.spot__day {
  font-family: var(--font-display);
  color: var(--gold); font-size: 1.15rem; margin: 0;
}
.spot__time {
  font-size: 0.78rem; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--amber); margin: 0.15rem 0 0.9rem;
}
.spot__place {
  font-family: var(--font-display); font-weight: 400;
  font-size: 1.25rem; line-height: 1.25;
  margin: 0 0 0.5rem; color: var(--bone);
}
.spot__note { margin: 0; font-size: 0.92rem; color: rgba(242, 226, 189, 0.7); }

.follow {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  text-align: center;
}
.follow p {
  font-family: var(--font-display);
  font-size: 1.1rem; color: var(--cream);
  margin: 0 0 1.1rem;
}

/* ═══ BOOK ══════════════════════════════════════════════════ */
.book {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: clamp(1.75rem, 4vw, 3rem);
  align-items: start;
}
@media (max-width: 900px) { .book { grid-template-columns: 1fr; } }

.book__form {
  background: #fff;
  border: 3px solid var(--ink);
  box-shadow: var(--shadow-hard);
  padding: 6px;
  min-height: 260px;
}
.book__form iframe { display: block; width: 100%; border: 0; }

.form-fallback {
  padding: clamp(1.75rem, 4vw, 2.75rem);
  text-align: center;
  background: var(--cream);
}
.form-fallback__title {
  font-family: var(--font-display);
  font-size: 1.35rem; margin: 0 0 0.75rem; color: var(--ink);
}
.form-fallback p { margin: 0 0 1.25rem; color: #4a3c31; }
.form-fallback code {
  background: rgba(20, 16, 13, 0.09);
  padding: 0.1em 0.4em; border-radius: 3px;
  font-size: 0.9em;
}

.book__side h3 {
  font-family: var(--font-display); font-weight: 400;
  font-size: 1.45rem; margin: 0 0 1rem; color: var(--ink);
}

.contact-list { list-style: none; margin: 0 0 2rem; padding: 0; }
.contact-list li {
  padding: 0.85rem 0;
  border-bottom: 2px solid rgba(20, 16, 13, 0.12);
}
.contact-list__label {
  display: block;
  font-size: 0.72rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ember); font-weight: 700;
}
.contact-list a {
  color: var(--ink); font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  text-decoration-color: var(--marigold);
  word-break: break-word;
}
.contact-list a:hover { color: var(--rust); text-decoration-color: var(--rust); }

.note {
  background: var(--ink); color: var(--cream);
  padding: 1.4rem 1.5rem;
  box-shadow: var(--shadow-hard);
}
.note__title {
  font-family: var(--font-display);
  color: var(--gold); margin: 0 0 0.6rem; font-size: 1.1rem;
}
.note ul { margin: 0; padding-left: 1.1rem; font-size: 0.93rem; }
.note li { margin-bottom: 0.45rem; }
.note li:last-child { margin-bottom: 0; }

/* ═══ FOOTER ════════════════════════════════════════════════ */
.footer {
  background: var(--ink);
  color: var(--cream);
  text-align: center;
  padding: clamp(3rem, 6vw, 4.5rem) var(--pad) 2.5rem;
  border-top: 4px solid var(--marigold);
}
.footer__mark {
  width: 72px; height: 72px; border-radius: 50%;
  margin: 0 auto 1rem;
  border: 2px solid var(--marigold);
}
.footer__name {
  font-family: var(--font-display);
  font-size: 1.6rem; margin: 0; color: var(--bone);
}
.footer__name span { color: var(--amber); font-size: 0.7em; }
.footer__tag {
  margin: 0.35rem 0 1.25rem;
  font-size: 0.85rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(242, 226, 189, 0.65);
}
.footer__links { margin: 0 0 1.5rem; font-size: 0.95rem; color: rgba(242, 226, 189, 0.5); }
.footer__links a { color: var(--gold); text-decoration: none; font-weight: 600; }
.footer__links a:hover { text-decoration: underline; }
.footer__copy { margin: 0; font-size: 0.8rem; color: rgba(242, 226, 189, 0.4); }

/* ═══ REVEAL ════════════════════════════════════════════════
   Classes are only added by JS, so nothing is ever stuck
   invisible if the script fails to load.                      */
.js-reveal .reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.65s ease, transform 0.65s cubic-bezier(0.2, 0.8, 0.25, 1);
}
.js-reveal .poster.reveal { transform: translateY(20px) rotate(-1.2deg); }
.js-reveal .reveal.is-in { opacity: 1; transform: none; }
.js-reveal .poster.reveal.is-in { transform: rotate(-1.2deg); }

.spot:nth-child(2).reveal { transition-delay: 0.1s; }
.spot:nth-child(3).reveal { transition-delay: 0.2s; }

/* ═══ MOTION ════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .ticker__track { animation: none; }
}
