:root {
    --cream: #f6f1e3;
    --cream-deep: #efe4cf;
    --paper: #fffdf8;
    --brown: #8d5a32;
    --brown-deep: #5c3a1e;
    --green: #1d6b32;
    --green-bright: #2f9a42;
    --ink: #2b2418;
    --muted: #6d6254;
    --line: #e4d8c4;
    --danger: #8d2d2d;
    --warn: #8a4b12;
    --shadow: 0 16px 40px rgba(92, 58, 30, 0.08);
    --radius: 18px;
    --header: 84px;
    --font: "Nunito Sans", "Segoe UI", sans-serif;
    --display: "Fraunces", Georgia, serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--cream);
    font-family: var(--font);
    font-size: 1.05rem;
    line-height: 1.55;
}
img { max-width: 100%; height: auto; }
a { color: var(--green); }
button, input, textarea, select { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--display); line-height: 1.15; font-weight: 560; margin: 0 0 .4rem; }
p { margin: 0 0 .8rem; }
.skip {
    position: absolute;
    left: 1rem;
    top: -4rem;
    background: var(--ink);
    color: white;
    padding: .6rem 1rem;
    z-index: 20;
}
.skip:focus { top: 1rem; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}
.wrap { width: min(1120px, calc(100% - 2rem)); margin-inline: auto; }
.kicker {
    color: var(--green);
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    font-size: .78rem;
    margin-bottom: .35rem;
}
.muted { color: var(--muted); }
.block { display: block; }
.lead { max-width: 42rem; color: var(--muted); }

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(246, 241, 227, .94);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
}
.header-bar {
    min-height: var(--header);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}
