/* ============================================================
   Judit Camps · Dietètica i Nutrició
   Paleta oficial de marca: taupe #857774 + verd menta #7cccaf.
   Tipografia de marca: geomètrica arrodonida (Quicksand).
   ============================================================ */

/* Fonts servides des del propi domini (sense transferir la IP a Google) */
@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 300 600;
    font-display: swap;
    src: url("../assets/fonts/inter-latin.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
        U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
        U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 300 600;
    font-display: swap;
    src: url("../assets/fonts/inter-latin-ext.woff2") format("woff2");
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
        U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
        U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: "Quicksand";
    font-style: normal;
    font-weight: 400 600;
    font-display: swap;
    src: url("../assets/fonts/quicksand-latin.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
        U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
        U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: "Quicksand";
    font-style: normal;
    font-weight: 400 600;
    font-display: swap;
    src: url("../assets/fonts/quicksand-latin-ext.woff2") format("woff2");
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
        U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
        U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
    --green-900: #5a4f4c;   /* taupe fosc (titulars) */
    --green-700: #857774;   /* taupe de marca (text secundari, enllaços) */
    --green-500: #4aa98c;   /* menta fosc (accents amb bon contrast) */
    --green-300: #7cccaf;   /* menta de marca (decoració) */
    --cream: #fbfaf8;
    --sand: #f3efec;
    --ink: #4a4341;
    --muted: #8a7f7c;
    --radius: 14px;
    --shadow: 0 10px 40px rgba(90, 79, 76, 0.08);
    --font-display: "Quicksand", "Trebuchet MS", sans-serif;
    --font-body: "Inter", Helvetica, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    font-weight: 300;
    font-size: 17px;
    line-height: 1.7;
    color: var(--ink);
    background: var(--cream);
    -webkit-font-smoothing: antialiased;
}

.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 500; color: var(--green-900); }
h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); line-height: 1.1; }
h1 em { font-style: normal; color: var(--green-500); }
h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); margin-bottom: 1rem; }
h3 { font-size: 1.35rem; margin-bottom: 0.5rem; }
p { margin-bottom: 1rem; }
a { color: var(--green-700); }

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.25em;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--green-500);
    margin-bottom: 0.75rem;
}

/* ---------- Header ---------- */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(251, 250, 248, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(124, 204, 175, 0.12);
}
.nav { display: flex; align-items: center; justify-content: space-between; padding: 14px 24px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { display: block; height: 52px; width: auto; }
/* logo-es.png és més alt pel descendent de la "y": mateixa escala que logo.png */
.brand img.logo-es { height: 55px; margin-bottom: -3px; }
.brand .brand-leaf { height: 42px; opacity: 0.9; transform: rotate(-8deg); }
.nav-links { display: flex; gap: 28px; list-style: none; align-items: center; }
.nav-links a { text-decoration: none; font-size: 0.95rem; font-weight: 400; }
.nav-links a:hover { color: var(--green-500); }
.lang-switch a { font-size: 0.8rem; font-weight: 500; letter-spacing: 0.08em; opacity: 0.7; }
.lang-switch a:hover { opacity: 1; }
.nav-toggle { display: none; background: none; border: none; font-size: 1.6rem; color: var(--green-900); cursor: pointer; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-block;
    background: var(--green-700);
    color: #fff !important;
    padding: 14px 32px;
    border: none;
    border-radius: 999px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.25s ease, transform 0.25s ease;
}
.btn:hover { background: var(--green-500); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--green-700) !important; border: 1.5px solid var(--green-500); }
.btn-ghost:hover { background: var(--green-300); }
.btn-small { padding: 9px 22px; }

/* ---------- Hero ---------- */
.hero {
    padding: 110px 0 130px;
    background:
        radial-gradient(ellipse 70% 60% at 85% 10%, rgba(124, 204, 175, 0.25), transparent),
        radial-gradient(ellipse 50% 50% at 10% 90%, rgba(243, 239, 236, 0.9), transparent),
        var(--cream);
    text-align: center;
}
.hero .lead { max-width: 620px; margin: 1.6rem auto 2.4rem; font-size: 1.15rem; color: var(--muted); }
.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section-alt { background: var(--sand); }

.grid-2 { display: grid; grid-template-columns: 1.2fr 1fr; gap: 56px; align-items: start; }

.card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 32px;
}
.card ul { list-style: none; margin-bottom: 1.2rem; }
.card ul li { padding: 5px 0 5px 26px; position: relative; }
.card ul li::before {
    content: "";
    position: absolute; left: 0; top: 13px;
    width: 12px; height: 12px;
    background: var(--green-300);
    border-radius: 50% 0 50% 50%;
}

.credentials h3 { margin-top: 1rem; }
.credentials h3:first-child { margin-top: 0; }

