/* ============================================
   ARFOOO LEGACY - MODERNIZED CSS
   Original CSS by Guillaume Hocine
   Modernized for Super Arfooo (2025)
   ============================================ */

/* ============================================
   CSS CUSTOM PROPERTIES
   Refonte 2026 : fond blanc, rouge vif pour l'action, bleu pour les liens,
   couleurs du tourbillon Arfooo en petites touches, vert pour ce qui est validé.
   Les anciens noms (--color-primary, --color-white...) restent
   pour que tout le reste de la feuille suive.
   ============================================ */
:root {
  /* Couleurs de base */
  --ink: #161a26;
  --ink-2: #414858;
  --paper: #ffffff;
  --paper-2: #f7f9fd;
  --paper-3: #eef3fb;
  --line: #e2e8f2;
  --line-strong: #b9c4d6;
  /* Le duo d'Arfooo, en teintes franches : rouge pour l'action, bleu pour les liens */
  --accent: #dc3626;
  --accent-strong: #c02a1c;
  --accent-link: #1259d1;
  --accent-soft: #fff0ea;
  --on-accent: #ffffff;
  --valid: #0a7d45;
  --valid-soft: #dcf5e7;

  /* Pétales du logo (couleurs du tourbillon Arfooo) */
  --petal-1: #ff5247;
  --petal-2: #ffa600;
  --petal-3: #1fc16b;
  --petal-4: #2f6fdf;
  --petal-5: #8e44c9;

  /* Anciens noms, branchés sur la nouvelle palette */
  --color-primary: var(--accent);
  --color-primary-dark: var(--accent-strong);
  --color-primary-light: #ffd9d2;
  --color-primary-bg: var(--accent-soft);
  --color-on-primary: var(--on-accent);
  --color-text: var(--ink);
  --color-text-secondary: var(--ink-2);
  --color-text-muted: #5f6779;
  --color-border: var(--line);
  --color-border-dark: var(--line-strong);
  --color-bg: var(--paper-2);
  --color-bg-warm: var(--paper);
  --color-white: var(--paper);
  --color-danger: #c62828;
  --color-danger-light: #fdecec;
  --color-success: var(--valid);
  --color-warning: #b7791f;
  --color-orange: #c2410c;
  --color-accent: var(--petal-5);
  --color-accent-light: #f3eafa;

  --font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: var(--font-family);
  --radius: 10px;
  --radius-sm: 6px;
  --radius-lg: 14px;
  --shadow: 0 1px 2px rgba(28, 25, 23, 0.06);
  --shadow-md: 0 4px 12px rgba(28, 25, 23, 0.08);
  --shadow-lg: 0 12px 32px rgba(28, 25, 23, 0.12);
  --shadow-card: 0 1px 2px rgba(28, 25, 23, 0.05);
  --transition: 0.18s cubic-bezier(0.22, 1, 0.36, 1);
  --wrap: 1200px;
  --gutter: 24px;
  --header-h: 68px;
}

/* ============================================
   BASE
   ============================================ */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

/* Contrôles du navigateur (barres de défilement, cases, listes déroulantes, calendriers) clairs ou sombres comme la page.
   Les couleurs suivent data-theme, posé par includes/header.tpl et javascript/main/theme.js selon le réglage
   Apparence et le choix du visiteur, et non la préférence du système : color-scheme suit donc data-theme, pas « light dark ». */
:root {
  color-scheme: light;
}

:root[data-theme="dark"] {
  color-scheme: dark;
}

body {
  margin: 0;
  padding: 0;
  line-height: 1.6;
  font-family: var(--font-family);
  font-size: 16px;
  color: var(--color-text);
  background-color: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  font-variant-numeric: tabular-nums;
}

::selection {
  background: var(--color-primary-light);
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--paper) !important;
  border-radius: var(--radius-sm);
  font-weight: 600;
}
.skip-link:focus {
  top: 12px;
}

#principal {
  position: relative;
  width: 100%;
  min-height: 100vh;
  background-color: var(--paper);
}

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

/* ============================================
   EN-TÊTE
   ============================================ */
/* ---------- Bannière du haut de page (Configurations > Apparence) ----------
   Une image de l'annuairiste, au-dessus ou au-dessous de l'en-tête, dans tous les thèmes.
   « cover » : bande sur toute la largeur ; l'image garde ses proportions tant que la bande reste entre 96 px
   et 340 px de haut (38 % de la hauteur de la fenêtre au plus), puis elle est recadrée autour de --masthead-pos.
   « whole » : image entière, jamais agrandie au-delà de sa largeur ; la bande prolonge la couleur de ses bords.
   Variables posées par la page : --masthead-w, --masthead-pos, --masthead-left, --masthead-right. */
.masthead {
  background: var(--paper-2);
  line-height: 0;
}

.masthead-link {
  display: block;
}

.masthead-image {
  display: block;
  width: 100%;
  height: auto;
}

.masthead--cover .masthead-image {
  min-height: 96px;
  max-height: min(340px, 38vh);
  object-fit: cover;
  object-position: var(--masthead-pos, center);
}

.masthead--whole {
  background: linear-gradient(90deg, var(--masthead-left, var(--paper-2)) 0 50%, var(--masthead-right, var(--paper-2)) 50% 100%);
}

.masthead--whole .masthead-image {
  max-width: min(100%, var(--masthead-w, 100%));
  margin: 0 auto;
}

.masthead-link:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: -3px;
}

@media print {
  .masthead {
    display: none;
  }
}

#top1.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.header-row {
  display: flex;
  align-items: center;
  gap: 28px;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  text-decoration: none !important;
  color: var(--ink) !important;
}

.brand-mark {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.brand:hover .brand-mark {
  transform: rotate(72deg);
}

.brand-name {
  font-size: 21px;
  line-height: 1;
  font-weight: 500;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.brand-name b {
  font-weight: 800;
}

#top2.header-nav {
  flex: 1;
  min-width: 0;
}

#menutop2 ul {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

#menutop2 li {
  margin: 0;
}

#menutop2 li a {
  display: block;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 550;
  color: var(--ink-2);
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--transition), background-color var(--transition);
}

#menutop2 li a:hover {
  color: var(--ink);
  background: var(--paper-2);
}

#menutop2 li#account {
  margin-left: auto;
}

#menutop2 li#add a {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 650;
  padding: 9px 16px;
  margin-left: 6px;
}

#menutop2 li#add a:hover {
  background: var(--accent-strong);
  color: var(--on-accent);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.header-ad:empty {
  display: none;
}

/* Sélecteur de langue */
.lang-switcher {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 999px;
}

.lang-btn {
  display: inline-block;
  min-width: 34px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-align: center;
  color: var(--color-text-muted) !important;
  text-decoration: none !important;
}

.lang-btn:hover {
  color: var(--ink) !important;
}

.lang-btn.active {
  background: var(--ink);
  color: var(--paper) !important;
}

/* Bouton thème */
.theme-toggle-btn {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  cursor: pointer;
  transition: background-color var(--transition), color var(--transition);
}

.theme-toggle-btn:hover {
  background: var(--paper-2);
  color: var(--ink);
}

.theme-toggle-btn svg {
  width: 18px;
  height: 18px;
}

#theme-icon-sun { display: none; }
#theme-icon-moon { display: block; }
[data-theme="dark"] #theme-icon-sun { display: block; }
[data-theme="dark"] #theme-icon-moon { display: none; }

/* Bouton menu (mobile) */
.hamburger-btn {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.hamburger-bar {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform var(--transition), opacity var(--transition);
}

body.drawer-open .hamburger-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.drawer-open .hamburger-bar:nth-child(2) { opacity: 0; }
body.drawer-open .hamburger-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.drawer-overlay {
  display: none;
}

/* ============================================
   ACCUEIL : BANDEAU D'OUVERTURE
   ============================================ */
.home-hero {
  background: var(--paper-2);
  border-bottom: 1px solid var(--line);
}

.home-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 56px;
  align-items: center;
  padding-top: 64px;
  padding-bottom: 56px;
}

.home-hero h1 {
  float: none;
  display: block;
  margin: 0 0 20px;
  font-family: var(--font-display);
  font-size: clamp(32px, 4.4vw, 52px);
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--ink);
  text-wrap: balance;
}

.home-hero-lead {
  margin: 0 0 32px;
  max-width: 34em;
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink-2);
}

.home-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 16px;
  font-weight: 650;
  line-height: 1.2;
  text-decoration: none !important;
  cursor: pointer;
  transition: background-color var(--transition), border-color var(--transition), color var(--transition), transform var(--transition);
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary,
.btn-primary:link,
.btn-primary:visited {
  background: var(--accent);
  color: var(--on-accent);
}

.btn-primary:hover {
  background: var(--accent-strong);
  color: var(--on-accent);
}

.btn-ghost,
.btn-ghost:link,
.btn-ghost:visited {
  background: var(--paper);
  border-color: var(--line-strong);
  color: var(--ink);
}

.btn-ghost:hover {
  border-color: var(--ink);
  color: var(--ink);
}

.home-hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
  font-size: 14.5px;
  color: var(--ink-2);
}

.home-hero-facts li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.home-hero-facts svg {
  width: 16px;
  height: 16px;
  color: var(--valid);
  flex-shrink: 0;
}

/* Échelle : longueur de description -> liens profonds */
.ladder {
  min-width: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 26px 22px 22px;
}

.ladder-title {
  margin: 0 0 4px;
  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.ladder-sub {
  margin: 0 0 24px;
  font-size: 14.5px;
  color: var(--color-text-muted);
}

.ladder-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ladder-step {
  display: grid;
  grid-template-rows: 124px auto;
  row-gap: 10px;
}

.ladder-bar {
  display: block;
  align-self: end;
  border-radius: 6px 6px 2px 2px;
  background: var(--paper-3);
  transform-origin: bottom;
}

.ladder-step:nth-child(1) .ladder-bar { height: 34px; background: var(--paper-3); }
.ladder-step:nth-child(2) .ladder-bar { height: 62px; background: color-mix(in srgb, var(--accent) 30%, var(--paper)); }
.ladder-step:nth-child(3) .ladder-bar { height: 92px; background: color-mix(in srgb, var(--accent) 62%, var(--paper)); }
.ladder-step:nth-child(4) .ladder-bar { height: 124px; background: var(--accent); }

.ladder-num {
  display: block;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--ink);
}

.ladder-label {
  display: block;
  margin-top: 4px;
  font-size: 12.5px;
  line-height: 1.35;
  color: var(--ink-2);
}

.ladder-note {
  margin: 22px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--color-text-muted);
}

@media (prefers-reduced-motion: no-preference) {
  .ladder-bar {
    animation: ladder-rise 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
  }
  .ladder-step:nth-child(2) .ladder-bar { animation-delay: 0.08s; }
  .ladder-step:nth-child(3) .ladder-bar { animation-delay: 0.16s; }
  .ladder-step:nth-child(4) .ladder-bar { animation-delay: 0.24s; }
}

@keyframes ladder-rise {
  from { transform: scaleY(0.15); }
  to { transform: scaleY(1); }
}

/* ============================================
   RECHERCHE
   ============================================ */
#top3 {
  margin: 0;
  padding: 20px 0;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

#searchEnginePanel {
  position: relative;
}

#search {
  border-radius: var(--radius-lg);
  transition: background-color 0.25s ease, box-shadow 0.25s ease;
}

#search.search-expanded {
  background: var(--paper);
  padding: 12px;
  box-shadow: var(--shadow-lg);
}

.search-bar {
  display: flex;
  align-items: stretch;
  min-height: 62px;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.search-bar:focus-within {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(28, 25, 23, 0.08);
}

.search-field {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 8px 20px;
}

.search-field-label {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.3;
}

#search .search-field-input,
.search-field-input {
  width: 100%;
  margin: 0;
  padding: 2px 0;
  border: none !important;
  outline: none;
  background: transparent !important;
  box-shadow: none !important;
  font-family: inherit;
  font-size: 16px;
  color: var(--ink);
}

.search-field-input::placeholder {
  color: var(--color-text-muted);
}

.search-sep {
  width: 1px;
  margin: 12px 0;
  background: var(--line);
}

.search-submit {
  margin: 8px;
  padding: 0 28px;
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--on-accent);
  font-family: inherit;
  font-size: 16px;
  font-weight: 650;
  cursor: pointer;
  transition: background-color var(--transition);
}

.search-submit:hover {
  background: var(--accent-strong);
}

.search-advanced-toggle {
  margin-top: 10px;
  text-align: right;
}

a#advancedSearchLink,
a#advancedSearchLink:link,
a#advancedSearchLink:visited {
  font-size: 14px;
  font-weight: 550;
  color: var(--ink-2);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--line-strong);
}

a#advancedSearchLink:hover {
  color: var(--ink);
  text-decoration-color: var(--ink);
}

a#advancedSearchLink::after {
  content: '';
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 8px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-3px) rotate(45deg);
  transition: transform var(--transition);
}

a#advancedSearchLink.is-open::after {
  transform: translateY(0) rotate(-135deg);
}

@keyframes advSearchOpen {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes advSearchClose {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(-4px); }
}

#searchEngineExtraFields {
  display: none;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 12px;
}

#searchEngineExtraFields.is-open {
  display: flex;
  animation: advSearchOpen 0.25s ease both;
}

#searchEngineExtraFields.is-closing {
  display: flex;
  animation: advSearchClose 0.2s ease both;
}

div.search_cat_place {
  flex: 1 1 220px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

div.search_cat_place .text_search {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
}

div.search_cat_place select {
  width: 100%;
  min-height: 42px;
  padding: 8px 34px 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background-color: var(--paper);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2378716c' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}

div.search_cat_place select:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

div.search_cat_place select:hover:not(:disabled),
div.search_cat_place select:focus {
  border-color: var(--ink);
  outline: none;
}

.selectCategory {
  font-weight: 700;
}

.selectSubcategory {
  font-weight: 400;
}

div.din_search_engine {
  flex: 1 1 220px;
}

/* ============================================
   PIED DE PAGE
   ============================================ */
#bottom {
  margin-top: 0;
  background: #1c1917;
  color: #d6d0c8;
}

#column_bottom {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 56px var(--gutter) 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid #3a3531;
}

.footer-brand .brand-name {
  color: #ffffff;
}

.footer-pitch {
  margin: 16px 0 0;
  max-width: 30em;
  font-size: 15px;
  line-height: 1.6;
  color: #bdb5ab;
}

/* Profils officiels de l'annuaire, en icônes sous la présentation du pied de page */
.footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  /* Couleur du texte du pied de page de chaque thème (sombre ou clair) */
  color: inherit;
  border: 1px solid color-mix(in srgb, currentColor 35%, transparent);
  transition: background-color .2s ease, border-color .2s ease;
}

.footer-social a:hover,
.footer-social a:focus-visible {
  background: color-mix(in srgb, currentColor 14%, transparent);
  border-color: color-mix(in srgb, currentColor 65%, transparent);
}

.footer-title {
  margin: 0 0 14px;
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
}

.footer-links {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links li {
  margin: 0 0 9px;
}

#bottom a,
#bottom a:link,
#bottom a:visited {
  color: #d6d0c8;
  text-decoration: none;
}

#bottom a:hover {
  color: #ffffff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-copy {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 24px;
  font-size: 13.5px;
  color: #a39b91;
}

/* ============================================
   MISE EN PAGE : CONTENU + COLONNE
   ============================================ */
#main1 {
  background: var(--paper);
}

#main2 {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 288px;
  grid-template-rows: auto 1fr;
  column-gap: 48px;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 36px var(--gutter) 72px;
}

#middle {
  grid-column: 1;
  grid-row: 1 / span 2;
  min-width: 0;
}

#left {
  grid-column: 2;
  grid-row: 1;
  min-width: 0;
}

#right {
  grid-column: 2;
  grid-row: 2;
  min-width: 0;
}

/* Grand écran : la colonne latérale reste à l'écran quand la page défile. Une colonne plus haute que la
   fenêtre défile d'abord avec la page, puis se cale sur son bas : --side-h est sa hauteur, mesurée par
   javascript/main/theme.js. Sans JavaScript, elle se cale sous l'en-tête. */
@media (min-width: 1025px) {
  #right {
    position: sticky;
    top: min(calc(var(--header-h) + 20px), calc(100vh - var(--side-h, 0px) - 20px));
    align-self: start;
  }
}

#main2 > .fixe {
  display: none;
}

/* Accueil : la colonne latérale de l'annuaire démarre en haut de la page, comme sur les autres pages.
   Le bandeau d'ouverture et la recherche sont dans la colonne centrale. */
.page-home .home-hero {
  border: 0;
  border-radius: 20px;
  background:
    radial-gradient(circle at calc(100% - 36px) -34px, var(--petal-2) 0 128px, rgba(255, 166, 0, 0) 129px),
    radial-gradient(circle at calc(100% - 250px) calc(100% + 70px), var(--petal-4) 0 150px, rgba(47, 111, 223, 0) 151px),
    var(--accent-soft);
}

/* Sur une colonne, le titre occupe toute la largeur : le disque du haut se fait petit pour ne pas passer dessous */
@media (max-width: 1024px) {
  .page-home .home-hero {
    background:
      radial-gradient(circle at 100% 0, var(--petal-2) 0 58px, rgba(255, 166, 0, 0) 59px),
      radial-gradient(circle at 0 100%, var(--petal-4) 0 120px, rgba(47, 111, 223, 0) 121px),
      var(--accent-soft);
  }
}

/* La colonne du graphique garde une largeur qui laisse ses quatre marches lisibles */
@media (min-width: 1025px) {
  .page-home .home-hero-grid {
    grid-template-columns: minmax(0, 1fr) minmax(312px, 0.72fr);
  }
}

.page-home .home-hero .wrap {
  max-width: none;
  padding-left: 32px;
  padding-right: 32px;
}

.page-home .home-hero-grid {
  gap: 32px;
  padding-top: 40px;
  padding-bottom: 36px;
}

.page-home .home-hero h1 {
  font-size: clamp(28px, 3.1vw, 40px);
}

.page-home #top3 {
  padding: 16px 0 0;
  background: transparent;
  border-bottom: 0;
}

.page-home #searchEnginePanel {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

/* Dans la colonne centrale de l'accueil, la carte passe au-dessus de la liste des régions */
.page-home .france-map {
  grid-template-columns: minmax(0, 1fr);
}

.page-home .france-map-figure {
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

.page-home .france-map-list {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

/* Pages pleine largeur sans colonne latérale (offres, paiement, espace webmaster) */
.page-wide #main2 {
  grid-template-columns: minmax(0, 1fr);
}

.page-wide #left,
.page-wide #right {
  display: none;
}

/* ============================================
   COLONNE DE DROITE (blocs du menu)
   ============================================ */
.menuleft,
.menuright {
  margin: 0 0 16px;
  padding: 16px 18px 8px;
  border-radius: var(--radius-lg);
  background: var(--paper-2);
}

.menuleft ul,
.menuright ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.menuleft li,
.menuright li {
  margin: 0;
  font-size: 14.5px;
}

.menuleft li.header,
.menuright li.header {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 4px;
  padding-bottom: 8px;
  font-size: 16px;
  font-weight: 800;
  color: var(--ink);
}

