/**
 * pages.css — AutoPerf Store
 * Styles spécifiques aux templates : boutique, produit, article, page, 404, trackday.
 */

/* ============================================================
   CARTE PRODUIT — content-product.php
   Utilisée dans la boutique, best-sellers, produits liés.
   ============================================================ */

/* Container carte */
.ap-card-product {
  display: flex;
  flex-direction: column;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: var(--ap-r-xl);
  overflow: hidden;
  position: relative;
  transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}
.ap-card-product:hover {
  border-color: rgba(239,68,68,0.4);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.35), 0 0 0 1px rgba(239,68,68,0.15);
}

/* Zone image */
.ap-card-product__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: var(--ap-bg-deep);
}
.ap-card-product__img-link {
  display: block;
  width: 100%;
  height: 100%;
}
.ap-card-product__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.45s ease, opacity 0.35s ease;
}
.ap-card-product__img--hover {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.35s ease;
}
.ap-card-product:hover .ap-card-product__img:not(.ap-card-product__img--hover) {
  transform: scale(1.05);
}
.ap-card-product:hover .ap-card-product__img--hover {
  opacity: 1;
}

/* Badges */
.ap-card-product__badges {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  z-index: 2;
}

/* Actions rapides (wishlist + voir) */
.ap-card-product__actions {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
  opacity: 0;
  transform: translateX(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.ap-card-product:hover .ap-card-product__actions,
.ap-card-product:focus-within .ap-card-product__actions {
  opacity: 1;
  transform: translateX(0);
}
.ap-card-product__action-btn,
.ap-card-product__wishlist a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: rgba(7,11,18,0.75);
  backdrop-filter: blur(8px);
  border: 1px solid var(--ap-border);
  border-radius: 50%;
  color: var(--ap-text-2);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.ap-card-product__action-btn:hover,
.ap-card-product__wishlist a:hover {
  background: var(--ap-red);
  border-color: var(--ap-red);
  color: #fff;
}
/* YITH wishlist override */
.ap-card-product__wishlist .yith-wcwl-add-to-wishlist { margin: 0; }
.ap-card-product__wishlist .add_to_wishlist { padding: 0; font-size: 0; }

/* Corps de carte */
.ap-card-product__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 16px 10px;
}
.ap-card-product__brand {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ap-red);
}
.ap-card-product__title {
  font-family: var(--ap-f-heading);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ap-text-0);
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ap-card-product__title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}
.ap-card-product__title a:hover { color: var(--ap-red); }

/* Étoiles petites */
.ap-stars--sm { gap: 1px; }
.ap-card-product__rating {
  display: flex;
  align-items: center;
  gap: 5px;
}
.ap-card-product__review-count {
  font-size: 0.72rem;
  color: var(--ap-text-3);
}

/* Prix */
.ap-card-product__price { line-height: 1; margin-top: 2px; }
.ap-card-product__price .woocommerce-Price-amount {
  font-family: var(--ap-f-mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--ap-text-0);
}
.ap-card-product__price del .woocommerce-Price-amount {
  font-size: 0.85rem;
  color: var(--ap-text-3);
  text-decoration: line-through;
}
.ap-card-product__price ins {
  text-decoration: none;
}
.ap-card-product__price ins .woocommerce-Price-amount {
  color: var(--ap-red);
}

/* Indicateur stock */
.ap-card-product__stock {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 500;
}
.ap-card-product__stock--in { color: var(--ap-green); }
.ap-card-product__stock--out { color: var(--ap-text-3); }

