/* ==========================================================================
   MathRelaxing — tema de marca (basado en brand.py + logo)
   Se carga DESPUÉS de styles.css. Fuente de verdad visual:
     · logo: infinito acuarela lavanda → periwinkle → aqua
     · navy #12172d · negro (banda de pie) · dorado #c9a24b · crema #f8f4eb
     · acento verde azulado #7fb0aa · títulos en serif
   ========================================================================== */

:root {
    /* nombres heredados de styles.css, remapeados a la marca */
    --green-900: #0b0e1d;      /* negro-navy profundo (banda) */
    --green-800: #12172d;      /* IPAD_NAVY */
    --green-700: #232a52;
    --green-200: #b9bde0;
    --green-100: #e7e8f4;

    --red-700: #9b2c3f;
    --red-600: #b8384c;
    --orange-600: #b0883a;
    --orange-500: #c9a24b;

    --gold-600: #a8832f;       /* dorado oscuro: texto sobre crema */
    --gold-500: #c9a24b;       /* GOLD de la marca */
    --gold-300: #e3cc92;

    --cream-50: #fdfbf6;
    --cream-100: #f8f4eb;      /* CREAM de la marca */
    --cream-200: #f0eadb;
    --cream-300: #e2d9c2;

    --lav: #cfb6ec;            /* extremos del degradado del infinito */
    --peri: #9ea6e2;
    --aqua: #8fe3e2;
    --teal: #7fb0aa;           /* IPAD_TEAL */

    --bg: var(--cream-100);
    --bg-raised: #ffffff;
    --bg-sunken: var(--cream-200);
    --ink: #151a2e;
    --ink-muted: #5a5f74;
    --ink-inverse: #f8f4eb;
    --brand: var(--green-800);
    --brand-strong: var(--green-900);
    --accent: var(--gold-500);
    --line: rgba(18, 23, 45, 0.12);
    --line-strong: rgba(18, 23, 45, 0.24);

    --font-display: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
    --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
    --font-label: "Montserrat", "Inter", system-ui, sans-serif;   /* como el wordmark */

    --r-sm: 6px;
    --r-md: 12px;
    --r-lg: 18px;

    --shadow-sm: 0 1px 2px rgba(18, 23, 45, 0.06), 0 2px 8px rgba(18, 23, 45, 0.05);
    --shadow-md: 0 4px 14px rgba(18, 23, 45, 0.08), 0 14px 36px rgba(18, 23, 45, 0.09);
    --shadow-lg: 0 10px 30px rgba(18, 23, 45, 0.14), 0 30px 70px rgba(18, 23, 45, 0.16);

    --grad-brand: linear-gradient(100deg, var(--lav) 0%, var(--peri) 50%, var(--aqua) 100%);
}

/* ---- Base ---------------------------------------------------------------- */
body {
    font-family: var(--font-body);
    color: var(--ink);
    background: var(--bg);
}

h1, h2, h3, h4, .product__body h3, .pdp__price {
    font-family: var(--font-display);
    font-weight: 600;
    letter-spacing: -0.005em;
}
h1 { line-height: 1.05; }
h2 { line-height: 1.1; }

::selection { background: var(--lav); color: var(--green-800); }
a { text-underline-offset: 3px; }

/* etiquetas: Montserrat fina, mayúsculas, dorado (eco del wordmark) */
.eyebrow, .product__cat, .pdp__crumb, .brand__tagline {
    font-family: var(--font-label);
    font-weight: 500;
    font-size: 0.68rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold-600);
}

/* ---- Cabecera ------------------------------------------------------------ */
.announcement, .announcement--festive {
    background: var(--green-900);
    color: var(--ink-inverse);
}
.announcement strong { color: var(--gold-300); }

.header {
    background: color-mix(in srgb, var(--green-800) 94%, transparent);
    backdrop-filter: blur(14px) saturate(140%);
    border-bottom: 1px solid rgba(201, 162, 75, 0.22);
}
.header.is-stuck { box-shadow: 0 6px 24px rgba(11, 14, 29, 0.4); }

