/*
	Nouvelle direction artistique : sombre et épurée.
	Le vert #089c91 du site reste la couleur d'accent.
*/

@font-face {
	font-family: 'Open Sans';
	src: url('../fonts/open-sans-fontfacekit/OpenSans-Light-webfont.woff') format('woff');
	font-weight: 300;
	font-display: swap;
}

@font-face {
	font-family: 'Open Sans';
	src: url('../fonts/open-sans-fontfacekit/OpenSans-Regular-webfont.woff') format('woff');
	font-weight: 400;
	font-display: swap;
}

@font-face {
	font-family: 'Open Sans';
	src: url('../fonts/open-sans-fontfacekit/OpenSans-Semibold-webfont.woff') format('woff');
	font-weight: 600;
	font-display: swap;
}

@font-face {
	font-family: 'Open Sans';
	src: url('../fonts/open-sans-fontfacekit/OpenSans-Bold-webfont.woff') format('woff');
	font-weight: 700;
	font-display: swap;
}

@font-face {
	font-family: 'Aaargh';
	src: url('../fonts/Aaargh-fontfacekit/Aaargh-webfont.woff') format('woff');
	font-weight: 400;
	font-display: swap;
}

:root {
	--fond: #0d1012;
	--surface: #151a1d;
	--surface-2: #1c2226;
	--trait: rgba(255, 255, 255, 0.08);
	--texte: #e9eeee;
	--texte-doux: #9aa6a8;
	--accent: #089c91;
	--accent-clair: #1fc2b4;
	--largeur: 1200px;
	--marge: clamp(16px, 4vw, 48px);
	--rayon: 6px;
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
	-webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
}

body {
	margin: 0;
	background: var(--fond);
	color: var(--texte);
	font-family: 'Open Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
	font-size: 16px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

img {
	display: block;
	max-width: 100%;
}

a {
	color: inherit;
	text-decoration: none;
}

h1, h2, h3, p {
	margin: 0;
}

:focus-visible {
	outline: 2px solid var(--accent-clair);
	outline-offset: 3px;
}

/* ---------- En-tête ---------- */

.entete {
	position: sticky;
	top: 0;
	z-index: 50;
	background: rgba(13, 16, 18, 0.72);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	border-bottom: 1px solid var(--trait);
}

.entete-contenu {
	display: flex;
	align-items: center;
	gap: 24px;
	max-width: var(--largeur);
	margin: 0 auto;
	padding: 14px var(--marge);
}

.logo {
	font-family: 'Aaargh', 'Open Sans', sans-serif;
	font-size: 26px;
	line-height: 1;
	letter-spacing: 0.02em;
	white-space: nowrap;
}

.logo strong {
	font-weight: 400;
	text-transform: uppercase;
	color: var(--accent-clair);
}

.nav-principale {
	display: flex;
	gap: 4px;
	margin-left: auto;
}

.nav-principale a,
.langues a {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--texte-doux);
	padding: 8px 12px;
	border-radius: var(--rayon);
	transition: color .2s, background-color .2s;
}

.nav-principale a:hover,
.langues a:hover {
	color: var(--texte);
	background: var(--surface-2);
}

.nav-principale a.current_page {
	color: var(--texte);
	box-shadow: inset 0 -2px 0 var(--accent);
	border-radius: 0;
}

.langues {
	display: flex;
	padding-left: 16px;
	border-left: 1px solid var(--trait);
}

.langues a {
	padding: 8px 8px;
}

.langues a[aria-current] {
	color: var(--accent-clair);
}

/* ---------- Boutons ---------- */

.bouton {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 13px 22px;
	border-radius: var(--rayon);
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	transition: background-color .2s, color .2s, border-color .2s, transform .2s;
}

.bouton-plein {
	background: var(--accent);
	color: #fff;
}

.bouton-plein:hover {
	background: var(--accent-clair);
	transform: translateY(-1px);
}

.bouton-contour {
	border: 1px solid rgba(255, 255, 255, 0.35);
	color: var(--texte);
}

.bouton-contour:hover {
	border-color: var(--texte);
	background: rgba(255, 255, 255, 0.06);
}

.icone-lecture {
	width: 0;
	height: 0;
	border-style: solid;
	border-width: 6px 0 6px 10px;
	border-color: transparent transparent transparent currentColor;
}