/* Footer — bouton ATC */
.ap-card-product__footer {
  padding: 10px 12px 14px;
}
.ap-card-product__atc {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 10px 14px;
  min-height: 44px;
  background: var(--ap-red);
  color: #fff;
  border: none;
  border-radius: var(--ap-r-md);
  font-family: var(--ap-f-heading);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, transform 0.15s;
  position: relative;
  overflow: hidden;
}
.ap-card-product__atc:hover {
  background: var(--ap-red-h, #dc2626);
  transform: translateY(-1px);
  color: #fff;
}
.ap-card-product__atc:active { transform: translateY(0); }

/* État chargement AJAX */
.ap-card-product__atc-spinner { display: none; animation: ap-spin 0.7s linear infinite; }
.ap-card-product__atc.loading .ap-card-product__atc-spinner { display: block; }
.ap-card-product__atc.loading svg:not(.ap-card-product__atc-spinner) { opacity: 0.4; }
.ap-card-product__atc.added { background: var(--ap-green); }

@keyframes ap-spin { to { transform: rotate(360deg); } }

/* Variante hors stock */
.ap-card-product__atc--out {
  background: var(--ap-bg-elevated);
  color: var(--ap-text-3);
  border: 1px solid var(--ap-border);
  cursor: default;
}
.ap-card-product__atc--out:hover {
  background: var(--ap-bg-elevated);
  color: var(--ap-text-2);
  transform: none;
}

/* Variante produit variable */
.ap-card-product__atc--options {
  background: transparent;
  color: var(--ap-text-1);
  border: 1px solid var(--ap-border);
}
.ap-card-product__atc--options:hover {
  border-color: var(--ap-red);
  color: var(--ap-red);
  background: transparent;
}

/* Grille WooCommerce */
ul.products {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
  list-style: none;
  margin: 0 !important;
  padding: 0 !important;
}
ul.products li.product { margin: 0 !important; }

/* ============================================================
   PROSE — contenu éditorial riche (page.php, single.php, tabs)
   ============================================================ */
.ap-prose {
  color: var(--ap-text-1);
  line-height: 1.75;
  font-size: 1rem;
}
.ap-prose h2,
.ap-prose h3,
.ap-prose h4 {
  font-family: var(--ap-f-heading);
  font-weight: 600;
  color: var(--ap-text-0);
  margin: 2rem 0 0.75rem;
}
.ap-prose h2 { font-size: clamp(1.35rem, 3vw, 1.75rem); }
.ap-prose h3 { font-size: clamp(1.1rem, 2.5vw, 1.35rem); }
.ap-prose p  { margin-bottom: 1rem; }
.ap-prose ul,
.ap-prose ol  { margin: 0 0 1rem 1.5rem; }
.ap-prose li  { margin-bottom: 0.35rem; }
.ap-prose a   { color: var(--ap-red); text-decoration: underline; text-underline-offset: 3px; }
.ap-prose a:hover { color: var(--ap-red-h); }
.ap-prose strong { color: var(--ap-text-0); font-weight: 600; }
.ap-prose blockquote {
  border-left: 3px solid var(--ap-red);
  padding: 0.75rem 1.25rem;
  margin: 1.5rem 0;
  background: var(--ap-bg-surface);
  border-radius: 0 var(--ap-r-md) var(--ap-r-md) 0;
  color: var(--ap-text-2);
}
.ap-prose code {
  font-family: var(--ap-f-mono);
  font-size: 0.875em;
  background: var(--ap-bg-elevated);
  padding: 0.1em 0.4em;
  border-radius: 4px;
  color: var(--ap-green);
}
.ap-prose img {
  max-width: 100%;
  height: auto;
  border-radius: var(--ap-r-lg);
  margin: 1.5rem 0;
}
.ap-prose hr {
  border: none;
  border-top: 1px solid var(--ap-border);
  margin: 2rem 0;
}
.ap-prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}
.ap-prose table th,
.ap-prose table td {
  padding: 10px 14px;
  border: 1px solid var(--ap-border);
  text-align: left;
}
.ap-prose table th {
  background: var(--ap-bg-surface);
  font-weight: 600;
  color: var(--ap-text-0);
}
.ap-prose table tr:nth-child(even) td {
  background: rgba(255,255,255,0.02);
}

/* ============================================================
   PAGE GÉNÉRIQUE (page.php)
   ============================================================ */
.ap-page-hero {
  background: var(--ap-bg-surface);
  border-bottom: 1px solid var(--ap-border);
  padding: 48px 0 40px;
}
.ap-page-hero__inner { display: flex; flex-direction: column; gap: 12px; }
.ap-page-hero__title {
  font-family: var(--ap-f-display);
  font-size: clamp(1.75rem, 5vw, 3rem);
  font-weight: 700;
  color: var(--ap-text-0);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.1;
}
.ap-page-layout {
  max-width: 800px;
  margin: 0 auto;
  padding: 48px 0 80px;
}
.ap-page-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--ap-border);
  font-size: 0.875rem;
}

/* ============================================================
   BOUTIQUE / ARCHIVES PRODUITS (archive-product.php)
   ============================================================ */

/* Hero catégorie */
.ap-shop-hero {
  position: relative;
  min-height: 260px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
.ap-shop-hero__img {
  position: absolute;
  inset: 0;
}
.ap-shop-hero__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ap-shop-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(7,11,18,0.92) 0%, rgba(7,11,18,0.5) 60%, rgba(7,11,18,0.3) 100%);
}
.ap-shop-hero__placeholder {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--ap-bg-surface) 0%, var(--ap-bg-deep) 100%);
}
.ap-shop-hero__content {
  position: relative;
  z-index: 1;
  padding: 40px 0 36px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.ap-shop-hero__title {
  font-family: var(--ap-f-display);
  font-size: clamp(1.75rem, 5vw, 3rem);
  font-weight: 700;
  color: var(--ap-text-0);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.1;
}
.ap-shop-hero__desc {
  color: var(--ap-text-2);
  font-size: 1rem;
  max-width: 640px;
  margin: 0;
}
.ap-shop-title {
  font-family: var(--ap-f-display);
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--ap-text-0);
  margin: 0 0 8px;
}
.ap-shop-title span { color: var(--ap-red); }

