/*
Theme Name: Compress Theme
Theme URI: https://meilleur-compresseur.fr
Description: Thème enfant GeneratePress pour meilleur-compresseur.fr. Identité « atelier » — bleu pétrole, accent ambre, typographie d'instrumentation (Saira + Inter) et motif manomètre. Simple, moderne, rapide. À utiliser avec le thème parent GeneratePress.
Author: Meilleur Compresseur
Author URI: https://meilleur-compresseur.fr
Template: generatepress
Version: 1.4.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: compress-theme
*/

/* ==========================================================================
   1. JETONS DE DESIGN (couleurs, ombres, rayons)
   ========================================================================== */
:root {
	/* Encre & textes */
	--mc-ink:        #14222e; /* texte principal */
	--mc-ink-soft:   #3a4a57; /* texte secondaire */
	--mc-steel:      #5e6e7a; /* gris acier, métas, graduations */

	/* Bleu pétrole — la marque */
	--mc-blue:       #0c4a60;
	--mc-blue-700:   #0a3c4e;
	--mc-blue-900:   #072d3b;
	--mc-blue-link:  #176f8c; /* liens dans le texte (contraste AA) */

	/* Ambre — l'air sous pression, les CTA */
	--mc-amber:      #f08a1d;
	--mc-amber-600:  #d9740c;
	--mc-amber-100:  #fdeed7;

	/* Surfaces & lignes */
	--mc-paper:      #ffffff;
	--mc-mist:       #eef4f7; /* fond de section clair */
	--mc-mist-2:     #f6f9fb;
	--mc-line:       #d9e2e8;
	--mc-line-soft:  #e7eef2;

	/* États */
	--mc-ok:         #1e8f5b;

	/* Rayons & ombres */
	--mc-radius:     12px;
	--mc-radius-sm:  8px;
	--mc-shadow:     0 1px 2px rgba(14, 34, 46, .06), 0 6px 20px rgba(14, 34, 46, .07);
	--mc-shadow-sm:  0 1px 2px rgba(14, 34, 46, .08);

	/* Typo */
	--mc-font-body:    "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	--mc-font-display: "Saira", var(--mc-font-body);
}

/* ==========================================================================
   2. BASE & TYPOGRAPHIE
   ========================================================================== */
body {
	font-family: var(--mc-font-body);
	font-size: 17px;
	line-height: 1.7;
	color: var(--mc-ink);
	background-color: var(--mc-paper);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

.entry-content,
.inside-article {
	color: var(--mc-ink-soft);
}

h1, h2, h3, h4, h5, h6,
.entry-title,
.widget-title,
.main-title {
	font-family: var(--mc-font-display);
	color: var(--mc-ink);
	line-height: 1.18;
	letter-spacing: -0.01em;
	font-weight: 700;
}

h1, .entry-title {
	font-size: clamp(2rem, 1.4rem + 2.6vw, 3rem);
	font-weight: 800;
	letter-spacing: -0.02em;
	color: var(--mc-blue-900);
}

h2 {
	font-size: clamp(1.55rem, 1.15rem + 1.5vw, 2.05rem);
	margin-top: 2.4em;
}

h3 { font-size: clamp(1.25rem, 1.05rem + 0.6vw, 1.45rem); margin-top: 1.8em; }
h4 { font-size: 1.15rem; }
h5 { font-size: 1rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--mc-steel); }
h6 { font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--mc-steel); }

p { margin-bottom: 1.25em; }

strong, b { color: var(--mc-ink); font-weight: 700; }

::selection { background: var(--mc-amber-100); color: var(--mc-blue-900); }

/* Repère ambre sous les H2 du contenu — motif « niveau / aiguille » */
.entry-content h2,
.page-content h2 {
	position: relative;
	padding-bottom: 0.45rem;
}
.entry-content h2::after,
.page-content h2::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: 0;
	width: 2.6rem;
	height: 3px;
	border-radius: 3px;
	background: var(--mc-amber);
}