/* Les couleurs du logo tournent d'un bloc à l'autre, comme le petit logo devant les titres d'Arfooo */
.menuleft li.header::before,
.menuright li.header::before {
  content: "";
  flex: 0 0 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--petal-1);
}

.menuright:nth-of-type(5n+2) li.header::before, .menuleft:nth-of-type(5n+2) li.header::before { background: var(--petal-4); }
.menuright:nth-of-type(5n+3) li.header::before, .menuleft:nth-of-type(5n+3) li.header::before { background: var(--petal-3); }
.menuright:nth-of-type(5n+4) li.header::before, .menuleft:nth-of-type(5n+4) li.header::before { background: var(--petal-2); }
.menuright:nth-of-type(5n+5) li.header::before, .menuleft:nth-of-type(5n+5) li.header::before { background: var(--petal-5); }

.menuleft li a,
.menuright li a {
  display: block;
  padding: 7px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  text-decoration: none;
  transition: color var(--transition), transform var(--transition);
}

.menuleft li a:hover,
.menuright li a:hover {
  color: var(--accent-link);
  transform: translateX(4px);
}

.menuleft li.text,
.menuright li.text {
  padding: 7px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
}

.menuleft li.text_last,
.menuright li.text_last {
  display: none;
}

/* Nuage de tags */
.menuright li.cloudTag1, .menuright li.cloudTag2, .menuright li.cloudTag3,
.menuright li.cloudTag4, .menuright li.cloudTag5, .menuright li.cloudTag6,
.menuright li.cloudTag7, .menuright li.cloudTag8, .menuright li.cloudTag9,
.menuright li.cloudTag10 {
  display: inline-block;
  margin: 0 6px 4px 0;
}

.menuright li[class^="cloudTag"] a {
  display: inline;
  padding: 0;
  border: none;
}

.menuright li.cloudTag1 a { font-size: 12px; }
.menuright li.cloudTag2 a { font-size: 13px; }
.menuright li.cloudTag3 a { font-size: 14px; }
.menuright li.cloudTag4 a { font-size: 15px; }
.menuright li.cloudTag5 a { font-size: 16px; }
.menuright li.cloudTag6 a { font-size: 17px; font-weight: 600; }
.menuright li.cloudTag7 a { font-size: 18px; font-weight: 600; }
.menuright li.cloudTag8 a { font-size: 19px; font-weight: 700; }
.menuright li.cloudTag9 a { font-size: 20px; font-weight: 700; }
.menuright li.cloudTag10 a { font-size: 22px; font-weight: 800; }

/* Mots-clés (fonction désactivée par défaut) */
.menuleft_text_2 {
  margin: 0 0 6px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--ink);
  font-size: 15px;
  font-weight: 750;
}

.menuleft_text_keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin-bottom: 28px;
}

.menuleft_keywords ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.menuleft_keywords li a {
  font-weight: 650;
  color: var(--ink-2);
}

/* ============================================
   CATÉGORIES (annuaire en colonnes)
   ============================================ */
.cat-directory {
  columns: 3 260px;
  column-gap: 40px;
  margin: 0 0 8px;
}

.cat-block {
  break-inside: avoid;
  margin: 0 0 26px;
}

.cat-block-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.3;
  font-weight: 750;
  letter-spacing: -0.01em;
}

.cat-block-title::before {
  content: '';
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: var(--petal-1);
  transform: translateY(-1px);
}

.cat-block-title:has(img.category_image)::before { display: none; }
.cat-block:nth-child(5n+2) .cat-block-title::before { background: var(--petal-2); }
.cat-block:nth-child(5n+3) .cat-block-title::before { background: var(--petal-3); }
.cat-block:nth-child(5n+4) .cat-block-title::before { background: var(--petal-4); }
.cat-block:nth-child(5n+5) .cat-block-title::before { background: var(--petal-5); }

.cat-block-title a,
.cat-block-title a:link,
.cat-block-title a:visited {
  color: var(--ink);
  text-decoration: none;
}

.cat-block-title a:hover {
  color: var(--accent-link);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cat-count {
  margin-left: auto;
  padding-left: 8px;
  font-size: 13px;
  font-weight: 650;
  color: var(--valid);
}

.cat-block img.category_image {
  width: 22px;
  height: 22px;
  object-fit: contain;
  align-self: center;
}

.cat-subs {
  margin: 0;
  padding: 0 0 0 20px;
  list-style: none;
  font-size: 14.5px;
  line-height: 1.45;
}

.cat-subs li {
  margin: 0 0 5px;
}

.cat-subs a,
.cat-subs a:link,
.cat-subs a:visited {
  color: var(--ink-2);
  text-decoration: none;
}

.cat-subs a:hover {
  color: var(--accent-link);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Sous-catégories sans enfants : grille simple */

/* ============================================
   ACCUEIL : SECTIONS
   ============================================ */
.home-section {
  padding: 56px 0 0;
}

.home-section + .home-section {
  margin-top: 8px;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin: 0 0 24px;
}

.section-head h2 {
  float: none;
  display: block;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 2.6vw, 30px);
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.section-link,
.section-link:link,
.section-link:visited {
  font-size: 15px;
  font-weight: 650;
  color: var(--accent-link);
  text-decoration: none;
}

.section-link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Dernières fiches validées */
.latest-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.latest-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper);
  overflow: hidden;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.latest-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.latest-thumb {
  display: block;
  aspect-ratio: 16 / 10;
  background: var(--paper-2);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.latest-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.latest-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px 18px 18px;
  flex: 1;
}

.latest-cat {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-muted);
}

.latest-title {
  margin: 0;
  font-size: 17px;
  line-height: 1.3;
  font-weight: 750;
  letter-spacing: -0.01em;
}

.latest-title a,
.latest-title a:link,
.latest-title a:visited {
  color: var(--ink);
  text-decoration: none;
}

.latest-title a::after {
  content: '';
  position: absolute;
  inset: 0;
}

.latest-title a:hover {
  color: var(--accent-link);
}

.latest-desc {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--ink-2);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.latest-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--valid);
}

.latest-meta svg {
  width: 15px;
  height: 15px;
}

.latest-empty {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 28px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  color: var(--ink-2);
}

.latest-empty p {
  margin: 0;
}

/* Texte de présentation */
.home-about {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 48px;
  margin-top: 64px;
  padding: 48px 0 0;
  border-top: 1px solid var(--line);
}

.home-about h2 {
  float: none;
  display: block;
  margin: 0;
  font-size: clamp(22px, 2.3vw, 27px);
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-wrap: balance;
}

.home-about-text {
  max-width: 68ch;
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--ink-2);
}

/* Au hasard dans l'annuaire */
.random-strip {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
}

img.random_image {
  display: block;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: top center;
}

/* ============================================
   LISTES DE SITES (catégories, nouveautés, recherche)
   ============================================ */
.visually-hidden {
  position: absolute !important;
  padding: 0;
  margin: -1px;
  border: 0;
}

.site-list {
  clear: both;
  margin: 0 0 8px;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.site-row {
  display: grid;
  grid-template-columns: 168px minmax(0, 1fr);
  gap: 22px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}

.site-row:not(:has(.site-row-thumb)) {
  grid-template-columns: minmax(0, 1fr);
}

.site-row-thumb {
  display: block;
  align-self: start;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
  overflow: hidden;
}

.site-row img.website_image {
  float: none;
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  border: none;
  border-radius: 0;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.site-row-thumb:hover img.website_image {
  transform: scale(1.03);
  box-shadow: none;
}

.site-row-body {
  min-width: 0;
}

.site-row-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin: 0 0 4px;
  /* Titre de niveau 2 depuis novembre 2026 : sa taille et sa graisse restent celles-ci, quel que soit le thème */
  text-wrap: wrap;
  font-size: 19px;
  line-height: 1.3;
  font-weight: 750;
  letter-spacing: -0.01em;
}

.site-row-title a,
.site-row-title a:link,
.site-row-title a:visited {
  color: var(--ink);
  text-decoration: none;
}

.site-row-title a:hover {
  color: var(--accent-link);
  text-decoration: underline;
}

.site-row-title img.package_image {
  float: none;
  max-height: 22px;
}

.site-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.site-badge-new {
  background: var(--valid-soft);
  color: var(--valid);
}

.site-row-domain {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 8px;
  font-size: 14px;
  color: var(--valid);
}

.site-row-domain img.flag_image {
  float: none;
  margin: 0;
}

.site-row-desc {
  margin: 0 0 10px;
  max-width: 72ch;
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--ink-2);
}

.site-row-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  margin: 0;
  font-size: 14px;
  color: var(--color-text-muted);
}

a.site-row-more,
a.site-row-more:link,
a.site-row-more:visited {
  font-weight: 650;
  color: var(--accent-link);
}

a.site-row-visit,
a.site-row-visit:link,
a.site-row-visit:visited {
  color: var(--ink-2);
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
}

a.site-row-visit:hover {
  color: var(--ink);
  text-decoration-color: var(--ink);
}

.site-row mark,
.site-row .highlight {
  background: #fde68a;
  color: inherit;
  padding: 0 2px;
  border-radius: 3px;
}

@media (max-width: 640px) {
  .site-row {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 14px;
    padding: 18px 0;
  }

  .site-row-title {
    font-size: 17px;
  }

  .site-row-desc {
    font-size: 15px;
  }
}

/* Pagination */
.pager {
  display: flex !important;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 24px 0 8px !important;
}

.pager a,
.pager .pager-current {
  display: inline-grid;
  place-items: center;
  min-width: 40px;
  height: 40px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-weight: 650;
  color: var(--ink-2);
  text-decoration: none;
}

.pager a:hover {
  border-color: var(--ink);
  color: var(--ink);
  text-decoration: none;
}

.pager .pager-current {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.pager-arrow svg {
  width: 18px;
  height: 18px;
}

.pager-total {
  margin: 0 6px;
  font-size: 14px;
  color: var(--color-text-muted);
}

/* ===========================================
   GEO-REFERENCING PAGES
   =========================================== */

/* Intro section */
.geo-intro {
  background: var(--color-primary-bg);
  padding: 16px 20px;
  margin-bottom: 20px;
  border-radius: var(--radius-lg);
  font-size: 0.95em;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* Continent section */
.geo-continent-section {
  margin-bottom: 24px;
}

/* Countries grid */
.geo-countries-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
  padding: 12px 0;
}

.geo-country-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px 12px 16px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: 14px;
  text-decoration: none;
  color: var(--color-text);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  box-shadow: var(--shadow-card);
  gap: 0;
  overflow: hidden;
}

.geo-country-card:hover {
  border-color: var(--color-primary);
  box-shadow: 0 8px 24px rgba(207, 62, 28, 0.18);
  transform: translateY(-4px);
}

/* Drapeau SVG */
.geo-country-flag {
  margin-bottom: 12px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.geo-flag-img {
  width: 64px;
  height: auto;
  /* Même cadre pour tous les drapeaux (la Belgique est presque carrée, le Luxembourg très allongé) : cartes alignées */
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 5px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18), 0 0 0 1px rgba(0,0,0,0.06);
  display: block;
  transition: box-shadow 0.2s ease;
}

.geo-country-card:hover .geo-flag-img {
  box-shadow: 0 4px 14px rgba(0,0,0,0.25), 0 0 0 1px rgba(0,0,0,0.08);
}

[data-theme="dark"] .geo-flag-img {
  box-shadow: 0 2px 10px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.08);
}

/* Fallback texte si l'image ne charge pas */
.geo-flag-fallback {
  font-size: 1.2em;
  font-weight: 700;
  color: var(--color-primary);
  letter-spacing: 2px;
  text-transform: uppercase;
  background: var(--color-primary-bg);
  padding: 8px 14px;
  border-radius: 6px;
  display: inline-block;
}

.geo-country-name {
  font-weight: 600;
  font-size: 0.9em;
  color: var(--color-text);
  margin-bottom: 8px;
  text-align: center;
  line-height: 1.3;
}

.geo-country-count {
  font-size: 0.75em;
  color: var(--color-primary);
  background: var(--color-primary-bg);
  padding: 3px 10px;
  border-radius: 12px;
  font-weight: 500;
}

/* Regions & Departments grid */
.geo-section-title {
  font-size: 1.15em;
  color: var(--color-primary-dark);
  margin: 16px 0 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--color-primary-light);
}

.geo-regions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.geo-region-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 16px;
  transition: border-color 0.2s, background 0.25s;
}

.geo-region-card:hover {
  border-color: var(--color-primary);
}

.geo-region-name {
  font-size: 1.05em;
  color: var(--color-text);
  margin: 0 0 6px;
}

.geo-region-count {
  display: inline-block;
  font-size: 0.8em;
  color: var(--color-primary);
  background: var(--color-primary-light);
  padding: 2px 10px;
  border-radius: 12px;
  margin-bottom: 10px;
}

.geo-region-link {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.9em;
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 600;
}

.geo-region-link:hover {
  text-decoration: underline;
}

.geo-region-code {
  font-weight: 400;
  color: var(--color-text-muted);
  font-size: 0.85em;
}

/* Departments list inside region card */
.geo-departments-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.geo-dept-link {
  display: inline-block;
  font-size: 0.82em;
  padding: 3px 10px;
  background: var(--color-primary-bg);
  color: var(--color-primary-dark);
  border-radius: 14px;
  text-decoration: none;
  transition: background 0.2s;
  white-space: nowrap;
}

.geo-dept-link:hover {
  background: var(--color-primary-light);
  color: var(--color-primary);
}

/* Departments grid (standalone) */
.geo-departments-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}

.geo-dept-card {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  text-decoration: none;
  color: var(--color-text);
  transition: all 0.2s ease;
}

.geo-dept-card:hover {
  border-color: var(--color-primary);
  background: var(--color-primary-bg);
}

.geo-dept-code {
  font-weight: 700;
  color: var(--color-primary);
  font-size: 0.95em;
  min-width: 30px;
}

.geo-dept-name {
  font-size: 0.9em;
  color: var(--color-text);
}

/* Cities grid */
.geo-cities-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.geo-city-link {
  display: inline-block;
  font-size: 0.88em;
  padding: 5px 14px;
  background: var(--color-primary-bg);
  color: var(--color-primary-dark);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  text-decoration: none;
  transition: all 0.2s;
}

.geo-city-link:hover {
  border-color: var(--color-primary);
  background: var(--color-primary-light);
  color: var(--color-primary);
}

.geo-zipcode {
  color: var(--color-text-muted);
  font-size: 0.85em;
}

.geo-city-zip {
  font-weight: 400;
  color: var(--color-text-muted);
}

/* City info */
.geo-city-info {
  background: var(--color-primary-bg);
  padding: 12px 20px;
  border-radius: 8px;
  margin-bottom: 16px;
}

.geo-breadcrumb-text {
  color: var(--color-text-secondary);
  font-size: 0.92em;
  margin: 0;
}

/* No results */
.geo-no-results {
  text-align: center;
  color: var(--color-text-muted);
  font-style: italic;
  padding: 30px 20px;
  font-size: 0.95em;
}

/* Submit form geo hint */
.geo-hint {
  font-size: 0.9em;
  color: var(--color-text-secondary);
  background: var(--color-primary-bg);
  padding: 10px 14px;
  margin: 0 0 16px; /* full width */
  border-radius: var(--radius);
}

/* Geo selects: wider than input_text_medium default (150px) to show full option text */
#geoCountrySelect,
#geoRegionSelect,
#geoCitySelect {
  width: 280px;
}

/* Geo sub-section */
.geo-sub-section {
  margin-bottom: 20px;
}

/* Carte de France cliquable (gabarit geo/franceMap.tpl) : la carte, et la liste des zones à côté */
.geo-map-section {
  margin-bottom: 24px;
}

.france-map {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 24px 40px;
  align-items: center;
}

.france-map-figure {
  min-width: 0;
}

.france-map-figure:only-child {
  grid-column: 1 / -1;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
}

.france-map-caption {
  margin: 0 0 8px;
  min-height: 1.5em;
  font-size: 15px;
  text-align: center;
  color: var(--color-text-muted);
}

.france-map-caption.is-active {
  font-weight: 650;
  color: var(--color-text);
}

.france-map-svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 560px;
}

/* Zones de la carte : bleu plein, séparateurs bleu nuit épais, zone survolée en orange. Les couleurs sont des
   variables, qu'un thème ou les styles personnalisés peuvent changer :
     --map-fill         zone sans fiche (4,9 pour 1 sur fond blanc)
     --map-fill-strong  zone qui a des fiches, un ton plus soutenu
     --map-line         séparateurs et contour
     --map-hover        zone survolée ou atteinte au clavier
   Sur fond sombre, les séparateurs prennent la couleur de la page. */
.france-map {
  --map-fill: #456bc2;
  --map-fill-strong: #2f4f9f;
  --map-line: #243780;
  --map-hover: #ec691e;
}

[data-theme="dark"] .france-map {
  --map-fill: #5a7ed3;
  --map-fill-strong: #86a2e6;
  --map-line: var(--color-white);
  --map-hover: #f58a4a;
}

/* Ombre douce sous les zones seulement : les noms et les numéros restent nets */
.france-map-zones {
  filter: drop-shadow(0 5px 8px rgba(36, 55, 128, 0.18));
}

.france-map-area path {
  fill: var(--map-fill);
  stroke: var(--map-line);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
  transition: fill 0.16s cubic-bezier(0.23, 1, 0.32, 1);
}

.france-map-area:not(.is-empty) path {
  fill: var(--map-fill-strong);
}

.france-map-area:focus path {
  fill: var(--map-hover);
}

@media (hover: hover) and (pointer: fine) {
  .france-map-area:hover path {
    fill: var(--map-hover);
  }
}

.france-map-area:focus {
  outline: none;
}

.france-map-area:focus-visible path {
  stroke: var(--color-text);
  stroke-width: 3;
}

/* Outre-mer : pas de cadre, le dessin et son nom en dessous */
.france-map-inset {
  fill: none;
  stroke: none;
}

.france-map-inset-label {
  font-family: var(--font-family);
  font-size: 9px;
  font-weight: 600;
  fill: var(--color-text-secondary);
  pointer-events: none;
}

.france-map-label {
  font-family: var(--font-family);
  font-weight: 700;
  fill: #ffffff;
  pointer-events: none;
}

.france-map-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.france-map-list a,
.france-map-list a:link,
.france-map-list a:visited {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 15px;
  color: var(--color-text);
  text-decoration: none;
}

.france-map-list a:hover {
  color: var(--accent-link);
}

.france-map-code {
  min-width: 28px;
  font-weight: 700;
  color: var(--color-primary);
}

.france-map-count {
  margin-left: auto;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  color: var(--color-text-muted);
}

@media (max-width: 768px) {
  .france-map {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .france-map-list {
    grid-template-columns: 1fr;
  }
}

/* Responsive: geo grids */
@media screen and (max-width: 768px) {
  .geo-hint {
    margin-left: 0;
  }
  #geoCountrySelect,
  #geoRegionSelect,
  #geoCitySelect {
    width: 100%;
  }
  .geo-countries-grid {
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 10px;
  }
  .geo-flag-img {
    width: 52px;
  }
  .geo-regions-grid {
    grid-template-columns: 1fr;
  }
  .geo-departments-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  }
}