/* Layout 2 colonnes */
.ap-shop-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 40px;
  padding: 40px 0 80px;
  align-items: start;
}

/* Sidebar filtres */
.ap-shop-sidebar {
  position: sticky;
  top: calc(var(--ap-header-h, 72px) + 16px);
  display: flex;
  flex-direction: column;
  gap: 0;
}
.ap-sidebar-header {
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--ap-border);
}
.ap-sidebar-header__title {
  font-family: var(--ap-f-heading);
  font-weight: 600;
  font-size: 1rem;
  color: var(--ap-text-0);
}
.ap-sidebar-close {
  background: none;
  border: none;
  color: var(--ap-text-2);
  cursor: pointer;
  padding: 4px;
  transition: color 0.2s;
}
.ap-sidebar-close:hover { color: var(--ap-red); }

.ap-filter-reset {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: var(--ap-text-3);
  text-decoration: none;
  padding: 8px 16px;
  transition: color 0.2s;
  border-bottom: 1px solid var(--ap-border);
}
.ap-filter-reset:hover { color: var(--ap-red); }

.ap-filter-block {
  padding: 16px;
  border-bottom: 1px solid var(--ap-border);
  background: var(--ap-bg-surface);
}
.ap-filter-block:first-child { border-radius: var(--ap-r-lg) var(--ap-r-lg) 0 0; }
.ap-filter-block:last-child  { border-radius: 0 0 var(--ap-r-lg) var(--ap-r-lg); border-bottom: none; }
.ap-filter-title {
  font-family: var(--ap-f-heading);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ap-text-3);
  margin: 0 0 10px;
}

/* Listes de catégories WP */
.ap-filter-block ul,
.ap-shop-sidebar .product-categories {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.ap-filter-block ul li a,
.ap-shop-sidebar .product-categories li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 0;
  font-size: 0.875rem;
  color: var(--ap-text-2);
  text-decoration: none;
  transition: color 0.2s;
}
.ap-filter-block ul li a:hover,
.ap-shop-sidebar .product-categories li.current-cat a { color: var(--ap-red); }
.ap-filter-block .count,
.ap-shop-sidebar .count {
  font-size: 0.75rem;
  color: var(--ap-text-3);
  background: var(--ap-bg-elevated);
  padding: 1px 6px;
  border-radius: 999px;
}

/* Sous-catégories */
.ap-subcat-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.ap-subcat-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 0.875rem;
  color: var(--ap-text-2);
  text-decoration: none;
  transition: color 0.2s;
}
.ap-subcat-link:hover,
.ap-subcat-link.active { color: var(--ap-red); }
.ap-subcat-count {
  font-size: 0.75rem;
  color: var(--ap-text-3);
  background: var(--ap-bg-elevated);
  padding: 1px 6px;
  border-radius: 999px;
}

/* Toolbar */
.ap-shop-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 0 20px;
  border-bottom: 1px solid var(--ap-border);
  margin-bottom: 28px;
}
.ap-shop-toolbar__right { display: flex; align-items: center; gap: 10px; }
.woocommerce-result-count {
  font-size: 0.875rem;
  color: var(--ap-text-3);
  margin: 0;
}
.woocommerce-ordering select {
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  color: var(--ap-text-1);
  padding: 7px 32px 7px 12px;
  border-radius: var(--ap-r-md);
  font-size: 0.875rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2'%3E%3Cpath d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}
.woocommerce-ordering select:focus { outline: 2px solid var(--ap-red); outline-offset: 2px; }

.ap-filter-toggle {
  display: none;
  align-items: center;
  gap: 6px;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  color: var(--ap-text-1);
  padding: 8px 14px;
  border-radius: var(--ap-r-md);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.ap-filter-toggle:hover { border-color: var(--ap-red); color: var(--ap-red); }
.ap-filter-toggle[aria-expanded="true"] { border-color: var(--ap-red); color: var(--ap-red); }

/* État vide */
.ap-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px;
  gap: 16px;
  color: var(--ap-text-2);
}

/* Texte SEO catégorie */
.ap-cat-seo-text { margin-top: 56px; }
.ap-divider {
  height: 1px;
  background: var(--ap-border);
  margin-bottom: 32px;
}
.ap-cat-seo-text__content { color: var(--ap-text-3); font-size: 0.9rem; max-width: 760px; }

/* FAQ accordéon (boutique + produit) */
.ap-faq { margin-top: 48px; }
.ap-faq__title {
  font-family: var(--ap-f-heading);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--ap-text-0);
  margin-bottom: 20px;
}
.ap-faq__list { display: flex; flex-direction: column; }
.ap-faq__item { border-bottom: 1px solid var(--ap-border); }
.ap-faq__question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  background: none;
  border: none;
  padding: 18px 0;
  text-align: left;
  font-family: var(--ap-f-heading);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ap-text-1);
  cursor: pointer;
  transition: color 0.2s;
}
.ap-faq__question:hover { color: var(--ap-text-0); }
.ap-faq__icon { flex-shrink: 0; transition: transform 0.25s ease; color: var(--ap-text-3); }
.ap-faq__answer { overflow: hidden; }
.ap-faq__answer-inner {
  padding: 0 0 18px;
  color: var(--ap-text-2);
  font-size: 0.9rem;
  line-height: 1.7;
}

