/*
Theme Name: M.S WATT
Theme URI: https://mswatt.fr
Author: M.S WATT
Description: Thème vitrine sur-mesure pour M.S WATT, électricien indépendant à Bordeaux/Gironde. Une page unique (accueil) + mentions légales et politique de confidentialité conformes RGPD/LCEN.
Version: 1.0.0
Requires PHP: 7.4
Text Domain: ms-watt
*/

/* ==========================================================================
   Polices auto-hébergées (RGPD : aucune requête vers Google Fonts)
   ========================================================================== */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/fonts/inter-variable.woff2") format("woff2");
}
@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url("assets/fonts/space-grotesk-variable.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("assets/fonts/jetbrains-mono-500.woff2") format("woff2");
}

/* ==========================================================================
   Tokens
   ========================================================================== */
:root {
  --background: #05070d;
  --background-alt: #0a0f1c;
  --surface: rgba(255, 255, 255, 0.04);
  --border: rgba(255, 255, 255, 0.1);
  --foreground: #eef2fb;
  --muted: #93a0bd;
  --primary: #22d3ee;
  --primary-strong: #5eead4;
  --primary-foreground: #04141a;
  --accent: #ffb020;
  --accent-foreground: #1a1103;
  --danger: #f87171;
  --danger-bg: rgba(248, 113, 113, 0.08);
  --font-heading: "Space Grotesk", system-ui, -apple-system, sans-serif;
  --font-sans: "Inter", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --container-max: 1200px;
}

/* ==========================================================================
   Reset & base
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; color-scheme: dark; }
body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-heading); margin: 0; font-weight: 600; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
button { font: inherit; cursor: pointer; background: none; border: none; color: inherit; }
input, textarea, select { font: inherit; color: inherit; }
::selection { background: color-mix(in srgb, var(--primary) 25%, transparent); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 2px; }

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 20px;
}
@media (min-width: 640px) { .container { padding: 0 32px; } }

.section { position: relative; padding: 96px 0; }
@media (min-width: 640px) { .section { padding: 128px 0; } }

.mono {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* ==========================================================================
   Reveal-on-scroll (progressive enhancement — visible by default)
   ========================================================================== */
