@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');

/*
Theme Name: AtypikHouse Theme
Author: Joey Marquet
Description: Thème WordPress custom pour la plateforme AtypikHouse.
Version: 1.0
Text Domain: atypikhouse
*/

.hero-categories {
  display: flex;
  flex-direction: row;
  width: 100%;
  text-align: center;
}

.category-block {
  flex: 1;
  padding: 4rem 2rem;
  color: white;
}

.category-block h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.category-block p {
  font-size: 1rem;
  margin-bottom: 2rem;
}

.category-block a.btn {
  display: inline-block;
  padding: 0.8rem 1.6rem;
  background-color: white;
  color: black;
  text-decoration: none;
  font-weight: bold;
}

.campagne {
  background-color: #B6C49A;
}

.bord-de-mer {
  background-color: #A3C8D9;
}

.montagne {
  background-color: #7A988C;
}

.filtre-bar {
  background: #f0ebe3;
  padding: 2rem;
  text-align: center;
}

.filtre-dates input[type="date"] {
  padding: 0.5rem 1rem;
  margin: 0 0.5rem;
  font-size: 1rem;
}

.filtre-types {
  margin-top: 1rem;
}

.filtre-types button {
  background-color: white;
  border: 1px solid #ccc;
  margin: 0.3rem;
  padding: 0.5rem 1rem;
  cursor: pointer;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.filtre-types button:hover {
  background-color: #ddd;
}

.logement-featured {
  margin: 2rem 0;
}

.logement-image {
  position: relative;
  background-size: cover;
  background-position: center;
  min-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logement-info {
  background-color: rgba(255, 255, 255, 0.9);
  padding: 2rem;
  max-width: 600px;
  text-align: center;
}

.logement-tags span {
  display: inline-block;
  background: #ddd;
  padding: 0.3rem 0.8rem;
  margin: 0.2rem;
  font-size: 0.85rem;
}

.logement-title {
  font-size: 2rem;
  margin-top: 1rem;
}

.logement-location {
  font-size: 1rem;
  font-weight: 500;
  color: #666;
}

.logement-description {
  margin: 1rem 0;
  font-size: 1rem;
}

.btn-reserver {
  background-color: black;
  color: white;
  padding: 0.7rem 1.5rem;
  text-decoration: none;
  display: inline-block;
  margin-top: 1rem;
}

.recherche-logements {
  background-color: #f5f5f5;
  padding: 4rem 2rem;
}

.recherche-logements h2 {
  text-align: center;
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

.search-bar {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
}

.search-bar input[type="text"] {
  padding: 0.5rem 1rem;
  width: 250px;
  border: 1px solid #ccc;
  font-size: 1rem;
}

.search-bar button {
  padding: 0.5rem 1rem;
  border: 1px solid #ccc;
  background-color: #eee;
  border-left: none;
  cursor: pointer;
}

.tag-filters {
  text-align: center;
  margin-bottom: 2rem;
}

.tag-filters span {
  display: inline-block;
  background: #ddd;
  padding: 0.4rem 1rem;
  margin: 0.3rem;
  font-size: 0.85rem;
  cursor: pointer;
}

.logements-liste {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 1080px;
  margin: 0 auto;
}

.logement-card {
  background-color: #fff;
  border: 1px solid #000;
  padding: 1.75rem 2rem;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}

.logement-card h3 {
  margin-top: 0.5rem;
  font-size: 1.2rem;
}

.logement-card p {
  color: #666;
  font-size: 0.95rem;
}

.logement-card .tags span {
  display: inline-block;
  background: #eee;
  margin: 0.2rem;
  padding: 0.3rem 0.7rem;
  font-size: 0.75rem;
}

/* Keep texts inside card and improve actions layout */
.logement-card * {
  word-break: break-word;
}

.logement-card .actions {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
  margin-top: .75rem;
}

.logement-card .actions a {
  border: 1px solid #000;
  background: #fff;
  color: #000;
  padding: .55rem 1.1rem;
  text-decoration: none;
  line-height: 1;
}

.logement-card .actions a:hover {
  background: #000;
  color: #fff;
}

/* Desktop a bit more generous */
@media (min-width: 1200px) {
  .logement-card { padding: 2rem 2.25rem; }
}

/* ===== Styles globaux ===== */

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  margin: 0;
  padding: 0;
  background-color: #fff;
  color: #222;
}

main {
  max-width: 100%;
  margin: 0 auto 0;
  padding: 4rem 2rem;
}

h1, h2, h3 {
  font-weight: 600;
  line-height: 1.3;
}

h1 {
  font-size: 2.4rem;
  margin-bottom: 1.5rem;
}

h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

p {
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.scrolling-nav {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  white-space: nowrap;
  padding: 1rem 1rem 0;
  background: #fff;
  margin-bottom: 1rem;
}

.scrollable-menu {
  display: inline-flex;
  flex-wrap: nowrap;
  gap: 2rem;
  list-style: none;
  margin: 0;
  padding: 0;
  min-width: max-content;
}

.scrollable-menu li {
  flex: 0 0 auto;
}

.scrollable-menu li a {
  display: inline-block;
  text-decoration: none;
  color: #000;
  font-size: 1rem;
  padding-bottom: 0.5rem;
  font-weight: 400;
  transition: all 0.3s ease;
}

.scrollable-menu li.current-menu-item a {
  font-weight: 700;
}

body, h1, h2, h3, h4, h5, h6, p, a, li, input, button {
  font-family: 'Inter', sans-serif !important;
}

.tag-button {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  margin: 0.3rem;
  border: 1px solid black;
  text-decoration: none;
  font-size: 0.85rem;
  background-color: transparent;
}

.tag-button.active {
  background-color: white;
  color: black;
  border-color: black;
}
.site-header {
  background-color: #fff;
  position: fixed;
  top: 0;
  z-index: 1000;
  width: 100%;
  padding: 1.5rem 1rem; /* slightly reduced default height */
  transition: transform 0.3s ease-in-out;
  display: block;
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}

/* === Mobile: force perfect centering of the logo only === */
@media (max-width: 768px) {
  .site-header .container { display: block !important; padding-left: 0 !important; padding-right: 0 !important; }
  .site-branding {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
  }
  .site-branding .logo-atypik {
    display: block !important;
    width: auto !important;
    max-width: 90vw !important;
    margin: 0 auto !important;
    padding: 0 !important;
    left: auto !important;
    transform: none !important;
    text-align: center !important;
    margin-top: 1.25rem !important;   /* more air above logo */
    margin-bottom: 0.25rem !important;/* less space below logo */
  }
  .site-branding .logo-atypik > a {
    display: block !important;
    margin: 0 auto !important;
    text-align: center !important;
  }
  .site-header { 
    padding: 1rem 1rem 0.5rem !important; 
  }
  .scrolling-nav {
    margin-bottom: 0.5rem !important;
    padding-top: 0.25rem !important;
  }
  /* --- Menu mobile : coussins gauche/droite + scroll confortable --- */
  header.site-header nav.main-navigation .scrolling-nav{
    padding-left: 12px !important;
    padding-right: 12px !important;
    scroll-padding-left: 12px;
    scroll-padding-right: 12px;
    overflow-x: auto;                  /* safety: ensure horizontal scroll works */
    -webkit-overflow-scrolling: touch; /* smooth on iOS */
  }
  header.site-header nav.main-navigation .scrolling-nav .scrollable-menu{
    padding-left: 6px !important;
    padding-right: 6px !important;
  }
  /* petits espaces au tout début et à la fin de la liste pour éviter que le texte touche le bord */
  header.site-header nav.main-navigation .scrolling-nav .scrollable-menu::before,
  header.site-header nav.main-navigation .scrolling-nav .scrollable-menu::after{
    content: "";
    flex: 0 0 4px;
  }
  header.site-header nav.main-navigation .scrolling-nav .scrollable-menu > li:first-child{ margin-left: 4px; }
  header.site-header nav.main-navigation .scrolling-nav .scrollable-menu > li:last-child{  margin-right: 4px; }
}