/* ==========================================================================
   Loco Bullies TX — shared stylesheet
   Design tokens + reset + shared components/chrome.
   Consumed verbatim by every page. Mobile-first (base = 390px).
   ========================================================================== */

/* --- Design tokens ------------------------------------------------------- */
:root {
  /* Palette (exact — see plan Global Constraints) */
  --ground: #14100C;
  --panel: #1E1812;
  --line: #3B3226;
  --orange: #F58A1F;   /* sunset orange — primary accent */
  --gold: #E5B64A;
  --bone: #EFE6D7;     /* bone white — body text */
  --dim: #B5A993;      /* dim text */
  --blood: #7A1F1F;    /* blood red — use sparingly */

  /* Type */
  --font-display: "Anton", "Segoe UI", system-ui, sans-serif;
  --font-body: "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono: "Consolas", ui-monospace, monospace;

  /* Layout */
  --wrap: 1080px;
  --radius: 4px;
  --header-h: 60px;
}

/* --- Reset --------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

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

body {
  font-family: var(--font-body);
  background: var(--ground);
  color: var(--bone);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, picture, svg, video { display: block; max-width: 100%; }

a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--gold); }

button { font: inherit; color: inherit; cursor: pointer; }

ul { list-style: none; padding: 0; }

:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }

/* --- Utilities ------------------------------------------------------------ */
.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;
}

.section-tight { padding-top: 0; }

/* --- Layout helpers ------------------------------------------------------ */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 20px;
}

.section {
  padding-block: 48px;
}

@media (min-width: 768px) {
  .section { padding-block: 72px; }
}

/* --- Typography ---------------------------------------------------------- */
.display {
  font-family: var(--font-display);
  font-weight: 400;
  text-transform: uppercase;
  line-height: 0.95;
  letter-spacing: 0.01em;
  font-size: clamp(2.2rem, 6vw + 1rem, 4.5rem);
  color: var(--bone);
}
.display .hot { color: var(--orange); }

.eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--orange);
}

/* --- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  min-height: 44px;
  padding: 0.7em 1.4em;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-align: center;
  transition: transform 0.12s ease, background 0.15s ease, color 0.15s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--orange);
  color: var(--ground);
  border-color: var(--orange);
}
.btn-primary:hover { background: var(--gold); border-color: var(--gold); color: var(--ground); }

.btn-ghost {
  background: transparent;
  color: var(--bone);
  border: 1px solid var(--line);
}
.btn-ghost:hover { border-color: var(--orange); color: var(--orange); }

/* --- Header / nav -------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--ground);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--bone);
}
.brand:hover { color: var(--bone); }
.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--line);
  flex: none;
}
.brand-name {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: 1.2rem;
  letter-spacing: 0.02em;
  line-height: 1;
}
.brand-name .hot { color: var(--orange); }

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--bone);
  font-size: 1.3rem;
  line-height: 1;
}

/* Mobile nav: hidden by default, revealed via JS (aria-expanded on toggle) */
.nav {
  position: absolute;
  top: var(--header-h);
  left: 0;
  right: 0;
  display: none;
  flex-direction: column;
  gap: 2px;
  padding: 8px 20px 16px;
  background: var(--ground);
  border-bottom: 1px solid var(--line);
}
.nav.is-open { display: flex; }

.nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 4px 6px;
  color: var(--bone);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--line);
}
.nav a:last-child { border-bottom: 0; }
.nav a:hover { color: var(--orange); }
.nav a[aria-current="page"] { color: var(--orange); }

/* Instagram glyph link (sits at the end of the nav) */
.nav-ig {
  min-width: 44px;
  justify-content: center;
  color: var(--bone);
}
.nav-ig svg { width: 22px; height: 22px; }
.nav-ig:hover { color: var(--orange); }

