/* =========================================
   ECOVIES — Design Tokens & CSS Reset
   ========================================= */

/* -----------------------------------------
   :root — Tokens de diseño
   ----------------------------------------- */
:root {

    /* --- Brand --- */
    --primary-500:   #1C5046;
    --secondary-500: #1F9562;
    --accent-500:    #BBC932;

    /* --- Neutrals --- */
    --white: #FFFFFF;
    --black: #1E1E1E;

    --text-50:  #F0F1F2;
    --text-100: #D0D3D6;
    --text-200: #B9BDC2;
    --text-300: #989FA6;
    --text-400: #858D95;
    --text-500: #66707A;
    --text-600: #5D666F;
    --text-700: #485057;
    --text-800: #383E43;
    --text-900: #2B2F33;

    /* --- Semantic --- */
    --error-500:   #F33462;
    --success-500: #7CC921;
    --warning-500: #FCD904;
    --info-500:    #4C8DE9;

    /* --- Backgrounds --- */
    --bg-primary:   #BDD7D2;
    --bg-secondary: #CCEBDD;
    --bg-accent:    #EDFA69;
    --bg-neutral:   #D1E3E5;
    --bg-alert:     #E5D1D1;

    /* --- Routes --- */
    --route-vies-verdes:     #B6C932;
    --route-vies-tematiques: #1F9562;
    --route-vies-locals:     #B3A386;
    --route-pirinexus:       #6887C3;
    --route-consorci-generic: #1C5046;

    /* --- Typography --- */
    --font-family-heading: 'Darker Grotesque', sans-serif;
    --font-family-base:    Helvetica, 'Inter', Arial, sans-serif;
    --font-size-base:      16px;
    --line-height-base:    1.5;

    /* --- Font Scale --- */
    --fs-xs:   12px;   /* etiquetas, badges             */
    --fs-sm:   14px;   /* breadcrumbs, auxiliar          */
    --fs-md:   16px;   /* body base, footer texto        */
    --fs-lg:   20px;   /* texto descriptivo, c-card text */
    --fs-xl:   24px;   /* c-card__title, footer nav      */
    --fs-2xl:  32px;   /* subtítulo page-header          */
    --fs-3xl:  40px;   /* —                              */
    --fs-4xl:  56px;   /* c-heading-2                    */
    --fs-5xl:  72px;   /* page-header__title             */
    --fs-6xl:  96px;   /* info-practica-head__title      */

 
    --lh-xs:   16px;   /* para --fs-xs  (12px) — ratio 1.33 */
    --lh-sm:   20px;   /* para --fs-sm  (14px) — ratio 1.43 */
    --lh-md:   24px;   /* para --fs-md  (16px) — ratio 1.5  */
    --lh-lg:   28px;   /* para --fs-lg  (20px) — ratio 1.4  */
    --lh-xl:   32px;   /* para --fs-xl  (24px) — ratio 1.33 */
    --lh-2xl:  40px;   /* para --fs-2xl (32px) — ratio 1.25 */
    --lh-3xl:  48px;   /* para --fs-3xl (40px) — ratio 1.2  */
    --lh-4xl:  64px;   /* para --fs-4xl (56px) — display    */
    --lh-5xl:  72px;   /* para --fs-5xl (72px) — display    */
    --lh-6xl:  104px;  /* para --fs-6xl (96px) — hero       */

    /* --- Section Spacing --- */
    --section-sm:   48px;   /* secciones compactas           */
    --section-md:   64px;   /* secciones medianas            */
    --section-lg:   80px;   /* secciones estándar            */
    --section-xl:   96px;   /* secciones destacadas          */
    --section-2xl:  120px;  /* secciones hero / footer       */



    /* --- Shadows --- */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);

    /* --- Transitions --- */
    --transition-fast:   150ms ease-in-out;
    --transition-base:   250ms ease-in-out;
    --transition-slow:   400ms ease-in-out;

    /* --- Z-index --- */
    --z-dropdown: 1000;
    --z-sticky:   1020;
    --z-fixed:    1030;
    --z-modal:    1050;
    --z-tooltip:  1070;

    /* --- Container max-width (Bootstrap) --- */
    --container-max-width: 100vw;
}

