/**
 * DEVCON7 — Header & footer « agence »
 * Identité : #0A2540 · #00C6FF · #F5A623 · Inter
 *
 * @package Devcon7_Theme
 */

/* -----------------------------------------------------------------------------
 * Variables locales (complètent style.css)
 * ----------------------------------------------------------------------------- */
:root {
	--dc7-h-accent: #00c6ff;
	--dc7-h-gold: #f5a623;
	--dc7-h-night: #0a2540;
	/* Hauteur « barre » hors encoche ; l’encoche est ajoutée sur le masthead */
	--dc7-header-h: clamp(4.25rem, 5vw, 5.25rem);
	--dc7-header-h-shrunk: 3.5rem;
	--dc7-safe-top: env(safe-area-inset-top, 0px);
	--dc7-font: "Inter", system-ui, sans-serif;
}

/* -----------------------------------------------------------------------------
 * Skip link (accessibilité) — reste visible au focus
 * ----------------------------------------------------------------------------- */
.screen-reader-text:focus,
.skip-link:focus {
	clip: auto !important;
	height: auto;
	left: 8px;
	top: 8px;
	width: auto;
	z-index: 100000;
	padding: 0.5rem 1rem;
	background: var(--dc7-h-night);
	color: var(--dc7-h-accent);
	border: 2px solid var(--dc7-h-accent);
	border-radius: 4px;
	text-decoration: none;
	font-weight: 700;
}

/* -----------------------------------------------------------------------------
 * Compensation header fixe — hauteur réelle = barre + encoche (safe-area)
 * ----------------------------------------------------------------------------- */
body.dc7-fixed-masthead {
	padding-top: calc(var(--dc7-header-h) + var(--dc7-safe-top));
}

body.dc7-fixed-masthead.dc7-header-shrunk {
	padding-top: calc(var(--dc7-header-h-shrunk) + var(--dc7-safe-top));
}

/* Barre d’admin WP : le masthead ne doit pas passer sous elle (sinon « coupé ») */
.admin-bar .dc7-masthead {
	top: 32px;
}

@media screen and (max-width: 782px) {
	.admin-bar .dc7-masthead {
		top: 46px;
	}
}

/*
 * Ne pas cumuler avec margin-top html de WP : évite double bande vide.
 * (WP pousse souvent le flux via margin/padding sur html — le masthead reste en fixed sur le viewport.)
 */
html {
	scroll-padding-top: calc(var(--dc7-header-h) + var(--dc7-safe-top));
}

body.admin-bar {
	scroll-padding-top: calc(32px + var(--dc7-header-h) + var(--dc7-safe-top));
}

@media screen and (max-width: 782px) {
	body.admin-bar {
		scroll-padding-top: calc(46px + var(--dc7-header-h) + var(--dc7-safe-top));
	}
}

/*
 * GeneratePress : padding / marge au-dessus du premier bloc — sinon ~40px + 20px
 * de vide entre le bas du masthead fixe et le hero (sans être « poussé » par la barre admin).
 */
body.dc7-fixed-masthead.separate-containers .inside-article {
	padding-top: 0;
}

body.dc7-fixed-masthead.separate-containers .site-main {
	margin-top: 0;
}

body.dc7-fixed-masthead.one-container .site-content {
	padding-top: 0;
}

/* -----------------------------------------------------------------------------
 * HEADER — Glassmorphism + structure
 * ----------------------------------------------------------------------------- */
.dc7-masthead {
	--dc7-glass-bg: rgba(10, 37, 64, 0.72);
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 10050;
	/* Bande encoche + hauteur utile ; box-sizing pour hauteur totale prévisible */
	box-sizing: border-box;
	padding-top: var(--dc7-safe-top);
	height: calc(var(--dc7-header-h) + var(--dc7-safe-top));
	font-family: var(--dc7-font);
	transition: height 0.35s ease, box-shadow 0.35s ease;
	box-shadow: 0 0 0 rgba(0, 198, 255, 0);
	display: flex;
	flex-direction: column;
}

