/* =====================================================================
   TP Calendrier Polynésie — front-end v1.1.0
   ---------------------------------------------------------------------
   1. Tokens & reset (isolation du thème / Elementor)
   2. Hero « Aujourd'hui »
   3. Cartes Marées / Météo / Le saviez-vous ?
   4. Modules secondaires & proverbe
   5. Panneaux (calendrier annuel, actualités)
   6. Lightbox & toast
   7. Responsive (tablette, mobile)
   ===================================================================== */

/* ---------- 1. Tokens & reset ---------- */
.tp-cal {
	--tp-ocean: #0284c7;
	--tp-ocean-600: #0369a1;
	--tp-deep: #0c4a6e;
	--tp-navy: #0b2a45;
	--tp-sky: #e0f2fe;
	--tp-sky-50: #f0f9ff;
	--tp-lagoon: #0891b2;
	--tp-text: #1e293b;
	--tp-muted: #64748b;
	--tp-faint: #94a3b8;
	--tp-line: #e3eef6;
	--tp-coral: #ea580c;
	--tp-coral-700: #c2410c;
	--tp-amber-bg: #fef3c7;
	--tp-amber: #92400e;
	--tp-rose: #e11d48;
	--tp-radius: 20px;
	--tp-radius-sm: 14px;
	--tp-shadow: 0 1px 2px rgba(12, 74, 110, .04), 0 10px 30px rgba(12, 74, 110, .08);
	--tp-shadow-lg: 0 2px 6px rgba(12, 74, 110, .05), 0 22px 50px rgba(12, 74, 110, .12);
	--tp-serif: "DM Serif Display", "Playfair Display", Georgia, "Times New Roman", serif;
	--tp-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

	max-width: 1180px;
	margin: 0 auto;
	padding: 8px 0 40px;
	font-family: var(--tp-sans);
	font-size: 15px;
	line-height: 1.5;
	color: var(--tp-text);
	-webkit-font-smoothing: antialiased;
	container: tpcal / inline-size;
}

.tp-cal *,
.tp-cal *::before,
.tp-cal *::after {
	box-sizing: border-box;
}

.tp-cal h2,
.tp-cal h3,
.tp-cal p,
.tp-cal ul,
.tp-cal ol,
.tp-cal figure,
.tp-cal blockquote {
	margin: 0;
	padding: 0;
	letter-spacing: normal;
	text-transform: none;
	border: 0;
	background: none;
}

.tp-cal ul,
.tp-cal ol {
	list-style: none;
}

.tp-cal li {
	margin: 0;
}

.tp-cal li::before,
.tp-cal blockquote::before,
.tp-cal blockquote::after {
	content: none;
}

.tp-cal img {
	max-width: 100%;
	height: auto;
	border: 0;
	box-shadow: none;
}

.tp-cal button {
	margin: 0;
	font: inherit;
	line-height: inherit;
	letter-spacing: normal;
	text-transform: none;
	text-shadow: none;
	box-shadow: none;
	min-height: 0;
	min-width: 0;
	width: auto;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
}

.tp-cal button:focus-visible,
.tp-cal a:focus-visible {
	outline: 2px solid var(--tp-ocean);
	outline-offset: 2px;
}

.tp-cal a {
	text-decoration: none;
	box-shadow: none;
}

.tp-cal abbr[title] {
	text-decoration: none;
	border: 0;
	cursor: default;
}

.tp-icon {
	width: 1.25em;
	height: 1.25em;
	flex-shrink: 0;
	vertical-align: middle;
}

/* Visibilité desktop / mobile (Modules & Affichage) */
@media (min-width: 768px) {
	.tp-cal .tp-hide-desktop { display: none !important; }
}
@media (max-width: 767px) {
	.tp-cal .tp-hide-mobile { display: none !important; }
}

/* Chargement AJAX */
.tp-day-container {
	transition: opacity .2s ease;
}
.tp-day-container.is-loading {
	opacity: .5;
	pointer-events: none;
}

/* Boutons génériques */
.tp-cal .tp-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 9px 18px;
	border-radius: 12px;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
	border: 1px solid transparent;
	background: #fff;
	color: var(--tp-deep);
	transition: background .15s, color .15s, border-color .15s, box-shadow .15s;
}
.tp-cal .tp-btn .tp-icon { width: 18px; height: 18px; }

.tp-cal .tp-btn-ghost {
	border-color: #cfe0ec;
	background: #fff;
	color: var(--tp-deep);
}
.tp-cal .tp-btn-ghost:hover {
	background: var(--tp-sky-50);
	border-color: var(--tp-ocean);
	color: var(--tp-ocean-600);
}

.tp-cal .tp-btn-primary {
	background: var(--tp-ocean);
	border-color: var(--tp-ocean);
	color: #fff;
}
.tp-cal .tp-btn-primary:hover {
	background: var(--tp-ocean-600);
	border-color: var(--tp-ocean-600);
	color: #fff;
}

.tp-cal .tp-btn-outline {
	background: #fff;
	border-color: #f4a77c;
	color: var(--tp-coral-700);
}
.tp-cal .tp-btn-outline:hover {
	background: #fff4ed;
	border-color: var(--tp-coral);
	color: var(--tp-coral-700);
}

.tp-cal .tp-btn-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	padding: 0;
	border-radius: 10px;
	border: 1px solid #cfe0ec;
	background: #fff;
	color: var(--tp-deep);
	transition: background .15s, color .15s, border-color .15s;
}
.tp-cal .tp-btn-icon:hover {
	background: var(--tp-sky-50);
	border-color: var(--tp-ocean);
	color: var(--tp-ocean);
}
.tp-cal .tp-btn-icon .tp-icon { width: 18px; height: 18px; }

.tp-btn-group {
	display: inline-flex;
}
.tp-cal .tp-btn-group .tp-btn-icon:first-child { border-radius: 10px 0 0 10px; }
.tp-cal .tp-btn-group .tp-btn-icon:last-child { border-radius: 0 10px 10px 0; margin-left: -1px; }

