/* Yoopies FR — thème v0.2 (polish pass) */

/* ============ GENERIC ============ */
.yp-wrap { max-width: var(--screen-wrapper, 1184px); margin: 0 auto; padding: 0 var(--space-4, 16px); }
@media (min-width: 1024px) { .yp-wrap { padding: 0 var(--space-6, 32px); } }

body { font-family: var(--font-body); color: var(--text-body); background: var(--surface-page); }
/* Safety net : empêche un overflow accidentel (bloc trop large, lien nowrap)
   de déclencher un scroll horizontal du body sur mobile — ce qui pousserait
   les tap targets fixes (sticky nav : search + burger) hors du viewport.
   `clip` est préféré à `hidden` (ne crée pas un contexte de scroll qui
   casserait position:sticky dans les descendants). Fallback `hidden` pour
   les vieux browsers. */
html, body { overflow-x: hidden; overflow-x: clip; }
img { max-width: 100%; height: auto; display: block; }
a { transition: color .15s cubic-bezier(0.4,0,0.2,1); }

/* ============ HERO ============ */
.yp-hero { position: relative; }

.yp-hero__topbar {
  background: rgba(255,255,255,0.08);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  padding: 10px 0;
}
.yp-hero__topbar .yp-wrap { position: relative; z-index: 2; }

.yp-business-links {
  list-style: none;
  display: flex;
  gap: var(--space-5, 20px);
  margin: 0; padding: 0;
  font-size: 13px;
  overflow-x: auto;
  scrollbar-width: none;
  justify-content: center;
}
.yp-business-links::-webkit-scrollbar { display: none; }
.yp-business-links a {
  color: rgba(255,255,255,0.8);
  font-weight: 600;
  white-space: nowrap;
  position: relative;
}
.yp-business-links a::before {
  content: "›"; margin-right: 6px; color: var(--color-primary-500);
  font-weight: 700;
}
.yp-business-links a:hover { color: #fff; }

/* Hero main : dégradé deep blue → tertiary-450, wave en bas */
.yp-hero__main {
  position: relative;
  background: linear-gradient(135deg, var(--color-tertiary-500) 0%, #1b5c7e 50%, var(--color-tertiary-450) 100%);
  color: #fff;
  padding: var(--space-6, 32px) 0 var(--space-8, 64px);
  overflow: hidden;
}
/* Décor subtil : cercles flous en bg */
.yp-hero__main::before {
  content: "";
  position: absolute; top: -80px; right: -80px;
  width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(50,191,163,0.18), transparent 70%);
  pointer-events: none;
}
.yp-hero__main::after {
  content: "";
  position: absolute; bottom: 20px; left: -100px;
  width: 280px; height: 280px;
  background: radial-gradient(circle, rgba(250,152,86,0.12), transparent 70%);
  pointer-events: none;
}

.yp-hero__brand {
  text-align: center;
  position: relative; z-index: 2;
  padding: var(--space-6, 32px) 0;
  max-width: 720px; margin: 0 auto;
}
/* .yp-hero__logo-link / .yp-hero__logo : voir home.css — l'ancien hero sombre
 * forçait un logo blanc (filter: brightness(0) invert(1)) ; retiré pour le
 * nouveau hero clair qui utilise le logo bicolore natif. */

.yp-hero__title {
  margin: 0 0 var(--space-3, 12px);
  color: #fff;
  font-size: clamp(40px, 6vw, 68px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
}
.yp-hero__title span {
  color: var(--color-secondary-500);
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0;
}
.yp-hero__tagline {
  margin: 0 auto var(--space-5, 20px);
  max-width: 540px;
  color: rgba(255,255,255,0.85);
  font-size: var(--text-h5, 18px);
  line-height: 1.45;
}
.yp-trust {
  list-style: none; margin: 0; padding: 0;
  display: inline-flex; flex-wrap: wrap; gap: var(--space-4, 16px);
  font-size: 13px; color: rgba(255,255,255,0.75);
  justify-content: center;
}
.yp-check {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--color-primary-500); color: #fff;
  margin-right: 6px; font-size: 11px; font-weight: 700;
}

/* Wave SVG en bas du hero */
.yp-hero__wave {
  position: absolute; left: 0; right: 0; bottom: -1px;
  width: 100%; height: 80px;
  color: var(--surface-page);
  display: block;
}

/* Nav sticky */
.yp-hero__nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.95);
  backdrop-filter: saturate(1.3) blur(8px);
  -webkit-backdrop-filter: saturate(1.3) blur(8px);
  border-bottom: 1px solid var(--color-neutral-200);
  box-shadow: var(--elevation-2);
}
/* .yp-hub-nav : voir home.css — l'ancienne barre top-level a été remplacée
 * par les pills du hero (hero-block.php). */