@media (min-width: 768px) {
  .nav-toggle { display: none; }
  .brand-mark { width: 36px; height: 36px; }
  .brand-name { font-size: 1.4rem; }
  .nav {
    position: static;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    padding: 0;
    background: transparent;
    border-bottom: 0;
  }
  .nav a {
    min-height: 44px;
    padding: 6px 10px;
    border-bottom: 0;
    font-size: 0.85rem;
  }
  .nav-ig { padding-inline: 8px; }
}

/* --- Hero ------------------------------------------------------------------ */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 78vh;
  display: flex;
  align-items: center;
  background: var(--ground);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 85% 8%, rgb(245 138 31 / 0.20), transparent 55%);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  padding-block: 56px;
}
.hero .eyebrow { margin-bottom: 12px; }
.hero .display { margin-bottom: 16px; }
.hero-sub {
  color: var(--dim);
  font-size: 1.05rem;
  max-width: 42ch;
  margin-bottom: 28px;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

@media (min-width: 768px) {
  .hero { min-height: 86vh; }
}

/* --- Home hero slideshow (index.html) -------------------------------------
   Full-viewport crossfading photo background. Slides are absolutely stacked
   <img>s; JS toggles .is-active to fade between them (see js/main.js). The
   .hero-scrim replaces the base orange glow with a stronger dark wash so the
   logo + headline stay legible over every slide (incl. the golden ones). */
.hero-home { color: var(--bone); }
.hero-home::before { display: none; }      /* scrim element supersedes base glow */

.hero-slides {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.hero-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.2s ease-in-out;
}
.hero-slide.is-active { opacity: 1; }

.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(circle at 82% 6%, rgb(245 138 31 / 0.22), transparent 52%),
    linear-gradient(180deg, rgb(20 16 12 / 0.74) 0%, rgb(20 16 12 / 0.5) 42%, rgb(20 16 12 / 0.86) 100%);
}

.hero-home .hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.hero-home .hero-sub { margin-inline: auto; }
.hero-home .hero-actions { justify-content: center; }

/* Logo: soft radial feather melts the square black edge into the hero while
   keeping the full crest + "LOCO BULLIES" lettering fully opaque (a hard
   circular crop would clip the shield wings and the wordmark). */
.hero-logo {
  width: clamp(200px, 46vw, 300px);
  height: auto;
  margin-bottom: 18px;
  border-radius: 16px;
  -webkit-mask-image: radial-gradient(125% 125% at 50% 50%, #000 80%, transparent 100%);
          mask-image: radial-gradient(125% 125% at 50% 50%, #000 80%, transparent 100%);
  filter: drop-shadow(0 12px 34px rgb(0 0 0 / 0.72));
}

/* --- Section links --------------------------------------------------------- */
.section-link {
  margin-top: 20px;
  font-weight: 700;
}

/* --- CTA band ---------------------------------------------------------------- */
.cta-band {
  padding-block: 48px;
  background: linear-gradient(160deg, rgb(245 138 31 / 0.16), rgb(245 138 31 / 0.04));
  border-block: 1px solid var(--line);
  text-align: center;
}
.cta-band .display { margin-bottom: 24px; }
.cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

@media (min-width: 768px) {
  .cta-band { padding-block: 72px; }
}

/* --- Our Story (index.html) ------------------------------------------------ */
.story-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: center;
}
.story-copy .display { margin-block: 6px 14px; }
.story-copy p + p { margin-top: 14px; }
.story-copy p { max-width: 60ch; }
.story-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}
@media (min-width: 820px) {
  .story-grid { grid-template-columns: 1.5fr 1fr; gap: 40px; }
  .story-photo { aspect-ratio: 4 / 5; max-width: 360px; margin-left: auto; }
}

/* --- Stats band (index.html) ----------------------------------------------- */
.stats-band {
  padding-block: 36px;
  background: var(--panel);
  border-block: 1px solid var(--line);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px 12px;
  text-align: center;
}
@media (min-width: 768px) {
  .stats-band { padding-block: 48px; }
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
}
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat-num {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 8vw, 3rem);
  line-height: 1;
  color: var(--orange);
  letter-spacing: 0.01em;
}
.stat-label {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.7rem;
  color: var(--dim);
}