/* ==========================================================================
   3. LIENS
   ========================================================================== */
a {
	color: var(--mc-blue-link);
	text-decoration: none;
	transition: color .15s ease;
}
.entry-content a:not(.button):not(.wp-block-button__link) {
	text-decoration: underline;
	text-decoration-color: rgba(23, 111, 140, .35);
	text-underline-offset: 3px;
	text-decoration-thickness: 1.5px;
}
a:hover,
a:focus {
	color: var(--mc-amber-600);
}
.entry-content a:not(.button):not(.wp-block-button__link):hover {
	text-decoration-color: var(--mc-amber-600);
}

/* ==========================================================================
   4. BOUTONS & CTA
   ========================================================================== */
.button,
button:not(.menu-toggle):not(.search-submit),
input[type="submit"],
input[type="button"],
.wp-block-button__link,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce .button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: .5em;
	font-family: var(--mc-font-display);
	font-weight: 600;
	font-size: 1rem;
	letter-spacing: 0.01em;
	line-height: 1.2;
	color: #fff;
	background-color: var(--mc-amber);
	border: 0;
	border-radius: var(--mc-radius-sm);
	padding: 0.7em 1.4em;
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), var(--mc-shadow-sm);
	cursor: pointer;
	transition: background-color .15s ease, transform .12s ease, box-shadow .15s ease;
	text-decoration: none;
}
.button:hover,
button:not(.menu-toggle):not(.search-submit):hover,
input[type="submit"]:hover,
input[type="button"]:hover,
.wp-block-button__link:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce .button:hover {
	background-color: var(--mc-amber-600);
	color: #fff;
	transform: translateY(-1px);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 4px 14px rgba(217, 116, 12, .28);
}
.button:active,
.wp-block-button__link:active {
	transform: translateY(0);
	box-shadow: inset 0 2px 4px rgba(120, 60, 0, .25);
}

/* Bouton secondaire (contour bleu pétrole) */
.is-style-outline .wp-block-button__link,
.button.is-outline {
	background: transparent;
	color: var(--mc-blue);
	box-shadow: inset 0 0 0 2px var(--mc-blue);
}
.is-style-outline .wp-block-button__link:hover,
.button.is-outline:hover {
	background: var(--mc-blue);
	color: #fff;
	box-shadow: inset 0 0 0 2px var(--mc-blue);
}

/* ==========================================================================
   5. EN-TÊTE & IDENTITÉ
   ========================================================================== */
.site-header {
	background-color: var(--mc-paper);
	border-bottom: 1px solid var(--mc-line);
}
.inside-header {
	padding-top: 18px;
	padding-bottom: 18px;
}
.main-title {
	font-family: var(--mc-font-display);
	font-weight: 800;
	letter-spacing: -0.02em;
}
.main-title a {
	color: var(--mc-blue);
}
.main-title a:hover {
	color: var(--mc-amber-600);
}
.site-description {
	color: var(--mc-steel);
	font-size: 0.92rem;
}

/* ==========================================================================
   6. NAVIGATION
   ========================================================================== */
.main-navigation {
	background-color: var(--mc-paper);
	border-bottom: 1px solid var(--mc-line);
}
.main-navigation .main-nav ul li a {
	font-family: var(--mc-font-display);
	font-weight: 600;
	font-size: 0.96rem;
	letter-spacing: 0.005em;
	color: var(--mc-ink);
	position: relative;
}
.main-navigation .main-nav ul li a:hover,
.main-navigation .main-nav ul li.current-menu-item > a,
.main-navigation .main-nav ul li:hover > a {
	color: var(--mc-blue);
	background: transparent;
}
/* Soulignement « jauge » au survol et sur l'item courant */
.main-navigation .main-nav > ul > li > a::after {
	content: "";
	position: absolute;
	left: 20px;
	right: 20px;
	bottom: 12px;
	height: 2px;
	border-radius: 2px;
	background: var(--mc-amber);
	transform: scaleX(0);
	transform-origin: left;
	transition: transform .18s ease;
}
.main-navigation .main-nav > ul > li:hover > a::after,
.main-navigation .main-nav > ul > li.current-menu-item > a::after {
	transform: scaleX(1);
}