@media screen and (max-width: 480px) {
  .geo-countries-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  .geo-country-card {
    padding: 14px 8px 12px;
  }
  .geo-flag-img {
    width: 44px;
  }
  .geo-country-name {
    font-size: 0.78em;
  }
}

/* END GEO-REFERENCING */

/* Legacy menucategories (keep for sidebar/keyword menus) */
.menucategories {
  float: left;
  width: 33.33%;
  margin: 0;
  padding: 0 0 0 2px;
  box-sizing: border-box;
}

.menucategories ul {
  padding: 0;
  margin: 0;
  list-style-type: none;
}

.menucategories li.keyword {
  float: left;
  width: 100%;
  display: inline;
  padding: 0;
  margin: 8px 0;
}

.menucategories li.keyword a, .menucategories li.keyword a:link, .menucategories li.keyword a:visited {
  display: inline;
  width: auto;
  height: 22px;
  line-height: 22px;
  margin: 0;
  padding: 0 3px;
  font-size: 1em;
  font-weight: 600;
  text-decoration: none;
  color: var(--color-text);
  transition: color var(--transition);
}

.menucategories li.keyword a:hover, .menucategories li.keyword a:active {
  color: var(--color-primary);
  background-color: transparent;
}

/* ============================================
   QUALITY SCORE BADGES (remplace l'ancien PageRank)
   ============================================ */

/* ===== Onglets Top Qualité / Top Hits ===== */
.toprank-tabs {
  display: flex;
  gap: 8px;
  margin: 0 0 20px 0;
}
.toprank-tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  color: var(--color-text);
  background: var(--color-white);
  border: 2px solid transparent;
  transition: all 0.2s ease;
}
.toprank-tab:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}
.toprank-tab.active {
  background: var(--color-primary);
  color: var(--on-accent);
  border-color: var(--color-primary);
}
.toprank-tab-icon {
  font-size: 1.1rem;
}

/* Navigation par score sur la page Top qualité */
.quality-score-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 16px 12px;
  margin: 0 0 16px 0;
  background: var(--paper-2);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}

.quality-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 12px;
  border-radius: 8px;
  text-decoration: none;
  border: 2px solid var(--line);
  background: var(--color-white);
  transition: all 0.2s ease;
  min-width: 60px;
}

.quality-badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
  border-color: var(--color-primary);
}

.quality-badge.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--on-accent);
  box-shadow: 0 4px 12px rgba(207, 62, 28, 0.3);
}

.quality-badge.active .quality-stars {
  color: #fbbf24;
}

.quality-badge.active .quality-label {
  color: rgba(255, 255, 255, 0.9);
}

.quality-stars {
  font-size: 11px;
  line-height: 1;
  letter-spacing: -1px;
  color: #f59e0b;
}

.quality-label {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  margin-top: 2px;
}

/* Couleurs progressives par score (1-5 étoiles) */
.quality-badge.quality-1 { border-color: #ef4444; }
.quality-badge.quality-2 { border-color: #f97316; }
.quality-badge.quality-3 { border-color: #eab308; }
.quality-badge.quality-4 { border-color: #22c55e; }
.quality-badge.quality-5 { border-color: #15803d; }

/* Badge inline dans les listes de sites (couleurs de texte foncées en 1.4.0 : contraste d'au moins 4,5 pour 1) */
.quality-badge-inline {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.3px;
  vertical-align: middle;
}

.quality-badge-inline.quality-1 {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}
.quality-badge-inline.quality-2 {
  background: #fff7ed;
  color: #c2410c;
  border: 1px solid #fed7aa;
}
.quality-badge-inline.quality-3 {
  background: #fefce8;
  color: #a16207;
  border: 1px solid #fef08a;
}
.quality-badge-inline.quality-4 {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}
.quality-badge-inline.quality-5 {
  background: #e3f2ea;
  color: #166534;
  border: 1px solid #b7dfc6;
}

/* ===== Notice Score de qualité (glassmorphism) ===== */
.quality-notice {
  display: flex;
  align-items: center;
  gap: 10px;
  /* Couleurs du thème (clair et sombre) : l'ancien fond bleu clair fixe rendait le texte illisible en sombre */
  background: var(--accent-soft);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px 18px;
  margin: 18px 0;
  font-size: 0.88em;
  color: var(--ink);
  line-height: 1.55;
  box-shadow: 0 4px 24px rgba(207, 62, 28, 0.1), 0 0 0 1px rgba(207, 62, 28, 0.06);
}
.quality-notice-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: var(--color-primary);
}
.quality-notice-text {
  flex: 1;
}

/* Ancien #menuin conservé pour keywords */
#menuin {
  float: left;
  width: 100%;
  padding: 10px;
  margin: 0 0 10px 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  text-align: center;
}

#menuin ul {
  padding: 0;
  margin: 0;
  list-style-type: none;
}

#menuin li {
  padding: 0;
  margin: 0;
  display: inline;
}

#menuin li a, #menuin li a:link, #menuin li a:visited {
  display: inline;
  margin: 0;
  padding: 0 0 0 3px;
  color: var(--color-text);
  font-weight: 600;
  text-decoration: none;
  transition: color var(--transition);
}

#menuin li a:hover, #menuin li a:active {
  margin: 0;
  padding: 0 0 0 3px;
  color: var(--color-primary);
  font-weight: 600;
  text-decoration: none;
}

/* ============================================
   CENTRAL PAGE / CONTENT
   ============================================ */
#middle {
  margin: 0;
  padding: 0;
  min-height: 400px;
}

.column {
  display: flow-root;
  margin: 0;
  padding: 0;
}

.column_in {
  float: left;
  width: 100%;
  margin: 0 0 16px 0;
  padding: 20px 22px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background-color: var(--color-white);
  line-height: 1.65;
}

#map {
  float: left;
  width: 100%;
  height: 250px;
  margin: 0;
  padding: 0;
  border-radius: var(--radius);
}

.column_in_pagination {
  float: left;
  width: 100%;
  margin: 0;
  padding: 12px;
  text-align: center;
}

.show_arbo {
  float: none;
  clear: both;
  display: block;
  width: 100%;
  margin: 0 0 14px;
  padding: 0;
  color: var(--color-text-muted);
  font-size: 14px;
  line-height: 1.5;
}

/* ============================================
   FORMS
   ============================================ */
fieldset.column_in {
  float: left;
  width: 100%;
  margin: 0 0 10px 0;
  padding: 12px;
  text-align: right;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}

legend.title {
  float: left;
  display: inline;
  width: calc(100% - 14px);
  height: auto;
  margin: 0 0 20px;
  padding: 0;
  color: var(--ink);
  font-size: 19px;
  font-weight: 750;
  letter-spacing: -0.01em;
  background: none;
}

label {
  float: left;
  margin: 0;
  padding: 0;
  line-height: 1.8em;
}

label.title {
  width: 142px;
  padding: 0 17px 0 0;
  font-size: 0.9em;
  font-weight: 600;
  text-align: right;
  color: var(--color-text-secondary);
}

div.infos {
  float: left;
  width: 435px;
  margin: 0;
  padding: 0 0 0 10px;
  line-height: 1.8em;
  text-align: left;
}

div.infos_textarea {
  float: left;
  width: 365px;
  margin: 0;
  padding: 0;
}

div.infos_terms {
  float: left;
  width: 570px;
  margin: 0;
  padding: 0 0 0 10px;
  line-height: 1.8em;
  text-align: left;
}

label.infos_select_category {
  text-align: left;
}

/* Case à cocher et son texte dans le même libellé, sur la ligne (un clic sur le texte coche la case) */
label.check-inline { float: none; display: inline; }

label.infos_checkbox {
  width: 200px;
  padding-left: 10px;
  text-align: left;
}

.text_error {
  float: right;
  width: 140px;
  margin: 0 0 -10px 0;
  padding: 4px 8px;
  text-align: center;
  font-size: 0.85em;
  color: var(--color-danger);
  background: var(--color-danger-light);
  border: 1px solid #fecaca;
  border-radius: var(--radius-sm);
}

p.form {
  float: left;
  width: 100%;
  margin: 0 0 10px 0;
  padding: 4px 0;
}

div.form {
  float: left;
  width: 100%;
  margin: 0 0 10px 0;
  padding: 4px 0;
  text-align: left;
}

div.error, td.error {
  background-color: var(--color-danger-light);
}

/* ============================================
   POPUP — jQuery UI Dialog override (modern)
   ============================================ */

/* Modal backdrop */
.ui-widget-overlay {
  background: rgba(0, 0, 0, 0.45) !important;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 1 !important;
}

/* ============================================================
   POPUP MODAL CUSTOM — remplace jQuery UI dialog
   ============================================================ */
.arfooo-popup-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: popupOverlayIn 0.18s ease forwards;
}

@keyframes popupOverlayIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.arfooo-popup-overlay.arfooo-popup-closing {
  animation: popupOverlayOut 0.2s ease forwards;
}

@keyframes popupOverlayOut {
  from { opacity: 1; }
  to   { opacity: 0; }
}

.arfooo-popup-box {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 80px rgba(0,0,0,0.28), 0 4px 16px rgba(0,0,0,0.12);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: popupBoxIn 0.22s cubic-bezier(0.22,1,0.36,1) forwards;
}

/* La fenêtre reçoit le focus à l'ouverture (jquery.popup.js) : pas de cadre autour d'elle, ses champs gardent le leur */
.arfooo-popup-box:focus { outline: none; }

@keyframes popupBoxIn {
  from { opacity: 0; transform: scale(0.92) translateY(10px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.arfooo-popup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-warm);
  flex-shrink: 0;
}

.arfooo-popup-title {
  font-weight: 700;
  font-size: 1rem;
  color: var(--color-text);
  font-family: var(--font-family);
}

.arfooo-popup-close {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.4rem;
  line-height: 1;
  color: var(--color-text-muted);
  padding: 2px 6px;
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition);
}

.arfooo-popup-close:hover {
  color: var(--color-text);
  background: var(--color-border);
}

.arfooo-popup-body {
  padding: 22px 20px;
  overflow-y: auto;
  flex: 1;
}

.arfooo-popup-loading {
  text-align: center;
  font-size: 1.6rem;
  color: var(--color-text-muted);
  padding: 20px 0;
  animation: spin 1s linear infinite;
}

[data-theme="dark"] .arfooo-popup-box {
  box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 4px 16px rgba(0,0,0,0.4);
}

/* Legacy popup wrappers (kept for compat, neutralized) */
#popup_principal { width: 100%; }
#popup_top, #popup_main1, #popup_main2, #popup_middle, #popup_column { margin: 0; padding: 0; }
fieldset.column_in_popup { float: none; width: 100%; border: none; margin: 0; padding: 0; text-align: left; }

/* Modern popup form layout */
.popup-form-row {
  margin-bottom: 16px;
}

.popup-form-row:last-child {
  margin-bottom: 0;
}

.popup-form-row > label,
.popup-form-row > .popup-label {
  display: block;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--color-text);
  margin-bottom: 6px;
  float: none;
  width: auto;
  text-align: left;
  padding: 0;
}

.popup-form-row input[type="text"],
.popup-form-row textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-family: var(--font-family);
  color: var(--color-text);
  background: var(--color-bg-warm);
  transition: border-color var(--transition), box-shadow var(--transition);
  float: none;
}

.popup-form-row input[type="text"]:focus,
.popup-form-row textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(207, 62, 28, 0.12);
}

.popup-mandatory {
  color: var(--color-danger);
  margin-left: 2px;
}

.popup-form-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--color-border);
}

.popup-btn-primary {
  padding: 9px 20px;
  background: var(--color-primary);
  color: var(--on-accent);
  border: none;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition);
  font-family: var(--font-family);
}

.popup-btn-primary:hover {
  background: var(--color-primary-dark);
}

.popup-btn-cancel {
  padding: 9px 20px;
  background: var(--color-white);
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font-family);
}

.popup-btn-cancel:hover {
  background: var(--color-bg);
  border-color: var(--color-border-dark);
}

/* Override old popup label/infos to prevent float layout */
label.title_popup {
  float: none;
  width: auto;
  text-align: left;
  padding: 0;
  font-weight: 600;
  display: block;
  margin-bottom: 6px;
  color: var(--color-text);
}

div.infos_popup {
  float: none;
  width: 100%;
  padding: 0;
  margin: 0;
}

div.form_popup {
  float: none;
  width: auto;
  margin: 0 0 14px 0;
  padding: 0;
  text-align: left;
}

/* ============================================
   TABLES
   ============================================ */

th {
  margin: 0;
  padding: 10px 12px;
  font-size: 0.8em;
  font-weight: 600;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-2);
  background: var(--paper-2);
  border-bottom: 1px solid var(--line);
}

td {
  line-height: 1.4em;
  padding: 8px 12px;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

.col1-3 { width: 200px; background-color: var(--color-bg); }
.col2-3 { width: auto; background-color: var(--color-bg); }
.line1 { background-color: var(--color-bg); }
.line2 { background-color: var(--color-white); }

/* ============================================
   TITLES
   ============================================ */
.title_h,
.title_h_1,
.title_h_2 {
  float: none; /* plus de flottant : il réduisait à zéro la largeur des blocs en colonnes placés après le titre */
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0 18px;
  padding: 0;
}

.title_h_2 {
  margin-top: 28px;
}

.title_h_1 h1,
.title_h h1 {
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.title_h_2 h2,
.title_h h2 {
  font-size: clamp(20px, 2.2vw, 24px);
  line-height: 1.25;
  font-weight: 750;
  letter-spacing: -0.015em;
}

.title_h_1 img.rss_image,
.title_h_2 img.rss_image {
  margin-left: auto;
  float: none;
}

.fixe {
  clear: both;
  height: 1px;
  font-size: 1px;
  border: none;
  margin: 0;
  padding: 0;
  background: transparent;
}

/* ============================================
   LINKS & TEXT STYLES
   ============================================ */
a { font-family: var(--font-family); transition: color var(--transition); text-underline-offset: 3px; }
a:link, a:visited { color: var(--accent-link); text-decoration: none; }
a:hover, a:active { color: var(--accent-strong); text-decoration: underline; }

a.link_black_blue_b_u { font-family: var(--font-family); }
a.link_black_blue_b_u:link, a.link_black_blue_b_u:visited { color: var(--color-primary-dark); font-weight: 600; text-decoration: none; }
a.link_black_blue_b_u:hover, a.link_black_blue_b_u:active { color: var(--color-primary); font-weight: 600; text-decoration: underline; }

a.link_black_grey_bold { font-family: var(--font-family); }
a.link_black_grey_bold:link, a.link_black_grey_bold:visited { color: var(--color-text); font-weight: 600; text-decoration: none; }
a.link_black_grey_bold:hover, a.link_black_grey_bold:active { color: var(--color-text-secondary); font-weight: 600; text-decoration: none; }

a.link_black_grey_normal { font-family: var(--font-family); }
a.link_black_grey_normal:link, a.link_black_grey_normal:visited { color: var(--color-text); text-decoration: none; }
a.link_black_grey_normal:hover, a.link_black_grey_normal:active { color: var(--color-text-secondary); text-decoration: none; }

a.link_black_grey_small { font-family: var(--font-family); font-size: 0.9em; }
a.link_black_grey_small:link, a.link_black_grey_small:visited { color: var(--color-text); text-decoration: none; }
a.link_black_grey_small:hover, a.link_black_grey_small:active { color: var(--color-text-secondary); text-decoration: none; }

a.link_showarbo { font-family: var(--font-family); }
a.link_showarbo:link, a.link_showarbo:visited { color: var(--color-text); }
a.link_showarbo:hover, a.link_showarbo:active { color: var(--color-primary); text-decoration: underline; }

a.link_add_website { font-family: var(--font-family); }
a.link_add_website:link, a.link_add_website:visited { color: var(--color-danger); font-weight: 600; }
a.link_add_website:hover, a.link_add_website:active { color: #b91c1c; text-decoration: none; font-weight: 600; }

a.link_edit { font-family: var(--font-family); }
a.link_edit:link, a.link_edit:visited { color: var(--color-success); text-decoration: none; }
a.link_edit:hover, a.link_edit:active { color: #059669; text-decoration: none; }

a.link_delete { font-family: var(--font-family); }
a.link_delete:link, a.link_delete:visited { color: var(--color-danger); text-decoration: none; }
a.link_delete:hover, a.link_delete:active { color: #b91c1c; text-decoration: none; }

a.link_black_grey_underline { font-family: var(--font-family); }
a.link_black_grey_underline:link, a.link_black_grey_underline:visited { color: var(--color-text); text-decoration: underline; }
a.link_black_grey_underline:hover, a.link_black_grey_underline:active { color: var(--color-text-secondary); text-decoration: none; }

a.link_small_underline { font-family: var(--font-family); font-size: 0.85em; }
a.link_small_underline:link, a.link_small_underline:visited { color: var(--color-text); text-decoration: underline; }
a.link_small_underline:hover, a.link_small_underline:active { color: var(--color-text-secondary); text-decoration: underline; }

a.link_black_grey { font-family: var(--font-family); }
a.link_black_grey:link, a.link_black_grey:visited { color: var(--ink-2); text-decoration: none; }
a.link_black_grey:hover, a.link_black_grey:active { color: var(--accent-link); text-decoration: underline; }

h1,
h2,
h3 {
  margin: 0;
  padding: 0;
  font-family: var(--font-display);
  color: var(--ink);
  background-color: transparent;
}

h1 {
  font-size: 1.9em;
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.025em;
}

h2 {
  font-size: 1.35em;
  line-height: 1.25;
  font-weight: 750;
  letter-spacing: -0.015em;
}

.text_numbers {
  font-size: 0.8em;
  color: var(--color-primary);
  font-weight: 600;
  background-color: var(--color-primary-bg);
  padding: 1px 6px;
  border-radius: 10px;
  margin-left: 4px;
}

.text_characters_boldgras {
  font-weight: 600;
}

.text_green {
  color: var(--color-success);
}

.text_red {
  color: var(--color-danger);
}

/* Astérisque des champs obligatoires : rouge foncé sur fond clair (6:1, même sur le fond teinté d'un thème), rouge clair en mode sombre */
.text_color_mandatory {
  color: #b91c1c;
}

[data-theme="dark"] .text_color_mandatory {
  color: #f87171;
}

.text_search {
  font-weight: 600;
  color: var(--color-primary-dark);
}

/* ============================================
   FORM ELEMENTS
   ============================================ */
form {
  margin: 0;
  padding: 0;
}

select {
  margin: 0;
  padding: 9px 12px;
  font-family: var(--font-family);
  font-size: 15px;
  color: var(--ink);
  background-color: var(--color-white);
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  transition: border-color var(--transition), box-shadow var(--transition);
}

select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(207, 62, 28, 0.15);
}

input {
  margin: 0;
  padding: 9px 12px;
  font-family: var(--font-family);
  font-size: 15px;
  color: var(--ink);
  background-color: var(--color-white);
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  transition: border-color var(--transition), box-shadow var(--transition);
}

input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(207, 62, 28, 0.15);
}

input[type="checkbox"],
input[type="radio"] {
  padding: 0;
  border-radius: 2px;
}

input.button,
button.button {
  min-height: 44px;
  padding: 10px 22px;
  border: none;
  border-radius: var(--radius);
  background: var(--color-primary);
  color: var(--on-accent);
  font-weight: 650;
  cursor: pointer;
  font-size: inherit;
  font-family: inherit;
  line-height: normal;
  transition: background-color var(--transition), transform var(--transition), box-shadow var(--transition);
}

input.button:hover,
button.button:hover {
  background: var(--color-primary-dark);
}

input.button:disabled,
button.button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.input_text_small {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 80px;
}

.input_text_medium {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 260px;
  max-width: 100%;
}

.input_text_large {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 360px;
  max-width: 100%;
}

.input_text_metas {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 260px;
  max-width: 100%;
}

.textarea_large {
  float: left;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 460px;
  max-width: 100%;
  height: 120px;
  font-family: var(--font-family);
  font-size: 14px;
  padding: 8px 10px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.textarea_large:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(207, 62, 28, 0.15);
}

.textarea_extra_large {
  float: left;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 520px;
  max-width: 100%;
  height: 220px;
  font-family: var(--font-family);
  font-size: 14px;
  padding: 8px 10px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.textarea_extra_large:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(207, 62, 28, 0.15);
}

.textarea_return {
  float: left;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 300px;
  height: 90px;
  font-family: var(--font-family);
  font-size: 14px;
  padding: 8px 10px;
}

/* ============================================
   EXTRA FIELDS
   ============================================ */
.extraField_textarea {
  float: left;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 350px;
  height: 110px;
  font-family: var(--font-family);
  padding: 8px 10px;
}

.extraField_text {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 250px;
}

.extraField_select { }
.extraField_radio { }
.extraField_checkbox { }

.extraField_range {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 250px;
}

.extraField_url_url {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 250px;
}

.extraField_url_anchor {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 250px;
}

.extraField_file_file {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 250px;
}

.extraField_file_title {
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  width: 250px;
}

/* ============================================
   RESET P / IMAGES
   ============================================ */
p {
  margin: 0;
  padding: 0;
}

img {
  border: 0;
  margin: 0;
  padding: 0;
}

img.random_image {
  width: 120px;
  height: 90px;
  margin: 4px 0 4px 50px;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: var(--shadow-card);
}

img.random_image:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: var(--shadow-lg);
}

img.category_image {
  float: left;
  width: 22px;
  height: 22px;
  margin-top: -1px;
  margin-right: 6px;
  padding: 0;
  filter: drop-shadow(0 1px 1px rgba(0,0,0,0.1));
}

img.rss_image {
  display: inline;
  float: right;
  height: 12px;
  margin: 0;
  padding: 0;
  vertical-align: middle;
}

img.website_image {
  float: left;
  width: 120px;
  height: 90px;
  margin: 0 10px 0 0;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  transition: box-shadow var(--transition);
}

img.website_image:hover {
  box-shadow: var(--shadow-md);
}

img.nanoImage {
  float: left;
  margin: 5px 8px 0 0;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

img.mediumImage {
  float: left;
  margin: 0;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

img.flag_image {
  float: left;
  width: 18px;
  height: 12px;
  margin: 2px 0 0 -30px;
  padding: 0;
  border-radius: 2px;
}

img.package_image {
  float: right;
  margin: 0;
  padding: 0;
}

img.aide {
  margin: 0 0 0 7px;
  padding: 0;
  vertical-align: middle;
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* --- Menu un peu plus serré avant de passer en tiroir --- */
@media (max-width: 1240px) {
  .header-row {
    gap: 18px;
  }

  #menutop2 li a {
    padding: 8px 9px;
    font-size: 14.5px;
  }
}

/* --- Tablette (1024px) : menu en tiroir, colonne sous le contenu --- */
@media (max-width: 1024px) {
  .hamburger-btn {
    display: inline-flex;
    position: relative;
    z-index: 130;
  }

  #top2.header-nav {
    flex: 1;
  }

  #menutop2 {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(320px, 86vw);
    padding: calc(var(--header-h) + 8px) 16px 24px;
    background: var(--paper);
    border-left: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    overflow-y: auto;
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1), visibility 0s linear 0.32s;
    z-index: 120;
  }

  body.drawer-open #menutop2 {
    transform: translateX(0);
    visibility: visible;
    transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
  }

  body.drawer-open #top1.site-header {
    z-index: 130;
  }

  #menutop2 ul {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }

  #menutop2 li#account {
    margin-left: 0;
  }

  #menutop2 li a {
    padding: 12px 14px;
    font-size: 16px;
  }

  #menutop2 li#add a {
    margin: 14px 0 0;
    text-align: center;
  }

  .drawer-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(28, 25, 23, 0.42);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 110;
  }

  body.drawer-open .drawer-overlay {
    opacity: 1;
    pointer-events: auto;
  }

  body.drawer-open {
    overflow: hidden;
  }

  #main2 {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
  }

  #middle,
  #left,
  #right {
    grid-column: 1;
    grid-row: auto;
  }

  #middle {
    order: -1;
  }

  #left:empty {
    display: none;
  }

  #left:not(:empty),
  #right {
    margin-top: 40px;
  }

  .home-hero-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 40px;
    padding-top: 44px;
    padding-bottom: 44px;
  }

  .home-about {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  /* Blocs de contenu à largeur fixe : 100 % du parent */
  .column_in,
  .column_in_grey,
  .column_in_thematic,
  .column_in_comment,
  .column_in_comment_grey,
  .column_in_comment_in,
  .column_in_pagination,
  .show_arbo,
  fieldset.column_in,
  p.form,
  div.form,
  .title_h,
  .title_h_1,
  .title_h_2,
  label.infos_select_category,
  #menuin {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .table_user,
  .table_website {
    width: 100%;
    max-width: 100%;
    display: block;
    overflow-x: auto;
  }

  .menucategories,
  .menucategories li.maincat,
  .menucategories li.subcat,
  .menucategories li.keyword,
  .menucategories li.maincat a,
  .menucategories li.subcat a,
  .menucategories li.keyword a {
    width: 100%;
  }
}