.dc7-masthead::before {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(
		105deg,
		rgba(0, 198, 255, 0.08) 0%,
		transparent 40%,
		rgba(245, 166, 35, 0.06) 70%,
		transparent 100%
	);
	background-size: 200% 100%;
	animation: dc7-header-gradient 14s ease-in-out infinite;
	pointer-events: none;
	opacity: 0.85;
}

@keyframes dc7-header-gradient {
	0%,
	100% {
		background-position: 0% 50%;
	}
	50% {
		background-position: 100% 50%;
	}
}

.dc7-masthead__glass {
	position: absolute;
	inset: 0;
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	background: var(--dc7-glass-bg);
	border-bottom: 1px solid rgba(0, 198, 255, 0.12);
	pointer-events: none;
}

/* Particules or (points décoratifs) */
.dc7-masthead__particles {
	position: absolute;
	inset: 0;
	pointer-events: none;
	overflow: hidden;
	z-index: 1;
}

.dc7-masthead__particle {
	position: absolute;
	width: 4px;
	height: 4px;
	border-radius: 50%;
	background: var(--dc7-h-gold);
	box-shadow: 0 0 10px rgba(245, 166, 35, 0.7);
	opacity: 0.45;
}

.dc7-masthead__inner {
	position: relative;
	z-index: 2;
	max-width: 1240px;
	margin: 0 auto;
	padding: 0 clamp(1rem, 3vw, 1.75rem);
	flex: 1 1 auto;
	min-height: 0;
	height: auto;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
}

/* Logo + D 3D + pulse satellite */
.dc7-masthead__logo {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	text-decoration: none;
	color: #f8fafc;
	font-weight: 800;
	font-size: clamp(1.15rem, 2vw, 1.35rem);
	letter-spacing: -0.03em;
	position: relative;
	perspective: 420px;
}

.dc7-masthead__logo-d {
	display: inline-block;
	transform-style: preserve-3d;
	color: var(--dc7-h-accent);
	will-change: transform;
}

.dc7-masthead__logo-pulse {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--dc7-h-gold);
	box-shadow: 0 0 0 0 rgba(245, 166, 35, 0.5);
	animation: dc7-satellite-pulse 2.2s ease-out infinite;
	flex-shrink: 0;
}

@keyframes dc7-satellite-pulse {
	0% {
		box-shadow: 0 0 0 0 rgba(245, 166, 35, 0.55);
		transform: scale(1);
	}
	60% {
		box-shadow: 0 0 0 12px rgba(245, 166, 35, 0);
		transform: scale(1.05);
	}
	100% {
		box-shadow: 0 0 0 0 rgba(245, 166, 35, 0);
		transform: scale(1);
	}
}

/* Navigation centrale */
.dc7-masthead__nav {
	display: none;
	flex: 1;
	justify-content: center;
	max-width: 36rem;
}

@media (min-width: 960px) {
	.dc7-masthead__nav {
		display: flex;
	}
}

.dc7-masthead__nav-list-wrap {
	position: relative;
}

.dc7-masthead__nav-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.25rem;
}

.dc7-masthead__nav-list a {
	display: block;
	padding: 0.5rem 0.85rem;
	color: rgba(248, 250, 252, 0.88);
	text-decoration: none;
	font-weight: 600;
	font-size: 0.875rem;
	letter-spacing: 0.02em;
	border-radius: 6px;
	position: relative;
	transition: color 0.2s ease;
}

.dc7-masthead__nav-list a:hover,
.dc7-masthead__nav-list a:focus-visible {
	color: var(--dc7-h-accent);
}

.dc7-masthead__nav-list a.is-active {
	color: var(--dc7-h-accent);
}

.dc7-masthead__nav-indicator {
	position: absolute;
	left: 0;
	bottom: 0;
	height: 3px;
	width: 0;
	border-radius: 2px;
	background: linear-gradient(90deg, var(--dc7-h-accent), var(--dc7-h-gold));
	pointer-events: none;
	opacity: 0;
	box-shadow: 0 0 12px rgba(0, 198, 255, 0.45);
}

/* CTA shimmer */
.dc7-masthead__cta-wrap {
	display: none;
}

@media (min-width: 960px) {
	.dc7-masthead__cta-wrap {
		display: block;
		flex-shrink: 0;
	}
}

