/* =====================================================================
   Content pages (team, events, gallery, shop) — loaded after site.css
   ===================================================================== */
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.small { font-size: .9rem; }
.title-sm { font-size: clamp(1.9rem, 4.5vw, 2.75rem); margin-bottom: 1rem; }
.center-link { text-align: center; margin: 2.5rem auto 0; max-width: none; }
.site-nav a[aria-current="page"] { color: var(--red-hot); }
.site-nav .nav-cta[aria-current="page"] { color: #fff; background: var(--red-hot); }
.section-dark { background: var(--surface); }
.section-detail { padding-top: 56px; }
.empty {
  padding: 32px; background: var(--surface); border: 1px solid var(--border);
  border-left: 4px solid var(--red); border-radius: var(--radius);
}
.empty p:last-child { margin-bottom: 0; }
.ph-portrait { aspect-ratio: 4 / 5; }
.ph-wide { aspect-ratio: 16 / 10; }

/* Breadcrumbs */
.breadcrumbs { font-size: .9rem; color: var(--muted); margin-bottom: 1.25rem; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--fg); }
.breadcrumbs [aria-current] { color: var(--fg); }

/* Crew chips on home */
.crew-chips { list-style: none; padding: 0; margin: 0 0 1.5rem; display: flex; flex-wrap: wrap; gap: 8px; }
.crew-chips li {
  background: var(--surface); border: 1px solid var(--border); padding: 8px 14px;
  font-size: .95rem; border-left: 3px solid var(--red);
}
.crew-chips span { color: var(--muted); }

