/*
Theme Name: OptimIA
Theme URI: https://optimia.fr
Author: OptimIA
Description: Theme de blocs sur mesure pour OptimIA, createur d'automatisations de flux de travail a Perpignan.
Version: 1.0.0
Requires at least: 6.5
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: optimia
*/

/* ---- Bascule clair / sombre : on echange les variables de palette ---- */
html.mode-clair {
  --wp--preset--color--encre: #f3f5fd;
  --wp--preset--color--nuit: #ffffff;
  --wp--preset--color--blanc: #0b1124;
  --wp--preset--color--brume: #47527a;
  --wp--preset--color--violet: #4f2fe0;
  --wp--preset--color--cyan: #0a6a80;
}
html.mode-clair body { background-color: #f3f5fd; }
html.mode-clair .carte-verre,
html.mode-clair .bloc-verre,
html.mode-clair .wp-block-details {
  background: rgba(11, 17, 36, 0.04);
  border-color: rgba(11, 17, 36, 0.12);
}
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { overflow-x: hidden; }

/* ---- Cartes en verre ---- */
.carte-verre {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  backdrop-filter: blur(10px);
  height: 100%;
}
.bloc-verre {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  backdrop-filter: blur(10px);
}
.carte-forte {
  background: linear-gradient(150deg, rgba(108, 75, 246, 0.38), rgba(34, 211, 238, 0.16));
  border: 1px solid rgba(34, 211, 238, 0.45);
  border-radius: 24px;
  height: 100%;
}
.titre-degrade {
  background: linear-gradient(100deg, var(--wp--preset--color--blanc) 15%, var(--wp--preset--color--cyan) 62%, var(--wp--preset--color--violet) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.sur-titre {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 600;
}
.wp-block-image img { border-radius: 18px; }
.wp-block-details {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 1.1rem 1.4rem;
  background: rgba(255, 255, 255, 0.04);
}
.wp-block-details summary { cursor: pointer; font-weight: 600; }
.wp-block-button__link { transition: transform .2s ease, box-shadow .2s ease; }
.wp-block-button__link:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(108, 75, 246, .35); }
.wp-block-table td, .wp-block-table th { border-color: rgba(255, 255, 255, .16); }
.wp-block-table figcaption { color: var(--wp--preset--color--brume); }

/* ---- Bandeau cookies ---- */
#cookie_banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 9000;
  max-width: 720px;
  margin: 0 auto;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .45);
}
#cookie_banner[hidden] { display: none !important; }
