@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,700;12..96,800&family=Hanken+Grotesk:wght@400;500;600;700;800&family=Caveat:wght@600;700&display=swap');

:root {
    --bg: #fdf3e8;
    --surface: #ffffff;
    --ink: #2a1430;
    --ink-soft: #6b5b70;
    --red: #fb4b3a;
    --red-dark: #df3624;
    --teal: #0aa28f;
    --teal-dark: #08897a;
    --yellow: #ffc02b;
    --yellow-dark: #e2a200;
    --pink: #ff6aa2;
    --pink-dark: #ec4f8b;
    --line: #ecdfcd;
    --radius: 18px;
    --shadow: 0 10px 30px -12px rgba(42, 20, 48, 0.35);
    --shadow-sm: 0 6px 16px -8px rgba(42, 20, 48, 0.4);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
    font-family: 'Hanken Grotesk', sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.55;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}
/* atmosphère colorée diffuse (pas de dégradé violet cliché) */
body::after {
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background:
        radial-gradient(closest-side, rgba(10,162,143,0.20), transparent) -8% -6% / 520px 520px no-repeat,
        radial-gradient(closest-side, rgba(255,192,43,0.26), transparent) 112% 4% / 460px 460px no-repeat,
        radial-gradient(closest-side, rgba(255,106,162,0.18), transparent) 92% 104% / 520px 520px no-repeat;
}

a { color: inherit; text-decoration: none; }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 20px; position: relative; z-index: 2; }

/* ---------- Header ---------- */
.site-header {
    background: rgba(253, 243, 232, 0.88);
    backdrop-filter: blur(8px);
    position: sticky; top: 0; z-index: 50;
    border-bottom: 1px solid var(--line);
}
.site-header .wrap {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 20px; gap: 16px; flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 12px; }
.logo-mark {
    width: 68px; height: 68px; border-radius: 50%;
    border: 2.5px solid var(--yellow); object-fit: cover; background: var(--surface);
    transform: rotate(-4deg); transition: transform .2s ease;
    box-shadow: var(--shadow-sm);
}
.brand:hover .logo-mark { transform: rotate(5deg) scale(1.06); }
.brand-text {
    font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800;
    font-size: 1.3rem; line-height: 0.88; letter-spacing: -0.03em;
    display: flex; flex-direction: column;
}
.brand-text span { color: var(--red); }

.nav-cats { display: flex; gap: 8px; flex-wrap: wrap; }
.nav-cats a {
    font-weight: 700; font-size: 0.85rem; padding: 8px 14px;
    border-radius: 999px; background: var(--surface); color: var(--ink);
    box-shadow: var(--shadow-sm);
    transition: transform .14s ease, background .14s ease, color .14s ease;
}
.nav-cats a:hover { transform: translateY(-2px) rotate(-1deg); background: var(--teal); color: #fff; }
.nav-cats a.active { background: var(--red); color: #fff; }

/* ---------- Burger / menú móvil ---------- */
.nav-toggle { display: none; }

/* ---------- Bunting (papel picado) ---------- */
.bunting {
    height: 30px; position: relative; z-index: 2;
    background-repeat: repeat-x; background-size: 120px 30px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='30'%3E%3Cline x1='0' y1='3' x2='120' y2='3' stroke='%232a1430' stroke-width='2'/%3E%3Cpolygon points='2,3 32,3 17,26' fill='%23fb4b3a'/%3E%3Cpolygon points='32,3 62,3 47,26' fill='%23ffc02b'/%3E%3Cpolygon points='62,3 92,3 77,26' fill='%230aa28f'/%3E%3Cpolygon points='92,3 122,3 107,26' fill='%23ff6aa2'/%3E%3C/svg%3E");
}

/* ---------- Hero ---------- */
.hero { text-align: center; padding: 30px 20px 30px; position: relative; }
.hero-logo {
    width: min(270px, 68vw); height: auto; display: block; margin: 0 auto 4px;
    animation: pop .6s cubic-bezier(.34,1.56,.64,1) both;
}
.hero h1 {
    font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800;
    font-size: clamp(2rem, 6vw, 3.6rem); line-height: 0.98;
    letter-spacing: -0.03em;
}
.hero h1 em { color: var(--red); font-style: normal; position: relative; white-space: nowrap; }
.hero h1 em::after {
    content: ""; position: absolute; left: -2%; right: -2%; bottom: 2px; height: 38%;
    background: var(--yellow); opacity: .55; z-index: -1; border-radius: 4px; transform: rotate(-1deg);
}
.hero .tagline {
    font-family: 'Caveat', cursive; font-size: 1.8rem; color: var(--teal-dark);
    margin-top: 8px; transform: rotate(-1.5deg);
}
.hero p.sub { margin-top: 10px; font-size: 1.05rem; color: var(--ink-soft); max-width: 540px; margin-inline: auto; }
@keyframes pop { from { opacity: 0; transform: scale(.85) rotate(-3deg); } to { opacity: 1; transform: scale(1) rotate(0); } }

/* ---------- Sections ---------- */
.section-title {
    font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800;
    font-size: 1.5rem; letter-spacing: -0.02em; margin: 30px 0 20px;
    display: flex; align-items: center; gap: 14px;
}
.section-title::before { content: "✦"; color: var(--pink); }
.section-title::after { content: ""; flex: 1; height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--teal), transparent); }

