/* ═══════════ KasherHub · réglages téléphone ═══════════
   Ce que l'on ne voit qu'à l'usage sur un écran étroit : champs écrasés, barres qui débordent,
   boutons trop petits. Rien ici ne change l'affichage sur ordinateur. */
@media (max-width: 760px) {
  /* la barre de recherche des annuaires : le champ prend toute la largeur, la date passe dessous */
  .an-rang1 { grid-template-columns: 1fr !important; gap: 10px !important; }
  .an-barre input#anQ { min-height: 52px; font-size: 16px; }
  .an-date { justify-content: space-between; }
  .an-date input { flex: 1 1 auto; min-width: 0; }
  .an-compte { text-align: left; }
  .an-rang2 { gap: 8px; }
  .an-villes { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
  .an-villes::-webkit-scrollbar { display: none; }
  .an-villes button, .an-lien-bulle { flex: none; }

  /* la barre des salles : même traitement */
  .sa-barre-in { gap: 10px; }
  .sa-barre input { flex: 1 1 100%; min-height: 50px; font-size: 16px; }
  .sa-types { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .sa-types::-webkit-scrollbar { display: none; }
  .sa-types button { flex: none; }

  /* les bulles de sélection posées par les étiquettes */
  .kh-etiq-barre { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .kh-etiq-barre::-webkit-scrollbar { display: none; }
  .kh-etiq-barre button { flex: none; }

  /* une fiche : la colonne de droite passe dessous, sans coller au bord */
  .fiche-layout { gap: 16px !important; }
  .sidebar { position: static !important; }
  .contact-card { padding: 18px !important; }

  /* lecture confortable */
  body { font-size: 16.5px; }
  .co-sec, .ou-sec, .pr-sec { padding-left: 16px; padding-right: 16px; }

  /* rien ne dépasse à l'horizontale */
  img, video, iframe, table { max-width: 100%; }
  .an-grille, .sa-grille, .ou-grille, .pr-grille { grid-template-columns: 1fr !important; }
}
@media (max-width: 420px) {
  .kh-aide-btn span { font-size: 13px; }
  .pr-hero h1, .ou-hero h1 { font-size: 34px; }
}

/* ═══════════ Page d'accueil sur téléphone ═══════════
   Le bandeau d'accueil tenait sur près de deux écrans : on le resserre pour que la recherche
   et les premiers prestataires soient visibles sans descendre. */
@media (max-width: 760px) {
  .hero { padding-top: 14px !important; padding-bottom: 18px !important; min-height: 0 !important; }
  .hero-content { padding: 16px 20px 4px !important; gap: 0 !important; }
  .hero-eyebrow { font-size: 10.5px !important; letter-spacing: 2.2px !important; margin: 0 0 6px !important; }
  .hero-title { font-size: 29px !important; line-height: 1.12 !important; margin: 0 0 6px !important; }
  .hero-divider { width: 44px !important; margin: 12px auto !important; }
  .hero-subtitle { font-size: 14px !important; letter-spacing: 1.2px !important; line-height: 1.45 !important; margin: 0 0 14px !important; }
  .hero-image { order: -1; height: 190px !important; min-height: 190px !important; margin-bottom: 12px; }
  .hero-image img { height: 100% !important; object-fit: cover; }

  /* la recherche : un champ, un bouton, rien qui déborde */
  .search-bar { display: grid !important; grid-template-columns: 1fr !important; gap: 8px !important;
    padding: 10px !important; border-radius: 14px !important; }
  .search-bar input, .search-bar select { min-height: 46px !important; font-size: 16px !important; width: 100% !important; }
  .search-bar button:not(.kh-geo) { min-height: 48px !important; width: 100% !important; font-size: 15px !important; }
  .search-bar .kh-loc { width: 100% !important; }
  .search-bar .kh-geo { width: 36px !important; min-height: 36px !important; height: 36px !important; right: 6px !important; }

  /* les trois preuves sous la recherche : sur une seule ligne, en petit */
  .hero-trust { display: flex !important; flex-direction: row !important; flex-wrap: wrap; justify-content: center !important;
    gap: 6px 12px !important; font-size: 11.5px !important; letter-spacing: 1px !important; margin-top: 16px !important; }
  .hero-trust > * { margin: 0 !important; }
  .hero-trust-separator { display: inline !important; }

  /* le rappel « devis express » sous la recherche : plus compact */
  .hero-content > div:last-child { margin-top: 16px !important; padding-top: 14px !important; }

  /* les blocs de la page d'accueil respirent moins */
  .section-prestataires, .section-categories, .section-outils, .section-magazine { padding-top: 34px !important; padding-bottom: 34px !important; }
  .section-title, .section-titre { font-size: 26px !important; line-height: 1.15 !important; }
}

@media (max-width: 760px) {
  /* les hauteurs minimales posées pour l'ordinateur ne valent pas sur un téléphone */
  .hero-content { min-height: 0 !important; }
  .hero-trust { min-height: 0 !important; }
  .search-bar { min-height: 0 !important; }
}

/* ═══════════ La barre de contact en bas de fiche ═══════════ */
@media (max-width: 900px) {
  .barre-mobile { background: #fff !important; border-top: 1px solid #E4E0D6 !important;
    display: grid !important; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; padding: 10px 12px !important; }
  .barre-mobile a, .barre-mobile button {
    background: #fff !important; color: #14140F !important; border: 1.5px solid #8E6F2C !important;
    border-radius: 10px !important; min-height: 48px; display: flex; align-items: center; justify-content: center;
    font: 700 14.5px Manrope, system-ui, sans-serif !important; text-decoration: none; }
  .barre-mobile a.barre-devis { background: #8E6F2C !important; color: #fff !important; border-color: #8E6F2C !important; }
  .barre-mobile a.barre-wa { color: #128C4A !important; border-color: #128C4A !important; }
  .barre-mobile a.barre-appel { color: #14140F !important; border-color: #8E6F2C !important; font-weight: 800 !important; }
}

@media (max-width: 480px) {
  /* trois boutons sur une ligne : des mots courts, pas de retour à la ligne */
  .barre-mobile a, .barre-mobile button { font-size: 13.5px !important; padding: 0 6px; white-space: nowrap; }
}

/* ═══════════ La bulle d'aide reste une bulle ═══════════
   Certaines pages étirent tous les boutons sur toute la largeur en dessous de 600 px ;
   la bulle d'aide, elle, garde sa taille. */
@media (max-width: 760px) {
  body button.kh-aide-btn { width: auto !important; max-width: calc(100vw - 24px) !important; text-align: left !important; }
}