/* ============ HUBS ============ */
.yp-hub { padding: calc(var(--space-6, 32px) * 2.5) 0; position: relative; }
.yp-hub + .yp-hub { border-top: 1px solid var(--color-neutral-200); }
/* Alterner le fond pour aérer */
.yp-hub:nth-child(even) { background: var(--surface-muted); }

/* Accent par hub (border-top petit trait coloré) */
.yp-hub--accent-primary   { --yp-accent: var(--color-primary-500); --yp-accent-light: rgba(50,191,163,0.08); }
.yp-hub--accent-secondary { --yp-accent: var(--color-secondary-500); --yp-accent-light: rgba(250,152,86,0.08); }
.yp-hub--accent-tertiary  { --yp-accent: var(--color-tertiary-500); --yp-accent-light: rgba(20,72,98,0.06); }

/* Header hub : illus + text en 2 colonnes sur desktop */
.yp-hub__header {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5, 20px);
  align-items: center;
  margin-bottom: var(--space-6, 32px);
  max-width: 920px; margin-inline: auto;
  text-align: center;
}
@media (min-width: 768px) {
  .yp-hub__header { grid-template-columns: 160px 1fr; gap: var(--space-6, 32px); text-align: left; }
}
.yp-hub__illus {
  display: flex; align-items: center; justify-content: center;
  width: 160px; height: 160px; margin: 0 auto;
  background: var(--yp-accent-light);
  border-radius: 50%;
  padding: 24px;
}
.yp-hub__illus img { width: 100%; height: 100%; object-fit: contain; }

.yp-hub__eyebrow {
  display: inline-block;
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--yp-accent); margin-bottom: 8px;
}
.yp-hub__title {
  margin: 0 0 var(--space-3, 12px);
  font-size: clamp(28px, 3.5vw, 40px); font-weight: 800;
  color: var(--color-tertiary-500); line-height: 1.1;
}
.yp-hub__title a { color: inherit; }
.yp-hub__title a:hover { color: var(--yp-accent); }
.yp-hub__intro { color: var(--text-subtle); font-size: 16px; line-height: 1.5; max-width: 620px; }
@media (min-width: 768px) { .yp-hub__intro { margin: 0; } }
.yp-hub__intro--placeholder { color: var(--text-muted); font-size: 13px; }