.dc7-masthead__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.65rem 1.35rem;
	border-radius: 999px;
	font-weight: 700;
	font-size: 0.8125rem;
	text-decoration: none;
	color: var(--dc7-h-night);
	background: linear-gradient(135deg, var(--dc7-h-accent), #0099c9);
	border: none;
	cursor: pointer;
	position: relative;
	overflow: hidden;
	white-space: nowrap;
}

.dc7-masthead__cta::after {
	content: "";
	position: absolute;
	top: 0;
	left: -120%;
	width: 60%;
	height: 100%;
	background: linear-gradient(
		90deg,
		transparent,
		rgba(255, 255, 255, 0.55),
		transparent
	);
	animation: dc7-shimmer 3.5s ease-in-out infinite;
}

@keyframes dc7-shimmer {
	0% {
		left: -120%;
	}
	40%,
	100% {
		left: 220%;
	}
}

.dc7-masthead__cta:hover,
.dc7-masthead__cta:focus-visible {
	filter: brightness(1.06);
	color: var(--dc7-h-night);
}

/* Ligne néon bas de header (état scroll géré en JS / classe) */
.dc7-masthead__neon {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 2px;
	background: linear-gradient(90deg, transparent, var(--dc7-h-accent), transparent);
	opacity: 0;
	transform: scaleX(0.3);
	transform-origin: center;
	pointer-events: none;
	z-index: 3;
	box-shadow: 0 0 16px rgba(0, 198, 255, 0.65);
}