/* --- Tablette portrait (768px) --- */
@media (max-width: 768px) {
  #column_in_right_details {
    float: none;
    width: 100%;
    margin: 0 0 10px 0;
  }

  #column_in_details {
    width: 100%;
  }

  .column_in_description_site_category {
    width: 100%;
    padding: 0;
  }

  .menudetails {
    float: none;
    width: 100%;
    border-left: none;
    border-top: 1px solid var(--color-border);
    padding: 12px 0 0 0;
    margin: 10px 0;
  }

  .column_in_choose_left,
  .column_in_choose_right {
    float: none;
    width: 100%;
  }

  .menuchoose_left,
  .menuchoose_right {
    height: auto;
    min-height: 0;
  }

  .menuchoose_left li,
  .menuchoose_right li {
    float: none;
    width: 100%;
  }

  .menuchoose_left li a,
  .menuchoose_right li a {
    height: auto;
    line-height: 1.4;
    padding: 30px 20px;
    background-size: cover;
    background-position: center;
  }

  legend.title {
    width: calc(100% - 14px);
  }

  label.title,
  label.title_details,
  label.title_popup {
    width: 100%;
    text-align: left;
    padding: 0 0 4px 0;
    float: none;
  }

  div.infos,
  div.infos_textarea,
  div.infos_terms,
  div.form_details,
  div.infos_details,
  div.infos_popup {
    width: 100%;
    padding: 0;
    float: none;
  }

  .input_text_small,
  .input_text_medium,
  .input_text_large,
  .input_text_metas,
  .textarea_large,
  .textarea_extra_large,
  .textarea_return,
  .extraField_textarea,
  .extraField_text,
  .extraField_range,
  .extraField_url_url,
  .extraField_url_anchor,
  .extraField_file_file,
  .extraField_file_title {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    float: none;
  }

  fieldset.column_in_popup,
  div.form_popup,
  div.form_error_popup,
  #popup_principal {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  img {
    max-width: 100%;
    height: auto;
  }

  img.website_image {
    max-width: 100%;
    height: auto;
  }
}

/* --- Téléphone (640px) --- */
@media (max-width: 640px) {
  :root {
    --gutter: 16px;
    --header-h: 60px;
  }

  .header-row {
    gap: 10px;
  }

  .brand {
    gap: 8px;
  }

  .brand-mark {
    width: 30px;
    height: 30px;
  }

  .brand-name {
    font-size: 18px;
  }

  .header-tools {
    margin-left: auto;
  }

  .lang-btn {
    min-width: 30px;
    padding: 4px 6px;
  }

  .theme-toggle-btn {
    width: 36px;
    height: 36px;
  }

  .home-hero-grid {
    padding-top: 32px;
    padding-bottom: 36px;
  }

  .home-hero-lead {
    font-size: 17px;
  }

  .home-hero-actions .btn {
    flex: 1 1 100%;
  }

  .ladder {
    padding: 22px 18px 18px;
  }

  .ladder-steps {
    gap: 6px;
  }

  .ladder-num {
    font-size: 18px;
  }

  .ladder-label {
    font-size: 12.5px;
  }

  #top3 {
    padding: 14px 0;
  }

  .search-bar {
    flex-direction: column;
    min-height: 0;
  }

  .search-sep {
    width: auto;
    height: 1px;
    margin: 0 16px;
  }

  .search-field {
    padding: 12px 16px;
  }

  .search-submit {
    min-height: 48px;
  }

  .search-advanced-toggle {
    text-align: left;
  }

  #main2 {
    padding-top: 24px;
    padding-bottom: 48px;
  }

  .home-section {
    padding-top: 40px;
  }

  .latest-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .column_in,
  .column_in_grey {
    padding: 12px;
  }

  input.button,
  button.button {
    width: 100%;
    box-sizing: border-box;
  }
}

/* --- Petit téléphone (380px) --- */
@media (max-width: 380px) {
  .lang-switcher {
    display: none;
  }

  .brand-name {
    font-size: 17px;
  }
}

/* ============================================
   DARK THEME
   Même logique que le clair : rouge pour l'action, bleu pour les liens.
   ============================================ */
[data-theme="dark"] {
  --ink: #f3f5fa;
  --ink-2: #c9cfdd;
  --paper: #12141c;
  --paper-2: #181b26;
  --paper-3: #1f2331;
  --line: #2a2f40;
  --line-strong: #5a6480;
  --accent: #ff6b57;
  --accent-strong: #ff8a7a;
  --accent-link: #8fb8ff;
  --accent-soft: #2a1c22;
  --on-accent: #2a0704;
  --valid: #5fdc9b;
  --valid-soft: #123a2a;

  --color-primary-light: #5a2420;
  --color-text-muted: #9aa3b8;
  --color-danger: #f28b82;
  --color-danger-light: #3b1715;
  --color-warning: #f0b45a;
  --color-orange: #ff9d6c;
  --color-accent-light: #2c2236;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 14px 36px rgba(0, 0, 0, 0.55);
  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .search-bar:focus-within {
  box-shadow: 0 0 0 3px rgba(242, 238, 233, 0.1);
}

[data-theme="dark"] div.search_cat_place select option {
  background-color: var(--paper-2);
  color: var(--ink);
}

[data-theme="dark"] .ladder-step:nth-child(2) .ladder-bar { background: color-mix(in srgb, var(--accent) 32%, var(--paper)); }
[data-theme="dark"] .ladder-step:nth-child(3) .ladder-bar { background: color-mix(in srgb, var(--accent) 64%, var(--paper)); }

[data-theme="dark"] #bottom {
  background: #0f0e0c;
  border-top: 1px solid var(--line);
}

/* Texte sur les fonds d'accent : encre foncée en mode sombre */
[data-theme="dark"] .search-submit,
[data-theme="dark"] input.button,
[data-theme="dark"] button.button,
[data-theme="dark"] .btn-primary,
[data-theme="dark"] #menutop2 li#add a {
  color: var(--on-accent);
}

/* Champs de formulaire en mode sombre */
[data-theme="dark"] select,
[data-theme="dark"] input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]),
[data-theme="dark"] textarea {
  background-color: var(--paper-2);
  color: var(--ink);
  border-color: var(--line-strong);
}

[data-theme="dark"] select:focus,
[data-theme="dark"] input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]):focus,
[data-theme="dark"] textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 24%, transparent);
}

[data-theme="dark"] input::placeholder,
[data-theme="dark"] textarea::placeholder {
  color: var(--color-text-muted);
  opacity: 1;
}

[data-theme="dark"] input[type="checkbox"],
[data-theme="dark"] input[type="radio"] {
  accent-color: var(--accent);
}

/* Changement de thème en douceur */
body,
#principal,
#main1,
#top1,
#top3,
.search-bar {
  transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

/* ============================================================
   CATEGORY CHAIN-SELECT — soumission de site (étape 1)
   ============================================================ */
label.infos_select_category {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-start;
  width: 100%;
}

label.infos_select_category select {
  flex: 0 0 auto;
  min-width: 210px;
  max-width: 280px;
  height: 264px;
  border: 1.5px solid var(--color-border-dark);
  border-radius: var(--radius);
  color-scheme: light;
  background-color: #ffffff !important;
  color: #1c1917 !important;
  padding: 4px 0;
  font-size: 0.88rem;
  cursor: pointer;
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
  box-shadow: var(--shadow-card);
}

label.infos_select_category select option {
  background-color: #ffffff !important;
  color: #1c1917 !important;
}

label.infos_select_category select option:checked,
label.infos_select_category select option:hover {
  background-color: var(--accent) !important;
  color: #ffffff !important;
}

label.infos_select_category select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(207, 62, 28, 0.12);
}

[data-theme="dark"] label.infos_select_category select {
  color-scheme: dark;
  background-color: var(--paper-2) !important;
  color: var(--ink) !important;
  border-color: var(--color-border);
  box-shadow: var(--shadow-card);
}

[data-theme="dark"] label.infos_select_category select option {
  background-color: var(--paper-2) !important;
  color: var(--ink) !important;
}

[data-theme="dark"] label.infos_select_category select option:checked,
[data-theme="dark"] label.infos_select_category select option:hover {
  background-color: var(--accent) !important;
  color: #1c1917 !important;
}

[data-theme="dark"] label.infos_select_category select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(239, 106, 60, 0.2);
}

@media (max-width: 600px) {
  label.infos_select_category select {
    min-width: 100%;
    max-width: 100%;
    height: 200px;
  }
}

/* ============================================================
   SEO QUALITY BARS — description (word-based) + title (pixel-based)
   ============================================================ */
#descriptionQualityBar,
#titleQualityBar {
  position: relative;
  height: 6px;
  background: rgba(128, 128, 128, 0.15);
  border-radius: 4px;
  overflow: visible;
  margin: 8px 0 2px;
}
#descriptionQualityBar { max-width: 365px; }
#titleQualityBar        { max-width: 300px; }

#descriptionQualityFill,
#titleQualityFill {
  height: 100%;
  width: 0%;
  border-radius: 4px;
  background-color: #dc2626;
  -webkit-transition: width 0.3s ease, background-color 0.3s ease;
  transition: width 0.3s ease, background-color 0.3s ease;
}

/* description ticks: 50 words (12.5%), 200 words (50%) — scale 400w */
#descriptionQualityBar::before,
#descriptionQualityBar::after {
  content: '';
  position: absolute;
  top: -2px;
  width: 1px;
  height: 10px;
  background: rgba(128, 128, 128, 0.4);
  border-radius: 1px;
}
#descriptionQualityBar::before { left: 40%; }   /* 800 caractères : minimum */
#descriptionQualityBar::after  { left: 65%; }   /* 1 300 caractères : 1er lien profond */

/* title ticks: 200px (33%), 380px (63%) — scale 600px */
#titleQualityBar::before,
#titleQualityBar::after {
  content: '';
  position: absolute;
  top: -2px;
  width: 1px;
  height: 10px;
  background: rgba(128, 128, 128, 0.4);
  border-radius: 1px;
}
#titleQualityBar::before { left: 33.33%; }
#titleQualityBar::after  { left: 63.33%; }

#descriptionQualityLabel,
#titleQualityLabel,
#sdQualityLabel {
  display: inline-block;
  margin-top: 4px;
  font-size: 0.70rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #dc2626;
  -webkit-transition: color 0.3s ease;
  transition: color 0.3s ease;
  cursor: default;
}

/* short description quality bar */
#sdQualityBar {
  position: relative;
  height: 6px;
  background: rgba(128, 128, 128, 0.15);
  border-radius: 4px;
  overflow: visible;
  margin: 8px 0 2px;
  max-width: 300px;
}
#sdQualityFill {
  height: 100%;
  width: 0%;
  border-radius: 4px;
  background-color: #dc2626;
  transition: width .25s ease, background-color .25s ease;
}
/* ticks: at 20 chars (6.67%) and 80 chars (26.67%) on 300-char scale */
#sdQualityBar::before,
#sdQualityBar::after {
  content: '';
  position: absolute;
  top: -2px;
  width: 2px;
  height: 10px;
  background: rgba(128, 128, 128, 0.4);
  border-radius: 1px;
}
#sdQualityBar::before { left: 6.67%; }
#sdQualityBar::after  { left: 26.67%; }

[data-theme="dark"] #sdQualityBar {
  background: rgba(255, 255, 255, 0.08);
}
[data-theme="dark"] #sdQualityBar::before,
[data-theme="dark"] #sdQualityBar::after {
  background: rgba(255, 255, 255, 0.25);
}

[data-theme="dark"] #descriptionQualityBar,
[data-theme="dark"] #titleQualityBar {
  background: rgba(255, 255, 255, 0.08);
}
[data-theme="dark"] #descriptionQualityBar::before,
[data-theme="dark"] #descriptionQualityBar::after,
[data-theme="dark"] #titleQualityBar::before,
[data-theme="dark"] #titleQualityBar::after {
  background: rgba(255, 255, 255, 0.25);
}

/* ============================================================
   LABEL INFO ICON + COUNTER SECTION — layout
   ============================================================ */

/* Info icon inline in label */
label.title .field-info {
  display: inline-block;
  vertical-align: middle;
  margin-left: 4px;
  position: relative;
  top: -1px;
}

/* Counter section: counters + bar + quality label */
.seo-counter-section {
  clear: left; /* push below float:left textarea */
  margin-top: 6px;
  font-size: 0.82rem;
  color: var(--color-text-secondary);
}

/* ---- Mobile ---- */
@media (max-width: 768px) {
  /* Bars: full width — no desktop max-width cap */
  #descriptionQualityBar,
  #titleQualityBar {
    max-width: 100%;
  }

  /* Counter section: slightly more breathing room */
  .seo-counter-section {
    margin-top: 8px;
    padding-top: 2px;
  }

  /* Quality labels: wrap cleanly */
  #descriptionQualityLabel,
  #titleQualityLabel {
    display: block;
    margin-top: 3px;
  }
}

/* ============================================================
   BACKLINK CHECKER BUTTON + RESULT
   ============================================================ */
