/* ==========================================================================
RESET BOX-SIZING (evite les debordements horizontaux sur mobile)
========================================================================== */
*, *::before, *::after {
	box-sizing: border-box;
}

html, body {
	overflow-x: hidden;
	max-width: 100%;
}

/* ==========================================================================
VARIABLES POUR LE HEADER
========================================================================== */
:root {
	--header-bg: #fdfcf5;
	--header-text: #333333;
	--header-border: #e0e0e0;
	--header-hover: #826E08;
	--header-active: #5b8c3e;
	--header-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
	--header-height: 80px;
	--info-bar-bg: #826E08;
	--info-bar-text: #ffffff;
}

/* ==========================================================================
HEADER PRINCIPAL
========================================================================== */
.site-header {
	position: sticky;
	top: 0;
	z-index: 1000;
	background: var(--header-bg);
	box-shadow: var(--header-shadow);
	transition: all 0.3s ease;
}

.site-header.scrolled {
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

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

/* ==========================================================================
LOGO
========================================================================== */
.header-logo {
	flex-shrink: 0;
	z-index: 1001;
}

.header-logo a {
	display: flex;
	align-items: center;
	text-decoration: none;
	transition: transform 0.3s ease;
}

.header-logo a:hover {
	transform: scale(1.05);
}

.header-logo img {
	height: 60px;
	width: auto;
	display: block;
}

/* ==========================================================================
NAVIGATION PRINCIPALE
========================================================================== */
.main-navigation {
	flex-grow: 1;
	display: flex;
	justify-content: center;
}

.nav-links {
	display: flex;
	list-style: none;
	margin: 0;
	padding: 0;
	gap: 0.5rem;
	align-items: center;
}

.nav-item {
	position: relative;
}

.nav-link {
	display: flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.75rem 1.25rem;
	color: var(--header-text);
	text-decoration: none;
	font-weight: 500;
	font-size: 0.95rem;
	border-radius: 8px;
	transition: all 0.3s ease;
	position: relative;
}

.nav-link:hover {
	color: var(--header-hover);
	background: rgba(130, 110, 8, 0.05);
}

.nav-link.active {
	color: var(--header-hover);
	font-weight: 600;
}

.nav-link.active::after {
	content: '';
	position: absolute;
	bottom: 8px;
	left: 50%;
	transform: translateX(-50%);
	width: 30px;
	height: 3px;
	background: var(--header-active);
	border-radius: 2px;
}

/* Icônes dans le menu */
.nav-icon {
	font-size: 1.1rem;
	display: inline-block;
}

/* Mise en avant de la boutique */
.nav-item-highlight .nav-link-shop {
	background: linear-gradient(135deg, #5b8c3e, #3f6b2a);
	color: white;
	font-weight: 600;
	box-shadow: 0 2px 8px rgba(91, 140, 62, 0.3);
}

.nav-item-highlight .nav-link-shop:hover {
	background: linear-gradient(135deg, #3f6b2a, #5b8c3e);
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(91, 140, 62, 0.4);
	color: white;
}

/* ==========================================================================
MENU DÉROULANT
========================================================================== */
.nav-item-dropdown {
	position: relative;
}

.dropdown-icon {
	font-size: 0.7rem;
	margin-left: 0.25rem;
	transition: transform 0.3s ease;
}

.nav-item-dropdown:hover .dropdown-icon {
	transform: rotate(180deg);
}

.dropdown-menu {
	position: absolute;
	top: calc(100% + 0.5rem);
	left: 50%;
	transform: translateX(-50%) translateY(-10px);
	background: white;
	border-radius: 8px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
	list-style: none;
	margin: 0;
	padding: 0.5rem 0;
	min-width: 240px;
	opacity: 0;
	visibility: hidden;
	transition: all 0.3s ease;
	z-index: 100;
}

.nav-item-dropdown:hover .dropdown-menu {
	opacity: 1;
	visibility: visible;
	transform: translateX(-50%) translateY(0);
}

.dropdown-menu li {
	margin: 0;
}

.dropdown-menu a {
	display: block;
	padding: 0.75rem 1.5rem;
	color: var(--header-text);
	text-decoration: none;
	transition: all 0.3s ease;
	font-weight: 500;
}

.dropdown-menu a:hover {
	background: rgba(130, 110, 8, 0.05);
	color: var(--header-hover);
	padding-left: 2rem;
}

/* ==========================================================================
BOUTON HAMBURGER (Mobile)
========================================================================== */
.hamburger {
	display: none;
	flex-direction: column;
	gap: 5px;
	background: none;
	border: none;
	cursor: pointer;
	padding: 0.5rem;
	z-index: 1001;
	transition: all 0.3s ease;
}

.hamburger-line {
	width: 28px;
	height: 3px;
	background: var(--header-text);
	border-radius: 2px;
	transition: all 0.3s ease;
}

.hamburger:hover .hamburger-line {
	background: var(--header-hover);
}

.hamburger.active .hamburger-line:nth-child(1) {
	transform: rotate(45deg) translate(8px, 8px);
}

.hamburger.active .hamburger-line:nth-child(2) {
	opacity: 0;
}

.hamburger.active .hamburger-line:nth-child(3) {
	transform: rotate(-45deg) translate(7px, -7px);
}

/* ==========================================================================
BARRE D'INFORMATIONS
========================================================================== */
.header-info-bar {
	background: var(--info-bar-bg);
	color: var(--info-bar-text);
	font-size: 0.875rem;
	padding: 0.5rem 0;
}

.info-bar-content {
	max-width: 1400px;
	margin: 0 auto;
	padding: 0 2rem;
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 2rem;
	flex-wrap: wrap;
}

.info-item {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.info-icon {
	font-size: 1rem;
}

.info-item a {
	color: var(--info-bar-text);
	text-decoration: none;
	font-weight: 500;
	transition: opacity 0.3s ease;
}

.info-item a:hover {
	opacity: 0.8;
	text-decoration: underline;
}

/* ==========================================================================
OVERLAY MENU MOBILE
========================================================================== */
.menu-overlay {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	z-index: 999;
	opacity: 0;
	transition: opacity 0.3s ease;
}

.menu-overlay.active {
	display: block;
	opacity: 1;
}

/* ==========================================================================
RESPONSIVE - TABLETTE
========================================================================== */
@media (max-width: 1024px) {
	.nav-links {
		gap: 0.25rem;
	}

	.nav-link {
		padding: 0.6rem 1rem;
		font-size: 0.9rem;
	}

	.nav-icon {
		display: none;
	}

	.info-bar-content {
		font-size: 0.8rem;
		gap: 1rem;
	}
}

/* ==========================================================================
RESPONSIVE - MOBILE
========================================================================== */
@media (max-width: 768px) {
	.header-container {
		padding: 0 1rem;
		height: 70px;
	}

	.header-logo img {
		height: 50px;
	}

	/* Afficher le hamburger */
	.hamburger {
		display: flex;
	}

	/* Menu mobile */
	.main-navigation {
		position: fixed;
		top: 70px;
		right: 0;
		width: 280px;
		height: calc(100vh - 70px);
		background: white;
		box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
		transform: translateX(100%);
		transition: transform 0.4s ease;
		z-index: 1000;
		overflow-y: auto;
	}

	.main-navigation.active {
		transform: translateX(0);
	}

	.nav-links {
		flex-direction: column;
		gap: 0;
		width: 100%;
		padding: 1rem 0;
	}

	.nav-item {
		width: 100%;
	}

	.nav-link {
		width: 100%;
		padding: 1rem 1.5rem;
		border-radius: 0;
		justify-content: flex-start;
		border-bottom: 1px solid var(--header-border);
	}

	.nav-icon {
		display: inline-block;
		font-size: 1.3rem;
	}

	.nav-link.active::after {
		display: none;
	}

	.nav-link.active {
		background: rgba(130, 110, 8, 0.08);
		border-left: 4px solid var(--header-hover);
	}

	/* Menu déroulant mobile */
	.nav-item-dropdown .dropdown-menu{
		position: static;
		opacity: 1;
		visibility: visible;
		transform: none;
		box-shadow: none;
		margin: 0;
		padding: 0;
		background: rgba(130, 110, 8, 0.03);
		border-radius: 0;
		max-height: 0;
		overflow: hidden;
		display: none;
		transition: max-height 0.3s ease;
	}
	
	.nav-item-dropdown.active .dropdown-menu {
		display: block;
		max-height: 500px;
		background: rgba(130, 110, 8, 0.03);
	}

	.dropdown-menu a {
		padding-left: 3rem;
		border-bottom: 1px solid rgba(224, 224, 224, 0.5);
		font-size: 0.9rem;
	}

	.dropdown-menu a:hover {
		padding-left: 3.5rem;
	}

.nav-item-highlight {
	margin: 1rem;
	border-radius: 8px;
	overflow: hidden;
}

.nav-item-highlight .nav-link-shop {
	border-radius: 8px;
	background: linear-gradient(135deg, #5b8c3e, #3f6b2a) !important;
	color: white !important;
	font-weight: 600;
	box-shadow: 0 2px 8px rgba(91, 140, 62, 0.3);
	border-bottom: none !important;
	border-left: none !important;
}

.nav-item-highlight .nav-link-shop:hover,
.nav-item-highlight .nav-link-shop:active {
	background: linear-gradient(135deg, #3f6b2a, #5b8c3e) !important;
	color: white !important;
}

	/* Barre d'infos mobile */
	.header-info-bar {
		display: none;
	}

	/* Afficher la barre d'infos dans le menu mobile */
	.main-navigation.active ~ .header-info-bar {
		display: block;
		position: fixed;
		bottom: 0;
		left: auto;
		right: 0;
		width: 280px;
		z-index: 1000;
	}

	.info-bar-content {
		flex-direction: column;
		gap: 0.75rem;
		padding: 1rem;
		text-align: center;
	}

	.info-item {
		justify-content: center;
	}
}

@media (max-width: 480px) {
	.main-navigation {
		width: 100%;
	}

	.main-navigation.active ~ .header-info-bar {
		width: 100%;
	}
}

/* ==========================================================================
ANIMATIONS
========================================================================== */
@keyframes slideInFromRight {
	from {
		transform: translateX(100%);
		opacity: 0;
	}
	to {
		transform: translateX(0);
		opacity: 1;
	}
}

.nav-item {
	animation: slideInFromRight 0.3s ease-out backwards;
}

.nav-item:nth-child(1) { animation-delay: 0.05s; }
.nav-item:nth-child(2) { animation-delay: 0.1s; }
.nav-item:nth-child(3) { animation-delay: 0.15s; }
.nav-item:nth-child(4) { animation-delay: 0.2s; }
.nav-item:nth-child(5) { animation-delay: 0.25s; }
.nav-item:nth-child(6) { animation-delay: 0.3s; }
.nav-item:nth-child(7) { animation-delay: 0.35s; }

/* ==========================================================================
ACCESSIBILITÉ
========================================================================== */
@media (prefers-reduced-motion: reduce) {
	.site-header,
	.nav-link,
	.hamburger-line,
	.main-navigation,
	.menu-overlay {
		transition: none !important;
	}

	.nav-item {
		animation: none !important;
	}
}

/* Focus pour navigation clavier */
.nav-link:focus-visible,
.hamburger:focus-visible {
	outline: 3px solid var(--header-active);
	outline-offset: 2px;
}

/* Skip to content (accessibilité) */
.skip-to-content {
	position: absolute;
	top: -40px;
	left: 0;
	background: var(--header-hover);
	color: white;
	padding: 0.5rem 1rem;
	text-decoration: none;
	z-index: 100;
	transition: top 0.3s ease;
}

.skip-to-content:focus {
	top: 0;
}