/* Sous-menus : carte blanche douce */
.main-navigation ul ul {
	background-color: var(--mc-paper);
	border: 1px solid var(--mc-line);
	border-radius: var(--mc-radius-sm);
	box-shadow: var(--mc-shadow);
	padding: 6px;
	overflow: hidden;
}
.main-navigation ul ul li a {
	border-radius: 6px;
}
.main-navigation ul ul li:hover > a,
.main-navigation ul ul li.current-menu-item > a {
	background-color: var(--mc-mist);
	color: var(--mc-blue);
}
.main-navigation ul ul > li > a::after { display: none; }

/* Recherche de la navigation */
.navigation-search input[type="search"] {
	background: var(--mc-mist);
	border: 1px solid var(--mc-line);
}

/* Bouton menu mobile */
.menu-toggle {
	font-family: var(--mc-font-display);
	font-weight: 600;
	color: var(--mc-ink);
}

/* ==========================================================================
   7. CONTENU / ARTICLE
   ========================================================================== */
.inside-article {
	font-size: 1.05rem;
}
.entry-meta {
	color: var(--mc-steel);
	font-size: 0.86rem;
}
.entry-meta a { color: var(--mc-steel); }
.entry-meta a:hover { color: var(--mc-amber-600); }

.page-header,
.entry-header {
	margin-bottom: 1.25rem;
}

/* Listes du contenu : puces ambre */
.entry-content ul:not(.wp-block-gallery):not(.menu) {
	list-style: none;
	padding-left: 1.4em;
}
.entry-content ul:not(.wp-block-gallery):not(.menu) > li {
	position: relative;
	margin-bottom: 0.5em;
}
.entry-content ul:not(.wp-block-gallery):not(.menu) > li::before {
	content: "";
	position: absolute;
	left: -1.15em;
	top: 0.62em;
	width: 7px;
	height: 7px;
	border-radius: 2px;
	background: var(--mc-amber);
}
.entry-content ol { padding-left: 1.3em; }
.entry-content ol > li { margin-bottom: 0.5em; }
.entry-content ol > li::marker {
	color: var(--mc-blue);
	font-family: var(--mc-font-display);
	font-weight: 700;
}

/* Images & figures */
.entry-content img,
.wp-block-image img {
	border-radius: var(--mc-radius-sm);
}
.wp-block-image figcaption,
figcaption {
	color: var(--mc-steel);
	font-size: 0.85rem;
}

/* Citations */
blockquote {
	border-left: 4px solid var(--mc-amber);
	background: var(--mc-mist);
	margin: 1.8em 0;
	padding: 1em 1.25em;
	border-radius: 0 var(--mc-radius-sm) var(--mc-radius-sm) 0;
	color: var(--mc-blue-900);
}
blockquote p:last-child { margin-bottom: 0; }
blockquote cite { color: var(--mc-steel); font-style: normal; }

/* Code */
code, kbd, pre {
	font-family: ui-monospace, "SFMono-Regular", "Menlo", monospace;
}
:not(pre) > code {
	background: var(--mc-mist);
	color: var(--mc-blue-900);
	padding: 0.12em 0.4em;
	border-radius: 5px;
	font-size: 0.9em;
}
pre {
	background: var(--mc-blue-900);
	color: #e7eef2;
	padding: 1em 1.25em;
	border-radius: var(--mc-radius-sm);
	overflow: auto;
}

/* ==========================================================================
   8. SÉPARATEUR « MANOMÈTRE » (signature)
   ========================================================================== */