/* ---------- Accueil : texte et demoreel côte à côte ---------- */
/* Objectif : tout l'accueil (titre, demoreel, catégories) visible sans défiler sur un écran d'ordinateur */

.accueil {
	position: relative;
	isolation: isolate;
	overflow: hidden;
}

.hero-image {
	position: absolute;
	top: 0;
	left: 0;
	width: 50%;
	height: 100%;
	object-fit: cover;
	object-position: 50% 15%;
	opacity: 0.35;
	z-index: -1;
	-webkit-mask-image: linear-gradient(90deg, #000 30%, transparent 100%), linear-gradient(0deg, transparent 0%, #000 35%);
	-webkit-mask-composite: source-in;
	mask-image: linear-gradient(90deg, #000 30%, transparent 100%), linear-gradient(0deg, transparent 0%, #000 35%);
	mask-composite: intersect;
}

.accueil-contenu {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: center;
	gap: 48px;
	max-width: var(--largeur);
	margin: 0 auto;
	padding: clamp(24px, 4.5vh, 56px) var(--marge) 0;
}

.hero-surtitre {
	color: var(--accent-clair);
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	margin-bottom: 14px;
}

.accueil h1 {
	font-family: 'Aaargh', 'Open Sans', sans-serif;
	font-weight: 400;
	font-size: clamp(34px, 3.8vw, 56px);
	line-height: 1.05;
	letter-spacing: 0.01em;
	text-transform: uppercase;
}

.hero-metier {
	margin-top: 14px;
	font-size: 17px;
	font-weight: 300;
	color: var(--texte-doux);
}

.reel-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 12px;
	margin-top: 28px;
}

.bouton-lien {
	color: var(--texte-doux);
	padding-left: 8px;
	padding-right: 8px;
}

.bouton-lien:hover {
	color: var(--accent-clair);
}

/* La vidéo prend la place que la hauteur de l'écran laisse */
.accueil .reel {
	width: min(680px, max(400px, calc((100svh - 470px) * 16 / 9)));
}

/* ---------- Demoreel ---------- */

.reel {
	position: relative;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	border-radius: var(--rayon);
	background: #000;
	box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}

.reel img,
.reel iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
	object-fit: cover;
}

.reel-lecture {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 16px;
	width: 100%;
	padding: 0;
	border: 0;
	background: linear-gradient(0deg, rgba(0, 0, 0, 0.55) 0%, rgba(0, 0, 0, 0.1) 60%);
	color: #fff;
	font: inherit;
	cursor: pointer;
}

.reel-rond {
	display: flex;
	align-items: center;
	justify-content: center;
	width: clamp(64px, 9vw, 96px);
	aspect-ratio: 1;
	padding-left: 6px;
	border-radius: 50%;
	background: var(--accent);
	box-shadow: 0 10px 30px rgba(8, 156, 145, 0.45);
	transition: transform .3s, background-color .3s;
}

.reel-rond .icone-lecture {
	border-width: 14px 0 14px 22px;
}

.reel-texte {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	text-shadow: 0 2px 10px rgba(0, 0, 0, 0.6);
}

.reel-lecture:hover .reel-rond {
	transform: scale(1.08);
	background: var(--accent-clair);
}

/* ---------- Blocs de contenu ---------- */

.bloc {
	max-width: var(--largeur);
	margin: 0 auto;
	padding: 72px var(--marge) 0;
	scroll-margin-top: 80px;
}

.bloc-explorer {
	padding-top: clamp(28px, 4.5vh, 56px);
}

.bloc-titre {
	display: flex;
	align-items: center;
	gap: 18px;
	margin-bottom: 18px;
}

.bloc-titre h2 {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--texte-doux);
}

.bloc-titre::after {
	content: '';
	flex: 1;
	height: 1px;
	background: var(--trait);
}

/* ---------- Catégories ---------- */

.categories {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
}

.categorie-carte {
	position: relative;
	display: flex;
	flex-direction: column;
	background: var(--surface);
	border: 1px solid var(--trait);
	border-radius: var(--rayon);
	overflow: hidden;
	transition: border-color .3s, transform .3s;
}

.categorie-carte:hover {
	border-color: rgba(31, 194, 180, 0.5);
	transform: translateY(-3px);
}

.categorie-image {
	aspect-ratio: 596 / 170;
	overflow: hidden;
}