/* Sub-hub cards — grille stable 3 col desktop, 2 tablet, 1 mobile */
.yp-hub__subs {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-bottom: var(--space-6, 32px);
}
@media (min-width: 600px)  { .yp-hub__subs { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .yp-hub__subs { grid-template-columns: repeat(3, 1fr); } }

.yp-sub-card {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  min-height: 56px;
  padding: 12px 16px;
  background: #fff;
  border: 1px solid var(--color-neutral-200);
  border-radius: 10px;
  color: var(--color-tertiary-500);
  transition: all .2s cubic-bezier(0.4,0,0.2,1);
  text-align: left;
}
.yp-sub-card__name { font-weight: 700; font-size: 14px; line-height: 1.25; }
.yp-sub-card__meta { font-size: 11px; color: var(--text-muted); white-space: nowrap; font-weight: 600; }
.yp-sub-card:hover {
  border-color: var(--yp-accent);
  box-shadow: var(--elevation-4);
  transform: translateY(-1px);
}
.yp-sub-card:hover .yp-sub-card__meta { color: var(--yp-accent); }

/* ============ COLS (featured + latest) ============ */
.yp-hub__cols {
  display: grid; gap: var(--space-6, 32px);
  grid-template-columns: 1fr;
}
@media (min-width: 1024px) { .yp-hub__cols { grid-template-columns: 2fr 1fr; } }

.yp-hub__col-head { margin-bottom: var(--space-4, 16px); }
.yp-hub__col-title {
  margin: 0; font-size: 16px; font-weight: 700;
  color: var(--color-tertiary-500);
}
.yp-badge {
  display: inline-block; padding: 5px 12px;
  border-radius: 999px;
  background: var(--yp-accent); color: #fff;
  font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em;
}

/* ============ CARDS ============ */
.yp-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.yp-cards--large { grid-template-columns: 1fr; }
@media (min-width: 600px) { .yp-cards--large { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) {
  /* 3 cards featured côte à côte en 2 col grid (col featured = 2fr) */
  .yp-hub__col--featured .yp-cards--large { grid-template-columns: repeat(3, 1fr); }
}
.yp-cards--small { grid-template-columns: 1fr; }

.yp-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--elevation-2);
  transition: all .2s cubic-bezier(0.4,0,0.2,1);
  border: 1px solid rgba(0,0,0,0.04);
}
.yp-card:hover { box-shadow: var(--elevation-8); transform: translateY(-3px); }
.yp-card__link { display: flex; flex-direction: column; color: inherit; height: 100%; }

/* Thumbnail */
.yp-card__thumb {
  aspect-ratio: 16/10;
  background-size: cover;
  background-position: center;
  background-color: var(--surface-muted);
  position: relative;
}
.yp-card__thumb--illus {
  background: var(--yp-accent-light);
  display: flex; align-items: center; justify-content: center;
}
.yp-card__thumb--illus img { width: 70px; height: 70px; opacity: 0.9; }

/* Small variant (latest): format liste horizontal */
.yp-cards--small .yp-card { border-radius: 10px; }
.yp-cards--small .yp-card__link { flex-direction: row; }
.yp-cards--small .yp-card__thumb {
  width: 96px; min-width: 96px; aspect-ratio: 1/1;
}
.yp-cards--small .yp-card__thumb--illus img { width: 42px; height: 42px; }
.yp-cards--small .yp-card__body { padding: 12px 14px; }
.yp-cards--small .yp-card__title { font-size: 14px; }

/* Body */
.yp-card__body { padding: 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.yp-card__cat {
  font-size: 10px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--yp-accent);
}
.yp-card__title {
  margin: 0; font-size: 17px; font-weight: 700;
  color: var(--color-tertiary-500); line-height: 1.3;
}
.yp-card__excerpt {
  margin: 0; color: var(--text-subtle); font-size: 13px;
  line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
  overflow: hidden;
}
.yp-card__arrow {
  display: inline-block; margin-top: auto; padding-top: 8px;
  color: var(--yp-accent);
  font-weight: 700; font-size: 14px;
  transition: transform .2s;
}
.yp-card:hover .yp-card__arrow { transform: translateX(4px); }

/* ============ FOOTER ============ */
.yp-footer {
  background: var(--color-tertiary-500); color: #fff;
  padding: var(--space-6, 32px) 0;
  margin-top: var(--space-8, 64px);
  text-align: center;
  font-size: 13px;
}
.yp-footer a { color: rgba(255,255,255,0.85); }
.yp-footer a:hover { color: var(--color-primary-450); }

/* ============ RESPONSIVE / UTILS ============ */
@media (max-width: 767px) {
  .yp-hub { padding: var(--space-7, 48px) 0; }
  .yp-hero__main { padding: var(--space-5, 20px) 0 var(--space-7, 48px); }
}
