/* Blog de loukka.fr : charte de l'application (bleu nuit, accent turquoise, Segoe UI), lecture longue en thème clair,
   thème sombre si le navigateur le demande. Copié tel quel dans public/blog/ par scripts/blog.mjs. */
:root {
  --fond: #f6f8fb;
  --surface: #ffffff;
  --texte: #1a2233;
  --texte-doux: #5b6577;
  --bordure: #dde3ec;
  --accent: #0d7d74;
  --accent-vif: #34d3c4;
  --sur-accent: #06251c;
  --barre: #0a0f1b;
  --largeur: 46rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --fond: #0d1220;
    --surface: #131a2b;
    --texte: #e6ecf5;
    --texte-doux: #9aa6b8;
    --bordure: #24304a;
    --accent: #34d3c4;
  }
}

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

body {
  margin: 0;
  background: var(--fond);
  color: var(--texte);
  font-family:
    'Segoe UI',
    system-ui,
    -apple-system,
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 1.0625rem;
  line-height: 1.7;
}

a {
  color: var(--accent);
}

img {
  max-width: 100%;
  height: auto;
}

/* Barre du haut et pied de page */
.barre {
  background: var(--barre);
  border-bottom: 1px solid #1c2638;
}

.barre__dedans,
.pied__dedans {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.barre__logo {
  display: block;
  width: 7.5rem;
  line-height: 0;
}

.barre__logo svg {
  width: 100%;
  height: auto;
}

.logo-loukka__lettres {
  fill: #ffffff;
}

.logo-loukka__loupe {
  fill: var(--accent-vif);
}

.logo-loukka__reflet {
  fill: #ffffff;
}

.barre__liens {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  font-size: 0.95rem;
}

.barre__liens a:not(.bouton) {
  color: #e6ecf5;
  text-decoration: none;
}

.barre__liens a {
  white-space: nowrap;
}

/* Téléphone : liens plus serrés, sur deux lignes au besoin, sans couper « Se connecter » ni le bouton. */
@media (max-width: 30rem) {
  .barre__liens {
    flex-wrap: wrap;
    gap: 0.5rem 0.9rem;
    font-size: 0.9rem;
  }
}

.barre__liens a:not(.bouton):hover {
  color: var(--accent-vif);
}

.bouton {
  display: inline-block;
  background: var(--accent-vif);
  color: var(--sur-accent);
  font-weight: 600;
  text-decoration: none;
  border-radius: 999px;
  padding: 0.45rem 1.1rem;
}

.bouton:hover {
  background: #5ce0d3;
}

.bouton--grand {
  padding: 0.7rem 1.6rem;
  font-size: 1.05rem;
}

.pied {
  margin-top: 4rem;
  border-top: 1px solid var(--bordure);
  color: var(--texte-doux);
  font-size: 0.9rem;
}

.pied p {
  margin: 0;
}

.pied nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
}

/* Accueil du blog */
.accueil {
  max-width: 72rem;
  margin: 0 auto;
  padding: 2.5rem 1rem 0;
}

.accueil h1 {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  margin: 0 0 0.5rem;
}

.accueil__chapeau {
  color: var(--texte-doux);
  max-width: 40rem;
  margin: 0 0 2rem;
}

.cartes {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr));
  gap: 1.5rem;
}

.carte a {
  display: block;
  height: 100%;
  background: var(--surface);
  border: 1px solid var(--bordure);
  border-radius: 14px;
  overflow: hidden;
  color: inherit;
  text-decoration: none;
  transition:
    transform 0.15s,
    box-shadow 0.15s;
}

.carte a:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(10, 15, 27, 0.12);
}

.carte img {
  display: block;
  width: 100%;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
}

.carte__date {
  display: block;
  padding: 1rem 1.25rem 0;
  font-size: 0.85rem;
  color: var(--texte-doux);
}

.carte h2 {
  font-size: 1.25rem;
  line-height: 1.35;
  margin: 0.35rem 1.25rem 0.5rem;
}

.carte p {
  margin: 0 1.25rem 1.25rem;
  color: var(--texte-doux);
  font-size: 0.95rem;
}

/* Article */
.article {
  max-width: var(--largeur);
  margin: 0 auto;
  padding: 2rem 1rem 0;
}

.fil {
  font-size: 0.85rem;
  color: var(--texte-doux);
}

.article h1 {
  font-size: clamp(1.8rem, 4.5vw, 2.5rem);
  line-height: 1.2;
  margin: 0.75rem 0 0.5rem;
}

.article__infos {
  color: var(--texte-doux);
  font-size: 0.9rem;
  margin: 0 0 1.5rem;
}

.article__image {
  display: block;
  width: 100%;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  border-radius: 14px;
}

.article__texte h2 {
  font-size: 1.5rem;
  line-height: 1.3;
  margin: 2.5rem 0 0.75rem;
}

.article__texte h3 {
  font-size: 1.2rem;
  margin: 1.75rem 0 0.5rem;
}

.article__texte img {
  border-radius: 12px;
  margin: 0.5rem 0;
}

.article__texte blockquote {
  margin: 1.5rem 0;
  padding: 0.25rem 1.25rem;
  border-inline-start: 4px solid var(--accent-vif);
  background: var(--surface);
  border-start-start-radius: 0;
  border-end-start-radius: 0;
  border-start-end-radius: 10px;
  border-end-end-radius: 10px;
  font-style: italic;
}