hr,
.wp-block-separator:not(.is-style-dots) {
	border: 0;
	height: 14px;
	width: 100%;
	max-width: 100%;
	margin: 2.75rem auto;
	opacity: 1;
	background:
		/* aiguille centrale ambre */
		linear-gradient(var(--mc-amber), var(--mc-amber)) center bottom / 2px 14px no-repeat,
		/* graduations acier */
		repeating-linear-gradient(90deg, var(--mc-steel) 0 1px, transparent 1px 11px) center bottom / 100% 9px no-repeat,
		/* ligne de base */
		linear-gradient(var(--mc-line), var(--mc-line)) left bottom / 100% 1px no-repeat;
}

/* ==========================================================================
   9. TABLEAUX (design « comparatif » de la maquette, valable sur tout le site)
   ========================================================================== */
/* Conteneur arrondi : pour le bloc Tableau natif, la figure sert d'enveloppe */
.entry-content .wp-block-table,
.entry-content table {
	border-radius: var(--mc-radius-sm);
	overflow: hidden;
	box-shadow: 0 0 0 1px var(--mc-line);
}
.entry-content .wp-block-table { background: var(--mc-paper); }
.entry-content .wp-block-table table {
	box-shadow: none;
	border-radius: 0;
}
.entry-content table {
	border-collapse: collapse;
	width: 100%;
	font-size: 0.95rem;
	margin-block: 1.6em;
}
.entry-content thead th {
	background: var(--mc-blue);
	color: #fff;
	font-family: var(--mc-font-display);
	font-weight: 600;
	text-align: left;
	padding: 14px 16px;
	border: 0;
}
.entry-content th,
.entry-content td {
	padding: 13px 16px;
	border: 0;
	border-bottom: 1px solid var(--mc-line-soft);
	color: var(--mc-ink-soft);
}
.entry-content tbody tr:nth-child(even) {
	background: var(--mc-mist-2);
}
.entry-content tbody tr:last-child td {
	border-bottom: 0;
}
.entry-content td b,
.entry-content td strong {
	color: var(--mc-blue-900);
}