.brand img { height: 64px; width: auto; display: block; }
.site-nav { display: flex; align-items: center; gap: .3rem 1rem; }
.site-nav a, .linkish {
    color: var(--ink);
    text-decoration: none;
    font-weight: 700;
    padding: .45rem .2rem;
    cursor: pointer;
}
.site-nav a.btn { color: white; padding: .45rem .9rem; }
.linkish { background: none; border: 0; }
.site-nav a.is-current { color: var(--green); }
.nav-toggle {
    display: none;
    width: 46px;
    height: 46px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--paper);
    padding: 10px;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
}
.nav-toggle span {
    display: block;
    height: 2px;
    background: var(--brown-deep);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: .7rem 1.15rem;
    border-radius: 999px;
    border: 2px solid var(--green);
    background: var(--green);
    color: white;
    text-decoration: none;
    font-weight: 800;
    cursor: pointer;
}
.btn:hover { background: #165628; }
.btn--ghost { background: transparent; color: var(--green); }
.btn--small { min-height: 42px; padding: .45rem .9rem; }
.btn--danger { background: var(--danger); border-color: var(--danger); }
.btn--danger:hover { background: #6f2222; }

.hero { position: relative; display: grid; }
.hero-slide {
    grid-area: 1 / 1;
    display: flex;
    align-items: center;
    min-height: calc(100vh - var(--header));
    min-height: calc(100svh - var(--header));
    padding: 2.5rem 0 4.5rem;
    opacity: 0;
    visibility: hidden;
}
.hero-slide.is-active { opacity: 1; visibility: visible; }
.hero-slide--0 { background: linear-gradient(160deg, #f8f3e6, #e7f3df 70%); }
.hero-slide--1 { background: linear-gradient(160deg, #f4efe2, #dceccf); }
.hero-slide--2 { background: linear-gradient(160deg, #f8f3e6, #f0e0c8); }
.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 2rem;
    align-items: center;
}
.hero-copy h1, .hero-copy h2 { font-size: clamp(2.3rem, 5vw, 4.4rem); }
.hero-copy p { font-size: 1.15rem; max-width: 36rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1rem; }
.hero-art img, .hero-art svg {
    width: 100%;
    height: min(440px, 56vw);
    object-fit: cover;
    border-radius: 28px;
    box-shadow: 0 18px 40px rgba(92, 58, 30, .16);
}
.slide-preview { width: 100%; max-height: 160px; object-fit: cover; border-radius: 14px; }
.hero-nav, .hero-dots { position: absolute; z-index: 2; }
.hero-nav {
    top: 50%;
    transform: translateY(-50%);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 0;
    background: var(--paper);
    color: var(--brown-deep);
    font-size: 1.8rem;
    cursor: pointer;
    box-shadow: var(--shadow);
}
.hero-nav--prev { left: 1rem; }
.hero-nav--next { right: 1rem; }
.hero-dots { left: 0; right: 0; bottom: 1.2rem; display: flex; justify-content: center; gap: .45rem; }
.hero-dots button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 0;
    background: #c8b89a;
    cursor: pointer;
}
.hero-dots button.is-active { background: var(--green); }

.band { background: var(--brown-deep); color: #f6f1e3; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; padding: 1.6rem 0; }
.steps article { padding: .4rem 0; }
.steps span {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--green-bright);
    color: white;
    font-weight: 800;
    margin-bottom: .5rem;
}
.steps h2 { font-size: 1.35rem; color: white; }
.section { padding: 3.5rem 0; }
#servicios { scroll-margin-top: calc(var(--header) + 8px); }
.section--tight { padding-top: 0; }
.section-head { margin-bottom: 1.4rem; max-width: 640px; }
.section-head h1, .section-head h2 { font-size: clamp(2rem, 4vw, 3rem); }
.section-lead { margin: .35rem 0 0; color: var(--muted); font-size: 1.08rem; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.card, .panel, .form-card, .calendar-card, .auth-card, .reserve-item {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.card { padding: 1.2rem; }
.card h3 { font-size: 1.45rem; }
.service-card {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 0;
    transition: transform .2s ease, box-shadow .2s ease;
}
.service-photo { width: 100%; height: 190px; object-fit: cover; display: block; }
.service-card-body { padding: 1.15rem 1.25rem 1.35rem 1.4rem; }
.service-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 6px;
    background: linear-gradient(var(--green), var(--green-bright));
    z-index: 1;
}
.service-card:hover { transform: translateY(-4px); box-shadow: 0 22px 40px rgba(92, 58, 30, .14); }
.service-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: .6rem; margin-bottom: .85rem; }
.service-card h3 { margin: 0 0 .35rem; }
.service-card p { margin: 0; color: var(--muted); }
.service-index { font-family: var(--display); font-size: 1.7rem; line-height: 1; color: #d7c09a; }
.card-icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    background: #e7f3df;
    color: var(--green);
    display: grid;
    place-items: center;
}
.card-icon svg { width: 30px; height: 30px; fill: currentColor; }
.service-edit-head { display: flex; align-items: center; gap: .7rem; }
.service-edit-head .card-icon { width: 46px; height: 46px; border-radius: 14px; }
.service-edit-head .card-icon svg { width: 24px; height: 24px; }
.edit-row { display: grid; grid-template-columns: 1.4fr .55fr auto; gap: .6rem; align-items: end; }
.cta-panel {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    border-radius: 28px;
    background: #e7f3df;
    border: 1px solid #cfe3c4;
}
.cta-panel h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }

.reserve-layout { display: grid; grid-template-columns: 1.3fr .7fr; gap: 1rem; align-items: start; }
.calendar-card, .form-card, .auth-card, .panel { padding: 1.1rem; }
.calendar-top, .panel-head, .detail-head, .row-head, .reserve-item, .alert-row, .filters {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: .8rem;
}
.calendar-top button, .pager a, .pager span {
    min-width: 44px;
    min-height: 44px;
}
.calendar-top button {
    border: 1px solid var(--line);
    background: var(--cream);
    border-radius: 12px;
    font-size: 1.5rem;
    cursor: pointer;
}
.calendar { display: grid; grid-template-columns: repeat(7, 1fr); gap: .35rem; margin-top: .8rem; }
.calendar .dow, .calendar button {
    min-height: 44px;
    border-radius: 12px;
    display: grid;
    place-items: center;
}
.calendar .dow { color: var(--muted); font-size: .78rem; font-weight: 800; min-height: auto; }
.calendar button {
    border: 1px solid transparent;
    background: #f3f7ef;
    cursor: pointer;
}
.calendar button.is-busy { background: #f3e4d4; color: var(--brown); text-decoration: line-through; }
.calendar button.is-past { color: #b3a894; background: transparent; cursor: default; }
.calendar button.is-range { background: #e7f3df; }
.calendar button.is-start, .calendar button.is-end { background: var(--green); color: white; }
.calendar button:focus-visible, .btn:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 3px solid #8dcc74;
    outline-offset: 2px;
}
.legend { display: flex; gap: 1rem; padding: 0; list-style: none; color: var(--muted); font-size: .92rem; }
.swatch { width: 14px; height: 14px; border-radius: 4px; display: inline-block; margin-right: .3rem; }
.swatch--free { background: #f3f7ef; border: 1px solid var(--line); }
.swatch--busy { background: #f3e4d4; }
.swatch--pick { background: var(--green); }
.range-summary { font-weight: 800; }

.stack-form, .stack { display: grid; gap: .85rem; }
label { display: grid; gap: .3rem; font-weight: 800; }
input, textarea, select {
    width: 100%;
    border: 1px solid var(--line);
    background: white;
    border-radius: 12px;
    padding: .75rem .8rem;
    font-weight: 600;
}
.check { display: flex; align-items: center; gap: .5rem; font-weight: 700; }
.check input { width: auto; }
.field-error { color: var(--danger); font-weight: 800; margin: 0; }
.auth-card { width: min(460px, calc(100% - 2rem)); margin: 2rem auto; text-align: left; }
.auth-card img { height: 78px; }
.auth-switch { margin-top: .4rem; }
.stack-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.reserve-list { display: grid; gap: .8rem; }
.reserve-item, .alert-row { padding: 1rem; align-items: flex-start; }
.reserve-side { display: grid; justify-items: end; gap: .5rem; }
.badge {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: .15rem .7rem;
    border-radius: 999px;
    font-size: .85rem;
    font-weight: 800;
    background: var(--cream-deep);
}
.badge--pendiente { background: #f6e2c4; color: var(--warn); }
.badge--confirmada { background: #e3f5e4; color: var(--green); }
.badge--rechazada, .badge--cancelada { background: #f8e4e4; color: var(--danger); }
.empty { padding: 1.5rem; background: var(--paper); border-radius: var(--radius); }

.site-footer {
    background:
        radial-gradient(900px 220px at 12% 0%, rgba(246, 241, 227, .16), transparent 55%),
        var(--brown-deep);
    color: #f6f1e3;
    margin-top: 2.5rem;
    padding: 0 0 1.1rem;
}
.site-footer::before {
    content: "";
    display: block;
    height: 7px;
    background: linear-gradient(90deg, var(--green) 0 28%, #e7d3b0 28% 72%, var(--green-bright) 72% 100%);
}
.site-footer h2 {
    font-family: var(--font);
    font-size: .75rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #e7d3b0;
    margin: 0 0 .85rem;
}
.site-footer a { color: #f6f1e3; }
.footer-panel {
    display: grid;
    grid-template-columns: minmax(240px, 1.35fr) minmax(140px, .75fr) minmax(180px, .95fr) minmax(230px, 1fr);
    gap: 2rem 1.6rem;
    align-items: start;
    padding: 2.4rem 0 1.5rem;
}
.footer-brand p { max-width: 34rem; color: #f3e6d2; }
.footer-logo-plate {
    display: grid;
    place-items: center;
    width: min(100%, 280px);
    margin-bottom: 1rem;
    padding: .85rem 1rem .7rem;
    background: var(--cream);
    border-radius: 28px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, .22);
}
.footer-logo { height: 104px; width: auto; display: block; }
.footer-links { list-style: none; padding: 0; margin: 0 0 .8rem; }
.footer-links a { text-decoration: none; font-weight: 700; }
.footer-links li + li { margin-top: .35rem; }
.footer-links a:hover { color: white; }
.footer-lead { color: #f3e6d2; margin-bottom: .85rem; }
.footer-cta { background: var(--green-bright); border-color: var(--green-bright); }
.footer-base {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    border-top: 1px solid rgba(246, 241, 227, .18);
    margin-top: .2rem;
    padding-top: 1rem;
    color: #e7d7c2;
}
.footer-base a {
    text-decoration: none;
    font-weight: 800;
    border-bottom: 1px solid rgba(246, 241, 227, .45);
}
.socials { display: flex; flex-wrap: wrap; gap: .85rem .65rem; list-style: none; padding: 0; margin: 0; }
.social {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .35rem;
    width: 76px;
    min-height: 0;
    padding: 0;
    background: transparent;
    color: #f6f1e3;
    text-decoration: none;
    font-size: .75rem;
    font-weight: 800;
    text-align: center;
}
.social-mark {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: white;
    box-shadow: 0 10px 18px rgba(0, 0, 0, .2);
    transition: transform .18s ease;
}
.social-mark svg { width: 22px; height: 22px; fill: currentColor; }
a.social:hover .social-mark { transform: translateY(-3px); }
.social--facebook .social-mark { background: #1877f2; }
.social--instagram .social-mark { background: linear-gradient(135deg, #f9ce34, #ee2a7b 55%, #6228d7); }
.social--tiktok .social-mark { background: #161616; }
.social--youtube .social-mark { background: #ff0033; }
.social--whatsapp .social-mark { background: #25d366; }
.social.is-idle { opacity: 1; }

.flash {
    width: min(1120px, calc(100% - 2rem));
    margin: 1rem auto 0;
    background: #e7f3df;
    border: 1px solid #b7ddb4;
    color: #145226;
    padding: .8rem 1rem;
    border-radius: 14px;
    font-weight: 800;
}
.admin-body { background: #f3ecdf; }
.admin-body .flash { width: auto; margin: 0 0 1rem; }
.admin-shell { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.admin-side { background: var(--brown-deep); color: white; padding: 1rem; }
.admin-side a { color: white; }
.brand--admin img { height: 72px; margin: .4rem auto 1rem; }
.admin-nav { display: grid; gap: .25rem; }
.admin-nav a { text-decoration: none; padding: .75rem .8rem; border-radius: 12px; font-weight: 800; }
.admin-nav a.is-current, .admin-nav a:hover { background: rgba(255,255,255,.12); }
.admin-main { min-width: 0; }
.admin-top {
    display: flex;
    align-items: center;
    gap: .8rem;
    padding: .8rem 1rem;
    background: rgba(255,253,248,.9);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 5;
}
.admin-hello { margin: 0; font-weight: 800; margin-right: auto; }
.admin-content { padding: 1.2rem; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin-bottom: 1rem; }
.stats article { background: var(--paper); border-radius: var(--radius); padding: 1rem; border: 1px solid var(--line); }
.stats span { color: var(--muted); font-weight: 800; }
.stats strong { display: block; font-family: var(--display); font-size: 2.4rem; }
.panel { margin-bottom: 1rem; }
.panel h2 { font-size: 1.5rem; }
.notice { background: #fff4e5; border: 1px solid #efd0a8; border-radius: var(--radius); padding: 1rem; margin-bottom: 1rem; }
.notice ul { margin: 0; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .75rem .4rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.filters, .form-grid { display: grid; grid-template-columns: 1fr 220px auto; gap: .7rem; align-items: end; margin-bottom: 1rem; }
.filters--search { grid-template-columns: 1fr auto; }
.form-grid { grid-template-columns: 1fr 1fr; }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.facts { display: grid; gap: .7rem; margin: 0; }
.facts div { display: grid; grid-template-columns: 120px 1fr; gap: .5rem; }
.facts dt { color: var(--muted); font-weight: 800; }
.facts dd { margin: 0; }
.edit-block { border: 1px dashed var(--line); border-radius: 14px; padding: .8rem; display: grid; gap: .6rem; }
.split-top { margin-top: 1rem; }
.back-link { font-weight: 800; }
.pager { display: flex; gap: .6rem; align-items: center; margin-top: 1rem; }
.pager a, .pager span { display: inline-flex; align-items: center; padding: .4rem .7rem; }
.pager .is-disabled { color: var(--muted); }
.alert-bell { position: relative; }
.bell {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: var(--paper);
    position: relative;
    cursor: pointer;
}
.bell svg { width: 22px; height: 22px; fill: var(--brown-deep); }
.bell-count {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    border-radius: 99px;
    background: var(--danger);
    color: white;
    font-size: .75rem;
    font-weight: 800;
    display: grid;
    place-items: center;
}
.bell-panel {
    position: absolute;
    right: 0;
    top: 52px;
    width: min(340px, 80vw);
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
    padding: .8rem;
    z-index: 6;
}
.bell-panel ul { list-style: none; padding: 0; margin: .5rem 0 0; display: grid; gap: .45rem; }
.bell-head { display: flex; justify-content: space-between; gap: .5rem; }
.alert-row.is-read { opacity: .65; }
.toast {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    background: var(--brown-deep);
    color: white;
    padding: .9rem 1rem;
    border-radius: 14px;
    z-index: 30;
    max-width: min(320px, calc(100% - 2rem));
    font-weight: 800;
}
.error-page { min-height: 100vh; display: grid; place-items: center; align-content: center; text-align: center; padding: 2rem; }
.error-page img { height: 90px; }

@media (min-width: 981px) {
    .hero .wrap { width: min(1040px, calc(100% - 8rem)); }
}
@media (max-width: 980px) {
    .hero-grid, .cards, .steps, .reserve-layout, .detail-grid, .stats { grid-template-columns: 1fr 1fr; }
    .footer-panel { grid-template-columns: 1fr 1fr; }
    .footer-brand { grid-column: 1 / -1; }
    .hero-grid { grid-template-columns: 1fr; }
    .hero-art { max-width: 460px; }
    .admin-shell { grid-template-columns: 1fr; }
    .admin-side {
        position: fixed;
        z-index: 15;
        inset: 0 auto 0 0;
        width: min(84vw, 300px);
        transform: translateX(-105%);
        transition: transform .2s ease;
    }
    .admin-side.is-open { transform: none; }
    .nav-toggle { display: inline-flex; }
    .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        background: var(--cream);
        border-bottom: 1px solid var(--line);
        padding: .6rem 1rem 1rem;
    }
    .site-nav.is-open { display: flex; }
    .header-bar { position: relative; }
    .site-nav a.btn { justify-content: center; }
}
@media (max-width: 760px) {
    .cards, .steps, .footer-panel, .reserve-layout, .detail-grid, .stats, .filters, .form-grid, .facts div, .edit-row { grid-template-columns: 1fr; }
    .footer-logo-plate { width: min(100%, 240px); }
    .footer-logo { height: 86px; }
    .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        background: var(--cream);
        border-bottom: 1px solid var(--line);
        padding: .6rem 1rem 1rem;
    }
    .site-nav.is-open { display: flex; }
    .header-bar { position: relative; }
    .brand img { height: 52px; }
    .hero-slide { min-height: auto; padding-bottom: 4rem; }
    .hero-art img, .hero-art svg { height: 230px; }
    .hero-nav { display: none; }
    .site-nav { display: none; }
    .site-nav.is-open { display: flex; }
    .cta-panel, .reserve-item, .alert-row, .detail-head, .row-head, .footer-base { flex-direction: column; align-items: stretch; }
    .reserve-side { justify-items: start; }
    .calendar { gap: .2rem; }
    .calendar button, .calendar .dow { min-height: 40px; font-size: .92rem; }
    table thead { display: none; }
    table, tbody, tr, td { display: block; width: 100%; }
    tr { padding: .4rem 0  .8rem; }
    td { border: 0; padding: .2rem 0; }
    td::before { content: attr(data-label); display: block; color: var(--muted); font-size: .78rem; font-weight: 800; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .hero-slide, .admin-side { transition: none; }
}