/* ============================================================
   PAGE PRODUIT (single-product.php)
   ============================================================ */
.ap-product-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
  padding: 32px 0 60px;
}
.ap-product-gallery-col { position: sticky; top: calc(var(--ap-header-h, 72px) + 20px); }
.ap-product-gallery-wrap {
  border-radius: var(--ap-r-xl);
  overflow: hidden;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
}
.ap-product-badges--mobile { display: none; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

/* Résumé produit */
.ap-product-summary { display: flex; flex-direction: column; gap: 20px; }
.ap-product-header { display: flex; flex-direction: column; gap: 8px; }
.ap-product-brand a {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ap-red);
  text-decoration: none;
}
.ap-product-brand a:hover { color: var(--ap-red-h); }
.ap-product-title {
  font-family: var(--ap-f-heading);
  font-size: clamp(1.35rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--ap-text-0);
  line-height: 1.2;
  margin: 0;
}

/* Notation */
.ap-product-rating {
  display: flex;
  align-items: center;
  gap: 10px;
}
.ap-stars { display: flex; gap: 2px; }
.ap-product-rating__count {
  font-size: 0.875rem;
  color: var(--ap-text-3);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: transparent;
  transition: text-decoration-color 0.2s, color 0.2s;
}
.ap-product-rating__count:hover { color: var(--ap-text-1); text-decoration-color: currentColor; }
.ap-product-rating__empty { font-size: 0.875rem; color: var(--ap-text-3); text-decoration: none; }

/* Prix */
.ap-product-price {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}
.ap-product-price .woocommerce-Price-amount {
  font-family: var(--ap-f-mono);
  font-size: 2rem;
  font-weight: 700;
  color: var(--ap-text-0);
}
.ap-product-price del .woocommerce-Price-amount {
  font-size: 1.25rem;
  color: var(--ap-text-3);
  text-decoration: line-through;
}
.ap-product-price ins {
  text-decoration: none;
}
.ap-product-price ins .woocommerce-Price-amount {
  color: var(--ap-red);
}
.ap-product-price__vat {
  font-size: 0.75rem;
  color: var(--ap-text-3);
  align-self: flex-end;
  padding-bottom: 4px;
}

/* Disponibilité */
.ap-product-availability { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.ap-availability {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 999px;
}
.ap-availability--in {
  color: var(--ap-green);
  background: rgba(16,185,129,0.08);
  border: 1px solid rgba(16,185,129,0.2);
}
.ap-availability--out {
  color: var(--ap-amber, #F59E0B);
  background: rgba(245,158,11,0.08);
  border: 1px solid rgba(245,158,11,0.2);
}
.ap-product-sku { font-size: 0.8rem; color: var(--ap-text-3); }

/* Description courte */
.ap-product-short-desc { color: var(--ap-text-2); font-size: 0.95rem; line-height: 1.7; }
.ap-product-short-desc p { margin: 0; }

/* Compatibilité */
.ap-product-compat {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: rgba(16,185,129,0.06);
  border: 1px solid rgba(16,185,129,0.15);
  border-radius: var(--ap-r-md);
  padding: 10px 14px;
  font-size: 0.875rem;
  color: var(--ap-text-2);
}
.ap-product-compat__label {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--ap-green);
  font-weight: 600;
  flex-shrink: 0;
}

/* Actions wishlist/compare */
.ap-product-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Réassurance produit */
.ap-product-reassurance {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 16px;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: var(--ap-r-lg);
}
.ap-product-reassurance__item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.8rem;
}
.ap-product-reassurance__item svg { color: var(--ap-red); flex-shrink: 0; margin-top: 1px; }
.ap-product-reassurance__item div { display: flex; flex-direction: column; gap: 2px; }
.ap-product-reassurance__item strong { color: var(--ap-text-0); font-weight: 600; }
.ap-product-reassurance__item span { color: var(--ap-text-3); }

/* Meta WooCommerce */
.ap-product-meta { font-size: 0.8rem; color: var(--ap-text-3); }
.ap-product-meta .tagged_as a,
.ap-product-meta .posted_in a {
  color: var(--ap-text-2);
  text-decoration: none;
}
.ap-product-meta .tagged_as a:hover,
.ap-product-meta .posted_in a:hover { color: var(--ap-red); }