.blcheck-btn {
  margin-left: 6px;
  vertical-align: middle;
}
#backlinkCheckResult {
  display: inline-block;
  margin-left: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  vertical-align: middle;
}
.blcheck-ok   { color: #16a34a; }
.blcheck-fail { color: #dc2626; }
.blcheck-info { color: var(--color-text-secondary); }
@media (max-width: 768px) {
  .blcheck-btn { margin-left: 0; margin-top: 6px; }
  #backlinkCheckResult { display: block; margin-left: 0; margin-top: 4px; }
}

/* Anti-spam: honeypot trap — visually hidden, bots still interact with it */
.hp-trap {
  position: absolute;
  left: -9999px;
  top: -9999px;
  opacity: 0;
  height: 0;
  overflow: hidden;
  pointer-events: none;
  tab-size: 0;
}

/* ============================================================
   AJAX LOADING OVERLAY — glassmorphism
   ============================================================ */
#ajax-loading-overlay {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 9999;
  display: none;
  align-items: center;
  gap: 12px;
  padding: 18px 28px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 18px;
  box-shadow:
    0 8px 32px rgba(30, 64, 175, 0.12),
    0 2px 8px rgba(0, 0, 0, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  font-family: var(--font-family);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
  pointer-events: none;
  animation: overlayFadeIn 0.18s ease forwards;
}

@keyframes overlayFadeIn {
  from { opacity: 0; transform: translate(-50%, -46%); }
  to   { opacity: 1; transform: translate(-50%, -50%); }
}

.ajax-spinner {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: var(--color-primary);
  animation: spinnerRotate 0.85s linear infinite;
  transform-origin: center;
  transform-box: fill-box;
}

@keyframes spinnerRotate {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

[data-theme="dark"] #ajax-loading-overlay {
  background: rgba(15, 23, 42, 0.78);
  border-color: rgba(255, 255, 255, 0.07);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.45),
    0 2px 8px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  color: #e2e8f0;
}

/* ============================================================
   ICÔNE INFO — .field-info (remplace icone_info.gif)
   ============================================================ */
.field-info {
  display: inline-block;
  position: relative;
  width: 16px;
  height: 16px;
  vertical-align: middle;
  margin-left: 6px;
  cursor: help;
}

/* Le dessin est porté par ::before : un masque posé sur l'élément rognerait aussi la zone sensible ci-dessous */
.field-info::before {
  content: "";
  position: absolute;
  inset: 0;
  background-color: var(--color-text-muted);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z'/%3E%3C/svg%3E") center/contain no-repeat;
  transition: background-color 0.2s;
}

.field-info:hover::before {
  background-color: var(--color-primary);
}

/* La zone qui déclenche l'infobulle déborde de 8 px autour de l'icône : 32 px à viser au lieu de 16 */
.field-info::after { content: ""; position: absolute; inset: -8px; }

.field-info.aide_description {
  float: left;
  margin: 4px 0 0 8px;
}

/* ============================================================
   FENÊTRE DE MESSAGE : $.alertDialog / $.confirmDialog
   Élément <dialog> ouvert par showModal() (javascript/jquery/jquery.formTool.js) : le voile est son ::backdrop.
   Jamais de display sur dialog seul, il afficherait la fenêtre fermée.
   ============================================================ */
dialog.arfooo-modal {
  border: none;
  color: var(--color-text);
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22), 0 4px 12px rgba(0, 0, 0, 0.1);
  padding: 28px 32px 24px;
  max-width: 420px;
  width: 90%;
}

dialog.arfooo-modal[open] {
  animation: modalIn 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Le défilement dans la fenêtre ou sur le voile ne fait pas défiler la page derrière */
dialog.arfooo-modal:modal {
  overscroll-behavior: contain;
}

dialog.arfooo-modal::backdrop {
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  overflow: hidden;
  overscroll-behavior: contain;
  animation: modalOverlayIn 0.15s ease;
}

@media (prefers-reduced-motion: reduce) {
  dialog.arfooo-modal[open],
  dialog.arfooo-modal::backdrop {
    animation: none;
  }
}

@keyframes modalOverlayIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes modalIn {
  from { opacity: 0; transform: scale(0.92) translateY(8px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.arfooo-modal-msg {
  margin: 0 0 22px;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--color-text);
  text-align: center;
}

.arfooo-modal-actions {
  display: flex;
  justify-content: center;
  margin: 0;
}

.arfooo-modal-btn {
  padding: 9px 32px;
  background: var(--color-primary);
  color: var(--on-accent);
  border: none;
  border-radius: var(--radius);
  font-family: var(--font-family);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

.arfooo-modal-btn:hover {
  background: var(--color-primary-dark);
}

.arfooo-modal-btn:active {
  transform: scale(0.97);
}

[data-theme="dark"] .arfooo-modal {
  background: #1e293b;
  border: 1px solid var(--color-border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* ============================================
   SITE DETAILS PAGE — MODERN LAYOUT (2026)
   ============================================ */

/* Hero */
.site-details-hero {
  clear: both;
  background: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  padding: 4px 0 22px;
  overflow: hidden; /* BFC: contient les floats des enfants */
}

/* Reset fort du h1 legacy (float:left; color:var(--color-white)) dans le hero */
.site-details-hero h1.hero-title {
  float: none;
  display: block;
  color: var(--color-text);
  font-size: clamp(24px, 2.6vw, 32px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  text-wrap: balance;
  margin: 0;
  padding: 0;
  flex: 1 1 auto;
  min-width: 0;
}

.hero-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.hero-title {
  flex: 1 1 auto;
  min-width: 0;
}

.hero-score-badge {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 700;
  /* Texte sombre sur les couleurs vives du score (blanc sur orange : 2,8:1), blanc sur le vert foncé du 5 */
  color: var(--score-ink, #1c1917);
  background: var(--score-color, #94a3b8);
  white-space: nowrap;
  line-height: 1;
}

.hero-score-badge span {
  font-weight: 400;
  font-size: 0.72rem;
}

.hero-rss-link {
  flex: 0 0 auto;
}

.hero-domain {
  margin: 0 0 8px;
}

.hero-domain a {
  font-size: 0.88rem;
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 500;
}

.hero-domain a:hover {
  text-decoration: underline;
}

.hero-description {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  line-height: 1.55;
  margin-bottom: 14px;
  max-height: 3.1em;
  overflow: hidden;
}

.hero-cta-row {
  margin-top: 4px;
}

.hero-visit-btn,
.hero-visit-btn:link,
.hero-visit-btn:visited {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 22px;
  background: var(--color-primary);
  color: var(--on-accent);
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius);
  text-decoration: none;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}

.hero-visit-btn:hover,
.hero-visit-btn:active {
  background: var(--accent-strong);
  box-shadow: 0 4px 16px rgba(207, 62, 28, 0.28);
  transform: translateY(-1px);
  color: var(--on-accent);
  text-decoration: none;
}

.hero-vote-btn,
.hero-vote-btn:link,
.hero-vote-btn:visited {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 22px;
  background: transparent;
  color: var(--color-primary);
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius);
  text-decoration: none;
  letter-spacing: 0.02em;
  border: 2px solid var(--color-primary);
  transition: background var(--transition), color var(--transition), transform var(--transition), box-shadow var(--transition);
}

.hero-vote-btn:hover,
.hero-vote-btn:active {
  background: var(--color-primary);
  color: var(--on-accent);
  box-shadow: 0 4px 16px rgba(207, 62, 28, 0.22);
  transform: translateY(-1px);
  text-decoration: none;
}

/* ============================================================
   SVG STAR RATING — Popup commentaire
   ============================================================ */
.arf-stars {
  display: inline-flex;
  gap: 5px;
  align-items: center;
}

.arf-star {
  cursor: pointer;
  line-height: 0;
  transition: transform 0.13s;
}

/* Les étoiles sont des boutons (clavier, lecteur d'écran) : l'habillage d'un bouton est retiré, le cadre du focus gardé */
button.arf-star { padding: 0; border: 0; background: none; font: inherit; line-height: 0; border-radius: 4px; }
button.arf-star:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 2px; }


.arf-star svg {
  display: block;
  width: 30px;
  height: 30px;
  pointer-events: none;
}

/* Couleur par défaut du polygon (gris) */
.arf-star svg polygon {
  fill: #cbd5e1;
  transition: fill 0.13s;
}

[data-theme="dark"] .arf-star svg polygon {
  fill: #374151;
}

/* Hover et sélection → jaune */
.arf-star.hover svg polygon,
.arf-star.selected svg polygon {
  fill: #f59e0b;
}

.arf-star.hover {
  transform: scale(1.18);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.hero-meta-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 9px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  font-size: 0.77rem;
  color: var(--color-text-muted);
  text-decoration: none;
  transition: all var(--transition);
}

a.hero-meta-tag:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

/* Action buttons row */
.site-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.site-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition);
  line-height: 1;
}

.site-action-btn.btn-primary {
  background: var(--color-primary);
  color: var(--on-accent);
  border-color: var(--color-primary);
}

.site-action-btn.btn-primary:hover {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
  color: var(--on-accent);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.site-action-btn.btn-secondary {
  background: var(--color-white);
  color: var(--color-text);
  border-color: var(--color-border);
}

.site-action-btn.btn-secondary:hover {
  background: var(--color-bg);
  border-color: var(--color-border-dark);
  color: var(--color-text);
  transform: translateY(-1px);
}

/* Main grid layout */
.site-details-grid {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  padding: 20px;
  align-items: start;
}

/* Cards */
.site-details-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  margin-bottom: 16px;
}

.site-details-card:last-child {
  margin-bottom: 0;
}

.site-details-card-header {
  /* Titre de niveau 2 depuis novembre 2026 : marges et police des grands titres neutralisées */
  margin: 0;
  font-family: inherit;
  line-height: inherit;
  text-wrap: wrap;
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-border);
  font-weight: 700;
  font-size: 0.78rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--color-bg-warm);
}

.site-details-card-body {
  padding: 16px;
}

/* Description */
.site-description {
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--color-text);
}

/* Meta rows inside cards */
.site-meta-row {
  display: flex;
  align-items: flex-start;
  padding: 9px 0;
  border-bottom: 1px solid var(--color-border);
  gap: 12px;
  font-size: 0.875rem;
}

.site-meta-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.site-meta-row:first-child {
  padding-top: 0;
}

.site-meta-label {
  width: 130px;
  min-width: 130px;
  color: var(--color-text-muted);
  font-weight: 500;
  padding-top: 1px;
}

.site-meta-value {
  color: var(--color-text);
  flex: 1;
}

/* Keywords */
.keyword-tag {
  display: inline-block;
  padding: 3px 10px;
  background: var(--color-primary-bg);
  color: var(--color-primary);
  border-radius: 20px;
  font-size: 0.78rem;
  text-decoration: none;
  margin: 2px;
  border: 1px solid var(--color-primary-light);
  transition: all var(--transition);
}

.keyword-tag:hover {
  background: var(--color-primary);
  color: var(--on-accent);
}

/* Gallery */
.site-gallery-nano-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.site-gallery-nano-grid img.nanoImage {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color var(--transition);
}

.site-gallery-nano-grid img.nanoImage:hover {
  border-color: var(--color-primary);
}

/* Thumbnail (single image) */
.site-thumbnail {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
  margin-bottom: 12px;
  box-shadow: var(--shadow);
}

/* Score panel sidebar */
.site-score-panel {
  position: sticky;
  top: 16px;
}

.site-score-panel .site-details-card {
  margin-bottom: 0;
}

/* Score circle */
.score-circle-wrap {
  text-align: center;
  padding: 20px 16px 14px;
}

.score-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: conic-gradient(var(--score-color, #94a3b8) calc(var(--score-pct, 0) * 1%), var(--color-border) 0);
  position: relative;
  margin-bottom: 8px;
}

.score-circle::before {
  content: '';
  position: absolute;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: var(--color-white);
}

.score-circle-inner {
  position: relative;
  z-index: 1;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-text);
  line-height: 1;
}

.score-circle-inner small {
  font-size: 0.65rem;
  font-weight: 400;
  color: var(--color-text-muted);
  display: block;
}

.score-stars-display {
  font-size: 1.2rem;
  margin-bottom: 4px;
  line-height: 1;
}

.score-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
}

/* Score color variants */
.score-color-0 { --score-color: #94a3b8; }
.score-color-1 { --score-color: #ef4444; }
.score-color-2 { --score-color: #f97316; }
.score-color-3 { --score-color: #eab308; }
.score-color-4 { --score-color: #22c55e; }
.score-color-5 { --score-color: #15803d; --score-ink: #ffffff; }

/* Score breakdown */
/* PageRank calculé par Super Webmaster */
.sw-pagerank {
  padding: 14px 16px 16px;
  border-top: 1px solid var(--color-border);
  text-align: center;
}

.sw-pagerank__value {
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.1;
  color: var(--color-text);
  font-variant-numeric: tabular-nums;
}

.sw-pagerank__value small {
  margin-left: 2px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text-muted);
}

.sw-pagerank a.sw-pagerank__by,
.sw-pagerank a.sw-pagerank__by:visited {
  display: inline-block;
  margin-top: 4px;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.sw-pagerank a.sw-pagerank__by:hover {
  color: var(--color-primary);
}

.score-breakdown {
  padding: 4px 14px 14px;
  border-top: 1px solid var(--color-border);
}

.score-section-title {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  margin: 12px 0 8px;
}

/* Score total display */
.score-total-pts {
  font-weight: 700;
  color: var(--color-primary);
}

/* Score category block */
.score-cat-block {
  margin-bottom: 10px;
}

.score-cat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 3px 0 3px;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 4px;
}

.score-cat-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
}

.score-cat-pts {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--color-primary);
  white-space: nowrap;
}

.score-item-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 2px 0;
  font-size: 0.78rem;
}

.score-item-label {
  flex: 1;
  color: var(--color-text-secondary);
}

.score-item-pts {
  font-size: 0.72rem;
  font-weight: 600;
  min-width: 26px;
  text-align: right;
}

.score-item-pts.ok { color: #15803d; }
[data-theme="dark"] .score-item-pts.ok { color: #4ade80; }
.score-item-pts.ko { color: var(--color-text-muted); }

/* E-E-A-T section (kept for legacy compatibility) */
.eeat-section {
  padding: 8px 14px 14px;
  border-top: 1px solid var(--color-border);
}

.eeat-item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
  font-size: 0.8rem;
  color: var(--color-text-secondary);
}

.eeat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  flex-shrink: 0;
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 1;
}

/* Coche et croix sur leur pastille claire : verts et rouges foncés (6,4:1 et 5,2:1, contre 3:1 et 3,9:1) */
.eeat-icon.ok {
  background: #dcfce7;
  color: #166534;
}

.eeat-icon.ko {
  background: #fee2e2;
  color: #b91c1c;
}

/* Critère pas encore mesuré (code HTTP d'une fiche jamais contrôlée) : pastille neutre, ni coche ni croix */
.eeat-icon.pending {
  background: var(--color-bg);
  color: var(--color-text-muted);
  border: 1px dashed var(--color-border-dark);
}
.score-item-pts.pending { color: var(--color-text-muted); }

/* Google stats sidebar */
.google-stats-section {
  padding: 8px 14px 14px;
  border-top: 1px solid var(--color-border);
}

.google-stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 0.8rem;
  color: var(--color-text-secondary);
}

.google-stat-row:last-child {
  border-bottom: none;
}

.google-stat-val {
  color: var(--color-text);
  font-weight: 600;
}

/* Sidebar actions */
.sidebar-actions {
  padding: 8px 14px 14px;
  border-top: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.sidebar-action-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: var(--radius);
  font-size: 0.85rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--color-text);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  transition: all var(--transition);
  cursor: pointer;
}

.sidebar-action-link:hover {
  background: var(--color-primary-bg);
  border-color: var(--color-primary-light);
  color: var(--color-primary);
}

.sidebar-action-link.primary-action {
  background: var(--color-primary);
  color: var(--on-accent);
  border-color: var(--color-primary);
  font-weight: 600;
}

.sidebar-action-link.primary-action:hover {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
  color: var(--on-accent);
}

/* GEO tags */
.geo-tags-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.geo-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: var(--color-accent-light);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 20px;
  font-size: 0.78rem;
  color: var(--color-accent);
  text-decoration: none;
  transition: all var(--transition);
}

.geo-tag:hover {
  background: var(--color-accent);
  color: #fff;
  border-color: var(--color-accent);
}

.geo-tag img {
  width: 14px;
  height: 10px;
  object-fit: cover;
}

/* Comments */
.comments-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.comment-item {
  background: var(--color-bg-warm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 14px 16px;
}

.comment-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  flex-wrap: wrap;
  gap: 6px;
}

.comment-author {
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--color-text);
}

.comment-date {
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

.comment-rating {
  font-size: 0.85rem;
  color: #fbbf24;
  margin-bottom: 6px;
}

.comment-text {
  font-size: 0.875rem;
  line-height: 1.65;
  color: var(--color-text-secondary);
}

/* Related sites */
.related-sites-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.related-site-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 12px 14px;
  transition: all var(--transition);
}

.related-site-card:hover {
  border-color: var(--color-primary-light);
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}

.related-site-card a {
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--color-primary);
  text-decoration: none;
  display: block;
  margin-bottom: 5px;
}

.related-site-card a:hover {
  text-decoration: underline;
}

.related-site-desc {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

/* Full-width section blocks */
.site-section-block {
  margin: 0 20px 20px;
}

.site-section-block .site-details-card {
  margin-bottom: 0;
}

/* RSS items */
.rss-item {
  padding: 10px 0;
  border-bottom: 1px solid var(--color-border);
}

.rss-item:last-child {
  border-bottom: none;
}

/* Responsive: stack at 768px */
@media (max-width: 768px) {
  .site-details-grid {
    grid-template-columns: 1fr;
    padding: 12px;
    gap: 12px;
  }

  .site-score-panel {
    position: static;
    order: 1;
  }

  .site-details-hero {
    padding: 4px 0 18px;
  }

  .site-details-hero h1.hero-title {
    font-size: 1.2rem;
  }

  .site-section-block {
    margin: 0 12px 12px;
  }

  .site-meta-label {
    width: 110px;
    min-width: 110px;
  }

  .related-sites-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .site-details-hero h1.hero-title {
    font-size: 1.1rem;
  }

  .score-circle {
    width: 76px;
    height: 76px;
  }

  .score-circle::before {
    width: 58px;
    height: 58px;
  }

  .score-circle-inner {
    font-size: 1.25rem;
  }
}

/* ============================================================
   OPENING HOURS WIDGET (submit form)
   ============================================================ */
.oh-table {
  border-collapse: collapse;
  width: 100%;
  max-width: 520px;
  margin-bottom: 10px;
}
.oh-table tr {
  border-bottom: 1px solid var(--color-border);
}
.oh-table tr:last-child {
  border-bottom: none;
}
.oh-day-cell {
  padding: 7px 14px 7px 0;
  width: 145px;
  white-space: nowrap;
  vertical-align: middle;
}
.oh-day-cell input[type="checkbox"] {
  margin-right: 8px;
  cursor: pointer;
  accent-color: var(--color-primary);
}
.oh-day-name {
  font-size: 0.88rem;
  cursor: pointer;
  user-select: none;
}
.oh-times-cell {
  padding: 7px 0;
  vertical-align: middle;
}
.oh-from,
.oh-to {
  padding: 4px 6px;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius);
  background: var(--color-white);
  color: var(--color-text);
  font-size: 0.85rem;
  cursor: pointer;
}
.oh-sep {
  margin: 0 5px;
  color: var(--color-text-muted);
  font-size: 0.85rem;
}
.oh-closed-badge {
  display: inline-block;
  padding: 2px 10px;
  background: var(--color-border);
  color: var(--color-text-muted);
  border-radius: var(--radius);
  font-size: 0.78rem;
  font-style: italic;
}
.oh-row-closed .oh-day-name {
  color: var(--color-text-muted);
}
.oh-copy-btn {
  margin-top: 8px;
  padding: 5px 14px;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius);
  background: var(--color-white);
  color: var(--color-text-muted);
  font-size: 0.8rem;
  cursor: pointer;
  transition: border-color .15s, color .15s;
}
.oh-copy-btn:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