.article__texte table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  margin: 1.5rem 0;
  display: block;
  overflow-x: auto;
}

.article__texte th,
.article__texte td {
  border: 1px solid var(--bordure);
  padding: 0.5rem 0.75rem;
  text-align: start;
  vertical-align: top;
}

.article__texte th {
  background: var(--surface);
}

/* Vidéo : vignette cliquable, YouTube chargé au clic */
.video {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  margin: 1.5rem 0 0;
  padding: 0;
  border: 0;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
  cursor: pointer;
}

.video img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.video__lecture {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 4.5rem;
  height: 4.5rem;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--accent-vif);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.4);
}

.video__lecture::after {
  content: '';
  position: absolute;
  inset: 50% auto auto 54%;
  transform: translate(-50%, -50%);
  border-style: solid;
  border-width: 0.8rem 0 0.8rem 1.3rem;
  border-color: transparent transparent transparent var(--sur-accent);
}

/* Encart d'appel à l'action et articles liés */
.encart {
  margin: 3rem 0 0;
  padding: 1.75rem;
  border-radius: 16px;
  background: linear-gradient(135deg, #0b1220, #0e2a33);
  color: #e6ecf5;
}

.encart__titre {
  font-size: 1.3rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.encart p {
  margin: 0 0 1.25rem;
  color: #c3cddb;
}

.lire-aussi {
  margin-top: 2.5rem;
}

.lire-aussi h2 {
  font-size: 1.2rem;
}

/* Renvoi d'un article vers sa page pilier */
.vers-pilier {
  margin: 3rem 0 0;
  padding: 1.25rem 1.5rem;
  border-inline-start: 4px solid var(--accent);
  background: var(--surface);
  border-start-start-radius: 0;
  border-end-start-radius: 0;
  border-start-end-radius: 12px;
  border-end-end-radius: 12px;
}

.vers-pilier__titre {
  margin: 0 0 0.25rem;
  font-weight: 700;
}

.vers-pilier p:last-child {
  margin: 0;
}

.vers-pilier a {
  color: var(--accent);
  font-weight: 600;
}

/* Pages piliers (/solutions/) */
.pilier__surtitre {
  margin: 1.5rem 0 0.25rem;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.pilier__accroche {
  font-size: 1.2rem;
  color: var(--texte-doux);
  margin: 0 0 1.25rem;
}

.pilier__articles {
  margin-top: 3rem;
}

.pilier__articles .cartes {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr));
  gap: 1rem;
}

.carte h3 {
  font-size: 1.05rem;
  line-height: 1.35;
  margin: 0.9rem 1.1rem 0.4rem;
}

.pilier__articles .carte p {
  margin: 0 1.1rem 1.1rem;
  font-size: 0.9rem;
}

/* Formulaire d'accès à la démo */
.demande {
  margin: 3rem 0 0;
  padding: 1.75rem;
  border-radius: 16px;
  background: linear-gradient(135deg, #0b1220, #0e2a33);
  color: #e6ecf5;
  scroll-margin-top: 1rem;
}

.demande h2 {
  margin: 0 0 0.5rem;
  font-size: 1.4rem;
}

.demande p {
  color: #c3cddb;
}

.formulaire-demo__champs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
  gap: 0.9rem;
  margin: 1.25rem 0;
}

.formulaire-demo label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.9rem;
  font-weight: 600;
}

.formulaire-demo input {
  font: inherit;
  font-weight: 400;
  padding: 0.6rem 0.75rem;
  border-radius: 10px;
  border: 1px solid #2c3a55;
  background: #0a0f1b;
  color: #e6ecf5;
}

.formulaire-demo input:focus {
  outline: 2px solid var(--accent-vif);
  outline-offset: 1px;
}

.formulaire-demo input[aria-invalid='true'] {
  border-color: #f87171;
}

.formulaire-demo button {
  border: 0;
  cursor: pointer;
  font-family: inherit;
}

.formulaire-demo button:disabled {
  opacity: 0.6;
  cursor: wait;
}

.formulaire-demo__message {
  min-height: 1.5em;
  margin: 0.75rem 0 0;
  color: #fecaca !important;
}

.formulaire-demo__note {
  margin: 0.5rem 0 0;
  font-size: 0.85rem;
}

.formulaire-demo__note a,
.formulaire-demo__merci {
  color: #e6ecf5;
}

/* Bandeau de consentement à la mesure d'audience */
.bandeau-cookies {
  position: fixed;
  inset-inline: 1rem;
  bottom: 1rem;
  z-index: 10;
  max-width: 44rem;
  margin: 0 auto;
  padding: 1rem 1.25rem;
  border-radius: 14px;
  background: var(--barre);
  color: #e6ecf5;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  font-size: 0.95rem;
}

.bandeau-cookies[hidden] {
  display: none;
}

.bandeau-cookies p {
  margin: 0 0 0.75rem;
}

.bandeau-cookies__boutons {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

.bandeau-cookies button {
  border: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
}

.bouton--discret {
  background: transparent;
  color: #e6ecf5;
  box-shadow: inset 0 0 0 1px #4b5a75;
}

.bouton--discret:hover {
  background: #1b2436;
}
