/* Copperstate UTV Adventures – shared styles (index.html, gallery.html, 404.html)
   Rules of the house:
   - Text is always a solid colour + text-shadow. Never background-clip:text / transparent fills
     (that caused the old "missing E" rendering bug).
   - Letter-spaced uppercase text balances its trailing space with padding-inline-start so it stays centred.
   - Everything animated is switched off under prefers-reduced-motion. */

@font-face {
  font-family: "Oswald";
  src: url("/assets/fonts/oswald-latin-var.woff2") format("woff2");
  font-weight: 400 600; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212;
}

:root {
  --font-display: "Oswald", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --font-body: Georgia, "Iowan Old Style", "Times New Roman", serif;
  --ink: #f3e2c7;          /* body text */
  --sand: #f6d9a6;         /* headings */
  --copper-hi: #e0a878;    /* ring highlight sampled from the badge */
  --copper: #d39268;       /* badge lettering */
  --copper-mid: #9e6240;
  --copper-lo: #7a4a2e;
  --night: #140c1c;
  --ease-out: cubic-bezier(.2,.7,.2,1);
}

*,*::before,*::after { margin:0; padding:0; box-sizing:border-box; }
html { background:var(--night); -webkit-text-size-adjust:100%; text-size-adjust:100%; }
body {
  min-height:100vh; min-height:100svh;
  display:flex; flex-direction:column;
  font-family:var(--font-body); color:var(--ink);
  overflow-x:hidden; position:relative;
  -webkit-font-smoothing:antialiased; -moz-osx-font-smoothing:grayscale;
  /* Twilight: indigo/plum sky fading to a copper/amber horizon */
  background: linear-gradient(180deg,
    #0c0a1f 0%, #171233 18%, #2a1840 36%, #4a2140 52%,
    #7a3434 66%, #b3562c 76%, #d9853a 83%, #c46a34 92%, #8a4028 100%);
  background-attachment: fixed;
}
img { max-width:100%; }

/* ---------- Background scene ---------- */
.scene { position:fixed; inset:0; pointer-events:none; z-index:0; overflow:hidden; }
.glow { position:absolute; left:50%; bottom:6%; width:160vmax; height:60vh; transform:translateX(-50%);
  background: radial-gradient(ellipse 50% 50% at 50% 70%, rgba(255,170,90,.42), rgba(230,110,50,.16) 45%, transparent 72%); }
canvas#sky { position:absolute; inset:0; width:100%; height:100%; }
.haze { position:absolute; left:-10%; right:-10%; bottom:10%; height:30vh;
  background: linear-gradient(180deg, transparent, rgba(240,150,90,.13) 55%, transparent);
  filter: blur(8px); animation: hazeDrift 40s ease-in-out infinite alternate; }
@keyframes hazeDrift { from { transform:translateX(-3%); } to { transform:translateX(3%); } }
.land { position:absolute; left:0; bottom:0; width:100%; height:auto; display:block; }
.land.far  { height:30vh; min-height:170px; }
.land.mid  { height:22vh; min-height:130px; }
.land.near { height:17vh; min-height:110px; }
.vignette { position:absolute; inset:0; background: radial-gradient(ellipse 85% 75% at 50% 45%, transparent 55%, rgba(6,3,10,.55) 100%); }

/* ---------- Skip link ---------- */
.skip { position:absolute; left:-999px; top:.5rem; z-index:20; background:var(--sand); color:#1a1020;
  padding:.5em 1em; border-radius:6px; font-family:var(--font-display); letter-spacing:.06em; }
.skip:focus { left:.5rem; }

/* ---------- Header + nav ---------- */
.site-header { position:relative; z-index:3; display:flex; align-items:center; justify-content:space-between; gap:1rem;
  padding: max(.9rem, env(safe-area-inset-top)) max(clamp(1rem, 4vw, 2.5rem), env(safe-area-inset-right)) .4rem max(clamp(1rem, 4vw, 2.5rem), env(safe-area-inset-left)); }
.site-header.solo { justify-content:flex-end; }
.home-badge { display:block; overflow:visible; transition: transform .25s var(--ease-out), filter .25s ease; }
.home-badge img { width:clamp(60px, 8vw, 88px); height:auto; display:block; object-fit:contain; filter: drop-shadow(0 8px 18px rgba(0,0,0,.5)); }
.home-badge:hover { transform: rotate(-4deg) scale(1.04); }
.home-badge:focus-visible { outline:2px solid #ffd9a8; outline-offset:4px; }

.sitenav { display:flex; align-items:center; gap:.25rem; padding:.3rem;
  border-radius:999px; background: rgba(20,12,28,.42); border:1px solid rgba(158,98,64,.45);
  box-shadow: 0 6px 20px rgba(0,0,0,.28), inset 0 1px 0 rgba(224,168,120,.12);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.sitenav a { display:inline-flex; align-items:center; gap:.45em; min-height:44px;
  padding:.35em 1em .35em calc(1em + .2em); border-radius:999px;
  font-family:var(--font-display); font-weight:500; font-size:.8rem; letter-spacing:.2em; text-transform:uppercase;
  color:rgba(243,226,199,.82); text-decoration:none; border:1px solid transparent;
  text-shadow:0 1px 2px rgba(0,0,0,.7);
  transition: color .2s ease, background-color .2s ease, border-color .2s ease, box-shadow .2s ease;
  -webkit-tap-highlight-color: transparent; }
.sitenav a svg { width:.95em; height:.95em; flex:none; }
.sitenav a:hover { color:var(--copper-hi); background:rgba(122,74,46,.32); }
.sitenav a:focus-visible { outline:2px solid var(--copper-hi); outline-offset:2px; color:var(--copper-hi); }
.sitenav a[aria-current="page"] { color:var(--copper-hi); background:rgba(122,74,46,.42); border-color:rgba(211,146,104,.55);
  box-shadow: inset 0 1px 0 rgba(224,168,120,.25); }
.sitenav a.nav-call { color:#fff1de; background: linear-gradient(180deg, rgba(196,98,45,.85), rgba(130,56,28,.85)); border-color:rgba(255,200,140,.45); }
.sitenav a.nav-call:hover, .sitenav a.nav-call:focus-visible { color:#fff; box-shadow: 0 0 0 3px rgba(255,170,90,.2), 0 0 18px rgba(240,140,70,.45); }
@media (max-width: 420px) {
  .sitenav a { font-size:.8rem; letter-spacing:.1em; padding:.35em .7em .35em calc(.7em + .1em); }
  .sitenav a .nav-label-long { display:none; }
}
@media (max-width: 400px) {
  .site-header { gap:.5rem; padding-left:max(.7rem, env(safe-area-inset-left)); padding-right:max(.7rem, env(safe-area-inset-right)); }
  .home-badge img { width:50px; }
  .sitenav { gap:.1rem; padding:.25rem; }
  .sitenav a { font-size:.78rem; letter-spacing:.06em; padding:.35em .55em .35em calc(.55em + .06em); min-height:44px; }
}
@media (max-width: 340px) {
  .home-badge img { width:42px; }
  .sitenav a { font-size:.75rem; letter-spacing:.03em; padding:.3em .45em .3em calc(.45em + .03em); }
  .sitenav a svg { display:none; }
}

/* ---------- Type ---------- */
.eyebrow, .display { font-family:var(--font-display); font-weight:500; text-transform:uppercase; color:var(--sand);
  text-shadow: 0 0 18px rgba(255,170,90,.32), 0 2px 6px rgba(0,0,0,.7); }
.rule { width:min(52vw, 240px); height:1px; margin-inline:auto; background:linear-gradient(90deg, transparent, #d98a4a, transparent); opacity:.85; }

/* ---------- Buttons ---------- */
.btn { position:relative; display:inline-flex; align-items:center; justify-content:center; gap:.6em;
  min-height:48px; padding:.7em 1.6em; border-radius:999px;
  font-family:var(--font-display); font-weight:500; letter-spacing:.08em; line-height:1.1;
  text-decoration:none; cursor:pointer; -webkit-tap-highlight-color: transparent;
  transition: transform .22s var(--ease-out), box-shadow .22s ease, background-color .22s ease, border-color .22s ease, color .22s ease; }
.btn svg { width:1em; height:1em; flex:none; }
.btn-copper { color:#fff6e8; font-size: clamp(1.2rem, 4.6vw, 1.55rem); font-weight:600;
  background: linear-gradient(180deg, #c8652f 0%, #9a4724 100%);
  border:1px solid rgba(255,200,140,.55);
  box-shadow: 0 10px 28px rgba(0,0,0,.45), 0 0 0 0 rgba(255,170,90,0), 0 0 24px rgba(230,120,50,.22), inset 0 1px 0 rgba(255,225,190,.45), inset 0 -2px 0 rgba(80,30,12,.35);
  text-shadow: 0 1px 2px rgba(60,20,5,.6); }
.btn-copper:hover, .btn-copper:focus-visible { transform:translateY(-2px);
  box-shadow: 0 14px 34px rgba(0,0,0,.5), 0 0 0 4px rgba(255,170,90,.22), 0 0 38px rgba(240,140,70,.5), inset 0 1px 0 rgba(255,225,190,.5), inset 0 -2px 0 rgba(80,30,12,.35); }
.btn-copper:active { transform:translateY(0); }
.btn-ghost { color:var(--sand); font-size:.92rem; letter-spacing:.18em; text-transform:uppercase; padding-inline:1.5em calc(1.5em - .18em);
  background: rgba(20,12,28,.38); border:1px solid rgba(211,146,104,.6);
  box-shadow: 0 6px 18px rgba(0,0,0,.3), inset 0 1px 0 rgba(224,168,120,.15); text-shadow:0 1px 3px rgba(0,0,0,.7); }
.btn-ghost:hover, .btn-ghost:focus-visible { color:var(--copper-hi); border-color:var(--copper-hi); background:rgba(122,74,46,.35); transform:translateY(-2px);
  box-shadow: 0 10px 24px rgba(0,0,0,.35), 0 0 0 3px rgba(211,146,104,.18), 0 0 22px rgba(211,146,104,.3); }
.btn-ghost .arrow { transition: transform .22s var(--ease-out); }
.btn-ghost:hover .arrow, .btn-ghost:focus-visible .arrow { transform: translateX(3px); }
.btn:focus-visible { outline:2px solid #ffd9a8; outline-offset:3px; }

/* ---------- Footer (fine print, in normal flow) ---------- */
.site-foot { position:relative; z-index:2; text-align:center; padding: 1.1rem 1rem max(.8rem, env(safe-area-inset-bottom)); }
.site-foot .copyright { max-width:46rem; margin:0 auto .45rem; font-size:.8rem; line-height:1.5; letter-spacing:.02em; color:rgba(243,226,199,.72); text-shadow:0 1px 3px rgba(0,0,0,.85); text-wrap:balance; }
.site-foot .partner-logo { position:absolute; right:1rem; bottom:max(.8rem, env(safe-area-inset-bottom)); }
.site-foot .partner-logo img { display:block; height:36px; width:auto; }
.credit { position:relative; z-index:2; text-align:center; padding: 0;
  font-size:.75rem; letter-spacing:.1em; text-transform:uppercase; color:rgba(243,226,199,.72); text-shadow:0 1px 3px rgba(0,0,0,.75); }
.credit a { display:inline-flex; align-items:center; min-height:44px; padding:0 .35rem; color:rgba(240,190,130,.95); text-decoration:underline; text-decoration-color:rgba(240,190,130,.4); text-underline-offset:3px; transition:color .2s, text-decoration-color .2s; }
.credit a:hover, .credit a:focus-visible { color:#ffd9a8; text-decoration-color:#ffd9a8; outline:none; }
.credit a:focus-visible { outline:2px solid #ffd9a8; outline-offset:2px; }

/* ---------- Entrance animation ---------- */
.enter { animation: enterUp .8s var(--ease-out) both; animation-delay: calc(var(--d, 0) * 90ms + 150ms); }
@keyframes enterUp { from { opacity:0; transform:translateY(10px); } to { opacity:1; transform:none; } }

@media (prefers-reduced-motion: reduce) {
  .haze, .enter { animation:none; }
  .btn, .btn-ghost .arrow, .home-badge, .sitenav a { transition:none; }
  .btn:hover, .btn:focus-visible, .home-badge:hover { transform:none; }
}

/* ---------- Footer legal links + policy boxes ---------- */
.foot-links { display:flex; flex-wrap:wrap; justify-content:center; gap:.2rem .2rem; margin:0 auto .45rem; font-size:.85rem; letter-spacing:.08em; }
.foot-links a { color:rgba(246,217,166,.92); text-decoration:none; padding:.35rem .6rem; min-height:44px; display:inline-flex; align-items:center;
  border-bottom:1px solid transparent; text-shadow:0 1px 3px rgba(0,0,0,.85); }
.foot-links a:hover, .foot-links a:focus-visible { color:#ffd9a8; border-color:rgba(255,217,168,.6); outline:none; }
.policy-box { max-width:46rem; margin: clamp(1.4rem,4vw,2rem) auto 0; padding: 1rem 1.25rem; text-align:left; border:1px solid rgba(224,168,120,.5);
  border-radius:14px; background:rgba(20,10,24,.72); line-height:1.55; color:rgba(243,226,199,.95); }
.policy-box h3 { font-family:var(--font-display); font-weight:600; text-transform:uppercase; letter-spacing:.1em; font-size:1rem; color:var(--sand); margin-bottom:.45rem; }
.policy-box p + p, .policy-box p + ul, .policy-box ul + p { margin-top:.55rem; }
.policy-box ul { padding-left:1.2rem; }
.policy-box li { margin:.2rem 0; }
.policy-box a, .legal a, .form-privacy a { color:#ffd9a8; }
.policy-box.risk { border-color:rgba(255,170,110,.75); box-shadow:inset 4px 0 0 #c8652f; }
.form-privacy { font-size:.85rem; color:rgba(243,226,199,.8); text-align:center; }
/* Long-form legal pages (privacy, terms, accessibility) */
.legal { position:relative; z-index:1; flex:1; width:100%; max-width:780px; margin:0 auto; padding:.5rem clamp(1rem,4vw,2rem) clamp(2rem,6vw,3.5rem); }
.legal .intro { text-align:center; margin:.25rem auto clamp(1.3rem,4vw,2rem); }
.legal h1 { display:inline-block; font-weight:500; font-size:clamp(1.45rem,4.6vw,2.3rem); letter-spacing:.2em; padding-inline-start:.2em; }
.legal .rule { margin:1rem auto; }
.legal .eff { font-style:italic; color:rgba(243,226,199,.85); }
.legal .doc { border:1px solid rgba(255,200,140,.28); border-radius:20px; padding:clamp(1.2rem,4vw,2rem);
  background:linear-gradient(180deg, rgba(34,20,40,.9), rgba(22,13,28,.94)); box-shadow:0 18px 44px rgba(0,0,0,.5), inset 0 1px 0 rgba(224,168,120,.12);
  line-height:1.6; color:rgba(243,226,199,.95); }
.legal .doc h2 { font-family:var(--font-display); font-weight:600; text-transform:uppercase; letter-spacing:.1em; font-size:1.08rem; color:var(--sand); margin:1.5rem 0 .5rem; }
.legal .doc h2:first-child { margin-top:0; }
.legal .doc p + p, .legal .doc p + ul, .legal .doc ul + p { margin-top:.6rem; }
.legal .doc ul { padding-left:1.25rem; }
.legal .doc li { margin:.25rem 0; }
.legal .doc strong { color:var(--sand); }
/* Contrast fix: footer fine print sits over the bright sunset glow on some pages; a soft dark fade keeps it readable. */
.site-foot { background:linear-gradient(180deg, rgba(14,8,20,0), rgba(14,8,20,.62) 35%, rgba(14,8,20,.72)); }
.site-foot .copyright { color:rgba(243,226,199,.9); }
.credit { color:rgba(243,226,199,.7); }