/* details page: opening hours display table */
.oh-display-table {
  border-collapse: collapse;
  font-size: 0.87rem;
  width: 100%;
  max-width: 340px;
}
.oh-display-table td {
  padding: 2px 10px 2px 0;
  vertical-align: top;
}
.oh-display-day {
  font-weight: 500;
  width: 105px;
  white-space: nowrap;
}
.oh-display-today {
  color: var(--color-primary);
  font-weight: 600;
}
.oh-display-closed-txt {
  color: var(--color-text-muted);
  font-style: italic;
}

[data-theme="dark"] .oh-from,
[data-theme="dark"] .oh-to {
  border-color: var(--color-border);
}
[data-theme="dark"] .oh-copy-btn {
  border-color: var(--color-border);
}

/* ── Liens profonds (formulaire de soumission et fiche) ─────────────── */
.deeplinks-help { margin: 0 0 8px; font-size: 0.85rem; color: var(--color-text-muted); }
.deeplink-row { display: grid; grid-template-columns: 28px 1fr 1fr; gap: 6px 8px; align-items: center; margin-bottom: 8px; }
.deeplink-row input { width: 100%; box-sizing: border-box; }
.deeplink-num { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; background: var(--color-primary); color: #fff; font-size: 0.8rem; font-weight: 600; }
.deeplink-status { grid-column: 2 / -1; font-size: 0.8rem; color: var(--color-success); }
.deeplink-locked .deeplink-num { background: var(--color-border-dark); }
.deeplink-locked .deeplink-status { color: var(--color-text-muted); }
.deeplink-locked input:disabled { opacity: 0.5; cursor: not-allowed; }
@media (max-width: 640px) {
  .deeplink-row { grid-template-columns: 28px 1fr; }
  .deeplink-row input[name$="Anchor"] { grid-column: 2; }
}
.site-deep-links { list-style: none; margin: 0; padding: 0; }
.site-deep-links li { padding: 6px 0; border-bottom: 1px solid var(--color-border); }
.site-deep-links li:last-child { border-bottom: 0; }

/* ── Logo et SIRET (formulaire de soumission) ───────────────────────── */
.logo-field { display: flex; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
.logo-preview { width: 72px; height: 72px; object-fit: contain; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-white); padding: 4px; }
.logo-help { font-size: 0.8rem; color: var(--color-text-muted); margin-top: 4px; }
.logo-delete { display: inline-flex; gap: 6px; align-items: center; font-size: 0.85rem; margin-top: 6px; }
.siret-status { font-size: 0.85rem; margin-top: 6px; min-height: 1.2em; color: var(--color-text-muted); }
.siret-status.ok { color: var(--color-success); }
.siret-status.warn { color: var(--color-warning); }

/* ── Fiche : logo, badge, mention de vérification ───────────────────── */
.site-logo { width: 96px; height: 96px; object-fit: contain; border-radius: var(--radius); background: #fff; padding: 6px; border: 1px solid var(--color-border); }
.verified-badge { display: inline-flex; align-items: center; gap: 4px; font-size: 0.8rem; font-weight: 600; color: var(--color-success); border: 1px solid currentColor; border-radius: 999px; padding: 2px 10px; }
.site-provenance { font-size: 0.85rem; color: var(--color-text-muted); margin-top: 8px; }

/* Modification de fiche en attente de modération */
.pending-notice { margin: 0 0 14px; padding: 10px 14px; border: 1px solid rgba(183, 121, 31, 0.35); background: rgba(245, 158, 11, 0.12); border-radius: var(--radius); }

/* =====================================================================
   Espace webmaster : liste des fiches, statistiques, badge (17/11/2026)
   ===================================================================== */
.wm-page { max-width: 980px; }
.wm-head { margin: 4px 0 24px; }
.wm-head h1 { margin: 0 0 6px; font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.wm-head-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.wm-kicker { margin: 0 0 4px; font-size: 13px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--color-text-muted); }
.wm-head-links { margin: 0; color: var(--ink-2); font-size: 15px; }
.wm-h2 { margin: 0 0 14px; font-size: 1.2rem; }
.wm-note { padding: 12px 16px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--paper-2); }
.wm-help { color: var(--color-text-muted); font-size: 14px; }

.wm-tag { display: inline-block; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--line-strong); font-size: 12px; font-weight: 700; line-height: 1.5; color: var(--ink-2); }
.wm-tag-ok { border-color: transparent; background: var(--valid-soft); color: var(--valid); }
.wm-tag-wait { border-color: transparent; background: var(--paper-3); color: var(--ink-2); }
.wm-tag-offer { border-color: transparent; background: var(--ink); color: var(--paper); }
.wm-tag-featured { border-color: transparent; background: var(--accent-soft); color: var(--accent-link); }

.wm-sites { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 12px; }
.wm-site { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 24px; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.wm-site-title { margin: 0; font-size: 1.1rem; overflow-wrap: anywhere; }
.wm-site-url { margin: 2px 0 8px; color: var(--valid); font-size: 14px; overflow-wrap: anywhere; }
.wm-site-tags { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.wm-site-stats { margin: 0; display: flex; gap: 20px; align-self: center; }
.wm-site-stats div { text-align: right; }
.wm-site-stats dt { font-size: 12px; color: var(--color-text-muted); }
.wm-site-stats dd { margin: 0; font-size: 1.35rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--ink); }
.wm-site-actions { grid-column: 1 / -1; margin: 6px 0 0; padding-top: 12px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 15px; }
.wm-action-main { font-weight: 700; }
.wm-site-actions a.wm-action-danger { color: var(--color-text-muted); margin-left: auto; }
.wm-site-actions a.wm-action-danger:hover { color: var(--accent-link); }
.wm-empty { padding: 28px; border: 1px dashed var(--line-strong); border-radius: var(--radius-lg); text-align: center; }

.wm-kpis, .wm-months, .wm-badge { margin: 0 0 32px; }
.wm-kpi-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.wm-kpi { display: flex; flex-direction: column; gap: 4px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.wm-kpi-num { font-size: 2.2rem; font-weight: 800; line-height: 1.1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; color: var(--ink); }
.wm-kpi-label { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink); }
.wm-kpi-help { font-size: 13px; color: var(--color-text-muted); line-height: 1.45; }
.wm-alltime { margin: 10px 0 0; font-size: 14px; color: var(--ink-2); }

.wm-dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; flex: none; }
.wm-dot-views, .wm-bar-views { background: var(--ink-2); }
.wm-dot-clicks, .wm-bar-clicks { background: var(--accent); }
.wm-dot-referrals, .wm-bar-referrals { background: var(--valid); }

.wm-chart { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 6px; align-items: end; height: 190px; padding: 14px 12px 0; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.wm-chart-col { display: flex; flex-direction: column; align-items: stretch; height: 100%; min-width: 0; }
.wm-chart-bars { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 2px; border-bottom: 1px solid var(--line-strong); }
.wm-bar { display: block; width: 28%; max-width: 12px; min-height: 0; border-radius: 3px 3px 0 0; }
.wm-chart-label { padding: 6px 0 8px; font-size: 11px; text-align: center; color: var(--color-text-muted); white-space: nowrap; overflow: hidden; }
.wm-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 10px 0 16px; font-size: 14px; color: var(--ink-2); }
.wm-legend span { display: inline-flex; align-items: center; gap: 8px; }
.wm-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.wm-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.wm-table th, .wm-table td { padding: 9px 14px; border-bottom: 1px solid var(--line); text-align: right; background: transparent; color: var(--ink); font-size: 15px; }
.wm-table th { text-transform: none; letter-spacing: normal; }
.wm-table th:first-child { text-align: left; font-weight: 600; }
.wm-table thead th { background: var(--paper-2); font-size: 13px; font-weight: 700; color: var(--ink-2); }
.wm-table tbody tr:last-child th, .wm-table tbody tr:last-child td { border-bottom: 0; }

