/*
Theme Name:     Blockbase Enfant
Theme URI:      https://wordpress.org/themes/blockbase/
Description:    Thème enfant personnalisé basé sur Blockbase
Author:         Pierre Lannes
Author URI:     https://www.pierre-lannes.fr/
Template:       blockbase
Version:        1.0.0
*/

/* POLICES LOCALES */

@font-face {
  font-family: 'Lora';
  src: url('./fonts/Lora-Regular.woff2') format('woff2'),
       url('./fonts/Lora-Regular.woff') format('woff');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Lora';
  src: url('./fonts/Lora-Bold.woff2') format('woff2'),
       url('./fonts/Lora-Bold.woff') format('woff');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Lora';
  src: url('./fonts/Lora-Italic.woff2') format('woff2'),
       url('./fonts/Lora-Italic.woff') format('woff');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'Lora';
  src: url('./fonts/Lora-BoldItalic.woff2') format('woff2'),
       url('./fonts/Lora-BoldItalic.woff') format('woff');
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'Lato';
  src: url('./fonts/Lato-Regular.woff2') format('woff2'),
       url('./fonts/Lato-Regular.woff') format('woff');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Lato';
  src: url('./fonts/Lato-Bold.woff2') format('woff2'),
       url('./fonts/Lato-Bold.woff') format('woff');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Lato';
  src: url('./fonts/Lato-Italic.woff2') format('woff2'),
       url('./fonts/Lato-Italic.woff') format('woff');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'Lato';
  src: url('./fonts/Lato-BoldItalic.woff2') format('woff2'),
       url('./fonts/Lato-BoldItalic.woff') format('woff');
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}

/* Déclaration des variables font-family */
:root {
  --theme-font-family: 'Lora', Georgia, serif;
  --theme-font-headings: 'Lato', 'Segoe UI', sans-serif;
}

body {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body,
p,
li {
  font-family: var(--theme-font-family);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--theme-font-headings);
  font-weight: 700;
}

.wp-block-navigation a,
.wp-block-navigation__link {
  font-family: var(--theme-font-headings) !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
}

.wp-block-navigation__container a:hover {
  color: #005b99;
  text-decoration: underline;
}

.wp-block-navigation__container .wp-block-navigation-item__content[aria-current="page"] {
  color: #007acc;
  font-weight: 900;
}

/* --- POLICES Responsives --- */

.site-title {
  font-size: clamp(1.3rem, 3vw, 2.2rem);
  font-weight: 700;
  line-height: 1.2;
}

html {
  font-size: 18px; /* Base scalable */
}

body,
p,
li {
  font-size: clamp(1rem, 1.5vw, 1.25rem); /* min: 16px, max: 20px */
  line-height: 1.7;
}

h1 {
  font-size: clamp(1.75rem, 3vw, 2.5rem); /* min: ~28px, max: 40px */
  font-weight: 700;
  line-height: 1.2;
}

h2 {
  font-size: clamp(1.4rem, 2.5vw, 2rem); /* min: ~22px, max: 32px */
  font-weight: 700;
  line-height: 1.3;
}

h3 {
  font-size: clamp(1.2rem, 2vw, 1.7rem); /* min: ~19px, max: 27px */
  font-weight: 700;
  line-height: 1.4;
}

@media (min-width: 1100px) {
  body, p, li {
    font-size: 1.15rem; /* ou tout simplement une valeur fixe plus modérée */
  }
}

button,
input[type="submit"],
.wpforms-submit {
  font-family: var(--theme-font-headings);
  font-size: clamp(1rem, 2vw, 1.3rem); /* ~16px à ~20.8px */
  font-weight: 900;
  text-transform: uppercase;
  padding: 0.8em 1.6em;
  border-radius: 6px;
}

/* --- Transitions plus douces entre états  --- */

:root {
  scroll-behavior: smooth;
}

button,
input[type="submit"],
.wpforms-submit {
  transition: all 0.2s ease-in-out;
}

/* --- FORMULAIRES WPForms --- */

.wpforms-form {
  font-family: 'Lato', "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  line-height: 1.6;
  color: #1e1e1e;
}

.wpforms-container-full {
  --wpforms-label-size-font-size: 1.6rem;
  --wpforms-label-size-line-height: 1.6;
  --wpforms-field-size-font-size: 1.3rem;
  --wpforms-field-size-line-height: 1.5;
}

.wpforms-container {
  max-width: 700px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (max-width: 600px) {
  .wpforms-field-row.wpforms-field-medium,
  .wpforms-field-row.wpforms-two-column,
  .wpforms-field.wpforms-half {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    display: block !important;
  }
}


/* Rendre le header sticky en haut */
.atester {
  position: sticky !important;
  top: 0;
  z-index: 9999;
  background-color: white; /* Ou une autre couleur adaptée */
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); /* Optionnel pour effet */
}