/* Onglets produit */
.ap-product-tabs-section {
  border-top: 1px solid var(--ap-border);
  margin: 40px 0;
  padding-top: 0;
}
.ap-product-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--ap-border);
  overflow-x: auto;
  scrollbar-width: none;
}
.ap-product-tabs::-webkit-scrollbar { display: none; }
.ap-product-tabs__btn {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  padding: 16px 20px;
  font-family: var(--ap-f-heading);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ap-text-3);
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s, border-color 0.2s;
}
.ap-product-tabs__btn:hover { color: var(--ap-text-1); }
.ap-product-tabs__btn.active {
  color: var(--ap-text-0);
  border-bottom-color: var(--ap-red);
}
.ap-product-panel {
  padding: 32px 0;
  display: none;
}
.ap-product-panel.active { display: block; }
.ap-product-panel__content { color: var(--ap-text-1); line-height: 1.75; }

/* Tableau spécifications */
.ap-specs-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.ap-specs-table th,
.ap-specs-table td {
  padding: 12px 16px;
  border: 1px solid var(--ap-border);
  text-align: left;
}
.ap-specs-table th {
  background: var(--ap-bg-surface);
  font-weight: 600;
  color: var(--ap-text-0);
  width: 40%;
}
.ap-specs-table td { color: var(--ap-text-2); }
.ap-specs-table tr:nth-child(even) td { background: rgba(255,255,255,0.02); }

/* Compatibilité */
.ap-compat-intro {
  color: var(--ap-text-2);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
}
.ap-compat-list { color: var(--ap-text-2); margin-bottom: 20px; line-height: 1.8; }
.ap-compat-note {
  font-size: 0.85rem;
  color: var(--ap-text-3);
  border-top: 1px solid var(--ap-border);
  padding-top: 16px;
}
.ap-compat-note a { color: var(--ap-red); }

/* ============================================================
   ARTICLE DE BLOG (single.php)
   ============================================================ */
.ap-article-hero {
  background: var(--ap-bg-surface);
  border-bottom: 1px solid var(--ap-border);
  padding: 48px 0 40px;
}
.ap-article-hero__inner { display: flex; flex-direction: column; gap: 12px; }
.ap-article-cat {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ap-red);
  text-decoration: none;
}
.ap-article-title {
  font-family: var(--ap-f-heading);
  font-size: clamp(1.6rem, 5vw, 2.75rem);
  font-weight: 700;
  color: var(--ap-text-0);
  line-height: 1.15;
  max-width: 760px;
}
.ap-article-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 0.875rem;
  color: var(--ap-text-3);
}
.ap-article-meta__item { display: inline-flex; align-items: center; gap: 5px; }
.ap-article-meta__sep { opacity: 0.4; }

/* Image à la une */
.ap-article-featured-img {
  background: var(--ap-bg-deep);
  padding: 0;
  overflow: hidden;
}
.ap-article-featured-img img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
  display: block;
}

/* Layout article 2 colonnes */
.ap-article-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 56px;
  padding: 56px 0 80px;
  align-items: start;
}
.ap-article-content { min-width: 0; }

/* Tags */
.ap-article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--ap-border);
}
.ap-article-tags a {
  display: inline-block;
  padding: 4px 12px;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: 999px;
  font-size: 0.8rem;
  color: var(--ap-text-2);
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s;
}
.ap-article-tags a:hover { border-color: var(--ap-red); color: var(--ap-red); }

/* Navigation précédent/suivant */
.ap-article-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--ap-border);
}
.ap-article-nav__link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: var(--ap-r-lg);
  text-decoration: none;
  transition: border-color 0.2s;
}
.ap-article-nav__link:hover { border-color: var(--ap-red); }
.ap-article-nav__link--next { text-align: right; }
.ap-article-nav__dir { font-size: 0.75rem; color: var(--ap-text-3); text-transform: uppercase; letter-spacing: 0.05em; }
.ap-article-nav__title { font-size: 0.9rem; font-weight: 600; color: var(--ap-text-1); line-height: 1.4; }