.grid {
    display: grid; gap: 24px;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    padding-bottom: 64px;
}

/* ---------- Cards (couleur tournante par carte) ---------- */
.card {
    --c: var(--red); --c-dark: var(--red-dark);
    background: var(--surface); border-radius: var(--radius); overflow: hidden;
    display: flex; flex-direction: column; box-shadow: var(--shadow);
    transition: transform .16s ease, box-shadow .16s ease;
    animation: rise .5s ease both;
}
.card:nth-child(4n+1) { --c: var(--red);    --c-dark: var(--red-dark);    --tint: #fde7e4; }
.card:nth-child(4n+2) { --c: var(--teal);   --c-dark: var(--teal-dark);   --tint: #d8f2ee; }
.card:nth-child(4n+3) { --c: var(--yellow); --c-dark: var(--yellow-dark); --tint: #fff3d3; }
.card:nth-child(4n+4) { --c: var(--pink);   --c-dark: var(--pink-dark);   --tint: #ffe3ee; }
.card:hover { transform: translateY(-6px) rotate(-.5deg); box-shadow: 0 18px 40px -14px rgba(42,20,48,.45); }
.card:nth-child(1){animation-delay:.04s}.card:nth-child(2){animation-delay:.10s}
.card:nth-child(3){animation-delay:.16s}.card:nth-child(4){animation-delay:.22s}
.card:nth-child(5){animation-delay:.28s}.card:nth-child(6){animation-delay:.34s}
.card:nth-child(7){animation-delay:.40s}.card:nth-child(8){animation-delay:.46s}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }

.card-media { position: relative; aspect-ratio: 16/10; background: var(--tint, #f3eadd); overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-media .placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 3.2rem; }
.badge-dcto {
    position: absolute; bottom: -14px; left: 16px;
    background: var(--c); color: #fff;
    font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: 1.05rem;
    padding: 8px 15px; border-radius: 12px; box-shadow: var(--shadow-sm);
}
.card:nth-child(4n+3) .badge-dcto { color: var(--ink); }
.badge-destacada {
    position: absolute; top: 12px; right: 12px;
    background: #fff; color: var(--ink); font-weight: 800; font-size: 0.7rem;
    text-transform: uppercase; padding: 6px 11px; border-radius: 999px; box-shadow: var(--shadow-sm);
}
.badge-destacada::before { content: "★ "; color: var(--yellow-dark); }

.card-body { padding: 22px 18px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-tienda { font-weight: 800; text-transform: uppercase; font-size: 0.72rem; letter-spacing: 0.07em; color: var(--c-dark); }
.card h3 { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 700; font-size: 1.2rem; line-height: 1.2; letter-spacing: -0.01em; }
.card p { font-size: 0.92rem; color: var(--ink-soft); }
.card-meta { display: flex; gap: 10px; flex-wrap: wrap; font-size: 0.78rem; color: var(--ink-soft); margin-top: auto; align-items: center; padding-top: 4px; }
.cupon { font-weight: 800; background: var(--tint, #f3eadd); color: var(--c-dark); padding: 4px 10px; border-radius: 8px; letter-spacing: 0.02em; }

.btn {
    display: inline-block; text-align: center; cursor: pointer;
    font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800;
    background: var(--red); color: #fff; border: none;
    padding: 12px 18px; border-radius: 12px; font-size: 0.98rem;
    box-shadow: var(--shadow-sm);
    transition: transform .12s ease, background .14s ease;
}
.btn:hover { background: var(--red-dark); transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-block { width: 100%; margin-top: 8px; }
.btn-outline { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 2px var(--ink); }
.btn-outline:hover { background: var(--ink); color: #fff; }

.video-link { font-size: 0.84rem; font-weight: 800; color: var(--c-dark); }
.video-link:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--ink); color: #fbeede; padding: 40px 20px; text-align: center;
    position: relative; z-index: 2; margin-top: 10px;
    border-top: 6px solid var(--yellow);
}
.footer-face { width: 70px; height: 70px; border-radius: 50%; border: 4px solid var(--pink); object-fit: cover; transform: rotate(-4deg); margin-bottom: 12px; }
.site-footer .ft-name { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: 1.5rem; }
.site-footer a { color: var(--yellow); font-weight: 800; }
.site-footer .hand { font-family: 'Caveat', cursive; font-size: 1.35rem; color: var(--teal); margin-top: 4px; }
.site-footer .ft-social { margin-top: 12px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.site-footer .ft-social a {
    display: inline-flex; align-items: center; gap: 6px;
    background: rgba(255,255,255,0.08); color: #fbeede;
    padding: 8px 16px; border-radius: 999px; font-size: 0.92rem;
    transition: background .14s ease, transform .14s ease, color .14s ease;
}
.site-footer .ft-social a:hover { background: var(--pink); color: #fff; transform: translateY(-2px); }

/* ---------- Admin ---------- */
.admin-bar { background: var(--ink); color: #fbeede; padding: 14px 0; position: relative; z-index: 2; }
.admin-bar .wrap { display: flex; justify-content: space-between; align-items: center; }
.admin-bar a { color: var(--yellow); font-weight: 800; }
.panel { background: var(--surface); border-radius: var(--radius); padding: 24px; margin: 24px 0; box-shadow: var(--shadow); }
.stat { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: 2.4rem; color: var(--red); }
table.tbl { width: 100%; border-collapse: collapse; }
table.tbl th, table.tbl td { text-align: left; padding: 11px; border-bottom: 1px solid var(--line); font-size: 0.9rem; }
table.tbl th { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; text-transform: uppercase; font-size: 0.72rem; }
.form-field { margin-bottom: 16px; display: flex; flex-direction: column; gap: 6px; }
.form-field label { font-weight: 800; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.03em; color: var(--ink-soft); }
.form-field input, .form-field textarea, .form-field select {
    font-family: inherit; font-size: 1rem; padding: 11px 13px;
    border: 2px solid var(--line); border-radius: 10px; background: var(--bg); width: 100%;
    transition: border-color .15s ease;
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus { outline: none; border-color: var(--teal); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.checkbox-row { display: flex; align-items: center; gap: 8px; }
.checkbox-row input { width: auto; }
.login-box { max-width: 380px; margin: 80px auto; }
.login-face { width: 84px; height: 84px; border-radius: 50%; border: 4px solid var(--yellow); object-fit: cover; display: block; margin: 0 auto 16px; transform: rotate(-4deg); }
.alert { background: #fde7e4; color: var(--red-dark); padding: 11px 15px; border-radius: 10px; margin-bottom: 16px; font-weight: 700; }

@media (max-width: 760px) {
    .site-header .wrap { flex-wrap: wrap; }
    .nav-toggle {
        display: flex; flex-direction: column; justify-content: center; gap: 5px;
        width: 46px; height: 46px; padding: 0 11px; flex: 0 0 auto; margin-left: auto;
        background: var(--surface); border: none; border-radius: 12px;
        box-shadow: var(--shadow-sm); cursor: pointer;
    }
    .nav-toggle span {
        display: block; width: 100%; height: 3px; border-radius: 3px;
        background: var(--ink); transition: transform .25s ease, opacity .2s ease;
    }
    .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
    .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

    .nav-cats {
        flex-basis: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        max-height: 0; overflow: hidden; opacity: 0; margin-top: 0;
        transition: max-height .3s ease, opacity .25s ease, margin-top .3s ease;
    }
    .nav-cats.open { max-height: 75vh; overflow-y: auto; opacity: 1; margin-top: 8px; }
    .nav-cats a { text-align: center; font-size: 0.95rem; padding: 12px 16px; }
}

@media (max-width: 560px) {
    .form-row { grid-template-columns: 1fr; }
    .brand-text { font-size: 1.15rem; }
}
@media (prefers-reduced-motion: reduce) {
    .card, .hero-logo { animation: none; }
}