/* --- The Family (index.html) ----------------------------------------------- */
.family .display { margin-block: 6px 22px; }
.family-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
@media (min-width: 820px) {
  .family-grid { grid-template-columns: repeat(3, 1fr); }
}
.family-card {
  display: flex;
  flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.family-card img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.family-card h3 {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 1.5rem;
  margin: 16px 16px 4px;
}
.family-card p {
  margin: 0 16px 14px;
  color: var(--bone);
  font-size: 0.95rem;
}
.family-card .family-link {
  margin: auto 16px 16px;
  font-weight: 700;
}

/* --- Show ring band (index.html) ------------------------------------------- */
.showring {
  background: linear-gradient(160deg, rgb(229 182 74 / 0.07), rgb(20 16 12 / 0));
  border-block: 1px solid var(--line);
}
.showring .display { margin-block: 6px 22px; }
.pillar-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 820px) {
  .pillar-grid { grid-template-columns: repeat(3, 1fr); }
}
.pillar {
  background: var(--panel);
  border: 1px solid var(--line);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 20px 18px;
}
.pillar-icon { font-size: 1.8rem; line-height: 1; }
.pillar h3 {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 1.25rem;
  margin-block: 10px 6px;
}
.pillar p { color: var(--bone); font-size: 0.92rem; }

/* --- FAQ accordion (index.html) -------------------------------------------- */
/* Native <details>/<summary> — no JS needed. */
.faq .display { margin-block: 6px 20px; }
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 760px;
}
.faq-item {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 44px;
  padding: 12px 16px;
  cursor: pointer;
  font-weight: 700;
  font-size: 1rem;
  color: var(--bone);
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-family: var(--font-display);
  font-size: 1.4rem;
  line-height: 1;
  color: var(--orange);
  flex: none;
}
.faq-item[open] summary::after { content: "–"; }
.faq-item summary:hover { color: var(--orange); }
.faq-body {
  padding: 0 16px 16px;
  color: var(--dim);
}

/* --- Cards --------------------------------------------------------------- */
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  overflow: hidden;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}
@media (min-width: 768px) {
  .card-grid { grid-template-columns: repeat(3, 1fr); }
}

.card h3 {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 1.3rem;
  margin-block: 10px 4px;
}

.card .meta {
  color: var(--dim);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.7rem;
  margin-bottom: 6px;
}

/* --- Status tags (chips) --------------------------------------------------- */
.tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 999px;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.65rem;
  font-weight: 700;
  vertical-align: middle;
}
.tag-available {
  background: rgb(245 138 31 / 0.16);
  color: var(--orange);
  border: 1px solid var(--orange);
}
.tag-reserved {
  background: rgb(181 169 147 / 0.12);
  color: var(--dim);
  border: 1px solid var(--line);
}

/* --- Dog profiles (dogs.html) -------------------------------------------- */
/* Real photos carry these cards; text is deliberately quiet around them. */
.roster-head {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.95;
  font-size: clamp(1.7rem, 3.5vw + 0.6rem, 2.8rem);
  color: var(--bone);
  margin-block: 6px 4px;
}
.roster-head .hot { color: var(--orange); }
.roster-sub {
  color: var(--dim);
  max-width: 60ch;
  margin-bottom: 22px;
}

.dog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
@media (min-width: 620px) {
  .dog-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 980px) {
  .dog-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Card body is a flex column so the show-record badge pins to the bottom,
   keeping badge lines aligned across a row of cards. */
.dog-card { display: flex; flex-direction: column; }

.dog-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--panel);
}

.dog-card h3 { margin-bottom: 2px; }

.dog-spec {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.72rem;
  color: var(--orange);
  margin-bottom: 6px;
}
.dog-ped {
  color: var(--dim);
  font-style: italic;
  font-size: 0.85rem;
  margin-bottom: 10px;
}
.dog-blurb { font-size: 0.95rem; }