/* Sidebar article */
.ap-article-sidebar {
  position: sticky;
  top: calc(var(--ap-header-h, 72px) + 20px);
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.ap-sidebar-block {
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: var(--ap-r-lg);
  overflow: hidden;
}
.ap-sidebar-block__title {
  font-family: var(--ap-f-heading);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ap-text-3);
  padding: 14px 16px;
  border-bottom: 1px solid var(--ap-border);
  margin: 0;
}
.ap-sidebar-product {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  text-decoration: none;
  border-bottom: 1px solid var(--ap-border);
  transition: background 0.15s;
}
.ap-sidebar-product:last-child { border-bottom: none; }
.ap-sidebar-product:hover { background: var(--ap-bg-elevated); }
.ap-sidebar-product img { width: 60px; height: 60px; object-fit: cover; border-radius: var(--ap-r-md); flex-shrink: 0; }
.ap-sidebar-product__name { font-size: 0.8rem; color: var(--ap-text-1); line-height: 1.3; margin: 0; }
.ap-sidebar-product__price { font-size: 0.8rem; color: var(--ap-red); font-family: var(--ap-f-mono); margin: 3px 0 0; }
.ap-sidebar-post {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 12px 16px;
  text-decoration: none;
  border-bottom: 1px solid var(--ap-border);
  transition: background 0.15s;
}
.ap-sidebar-post:last-child { border-bottom: none; }
.ap-sidebar-post:hover { background: var(--ap-bg-elevated); }
.ap-sidebar-post span:first-child { font-size: 0.875rem; color: var(--ap-text-1); line-height: 1.4; }
.ap-sidebar-post__date { font-size: 0.75rem; color: var(--ap-text-3); }
.ap-sidebar-cta {
  background: linear-gradient(135deg, var(--ap-bg-surface) 0%, rgba(239,68,68,0.06) 100%);
  border: 1px solid rgba(239,68,68,0.15);
  border-radius: var(--ap-r-lg);
  padding: 20px 16px;
  font-size: 0.875rem;
  color: var(--ap-text-2);
  line-height: 1.6;
}

/* ============================================================
   PAGE 404
   ============================================================ */
.ap-404 {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px;
  gap: 40px;
}
.ap-404__visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}
.ap-404__number {
  font-family: var(--ap-f-display);
  font-size: clamp(80px, 20vw, 160px);
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1;
  background: linear-gradient(135deg, var(--ap-text-0) 0%, var(--ap-red) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-transform: uppercase;
}
.ap-404__line {
  width: 80px;
  height: 3px;
  background: var(--ap-red);
  border-radius: 2px;
}
.ap-404__content { display: flex; flex-direction: column; align-items: center; gap: 20px; max-width: 560px; }
.ap-404__title {
  font-family: var(--ap-f-heading);
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  font-weight: 700;
  color: var(--ap-text-0);
  margin: 0;
}
.ap-404__text { color: var(--ap-text-2); font-size: 1rem; line-height: 1.6; margin: 0; }
.ap-404__search {
  display: flex;
  gap: 8px;
  width: 100%;
  max-width: 440px;
}
.ap-404__search input[type="search"] {
  flex: 1;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  color: var(--ap-text-1);
  padding: 11px 16px;
  border-radius: var(--ap-r-md);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s;
}
.ap-404__search input[type="search"]:focus { border-color: var(--ap-red); }
.ap-404__actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.ap-404__cats { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.ap-404__cats-title { font-size: 0.8rem; color: var(--ap-text-3); text-transform: uppercase; letter-spacing: 0.08em; }
.ap-404__cats-grid { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.ap-404__cat-link {
  display: inline-block;
  padding: 7px 16px;
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: 999px;
  font-size: 0.85rem;
  color: var(--ap-text-2);
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s;
}
.ap-404__cat-link:hover { border-color: var(--ap-red); color: var(--ap-red); }

/* ============================================================
   PAGE TRACKDAY (page-trackday.php)
   ============================================================ */

/* Hero */
.ap-td-hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.ap-td-hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ap-td-hero__fallback {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 40% 50%, rgba(239,68,68,0.15) 0%, transparent 70%),
              linear-gradient(135deg, #0d1117 0%, #1a0a0a 100%);
}
.ap-td-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom,
    rgba(7,11,18,0.35) 0%,
    rgba(7,11,18,0.55) 40%,
    rgba(7,11,18,0.92) 100%);
}
.ap-td-hero__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  padding: 100px 0 80px;
  max-width: 720px;
}
.ap-td-hero__title {
  font-family: var(--ap-f-display);
  font-size: clamp(3rem, 10vw, 7rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.9;
  color: var(--ap-text-0);
}
.ap-td-hero__title span { color: var(--ap-red); }
.ap-td-hero__sub { color: var(--ap-text-2); font-size: clamp(1rem, 2vw, 1.2rem); max-width: 560px; line-height: 1.6; }
.ap-td-hero__info { display: flex; flex-wrap: wrap; gap: 12px; }
.ap-td-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  border-radius: var(--ap-r-md);
  font-size: 0.875rem;
  color: var(--ap-text-1);
}
.ap-td-hero__badge strong { color: var(--ap-text-0); }
.ap-td-hero__badge--urgent { border-color: rgba(239,68,68,0.4); }
.ap-td-hero__ctas { display: flex; gap: 12px; flex-wrap: wrap; }