.categorie-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .6s cubic-bezier(.2, .7, .2, 1);
}

.categorie-carte:hover .categorie-image img {
	transform: scale(1.05);
}

.categorie-texte {
	display: flex;
	flex-direction: column;
	gap: 4px;
	padding: 14px 48px 16px 18px;
}

.categorie-texte strong {
	font-size: 18px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.categorie-texte span {
	font-size: 13px;
	line-height: 1.55;
	color: var(--texte-doux);
}

.categorie-fleche {
	position: absolute;
	right: 18px;
	bottom: 16px;
	color: var(--accent-clair);
	font-size: 20px;
	transition: transform .3s;
}

.categorie-carte:hover .categorie-fleche {
	transform: translateX(4px);
}

/* ---------- En-tête des pages intérieures ---------- */

.page-entete {
	max-width: var(--largeur);
	margin: 0 auto;
	padding: 56px var(--marge) 0;
}

.page-titre {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px 32px;
}

/* Même typo que les catégories d'Explorer (Open Sans semi-gras) :
   Aaargh a des chiffres et des accents d'une autre taille que les majuscules */
.page-titre h1 {
	font-family: 'Open Sans', system-ui, sans-serif;
	font-weight: 600;
	font-size: clamp(32px, 4.5vw, 52px);
	line-height: 1.1;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.page-entete .hero-metier {
	margin-top: 12px;
}

.categories-mini {
	display: flex;
	padding: 4px;
	border: 1px solid var(--trait);
	border-radius: 999px;
	background: var(--surface);
}

.categories-mini a {
	padding: 8px 18px;
	border-radius: 999px;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--texte-doux);
	transition: color .2s, background-color .2s;
}

.categories-mini a:hover {
	color: var(--texte);
}

.categories-mini a[aria-current] {
	background: var(--accent);
	color: #fff;
}

/* Onglets des rubriques */
.onglets {
	display: flex;
	flex-wrap: wrap;
	gap: 0 24px;
	margin-top: 36px;
	border-bottom: 1px solid var(--trait);
}

.onglets a {
	flex: none;
	padding: 12px 0;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--texte-doux);
	border-bottom: 2px solid transparent;
	margin-bottom: -1px;
	transition: color .2s, border-color .2s;
}

.onglets a:hover {
	color: var(--texte);
}

.onglets a[aria-selected="true"] {
	color: var(--texte);
	border-color: var(--accent);
}

/* ---------- Galeries des pages work ---------- */

.container_work {
	max-width: var(--largeur);
	margin: 0 auto;
	padding: 32px var(--marge) 0;
}

.work_block {
	display: none;
}

.work_block:first-child {
	display: block;
}

/* Bandeau d'origine : inutile, le nom de la rubrique est déjà dans les onglets */
.work_block .up {
	display: none;
}

.work_block ul {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	gap: 10px;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Cases vides qui servaient à compléter les lignes de l'ancienne mise en page */
.work_block li:empty {
	display: none;
}

.work_block li a {
	position: relative;
	display: block;
	aspect-ratio: 1;
	overflow: hidden;
	border-radius: var(--rayon);
	background: var(--surface);
}

.work_block li .img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .5s cubic-bezier(.2, .7, .2, 1);
}

.work_block li .cover {
	position: absolute;
	inset: 0;
	background: linear-gradient(0deg, rgba(0, 0, 0, 0.75) 0%, rgba(0, 0, 0, 0) 55%);
	opacity: 0;
	transition: opacity .3s;
}

.work_block li a > span {
	position: absolute;
	left: 12px;
	right: 12px;
	bottom: 10px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	opacity: 0;
	transform: translateY(6px);
	transition: opacity .3s, transform .3s;
}

.work_block li a:hover .img {
	transform: scale(1.06);
}

.work_block li a:hover .cover,
.work_block li a:hover > span,
.work_block li a:focus-visible .cover,
.work_block li a:focus-visible > span {
	opacity: 1;
	transform: none;
}

/* Vidéos : pastille lecture sur la vignette (rond + triangle) */
.work_block a.fancybox\.iframe::after,
.work_block a.fancybox\.iframe::before {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	transition: transform .3s;
}

