/**
 * Trimidi HSE — main.css v1.8
 *
 * Reset moderne + typo Fraunces (display) + Inter (body)
 * Layout aéré, rythme musical, anti-bans respectés.
 */

/* ════════════════════════════════════════════════════════════════════
   RESET MODERNE
   ════════════════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: var(--th-header-height);
}

body {
	font-family: var(--th-font);
	font-size: var(--th-fs-base);
	line-height: 1.6;
	color: var(--th-text);
	background: var(--th-bg);
	font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

img, svg, video { display: block; max-width: 100%; height: auto; }

/* ════════════════════════════════════════════════════════════════════
   TYPOGRAPHIE — Fraunces pour titres, Inter pour body
   Hiérarchie scale 1.333 (perfect fourth)
   ════════════════════════════════════════════════════════════════════ */

h1, h2, h3, h4, h5, h6, .display {
	font-family: var(--th-font-display);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: -0.02em;
	color: var(--th-text);
}

.display {
	font-size: clamp(var(--th-fs-3xl), 7vw, var(--th-fs-5xl));
	font-weight: 900;
	letter-spacing: -0.035em;
}

h1 { font-size: clamp(var(--th-fs-3xl), 6vw, var(--th-fs-4xl)); }
h2 { font-size: clamp(var(--th-fs-2xl), 4.5vw, var(--th-fs-3xl)); }
h3 { font-size: var(--th-fs-xl); font-weight: 700; }
h4 { font-size: var(--th-fs-lg); font-weight: 700; }
h5 { font-size: var(--th-fs-base); font-weight: 700; }
h6 { font-size: var(--th-fs-sm); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }

p { max-width: var(--th-measure); }
p + p { margin-top: 0.75em; }

a {
	color: var(--th-primary);
	text-decoration: underline;
	text-underline-offset: 0.18em;
	text-decoration-thickness: 0.08em;
	transition: color var(--th-transition);
}
a:hover { color: var(--th-accent-dark); }

/* Lede (paragraphe d'introduction de section) */
.lede {
	font-size: var(--th-fs-lg);
	color: var(--th-text-soft);
	max-width: 55ch;
	line-height: 1.55;
}

/* Kicker (eyebrow text au-dessus des titres) */
.kicker {
	font-family: var(--th-font);
	font-size: var(--th-fs-xs);
	text-transform: uppercase;
	letter-spacing: 0.16em;
	font-weight: 600;
	color: var(--th-accent);
	margin-bottom: 0.75rem;
}

/* Sélection texte (sobre, pas criard) */
::selection {
	background: var(--th-accent);
	color: var(--th-white);
}

/* ════════════════════════════════════════════════════════════════════
   LAYOUT — Conteneurs, sections, grilles
   ════════════════════════════════════════════════════════════════════ */

.wrap, .container {
	width: 100%;
	max-width: var(--th-container);
	margin: 0 auto;
	padding: 0 var(--th-sp-5);
}
.wrap--narrow, .container--narrow {
	max-width: var(--th-container-sm);
}

section { padding: var(--th-space-section) 0; }

/* Sections alternées (sable warm) */
section.bg-warm  { background: var(--th-paper-warm); }
section.bg-paper { background: var(--th-bg); }
section.bg-navy  { background: var(--th-primary-dark); color: var(--th-white); }

/* ════════════════════════════════════════════════════════════════════
   HEADER STICKY (avec backdrop-filter discret)
   ════════════════════════════════════════════════════════════════════ */

.site-header {
	position: sticky;
	top: 0;
	background: var(--th-bg);
	border-bottom: 1px solid var(--th-border);
	z-index: 50;
	backdrop-filter: saturate(180%) blur(10px);
	-webkit-backdrop-filter: saturate(180%) blur(10px);
}

/* ════════════════════════════════════════════════════════════════════
   ACCESSIBILITY
   ════════════════════════════════════════════════════════════════════ */

/* Skip link visible au focus */
.skip-link {
	position: absolute;
	top: -40px;
	left: 0;
	background: var(--th-primary);
	color: var(--th-white);
	padding: 8px 16px;
	z-index: 100;
	text-decoration: none;
	border-radius: 0 0 var(--th-radius) 0;
}
.skip-link:focus { top: 0; }

/* Focus visible (clavier uniquement) */
*:focus-visible {
	outline: 2px solid var(--th-accent);
	outline-offset: 3px;
	border-radius: 3px;
}

/* Réduction des animations pour les utilisateurs sensibles */
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

/* ════════════════════════════════════════════════════════════════════
   UTILITIES
   ════════════════════════════════════════════════════════════════════ */

.text-center { text-align: center; }
.text-soft   { color: var(--th-text-soft); }
.text-muted  { color: var(--th-muted); }
.text-accent { color: var(--th-accent); }

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Touche créole en italique cuivre */
.signature-creole {
	font-family: var(--th-font-display);
	font-style: italic;
	color: var(--th-accent);
}
