/* ============================================================
   Club Campestre Erandeni — Landing
   Brand palette mirrors the mobile app (lib/app/theme/colors.dart)
   ============================================================ */

:root {
    --brand-blue: #1B3A7A;
    --brand-blue-deep: #14306A;
    --brand-blue-light: #3558A3;
    --brand-green: #1E6B3A;
    --brand-green-light: #2F8A4E;
    --accent-orange: #E89A2B;
    --accent-red: #B91C1C;
    --fairway: #F4F7F2;
    --water: #2E8EC4;

    --ink: #16203a;
    --ink-soft: #4a5468;
    --line: #e4e8ef;
    --white: #ffffff;

    --font-display: 'Playfair Display', Georgia, serif;
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;

    --maxw: 1140px;
    --radius: 16px;
    --shadow: 0 14px 40px rgba(20, 48, 106, 0.12);
    --shadow-sm: 0 6px 18px rgba(20, 48, 106, 0.08);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
    font-family: var(--font-body);
    color: var(--ink);
    background: var(--white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container {
    width: 100%;
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Scroll reveal ---------- */
[data-reveal] {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity .7s ease, transform .7s ease;
    will-change: opacity, transform;
}
[data-reveal].is-visible { opacity: 1; transform: none; }
/* Stagger children within a grid */
[data-reveal-stagger] > * { transition-delay: calc(var(--i, 0) * 80ms); }
@media (prefers-reduced-motion: reduce) {
    [data-reveal] { opacity: 1; transform: none; transition: none; }
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.98rem;
    border: 2px solid transparent;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn--primary { background: var(--brand-green); color: var(--white); }
.btn--primary:hover { background: var(--brand-green-light); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn--ghost { background: transparent; color: var(--white); border-color: rgba(255,255,255,.7); }
.btn--ghost:hover { background: rgba(255,255,255,.12); }
.btn--outline { background: transparent; color: var(--brand-green); border-color: var(--brand-green); }
.btn--outline:hover { background: var(--brand-green); color: var(--white); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn--block { width: 100%; }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }

/* ---------- Nav ---------- */
.nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    background: rgba(255,255,255,.0);
    transition: background .3s ease, box-shadow .3s ease;
}
.nav.is-scrolled {
    background: rgba(255,255,255,.96);
    box-shadow: 0 2px 18px rgba(20,48,106,.1);
    backdrop-filter: saturate(160%) blur(8px);
}
.nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}
.nav__brand { display: flex; align-items: center; gap: 12px; }
.nav__logo {
    width: 46px; height: 46px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 2px 10px rgba(0,0,0,.2);
    background: #fff;
}
.nav__brand-text { display: flex; flex-direction: column; line-height: 1.1; color: var(--white); }
.nav.is-scrolled .nav__brand-text { color: var(--brand-blue); }
.nav__brand-text strong { font-size: .95rem; font-weight: 700; letter-spacing: .3px; }
.nav__brand-text span { font-size: .8rem; opacity: .85; text-transform: uppercase; letter-spacing: 2px; }

.nav__links { display: flex; align-items: center; gap: 28px; }
.nav__links a {
    color: var(--white);
    font-weight: 500;
    font-size: .95rem;
    transition: color .15s ease, opacity .15s ease;
    opacity: .92;
}
.nav__links a:hover { opacity: 1; }
.nav.is-scrolled .nav__links a { color: var(--ink); }
.nav__cta {
    background: var(--accent-orange);
    color: var(--white) !important;
    padding: 9px 20px;
    border-radius: 999px;
    font-weight: 600;
    opacity: 1 !important;
}
.nav__cta:hover { filter: brightness(1.05); }

.nav__toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none; border: none; cursor: pointer; padding: 6px;
}
.nav__toggle span { width: 26px; height: 2px; background: var(--white); border-radius: 2px; transition: .25s; }
.nav.is-scrolled .nav__toggle span { background: var(--brand-blue); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    color: var(--white);
    /* Swap-in: drop a file at assets/backgrounds/hero.jpg and it layers under the gradient */
    background:
        linear-gradient(120deg, rgba(20,48,106,.86), rgba(30,107,58,.72)),
        url('assets/backgrounds/hero.jpg') center/cover no-repeat,
        linear-gradient(120deg, var(--brand-blue-deep), var(--brand-green));
}
.hero__overlay {
    position: absolute; inset: 0;
    background: radial-gradient(circle at 75% 30%, rgba(46,142,196,.25), transparent 55%);
    pointer-events: none;
}
.hero__content { position: relative; z-index: 2; max-width: 760px; margin: 0 auto; text-align: center; padding-top: 96px; }

/* Large masked crest watermark behind the hero text */
.hero__watermark {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
    pointer-events: none;
}
.hero__watermark img {
    width: min(640px, 78vw);
    height: auto;
    opacity: .16;
    mix-blend-mode: soft-light;
    /* Fade the square JPG corners into nothing -> only the round crest reads */
    -webkit-mask-image: radial-gradient(circle, #000 48%, rgba(0,0,0,0) 66%);
    mask-image: radial-gradient(circle, #000 48%, rgba(0,0,0,0) 66%);
}
.hero__eyebrow {
    text-transform: uppercase;
    letter-spacing: 4px;
    font-size: .8rem;
    font-weight: 600;
    color: var(--accent-orange);
    margin-bottom: 18px;
}
.hero__title {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(2.6rem, 6vw, 4.6rem);
    line-height: 1.05;
    margin-bottom: 22px;
    text-shadow: 0 4px 30px rgba(0,0,0,.3);
}
.hero__subtitle { font-size: clamp(1.05rem, 2vw, 1.3rem); max-width: 560px; margin: 0 auto 34px; opacity: .95; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.hero__scroll {
    position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
    z-index: 2; font-size: 1.6rem; color: var(--white); opacity: .8;
    animation: bob 1.8s ease-in-out infinite;
}
@keyframes bob { 0%,100% { transform: translate(-50%,0); } 50% { transform: translate(-50%,8px); } }

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section--alt { background: var(--fairway); }
.section__head { max-width: 720px; margin: 0 auto 56px; text-align: center; }
.section__eyebrow {
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: .78rem;
    font-weight: 700;
    color: var(--brand-green);
    margin-bottom: 14px;
}
.section__eyebrow--light { color: var(--accent-orange); }
.section__title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(1.9rem, 4vw, 2.8rem);
    color: var(--brand-blue);
    line-height: 1.15;
    margin-bottom: 16px;
}
.section__title--light { color: var(--white); }
.section__lead { color: var(--ink-soft); font-size: 1.08rem; }

/* ---------- Features ---------- */
.features {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 22px;
    margin-bottom: 72px;
}
.feature {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 32px 24px;
    text-align: center;
    transition: transform .2s ease, box-shadow .2s ease;
}
.feature:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.feature__icon { font-size: 2.4rem; margin-bottom: 14px; }
.feature h3 { color: var(--brand-blue); font-size: 1.15rem; margin-bottom: 8px; }
.feature p { color: var(--ink-soft); font-size: .95rem; }

/* ---------- Stats ---------- */
.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    background: linear-gradient(120deg, var(--brand-blue), var(--brand-blue-light));
    border-radius: var(--radius);
    padding: 40px 24px;
    color: var(--white);
}
.stat { text-align: center; }
.stat__num { display: block; font-family: var(--font-display); font-size: 2.6rem; font-weight: 700; color: var(--accent-orange); }
.stat__label { font-size: .92rem; opacity: .9; }

/* ---------- Disciplinas (chips) + Amenidades ---------- */
.block-title {
    text-align: center;
    font-family: var(--font-display);
    color: var(--brand-blue);
    font-size: 1.5rem;
    margin-bottom: 24px;
}
.chips { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-bottom: 64px; }
.chip {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 10px 18px;
    font-weight: 600; font-size: .95rem; color: var(--ink);
    box-shadow: var(--shadow-sm);
    transition: transform .15s ease, border-color .15s ease, color .15s ease;
}
.chip:hover { border-color: var(--brand-green); color: var(--brand-green); transform: translateY(-2px); }

.amenities { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; max-width: 860px; margin: 0 auto 72px; }
.amenity {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px 22px;
    text-align: center;
    transition: transform .2s ease, box-shadow .2s ease;
}
.amenity:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.amenity__icon { font-size: 2.2rem; margin-bottom: 12px; }
.amenity h4 { color: var(--brand-blue); font-size: 1.05rem; margin-bottom: 6px; }
.amenity p { color: var(--ink-soft); font-size: .9rem; }

/* ---------- Golf ---------- */
.section--golf {
    background:
        linear-gradient(135deg, rgba(20,48,106,.92), rgba(30,107,58,.9)),
        url('assets/backgrounds/golf.jpg') center/cover no-repeat,
        var(--brand-green);
    color: var(--white);
}
.golf__grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 48px;
    align-items: center;
}
.golf__text { font-size: 1.08rem; opacity: .95; margin-bottom: 22px; }
.golf__list { list-style: none; margin-bottom: 30px; }
.golf__list li { padding: 8px 0 8px 30px; position: relative; opacity: .95; }
.golf__list li::before {
    content: "\26F3"; position: absolute; left: 0; top: 8px; font-size: 1rem;
}
.golf__card {
    background: var(--white);
    color: var(--ink);
    border-radius: var(--radius);
    padding: 34px;
    box-shadow: var(--shadow);
    position: relative;
}
.golf__card h3 { font-family: var(--font-display); color: var(--brand-blue); font-size: 1.5rem; margin: 6px 0 12px; }
.golf__card > p { color: var(--ink-soft); margin-bottom: 22px; }
.golf__card-mock {
    background: var(--fairway);
    border: 1px dashed var(--line);
    border-radius: 12px;
    padding: 20px;
}
.golf__card-row {
    display: flex; justify-content: space-between;
    padding: 10px 0; border-bottom: 1px solid var(--line);
    font-size: .95rem;
}
.golf__card-row:nth-child(2) { border-bottom: none; margin-bottom: 16px; }
.golf__card-row span:last-child { font-weight: 700; color: var(--brand-green); }
.golf__card-note { text-align: center; font-size: .82rem; color: var(--ink-soft); margin-top: 12px; }

.badge {
    display: inline-block;
    font-size: .72rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 1.5px;
    padding: 6px 14px; border-radius: 999px;
}
.badge--soon { background: var(--accent-orange); color: var(--white); }
.badge--feature { background: var(--accent-red); color: var(--white); }

/* ---------- Torneos de Golf (featured tournament) ---------- */
.torneo {
    display: grid;
    grid-template-columns: minmax(300px, 420px) 1fr;
    gap: 44px;
    align-items: start;
    background: var(--white);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
}
.torneo__flyer {
    position: relative;
    display: block;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(20,48,106,.18);
    line-height: 0;
}
.torneo__flyer img { width: 100%; height: auto; transition: transform .3s ease; }
.torneo__flyer:hover img { transform: scale(1.03); }
.torneo__flyer-zoom {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    background: rgba(20,48,106,.45);
    color: var(--white); font-weight: 600; font-size: .95rem; line-height: 1.4;
    opacity: 0; transition: opacity .25s ease;
}
.torneo__flyer:hover .torneo__flyer-zoom { opacity: 1; }

.torneo__info { padding-top: 6px; }
.torneo__title { font-family: var(--font-display); color: var(--brand-blue); font-size: clamp(1.6rem, 3vw, 2.3rem); margin: 14px 0 8px; }
.torneo__sub { color: var(--ink-soft); margin-bottom: 22px; }

.torneo__facts { list-style: none; margin-bottom: 22px; border-top: 1px solid var(--line); }
.torneo__facts li {
    display: flex; flex-wrap: wrap; gap: 4px 16px;
    padding: 11px 0; border-bottom: 1px solid var(--line);
}
.torneo__facts li span {
    flex: 0 0 92px;
    font-size: .72rem; text-transform: uppercase; letter-spacing: 1.5px;
    color: var(--brand-green); font-weight: 700; padding-top: 2px;
}
.torneo__facts li strong { flex: 1; font-weight: 600; color: var(--ink); }

.torneo__prices { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
.torneo__price {
    flex: 1; min-width: 110px;
    background: var(--fairway); border: 1px solid var(--line); border-radius: 12px;
    padding: 12px 14px; text-align: center;
}
.torneo__price span { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: 1px; color: var(--ink-soft); }
.torneo__price strong { font-family: var(--font-display); font-size: 1.5rem; color: var(--brand-green); }

.torneo__deadline { font-size: .92rem; color: var(--accent-red); font-weight: 500; margin-bottom: 22px; }
.torneo__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.torneo__note { font-size: .82rem; color: var(--ink-soft); line-height: 1.5; }

/* ---------- Golf page hero (próximo torneo header) ---------- */
.page-hero {
    position: relative;
    padding: 150px 0 88px;
    color: var(--white);
    text-align: center;
    background:
        linear-gradient(135deg, rgba(20,48,106,.9), rgba(30,107,58,.82)),
        url('assets/backgrounds/golf.jpg') center/cover no-repeat,
        var(--brand-green);
}
.page-hero__content { position: relative; z-index: 2; max-width: 820px; margin: 0 auto; }
.page-hero__back {
    display: inline-block; margin-bottom: 18px;
    font-size: .9rem; font-weight: 500; color: rgba(255,255,255,.85);
}
.page-hero__back:hover { color: var(--white); }
.page-hero__eyebrow {
    display: inline-block; margin-bottom: 14px;
    text-transform: uppercase; letter-spacing: 3px; font-size: .8rem; font-weight: 700;
    color: var(--accent-orange);
}
.page-hero__title {
    font-family: var(--font-display); font-weight: 800;
    font-size: clamp(2.1rem, 5vw, 3.4rem); line-height: 1.08; margin-bottom: 16px;
    text-shadow: 0 4px 28px rgba(0,0,0,.3);
}
.page-hero__meta { font-size: clamp(1rem, 2vw, 1.18rem); opacity: .95; margin-bottom: 30px; }
.page-hero__actions { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }

/* Active nav link */
.nav__links a.is-active { color: var(--accent-orange); opacity: 1; }
.nav.is-scrolled .nav__links a.is-active { color: var(--accent-orange); }

/* ---------- Próximamente · Pagos en línea ---------- */
.pagos { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.pago-card {
    position: relative;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 30px 24px;
    text-align: center;
    transition: transform .2s ease, box-shadow .2s ease;
}
.pago-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.pago-card .badge--soon { position: absolute; top: 14px; right: 14px; }
.pago-card__icon { font-size: 2.4rem; margin-bottom: 14px; }
.pago-card h3 { color: var(--brand-blue); font-size: 1.1rem; margin-bottom: 8px; }
.pago-card p { color: var(--ink-soft); font-size: .92rem; }

/* ---------- Events ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 40px; }
.filter-btn {
    padding: 9px 22px;
    border-radius: 999px;
    border: 1.5px solid var(--line);
    background: var(--white);
    color: var(--ink-soft);
    font-weight: 600; font-size: .92rem; cursor: pointer;
    transition: .15s;
}
.filter-btn:hover { border-color: var(--brand-green); color: var(--brand-green); }
.filter-btn.is-active { background: var(--brand-green); border-color: var(--brand-green); color: var(--white); }

.events { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.events__loading, .events__empty { text-align: center; color: var(--ink-soft); padding: 40px 0; }

.event-card {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--white);
    display: flex; flex-direction: column;
    transition: transform .2s ease, box-shadow .2s ease;
}
.event-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.event-card__top {
    padding: 18px 20px;
    color: var(--white);
    display: flex; align-items: center; justify-content: space-between;
}
.event-card__date { text-align: center; line-height: 1; }
.event-card__day { font-family: var(--font-display); font-size: 1.9rem; font-weight: 700; }
.event-card__month { font-size: .75rem; text-transform: uppercase; letter-spacing: 1.5px; }
.event-card__cat {
    font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
    background: rgba(255,255,255,.22); padding: 5px 10px; border-radius: 999px;
}
.event-card__body { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.event-card__title { color: var(--brand-blue); font-size: 1.1rem; margin-bottom: 8px; }
.event-card__desc { color: var(--ink-soft); font-size: .92rem; flex: 1; margin-bottom: 14px; }
.event-card__meta { font-size: .85rem; color: var(--ink-soft); display: flex; flex-direction: column; gap: 4px; }
.event-card__time::before { content: "\1F552"; margin-right: 6px; }
.event-card__loc::before { content: "\1F4CD"; margin-right: 6px; }
.event-card__spots {
    margin-top: 14px; font-size: .82rem; font-weight: 600; color: var(--brand-green);
}

/* "Próximamente" event card — muted header, no date */
.event-card--soon .event-card__top { background: #7a8699; }
.event-card__soon-pill {
    font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px;
    color: var(--white);
}
.event-card--soon .event-card__title { color: var(--ink); }

/* ---------- Sponsors ---------- */
.sponsors {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 18px;
    margin-bottom: 56px;
}
.sponsor {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 12px;
    height: 90px;
    display: flex; align-items: center; justify-content: center;
    padding: 14px;
}
.sponsor img { max-height: 56px; width: auto; object-fit: contain; filter: grayscale(1); opacity: .8; transition: .2s; }
.sponsor:hover img { filter: grayscale(0); opacity: 1; }
.sponsor--placeholder { color: #b6bdca; font-size: .82rem; font-weight: 600; border-style: dashed; }
.sponsors__cta {
    text-align: center;
    background: linear-gradient(120deg, var(--brand-blue), var(--brand-green));
    color: var(--white);
    border-radius: var(--radius);
    padding: 48px 24px;
}
.sponsors__cta h3 { font-family: var(--font-display); font-size: 1.8rem; margin-bottom: 10px; }
.sponsors__cta p { opacity: .9; margin-bottom: 24px; }

/* ---------- Footer ---------- */
.footer { background: var(--brand-blue-deep); color: rgba(255,255,255,.85); }
.footer__grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr 1fr;
    gap: 40px;
    padding: 64px 24px 48px;
}
.footer__logo { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; margin-bottom: 16px; }
.footer__brand p { font-size: .95rem; opacity: .85; }
.footer__col h4 { color: var(--white); font-size: .95rem; margin-bottom: 16px; text-transform: uppercase; letter-spacing: 1px; }
.footer__col p { margin-bottom: 10px; font-size: .92rem; }
.footer__col a:hover, .footer__brand a:hover { color: var(--accent-orange); }
.footer__bar { border-top: 1px solid rgba(255,255,255,.12); }
.footer__bar-inner {
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;
    padding: 20px 24px; font-size: .85rem; opacity: .75;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
    .features, .stats, .pagos { grid-template-columns: repeat(2, 1fr); }
    .golf__grid { grid-template-columns: 1fr; }
    .torneo { grid-template-columns: 1fr; gap: 32px; }
    .torneo__flyer { max-width: 460px; margin: 0 auto; }
    .events { grid-template-columns: repeat(2, 1fr); }
    .sponsors { grid-template-columns: repeat(3, 1fr); }
    .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
    .nav__toggle { display: flex; }
    .nav__links {
        position: absolute; top: 72px; left: 0; right: 0;
        flex-direction: column; align-items: stretch; gap: 0;
        background: var(--white);
        box-shadow: 0 12px 30px rgba(20,48,106,.15);
        padding: 8px 0;
        max-height: 0; overflow: hidden;
        transition: max-height .3s ease;
    }
    .nav__links.is-open { max-height: 420px; }
    .nav__links a { color: var(--ink); padding: 14px 24px; border-bottom: 1px solid var(--line); }
    .nav__cta { margin: 12px 24px; text-align: center; }
    .section { padding: 64px 0; }
    .events { grid-template-columns: 1fr; }
    .amenities { grid-template-columns: 1fr; }
    .sponsors { grid-template-columns: repeat(2, 1fr); }
    .footer__grid { grid-template-columns: 1fr; gap: 28px; }
}