.dog-record {
  display: flex;
  gap: 8px;
  align-items: baseline;
  margin-top: auto;                 /* pin to card bottom */
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--gold);
  border-radius: var(--radius);
  background: rgb(229 182 74 / 0.06);
  font-size: 0.82rem;
  color: var(--bone);
}
.dog-record::before { content: "🏆"; }
.dog-record + .dog-record { margin-top: 8px; }

/* --- Legacy / memorial (dogs.html) --------------------------------------- */
.legacy-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}
@media (min-width: 820px) {
  .legacy-grid { grid-template-columns: repeat(2, 1fr); }
}
.legacy-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 20px;
}
.legacy-card h3 {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 1.5rem;
  margin-block: 12px 2px;
}
.legacy-role {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.7rem;
  color: var(--gold);
  margin-bottom: 8px;
}

/* --- Placeholder image (.ph) --------------------------------------------- */
/* Warm dark gradient + dog emoji + label; swapped for real <img> later. */
.ph {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  aspect-ratio: 4 / 5;
  width: 100%;
  border-radius: var(--radius);
  background: linear-gradient(160deg, #241C13, #3B2A17);
  color: var(--dim);
}
.ph::before {
  content: "🐕";
  font-size: clamp(2rem, 8vw, 3rem);
  line-height: 1;
}
.ph[data-label]::after {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.7rem;
  color: var(--dim);
}
.ph[data-label]::after { content: attr(data-label); }

/* --- Gallery grid (gallery.html) ------------------------------------------ */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  grid-auto-flow: dense;
  gap: 12px;
}
@media (min-width: 768px) {
  .gallery-grid { gap: 16px; }
}

/* Gallery tiles are real <button>s (keyboard-operable) wrapping one <img>;
   the button is the fixed-ratio frame and the photo covers it. */
.gallery-item {
  appearance: none;
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  overflow: hidden;
  border-radius: var(--radius);
  aspect-ratio: 4 / 5;
  background: var(--panel);
  transition: filter 0.15s ease;
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gallery-item:hover,
.gallery-item:focus-visible {
  filter: brightness(1.12);
}

/* --- Lightbox (gallery.html) ----------------------------------------------- */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgb(20 16 12 / 0.92); /* ground @ 92% alpha */
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.18s ease, visibility 0.18s ease;
}
.lightbox-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  width: min(90vw, 480px);
  max-height: 88vh;
  display: flex;
  flex-direction: column;
}

.lightbox-img {
  width: 100%;
  max-height: 78vh;
  object-fit: contain;
  border-radius: var(--radius);
  background: var(--panel);
}

.lightbox-caption {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  color: var(--bone);
  margin-top: 10px;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--bone);
  font-size: 1.1rem;
}
.lightbox-close:hover { border-color: var(--orange); color: var(--orange); }

/* --- Contact page (contact.html) ------------------------------------------ */
.contact-actions {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-block: 28px;
}
.contact-actions .btn {
  min-height: 64px;
  width: 100%;
  font-size: 1.05rem;
}
.contact-location {
  color: var(--dim);
  margin-bottom: 8px;
}
.contact-backup {
  color: var(--dim);
}

/* --- Footer -------------------------------------------------------------- */
/* 3-column on desktop, stacked on mobile. Markup is byte-identical across all
   5 pages (no aria-current here). */
.site-footer {
  border-top: 1px solid var(--line);
  background: var(--ground);
  color: var(--dim);
  padding-block: 40px 28px;
  font-size: 0.88rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1.2fr; gap: 32px; }
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.footer-mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--bone);
}
.footer-mark:hover { color: var(--bone); }
.footer-mark img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line);
  flex: none;
}
.site-footer a { color: var(--dim); }
.site-footer a:hover { color: var(--orange); }
.site-footer .footer-brand {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: 1.15rem;
  color: var(--bone);
  letter-spacing: 0.02em;
}
.footer-head {
  font-family: var(--font-display);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.95rem;
  color: var(--bone);
}
.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.footer-legal {
  margin-top: 28px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 0.8rem;
}

/* --- Reduced motion ------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