.work_block a.fancybox\.iframe::after {
	z-index: 1;
	width: 52px;
	height: 52px;
	margin: -26px 0 0 -26px;
	border-radius: 50%;
	background: var(--accent);
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.work_block a.fancybox\.iframe::before {
	z-index: 2;
	width: 0;
	height: 0;
	margin: -9px 0 0 -5px;
	border-style: solid;
	border-width: 9px 0 9px 15px;
	border-color: transparent transparent transparent #fff;
}

.work_block a.fancybox\.iframe:hover::after {
	transform: scale(1.1);
}

/* ---------- About / contact ---------- */

.cv-bloc {
	padding-top: 40px;
}

.cv-image {
	display: block;
	max-width: 900px;
	margin: 0 auto;
	overflow: hidden;
	border-radius: var(--rayon);
	box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}

.cv-image img,
.contact-image {
	width: 100%;
	height: auto;
}

.contact-image {
	max-width: 700px;
	margin: 0 auto;
	border-radius: var(--rayon);
}

/* ---------- Pied de page ---------- */

.pied {
	margin-top: 96px;
	border-top: 1px solid var(--trait);
	background: var(--surface);
}

.pied-contenu {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 20px 40px;
	max-width: var(--largeur);
	margin: 0 auto;
	padding: 36px var(--marge);
}

.pied-nom .logo {
	font-size: 22px;
}

.pied-nom p {
	margin-top: 6px;
	font-size: 13px;
	color: var(--texte-doux);
}

.pied-liens {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 20px;
	margin-left: auto;
}

.pied-liens a {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--texte-doux);
	transition: color .2s;
}

.pied-liens a:hover {
	color: var(--accent-clair);
}

.pied-copyright {
	width: 100%;
	padding-top: 20px;
	border-top: 1px solid var(--trait);
	font-size: 12px;
	color: var(--texte-doux);
}

/* ---------- Tablette ---------- */

@media (max-width: 900px) {
	.accueil-contenu {
		grid-template-columns: 1fr;
		gap: 28px;
	}

	.accueil .reel {
		width: 100%;
	}

	.hero-image {
		width: 100%;
		height: 60%;
		-webkit-mask-image: linear-gradient(180deg, #000 20%, transparent 100%);
		-webkit-mask-composite: source-over;
		mask-image: linear-gradient(180deg, #000 20%, transparent 100%);
		mask-composite: add;
	}

	.categories {
		grid-template-columns: 1fr;
	}

	.categorie-carte {
		flex-direction: row;
	}

	.categorie-image {
		flex: 0 0 42%;
		aspect-ratio: auto;
	}
}

/* ---------- Téléphone ---------- */

@media (max-width: 600px) {
	/* En-tête des pages : titre puis sélecteur en pleine largeur,
	   quelle que soit la longueur du titre (2D, 3D, Vidéos, About) */
	.page-titre {
		flex-direction: column;
		align-items: stretch;
		gap: 16px;
	}

	.categories-mini a {
		flex: 1;
		text-align: center;
	}
	.entete-contenu {
		flex-wrap: wrap;
		gap: 4px 12px;
		padding-top: 12px;
		padding-bottom: 6px;
	}

	.logo {
		font-size: 22px;
	}

	.langues {
		margin-left: auto;
		padding-left: 0;
		border-left: 0;
	}

	.nav-principale {
		order: 3;
		width: 100%;
		margin: 0 0 0 -12px;
	}

	/* Téléphone : l'image en haut, le texte qui vient se poser sur le bas de l'image */
	.hero-image {
		height: 85vw;
		opacity: 0.8;
		object-position: 55% 0;
		-webkit-mask-image: linear-gradient(180deg, #000 35%, transparent 100%);
		-webkit-mask-composite: source-over;
		mask-image: linear-gradient(180deg, #000 35%, transparent 100%);
		mask-composite: add;
	}

	.accueil-contenu {
		padding-top: 46vw;
	}

	.accueil h1 {
		font-size: 40px;
	}

	.bouton {
		flex: 1 1 auto;
		justify-content: center;
	}

	.bloc {
		padding-top: 56px;
	}

	.categorie-carte {
		flex-direction: column;
	}

	.work_block ul {
		grid-template-columns: repeat(2, 1fr);
		gap: 8px;
	}

	.categorie-image {
		flex: none;
		aspect-ratio: 596 / 200;
	}

	.pied-liens {
		margin-left: 0;
	}
}