/* ---------- Serveis ---------- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 24px;
    margin-top: 2rem;
}
.specialty-tag {
    display: inline-block;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--green-500);
    border: 1px solid var(--green-300);
    border-radius: 999px;
    padding: 2px 12px;
    margin-bottom: 0.8rem;
}

/* ---------- Mètode ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 28px; margin-top: 2rem; }
.step span {
    font-family: var(--font-display);
    font-size: 2.4rem;
    color: var(--green-300);
    display: block;
    line-height: 1;
    margin-bottom: 0.4rem;
}

/* ---------- Formulari ---------- */
.contact-form label { display: block; font-size: 0.85rem; font-weight: 500; margin: 14px 0 4px; }
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #dcd6d2;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    background: var(--cream);
    transition: border-color 0.2s;
}
.contact-form input:focus, .contact-form textarea:focus {
    outline: none; border-color: var(--green-500);
}
.contact-form .btn { margin-top: 18px; width: 100%; }
.consent { font-size: 0.82rem !important; font-weight: 300 !important; display: flex; gap: 8px; align-items: flex-start; margin-top: 16px !important; }
.consent input { margin-top: 4px; }
.field-hint { font-size: 0.75rem; color: var(--muted); margin-top: 4px; line-height: 1.5; }
.legal-note { font-size: 0.72rem; color: var(--muted); margin-top: 14px; line-height: 1.5; }
.legal-note a { color: var(--green-700); }

/* ---------- Pàgines legals ---------- */
.legal-page h2 { font-size: 1.25rem; margin: 2rem 0 0.6rem; }
.legal-page ul { margin: 0 0 1rem 1.2rem; }
.legal-page li { margin-bottom: 0.4rem; }
.legal-page .updated { font-size: 0.85rem; color: var(--muted); }
.pending { background: #fff3cd; color: var(--green-900); padding: 0 4px; border-radius: 4px; }
.form-status { font-size: 0.9rem; margin-top: 10px; font-weight: 500; }
.form-status.ok { color: var(--green-500); }
.form-status.error { color: #b3473e; }
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; }
.cf-turnstile { margin-top: 16px; }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--green-900);
    color: #e8e6dd;
    padding: 48px 0;
    text-align: center;
    font-size: 0.85rem;
}
.footer-inner img { filter: brightness(0) invert(0.95); margin-bottom: 16px; }
.site-footer a { color: var(--green-300); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer p { margin: 10px 0 0; }
.cookie-settings-link {
    border: 0;
    padding: 0;
    background: none;
    color: var(--green-300);
    font: inherit;
    text-decoration: underline;
    cursor: pointer;
}
.cookie-consent {
    position: fixed;
    z-index: 1000;
    right: 20px;
    bottom: 20px;
    display: flex;
    align-items: center;
    gap: 24px;
    width: min(760px, calc(100vw - 40px));
    padding: 22px 24px;
    border: 1px solid rgba(90, 79, 76, 0.18);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 12px 44px rgba(38, 31, 29, 0.2);
    color: var(--ink);
    font-size: 0.9rem;
    line-height: 1.5;
}
.cookie-consent[hidden] { display: none; }
.cookie-consent-copy { flex: 1; }
.cookie-consent h2 { margin: 0 0 5px; font: 600 1.1rem var(--font-display); color: var(--green-900); }
.cookie-consent p { margin: 0 0 5px; }
.cookie-consent-info { color: var(--green-700); }
.cookie-consent-actions { display: flex; flex-direction: column; gap: 8px; min-width: 175px; }
.cookie-consent-actions button {
    min-height: 42px;
    padding: 8px 12px;
    border: 1px solid var(--green-700);
    border-radius: 8px;
    background: #fff;
    color: var(--green-900);
    font: 500 0.85rem var(--font-body);
    cursor: pointer;
}
.cookie-consent-actions .cookie-accept { background: #fff; color: var(--green-900); }
.cookie-consent-actions button:focus-visible,
.cookie-settings-link:focus-visible { outline: 3px solid var(--green-500); outline-offset: 3px; }

/* ---------- Animacions reveal ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
    .grid-2 { grid-template-columns: 1fr; gap: 32px; }
    .nav-toggle { display: block; }
    .nav-links {
        display: none;
        position: absolute; top: 100%; left: 0; right: 0;
        flex-direction: column;
        background: var(--cream);
        padding: 20px;
        border-bottom: 1px solid rgba(124, 204, 175, 0.15);
    }
    .nav-links.open { display: flex; }
    .hero { padding: 70px 0 90px; }
    .section { padding: 64px 0; }
}
@media (max-width: 620px) {
    .cookie-consent { right: 12px; bottom: 12px; width: calc(100vw - 24px); flex-direction: column; align-items: stretch; gap: 14px; padding: 18px; }
    .cookie-consent-actions { flex-direction: column; }
}