.tp-chip {
	display: inline-flex;
	align-items: center;
	padding: 2px 9px;
	border-radius: 999px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .02em;
	text-transform: uppercase;
	vertical-align: middle;
	background: var(--tp-sky);
	color: var(--tp-deep);
}
.tp-chip-major,
.tp-chip-imp-1 { background: #ffedd5; color: var(--tp-coral-700); }
.tp-chip-imp-3 { background: #f1f5f9; color: var(--tp-muted); }

.tp-kicker {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	font-weight: 500;
	color: var(--tp-muted);
}

/* ---------- 2. Hero « Aujourd'hui » ---------- */
.tp-hero {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr) 250px;
	align-items: center;
	gap: 36px;
	min-height: 300px;
	padding: 40px 44px;
	border-radius: 26px;
	background:
		radial-gradient(120% 90% at 100% 0%, rgba(186, 230, 253, .55) 0%, rgba(186, 230, 253, 0) 60%),
		linear-gradient(135deg, #ffffff 0%, #f5fbff 55%, #e9f6fd 100%);
	border: 1px solid var(--tp-line);
	box-shadow: var(--tp-shadow);
	overflow: hidden;
	isolation: isolate;
}

/* Fond de Polynésie plein cadre + voile de lisibilité (réglable : --tp-veil, 0 → 0,95) */
.tp-hero.has-visual {
	min-height: 360px;
	border-color: rgba(255, 255, 255, .6);
}

.tp-hero-visual {
	position: absolute;
	inset: 0;
	z-index: -2;
	background-size: cover;
	background-position: 70% 55%;
}

.tp-hero-veil {
	position: absolute;
	inset: 0;
	z-index: -1;
	background: linear-gradient(
		90deg,
		rgba(255, 255, 255, calc(var(--tp-veil, .7) + .08)) 0%,
		rgba(255, 255, 255, var(--tp-veil, .7)) 34%,
		rgba(255, 255, 255, calc(var(--tp-veil, .7) * .35)) 58%,
		rgba(255, 255, 255, 0) 78%
	);
}

.tp-hero.has-visual .tp-date,
.tp-hero.has-visual .tp-eyebrow {
	text-shadow: 0 1px 12px rgba(255, 255, 255, .7);
}

/* Carte « verre dépoli » pour la lune sur la photo */
.tp-hero.has-visual .tp-hero-moon {
	padding: 22px 20px 18px;
	border-left: 0;
	border-radius: 22px;
	background: rgba(255, 255, 255, .74);
	border: 1px solid rgba(255, 255, 255, .85);
	-webkit-backdrop-filter: blur(10px) saturate(1.2);
	backdrop-filter: blur(10px) saturate(1.2);
	box-shadow: 0 12px 34px rgba(12, 74, 110, .18);
}
.tp-hero.has-visual .tp-moon-figure { width: 132px; height: 132px; }

/* Solstice / équinoxe / éclipse sous la lune */
.tp-astro {
	display: flex;
	flex-direction: column;
	gap: 6px;
	width: 100%;
	margin-top: 10px !important;
	text-align: left;
}
.tp-astro-item {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 6px 10px;
	border-radius: 12px;
	border: 1px solid transparent;
	line-height: 1.25;
}
.tp-astro-item .tp-icon { width: 20px; height: 20px; }
.tp-astro-item > span { display: flex; flex-direction: column; min-width: 0; }
.tp-astro-item strong { font-size: 12.5px; font-weight: 700; }
.tp-astro-item small { font-size: 11px; opacity: .85; }
.tp-astro-item.is-solstice { background: #fff7e6; border-color: #fde7c2; color: #92400e; }
.tp-astro-item.is-solstice .tp-icon { color: #c2410c; }
.tp-astro-item.is-equinoxe { background: var(--tp-sky); border-color: #bae6fd; color: var(--tp-deep); }
.tp-astro-item.is-equinoxe .tp-icon { color: #c2410c; }
.tp-astro-item.is-eclipse { background: #1e293b; border-color: #1e293b; color: #f8fafc; }
.tp-astro-item.is-matarii-nia,
.tp-astro-item.is-matarii-raro { background: #eef2ff; border-color: #c7d2fe; color: #312e81; }
.tp-astro-item.is-matarii-nia .tp-icon,
.tp-astro-item.is-matarii-raro .tp-icon { color: #4338ca; }
.tp-astro-item.is-eclipse .tp-icon { color: #fcd34d; }

.tp-astro-inline { flex-direction: row; flex-wrap: wrap; width: auto; margin-top: 14px !important; }
.tp-astro-narrow { display: none; }

.tp-hero-main {
	min-width: 0;
}

.tp-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 10px !important;
	font-size: 15px;
	font-weight: 600;
	color: var(--tp-lagoon);
}
.tp-eyebrow .tp-icon { width: 22px; height: 22px; }

.tp-cal .tp-date {
	margin: 0 0 20px;
	font-family: var(--tp-serif);
	font-weight: 400;
	font-size: clamp(2.3rem, 5.2cqi, 3.7rem);
	line-height: 1.04;
	letter-spacing: -.01em;
	color: var(--tp-navy);
}

.tp-badges {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
}

.tp-saint {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 6px 18px 6px 8px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .85);
	border: 1px solid #fde3c8;
	box-shadow: 0 4px 14px rgba(234, 88, 12, .08);
}
.tp-saint-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	background: #fff7ed;
	color: #f97316;
}
.tp-saint-icon .tp-icon { width: 26px; height: 26px; }
.tp-saint-text { display: flex; flex-direction: column; line-height: 1.2; }
.tp-saint-label { font-size: 12px; font-weight: 500; color: var(--tp-muted); }
.tp-saint-name { font-size: 16px; font-weight: 600; color: var(--tp-navy); }

.tp-pill {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 9px 16px;
	border-radius: 999px;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
}
.tp-pill .tp-icon { width: 18px; height: 18px; }
.tp-pill-ferie { background: var(--tp-amber-bg); color: var(--tp-amber); }
.tp-pill-ferie .tp-icon { color: #d97706; }
.tp-pill-sky { background: var(--tp-sky); color: var(--tp-deep); }

.tp-cal .tp-back-today {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-top: 18px;
	padding: 6px 0;
	border: 0;
	background: none;
	font-size: 14px;
	font-weight: 600;
	color: var(--tp-ocean);
}
.tp-cal .tp-back-today:hover { color: var(--tp-deep); background: none; }
.tp-back-today .tp-icon { width: 16px; height: 16px; }

/* Lune */
.tp-hero-moon {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding-left: 36px;
	border-left: 1px solid rgba(12, 74, 110, .12);
}

.tp-moon-figure {
	width: 150px;
	height: 150px;
	margin-bottom: 14px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 0 0 10px rgba(255, 255, 255, .7), 0 0 0 11px rgba(12, 74, 110, .06), 0 20px 40px rgba(12, 74, 110, .18);
	overflow: hidden;
}
.tp-moon-figure img,
.tp-moon-figure .tp-moon-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 50%;
	display: block;
}
.tp-moon-svg { display: block; width: 100%; height: 100%; }

.tp-moon-caption { font-size: 16px; font-weight: 600; color: var(--tp-navy); }
.tp-moon-name { font-size: 14px; color: var(--tp-muted); }
.tp-moon-meta {
	display: flex;
	gap: 8px;
	justify-content: center;
	margin-top: 6px !important;
	font-size: 12.5px;
	font-weight: 600;
	color: var(--tp-ocean-600);
}
.tp-moon-meta span + span::before {
	content: "·";
	margin-right: 8px;
	color: var(--tp-faint);
}

.tp-moon-steps {
	display: flex;
	gap: 7px;
	margin-top: 14px !important;
}
.tp-moon-steps li {
	width: 17px;
	height: 17px;
	border-radius: 50%;
	opacity: .55;
	transition: opacity .2s;
}
.tp-moon-steps li.is-current {
	opacity: 1;
	box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--tp-lagoon);
}

/* ---------- 3. Cartes ---------- */
.tp-cards {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px;
	margin-top: 22px;
}
.tp-cards-3 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.45fr); }
.tp-cards-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tp-cards-1 { grid-template-columns: minmax(0, 1fr); }

.tp-card {
	display: flex;
	flex-direction: column;
	min-width: 0;
	padding: 22px 24px;
	border-radius: var(--tp-radius);
	background: #fff;
	border: 1px solid var(--tp-line);
	box-shadow: var(--tp-shadow);
}

.tp-card-head {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 14px;
}
.tp-card-icon {
	display: inline-flex;
	color: var(--tp-lagoon);
}
.tp-card-icon .tp-icon { width: 30px; height: 30px; }
.tp-card-icon-sun { color: #f59e0b; }
.tp-cal .tp-card-head h3 {
	font-family: var(--tp-serif);
	font-weight: 400;
	font-size: 1.4rem;
	line-height: 1.15;
	color: var(--tp-navy);
}
.tp-card-sub { font-size: 13px; color: var(--tp-muted); }

.tp-card-note {
	margin-top: 12px !important;
	font-size: 13px;
	color: var(--tp-faint);
}

/* Marées */
.tp-tides li {
	display: grid;
	grid-template-columns: 18px minmax(0, 1fr) auto 52px;
	align-items: center;
	gap: 10px;
	padding: 8px 0;
	border-bottom: 1px dashed #e5edf3;
	font-size: 14px;
}
.tp-tides li:last-child { border-bottom: 0; }
.tp-tides .tp-icon { width: 17px; height: 17px; color: var(--tp-faint); }
.tp-tide-type { color: var(--tp-text); }
.tp-tide-time { font-weight: 700; color: var(--tp-navy); font-variant-numeric: tabular-nums; }
.tp-tide-height { text-align: right; color: var(--tp-muted); font-variant-numeric: tabular-nums; }
.tp-tides.is-pending .tp-tide-time,
.tp-tides.is-pending .tp-tide-height { color: #cbd5e1; font-weight: 600; }

/* Météo */
.tp-weather-main {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-bottom: 16px;
}
.tp-weather-icon { color: #f59e0b; display: inline-flex; }
.tp-weather-icon .tp-icon { width: 64px; height: 64px; stroke-width: 1.3; }
.tp-weather-temp {
	font-family: var(--tp-serif);
	font-size: 2.7rem;
	line-height: 1;
	color: var(--tp-navy);
}
.tp-weather-temp span { font-size: .55em; margin-left: 2px; vertical-align: top; }
.tp-weather-cond { margin-top: 4px !important; font-size: 14px; color: var(--tp-muted); }
.tp-weather-main.is-pending .tp-weather-temp { color: #cbd5e1; }
.tp-weather-main.is-pending .tp-weather-icon { color: #fcd34d; }

.tp-weather-stats {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 8px;
}
.tp-weather-stats li {
	display: grid;
	grid-template-columns: 20px minmax(0, 1fr);
	column-gap: 6px;
	align-items: center;
	font-size: 12.5px;
	color: var(--tp-muted);
}
.tp-weather-stats .tp-icon { grid-row: span 2; width: 20px; height: 20px; color: var(--tp-lagoon); }
.tp-weather-stats strong { font-size: 14px; color: var(--tp-navy); font-weight: 700; }

.tp-sun {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 8px 16px;
	margin-top: auto !important;
	padding-top: 14px !important;
	border-top: 1px solid #edf3f8 !important;
	font-size: 13px;
	color: var(--tp-muted);
}
.tp-sun > span { display: inline-flex; align-items: center; gap: 6px; }
.tp-sun .tp-icon { width: 18px; height: 18px; color: #f59e0b; }
.tp-sun strong { color: var(--tp-navy); font-variant-numeric: tabular-nums; }
.tp-card-weather .tp-weather-stats { margin-bottom: 14px; }

/* Le saviez-vous ? */
.tp-card-history {
	background: linear-gradient(180deg, #fffaf3 0%, #fff6ea 100%);
	border-color: #fbe3c4;
}

.tp-history { display: flex; flex-direction: column; height: 100%; }
.tp-history-track { flex: 1; }

.tp-history-slide {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 18px;
	align-items: start;
	animation: tp-fade .3s ease;
}
.tp-history-slide[hidden] { display: none; }
.tp-history-slide.has-image { grid-template-columns: minmax(0, 1fr) minmax(0, 42%); }

@keyframes tp-fade {
	from { opacity: 0; transform: translateY(4px); }
	to { opacity: 1; transform: none; }
}

.tp-history-body { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }

.tp-cal .tp-history-title {
	margin: 4px 0 8px;
	font-family: var(--tp-serif);
	font-weight: 400;
	font-size: 1.85rem;
	line-height: 1.1;
	color: var(--tp-navy);
}

.tp-history-text {
	display: -webkit-box;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
	overflow: hidden;
	margin-bottom: 14px !important;
	font-size: 14px;
	line-height: 1.55;
	color: #334155;
}

.tp-cal .tp-history-media {
	position: relative;
	display: block;
	width: 100%;
	padding: 0;
	border: 0;
	border-radius: var(--tp-radius-sm);
	background: #f1e6d6;
	overflow: hidden;
	aspect-ratio: 4 / 3.2;
	box-shadow: 0 8px 22px rgba(120, 72, 20, .14);
}
.tp-history-media img {
	display: block;
	width: 100%;
	height: 100% !important;
	object-fit: cover;
	transition: transform .4s ease;
}
.tp-cal .tp-history-media:hover img { transform: scale(1.04); }

.tp-zoom {
	position: absolute;
	right: 10px;
	bottom: 10px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: rgba(255, 255, 255, .92);
	color: var(--tp-navy);
	box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
}
.tp-zoom .tp-icon { width: 20px; height: 20px; }

.tp-history-nav {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	margin-top: 16px;
}
.tp-cal .tp-history-nav .tp-btn-icon { width: 32px; height: 32px; border-radius: 50%; }
.tp-dots { display: flex; gap: 6px; }
.tp-cal .tp-dot {
	width: 8px;
	height: 8px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: #e2cfb6;
	transition: width .2s, background .2s;
}
.tp-cal .tp-dot.is-active { width: 22px; background: var(--tp-coral); }

.tp-history-empty .tp-history-title { font-size: 1.45rem; }
.tp-nearby { display: flex; flex-direction: column; gap: 8px; margin-top: 10px !important; }
.tp-cal .tp-nearby-item {
	display: flex;
	align-items: center;
	gap: 12px;
	width: 100%;
	padding: 10px 12px;
	border: 1px solid #f3dcc0;
	border-radius: 12px;
	background: #fff;
	text-align: left;
	color: var(--tp-text);
	transition: border-color .15s, box-shadow .15s;
}
.tp-cal .tp-nearby-item:hover { border-color: var(--tp-coral); box-shadow: 0 4px 14px rgba(234, 88, 12, .1); background: #fff; color: var(--tp-text); }
.tp-nearby-date {
	flex-shrink: 0;
	min-width: 62px;
	font-weight: 700;
	font-size: 13px;
	color: var(--tp-coral-700);
}
.tp-nearby-text {
	flex: 1;
	min-width: 0;
	font-size: 13px;
	line-height: 1.4;
	color: #475569;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* ---------- 4. Modules secondaires & proverbe ---------- */
.tp-extras {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 16px;
	margin-top: 18px;
}

.tp-extra {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	padding: 16px 18px;
	border-radius: 16px;
	background: #fff;
	border: 1px solid var(--tp-line);
	box-shadow: 0 4px 16px rgba(12, 74, 110, .05);
}
.tp-extra-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 42px;
	height: 42px;
	border-radius: 12px;
	background: var(--tp-sky);
	color: var(--tp-ocean);
}
.tp-extra-icon .tp-icon { width: 22px; height: 22px; }
.tp-cal .tp-extra-img { width: 48px; height: 48px !important; border-radius: 12px; object-fit: cover; flex-shrink: 0; }
.tp-extra-label {
	margin-bottom: 2px !important;
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: .06em !important;
	text-transform: uppercase !important;
	color: var(--tp-ocean);
}
.tp-extra-text { font-size: 14.5px; color: var(--tp-navy); line-height: 1.45; }
.tp-extra-text + .tp-extra-text { margin-top: 2px !important; }

.tp-proverb {
	display: grid;
	grid-template-columns: minmax(30px, 1fr) minmax(0, auto) minmax(30px, 1fr);
	align-items: center;
	gap: 22px;
	margin: 36px 0 6px !important;
}
.tp-proverb-line {
	position: relative;
	height: 1px;
	background: linear-gradient(90deg, rgba(8, 145, 178, 0), rgba(8, 145, 178, .45));
}
.tp-proverb-line:last-child { background: linear-gradient(90deg, rgba(8, 145, 178, .45), rgba(8, 145, 178, 0)); }
.tp-proverb-line::after {
	content: "";
	position: absolute;
	top: -3px;
	right: -2px;
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--tp-lagoon);
	box-shadow: -14px 0 0 -1px rgba(8, 145, 178, .5);
}
.tp-proverb-line:last-child::after { right: auto; left: -2px; box-shadow: 14px 0 0 -1px rgba(8, 145, 178, .5); }

.tp-proverb-inner { max-width: 760px; text-align: center; }
.tp-proverb-mark { display: inline-flex; color: var(--tp-lagoon); vertical-align: top; margin-right: 8px; }
.tp-proverb-mark .tp-icon { width: 30px; height: 30px; }
.tp-cal .tp-proverb blockquote { display: inline; margin: 0; padding: 0; border: 0; background: none; font-size: inherit; quotes: none; }
.tp-cal .tp-proverb blockquote p {
	display: inline;
	font-family: var(--tp-serif);
	font-style: italic;
	font-size: 1.45rem;
	line-height: 1.4;
	color: var(--tp-navy);
}
.tp-proverb figcaption {
	margin-top: 6px;
	font-size: 13.5px;
	font-style: italic;
	color: var(--tp-muted);
}

/* ---------- 5. Panneaux ---------- */
.tp-panel {
	margin-top: 28px;
	padding: 24px 26px 22px;
	border-radius: 24px;
	background: #fff;
	border: 1px solid var(--tp-line);
	box-shadow: var(--tp-shadow);
}

.tp-section-head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 14px 20px;
	margin-bottom: 18px;
}
.tp-section-title { display: flex; align-items: center; gap: 14px; min-width: 0; }
.tp-section-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 46px;
	height: 46px;
	border-radius: 14px;
	background: var(--tp-sky);
	color: var(--tp-ocean);
}
.tp-section-icon .tp-icon { width: 24px; height: 24px; }
.tp-cal .tp-section-title h2 {
	font-family: var(--tp-serif);
	font-weight: 400;
	font-size: 1.65rem;
	line-height: 1.15;
	color: var(--tp-navy);
}
.tp-year-label { color: var(--tp-ocean); }
.tp-section-title p { margin-top: 2px !important; font-size: 13.5px; color: var(--tp-muted); }

.tp-year-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.tp-cal .tp-btn-pdf[data-soon] { opacity: .85; }

/* Calendrier annuel */
.tp-year-body { position: relative; transition: opacity .2s; }
.tp-year-body.is-loading { opacity: .45; pointer-events: none; }

.tp-year-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 0;
	border-top: 1px solid var(--tp-line);
}

.tp-month {
	padding: 16px 14px 14px;
	border-bottom: 1px solid var(--tp-line);
	border-right: 1px solid var(--tp-line);
	min-width: 0;
}
.tp-month:nth-child(4n) { border-right: 0; }

.tp-cal .tp-month-title {
	margin-bottom: 8px;
	text-align: center;
	font-family: var(--tp-serif);
	font-weight: 400;
	font-size: 15px;
	letter-spacing: .08em !important;
	text-transform: uppercase !important;
	color: var(--tp-navy);
}
.tp-month-title span { color: var(--tp-ocean); }

.tp-month-grid {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	row-gap: 2px;
	text-align: center;
}

.tp-wd {
	padding: 2px 0 4px;
	font-size: 11px;
	font-weight: 600;
	color: var(--tp-muted);
}
.tp-wd.is-weekend { color: var(--tp-lagoon); }

.tp-cal .tp-cal-day {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	max-width: 32px;
	aspect-ratio: 1 / 1;
	margin: 0 auto;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	font-size: 12.5px;
	font-weight: 500;
	line-height: 1;
	color: var(--tp-text);
	font-variant-numeric: tabular-nums;
	transition: background .15s, color .15s;
}
.tp-cal .tp-cal-day.is-weekend { color: var(--tp-lagoon); }
.tp-cal .tp-cal-day:hover { background: var(--tp-sky); color: var(--tp-ocean-600); }
/* Jour férié : fond orange, texte noir (bleu foncé le week-end) */
.tp-cal .tp-cal-day.is-ferie { background: #fadec0; color: #111827; font-weight: 700; border-radius: 8px; }
.tp-cal .tp-cal-day.is-ferie.is-weekend { color: #1e40af; }
.tp-cal .tp-cal-day.is-today { box-shadow: inset 0 0 0 1.5px var(--tp-ocean); font-weight: 700; }
.tp-cal .tp-cal-day.is-selected,
.tp-cal .tp-cal-day.is-selected:hover {
	background: var(--tp-lagoon);
	color: #fff;
	font-weight: 700;
	box-shadow: 0 4px 10px rgba(8, 145, 178, .35);
}

/* Lune pleine / nouvelle : petite pastille en haut à droite */
.tp-cal-day.is-full-moon::before,
.tp-cal-day.is-new-moon::before {
	content: "";
	position: absolute;
	top: 1px;
	right: 1px;
	width: 7px;
	height: 7px;
	border-radius: 50%;
}
.tp-cal-day.is-full-moon::before { background: #fcd34d; box-shadow: 0 0 0 1px #d4a514; }
.tp-cal-day.is-new-moon::before { background: #1e3a5f; box-shadow: 0 0 0 1px #fff; }

/* Événement : point sous le chiffre */
.tp-cal-day.has-event::after {
	content: "";
	position: absolute;
	bottom: 2px;
	left: 50%;
	width: 4px;
	height: 4px;
	margin-left: -2px;
	border-radius: 50%;
	background: var(--tp-coral);
}
.tp-cal-day.is-selected.has-event::after { background: #fff; }

.tp-legend {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 20px;
	margin-top: 16px !important;
	font-size: 12.5px;
	color: var(--tp-muted);
}
.tp-legend li { display: inline-flex; align-items: center; gap: 7px; }
.tp-lg { display: inline-block; width: 10px; height: 10px; border-radius: 50%; }
.tp-lg-today { width: 16px; height: 16px; box-shadow: inset 0 0 0 1.5px var(--tp-ocean); }
.tp-lg-full { background: #fcd34d; box-shadow: 0 0 0 1px #d4a514; }
.tp-lg-new { background: #1e3a5f; }
.tp-lg-ferie { width: auto; height: auto; padding: 0 4px; border-radius: 4px; background: #fadec0; font-size: 11px; font-weight: 700; color: #111827; }
.tp-lg-event { width: 6px; height: 6px; background: var(--tp-coral); }

/* Cours du change (placeholder) */
.tp-change .tp-section-head { margin-bottom: 0; }

/* Actualités */
.tp-news-list {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 16px;
}

.tp-cal .tp-news-card {
	display: grid;
	grid-template-columns: 44% minmax(0, 1fr);
	min-height: 120px;
	border-radius: 16px;
	background: #fff;
	border: 1px solid var(--tp-line);
	overflow: hidden;
	color: var(--tp-text);
	transition: box-shadow .2s, transform .2s, border-color .2s;
}
.tp-cal .tp-news-card:hover {
	transform: translateY(-2px);
	border-color: #bfdcef;
	box-shadow: var(--tp-shadow-lg);
	color: var(--tp-text);
}

.tp-news-media { position: relative; display: block; background: var(--tp-sky); }
.tp-cal .tp-news-media img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.tp-news-noimg {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #7dd3fc;
}
.tp-news-noimg .tp-icon { width: 36px; height: 36px; }

.tp-news-body {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	gap: 10px;
	padding: 12px 14px;
}
.tp-news-title {
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.35;
	color: var(--tp-navy);
}
.tp-news-meta { display: flex; flex-direction: column; gap: 2px; }
.tp-news-source { font-size: 12px; font-weight: 700; color: var(--tp-ocean); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tp-news-date { font-size: 11.5px; color: var(--tp-faint); }

.tp-cal .tp-more-link {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-size: 14px;
	font-weight: 600;
	color: var(--tp-ocean);
}
.tp-cal .tp-more-link:hover { color: var(--tp-deep); }
.tp-more-link .tp-icon { width: 16px; height: 16px; }

.tp-admin-hint {
	margin-top: 24px !important;
	padding: 12px 16px !important;
	border: 1px dashed #93c5fd !important;
	border-radius: 12px;
	background: var(--tp-sky-50) !important;
	font-size: 13.5px;
	color: var(--tp-deep);
}
.tp-admin-hint a { color: var(--tp-ocean); text-decoration: underline; }

/* ---------- 6. Lightbox & toast ---------- */
.tp-lb {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: rgba(8, 24, 40, .72);
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
	animation: tp-fade .2s ease;
	font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.tp-lb-dialog {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	width: 100%;
	max-width: 920px;
	max-height: calc(100vh - 40px);
	overflow: auto;
	border-radius: 22px;
	background: #fff;
	box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
	color: #1e293b;
}
.tp-lb-dialog.has-figure { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }

.tp-lb-figure { margin: 0; background: #0b2a45; min-height: 260px; }
.tp-lb-figure img { display: block; width: 100%; height: 100% !important; max-height: calc(100vh - 40px); object-fit: cover; }

.tp-lb-body { padding: 34px 32px 30px; }
.tp-lb-body .tp-kicker { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13px; color: #64748b; margin: 0 0 6px; }
.tp-lb .tp-chip { display: inline-flex; padding: 2px 9px; border-radius: 999px; font-size: 11px; font-weight: 700; text-transform: uppercase; background: #e0f2fe; color: #0c4a6e; }
.tp-lb .tp-chip-imp-1 { background: #ffedd5; color: #c2410c; }
.tp-lb .tp-chip-imp-3 { background: #f1f5f9; color: #64748b; }
.tp-lb-title {
	margin: 0 0 14px;
	font-family: "DM Serif Display", Georgia, serif;
	font-weight: 400;
	font-size: 1.9rem;
	line-height: 1.15;
	color: #0b2a45;
}
.tp-lb-text p { margin: 0 0 12px; font-size: 15.5px; line-height: 1.7; color: #334155; }

.tp-lb-close {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .95);
	color: #0b2a45;
	box-shadow: 0 4px 14px rgba(0, 0, 0, .18);
	cursor: pointer;
}
.tp-lb-close:hover { background: #fff; color: #0284c7; }
.tp-lb-close svg { width: 20px; height: 20px; }

html.tp-lb-open { overflow: hidden; }

.tp-toast {
	position: fixed;
	left: 50%;
	bottom: 24px;
	z-index: 999999;
	transform: translateX(-50%);
	padding: 10px 18px;
	border-radius: 999px;
	background: #0b2a45;
	color: #fff;
	font: 600 14px/1.3 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
	animation: tp-fade .2s ease;
}

/* ---------- 6b. Icônes astronomiques du calendrier annuel ---------- */
.tp-cal-astro {
	position: absolute;
	top: 0;
	left: 0;
	width: 10px;
	height: 10px;
	background: center / contain no-repeat;
	pointer-events: none;
}
.tp-cal-astro-solstice {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Ccircle cx='6' cy='6' r='2.6' fill='%23c2410c'/%3E%3Cpath d='M6 .8v1.6M6 9.6v1.6M.8 6h1.6M9.6 6h1.6M2.3 2.3l1.1 1.1M8.6 8.6l1.1 1.1M2.3 9.7l1.1-1.1M8.6 3.4l1.1-1.1' stroke='%23c2410c' stroke-width='1.3' stroke-linecap='round'/%3E%3C/svg%3E");
}
.tp-cal-astro-equinoxe {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Ccircle cx='6' cy='6' r='4.6' fill='%23fff' stroke='%23c2410c' stroke-width='1.3'/%3E%3Cpath d='M6 1.4a4.6 4.6 0 0 1 0 9.2z' fill='%23c2410c'/%3E%3C/svg%3E");
}
.tp-cal-astro-matarii-nia {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cg fill='%234338ca'%3E%3Ccircle cx='3' cy='3.2' r='1.1'/%3E%3Ccircle cx='6' cy='2.2' r='.9'/%3E%3Ccircle cx='4.6' cy='5.4' r='1.2'/%3E%3Ccircle cx='2' cy='7' r='.8'/%3E%3Ccircle cx='6.6' cy='6.6' r='.9'/%3E%3C/g%3E%3Cpath d='M9.6 11.2V5.4M7.9 7.1l1.7-1.7 1.7 1.7' fill='none' stroke='%234338ca' stroke-width='1.3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.tp-cal-astro-matarii-raro {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cg fill='%234338ca'%3E%3Ccircle cx='3' cy='3.2' r='1.1'/%3E%3Ccircle cx='6' cy='2.2' r='.9'/%3E%3Ccircle cx='4.6' cy='5.4' r='1.2'/%3E%3Ccircle cx='2' cy='7' r='.8'/%3E%3Ccircle cx='6.6' cy='6.6' r='.9'/%3E%3C/g%3E%3Cpath d='M9.6 5.4v5.8M7.9 9.5l1.7 1.7 1.7-1.7' fill='none' stroke='%234338ca' stroke-width='1.3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.tp-cal-astro-eclipse {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Ccircle cx='6' cy='6' r='5.2' fill='%23fcd34d'/%3E%3Ccircle cx='7.4' cy='5' r='4.4' fill='%231e293b'/%3E%3C/svg%3E");
}
.tp-cal-day.is-eclipse,
.tp-cal-day.is-solstice,
.tp-cal-day.is-equinoxe { font-weight: 700; }
.tp-legend .tp-lg.tp-cal-astro { position: static; width: 13px; height: 13px; border-radius: 0; }

/* ---------- 6c. Fêtes du jour (slider) ---------- */
.tp-cal .tp-fetes {
	position: relative;
	flex-direction: column;
	align-items: stretch;
	gap: 10px;
	overflow: hidden;
	transition: background .4s ease, border-color .4s ease, box-shadow .4s ease;
}
.tp-fete-slide {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	animation: tp-fete-in .45s ease;
}
.tp-fete-slide[hidden] { display: none; }
@keyframes tp-fete-in {
	from { opacity: 0; transform: translateX(14px); }
	to { opacity: 1; transform: none; }
}
.tp-fete-body { min-width: 0; }
.tp-fete-name { font-weight: 500; }

/* Fête locale : mise en avant */
.tp-cal .tp-fetes.is-local {
	background: linear-gradient(135deg, #fff7ed 0%, #ffe8d1 100%);
	border-color: #fdc89a;
	box-shadow: 0 10px 28px rgba(234, 88, 12, .14);
}
.tp-fete-slide.is-local .tp-extra-icon {
	background: linear-gradient(135deg, #fb923c 0%, #f43f5e 100%);
	color: #fff;
	box-shadow: 0 6px 14px rgba(244, 63, 94, .3);
}
.tp-fete-slide.is-local .tp-extra-label { color: var(--tp-coral-700); }
.tp-fete-slide.is-local .tp-extra-label::before { content: "★ "; }
.tp-cal .tp-fete-slide.is-local .tp-fete-name {
	font-family: var(--tp-serif);
	font-size: 1.2rem;
	line-height: 1.25;
	font-weight: 400;
	color: #7c2d12;
}

.tp-fetes-nav {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 8px;
	margin-top: auto;
}
.tp-cal .tp-fetes-nav .tp-btn-icon { width: 30px; height: 30px; min-height: 30px; border-radius: 50%; }
.tp-fetes-count { font-size: 12px; font-weight: 600; color: var(--tp-muted); font-variant-numeric: tabular-nums; }

.tp-fetes-progress {
	position: absolute;
	left: 0;
	bottom: 0;
	width: 100%;
	height: 3px;
	background: var(--tp-ocean);
	opacity: .55;
	transform: scaleX(0);
	transform-origin: left center;
}
.tp-fetes.is-local .tp-fetes-progress { background: var(--tp-coral); }
.tp-fetes-progress.is-running { animation: tp-fetes-progress var(--tp-fetes-delay, 4.5s) linear forwards; }
.tp-fetes.is-paused .tp-fetes-progress { animation-play-state: paused; }
@keyframes tp-fetes-progress { to { transform: scaleX(1); } }

/* ---------- 6c-bis. Météo : commune, min/max, pluie, crédit ---------- */
.tp-weather-head { min-width: 0; flex: 1; }
.tp-commune {
	position: relative;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 2px 4px;
	max-width: 100%;
	margin-top: 2px;
	color: var(--tp-muted);
}
.tp-commune label { display: inline-flex; min-width: 0; max-width: 100%; margin: 0; }
.tp-cal .tp-commune .tp-island-select { font-weight: 500; color: var(--tp-muted); }
.tp-cal .tp-commune select { field-sizing: content; } /* largeur = option choisie (navigateurs récents) */
.tp-commune label + label::before { content: "›"; margin: 0 2px 0 0; color: var(--tp-faint); align-self: center; }
.tp-commune .tp-icon { width: 14px; height: 14px; color: var(--tp-ocean); flex-shrink: 0; }
.tp-cal .tp-commune-select,
.tp-cal .tp-island-select {
	max-width: 100%;
	margin: 0;
	padding: 3px 24px 3px 4px;
	border: 1px solid transparent;
	border-radius: 8px;
	background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5l3 3 3-3' fill='none' stroke='%2364748b' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 4px center / 12px;
	font: inherit;
	font-size: 13px;
	font-weight: 600;
	color: var(--tp-deep);
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	box-shadow: none;
	min-height: 0;
	height: auto;
	line-height: 1.3;
}
.tp-cal .tp-commune-select:hover,
.tp-cal .tp-commune-select:focus,
.tp-cal .tp-island-select:hover,
.tp-cal .tp-island-select:focus { border-color: #cfe0ec; background-color: var(--tp-sky-50); outline: none; }
.tp-cal .tp-commune-select:focus-visible,
.tp-cal .tp-island-select:focus-visible { outline: 2px solid var(--tp-ocean); outline-offset: 1px; }

.tp-weather-range { margin-top: 2px !important; font-size: 12.5px; font-weight: 600; color: var(--tp-deep); }

/* Vent et houle : direction (flèche orientée), force / hauteur, période */
.tp-weather-sea { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px !important; }
.tp-weather-sea li {
	display: grid;
	grid-template-columns: 22px 52px minmax(0, 1fr);
	align-items: center;
	gap: 6px;
	padding: 7px 10px;
	border-radius: 10px;
	background: var(--tp-sky-50);
	font-size: 13.5px;
	color: var(--tp-text);
}
.tp-sea-icon { display: inline-flex; color: var(--tp-lagoon); }
.tp-sea-icon .tp-icon { width: 20px; height: 20px; }
.tp-sea-label { font-size: 12.5px; color: var(--tp-muted); }
.tp-sea-value { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; font-variant-numeric: tabular-nums; }
.tp-sea-value strong { color: var(--tp-navy); font-weight: 700; }
.tp-sea-extra { font-size: 12px; color: var(--tp-muted); }
.tp-dir-arrow {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: #fff;
	color: var(--tp-ocean);
	box-shadow: 0 0 0 1px #d6e8f3;
}
.tp-weather-rain {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-bottom: 12px !important;
	font-size: 13px;
	color: var(--tp-muted);
}
.tp-weather-rain .tp-icon { width: 18px; height: 18px; color: var(--tp-lagoon); }
.tp-card-credit { margin-top: 8px !important; font-size: 11px; color: var(--tp-faint); }
.tp-card-weather.is-loading { opacity: .5; pointer-events: none; transition: opacity .2s; }

/* ---------- 6d. Cours du jour : change + or / argent / bitcoin ---------- */
.tp-fx {
	padding: 18px 20px;
	border-radius: 16px;
	background: linear-gradient(135deg, var(--tp-sky-50) 0%, #ffffff 100%);
	border: 1px solid var(--tp-line);
	text-align: center;
}
.tp-cal .tp-fx-main {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: baseline;
	gap: 4px 14px;
	font-family: var(--tp-serif);
	font-size: clamp(1.45rem, 3.6cqi, 2.2rem);
	line-height: 1.2;
	color: var(--tp-navy);
	font-variant-numeric: tabular-nums;
}
.tp-fx-eq { color: var(--tp-faint); }
.tp-fx-inverse { margin-top: 6px !important; font-size: 13.5px; color: var(--tp-muted); }

.tp-stats {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 16px;
	margin-top: 16px;
}
.tp-stat {
	display: flex;
	flex-direction: column;
	min-width: 0;
	padding: 18px 18px 14px;
	border-radius: 16px;
	background: #fff;
	border: 1px solid var(--tp-line);
}
.tp-stat-head { display: flex; align-items: center; gap: 10px; }
.tp-stat-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	font-size: 13px;
	font-weight: 800;
}
.tp-stat-xau .tp-stat-badge { background: #fef3c7; color: #92400e; box-shadow: inset 0 0 0 1px #fcd34d; }
.tp-stat-xag .tp-stat-badge { background: #f1f5f9; color: #475569; box-shadow: inset 0 0 0 1px #cbd5e1; }
.tp-stat-btc .tp-stat-badge { background: #fff7ed; color: #c2410c; box-shadow: inset 0 0 0 1px #fdba74; font-size: 17px; }
.tp-cal .tp-stat-head h3 { font-family: var(--tp-serif); font-weight: 400; font-size: 1.25rem; line-height: 1.15; color: var(--tp-navy); }
.tp-stat-unit { font-size: 12px; color: var(--tp-muted); }
.tp-cal .tp-stat-value {
	margin-top: 12px !important;
	font-size: 1.7rem;
	font-weight: 700;
	line-height: 1.1;
	color: var(--tp-navy);
	font-variant-numeric: tabular-nums;
	letter-spacing: -.01em !important;
}
.tp-stat-value span { font-size: .55em; font-weight: 600; color: var(--tp-muted); }
.tp-stat-sub { margin-top: 3px !important; font-size: 13px; color: var(--tp-muted); }
.tp-stat-delta { margin-top: 8px !important; font-size: 12.5px; font-weight: 600; color: var(--tp-text); }
.tp-stat-delta span { color: var(--tp-muted); font-size: 10px; margin-right: 2px; }

/* Sparkline 12 mois : trait atténué, mois en cours en accent, infobulle au survol */
.tp-spark {
	position: relative;
	height: 64px;
	margin-top: 12px;
	cursor: crosshair;
	touch-action: pan-y;
}
.tp-spark svg { display: block; width: 100%; height: 100%; overflow: visible; }
.tp-spark-base { stroke: var(--tp-line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.tp-spark-line { fill: none; stroke: #94a3b8; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.tp-spark-now { fill: none; stroke: var(--tp-ocean); stroke-width: 2.5; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.tp-spark-cross { stroke: #94a3b8; stroke-width: 1; stroke-dasharray: 3 3; vector-effect: non-scaling-stroke; }
.tp-spark-dot,
.tp-spark-hover {
	position: absolute;
	width: 9px;
	height: 9px;
	margin: -4.5px 0 0 -4.5px;
	border-radius: 50%;
	background: var(--tp-ocean);
	box-shadow: 0 0 0 2px #fff;
	pointer-events: none;
}
.tp-spark-hover { background: var(--tp-navy); }
.tp-spark-hover[hidden],
.tp-spark-tip[hidden] { display: none; }
.tp-spark-tip {
	position: absolute;
	bottom: calc(100% + 8px);
	z-index: 3;
	transform: translateX(-50%);
	padding: 6px 10px;
	border-radius: 8px;
	background: var(--tp-navy);
	color: #fff;
	font-size: 12px;
	line-height: 1.3;
	white-space: nowrap;
	text-align: center;
	pointer-events: none;
	box-shadow: 0 6px 18px rgba(11, 42, 69, .25);
}
.tp-spark-tip strong { display: block; font-size: 13px; font-variant-numeric: tabular-nums; }
.tp-spark-range { display: flex; justify-content: space-between; margin-top: 4px !important; font-size: 11.5px; color: var(--tp-faint); }

.tp-rates-source { margin-top: 14px !important; font-size: 11.5px; color: var(--tp-faint); }

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

/* ---------- 6d-bis. Colonne « histoire + mot du jour » et carte Mot du jour ---------- */
.tp-cards-col { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.tp-cards-col > .tp-card-history { flex: 1 1 auto; }
.tp-cards-col > .tp-card { min-height: 0; }

.tp-card-word { gap: 0; }
.tp-cal .tp-word {
	margin: 6px 0 0;
	font-family: var(--tp-serif);
	font-weight: 400;
	font-size: 2rem;
	line-height: 1.1;
	color: var(--tp-navy);
}
.tp-cal .tp-chip-lang { text-transform: none !important; letter-spacing: .01em !important; font-size: 11.5px; }
.tp-word-trad { margin-top: 2px !important; font-size: 1.05rem; font-style: italic; color: var(--tp-muted); }
.tp-word-example {
	margin-top: 14px;
	padding: 12px 14px;
	border-radius: 12px;
	background: var(--tp-sky-50);
	border: 1px solid var(--tp-line);
}
.tp-word-example-label {
	margin-bottom: 4px !important;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .06em !important;
	text-transform: uppercase !important;
	color: var(--tp-ocean);
}
.tp-word-example-text { font-weight: 600; color: var(--tp-navy); }
.tp-word-example-trad { margin-top: 2px !important; font-size: 13.5px; color: var(--tp-muted); }
.tp-word-expl { margin-top: 12px !important; font-size: 13.5px; line-height: 1.5; color: #475569; }

/* ---------- 6e. Heure de Tahiti, vacances scolaires, histoire ---------- */
.tp-cal .tp-clock {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin: -10px 0 16px !important;
	font-size: 14px;
	color: var(--tp-deep);
}
.tp-clock .tp-icon { width: 17px; height: 17px; color: var(--tp-lagoon); }
.tp-clock-time { font-size: 1.15rem; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--tp-navy); }
.tp-clock-zone { color: var(--tp-muted); font-size: 13px; white-space: nowrap; }
.tp-cal .tp-clock { flex-wrap: wrap; row-gap: 0; }

.tp-pill-vacances { background: #dcfce7; color: #166534; }
.tp-pill-vacances .tp-icon { color: #16a34a; }
.tp-pill-pedago { background: #dbeafe; color: #1e40af; }
.tp-pill-pedago .tp-icon { color: #2563eb; }

/* Calendrier : vacances = fond vert léger, journée pédagogique = soulignement violet */
.tp-cal .tp-cal-day.is-vacances { background: #dcfce7; border-radius: 8px; }
.tp-cal .tp-cal-day.is-pedago { background: #bfe6fe; border-radius: 8px; }
.tp-cal .tp-cal-day.is-vacances.is-selected,
.tp-cal .tp-cal-day.is-pedago.is-selected {
	border-radius: 50%;
	background: var(--tp-lagoon);
	color: #fff;
	box-shadow: 0 4px 10px rgba(8, 145, 178, .35);
}
.tp-cal .tp-cal-day.is-vacances.is-today:not(.is-selected) { box-shadow: inset 0 0 0 1.5px var(--tp-ocean); }
.tp-cal .tp-cal-day.is-ferie.is-vacances,
.tp-cal .tp-cal-day.is-ferie.is-pedago { background: #fadec0; }
.tp-cal .tp-cal-day.is-ferie.is-selected {
	border-radius: 50%;
	background: var(--tp-lagoon);
	color: #fff;
}
.tp-lg-vacances { width: 14px; height: 12px; border-radius: 3px; background: #dcfce7; box-shadow: inset 0 0 0 1px #86efac; }
.tp-lg-pedago { width: 14px; height: 12px; border-radius: 3px; background: #bfe6fe; box-shadow: inset 0 0 0 1px #93c5fd; }

.tp-chip-pays { background: var(--tp-sky); color: var(--tp-deep); }
.tp-chip-pays-polynesie { background: #ccfbf1; color: #115e59; }
.tp-chip-pays-france { background: #e0e7ff; color: #3730a3; }
.tp-history-date { margin: -4px 0 8px !important; font-size: 13px; font-weight: 600; color: var(--tp-coral-700); }

/* ---------- 6f. Préférences du visiteur : blocs repliables ---------- */
.tp-cal [data-tp-block] { position: relative; }
.tp-cal [data-tp-block] { scroll-margin-top: 90px; }
.tp-cal .tp-collapse-btn {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 4;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	padding: 0;
	border: 1px solid transparent;
	border-radius: 50%;
	background: rgba(255, 255, 255, .7);
	color: var(--tp-faint);
	opacity: 0;
	transition: opacity .15s, color .15s, background .15s, border-color .15s;
}
.tp-cal [data-tp-block]:hover > .tp-collapse-btn,
.tp-cal .tp-collapse-btn:focus-visible { opacity: 1; }
.tp-cal .tp-collapse-btn:hover { color: var(--tp-ocean); border-color: #cfe0ec; background: #fff; }
@media (hover: none) {
	.tp-cal .tp-collapse-btn { opacity: .85; }
}

.tp-cal .tp-collapsed-bar { display: none; }
.tp-cal [data-tp-block].is-collapsed > *:not(.tp-collapsed-bar) { display: none !important; }
.tp-cal [data-tp-block].is-collapsed {
	min-height: 0 !important;
	padding: 0 !important;
	background: none !important;
	border: 0 !important;
	box-shadow: none !important;
	animation: none;
}
.tp-cal [data-tp-block].is-collapsed > .tp-collapsed-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	width: 100%;
	padding: 10px 16px;
	border: 1px dashed #cfe0ec;
	border-radius: 14px;
	background: var(--tp-sky-50);
	font-size: 13.5px;
	color: var(--tp-muted);
	text-align: left;
}
.tp-collapsed-title { font-weight: 600; color: var(--tp-deep); }
.tp-collapsed-show { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; color: var(--tp-ocean); }
.tp-collapsed-show::before { content: "+"; font-size: 16px; line-height: 1; }
.tp-cal [data-tp-block].is-collapsed > .tp-collapsed-bar:hover { border-color: var(--tp-ocean); background: #fff; }
/* Bloc replié dans la grille des cartes : il ne prend pas toute la hauteur de la rangée */
.tp-cards > .is-collapsed { align-self: start; }

.tp-cal .tp-prefs-reset { margin-top: 18px !important; text-align: center; }
.tp-cal .tp-prefs-reset button {
	padding: 8px 16px;
	border: 1px solid #cfe0ec;
	border-radius: 999px;
	background: #fff;
	font-size: 13px;
	font-weight: 600;
	color: var(--tp-ocean);
}
.tp-cal .tp-prefs-reset button:hover { border-color: var(--tp-ocean); background: var(--tp-sky-50); }

/* ---------- 7. Responsive ---------- */

/* Les points de rupture suivent la largeur du bloc (container queries) et non celle de l'écran :
   le calendrier s'adapte aussi dans une colonne Elementor ou un thème étroit. */

/* Bloc moyen (tablette, colonne large) */
@container tpcal (max-width: 1000px) {
	.tp-hero,
	.tp-hero.has-visual {
		grid-template-columns: minmax(0, 1fr) 210px;
		padding: 32px;
	}
	/* Le texte occupe plus de largeur : voile prolongé */
	.tp-hero-veil {
		background: linear-gradient(
			90deg,
			rgba(255, 255, 255, calc(var(--tp-veil, .7) + .1)) 0%,
			rgba(255, 255, 255, var(--tp-veil, .7)) 50%,
			rgba(255, 255, 255, calc(var(--tp-veil, .7) * .4)) 80%,
			rgba(255, 255, 255, .1) 100%
		);
	}

	.tp-cards-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	/* Colonne histoire + mot : sur toute la largeur, les deux cartes côte à côte */
	.tp-cards-3 .tp-cards-col { grid-column: 1 / -1; flex-direction: row; }
	.tp-cards-3 .tp-cards-col > .tp-card { flex: 1 1 0; }

	.tp-year-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.tp-month:nth-child(4n) { border-right: 1px solid var(--tp-line); }
	.tp-month:nth-child(3n) { border-right: 0; }

	.tp-news-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Bloc étroit (mobile, colonne étroite) */
@container tpcal (max-width: 700px) {
	/* Hero sombre façon mockup mobile */
	.tp-hero,
	.tp-hero.has-visual {
		grid-template-columns: minmax(0, 1fr) auto;
		align-items: start;
		gap: 14px;
		min-height: 0;
		padding: 22px 18px 24px;
		border-radius: 22px;
		border: 0;
		background: linear-gradient(160deg, #0b3a5c 0%, #0369a1 60%, #0284c7 100%);
		color: #fff;
	}
	.tp-hero.has-visual { min-height: 0; }
	.tp-hero-visual { background-position: 72% 60%; }
	/* Mobile : voile sombre (texte blanc), intensité liée au réglage */
	.tp-hero-veil {
		background: linear-gradient(
			180deg,
			rgba(8, 47, 73, calc(.45 + var(--tp-veil, .7) * .45)) 0%,
			rgba(8, 47, 73, calc(.25 + var(--tp-veil, .7) * .4)) 55%,
			rgba(8, 47, 73, calc(.4 + var(--tp-veil, .7) * .45)) 100%
		);
	}
	.tp-hero.has-visual .tp-date,
	.tp-hero.has-visual .tp-eyebrow { text-shadow: 0 1px 10px rgba(0, 0, 0, .35); }
	.tp-hero.has-visual .tp-hero-moon {
		padding: 0;
		border: 0;
		background: none;
		-webkit-backdrop-filter: none;
		backdrop-filter: none;
		box-shadow: none;
	}
	.tp-hero.has-visual .tp-moon-figure { width: 84px; height: 84px; }

	/* Solstice / éclipse : sous les badges (colonne lune trop étroite) */
	.tp-hero-moon .tp-astro { display: none; }
	.tp-astro-narrow { display: flex; }
	.tp-astro-inline .tp-astro-item { background: rgba(255, 255, 255, .92); }
	.tp-astro-inline .tp-astro-item.is-eclipse { background: #1e293b; }

	.tp-eyebrow { color: #7dd3fc; font-size: 14px; margin-bottom: 6px !important; }
	.tp-cal .tp-date { font-size: 2.05rem; color: #fff; margin-bottom: 16px; }
	.tp-cal .tp-clock { color: #e0f2fe; margin-top: -8px !important; }
	.tp-clock-time { color: #fff; }
	.tp-clock-zone { color: #bae6fd; }
	.tp-clock .tp-icon { color: #7dd3fc; }

	.tp-badges { gap: 8px; }
	.tp-saint {
		padding: 5px 14px 5px 6px;
		background: rgba(255, 255, 255, .14);
		border-color: rgba(255, 255, 255, .25);
		box-shadow: none;
	}
	.tp-saint-icon { width: 32px; height: 32px; background: rgba(255, 255, 255, .9); }
	.tp-saint-icon .tp-icon { width: 22px; height: 22px; }
	.tp-saint-label { color: #bae6fd; }
	.tp-saint-name { color: #fff; font-size: 15px; }
	.tp-pill { padding: 7px 13px; font-size: 13px; }
	.tp-cal .tp-back-today,
	.tp-cal .tp-back-today:hover { color: #bae6fd; min-height: 44px; margin-top: 8px; }

	.tp-hero-moon {
		padding-left: 0;
		border-left: 0;
		width: 92px;
	}
	.tp-moon-figure {
		width: 84px;
		height: 84px;
		margin-bottom: 8px;
		box-shadow: 0 0 0 4px rgba(255, 255, 255, .15), 0 10px 26px rgba(0, 0, 0, .3);
	}
	.tp-moon-caption,
	.tp-moon-steps { display: none; }
	.tp-moon-name { font-size: 12.5px; line-height: 1.3; color: #fff; font-weight: 600; }
	.tp-moon-meta { flex-direction: column; gap: 0; font-size: 12px; color: #bae6fd; margin-top: 2px !important; }
	.tp-moon-meta span + span::before { content: none; }

	/* Cartes en 1 colonne */
	.tp-cards,
	.tp-cards-2,
	.tp-cards-3 { grid-template-columns: minmax(0, 1fr); gap: 14px; margin-top: 14px; }
	.tp-card { padding: 18px; border-radius: 18px; }
	.tp-cal .tp-card-head h3 { font-size: 1.25rem; }

	.tp-cards-3 .tp-cards-col { flex-direction: column; gap: 14px; }
	.tp-cards-3 .tp-cards-col > .tp-card { flex: 0 0 auto; }
	.tp-history-slide.has-image { grid-template-columns: minmax(0, 1fr); }
	.tp-history-slide.has-image .tp-history-media { order: -1; aspect-ratio: 16 / 9; }
	.tp-cal .tp-history-title { font-size: 1.6rem; }
	.tp-cal .tp-btn,
	.tp-cal .tp-btn-icon { min-height: 44px; }
	.tp-cal .tp-btn-icon { width: 44px; }
	.tp-cal .tp-history-nav .tp-btn-icon { width: 40px; height: 40px; min-height: 40px; }
	.tp-cal .tp-nearby-item { min-height: 48px; }

	.tp-extras { grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 14px; }

	.tp-cal .tp-proverb { grid-template-columns: 1fr; gap: 12px; margin-top: 26px !important; padding: 18px 16px; border-radius: 18px; background: linear-gradient(180deg, #f0f9ff, #fff); border: 1px solid var(--tp-line); }
	.tp-proverb-line { display: none; }
	.tp-cal .tp-proverb blockquote p { font-size: 1.2rem; }

	/* Panneaux */
	.tp-panel { margin-top: 20px; padding: 18px 12px 16px; border-radius: 20px; }
	.tp-section-head { padding: 0 4px; }
	.tp-cal .tp-section-title h2 { font-size: 1.35rem; }
	.tp-section-icon { width: 40px; height: 40px; border-radius: 12px; }
	.tp-year-actions { width: 100%; }
	.tp-year-actions .tp-goto-day { flex: 1; }

	/* Cours : tuiles empilées */
	.tp-stats { grid-template-columns: minmax(0, 1fr); gap: 12px; }
	.tp-fx { padding: 16px 12px; }

	/* Calendrier annuel : 2 colonnes de mois */
	.tp-year-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.tp-month,
	.tp-month:nth-child(3n),
	.tp-month:nth-child(4n) { padding: 12px 4px 10px; border-right: 1px solid var(--tp-line); }
	.tp-month:nth-child(2n) { border-right: 0; }
	.tp-cal .tp-month-title { font-size: 13px; }
	.tp-wd { font-size: 10px; }
	.tp-cal .tp-cal-day { font-size: 12px; max-width: 30px; }
	.tp-cal-day.is-full-moon::before,
	.tp-cal-day.is-new-moon::before { width: 6px; height: 6px; top: 0; right: 0; }
	.tp-legend { gap: 6px 14px; padding: 0 4px !important; }

	/* Actualités : défilement horizontal */
	.tp-news-list {
		display: flex;
		gap: 12px;
		margin: 0 -12px;
		padding: 2px 12px 8px;
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
	}
	.tp-news-list::-webkit-scrollbar { display: none; }
	.tp-cal .tp-news-card {
		flex: 0 0 72%;
		grid-template-columns: minmax(0, 1fr);
		grid-template-rows: auto 1fr;
		scroll-snap-align: start;
	}
	.tp-news-media { aspect-ratio: 16 / 10; }
}

/* Bloc très étroit (petits téléphones, marges du thème) */
@container tpcal (max-width: 400px) {
	.tp-month,
	.tp-month:nth-child(3n),
	.tp-month:nth-child(4n) { padding: 10px 1px 8px; }
	.tp-cal .tp-cal-day { font-size: 11px; letter-spacing: -.02em; }
	.tp-wd { font-size: 9.5px; }
	.tp-cal .tp-year-actions .tp-btn { padding: 9px 12px; }
	.tp-cal .tp-date { font-size: 1.85rem; }
}

/* Lightbox plein écran sur mobile (hors du conteneur : media query classique) */
@media (max-width: 767px) {
	.tp-lb { padding: 0; align-items: flex-end; }
	.tp-lb-dialog,
	.tp-lb-dialog.has-figure { grid-template-columns: minmax(0, 1fr); max-height: 92vh; border-radius: 22px 22px 0 0; }
	.tp-lb-figure { min-height: 0; }
	.tp-lb-figure img { max-height: 45vh; }
	.tp-lb-body { padding: 22px 20px 30px; }
	.tp-lb-title { font-size: 1.55rem; }
}

@media (prefers-reduced-motion: reduce) {
	.tp-cal *,
	.tp-lb,
	.tp-toast { animation: none !important; transition: none !important; }
}
