/* base.css — variables, reset, typographie, header/nav. */

:root {
    --bg: #fff;
    --text: #000;
    --muted: #777;
    --accent: #222;
    --border: #eee;
    /* Hauteur commune à tous les contrôles d'achat en ligne (stepper, "Add
       to cart", bouton supprimer) — sinon chacun suit son propre
       padding/font, jamais exactement identique d'un élément à l'autre. */
    --control-h: 44px;
    /* Longueur des barres des icônes +/- dessinées en CSS (.qty-btn). */
    --icon-size: 12px;
    /* Action destructive (supprimer une ligne du panier) : seule touche de
       couleur du site, réservée à ce type d'action pour rester lisible
       comme un signal d'alerte plutôt qu'un choix décoratif. */
    --danger: #e3181d;
    --danger-hover: #b11d1f;
    /* Gris partagé par tous les boutons non cliquables (stepper au
       plancher/plafond, liens désactivés). */
    --disabled-bg: #bbb;
    /* Gris "secondaire" : boîtes d'UI discrètes qui ne sont pas l'action
       principale (.secondary-action, .size-btn non sélectionné, fond actif
       du sélecteur de quantité) — distinct de --placeholder-bg (état de
       chargement, sémantique différente). */
    --secondary-bg: #f0f0f0;
    --secondary-bg-hover: #e4e4e4;
    /* Fond gris clair pendant le chargement d'une image (grilles, carousel,
       panier, produits associés...). */
    --placeholder-bg: #f8f8f8;
}

/* Reset / base ------------------------------------------------------------ */
* {
    box-sizing: border-box
}

html,
body {
    height: 100%;
    margin: 0;
    font-family: "greycliff-cf", sans-serif
}

body {
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    display: flex;
    flex-direction: column;
    min-height: 100vh
}

/* Typography -------------------------------------------------------------- */
h1 {
    font-family: "dazzle-unicase", sans-serif;
    font-weight: 500;
    color: var(--accent);
    font-size: 24px;
    margin: 0
}

.logo,
.home-logo {
    font-family: "dazzle-unicase", sans-serif;
    font-weight: 700;
    text-decoration: none;
    color: var(--text);
    letter-spacing: .413em
}

.logo {
    font-size: 16px
}

.home-logo {
    font-size: 6vw;
}

/* Layout helpers --------------------------------------------------------- */
.container {
    margin: 0 auto;
    padding: 0 16px;
    width: 100%
}

.sr-only {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0
}

/* Main app mount point -----------------------------------------------------
   Routes normales : padding standard. Home (body.home) gère son propre
   plein-cadre, voir home.css. */
#app {
    flex: 1;
    width: 100%;
    margin: 0 auto;
    padding: 88px 16px 64px;
}

body.home #app {
    padding: 0;
    margin: 0;
}

/* Header / Nav ----------------------------------------------------------- */
.site-header {
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    background: var(--bg);
    z-index: 50
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px
}

.main-nav {
    display: flex;
    align-items: center
}

.main-nav a {
    margin-left: 18px;
    text-decoration: none;
    color: var(--muted);
    font-family: "dazzle-unicase", sans-serif;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    padding-bottom: 4px;
    border-bottom: 2px solid transparent;
    transition: border-color .15s ease, color .15s ease;
}

.main-nav a:hover {
    color: var(--accent);
}

.main-nav a.active {
    color: var(--text);
    border-bottom-color: var(--accent);
}

.nav-toggle {
    display: none;
    background: transparent;
    border: 0;
    font-size: 22px;
    cursor: pointer;
    color: var(--accent)
}

/* Nav open state (mobile) */
.main-nav.open {
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: absolute;
    left: 0;
    right: 0;
    top: 64px;
    background: #fff;
    padding: 12px;
    z-index: 60
}