.dc7-masthead.is-scrolled .dc7-masthead__neon {
	opacity: 1;
	transform: scaleX(1);
	transition: opacity 0.35s ease, transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

body.dc7-header-shrunk .dc7-masthead {
	height: calc(var(--dc7-header-h-shrunk) + var(--dc7-safe-top));
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

/* Burger mobile */
.dc7-masthead__burger {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 6px;
	width: 44px;
	height: 44px;
	padding: 0;
	border: none;
	background: transparent;
	cursor: pointer;
	z-index: 10060;
	position: relative;
}

.dc7-masthead__burger span {
	display: block;
	height: 2px;
	width: 24px;
	background: #f8fafc;
	border-radius: 1px;
	margin: 0 auto;
	transform-origin: 50% 50%;
}

@media (min-width: 960px) {
	.dc7-masthead__burger {
		display: none;
	}
}

/* Overlay menu plein écran */
.dc7-nav-overlay {
	position: fixed;
	inset: 0;
	z-index: 10055;
	background: var(--dc7-h-night);
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: stretch;
	padding: 5rem clamp(1.25rem, 5vw, 3rem);
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: visibility 0.3s, opacity 0.3s;
}

.dc7-nav-overlay.is-open {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.dc7-nav-overlay__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.dc7-nav-overlay__list li {
	border-bottom: 1px solid rgba(0, 198, 255, 0.12);
	opacity: 0;
	transform: translateY(16px);
}

.dc7-nav-overlay__list a {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 1.15rem 0;
	color: #f8fafc;
	text-decoration: none;
	font-size: 1.35rem;
	font-weight: 700;
}

.dc7-nav-overlay__num {
	font-size: 0.75rem;
	font-weight: 800;
	color: var(--dc7-h-gold);
	letter-spacing: 0.08em;
	min-width: 2rem;
}

/* -----------------------------------------------------------------------------
 * FOOTER — Cinématique
 * ----------------------------------------------------------------------------- */
.dc7-foot {
	position: relative;
	font-family: var(--dc7-font);
	background: var(--dc7-h-night);
	color: rgba(248, 250, 252, 0.9);
	overflow: hidden;
}

/* Grille de points animée */
.dc7-foot__dotgrid {
	position: absolute;
	inset: 0;
	background-image: radial-gradient(rgba(0, 198, 255, 0.14) 1px, transparent 1px);
	background-size: 22px 22px;
	opacity: 0.35;
	animation: dc7-dot-drift 80s linear infinite;
	pointer-events: none;
}

@keyframes dc7-dot-drift {
	0% {
		background-position: 0 0;
	}
	100% {
		background-position: 220px 220px;
	}
}

.dc7-foot__glow {
	position: absolute;
	left: 50%;
	bottom: 0;
	transform: translateX(-50%);
	width: min(90%, 720px);
	height: 120px;
	background: radial-gradient(ellipse at center, rgba(0, 198, 255, 0.22), transparent 70%);
	animation: dc7-foot-glow 4s ease-in-out infinite;
	pointer-events: none;
}

@keyframes dc7-foot-glow {
	0%,
	100% {
		opacity: 0.55;
		transform: translateX(-50%) scale(1);
	}
	50% {
		opacity: 1;
		transform: translateX(-50%) scale(1.05);
	}
}

.dc7-foot__inner {
	position: relative;
	z-index: 1;
	max-width: 1140px;
	margin: 0 auto;
	padding: clamp(3rem, 6vw, 5rem) clamp(1.25rem, 4vw, 2rem) 2rem;
}

/* Mot à mot : conteneur titre */
.dc7-foot-hero__title {
	font-size: clamp(1.75rem, 4vw, 2.75rem);
	font-weight: 800;
	line-height: 1.15;
	text-align: center;
	color: #f8fafc;
	margin: 0 0 1.75rem;
	max-width: 900px;
	margin-left: auto;
	margin-right: auto;
}

.dc7-foot-hero__title .dc7-word {
	display: inline-block;
	margin-right: 0.35em;
	opacity: 0;
	transform: translateY(24px);
	will-change: transform, opacity;
}

.dc7-foot-hero__title .dc7-word:last-child {
	margin-right: 0;
}

.dc7-foot-hero__cta {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1.5rem;
	margin-bottom: 2.5rem;
}

.dc7-foot-cta {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 1.1rem 2.5rem;
	border-radius: 999px;
	font-weight: 800;
	font-size: 1rem;
	text-decoration: none;
	color: var(--dc7-h-night);
	background: linear-gradient(135deg, var(--dc7-h-accent), #00a8d9);
	border: none;
	cursor: pointer;
	overflow: hidden;
	box-shadow: 0 12px 40px rgba(0, 198, 255, 0.35);
}

.dc7-foot-cta .dc7-ripple {
	position: absolute;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.45);
	pointer-events: none;
	transform: scale(0);
	opacity: 0;
}

/* Ligne décorative clip-path (animation GSAP sur inline) */
.dc7-foot__rule-wrap {
	max-width: 560px;
	margin: 0 auto 3rem;
	height: 3px;
}

.dc7-foot__rule {
	height: 100%;
	width: 100%;
	background: linear-gradient(90deg, transparent, var(--dc7-h-accent), var(--dc7-h-gold), transparent);
	border-radius: 2px;
	clip-path: inset(0 100% 0 0);
	will-change: clip-path;
}

/* Grille 3 colonnes */
.dc7-foot-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2.5rem;
	margin-bottom: 3rem;
}

@media (min-width: 900px) {
	.dc7-foot-grid {
		grid-template-columns: 1.1fr 1fr 0.9fr;
		gap: 2rem;
	}
}

.dc7-foot-col h3 {
	font-size: 0.6875rem;
	text-transform: uppercase;
	letter-spacing: 0.18em;
	color: var(--dc7-h-accent);
	margin: 0 0 1rem;
}

.dc7-foot-col p {
	margin: 0;
	font-size: 0.9375rem;
	line-height: 1.65;
	color: rgba(248, 250, 252, 0.72);
}

.dc7-foot-logo {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	font-weight: 800;
	font-size: 1.2rem;
	color: #f8fafc;
	margin-bottom: 0.75rem;
}

.dc7-foot-logo span {
	color: var(--dc7-h-accent);
}

.dc7-foot-social {
	display: flex;
	gap: 0.75rem;
	margin-top: 1.25rem;
	perspective: 640px;
}

.dc7-tilt-icon {
	transform-style: preserve-3d;
}

.dc7-foot-social a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 12px;
	background: rgba(0, 198, 255, 0.1);
	border: 1px solid rgba(0, 198, 255, 0.25);
	color: var(--dc7-h-accent);
	transition: transform 0.2s ease, border-color 0.2s;
}

.dc7-foot-social a:hover,
.dc7-foot-social a:focus-visible {
	border-color: var(--dc7-h-gold);
	color: var(--dc7-h-gold);
}

.dc7-foot-services__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.dc7-foot-services__list li {
	margin-bottom: 0.65rem;
}

.dc7-foot-services__list a {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	color: rgba(248, 250, 252, 0.88);
	text-decoration: none;
	font-weight: 600;
	font-size: 0.9375rem;
}

.dc7-foot-services__list a .dc7-arrow {
	opacity: 0;
	transform: translateX(-6px);
	transition: opacity 0.2s, transform 0.2s;
	color: var(--dc7-h-accent);
}

.dc7-foot-services__list a:hover .dc7-arrow,
.dc7-foot-services__list a:focus-visible .dc7-arrow {
	opacity: 1;
	transform: translateX(0);
}

.dc7-foot-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	margin-top: 1rem;
	padding: 0.45rem 0.9rem;
	border-radius: 999px;
	background: rgba(245, 166, 35, 0.12);
	border: 1px solid rgba(245, 166, 35, 0.35);
	font-size: 0.8125rem;
	font-weight: 700;
	color: var(--dc7-h-gold);
}