[data-reveal] {
  opacity: 1;
  transform: none;
}
.js-reveal-ready [data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.js-reveal-ready [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .js-reveal-ready [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  border-radius: 999px;
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  border: 1px solid transparent;
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn--primary {
  background: var(--primary);
  color: var(--primary-foreground);
  box-shadow: 0 4px 14px -4px color-mix(in srgb, var(--primary) 55%, transparent);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 10px 28px -6px color-mix(in srgb, var(--primary) 55%, transparent); }
.btn--accent {
  background: var(--accent);
  color: var(--accent-foreground);
  box-shadow: 0 4px 14px -4px color-mix(in srgb, var(--accent) 50%, transparent);
}
.btn--accent:hover { transform: translateY(-2px); box-shadow: 0 10px 28px -6px color-mix(in srgb, var(--accent) 50%, transparent); }
.btn--outline {
  background: color-mix(in srgb, var(--foreground) 2%, transparent);
  border-color: var(--border);
  color: var(--foreground);
}
.btn--outline:hover { border-color: var(--primary); color: var(--primary); }
.btn--block { width: 100%; }
.btn--sm { padding: 10px 18px; font-size: 13px; }

/* ==========================================================================
   Cards
   ========================================================================== */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 1px 2px rgba(28, 22, 16, 0.04);
  transition: border-color 0.3s ease;
}
.card:hover { border-color: color-mix(in srgb, var(--primary) 40%, var(--border)); }

/* ==========================================================================
   Section heading
   ========================================================================== */
.section-heading { display: flex; flex-direction: column; gap: 12px; max-width: 640px; }
.section-heading--center { align-items: center; text-align: center; margin: 0 auto; }
.section-heading .mono { color: var(--primary); }
.section-heading h2 { font-size: 28px; letter-spacing: -0.01em; }
@media (min-width: 640px) { .section-heading h2 { font-size: 34px; } }
.section-heading p { color: var(--muted); font-size: 17px; line-height: 1.6; }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  transition: background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: color-mix(in srgb, var(--background) 95%, transparent);
  backdrop-filter: blur(16px);
  border-color: var(--border);
  box-shadow: 0 4px 24px rgba(28, 22, 16, 0.08);
}
.site-header__bar { display: flex; align-items: center; justify-content: space-between; height: 72px; }
@media (min-width: 640px) { .site-header__bar { height: 84px; } }
.site-logo { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.site-logo img { height: 40px; width: 40px; }
.site-logo span { font-family: var(--font-heading); font-size: 18px; font-weight: 700; letter-spacing: -0.01em; }

.site-nav { display: none; align-items: center; gap: 28px; }
.site-nav a { font-size: 14px; font-weight: 500; color: var(--muted); transition: color 0.2s ease; }
.site-nav a:hover { color: var(--primary); }

.header-actions { display: none; align-items: center; gap: 16px; }
.header-actions .phone-link { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; }
.header-actions .phone-link:hover { color: var(--primary); }
.header-actions .phone-link svg { width: 16px; height: 16px; }

.header-mobile { display: flex; align-items: center; gap: 12px; }
.icon-btn {
  display: flex; align-items: center; justify-content: center;
  height: 40px; width: 40px; border-radius: 999px;
  border: 1px solid var(--border);
}
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn--fill { background: var(--primary); color: var(--primary-foreground); border-color: transparent; }

@media (min-width: 1024px) {
  .site-nav { display: flex; }
  .header-actions { display: flex; }
  .header-mobile { display: none; }
}

.mobile-menu {
  display: none;
  border-top: 1px solid var(--border);
  background: color-mix(in srgb, var(--background) 98%, transparent);
  backdrop-filter: blur(16px);
}
.mobile-menu.is-open { display: block; }
.mobile-menu .container { display: flex; flex-direction: column; gap: 4px; padding-top: 16px; padding-bottom: 16px; }
.mobile-menu a { padding: 12px; border-radius: 10px; font-weight: 500; }
.mobile-menu a:hover { background: color-mix(in srgb, var(--foreground) 5%, transparent); color: var(--primary); }
.mobile-menu .btn { margin-top: 8px; }
@media (min-width: 1024px) { .mobile-menu { display: none !important; } }

/* ==========================================================================
   Text gradient (titre accent)
   ========================================================================== */
.text-gradient {
  background: linear-gradient(100deg, var(--primary) 0%, var(--primary-strong) 45%, var(--accent) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

/* ==========================================================================
   Fond "circuit imprimé" (décoratif, purement visuel)
   ========================================================================== */
.circuit-grid {
  background-image:
    linear-gradient(color-mix(in srgb, var(--primary) 14%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--primary) 14%, transparent) 1px, transparent 1px);
  background-size: 48px 48px;
}
@keyframes spark-blink { 0%, 100% { opacity: 0.4; } 50% { opacity: 1; } }
.spark-dot { animation: spark-blink 1.8s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) { .spark-dot { animation: none; opacity: 0.8; } }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 92vh;
  display: flex;
  align-items: center;
  padding: 150px 0 90px;
  background: radial-gradient(ellipse at top, var(--background-alt), var(--background));
}
@media (min-width: 640px) { .hero { padding: 180px 0 120px; } }

.hero__bg { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.hero__bg .circuit-grid { position: absolute; inset: 0; opacity: 0.4; mask-image: radial-gradient(ellipse at center, black 0%, transparent 75%); -webkit-mask-image: radial-gradient(ellipse at center, black 0%, transparent 75%); }
.hero__circuit-lines { position: absolute; top: -40px; right: -80px; width: 480px; height: 480px; opacity: 0.7; }
@media (min-width: 640px) { .hero__circuit-lines { right: -40px; } }

.hero__content { position: relative; z-index: 1; max-width: 760px; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent);
  background: color-mix(in srgb, var(--primary) 10%, transparent);
  color: var(--primary);
  padding: 6px 16px;
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
}
.badge svg { width: 14px; height: 14px; }

.hero h1 {
  margin-top: 24px;
  font-size: 40px;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.01em;
}
@media (min-width: 640px) { .hero h1 { font-size: 60px; } }
@media (min-width: 1024px) { .hero h1 { font-size: 64px; } }

.hero p.lead { margin-top: 24px; max-width: 560px; font-size: 18px; color: var(--muted); }
.hero .cta-row { margin-top: 40px; display: flex; flex-direction: column; gap: 16px; }
@media (min-width: 640px) { .hero .cta-row { flex-direction: row; align-items: center; } }
.hero .phone-link { display: inline-flex; align-items: center; gap: 8px; padding: 12px 8px; font-size: 16px; font-weight: 600; }
.hero .phone-link:hover { color: var(--primary); }
.hero .phone-link svg { width: 16px; height: 16px; }

/* ==========================================================================
   Lightning divider
   ========================================================================== */
.divider { display: flex; align-items: center; justify-content: center; padding: 8px 0; }
.divider svg { width: 120px; height: 24px; }

/* ==========================================================================
   Services
   ========================================================================== */
.services-grid { margin-top: 56px; display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 640px) { .services-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .services-grid { grid-template-columns: repeat(4, 1fr); } }
.service-card { padding: 24px; height: 100%; }
.service-card .icon-square {
  display: flex; align-items: center; justify-content: center;
  height: 44px; width: 44px; border-radius: 12px;
  background: color-mix(in srgb, var(--primary) 10%, transparent);
  color: var(--primary);
  transition: background 0.2s ease, color 0.2s ease;
}
.service-card .icon-square svg { width: 20px; height: 20px; }
.service-card:hover .icon-square { background: var(--primary); color: var(--primary-foreground); }
.service-card h3 { margin-top: 20px; font-size: 18px; }
.service-card p { margin-top: 8px; font-size: 14px; line-height: 1.6; color: var(--muted); }

/* ==========================================================================
   Gallery
   ========================================================================== */
.gallery-filters { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 10px; }
.gallery-filters button {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  transition: all 0.2s ease;
}
.gallery-filters button:hover { color: var(--foreground); border-color: var(--primary); }
.gallery-filters button.is-active { background: var(--primary); color: var(--primary-foreground); border-color: transparent; }

.gallery-grid { margin-top: 28px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (min-width: 640px) { .gallery-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .gallery-grid { grid-template-columns: repeat(4, 1fr); } }
.gallery-item {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--border);
  cursor: zoom-in;
}
.gallery-item.is-hidden { display: none; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item__overlay {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, 0); opacity: 0;
  color: #fff;
  transition: all 0.25s ease;
}
.gallery-item:hover .gallery-item__overlay { background: rgba(0, 0, 0, 0.4); opacity: 1; }
.gallery-item__overlay svg { width: 24px; height: 24px; }

.lightbox {
  position: fixed; inset: 0; z-index: 300;
  display: none;
  align-items: center; justify-content: center;
  background: rgba(10, 8, 6, 0.92);
  padding: 16px;
}
.lightbox.is-open { display: flex; }
.lightbox__inner { position: relative; max-width: 960px; width: 100%; }
.lightbox__inner img { max-height: 80vh; margin: 0 auto; border-radius: 12px; width: auto; }
.lightbox__caption { margin-top: 12px; text-align: center; font-size: 14px; color: rgba(255,255,255,0.7); }
.lightbox__close, .lightbox__prev, .lightbox__next {
  position: absolute;
  display: flex; align-items: center; justify-content: center;
  height: 44px; width: 44px; border-radius: 999px;
  background: rgba(255,255,255,0.1); color: #fff;
}
.lightbox__close:hover, .lightbox__prev:hover, .lightbox__next:hover { background: rgba(255,255,255,0.2); }
.lightbox__close { top: -56px; right: 0; }
.lightbox__prev { left: 8px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 8px; top: 50%; transform: translateY(-50%); }
.lightbox__close svg, .lightbox__prev svg, .lightbox__next svg { width: 20px; height: 20px; }

/* ==========================================================================
   About
   ========================================================================== */
.about-grid { display: grid; grid-template-columns: 1fr; gap: 48px; align-items: center; }
@media (min-width: 1024px) { .about-grid { grid-template-columns: 0.9fr 1.1fr; } }
.about-photo-wrap { position: relative; max-width: 384px; margin: 0 auto; }
.about-photo-wrap::before {
  content: "";
  position: absolute; inset: -16px;
  border-radius: 24px;
  background: color-mix(in srgb, var(--primary) 10%, transparent);
  filter: blur(24px);
  z-index: 0;
}
.about-photo { position: relative; aspect-ratio: 4 / 5; overflow: hidden; z-index: 1; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.about-copy { margin-top: 24px; display: flex; flex-direction: column; gap: 16px; font-size: 16px; line-height: 1.7; color: var(--muted); }
.about-copy .signature { font-family: var(--font-heading); font-size: 18px; font-weight: 600; color: var(--foreground); }

/* ==========================================================================
   Reviews
   ========================================================================== */
.reviews-empty { max-width: 480px; margin: 48px auto 0; text-align: center; padding: 40px; }
.reviews-empty .icon-circle { margin: 0 auto; display: flex; align-items: center; justify-content: center; height: 56px; width: 56px; border-radius: 999px; background: color-mix(in srgb, var(--accent) 15%, transparent); color: var(--accent); }
.reviews-empty .icon-circle svg { width: 28px; height: 28px; }
.reviews-empty h3 { margin-top: 20px; font-size: 20px; }
.reviews-empty p { margin-top: 8px; font-size: 14px; color: var(--muted); }
.reviews-empty .btn { margin-top: 24px; }

.reviews-grid { margin-top: 48px; display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 768px) { .reviews-grid { grid-template-columns: repeat(3, 1fr); } }
.review-card { padding: 28px; display: flex; flex-direction: column; gap: 16px; }
.review-card__stars { display: flex; gap: 2px; color: var(--accent); }
.review-card__stars svg { width: 16px; height: 16px; fill: currentColor; }
.review-card__text { font-size: 15px; line-height: 1.6; color: var(--foreground); flex: 1; }
.review-card__author { font-family: var(--font-heading); font-size: 14px; font-weight: 600; color: var(--muted); }
.reviews-cta { margin-top: 40px; display: flex; justify-content: center; }

/* ==========================================================================
   Zone d'intervention
   ========================================================================== */
.zone-grid { margin-top: 48px; display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 1024px) { .zone-grid { grid-template-columns: 1.3fr 1fr; } }
.zone-map { overflow: hidden; padding: 0; }
.zone-map iframe { width: 100%; height: 360px; border: 0; filter: grayscale(0.3) invert(0.92) contrast(0.9); }
@media (min-width: 640px) { .zone-map iframe { height: 420px; } }
.zone-map__placeholder {
  height: 360px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 12px; padding: 32px; text-align: center;
}
@media (min-width: 640px) { .zone-map__placeholder { height: 420px; } }
.zone-map__placeholder svg { width: 32px; height: 32px; color: var(--primary); }
.zone-map__placeholder p { max-width: 280px; font-size: 14px; color: var(--muted); }
.zone-list-card { padding: 24px; }
@media (min-width: 640px) { .zone-list-card { padding: 32px; } }
.zone-list-card .zone-eyebrow { display: flex; align-items: center; gap: 8px; color: var(--primary); }
.zone-list-card .zone-eyebrow svg { width: 20px; height: 20px; }
.zone-list ul { margin-top: 20px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; font-size: 14px; color: var(--muted); }
.zone-list li { display: flex; align-items: center; gap: 8px; }
.zone-list li::before { content: ""; height: 6px; width: 6px; border-radius: 999px; background: var(--accent); flex-shrink: 0; }
.zone-note { margin-top: 24px; font-size: 14px; color: var(--muted); }

/* ==========================================================================
   Contact
   ========================================================================== */
.contact-grid { margin-top: 48px; display: grid; grid-template-columns: 1fr; gap: 32px; }
@media (min-width: 1024px) { .contact-grid { grid-template-columns: 1fr 1.3fr; } }
.contact-side { display: flex; flex-direction: column; gap: 24px; }
.urgent-card { padding: 24px; border-color: color-mix(in srgb, var(--accent) 30%, transparent); background: color-mix(in srgb, var(--accent) 6%, transparent); }
.urgent-card .urgent-title { display: flex; align-items: center; gap: 8px; color: var(--accent); font-family: var(--font-heading); font-size: 14px; font-weight: 600; }
.urgent-card .urgent-title svg { width: 20px; height: 20px; }
.urgent-card p { margin-top: 8px; font-size: 14px; color: var(--muted); }
.urgent-card .btn-row { margin-top: 16px; display: flex; flex-direction: column; gap: 12px; }
@media (min-width: 640px) { .urgent-card .btn-row { flex-direction: row; } }
.info-card { padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.info-row { display: flex; align-items: flex-start; gap: 12px; }
.info-row .icon-square { height: 32px; width: 32px; border-radius: 8px; flex-shrink: 0; }
.info-row .icon-square svg { width: 16px; height: 16px; }
.info-row .info-label { font-size: 12px; text-transform: uppercase; letter-spacing: 0.02em; color: var(--muted); }
.info-row .info-value { font-size: 14px; }
.info-row .info-value a:hover { color: var(--primary); }

.contact-form-card { padding: 24px; }
@media (min-width: 640px) { .contact-form-card { padding: 32px; } }
.form-notice { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding: 40px 20px; border-radius: 16px; border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent); background: color-mix(in srgb, var(--primary) 8%, transparent); }
.form-notice svg { width: 40px; height: 40px; color: var(--primary); }
.form-notice h3 { font-size: 20px; }
.form-notice p { max-width: 360px; font-size: 14px; color: var(--muted); }
.form-notice.form-notice--error { border-color: color-mix(in srgb, var(--danger) 30%, transparent); background: var(--danger-bg); }
.form-notice.form-notice--error svg { color: var(--danger); }

.contact-form { display: flex; flex-direction: column; gap: 20px; }
.form-row { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }
.form-field label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 500; }
.form-field input[type="text"],
.form-field input[type="tel"],
.form-field input[type="email"],
.form-field select,
.form-field textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--foreground) 3%, transparent);
  padding: 12px 16px;
  font-size: 14px;
  transition: border-color 0.2s ease;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  outline: none;
  border-color: color-mix(in srgb, var(--primary) 50%, transparent);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--primary) 25%, transparent);
}
.form-field.has-error input, .form-field.has-error select, .form-field.has-error textarea { border-color: color-mix(in srgb, var(--danger) 60%, transparent); }
.form-error { margin-top: 8px; font-size: 13px; color: var(--danger); }

