/*
 * LE PETIT AGENAIS - Layout & Structure
 * Basé sur le thème Urbango
 */

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background-color: white;
  box-shadow: var(--shadow-md);
  z-index: var(--z-sticky);
  transition: all var(--transition-base);
}

.header.scrolled {
  height: 70px;
  box-shadow: var(--shadow-lg);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--container-2xl);
  margin: 0 auto;
  padding: 0 var(--spacing-xl);
}

.header-logo {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
  text-decoration: none;
}

.header-logo img {
  height: 40px;
  width: auto;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: var(--spacing-2xl);
}

.header-nav-link {
  color: var(--color-text);
  font-weight: var(--font-weight-medium);
  transition: color var(--transition-fast);
  position: relative;
}

.header-nav-link:hover,
.header-nav-link.active {
  color: var(--color-primary);
}

.header-nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--color-primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: var(--font-size-2xl);
  color: var(--color-text);
  cursor: pointer;
  padding: var(--spacing-sm);
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  color: white;
  margin-top: var(--header-height);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
  opacity: 0.3;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 900px;
  padding: 0 var(--spacing-lg);
}

.hero-title {
  font-size: var(--font-size-5xl);
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--spacing-lg);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
  font-size: var(--font-size-xl);
  margin-bottom: var(--spacing-2xl);
  opacity: 0.95;
  line-height: var(--line-height-relaxed);
}

.hero-search {
  margin: 0 auto;
  margin-bottom: var(--spacing-xl);
}

.hero-categories {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-lg);
  flex-wrap: wrap;
}

.hero-category {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  transition: all var(--transition-base);
  cursor: pointer;
  min-width: 100px;
}

.hero-category:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-4px);
}

.hero-category-icon {
  font-size: var(--font-size-3xl);
}

.hero-category-name {
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
}

/* Main Content */
.main-content {
  min-height: calc(100vh - var(--header-height) - 400px);
  padding-top: var(--header-height);
}

/* Footer */
.footer {
  background-color: var(--color-text);
  color: white;
  padding: var(--spacing-3xl) 0 var(--spacing-xl);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-2xl);
  margin-bottom: var(--spacing-2xl);
}

.footer-section h4 {
  color: white;
  margin-bottom: var(--spacing-lg);
  font-size: var(--font-size-lg);
}

.footer-section p,
.footer-section a {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: var(--spacing-sm);
  display: block;
  transition: color var(--transition-fast);
}

.footer-section a:hover {
  color: white;
}

.footer-social {
  display: flex;
  gap: var(--spacing-md);
  margin-top: var(--spacing-lg);
}

.footer-social-link {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--font-size-lg);
  transition: all var(--transition-base);
}

.footer-social-link:hover {
  background: var(--color-primary);
  transform: translateY(-2px);
}

.footer-bottom {
  padding-top: var(--spacing-xl);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: var(--font-size-sm);
}

/* Breadcrumb */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-lg) 0;
  font-size: var(--font-size-sm);
}

.breadcrumb-item {
  color: var(--color-text-light);
}

.breadcrumb-item.active {
  color: var(--color-text);
  font-weight: var(--font-weight-medium);
}

.breadcrumb-separator {
  color: var(--color-text-lighter);
}

/* Page Header */
.page-header {
  background: linear-gradient(135deg, var(--color-primary-light), var(--color-secondary-light));
  padding: var(--spacing-3xl) 0;
  margin-top: var(--header-height);
  text-align: center;
  color: white;
}

.page-header h1 {
  color: white;
  margin-bottom: var(--spacing-md);
}

.page-header p {
  font-size: var(--font-size-lg);
  opacity: 0.95;
}

/* Sidebar Layout */
.layout-with-sidebar {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: var(--spacing-2xl);
  padding: var(--spacing-3xl) 0;
}

.sidebar {
  position: sticky;
  top: calc(var(--header-height) + var(--spacing-lg));
  height: fit-content;
}

/* Filters */
.filters {
  background: white;
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.filters-title {
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--spacing-lg);
}

.filter-group {
  margin-bottom: var(--spacing-xl);
}

.filter-group:last-child {
  margin-bottom: 0;
}

.filter-label {
  display: block;
  font-weight: var(--font-weight-medium);
  margin-bottom: var(--spacing-md);
  color: var(--color-text);
}

/* Responsive */
@media (max-width: 1024px) {
  .layout-with-sidebar {
    grid-template-columns: 1fr;
  }
  
  .sidebar {
    position: static;
  }
}

@media (max-width: 768px) {
  .header-nav {
    display: none;
    position: fixed;
    top: var(--mobile-header-height);
    left: 0;
    right: 0;
    background: white;
    flex-direction: column;
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-lg);
    gap: var(--spacing-lg);
  }
  
  .header-nav.active {
    display: flex;
  }
  
  .mobile-menu-toggle {
    display: block;
  }
  
  .hero {
    min-height: 500px;
  }
  
  .hero-title {
    font-size: var(--font-size-3xl);
  }
  
  .hero-subtitle {
    font-size: var(--font-size-base);
  }
  
  .footer-content {
    grid-template-columns: 1fr;
  }
}