.brand { gap: 0.6rem; }
.brand__emblem {
    width: 64px; height: 34px; aspect-ratio: auto;
    border: 0; border-radius: 0; background-color: transparent;
    background-image: url("/assets/logo-mark.svg");
    background-size: contain; background-position: center; background-repeat: no-repeat;
    box-shadow: none;
    filter: drop-shadow(0 0 10px rgba(158, 166, 226, 0.35));
}
.brand:hover .brand__emblem { transform: scale(1.05); }

.brand__name {
    font-family: var(--font-label);
    font-weight: 300;
    font-size: 1.15rem;
    letter-spacing: 0.04em;
    color: var(--cream-100);
}
.header .brand__tagline, .footer .brand__tagline { color: var(--gold-500); font-size: 0.58rem; margin-top: 3px; }

.header .nav__link, .header .nav a {
    font-family: var(--font-label);
    font-weight: 400; font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase;
    color: rgba(248, 244, 235, 0.8);
}
.header .nav__link:hover, .header .nav a:hover { color: var(--gold-300); }
.header .icon-btn, .header #cartBtn, .header .mobile-menu { color: var(--cream-100); }
.cart-count { background: var(--gold-500); color: var(--green-800); font-weight: 700; }

/* ---- Botones: dorado de la marca ----------------------------------------- */
.btn, .button, .add-to-cart {
    font-family: var(--font-label);
    font-weight: 600; font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase;
    border-radius: var(--r-pill);
    background: var(--green-800);
    color: var(--cream-100);
    border: 1px solid var(--green-800);
    transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease), color 0.2s var(--ease);
}
.btn:hover, .button:hover, .add-to-cart:hover {
    background: var(--gold-500);
    border-color: var(--gold-500);
    color: var(--green-800);
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(201, 162, 75, 0.32);
}
.btn--ghost { background: transparent; color: var(--green-800); border-color: var(--line-strong); }
.btn--ghost:hover { background: var(--cream-200); color: var(--green-800); box-shadow: none; border-color: var(--gold-500); }

/* ---- Tarjetas ------------------------------------------------------------ */
.product {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s var(--ease);
}
.product:hover, .product:focus-within { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--gold-500); }
.product__media { background: var(--cream-200); }
.product__price strong { font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; }
.badge--gold { background: var(--green-800); color: var(--gold-300); }

.catalog-filter a, .catalog-filter button { border-radius: var(--r-pill); font-family: var(--font-label); font-size: 0.72rem; letter-spacing: 0.08em; }

/* ---- Pie: banda negra con el logo ---------------------------------------- */
.footer {
    background: #000;
    color: rgba(248, 244, 235, 0.74);
    border-top: 1px solid rgba(201, 162, 75, 0.35);
}
.footer h3 { color: var(--gold-500); font-family: var(--font-label); font-size: 0.7rem; letter-spacing: 0.2em; text-transform: uppercase; }
.footer a { color: rgba(248, 244, 235, 0.78); }
.footer a:hover { color: var(--gold-300); }
.footer .brand__name { color: var(--cream-100); }
.footer__quote { font-family: var(--font-display); font-style: italic; font-size: 1.15rem; color: var(--gold-300); }
.footer__legal { color: rgba(248, 244, 235, 0.5); }

/* ---- Formularios / foco -------------------------------------------------- */
input, select, textarea { border-radius: var(--r-md); }
input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible, button:focus-visible {
    outline: 2px solid var(--gold-500); outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* Selector de idioma sobre la cabecera navy */
.header .lang-switch, .header .lang-switch a, .header .lang-switch button { color: rgba(248, 244, 235, 0.75); }
.header .lang-switch a:hover, .header .lang-switch button:hover { color: var(--gold-300); }