.file-field label.file-drop {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px dashed var(--border); border-radius: 12px;
  padding: 16px; font-size: 14px; color: var(--muted); cursor: pointer;
  transition: all 0.2s ease;
}
.file-field label.file-drop:hover { border-color: color-mix(in srgb, var(--primary) 50%, transparent); color: var(--foreground); }
.file-field label.file-drop svg { width: 16px; height: 16px; }
.file-list { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; font-size: 12px; color: var(--muted); }
.file-list li { border: 1px solid var(--border); border-radius: 999px; padding: 4px 12px; background: color-mix(in srgb, var(--foreground) 5%, transparent); }

.consent-row { display: flex; align-items: flex-start; gap: 12px; font-size: 14px; color: var(--muted); }
.consent-row input { margin-top: 3px; accent-color: var(--primary); }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { position: relative; border-top: 1px solid var(--border); padding: 56px 0; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 40px; }
@media (min-width: 640px) { .footer-grid { grid-template-columns: repeat(3, 1fr); } }
.footer-col .footer-logo { display: flex; align-items: center; gap: 8px; }
.footer-col .footer-logo img { height: 40px; width: 40px; }
.footer-col .footer-logo span { font-family: var(--font-heading); font-size: 18px; font-weight: 700; }
.footer-col p.tagline { margin-top: 12px; max-width: 280px; font-size: 14px; color: var(--muted); }
.footer-col .mono { color: var(--primary); }
.footer-col ul { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.footer-col ul li a { font-size: 14px; color: var(--muted); }
.footer-col ul li a:hover { color: var(--primary); }
.footer-contact li { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.footer-contact li svg { width: 16px; height: 16px; flex-shrink: 0; }
.footer-contact li a:hover { color: var(--primary); }
.footer-bottom {
  margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 16px;
  font-size: 12px; color: var(--muted);
}
@media (min-width: 640px) { .footer-bottom { flex-direction: row; align-items: center; justify-content: space-between; } }
.footer-bottom-links { display: flex; flex-wrap: wrap; align-items: center; gap: 20px 16px; }
.footer-bottom-links a, .footer-bottom-links button { font-size: 12px; }
.footer-bottom-links a:hover, .footer-bottom-links button:hover { color: var(--primary); }

/* ==========================================================================
   Cookie banner
   ========================================================================== */
.cookie-banner {
  position: fixed; inset: auto 0 0 0; z-index: 400;
  padding: 16px;
  display: none;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}
@media (min-width: 640px) { .cookie-banner { padding: 24px; } }
.cookie-banner.is-visible { display: block; }
.cookie-banner.is-shown { transform: translateY(0); opacity: 1; }
.cookie-banner__inner {
  margin: 0 auto; max-width: 720px;
  border-radius: 16px; border: 1px solid color-mix(in srgb, var(--primary) 20%, transparent);
  background: color-mix(in srgb, var(--background-alt) 98%, transparent);
  backdrop-filter: blur(16px);
  box-shadow: 0 8px 40px rgba(28, 22, 16, 0.18);
  padding: 20px;
}
@media (min-width: 640px) { .cookie-banner__inner { padding: 24px; } }
.cookie-banner__head { display: flex; align-items: flex-start; gap: 12px; }
.cookie-banner__icon { flex-shrink: 0; margin-top: 2px; display: flex; align-items: center; justify-content: center; height: 36px; width: 36px; border-radius: 10px; background: color-mix(in srgb, var(--primary) 10%, transparent); color: var(--primary); }
.cookie-banner__icon svg { width: 16px; height: 16px; }
.cookie-banner h2 { font-size: 16px; }
.cookie-banner p { margin-top: 6px; font-size: 14px; line-height: 1.6; color: var(--muted); }
.cookie-banner p a { color: var(--primary); text-decoration: underline; text-underline-offset: 2px; }
.cookie-banner__actions { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
@media (min-width: 640px) { .cookie-banner__actions { flex-direction: row; } }
.cookie-banner__custom { display: none; margin-top: 16px; border-top: 1px solid var(--border); padding-top: 16px; flex-direction: column; gap: 12px; }
.cookie-banner__custom.is-open { display: flex; }
.cookie-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.cookie-row .cookie-row-title { font-size: 14px; font-weight: 500; }
.cookie-row .cookie-row-desc { font-size: 12px; color: var(--muted); }
.cookie-row .always-on { flex-shrink: 0; border-radius: 999px; border: 1px solid var(--border); padding: 4px 12px; font-size: 12px; color: var(--muted); }
.toggle { position: relative; height: 24px; width: 44px; border-radius: 999px; background: color-mix(in srgb, var(--foreground) 15%, transparent); flex-shrink: 0; transition: background 0.2s ease; }
.toggle.is-on { background: var(--primary); }
.toggle span { position: absolute; top: 2px; left: 2px; height: 20px; width: 20px; border-radius: 999px; background: #fff; transition: transform 0.2s ease; }
.toggle.is-on span { transform: translateX(20px); }
.link-btn { padding: 12px 16px; font-size: 14px; font-weight: 500; color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.link-btn:hover { color: var(--foreground); }

/* ==========================================================================
   Legal pages
   ========================================================================== */
.legal-page { padding: 128px 0 96px; max-width: 720px; margin: 0 auto; }
.legal-page .back-link { font-size: 14px; color: var(--primary); }
.legal-page .back-link:hover { text-decoration: underline; }
.legal-page h1 { margin-top: 24px; font-size: 30px; }
.legal-page .legal-intro { margin-top: 8px; font-size: 12px; color: var(--muted); }
.legal-page section { margin-top: 32px; font-size: 14px; line-height: 1.7; color: var(--muted); }
.legal-page section h2 { font-size: 17px; color: var(--foreground); margin-bottom: 8px; }
.legal-page section p { margin-top: 8px; }
.legal-page section a { color: var(--primary); text-decoration: underline; text-underline-offset: 2px; }
.legal-page section ul { margin-top: 12px; padding-left: 20px; list-style: disc; }
.legal-page section li { margin-top: 8px; }
.legal-page .todo-note { font-style: italic; }