/* Bootstrap container breakpoints */
@media (min-width: 576px)  { :root { --container-max-width: 540px;  } }
@media (min-width: 768px)  { :root { --container-max-width: 720px;  } }
@media (min-width: 992px)  { :root { --container-max-width: 960px;  } }
@media (min-width: 1200px) { :root { --container-max-width: 1140px; } }
@media (min-width: 1400px) { :root { --container-max-width: 1320px; } }


/* -----------------------------------------
   CSS Reset
   ----------------------------------------- */

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

html {
    font-size: var(--font-size-base);
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-family-base);
    font-size: var(--fs-md);
    line-height: var(--line-height-base);
    color: var(--text-800);
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

ul,
ol {
    list-style: none;
    font-family: var(--font-family-base);
}

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
}

input,
button,
textarea,
select {
    font: inherit;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
    overflow-wrap: break-word;
    
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-heading);
    font-weight: var(--font-weight-bold);
    margin: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    cursor: pointer;
    background: none;
    border: none;
}

table {
    border-collapse: collapse;
    border-spacing: 0;
}


/* -----------------------------------------
   Responsive tokens — breakpoints
   ----------------------------------------- */

/* Tablet — ≤ 991px */
@media (max-width: 991px) {
    :root {
        /* Font Scale — text */
        --fs-xl:   22px;   /* c-card__title — ligeramente reducido */
        --fs-2xl:  28px;   /* subtítulo page-header */
        --fs-3xl:  36px;   /* — */
        
        /* Font Scale — display */
        --fs-4xl:  40px;   /* c-heading-2 */
        --fs-5xl:  56px;   /* page-header__title */
        --fs-6xl:  72px;   /* info-practica-head__title */

        /* Line Heights — text */
        --lh-xl:   30px;   /* para --fs-xl  (22px) */
        --lh-2xl:  36px;   /* para --fs-2xl (28px) */
        --lh-3xl:  44px;   /* para --fs-3xl (36px) */
        
        /* Line Heights — display */
        --lh-4xl:  48px;   /* para --fs-4xl (40px) */
        --lh-5xl:  60px;   /* para --fs-5xl (56px) */
        --lh-6xl:  80px;   /* para --fs-6xl (72px) */

        /* Section Spacing */
        --section-sm:   24px;
        --section-md:   36px;
        --section-lg:   48px;
        --section-xl:   48px;
        --section-2xl:  64px;
    }
}

/* Mobile — ≤ 767px */
@media (max-width: 767px) {
    :root {
        /* Font Scale — text */
        --fs-xl:   20px;   /* c-card__title — más compacto */
        --fs-2xl:  24px;   /* subtítulo page-header */
        --fs-3xl:  28px;   /* — */
        
        /* Font Scale — display */
        --fs-4xl:  32px;   /* c-heading-2 */
        --fs-5xl:  40px;   /* page-header__title */
        --fs-6xl:  56px;   /* info-practica-head__title */

        /* Line Heights — text */
        --lh-xl:   28px;   /* para --fs-xl  (20px) */
        --lh-2xl:  32px;   /* para --fs-2xl (24px) */
        --lh-3xl:  36px;   /* para --fs-3xl (28px) */
        
        /* Line Heights — display */
        --lh-4xl:  40px;   /* para --fs-4xl (32px) */
        --lh-5xl:  48px;   /* para --fs-5xl (40px) */
        --lh-6xl:  64px;   /* para --fs-6xl (56px) */

        /* Section Spacing */
        --section-sm:   16px;
        --section-md:   24px;
        --section-lg:   32px;
        --section-xl:   32px;
        --section-2xl:  48px;
    }
}