.dc7-foot-live {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.35rem;
	margin-top: 1rem;
	font-size: 0.875rem;
	color: rgba(248, 250, 252, 0.65);
}

.dc7-foot-live strong {
	color: var(--dc7-h-accent);
	font-variant-numeric: tabular-nums;
	font-size: 1.125rem;
}

/* Barre basse */
.dc7-foot-bar {
	position: relative;
	z-index: 1;
	border-top: 1px solid rgba(0, 198, 255, 0.12);
	padding: 1.25rem clamp(1.25rem, 4vw, 2rem);
	background: rgba(0, 0, 0, 0.2);
}

.dc7-foot-bar__inner {
	max-width: 1140px;
	margin: 0 auto;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	font-size: 0.8125rem;
	color: rgba(248, 250, 252, 0.55);
}

.dc7-foot-bar__djiz {
	color: var(--dc7-h-gold);
	font-weight: 700;
}

.dc7-foot-bar__time {
	font-variant-numeric: tabular-nums;
	color: rgba(248, 250, 252, 0.75);
}

.dc7-foot-bar__status {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
}

.dc7-foot-bar__dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: #22c55e;
	box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.45);
	animation: dc7-status-pulse 2s ease-out infinite;
}

@keyframes dc7-status-pulse {
	0% {
		box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.5);
	}
	70% {
		box-shadow: 0 0 0 10px rgba(34, 197, 94, 0);
	}
	100% {
		box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
	}
}

/* Curseur custom : masquer le curseur natif (classe posée par cursor.js) */
body.dc7-custom-cursor,
body.dc7-custom-cursor * {
	cursor: none !important;
}

.dc7-cursor {
	pointer-events: none;
	z-index: 99999;
	mix-blend-mode: normal;
}

.dc7-cursor__ring {
	position: fixed;
	left: 0;
	top: 0;
	width: 40px;
	height: 40px;
	border: 2px solid var(--dc7-h-accent);
	border-radius: 50%;
	box-sizing: border-box;
	opacity: 0.85;
	will-change: transform;
	pointer-events: none;
}

.dc7-cursor__dot {
	position: fixed;
	left: 0;
	top: 0;
	width: 6px;
	height: 6px;
	background: var(--dc7-h-gold);
	border-radius: 50%;
	will-change: transform;
	pointer-events: none;
}

.dc7-cursor.is-press .dc7-cursor__ring {
	transform: scale(0.85);
}

body.dc7-cursor-hover .dc7-cursor__ring {
	border-color: var(--dc7-h-gold);
	transform: scale(1.35);
}

/* Réduction des animations (accessibilité) */
@media (prefers-reduced-motion: reduce) {
	.dc7-masthead::before,
	.dc7-masthead__logo-pulse,
	.dc7-masthead__cta::after,
	.dc7-foot__dotgrid,
	.dc7-foot__glow,
	.dc7-foot-bar__dot {
		animation: none !important;
	}

	body.dc7-custom-cursor,
	body.dc7-custom-cursor * {
		cursor: auto !important;
	}
}