/* Stats trackday */
.ap-td-stats { background: var(--ap-bg-surface); border-top: 1px solid var(--ap-border); }
.ap-td-stats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}
.ap-td-stats__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 24px;
  border-right: 1px solid var(--ap-border);
}
.ap-td-stats__item:last-child { border-right: none; }
.ap-td-stats__item .ap-stat__number {
  font-family: var(--ap-f-mono);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--ap-red);
  line-height: 1;
}
.ap-td-stats__label {
  font-size: 0.8rem;
  color: var(--ap-text-3);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 6px;
}

/* Avantages Trackday */
.ap-td-why__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.ap-td-card {
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: var(--ap-r-xl);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.2s, transform 0.2s;
}
.ap-td-card:hover { border-color: rgba(239,68,68,0.35); transform: translateY(-3px); }
.ap-td-card__icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.15);
  border-radius: var(--ap-r-lg);
  color: var(--ap-red);
}
.ap-td-card h3 {
  font-family: var(--ap-f-heading);
  font-size: 1rem;
  font-weight: 600;
  color: var(--ap-text-0);
  margin: 0;
}
.ap-td-card p {
  font-size: 0.875rem;
  color: var(--ap-text-3);
  line-height: 1.6;
  margin: 0;
}

/* Timeline programme */
.ap-td-program { background: var(--ap-bg-surface); border-top: 1px solid var(--ap-border); }
.ap-td-timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding-left: 120px;
}
.ap-td-timeline::before {
  content: '';
  position: absolute;
  left: 100px;
  top: 24px;
  bottom: 24px;
  width: 2px;
  background: linear-gradient(to bottom, var(--ap-red), rgba(239,68,68,0.1));
}
.ap-td-timeline__item {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  padding: 24px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.ap-td-timeline__item:last-child { border-bottom: none; }
.ap-td-timeline__time {
  position: absolute;
  left: -120px;
  top: 26px;
  font-family: var(--ap-f-mono);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ap-red);
  white-space: nowrap;
  width: 90px;
  text-align: right;
}
.ap-td-timeline__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--ap-red);
  box-shadow: 0 0 0 3px rgba(239,68,68,0.2);
  flex-shrink: 0;
  margin-top: 6px;
  position: absolute;
  left: -26px;
  top: 26px;
}
.ap-td-timeline__content { display: flex; flex-direction: column; gap: 4px; }
.ap-td-timeline__title {
  font-family: var(--ap-f-heading);
  font-size: 1rem;
  font-weight: 600;
  color: var(--ap-text-0);
  margin: 0;
}
.ap-td-timeline__desc { font-size: 0.875rem; color: var(--ap-text-3); line-height: 1.6; margin: 0; }

/* Galerie trackday */
.ap-td-gallery__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.ap-td-gallery__item {
  overflow: hidden;
  border-radius: var(--ap-r-lg);
  aspect-ratio: 4/3;
  background: var(--ap-bg-surface);
}
.ap-td-gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
  display: block;
}
.ap-td-gallery__item:hover img { transform: scale(1.05); }

/* Tarifs */
.ap-td-pricing__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: start;
}
.ap-pricing-card {
  background: var(--ap-bg-surface);
  border: 1px solid var(--ap-border);
  border-radius: var(--ap-r-xl);
  padding: 28px 24px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 20px;
  transition: border-color 0.2s;
}
.ap-pricing-card:hover { border-color: rgba(239,68,68,0.3); }
.ap-pricing-card--featured {
  border-color: rgba(239,68,68,0.4);
  background: linear-gradient(135deg, var(--ap-bg-surface) 0%, rgba(239,68,68,0.04) 100%);
}
.ap-pricing-card__badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ap-red);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 3px 12px;
  border-radius: 999px;
  white-space: nowrap;
}
.ap-pricing-card__header { display: flex; flex-direction: column; gap: 8px; }
.ap-pricing-card__name {
  font-family: var(--ap-f-heading);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ap-text-3);
}
.ap-pricing-card__price {
  font-size: 0.875rem;
  color: var(--ap-text-3);
  line-height: 1.3;
}
.ap-pricing-card__price strong {
  font-family: var(--ap-f-mono);
  font-size: 2rem;
  font-weight: 700;
  color: var(--ap-text-0);
  display: block;
}
.ap-pricing-card__features {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.875rem;
  color: var(--ap-text-2);
  flex: 1;
}
.ap-pricing-card__features li { line-height: 1.4; }
.ap-td-pricing__note {
  text-align: center;
  margin-top: 24px;
  font-size: 0.875rem;
  color: var(--ap-text-3);
}
.ap-td-pricing__note a { color: var(--ap-red); }