.wm-badge-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 14px 0; }
.wm-badge-item { display: flex; flex-direction: column; gap: 8px; }
.wm-badge-item label { font-weight: 700; }
.wm-badge-preview { display: flex; align-items: center; justify-content: center; min-height: 92px; border-radius: var(--radius); border: 1px solid var(--line); }
.wm-badge-preview-light { background: #ffffff; }
.wm-badge-preview-dark { background: #1c1917; }
.wm-code { width: 100%; max-width: 100%; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 12.5px; line-height: 1.5; resize: vertical; }
.wm-copy { align-self: flex-start; min-height: 40px; padding: 8px 16px; font-size: 15px; }

/* =====================================================================
   Page des offres
   ===================================================================== */
.offers-head { max-width: 820px; margin: 4px 0 26px; }
.offers-head h1 { margin: 0 0 10px; font-size: clamp(1.8rem, 3vw, 2.4rem); }
.offers-lead { margin: 0; font-size: 1.1rem; color: var(--ink-2); }
.offers-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
.offers-grid.offers-1 { grid-template-columns: minmax(0, 420px); }
.offers-grid.offers-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.offers-grid.offers-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.offer-card { position: relative; display: flex; flex-direction: column; padding: 22px 20px 20px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.offer-card-highlight { border: 2px solid var(--accent); padding: 21px 19px 19px; }
.offer-flag { position: absolute; top: -12px; left: 18px; margin: 0; padding: 2px 10px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 800; }
.offer-name { margin: 0; font-size: 1.15rem; }
.offer-price { margin: 8px 0 2px; font-size: 2.3rem; font-weight: 800; line-height: 1.1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; color: var(--ink); }
.offer-price span { font-size: 14px; font-weight: 600; letter-spacing: 0; color: var(--color-text-muted); }
.offer-validation { margin: 0 0 10px; font-size: 14px; font-weight: 700; color: var(--valid); }
.offer-pitch { margin: 0 0 14px; font-size: 15px; color: var(--ink-2); min-height: 4.5em; }
.offer-features { list-style: none; margin: 0 0 18px; padding: 14px 0 0; border-top: 1px solid var(--line); display: grid; gap: 9px; flex: 1; align-content: start; }
.offer-features li { position: relative; padding-left: 24px; font-size: 14px; line-height: 1.45; }
.offer-features li::before { content: ""; position: absolute; left: 0; top: 2px; width: 16px; height: 16px; background-color: currentColor; -webkit-mask: var(--offer-icon) center / contain no-repeat; mask: var(--offer-icon) center / contain no-repeat; }
.offer-features li.is-ok { color: var(--ink); }
.offer-features li.is-ok::before { color: var(--valid); --offer-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E"); }
.offer-features li.is-no { color: var(--color-text-muted); }
.offer-features li.is-no::before { --offer-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M6 12h12'/%3E%3C/svg%3E"); }
.offer-cta { width: 100%; }
.offers-notes { max-width: 760px; margin: 28px 0 0; font-size: 15px; color: var(--ink-2); }
.offers-notes p { margin: 0 0 10px; }
.offers-notes strong { color: var(--ink); }

/* =====================================================================
   Paiement
   ===================================================================== */
.pay-page { max-width: 760px; }
.pay-page h1 { margin: 4px 0 20px; }
.pay-alert { margin: 0 0 18px; padding: 12px 16px; border-radius: var(--radius); border: 1px solid var(--accent); background: var(--accent-soft); color: var(--ink); }
.pay-alert-info { border-color: var(--line-strong); background: var(--paper-2); }
.pay-alert-ok { border-color: transparent; background: var(--valid-soft); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.pay-alert-ok p { margin: 0; }
.pay-form { display: grid; gap: 22px; }
.pay-step { margin: 0; padding: 0; border: 0; min-width: 0; }
.pay-step legend { padding: 0; margin-bottom: 12px; font-size: 1.1rem; font-weight: 750; color: var(--ink); background: none; }
.pay-choices { display: grid; gap: 10px; }
.pay-choices-methods { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pay-choice { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--paper); cursor: pointer; transition: border-color var(--transition), background-color var(--transition); }
.pay-choice:hover { border-color: var(--ink-2); }
.pay-choice:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.pay-choice input { margin-top: 4px; accent-color: var(--accent); width: 18px; height: 18px; flex: none; }
.pay-choice-body { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; width: 100%; }
.pay-choice-name { font-weight: 750; color: var(--ink); }
.pay-choice-price { font-weight: 800; font-variant-numeric: tabular-nums; color: var(--ink); }
.pay-choice-desc { grid-column: 1 / -1; font-size: 14px; color: var(--ink-2); }
.pay-test { grid-column: 1 / -1; justify-self: start; margin-top: 4px; padding: 1px 8px; border-radius: 999px; background: var(--paper-3); font-size: 12px; font-weight: 700; color: var(--ink-2); }
.pay-help { margin: 8px 0 0; font-size: 14px; color: var(--color-text-muted); }
.pay-submit { justify-self: start; }

/* =====================================================================
   À la une, avis vérifiés
   ===================================================================== */
.site-badge-featured { background: var(--accent-soft); color: var(--accent-link); }
.featured-chip { display: inline-block; margin-right: 6px; padding: 0 8px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 11px; font-weight: 800; letter-spacing: 0.02em; text-transform: none; }
.latest-card-featured { border-color: var(--accent); }
.comment-verified { display: inline-flex; align-items: center; gap: 4px; margin-left: 8px; padding: 0 8px; border-radius: 999px; background: var(--valid-soft); color: var(--valid); font-size: 12px; font-weight: 700; }
.comment-verified::before { content: "✓"; }
.review-intro, .review-state { margin: 0 0 14px; color: var(--ink-2); }
.review-state-actions { margin: 14px 0; }
.review-state-small { font-size: 14px; color: var(--color-text-muted); }
.popup-help { display: block; margin-top: 4px; font-size: 13px; color: var(--color-text-muted); }

@media (max-width: 1024px) {
  .offers-grid, .offers-grid.offers-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .offers-grid, .offers-grid.offers-2, .offers-grid.offers-3 { grid-template-columns: 1fr; }
  .offer-pitch { min-height: 0; }
  .wm-site { grid-template-columns: 1fr; }
  .wm-site-stats { justify-content: space-between; }
  .wm-site-stats div { text-align: left; }
  .wm-kpi-grid { grid-template-columns: 1fr; }
  .wm-kpi { flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
  .wm-kpi-num { font-size: 1.8rem; }
  .wm-kpi-help { flex-basis: 100%; }
  .wm-badge-grid { grid-template-columns: 1fr; }
  .wm-chart { height: 150px; gap: 3px; padding: 10px 6px 0; }
  .wm-bar { width: 30%; }
  .wm-chart-label { font-size: 10px; }
  .pay-choices-methods { grid-template-columns: 1fr; }
  .wm-head-row .btn { width: 100%; }
}

/* Mon espace : fiche à corriger, fiche non retenue */
.wm-tag-fix { border-color: transparent; background: var(--accent-soft); color: var(--accent-link); }
.wm-tag-refused { border-color: transparent; background: var(--paper-3); color: var(--color-text-muted); }
.wm-fix, .wm-refused { margin-top: 12px; padding: 14px 16px; border-radius: var(--radius); background: var(--accent-soft); }
.wm-refused { background: var(--paper-2); }
.wm-fix-title { margin: 0 0 4px; font-weight: 700; color: var(--ink); }
.wm-fix-reason { margin: 0 0 10px; color: var(--ink-2); }
.wm-refused .wm-fix-reason { margin-bottom: 0; }
.wm-fix-btn { min-height: 40px; padding: 8px 16px; font-size: 15px; }

/* Paiement : accord de non-remboursement */
.pay-consent { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--paper-2); font-size: 14px; color: var(--ink-2); cursor: pointer; }
.pay-consent input { margin-top: 3px; width: 18px; height: 18px; flex: none; accent-color: var(--accent); }

/* Apparence : logo et illustrations réglés dans l'administration */
.brand-logo { display: block; height: 40px; width: auto; max-width: 180px; object-fit: contain; }
.home-hero-art { display: flex; align-items: center; justify-content: center; }
.home-hero-art img { display: block; width: 100%; max-width: 420px; height: auto; max-height: 380px; object-fit: contain; }
.appearance-empty-art, .appearance-404-art { display: block; width: 100%; max-width: 280px; height: auto; margin: 0 auto 16px; }
@media (max-width: 768px) {
  .home-hero-art img { max-width: 240px; max-height: 220px; }
}

/* ============================================
   FINITIONS (17/11/2026)
   ============================================ */
/* Cases et boutons radio aux couleurs du thème */
input[type="checkbox"], input[type="radio"] { accent-color: var(--accent); }

/* Icônes des boutons de la fiche */
.btn-icon { width: 14px; height: 14px; flex-shrink: 0; vertical-align: -2px; }
.hero-visit-btn, .hero-vote-btn { display: inline-flex; align-items: center; gap: 8px; }

/* Connexion et inscription : deux cartes, libellés au-dessus des champs */
.auth-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
  margin-top: 8px;
}
.auth-card {
  padding: 28px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}
.auth-card--new { background: var(--paper-2); }
.auth-card .title_h { margin: 0 0 6px; }
.auth-card .title_h h1,
.auth-card .title_h h2 { font-size: 1.6rem; margin: 0; }
.auth-card fieldset.column_in {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}
.auth-card .form { display: block; margin: 0 0 16px; padding: 0; }
.auth-card .form label.title {
  display: block;
  width: auto;
  float: none;
  margin: 0 0 6px;
  padding: 0;
  text-align: left;
  font-weight: 650;
  color: var(--ink);
}
.auth-card .form label.title:empty,
.auth-card .form label.title[for=""] { display: none; }
.auth-card .form .infos { margin: 0; padding: 0; float: none; width: auto; color: var(--ink-2); }
.auth-card input.input_text_large { width: 100%; max-width: none; }
.auth-card input.button { width: 100%; justify-content: center; }
@media (max-width: 860px) {
  .auth-grid { grid-template-columns: 1fr; }
  .auth-card { padding: 22px 18px; }
}

/* Page 404 */
.notfound {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 40px;
  align-items: center;
  max-width: 980px;
  padding: 24px 0 40px;
}
.notfound--art { grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); }
.notfound-code {
  margin: 0 0 8px;
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--accent);
}
.notfound h1 { margin: 0 0 12px; font-size: clamp(1.8rem, 3.6vw, 2.6rem); line-height: 1.12; letter-spacing: -0.025em; text-wrap: balance; }
.notfound-lead { max-width: 56ch; margin: 0 0 24px; font-size: 1.08rem; line-height: 1.6; color: var(--ink-2); }
.notfound-search {
  display: flex;
  gap: 8px;
  max-width: 520px;
  margin: 0 0 20px;
}
.notfound-search input[type="search"] {
  flex: 1;
  min-width: 0;
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
  font: inherit;
}
.notfound-search input[type="search"]:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.notfound-search .button { height: 46px; padding: 0 20px; }
.notfound-links { display: flex; flex-wrap: wrap; gap: 20px; margin: 0; }
.notfound-links a { font-weight: 650; color: var(--accent-link); text-decoration: underline; text-underline-offset: 3px; }
.notfound .appearance-404-art { width: 100%; max-width: 360px; justify-self: center; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 760px) {
  .notfound--art { grid-template-columns: 1fr; }
  .notfound .appearance-404-art { max-width: 220px; order: -1; }
  .notfound-search { flex-direction: column; }
}

@media (max-width: 760px) { .notfound-search input[type="search"] { flex: none; } }
/* Connexion : espaces réguliers entre les lignes du formulaire */
.auth-card .form .infos br { display: none; }

/* Lien « Signaler un problème » de la fiche : discret, mais trouvable */
/* Cases d'ouverture de la fiche (partenariats, articles invités, bientôt à vendre) et bouton de contact */
.site-openings { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 10px 0 0; }
.site-openings-list { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.site-openings-list li { padding: 3px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper-2); font-size: 0.82rem; color: var(--ink-2); }
.site-openings-contact { font-size: 0.85rem; font-weight: 600; color: var(--accent-link); text-decoration: underline; text-underline-offset: 3px; }
.site-openings-contact:hover { color: var(--accent-strong); }
.site-report { margin: 4px 0 0; font-size: 0.85rem; }
.site-report a { color: var(--color-text-muted); text-decoration: underline; text-underline-offset: 3px; }
.site-report a:hover { color: var(--accent-link); }

/* Fenêtres : mention des champs obligatoires sur une ligne, bouton Annuler secondaire */
.popup-required-note { margin: 0 0 14px; font-size: 0.85rem; color: var(--color-text-muted); }
.arfooo-popup-body input.button.close { background: var(--paper); color: var(--ink); border: 1px solid var(--line-strong); box-shadow: none; }
.arfooo-popup-body input.button.close:hover { background: var(--paper-2); color: var(--ink); }

/* --- Inscription : catégorie trouvée d'après l'adresse du site */
.category-finder { margin: 18px 0 6px; padding: 18px 20px; background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.category-finder-label { display: block; font-weight: 600; color: var(--ink); margin-bottom: 8px; font-size: 1.02rem; }
.category-finder-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.category-finder-row input { flex: 1 1 260px; min-width: 0; max-width: none; }
.category-finder-help { margin: 8px 0 0; font-size: 0.86rem; color: var(--ink-2); }
.category-finder-result { margin-top: 12px; font-size: 0.92rem; color: var(--ink-2); }
.category-finder-result:empty { display: none; }
.category-finder-result.is-empty { color: var(--ink-2); font-style: italic; }
.category-finder-intro { margin: 0 0 8px; color: var(--ink); }
.category-finder-choices { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.category-finder-choice { font: inherit; text-align: left; cursor: pointer; padding: 7px 12px; border-radius: var(--radius); border: 1px solid var(--line-strong); background: var(--paper); color: var(--ink); line-height: 1.35; }
.category-finder-choice:hover { border-color: var(--accent); }
.category-finder-choice:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.category-finder-choice.is-selected { border-color: var(--accent); background: var(--accent-soft); font-weight: 600; }
.category-finder-or { margin: 14px 0 4px; font-size: 0.88rem; color: var(--ink-2); }
.siret-category { display: block; margin-top: 4px; color: var(--ink); }
.button-link { font: inherit; background: none; border: 0; padding: 0; color: var(--accent-link); text-decoration: underline; cursor: pointer; }
[data-theme="dark"] .category-finder-choice.is-selected { color: var(--ink); }
/* Le bloc échappe aux anciens styles des formulaires (libellé flottant à gauche, textes alignés à droite) */
.column_in .category-finder, .column_in .category-finder p, .column_in .category-finder-result { text-align: left; }
.column_in .category-finder label.category-finder-label { float: none; width: auto; display: block; text-align: left; padding: 0; margin: 0 0 8px; }
.column_in .category-finder-row input.input_text_large { width: auto; flex: 1 1 260px; margin: 0; }
.column_in .category-finder-row .button { margin: 0; flex: 0 0 auto; }
@media (max-width: 560px) { .column_in .category-finder-row .button { flex: 1 1 100%; } .category-finder { padding: 14px; } }
.category-finder-or { text-align: left; }

/* --- Texte de la catégorie : le chapeau (avant les sous-catégories) et le texte sous les sites ne flottent pas,
   sinon les cartes des sous-catégories se rangent à côté au lieu de dessous */
.column_in.category-intro, .column_in.category-outro { float: none; }

/* --- Catégorie sans fiche : message et invitation à s'inscrire */
.category-empty { margin: 18px 0; padding: 22px 20px; border: 1px dashed var(--line-strong); border-radius: var(--radius-lg); background: var(--paper-2); text-align: center; }
.category-empty p { margin: 0 0 12px; color: var(--ink-2); }

/* --- Plan OpenStreetMap de la fiche : bouton, puis plan intégré après le clic du visiteur */
.site-map { margin-top: 16px; }
.site-map-load {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  width: 100%; min-height: 180px; padding: 20px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background-color: var(--paper-2);
  background-image: radial-gradient(circle at 20% 30%, var(--paper-3) 0 2px, transparent 3px),
                    radial-gradient(circle at 70% 60%, var(--paper-3) 0 2px, transparent 3px);
  background-size: 28px 28px, 36px 36px;
  color: var(--ink); font: inherit; cursor: pointer;
  transition: border-color var(--transition), background-color var(--transition);
}
.site-map-load:hover { border-color: var(--line-strong); background-color: var(--paper-3); }
.site-map-load:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.site-map-load-label { display: inline-flex; align-items: center; gap: 8px; font-weight: 650; }
.site-map-load-label::before {
  content: ""; width: 18px; height: 18px; background-color: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a7 7 0 0 0-7 7c0 5.2 7 13 7 13s7-7.8 7-13a7 7 0 0 0-7-7zm0 9.5a2.5 2.5 0 1 1 0-5 2.5 2.5 0 0 1 0 5z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a7 7 0 0 0-7 7c0 5.2 7 13 7 13s7-7.8 7-13a7 7 0 0 0-7-7zm0 9.5a2.5 2.5 0 1 1 0-5 2.5 2.5 0 0 1 0 5z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.site-map-load-note { font-size: 0.85rem; color: var(--color-text-muted); text-align: center; }
.site-map iframe { display: block; width: 100%; height: 320px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper-2); }
.site-map-links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; margin: 8px 0 0; font-size: 0.85rem; color: var(--color-text-muted); }
.site-map-links a { color: var(--accent-link); }
@media (max-width: 600px) {
  .site-map-load { min-height: 140px; }
  .site-map iframe { height: 260px; }
}

/* ============================================
   ÉCRANS LARGES ET TRÈS LARGES (18/11/2026)
   La page suivait une largeur fixe de 1 200 px : sur un écran de 2 560 px elle n'en occupait pas la moitié.
   Au-delà de 1 680 px elle s'élargit par paliers ; au-delà de 2 400 px tout grossit un peu (zoom), comme si le
   visiteur avait agrandi la page dans son navigateur, pour garder un texte lisible.
   ============================================ */
@media (min-width: 1680px) {
  :root { --wrap: 1440px; }
  .cat-directory { columns: 4 240px; }
}
@media (min-width: 2200px) {
  :root { --wrap: 1600px; }
}
@media (min-width: 2400px) {
  html { zoom: 1.125; }
}
@media (min-width: 3000px) {
  html { zoom: 1.25; }
}

/* ============================================
   Emplacements publicitaires vendus (components/SponsoredAds.php)
   ============================================ */

/* Encart d'une publicité, sur l'accueil, une catégorie ou une fiche */
.spot {
  /* Sous les blocs flottants qui le précèdent (description d'une catégorie, large de 100 %) : sans cela son
     texte se plaçait à leur droite et sortait de l'écran */
  clear: both;
  position: relative;
  margin: 24px 0;
  padding: 16px 18px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
}

.spot-tag {
  position: absolute;
  top: -9px;
  right: 14px;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--paper-3);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.spot-link,
.spot-link:link,
.spot-link:visited {
  display: grid;
  gap: 2px;
  color: var(--ink);
  text-decoration: none;
}

.spot-title {
  font-size: 17px;
  font-weight: 750;
}

a.spot-link:hover .spot-title {
  color: var(--accent-link);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.spot-text {
  font-size: 15px;
  color: var(--ink-2);
}

.spot-host {
  font-size: 13px;
  color: var(--color-text-muted);
}

.spot--image {
  padding: 12px;
  text-align: center;
}

.spot--image .spot-link {
  display: block;
}

.spot--image img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
  border-radius: 6px;
}

/* Emplacement libre : « Votre publicité ici » */
.spot--free {
  padding: 0;
  border-style: dashed;
  background: transparent;
}

.spot--free a,
.spot--free a:link,
.spot--free a:visited {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: 4px 10px;
  padding: 14px 18px;
  font-size: 15px;
  color: var(--ink-2);
  text-decoration: none;
}

.spot--free a:hover strong {
  color: var(--accent-link);
}

.spot--free span {
  font-size: 14px;
  color: var(--color-text-muted);
}

.spot--slim {
  margin: 12px 0;
  border: 0;
}

.spot--slim a,
.spot--slim a:link,
.spot--slim a:visited {
  justify-content: flex-start;
  padding: 0;
  font-size: 14px;
}

/* Page « Publicité » : une carte par emplacement */
.booking-page {
  max-width: 1040px;
}

.booking-lead {
  max-width: 62ch;
  margin: 0 0 28px;
  font-size: 17px;
  color: var(--ink-2);
}

.booking-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.booking-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
}

.booking-card h2 {
  float: none;
  margin: 4px 0 0;
  font-size: 18px;
  font-weight: 750;
}

.booking-card-desc {
  margin: 0;
  font-size: 14px;
  color: var(--ink-2);
}

.booking-card .btn,
.booking-state {
  margin-top: auto;
  align-self: flex-start;
}

.booking-state {
  margin-bottom: 0;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--paper-3);
  font-size: 14px;
  font-weight: 650;
  color: var(--ink-2);
}

.booking-prices {
  display: grid;
  gap: 0;
  margin: 2px 0 6px;
  padding: 0;
  list-style: none;
}

.booking-prices li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}

.booking-prices strong {
  font-variant-numeric: tabular-nums;
}

/* Promotion en cours : bandeau et compte à rebours */
.booking-promo {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 16px;
  margin: 0 0 20px;
  padding: 12px 16px;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  background: var(--accent-soft);
  color: var(--ink);
}

.booking-promo strong {
  font-size: 17px;
  font-weight: 800;
}

.booking-promo-end {
  font-variant-numeric: tabular-nums;
}

/* Prix barré et économie, sur la page Publicité et dans le choix de la durée */
.booking-price {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  white-space: nowrap;
}

.booking-price s,
.pay-choice-price s {
  font-size: 13px;
  font-weight: 400;
  color: var(--color-text-muted);
}

.booking-saving {
  margin-left: 4px;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--valid-soft);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  color: var(--valid);
  white-space: nowrap;
}

.booking-note {
  margin: -16px 0 28px;
  font-size: 13px;
  color: var(--color-text-muted);
}

.pay-step .booking-note {
  margin: 8px 0 0;
}

/* Maquette de page de chaque emplacement (gabarit advertise/sketch.tpl) : couleurs du thème */
.booking-sketch svg {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
}

.sk-bg { fill: var(--paper-2); stroke: var(--line); }
.sk-page { fill: var(--paper); stroke: var(--line); }
.sk-page-fill { fill: var(--paper); }
.sk-soft { fill: var(--paper-2); }
.sk-m { fill: var(--paper-3); }
.sk-m2 { fill: var(--line-strong); }
.sk-a { fill: var(--accent); }
.sk-i { fill: var(--ink); }
.sk-on-a { fill: var(--on-accent); }

.booking-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px 24px;
  margin: 0;
  padding: 0 0 0 20px;
  font-size: 15px;
  color: var(--ink-2);
}

/* Formulaire de commande */
.booking-select {
  width: 100%;
  max-width: 420px;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
  font: inherit;
  color: var(--ink);
}

.booking-durations {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.booking-format {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin-bottom: 14px;
  font-weight: 650;
}

.booking-format label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.booking-fields {
  display: grid;
  gap: 12px;
}

.booking-field {
  display: grid;
  gap: 4px;
  font-size: 14px;
  font-weight: 650;
  color: var(--ink-2);
}

.booking-field[hidden] {
  display: none;
}

.booking-field input[type="text"],
.booking-field input[type="url"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
  font: inherit;
  font-weight: 400;
  color: var(--ink);
}

.booking-field small {
  font-weight: 400;
  color: var(--color-text-muted);
}

.booking-preview-title {
  margin: 18px 0 0;
  font-size: 14px;
  font-weight: 650;
  color: var(--ink-2);
}

.booking-preview .spot {
  margin: 14px 0 0;
}

/* « Mes publicités » */
.booking-orders {
  display: grid;
  gap: 10px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.booking-order-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 20px;
  padding: 14px 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
}

.booking-order-meta {
  display: block;
  font-size: 14px;
  color: var(--color-text-muted);
  overflow-wrap: anywhere;
}

.booking-status {
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--paper-3);
  font-size: 14px;
  font-weight: 650;
  color: var(--ink-2);
}

.booking-status--live {
  background: var(--valid-soft);
  color: var(--valid);
}

.booking-status--refused {
  background: var(--color-danger-light);
  color: var(--color-danger);
}

/* Une retouche est demandée à l'annonceur : la pastille et le bouton attirent l'œil */
.booking-status--correction {
  background: var(--accent-soft);
  color: var(--accent-link);
}

.booking-fix {
  flex: 0 0 auto;
}

/* Attente après « Payer et continuer » : le bouton tourne et un voile annonce le départ vers le paiement */
.pay-submit.is-loading {
  position: relative;
  padding-left: 44px;
  pointer-events: none;
  opacity: 0.9;
}

.pay-submit.is-loading::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 50%;
  width: 16px;
  height: 16px;
  margin-top: -10px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: pay-spin 0.7s linear infinite;
}

.pay-wait {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 24px;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: blur(3px);
  font-size: 17px;
  font-weight: 650;
  text-align: center;
  color: var(--ink);
}

.pay-wait[hidden] {
  display: none;
}

.pay-wait-ring {
  width: 44px;
  height: 44px;
  border: 4px solid var(--line-strong);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: pay-spin 0.8s linear infinite;
}

@keyframes pay-spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .pay-wait-ring,
  .pay-submit.is-loading::before {
    animation-duration: 2.4s;
  }
}

/* ============================================================
   Formulaire d'inscription d'un site (webmaster/submitWebsite.tpl)
   L'essentiel d'abord, le facultatif replié par rubriques, l'envoi toujours à l'écran.
   Libellés au-dessus des champs, champs à la largeur de leur colonne, texte saisi en 16 px
   (en dessous, un iPhone agrandit la page à chaque champ). Seules la taille et la place sont
   réglées ici : les couleurs des champs restent celles du thème, clair comme sombre.
   ============================================================ */
.submit-form { display: block; max-width: 780px; margin: 0 auto; }
.page-wide .show_arbo:has(+ .title_h_1 + .submit-form),
.page-wide .title_h_1:has(+ .submit-form) { max-width: 780px; margin-left: auto; margin-right: auto; }
.submit-form .sf-lead { margin: 0 0 26px; max-width: 62ch; color: var(--ink-2); font-size: 1.04rem; line-height: 1.6; }
.submit-form .sf-draft {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 18px;
  margin: 0 0 26px; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--paper-2); color: var(--ink); font-size: 0.94rem; line-height: 1.5;
}
.submit-form .sf-block { margin: 0 0 34px; }
.submit-form .sf-title { margin: 0 0 6px; font-size: 1.3rem; line-height: 1.25; color: var(--ink); text-wrap: balance; }
.submit-form .sf-note { margin: 0 0 14px; max-width: 66ch; color: var(--ink-2); font-size: 0.94rem; line-height: 1.55; }

/* Une rubrique : une grille de deux colonnes, où chaque ligne prend toute la largeur sauf les champs courts */
.submit-form fieldset.column_in {
  float: none; width: auto; min-width: 0; margin: 0; padding: 22px 24px;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 22px;
  text-align: left; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper);
}
.submit-form fieldset.column_in > * { grid-column: 1 / -1; min-width: 0; }
.submit-form fieldset.column_in > .form.sf-half { grid-column: span 1; }
.submit-form fieldset.column_in > br { display: none; }
.submit-form div.form, .submit-form p.form { float: none; width: auto; margin: 0; padding: 0; }
.submit-form label { float: none; }
.submit-form label.title {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px;
  width: auto; margin: 0 0 7px; padding: 0;
  text-align: left; font-size: 0.95rem; font-weight: 650; line-height: 1.35; color: var(--ink);
}
.submit-form div.infos, .submit-form label.infos, .submit-form div.infos_textarea, .submit-form div.infos_terms {
  display: block; float: none; width: auto; margin: 0; padding: 0; line-height: 1.5;
}

/* Champs : toute la largeur de leur colonne, 46 px de haut, 16 px */
.submit-form input[type="text"], .submit-form input[type="url"], .submit-form input[type="email"],
.submit-form input[type="number"], .submit-form input[type="tel"], .submit-form select:not([size]),
.submit-form textarea {
  float: none; width: 100%; max-width: 100%; min-height: 46px; box-sizing: border-box;
  padding: 10px 12px; font-family: inherit; font-size: 16px; line-height: 1.45; border-radius: var(--radius);
}
.submit-form textarea { min-height: 96px; resize: vertical; }
.submit-form textarea.textarea_extra_large { height: 260px; }
.submit-form textarea.textarea_return { min-height: 0; height: auto; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 13px; }
.submit-form input[type="file"] { max-width: 100%; font-size: 15px; }
.submit-form input[type="checkbox"], .submit-form input[type="radio"] { width: 20px; height: 20px; margin: 0; flex: 0 0 auto; accent-color: var(--accent); }

/* Champ suivi de son bouton (lire le site, chercher au registre, vérifier le lien) : sur une ligne, puis l'un sous l'autre */
.submit-form .infos:has(> .button) { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 10px; }
.submit-form .infos:has(> .button) > input[type="text"] { flex: 1 1 240px; width: auto; }
.submit-form .infos:has(> .button) > .button { flex: 0 0 auto; min-height: 46px; }
.submit-form .infos:has(> .button) > div, .submit-form .infos:has(> .button) > span { flex: 1 1 100%; }