/* Pastilles de niveau réutilisables (ex. colonne « Bruit ») */
.mc-tag {
	display: inline-block;
	font-family: var(--mc-font-display);
	font-weight: 600;
	font-size: 0.78rem;
	line-height: 1.4;
	padding: 3px 10px;
	border-radius: 999px;
	white-space: nowrap;
}
.mc-tag.is-low  { background: #e3f3ec; color: #1e8f5b; } /* faible / vert   */
.mc-tag.is-mid  { background: #fdeed7; color: #d9740c; } /* moyen / ambre   */
.mc-tag.is-high { background: #fbe2dd; color: #c0432a; } /* élevé / rouge   */


/* ==========================================================================
   10. BARRE LATÉRALE & WIDGETS
   ========================================================================== */
.sidebar .widget,
.inside-right-sidebar .widget,
.inside-left-sidebar .widget {
	background: var(--mc-paper);
	border: 1px solid var(--mc-line);
	border-radius: var(--mc-radius);
	padding: 1.25rem 1.25rem 1.4rem;
	margin-bottom: 1.75rem;
	box-shadow: var(--mc-shadow-sm);
}
.widget-title {
	font-family: var(--mc-font-display);
	font-weight: 700;
	font-size: 1.05rem;
	color: var(--mc-blue-900);
	margin-bottom: 0.9rem;
	padding-left: 0.7rem;
	border-left: 3px solid var(--mc-amber);
	line-height: 1.3;
}
.widget ul { list-style: none; padding: 0; }
.widget ul li {
	padding: 0.35rem 0;
	border-bottom: 1px solid var(--mc-line-soft);
}
.widget ul li:last-child { border-bottom: 0; }
.widget a { color: var(--mc-ink); }
.widget a:hover { color: var(--mc-amber-600); }

/* ==========================================================================
   11. PIED DE PAGE
   ========================================================================== */
.site-footer {
	background-color: var(--mc-blue-900);
	color: rgba(231, 238, 242, .82);
}
.footer-widgets {
	border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.site-footer .widget-title {
	color: #fff;
	border-left-color: var(--mc-amber);
}
.site-footer a {
	color: rgba(231, 238, 242, .85);
}
.site-footer a:hover {
	color: var(--mc-amber);
}
.site-footer .widget ul li {
	border-bottom-color: rgba(255, 255, 255, .08);
}
.site-info {
	background-color: var(--mc-blue-900);
	color: rgba(231, 238, 242, .65);
	font-size: 0.88rem;
}
.site-info a { color: rgba(231, 238, 242, .8); }
.site-info a:hover { color: var(--mc-amber); }

/* Bouton « retour en haut » */
.generate-back-to-top {
	background-color: var(--mc-blue) !important;
	border-radius: var(--mc-radius-sm) !important;
}
.generate-back-to-top:hover {
	background-color: var(--mc-amber-600) !important;
}

/* ==========================================================================
   12. PAGINATION & COMMENTAIRES
   ========================================================================== */
.nav-links .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.4em;
	height: 2.4em;
	padding: 0 0.5em;
	border-radius: var(--mc-radius-sm);
	border: 1px solid var(--mc-line);
	color: var(--mc-ink);
	font-family: var(--mc-font-display);
	font-weight: 600;
}
.nav-links .page-numbers.current,
.nav-links a.page-numbers:hover {
	background: var(--mc-blue);
	border-color: var(--mc-blue);
	color: #fff;
}
.comment-respond input[type="text"],
.comment-respond input[type="email"],
.comment-respond input[type="url"],
.comment-respond textarea,
input[type="text"],
input[type="email"],
input[type="url"],
input[type="search"],
input[type="tel"],
input[type="number"],
input[type="password"],
textarea,
select {
	border: 1px solid var(--mc-line);
	border-radius: var(--mc-radius-sm);
	background: var(--mc-paper);
	color: var(--mc-ink);
}
input:focus,
textarea:focus,
select:focus {
	border-color: var(--mc-blue);
	box-shadow: 0 0 0 3px rgba(12, 74, 96, .14);
	outline: 0;
}

/* ==========================================================================
   13. WOOCOMMERCE (touches légères, cohérentes)
   ========================================================================== */
.woocommerce ul.products li.product .price,
.woocommerce div.product p.price,
.woocommerce div.product span.price {
	color: var(--mc-blue-900);
	font-family: var(--mc-font-display);
	font-weight: 700;
}
.woocommerce span.onsale {
	background: var(--mc-amber);
	color: #fff;
	border-radius: 999px;
	font-family: var(--mc-font-display);
}
.woocommerce .star-rating span::before,
.woocommerce p.stars a::before { color: var(--mc-amber); }
.woocommerce ul.products li.product a img,
.woocommerce div.product div.images img { border-radius: var(--mc-radius-sm); }
.woocommerce-message,
.woocommerce-info {
	border-top-color: var(--mc-blue) !important;
}
.woocommerce-message::before,
.woocommerce-info::before { color: var(--mc-blue); }

/* ==========================================================================
   14. ACCESSIBILITÉ & FINITIONS
   ========================================================================== */
:focus-visible {
	outline: 3px solid var(--mc-amber);
	outline-offset: 2px;
	border-radius: 4px;
}
a:focus:not(:focus-visible),
button:focus:not(:focus-visible) { outline: none; }

/* Barre de défilement discrète (navigateurs compatibles) */
* { scrollbar-color: var(--mc-steel) transparent; }

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		transition-duration: 0.01ms !important;
		animation-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

/* ==========================================================================
   15. RESPONSIVE
   ========================================================================== */
@media (max-width: 768px) {
	body { font-size: 16.5px; }
	.inside-article { font-size: 1rem; }
	h2 { margin-top: 1.8em; }
	.main-navigation .main-nav > ul > li > a::after { display: none; }
}