/* Formulaire Trackday */
.ap-td-form {
  background: var(--ap-bg-surface);
  border-top: 1px solid var(--ap-border);
}
.ap-td-form__wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}
.ap-td-form__info { display: flex; flex-direction: column; gap: 16px; }
.ap-td-form__date,
.ap-td-form__circuit {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--ap-text-2);
  margin: 0;
}
.ap-td-form__date svg,
.ap-td-form__circuit svg { color: var(--ap-red); flex-shrink: 0; }
.ap-td-urgency {
  display: inline-flex;
  padding: 10px 16px;
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: var(--ap-r-md);
  font-size: 0.875rem;
  color: var(--ap-text-2);
}
.ap-td-urgency strong { color: var(--ap-red); }

/* Formulaire natif */
.ap-td-native-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.ap-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.ap-form-group { display: flex; flex-direction: column; gap: 6px; }
.ap-form-group label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--ap-text-2);
}
.ap-form-group label span { color: var(--ap-red); }
.ap-form-group input,
.ap-form-group select,
.ap-form-group textarea {
  background: var(--ap-bg-elevated);
  border: 1px solid var(--ap-border);
  color: var(--ap-text-1);
  padding: 11px 14px;
  border-radius: var(--ap-r-md);
  font-family: var(--ap-f-body);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
  box-sizing: border-box;
}
.ap-form-group input:focus,
.ap-form-group select:focus,
.ap-form-group textarea:focus { border-color: var(--ap-red); }
.ap-form-group textarea { resize: vertical; min-height: 90px; }
.ap-form-group--check { flex-direction: row; align-items: flex-start; gap: 10px; }
.ap-checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.825rem;
  color: var(--ap-text-3);
  cursor: pointer;
  line-height: 1.5;
}
.ap-checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 2px;
  accent-color: var(--ap-red);
  cursor: pointer;
}
.ap-checkbox-label a { color: var(--ap-red); }

/* FAQ Trackday */
.ap-td-faq { border-top: 1px solid var(--ap-border); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .ap-td-timeline { padding-left: 100px; }
  .ap-td-timeline::before { left: 80px; }
  .ap-td-timeline__time { left: -100px; width: 72px; }
  .ap-td-timeline__dot { left: -22px; }
  .ap-td-stats__grid { grid-template-columns: repeat(2, 1fr); }
  .ap-td-stats__item:nth-child(2) { border-right: none; }
  .ap-td-why__grid { grid-template-columns: repeat(2, 1fr); }
  .ap-td-pricing__grid { grid-template-columns: 1fr 1fr; }
  .ap-td-pricing__grid > :last-child { grid-column: 1 / -1; max-width: 380px; margin: 0 auto; }
}

@media (max-width: 900px) {
  /* Boutique */
  .ap-shop-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .ap-shop-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: min(320px, 85vw);
    background: var(--ap-bg-surface);
    z-index: var(--z-drawer, 400);
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.25,0.46,0.45,0.94);
    border-right: 1px solid var(--ap-border);
    padding-top: 0;
    top: 0;
    border-radius: 0;
  }
  .ap-shop-sidebar.is-open { transform: translateX(0); }
  .ap-sidebar-header { display: flex; }
  .ap-filter-toggle { display: inline-flex; }
  .ap-filter-block:first-child { border-radius: 0; }
  .ap-filter-block:last-child  { border-radius: 0; }

  /* Produit */
  .ap-product-layout {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .ap-product-gallery-col { position: static; }
  .ap-product-badges--mobile { display: flex; }
  .ap-product-reassurance { grid-template-columns: 1fr; }

  /* Article */
  .ap-article-layout { grid-template-columns: 1fr; gap: 40px; }
  .ap-article-sidebar { position: static; }

  /* Trackday */
  .ap-td-form__wrapper { grid-template-columns: 1fr; gap: 40px; }
  .ap-td-gallery__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  /* Blog nav */
  .ap-article-nav { grid-template-columns: 1fr; }

  /* Trackday */
  .ap-td-why__grid { grid-template-columns: 1fr; }
  .ap-td-stats__grid { grid-template-columns: repeat(2, 1fr); }
  .ap-td-hero__title { font-size: clamp(2.5rem, 16vw, 5rem); }
  .ap-td-timeline { padding-left: 24px; }
  .ap-td-timeline::before { left: 10px; }
  .ap-td-timeline__time {
    position: static;
    width: auto;
    text-align: left;
    font-size: 0.8rem;
    margin-bottom: 4px;
  }
  .ap-td-timeline__dot { display: none; }
  .ap-td-timeline__item { grid-template-columns: 1fr; gap: 0; padding: 20px 0; }
  .ap-td-pricing__grid { grid-template-columns: 1fr; }
  .ap-td-pricing__grid > :last-child { max-width: 100%; grid-column: auto; }
  .ap-form-row { grid-template-columns: 1fr; }
  .ap-td-gallery__grid { grid-template-columns: 1fr; }

  /* 404 */
  .ap-404__actions { flex-direction: column; width: 100%; }
  .ap-404__actions .ap-btn { justify-content: center; }
  .ap-404__search { flex-direction: column; }
}