/* Case à cocher et son libellé sur une ligne, la case d'abord */
.submit-form .form:has(> .infos > input[type="checkbox"]:only-child) { display: flex; flex-direction: row-reverse; justify-content: flex-end; align-items: center; gap: 10px; }
.submit-form .form:has(> .infos > input[type="checkbox"]:only-child) > label.title { margin: 0; font-weight: 500; }
.submit-form .form:has(> .infos > input[type="checkbox"]:only-child) > .infos { display: flex; }

.submit-form .seo-counter-section { margin-top: 8px; }
.submit-form .siret-status:empty { display: none; }
.submit-form #oh-widget-container input[type="checkbox"] { vertical-align: middle; margin-right: 8px; }
.submit-form input[type="file"]::file-selector-button {
  margin-right: 12px; padding: 9px 14px; border: 1px solid var(--line-strong); border-radius: var(--radius);
  background: var(--paper); color: var(--ink); font: inherit; font-weight: 600; cursor: pointer;
}
.submit-form input[type="file"]::file-selector-button:hover { background: var(--paper-2); }
.submit-form .geo-hint { margin: 0; }
.submit-form .deeplinks-form > label.title { display: none; }
.submit-form .deeplinks-help { margin: 0 0 12px; color: var(--ink-2); font-size: 0.92rem; }

/* Le site et sa catégorie */
.submit-form .category-finder { margin: 0; padding: 0; border: 0; background: none; }
.submit-form .category-finder-row .button { min-height: 46px; }
.submit-form .sf-current { margin: 0; color: var(--ink-2); }
.submit-form .sf-current strong { color: var(--ink); font-weight: 650; }
.submit-form details.sf-manual > summary {
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer; list-style: none;
  padding: 6px 0; color: var(--accent-link); font-weight: 600; font-size: 0.95rem;
}
.submit-form details.sf-manual > summary::-webkit-details-marker { display: none; }
.submit-form details.sf-manual > summary::before {
  content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: rotate(-45deg); transition: transform 0.18s cubic-bezier(0.23, 1, 0.32, 1);
}
.submit-form details.sf-manual[open] > summary::before { transform: rotate(45deg); }
.submit-form details.sf-manual > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.submit-form details.sf-manual > .form { margin-top: 12px; }
.submit-form label.infos_select_category { display: flex; flex-wrap: wrap; gap: 10px; }
.submit-form label.infos_select_category select { flex: 1 1 220px; max-width: none; min-width: 0; height: 240px; font-size: 16px; }

/* Rubriques facultatives : un titre, ce qu'elles apportent, le nombre de champs remplis */
.submit-form details.sf-more { margin: 0 0 10px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.submit-form details.sf-more > summary {
  display: grid; grid-template-columns: minmax(0, 1fr) auto 14px; column-gap: 14px; align-items: center;
  padding: 15px 20px; cursor: pointer; list-style: none; border-radius: var(--radius-lg);
}
.submit-form details.sf-more > summary::-webkit-details-marker { display: none; }
.submit-form details.sf-more > summary:hover { background: var(--paper-2); }
.submit-form details.sf-more > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.submit-form details.sf-more > summary::after {
  content: ""; grid-column: 3; grid-row: 1 / span 2; width: 8px; height: 8px;
  border-right: 2px solid var(--ink-2); border-bottom: 2px solid var(--ink-2);
  transform: translateY(-2px) rotate(45deg); transition: transform 0.18s cubic-bezier(0.23, 1, 0.32, 1);
}
.submit-form details.sf-more[open] > summary::after { transform: translateY(2px) rotate(225deg); }
.submit-form .sf-more-name { grid-column: 1; font-weight: 700; color: var(--ink); line-height: 1.3; }
.submit-form .sf-more-hint { grid-column: 1; grid-row: 2; margin-top: 2px; color: var(--ink-2); font-size: 0.9rem; line-height: 1.4; }
.submit-form .sf-more-count { grid-column: 2; grid-row: 1 / span 2; font-size: 0.82rem; font-weight: 650; color: var(--ink); white-space: nowrap; }
.submit-form .sf-more-count.has-items { padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); }
.submit-form details.sf-more[open] > summary { border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
.submit-form details.sf-more > fieldset.column_in { border: 0; border-top: 1px solid var(--line); border-radius: 0 0 var(--radius-lg) var(--radius-lg); background: transparent; }

/* Envoi : lettre d'information, conditions, puis la barre du bouton qui suit l'écran */
.submit-form .sf-send { display: grid; gap: 10px; margin: 0 0 16px; }
.submit-form .sf-check { display: flex; align-items: center; gap: 10px; color: var(--ink); line-height: 1.4; cursor: pointer; }
.submit-form .sf-terms { margin: 0; color: var(--ink-2); font-size: 0.92rem; line-height: 1.5; }
.submit-form .sf-submit {
  position: sticky; bottom: 12px; z-index: 20;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 18px;
  padding: 14px 18px; border: 1px solid var(--line-strong); border-radius: var(--radius-lg);
  background: var(--paper); box-shadow: 0 10px 30px -12px rgba(28, 25, 23, 0.35);
}
.submit-form .sf-missing { flex: 1 1 260px; margin: 0; color: var(--ink-2); font-size: 0.93rem; line-height: 1.45; }
.submit-form .sf-missing.is-ready { color: var(--ink); font-weight: 600; }
.submit-form .sf-submit input[type="submit"] { flex: 0 0 auto; min-width: 220px; min-height: 48px; font-size: 1.02rem; }
.submit-form #siteLoader { flex: 1 1 100%; color: var(--ink-2); font-size: 0.93rem; }

@media (max-width: 640px) {
  .submit-form .sf-block { margin-bottom: 28px; }
  .submit-form fieldset.column_in { grid-template-columns: minmax(0, 1fr); padding: 18px 16px; gap: 18px; }
  .submit-form fieldset.column_in > .form.sf-half { grid-column: 1 / -1; }
  .submit-form details.sf-more > summary { padding: 14px 16px; }
  .submit-form .infos:has(> .button) > .button, .submit-form .category-finder-row .button { flex: 1 1 100%; }
  .submit-form .sf-submit { bottom: 8px; padding: 12px 14px; }
  .submit-form textarea.textarea_return { font-size: 16px; }
  .submit-form .sf-submit input[type="submit"] { flex: 1 1 100%; min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .submit-form details > summary::before, .submit-form details > summary::after { transition: none; }
}

/* Mentions légales (info/legalNotice.tpl) : une rubrique par intertitre, de l'air entre les blocs */
.legal-notice h2 { font-size: 1.15rem; margin: 1.75em 0 .5em; }
.legal-notice h2:first-child { margin-top: 0; }
.legal-notice p { margin: 0 0 .85em; line-height: 1.65; }
.legal-notice p:last-child { margin-bottom: 0; }

/* Page Partenaires (/partenaires.html) */
.partner-list { list-style: none; margin: 1.25em 0 0; padding: 0; display: grid; gap: .75rem; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.partner-item { border: 1px solid var(--color-border); border-radius: var(--radius); padding: .9rem 1rem; background: var(--color-white); }
.partner-banner { display: block; margin-bottom: .5rem; }
.partner-banner img { display: block; max-width: 100%; height: auto; max-height: 90px; }
.partner-name { font-weight: 600; font-size: 1.05rem; }
.partner-desc { margin: .35em 0 0; color: var(--color-text-secondary); line-height: 1.55; }

/* Guides (/guides.html et /guides/<slug>.html) : colonne de lecture d'environ 70 caractères, intertitres aérés,
   tableaux qui défilent de côté sur un petit écran. Couleurs et arrondis tirés des variables : les trois thèmes et
   le mode sombre s'appliquent d'eux-mêmes. */
.guide-wrap { max-width: 70ch; }
.guide-meta { margin: 0 0 1rem; color: var(--color-text-muted); font-size: .9rem; line-height: 1.5; }
.guide-meta-sep { margin: 0 .35em; }
.guide-article { color: var(--color-text); font-size: 1.0625rem; line-height: 1.7; }
.guide-intro { margin: 0 0 1.5rem; font-size: 1.15rem; font-weight: 600; line-height: 1.6; color: var(--color-text); }
.guide-cover { display: block; width: 100%; height: auto; margin: 0 0 1.75rem; border-radius: var(--radius); }
.guide-body { overflow-wrap: break-word; }
.guide-body > :first-child { margin-top: 0; }
.guide-body h2 { margin: 2.1em 0 .6em; font-family: var(--font-display); font-size: 1.45rem; line-height: 1.3; color: var(--color-text); }
.guide-body h3 { margin: 1.8em 0 .5em; font-size: 1.18rem; line-height: 1.35; color: var(--color-text); }
.guide-body h4 { margin: 1.5em 0 .4em; font-size: 1.02rem; line-height: 1.4; color: var(--color-text); }
.guide-body p { margin: 0 0 1.1em; }
.guide-body ul, .guide-body ol { margin: 0 0 1.2em; padding-left: 1.5em; }
.guide-body ul { list-style: disc; }
.guide-body ol { list-style: decimal; }
.guide-body li { margin: .35em 0; padding-left: .15em; }
.guide-body li::marker { color: var(--color-primary); font-weight: 700; }
.guide-body a { color: var(--accent-link, var(--color-primary)); text-decoration: underline; text-underline-offset: 3px; }
.guide-body a:hover { text-decoration-thickness: 2px; }
.guide-body strong, .guide-body b { font-weight: 700; color: var(--color-text); }
.guide-body blockquote { margin: 1.6em 0; padding: .9em 1.2em; border-left: 4px solid var(--color-primary); border-radius: 0 var(--radius) var(--radius) 0; background: var(--color-bg); color: var(--color-text-secondary); font-size: 1.05rem; }
.guide-body blockquote p:last-child { margin-bottom: 0; }
.guide-body img { max-width: 100%; height: auto; border-radius: var(--radius-sm); }
.guide-body hr { margin: 2em 0; border: 0; border-top: 1px solid var(--color-border); }
.guide-body code { padding: .1em .35em; border-radius: var(--radius-sm); background: var(--color-bg); font-size: .92em; }
.guide-body pre { margin: 0 0 1.2em; padding: 1em; overflow-x: auto; border-radius: var(--radius); background: var(--color-bg); }
.guide-body pre code { padding: 0; background: none; }
.guide-table { margin: 1.5em 0; overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-white); }
.guide-table table { width: 100%; border-collapse: collapse; font-size: .95rem; line-height: 1.5; }
.guide-table caption { padding: .6em .85em; caption-side: top; text-align: left; font-weight: 600; color: var(--color-text-secondary); }
.guide-table th, .guide-table td { min-width: 7em; padding: .6em .85em; border: 0; border-bottom: 1px solid var(--color-border); text-align: left; vertical-align: top; color: var(--color-text); }
.guide-table th { background: var(--color-bg); font-size: inherit; font-weight: 700; letter-spacing: normal; text-transform: none; }
.guide-table tr:last-child td { border-bottom: 0; }
.guide-table:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 2px; }

/* Liste des guides : une carte par guide, entièrement cliquable */
.guide-index-intro { margin: 0; color: var(--color-text-secondary); line-height: 1.6; }
.guide-list { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); margin: 1.25em 0 0; padding: 0; list-style: none; }
.guide-card { position: relative; display: flex; flex-direction: column; gap: .45rem; padding: 1.1rem 1.2rem; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-white); transition: border-color var(--transition), box-shadow var(--transition); }
.guide-card:hover, .guide-card:focus-within { border-color: var(--color-primary); box-shadow: var(--shadow-md); }
.guide-card-image { display: block; width: calc(100% + 2.4rem); max-width: none; height: auto; aspect-ratio: 1200 / 630; margin: -1.1rem -1.2rem .35rem; object-fit: cover; border-radius: calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0 0; background: var(--color-bg); }
.guide-card-title { margin: 0; font-size: 1.15rem; line-height: 1.35; }
.guide-card-title a { color: var(--color-text); text-decoration: none; }
.guide-card-title a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.guide-card .guide-meta { margin: 0; }
.guide-card-intro { display: -webkit-box; margin: 0; overflow: hidden; -webkit-line-clamp: 4; -webkit-box-orient: vertical; color: var(--color-text-secondary); line-height: 1.55; }
.guide-card-more { margin-top: auto; padding-top: .3rem; color: var(--accent-link, var(--color-primary)); font-weight: 600; text-decoration: none; }

/* Autres guides, sous l'article */
.guide-others h2 { margin: 0 0 .6em; font-size: 1.15rem; }
.guide-others ul { margin: 0 0 .8em; padding-left: 1.2em; list-style: disc; }
.guide-others li { margin: .3em 0; }
.guide-others p { margin: 0; }

@media (max-width: 640px) {
  .guide-article { font-size: 1rem; }
  .guide-intro { font-size: 1.06rem; }
  .guide-body h2 { font-size: 1.3rem; }
}

/* --- Accueil : bloc « Nos partenaires » (réglage partnersDisplay), bannières et liens alignés, sans présentation */
.home-partner-list { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; margin: 0; padding: 0; list-style: none; }
.home-partner { display: flex; align-items: center; }
.home-partner-banner img { display: block; max-width: 468px; max-height: 60px; width: auto; height: auto; }
.home-partner-name { font-size: 14px; }
@media (max-width: 560px) { .home-partner-banner img { max-width: 100%; } }


/* Panneau en verre du bandeau d'accueil (includes/heroPanel.tpl). Verre clair : flou et saturation de ce qui
   est derrière, reflet en haut, bord lumineux. Le texte garde la couleur du bandeau, l'accent vient du thème.
   Sans flou possible, ou si le visiteur demande moins de transparence : fond presque opaque du thème. */
.hero-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
  max-width: 300px;
  padding: 18px;
  border: 1px solid color-mix(in srgb, #fff 45%, transparent);
  border-radius: 22px;
  background:
    linear-gradient(160deg, color-mix(in srgb, #fff 30%, transparent) 0%, color-mix(in srgb, #fff 6%, transparent) 55%, color-mix(in srgb, #fff 14%, transparent) 100%);
  -webkit-backdrop-filter: blur(18px) saturate(170%);
  backdrop-filter: blur(18px) saturate(170%);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, #fff 60%, transparent),
    inset 0 -1px 0 color-mix(in srgb, #fff 12%, transparent),
    0 18px 48px rgba(10, 12, 24, 0.22);
  color: inherit;
  text-align: left;
}

.hero-panel-title {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.85;
}

.hero-panel-stats {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hero-panel-stats li {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid color-mix(in srgb, #fff 22%, transparent);
  border-radius: 14px;
  background: color-mix(in srgb, #fff 10%, transparent);
}

.hero-panel-num {
  min-width: 2.2ch;
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.hero-panel-label {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  opacity: 0.9;
}

.hero-panel-manage {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 14px;
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 800;
  text-decoration: none;
  transition: transform var(--transition), box-shadow var(--transition);
}

.hero-panel-manage:hover,
.hero-panel-manage:focus-visible {
  color: var(--on-accent);
  box-shadow: 0 8px 22px color-mix(in srgb, var(--accent) 45%, transparent);
  transform: translateY(-1px);
}

.hero-panel-manage svg {
  flex: none;
  width: 22px;
  height: 22px;
}

.hero-panel-manage-sub {
  display: block;
  font-size: 12px;
  font-weight: 600;
  opacity: 0.85;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .hero-panel {
    background: color-mix(in srgb, var(--paper) 88%, transparent);
    color: var(--ink);
  }
}

/* Moins de transparence demandée (Windows : effets de transparence coupés) : le flou reste, le verre se
   teinte davantage pour que le texte se détache mieux. */
@media (prefers-reduced-transparency: reduce) {
  .hero-panel {
    -webkit-backdrop-filter: blur(24px) saturate(150%);
    backdrop-filter: blur(24px) saturate(150%);
  }
  .hero-panel-stats li {
    background: color-mix(in srgb, #fff 16%, transparent);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-panel-manage:hover,
  .hero-panel-manage:focus-visible {
    transform: none;
  }
}

/* Bouton « Cliquer pour voir l'e-mail » (components/EmailShield.php) : il remplace une adresse dans le texte,
   à la taille du texte qui l'entoure, avec la couleur des liens du thème. */
.email-reveal {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 1px 10px 2px;
  border: 1px dashed currentColor;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent-link) 8%, transparent);
  color: var(--accent-link);
  font: inherit;
  font-weight: 600;
  line-height: 1.5;
  vertical-align: baseline;
  cursor: pointer;
  transition: background-color var(--transition), border-color var(--transition);
}

.email-reveal:hover,
.email-reveal:focus-visible {
  border-style: solid;
  background: color-mix(in srgb, var(--accent-link) 16%, transparent);
}

.email-reveal svg {
  flex: none;
  width: 1em;
  height: 1em;
}

.email-revealed {
  font-weight: 600;
  word-break: break-all;
}


/* Fiche non revendiquée (components/SiteClaim.php) : bandeau sur la fiche, page de revendication */
.claim-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  margin: 16px 0 4px;
  padding: 14px 18px;
  border: 1px dashed color-mix(in srgb, var(--accent-link) 45%, transparent);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--accent-link) 7%, transparent);
}

.claim-banner p {
  flex: 1 1 320px;
  margin: 0;
  font-size: 0.95em;
}

.claim-banner-btn {
  flex: none;
}

.claim-way {
  margin: 0 0 22px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
}

.claim-way h2 {
  margin: 0 0 8px;
  font-size: 1.1rem;
}

.claim-way .wm-code {
  margin: 4px 0 12px;
}

.claim-email-form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.claim-email-form input {
  flex: 1 1 260px;
}

.claim-ok {
  border-color: color-mix(in srgb, #15803d 50%, transparent);
}

.claim-ko {
  border-color: color-mix(in srgb, var(--accent) 50%, transparent);
}

.claim-help {
  color: var(--ink-2);
  font-size: 0.92em;
}


/* Rubriques voisines, en bas d'une sous-catégorie */
.category-neighbours {
  margin: 28px 0 8px;
}

.category-neighbours h2 {
  margin: 0 0 12px;
  font-size: 1.15rem;
}

/* Toutes les catégories (category/showAll.tpl) : une famille par intertitre, ses rubriques en liste */
.all-categories-family {
  margin: 22px 0 8px;
  font-size: 1.15rem;
}

.all-categories-family:first-child {
  margin-top: 0;
}

.all-categories-list {
  margin: 0 0 8px;
  padding-left: 1.2em;
  line-height: 1.7;
}

/* Textes des pages Contact et Partenaires (Réglages > Page Contact, Page Partenaires) */
.column_in.page-text p,
.column_in.page-text ul,
.column_in.page-text ol {
  margin: 0 0 0.8em;
}

.column_in.page-text h2,
.column_in.page-text h3 {
  margin: 1.1em 0 0.4em;
}

.column_in.page-text > :first-child {
  margin-top: 0;
}

.column_in.page-text > :last-child {
  margin-bottom: 0;
}

.page-text-box {
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm, 8px);
  background: var(--accent-soft);
  padding: 16px 20px;
}

/* Intertitre des sous-catégories d'une page de catégorie (category/list.tpl) */
.cat-directory-title {
  margin: 24px 0 12px;
  font-size: 1.15rem;
}

.category-neighbours ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.category-neighbours a {
  display: inline-block;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper-2);
  text-decoration: none;
}

.category-neighbours a:hover,
.category-neighbours a:focus-visible {
  border-color: var(--accent-link);
}
