/* ==========================================================================
   core — tokens, fuentes, reset, tipografia base, utilidades, pie, cookies
   Verdal Paisaje
   ========================================================================== */

/* --- Fuentes ------------------------------------------------------------- */
@font-face {
    font-display: swap;
    font-family: "Cormorant Garamond";
    font-style: normal;
    font-weight: 600;
    src: url("../fonts/cormorant-600.woff2") format("woff2");
}

@font-face {
    font-display: swap;
    font-family: "Inter";
    font-style: normal;
    font-weight: 100 900;
    src: url("../fonts/inter-latin.woff2") format("woff2");
}

/* --- Tokens -------------------------------------------------------------- */
:root {
    --ink: #16201a;
    --line: #d8e2d8;
    --muted: #54655a;
    --oliva: #cccc33;
    --oro: #cc9933;
    --oro-dark: #a87d23;
    --paper: #f3f6f1;
    --paper-2: #ffffff;
    --radius: 0.875rem;
    --radius-sm: 0.5rem;
    --shadow: 0 0.75rem 2.5rem rgba(3, 61, 35, 0.1);
    --shadow-soft: 0 0.25rem 1rem rgba(3, 61, 35, 0.07);
    --space: 1.5rem;
    --verde: #006633;
    --verde-deep: #033d23;
    --verde-soft: #e4ede4;
    /* TODO: revisar el contraste del dorado en hover sobre fondo claro */
    --wrap: 72rem;
}

/* --- Reset --------------------------------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    background: var(--paper);
    color: var(--ink);
    font-family: "Inter", system-ui, -apple-system, sans-serif;
    font-size: 1.0625rem;
    line-height: 1.62;
    margin: 0;
    text-rendering: optimizeLegibility;
}

img {
    display: block;
    height: auto;
    max-width: 100%;
}

a {
    color: var(--verde);
    text-decoration-thickness: 0.0625rem;
    text-underline-offset: 0.18em;
}

a:hover {
    color: var(--verde-deep);
}

h1,
h2,
h3 {
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.12;
    margin: 0 0 0.5em;
}

h1 {
    font-size: clamp(2.2rem, 1.4rem + 3.2vw, 3.4rem);
}

h2 {
    font-size: clamp(1.85rem, 1.3rem + 2vw, 2.5rem);
}

h3 {
    font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.6rem);
}

p {
    margin: 0 0 1rem;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        scroll-behavior: auto;
        transition-duration: 0.01ms !important;
    }
}

/* --- Utilidades --------------------------------------------------------- */
.wrap {
    margin-inline: auto;
    max-width: var(--wrap);
    padding-inline: 1.375rem;
    width: 100%;
}

.eyebrow {
    color: var(--oro-dark);
    display: inline-block;
    font-family: "Inter", sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
}

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

.to-content {
    background: var(--verde-deep);
    border-radius: var(--radius-sm);
    color: #ffffff;
    left: 0.875rem;
    padding: 0.75rem 1.125rem;
    position: absolute;
    top: -6.25rem;
    transition: top 0.2s ease;
    z-index: 1200;
}

.to-content:focus {
    color: #ffffff;
    top: 0.875rem;
}

:focus-visible {
    outline: 0.1875rem solid var(--oro);
    outline-offset: 0.1875rem;
}

/* --- Botones ------------------------------------------------------------ */
.btn {
    border: 0.0625rem solid transparent;
    border-radius: 999rem;
    cursor: pointer;
    display: inline-flex;
    font-family: "Inter", sans-serif;
    font-size: 0.98rem;
    font-weight: 600;
    gap: 0.5rem;
    justify-content: center;
    line-height: 1;
    min-height: 3rem;
    padding: 0.9rem 1.6rem;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.btn--oro {
    background: var(--oro);
    color: var(--verde-deep);
}

.btn--oro:hover {
    background: var(--oro-dark);
    color: #ffffff;
    transform: translateY(-0.125rem);
}

.btn--verde {
    background: var(--verde);
    color: #ffffff;
}

.btn--verde:hover {
    background: var(--verde-deep);
    color: #ffffff;
}

.btn--ghost {
    background: transparent;
    border-color: currentColor;
    color: inherit;
}

.btn--ghost:hover {
    background: rgba(255, 255, 255, 0.12);
}

/* --- Pie ---------------------------------------------------------------- */
.site-foot {
    background: var(--verde-deep);
    color: rgba(231, 239, 233, 0.84);
    margin-top: 4rem;
    padding-block: 3.5rem 2rem;
}

.site-foot a {
    color: rgba(231, 239, 233, 0.84);
}

.site-foot a:hover {
    color: var(--oro);
}

.site-foot__grid {
    display: grid;
    gap: 2.25rem;
    grid-template-columns: 1fr;
}

.site-foot__brand p {
    max-width: 30ch;
}

.site-foot__name {
    color: #ffffff;
    font-family: "Cormorant Garamond", serif;
    font-size: 1.4rem;
    font-weight: 600;
    text-decoration: none;
}

.site-foot__col h3 {
    color: #ffffff;
    font-family: "Inter", sans-serif;
    font-size: 0.82rem;
    letter-spacing: 0.12em;
    margin-bottom: 0.9rem;
    text-transform: uppercase;
}

.site-foot__col ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-foot__col li {
    margin-bottom: 0.55rem;
}

.site-foot__base {
    border-top: 0.0625rem solid rgba(231, 239, 233, 0.18);
    display: flex;
    flex-wrap: wrap;
    font-size: 0.85rem;
    gap: 0.75rem 1.5rem;
    justify-content: space-between;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
}

@media (min-width: 48rem) {
    .site-foot__grid {
        grid-template-columns: 1.4fr 1fr 1fr 1.1fr;
    }
}

/* --- Cookies (cookie-tray) ---------------------------------------------- */
.cookie-tray {
    background: var(--paper-2);
    border: 0.0625rem solid var(--line);
    border-radius: var(--radius);
    bottom: 1.25rem;
    box-shadow: var(--shadow);
    left: 1.25rem;
    max-width: 25rem;
    padding: 1.25rem 1.35rem;
    position: fixed;
    transform: translateY(1.5rem);
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 1100;
}

.cookie-tray[hidden] {
    display: none;
}

.cookie-tray--shown {
    opacity: 1;
    transform: translateY(0);
}

.cookie-tray__text {
    font-size: 0.92rem;
    margin: 0 0 1rem;
}

.cookie-tray__actions {
    display: flex;
    gap: 0.65rem;
}

.cookie-tray__btn {
    border: 0.0625rem solid var(--verde);
    border-radius: 999rem;
    cursor: pointer;
    flex: 1;
    font-family: "Inter", sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    min-height: 2.75rem;
    padding: 0.6rem 1rem;
}

.cookie-tray__btn--yes {
    background: var(--verde);
    color: #ffffff;
}

.cookie-tray__btn--no {
    background: transparent;
    color: var(--verde);
}