/* Events */
.event-list { display: grid; gap: 12px; max-width: 860px; margin: 2rem auto 0; }
.event-card-link {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center;
  text-decoration: none; background: rgba(20,20,22,.94); border: 1px solid var(--border);
  transition: border-color .15s var(--ease), transform .15s var(--ease);
}
.event-card-link:hover { border-color: var(--red); transform: translateX(4px); }
.event-date {
  align-self: stretch; display: flex; align-items: center; justify-content: center;
  min-width: 108px; padding: 16px 28px 16px 18px; background: var(--red); color: #fff; text-align: center;
  clip-path: polygon(0 0, 100% 0, calc(100% - 14px) 100%, 0 100%);
}
.is-past .event-date { background: #3a3a40; }
.event-date time { display: flex; flex-direction: column; }
.event-day { font: italic 900 2.5rem/1 var(--font-display); }
.event-month { font: italic 800 .85rem/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .08em; }
.event-body { padding: 16px 20px; min-width: 0; }
.event-title { font: italic 900 1.6rem/1 var(--font-display); text-transform: uppercase; margin: 0 0 .35rem; }
.event-place { margin: 0 0 .25rem; color: #e4e4e4; font-weight: 500; }
.event-body .muted { margin: 0; font-size: .95rem; }
.event-arrow { padding: 0 20px; font-size: 1.5rem; color: var(--red-hot); }
@media (max-width: 559px) {
  .event-card-link { grid-template-columns: auto 1fr; }
  .event-arrow { display: none; }
  .event-date { min-width: 84px; padding: 12px 22px 12px 12px; }
  .event-day { font-size: 2rem; }
  .event-title { font-size: 1.3rem; }
  .event-body { padding: 14px 16px; }
}
@media (prefers-reduced-motion: reduce) { .event-card-link:hover { transform: none; } }

/* Detail layout (event) */
.detail-grid { display: grid; gap: 40px; }
@media (min-width: 900px) { .detail-grid { grid-template-columns: 1.6fr 1fr; gap: 56px; align-items: start; } }
.detail-image { width: 100%; border-bottom: 4px solid var(--red); margin-bottom: 2rem; }
.detail-side { display: grid; gap: 12px; position: sticky; top: 92px; }
@media (max-width: 899px) { .detail-side { position: static; } }
.facts { margin: 0 0 8px; background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--red); }
.facts div { padding: 14px 20px; border-bottom: 1px solid var(--border); }
.facts div:last-child { border-bottom: 0; }
.facts dt { font: italic 800 .8rem/1 var(--font-display); text-transform: uppercase; letter-spacing: .12em; color: var(--red-hot); margin-bottom: 6px; }
.facts dd { margin: 0; font-weight: 500; }
.btn-block { width: 100%; }
.prose p { max-width: 68ch; }
.results { margin-top: 2.5rem; padding-top: 2rem; border-top: 1px solid var(--border); }

/* Team page */
.member-grid {
  list-style: none; padding: 0; margin: 2rem 0 0;
  display: grid; gap: 24px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.member { background: var(--surface); border: 1px solid var(--border); }
.member-photo { border-bottom: 4px solid var(--red); }
.member-photo img, .member-photo .ph-box { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.member-body { padding: 20px; }
.member-role { font: italic 800 .85rem/1 var(--font-display); text-transform: uppercase; letter-spacing: .12em; color: var(--red-hot); margin-bottom: .5rem; }
.member-name { font: italic 900 1.9rem/1 var(--font-display); text-transform: uppercase; margin: 0 0 .75rem; }
.member-body .muted { font-size: .95rem; }

.section-cars { background: var(--surface); }
.car { display: grid; gap: 32px; align-items: center; margin-top: 2.5rem; }
.car + .car { padding-top: 2.5rem; border-top: 1px solid var(--border); }
@media (min-width: 900px) {
  .car { grid-template-columns: 1.1fr 1fr; gap: 56px; }
  .car:nth-of-type(even) .car-photo { order: 2; }
}
.car-photo.framed { width: 100%; }
.car-photo img, .car-photo .ph-box { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.specs { margin: 1.25rem 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); }
.specs div { background: var(--bg); padding: 12px 16px; }
.specs dt { font: italic 800 .78rem/1 var(--font-display); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin-bottom: 4px; }
.specs dd { margin: 0; font-weight: 600; }

/* Sponsors */
.section-sponsors { border-top: 1px solid var(--border); }
.sponsor-grid {
  list-style: none; padding: 0; margin: 2rem 0 0;
  display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}
.sponsor { background: var(--surface); border: 1px solid var(--border); aspect-ratio: 3 / 2; display: flex; }
.sponsor a { display: flex; flex: 1; }
.sponsor img { margin: auto; max-width: 75%; max-height: 60%; object-fit: contain; filter: grayscale(1) brightness(1.6); opacity: .85; transition: filter .2s, opacity .2s; }
.sponsor:hover img { filter: none; opacity: 1; }
@media (min-width: 560px) { .sponsor-title { grid-column: span 2; aspect-ratio: auto; } }

/* Gallery */
.album-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin-top: 1rem; }
.album-card { display: block; text-decoration: none; background: var(--surface); border: 1px solid var(--border); transition: border-color .15s; }
.album-card:hover { border-color: var(--red); }
.album-cover { overflow: hidden; border-bottom: 3px solid var(--red); }
.album-cover img, .album-cover .ph-box { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; transition: transform .4s var(--ease); }
.album-card:hover .album-cover img { transform: scale(1.04); }
.album-body { padding: 16px 18px; }
.album-title { font: italic 900 1.5rem/1 var(--font-display); text-transform: uppercase; margin: 0 0 .4rem; }
.album-body .muted { margin: 0; font-size: .9rem; }

.photo-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
@media (max-width: 559px) { .photo-grid { grid-template-columns: repeat(2, 1fr); gap: 4px; } }
.photo { display: block; overflow: hidden; background: var(--surface); }
.photo img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .3s var(--ease), opacity .2s; }
.photo:hover img { transform: scale(1.04); opacity: .9; }

.lightbox { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(7,7,8,.96); color: #fff; }
.lightbox::backdrop { background: rgba(0,0,0,.6); }
.lightbox[open] { display: flex; align-items: center; justify-content: center; }
.lightbox figure { margin: 0; max-width: 92vw; text-align: center; }
.lightbox img { max-width: 92vw; max-height: 80dvh; margin: 0 auto; object-fit: contain; }
.lightbox figcaption { margin-top: 12px; color: #d4d4d4; }
.lightbox button {
  position: absolute; background: rgba(255,255,255,.08); color: #fff; border: 0; cursor: pointer;
  width: 52px; height: 52px; font-size: 2rem; line-height: 1; display: grid; place-items: center;
}
.lightbox button:hover { background: var(--red); }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 12px; top: 50%; transform: translateY(-50%); }
@media (max-width: 559px) { .lb-prev, .lb-next { top: auto; bottom: 16px; transform: none; } }

/* Shop */
.product-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); margin-top: 1rem; }
@media (max-width: 559px) { .product-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; } }
.product-card { display: block; text-decoration: none; background: var(--surface); border: 1px solid var(--border); transition: border-color .15s; }
.product-card:hover { border-color: var(--red); }
.product-img { position: relative; overflow: hidden; background: #fff; }
.product-img img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .4s var(--ease); }
.product-card:hover .product-img img { transform: scale(1.04); }
.stock-flag { position: absolute; top: 10px; left: 10px; background: var(--bg); color: #fff; font: italic 800 .8rem/1 var(--font-display); text-transform: uppercase; padding: 6px 10px; }
.product-body { padding: 14px 16px 16px; }
.product-cat { font: italic 800 .78rem/1 var(--font-display); text-transform: uppercase; letter-spacing: .12em; color: var(--red-hot); margin-bottom: .4rem; }
.product-name { font: italic 900 1.35rem/1.05 var(--font-display); text-transform: uppercase; margin: 0 0 .4rem; }
.product-price { font-weight: 700; margin: 0; }
.product-price-lg { font: italic 900 2rem/1 var(--font-display); color: var(--fg); margin-bottom: 1.5rem; }
.shop-note { margin: 2rem auto 0; text-align: center; }

.product-detail { display: grid; gap: 40px; }
@media (min-width: 900px) { .product-detail { grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: start; } }
.product-main { width: 100%; aspect-ratio: 1; object-fit: cover; background: #fff; }
.product-thumbs { list-style: none; padding: 0; margin: 10px 0 0; display: flex; gap: 8px; flex-wrap: wrap; }
.product-thumbs button { padding: 0; border: 2px solid transparent; background: #fff; cursor: pointer; width: 72px; height: 72px; }
.product-thumbs button[aria-pressed="true"] { border-color: var(--red); }
.product-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.product-info .title { font-size: clamp(2.25rem, 6vw, 3.5rem); }
.order-form { display: grid; gap: 16px; margin-top: 1.5rem; }
.order-form .btn { justify-self: start; border: 0; cursor: pointer; }
.sizes { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.sizes legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.size { position: relative; }
.size input { position: absolute; opacity: 0; inset: 0; }
.size span {
  display: grid; place-items: center; min-width: 52px; height: 48px; padding: 0 14px; cursor: pointer;
  border: 1px solid #3a3a40; background: var(--surface); font-weight: 600;
}
.size input:checked + span { border-color: var(--red); background: var(--red); color: #fff; }
.size input:focus-visible + span { outline: 2px solid var(--red-hot); outline-offset: 2px; }

/* Footer extras */
.footer-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; margin-bottom: 8px; }
.footer-meta .footer-email { margin: 0; }
.social { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.social a { color: var(--muted); text-decoration: none; font-weight: 600; }
.social a:hover { color: var(--red-hot); }

/* Comfortable tap targets on touch screens (44px minimum). */
.link-arrow { min-height: 44px; }
.footer-nav a, .social a { display: inline-flex; align-items: center; min-height: 44px; }
.footer-email { min-height: 44px; display: inline-flex; align-items: center; }
.breadcrumbs a { display: inline-block; padding: 10px 0; }
@media (max-width: 767px) {
  .footer-nav { gap: 0 24px; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 16px; }
}
@media (max-width: 559px) {
  .member-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .member-body { padding: 12px; }
  .member-name { font-size: 1.3rem; margin-bottom: .4rem; }
  .member-role { font-size: .72rem; }
  .member-body .muted { font-size: .85rem; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
  .album-grid { grid-template-columns: 1fr; }
}

/* Album videos */
.video-grid { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.video-grid video { width: 100%; aspect-ratio: 9 / 16; max-height: 70vh; object-fit: cover; background: #000; border-bottom: 4px solid var(--red); }


/* ---------- Empty image slots ----------
   Visitors see the brand fallback only; the "Hero image" style labels that say
   what to upload are shown just to signed-in staff. */
.ph-label { display: none; }
.is-staff .ph-label { display: block; }
.ph-box { isolation: isolate; overflow: hidden; }
.ph-box::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: url("../img/logo-md.d8296f1db176.webp") center / 46% no-repeat;
  opacity: .12; filter: grayscale(.3);
}

/* ---------- 404 page ---------- */
.error-hero { min-height: 70vh; display: flex; align-items: center; }
.error-hero .title { font-size: clamp(3rem, 12vw, 7rem); }
.error-links { display: flex; flex-wrap: wrap; gap: 4px 22px; margin-top: 2rem; }
.error-links a { color: var(--muted); text-decoration: none; font-weight: 600; min-height: 44px; display: inline-flex; align-items: center; }
.error-links a:hover { color: var(--red-hot); }
