/* =====================================================
   ROMANCE — PÁGINA PÚBLICA
   Editorial de lujo: tinta vino-negro + papel crema + dorado.
   Independiente de romance-design.css (ese es del panel admin) —
   esta hoja es autocontenida a propósito para no heredar los
   !important de Bootstrap/forms del panel.
   ===================================================== */

:root {
    --ink:          oklch(19% 0.035 18);
    --ink-soft:      oklch(25% 0.04 18);
    --ink-line:      oklch(32% 0.035 18);
    --paper:         oklch(96% 0.016 80);
    --paper-deep:    oklch(92.5% 0.022 72);
    --paper-line:    oklch(85% 0.025 65);
    --gold:          oklch(71% 0.13 78);
    --gold-deep:     oklch(58% 0.12 72);
    --text:          oklch(21% 0.025 25);
    --text-muted:    oklch(42% 0.03 30);
    --text-on-ink:   oklch(93% 0.018 75);
    --text-on-ink-muted: oklch(76% 0.03 60);

    --font-display: 'Fraunces', 'Iowan Old Style', serif;
    --font-body: 'Jost', 'Avenir Next', sans-serif;
    --font-script: 'Mrs Saint Delafield', cursive;

    --header-h: 76px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.romance-public {
    margin: 0;
    background: var(--paper);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

.romance-public .eyebrow {
    font-family: var(--font-body);
    font-size: 0.74rem;
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
}

/* ── Header ─────────────────────────────────────────── */
.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--header-h);
    z-index: 500;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 clamp(20px, 4vw, 56px);
    background: oklch(19% 0.035 18 / 0.92);
    backdrop-filter: blur(6px);
    border-bottom: 1px solid var(--ink-line);
}

.site-header .brand {
    font-family: var(--font-display);
    font-size: 1.3rem;
    letter-spacing: 0.1em;
    color: var(--text-on-ink);
    font-weight: 600;
}

.site-header .brand span { color: var(--gold); }

.site-nav {
    display: flex;
    align-items: center;
    gap: clamp(20px, 2.6vw, 40px);
}

.site-nav a:not(.btn-ghost) {
    font-size: 0.86rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: var(--text-on-ink-muted);
    padding: 6px 2px;
    border-bottom: 1px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.site-nav a:not(.btn-ghost):hover {
    color: var(--text-on-ink);
    border-color: var(--gold);
}

a.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-on-ink);
    border: 1px solid var(--ink-line);
    padding: 9px 18px;
    border-radius: 2px;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.btn-ghost:hover { border-color: var(--gold); background: oklch(100% 0 0 / 0.04); }

.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-on-ink);
    font-size: 1.25rem;
    padding: 8px;
    cursor: pointer;
}

.mobile-nav { display: none; }

/* ── Hero ───────────────────────────────────────────── */
.hero {
    position: relative;
    background: var(--ink);
    color: var(--text-on-ink);
    padding-top: calc(var(--header-h) + clamp(56px, 10vw, 112px));
    padding-bottom: clamp(72px, 11vw, 128px);
    padding-left: clamp(20px, 4vw, 56px);
    padding-right: clamp(20px, 4vw, 56px);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 60% 50% at 88% 8%, oklch(71% 0.13 78 / 0.14), transparent 60%),
        repeating-linear-gradient(135deg, oklch(100% 0 0 / 0.015) 0px, oklch(100% 0 0 / 0.015) 1px, transparent 1px, transparent 64px);
    pointer-events: none;
}

.hero-inner {
    position: relative;
    max-width: 660px;
}

.hero .eyebrow { color: var(--gold); margin-bottom: 22px; }

.hero h1 {
    font-family: var(--font-display);
    font-weight: 560;
    font-size: clamp(2.6rem, 2.1rem + 2.6vw, 4.6rem);
    line-height: 1.08;
    letter-spacing: -0.01em;
    margin: 0 0 26px;
}

.hero h1 em {
    font-style: italic;
    color: var(--gold);
}

.hero p.lede {
    font-size: clamp(1rem, 0.94rem + 0.3vw, 1.2rem);
    color: var(--text-on-ink-muted);
    max-width: 46ch;
    margin: 0 0 40px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: clamp(16px, 2vw, 28px);
}

.btn-gold {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--gold);
    color: var(--ink);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 15px 30px;
    border-radius: 2px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.btn-gold:hover { background: var(--text-on-ink); transform: translateY(-1px); }

.link-underline {
    font-size: 0.86rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    color: var(--text-on-ink-muted);
    border-bottom: 1px solid var(--ink-line);
    padding-bottom: 3px;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.link-underline:hover { color: var(--text-on-ink); border-color: var(--gold); }

/* vertical category strip, right edge — asymmetric accent instead of a stock photo */
.hero-sidenote {
    position: absolute;
    right: clamp(18px, 4vw, 64px);
    top: calc(var(--header-h) + 20px);
    bottom: 40px;
    display: flex;
    align-items: flex-end;
}

.hero-sidenote span {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    font-family: var(--font-body);
    font-size: 0.72rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--text-on-ink-muted);
    white-space: nowrap;
}

/* ── Tab switch (Servicios / Paquetes) ─────────────────── */
.tab-switch {
    background: var(--ink-soft);
    border-top: 1px solid var(--ink-line);
    border-bottom: 1px solid var(--ink-line);
    overflow-x: auto;
}

.tab-switch-inner {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 16px clamp(20px, 4vw, 56px);
    min-width: max-content;
    max-width: 1180px;
    margin: 0 auto;
}

.tab-btn {
    padding: 9px 22px;
    border-radius: 20px;
    border: 1.5px solid var(--ink-line);
    background: transparent;
    color: var(--text-on-ink-muted);
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tab-btn:hover { border-color: var(--gold); color: var(--text-on-ink); }
.tab-btn.active { background: var(--gold); border-color: var(--gold); color: var(--ink); }

/* ── Services ───────────────────────────────────────── */
.services {
    padding: clamp(72px, 10vw, 120px) clamp(20px, 4vw, 56px);
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    max-width: 1180px;
    margin: 0 auto clamp(40px, 5vw, 64px);
}

.section-head-main { position: relative; }

.service-flourish {
    position: absolute;
    top: -30px;
    left: -8px;
    width: 84px;
    height: auto;
    color: var(--gold-deep);
    opacity: 0.5;
    pointer-events: none;
}

@media (max-width: 640px) {
    .service-flourish { display: none; }
}

/* One deliberate departure from the site's caps-tracked eyebrow convention —
   a flowing script marks this section as the page's warm, personal moment. */
.section-head .eyebrow {
    font-family: var(--font-script);
    font-size: clamp(1.9rem, 1.5rem + 1.2vw, 2.6rem);
    font-weight: 400;
    text-transform: none;
    letter-spacing: 0;
    color: var(--gold-deep);
    margin-bottom: 2px;
    transform: rotate(-1.5deg);
    transform-origin: left center;
}

.section-head h2 {
    font-family: var(--font-display);
    font-weight: 560;
    font-size: clamp(1.9rem, 1.6rem + 1.3vw, 2.9rem);
    margin: 0;
    max-width: 18ch;
    color: var(--text);
}

.section-head p {
    max-width: 38ch;
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0;
}

.service-grid {
    max-width: 1180px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: clamp(18px, 2.2vw, 28px);
}

.service-grid.service-panel { display: none; }
.service-grid.service-panel.active { display: grid; }

/* Editorial asymmetry: a wide lead item, a tall second item beside it,
   then the rest fall into a tighter 3-up rhythm. Works for any item count. */
.service-card:nth-child(1) { grid-column: span 4; }
.service-card:nth-child(2) { grid-column: span 2; }
.service-card:nth-child(n+3) { grid-column: span 2; }

/* Last row of the 3-up rhythm may be short one or two cards — stretch
   whatever's left instead of leaving the grid's bare background showing.
   Scoped to the desktop 3-up width only: its selectors outrank the tablet
   breakpoint's own 2-up orphan rule by specificity, so left unscoped they'd
   leak through and strand a card there too. */
@media (min-width: 1041px) {
    .service-card:nth-child(3n):last-child { grid-column: span 6; }
    .service-card:nth-child(3n):nth-last-child(2) { grid-column: span 3; }
    .service-card:nth-child(3n+1):last-child:not(:nth-child(1)) { grid-column: span 3; }
}

.service-card:nth-child(1) .swatch { aspect-ratio: 16 / 9; }
.service-card:nth-child(2) .swatch { aspect-ratio: 4 / 5; }

.service-card:nth-child(1) h3 { font-size: clamp(1.6rem, 1.3rem + 1vw, 2.1rem); }

.service-card {
    background: var(--paper);
    border: 1px solid color-mix(in srgb, var(--paper-line) 65%, transparent);
    border-radius: 18px;
    padding: clamp(26px, 2.8vw, 40px);
    display: flex;
    flex-direction: column;
    gap: 18px;
    box-shadow: 0 1px 2px color-mix(in srgb, var(--ink) 6%, transparent);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
                box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1),
                border-color 0.35s ease,
                background 0.35s ease;
    cursor: pointer;
}

.service-card:hover, .service-card:focus-visible {
    background: var(--paper-deep);
    transform: translateY(-5px);
    border-color: color-mix(in srgb, var(--gold-deep) 45%, transparent);
    box-shadow:
        0 1px 2px color-mix(in srgb, var(--ink) 6%, transparent),
        0 22px 40px -18px color-mix(in srgb, var(--gold-deep) 45%, transparent);
}
.service-card:focus-visible { outline: 2px solid var(--gold-deep); outline-offset: 2px; }

.service-card .view-more {
    position: relative;
    display: inline-block;
    width: fit-content;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--gold-deep);
}

.service-card .view-more::after {
    content: '';
    position: absolute;
    left: 0; right: 0; bottom: -3px;
    height: 1px;
    background: currentColor;
    transform: scaleX(0.3);
    transform-origin: center;
    opacity: 0.5;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.service-card:hover .view-more::after,
.service-card:focus-visible .view-more::after {
    transform: scaleX(1);
    opacity: 1;
}

.service-card .swatch {
    width: 100%;
    aspect-ratio: 16 / 10;
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(155deg, var(--swatch-a, #cbb48c), var(--swatch-b, #8a6c4a));
}

/* Warm vignette on photographed swatches only — flat brand-gradient
   placeholders (no image) stay pure so each project's hue reads clean. */
.service-card .swatch:has(img)::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, transparent 45%, color-mix(in srgb, #2b1608 55%, transparent) 120%);
    mix-blend-mode: multiply;
    pointer-events: none;
}

#panel-servicios .service-card:nth-child(3n+2) .swatch { --swatch-a: #d4c4a0; --swatch-b: #8a7048; }
#panel-servicios .service-card:nth-child(3n+3) .swatch { --swatch-a: #b8a078; --swatch-b: #5c4a2e; }
#panel-paquetes .service-card:nth-child(3n+2) .swatch { --swatch-a: #e0c3b0; --swatch-b: #8a5a4a; }
#panel-paquetes .service-card:nth-child(3n+3) .swatch { --swatch-a: #c9a8b8; --swatch-b: #6a3f52; }

.service-card .swatch img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.service-card:hover .swatch img { transform: scale(1.04); }

.service-card h3 {
    font-family: var(--font-display);
    font-weight: 560;
    font-size: 1.3rem;
    margin: 0;
    color: var(--text);
}

.service-card p {
    margin: 0;
    font-size: 0.92rem;
    color: var(--text-muted);
}

.service-card .includes {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid var(--paper-line);
    font-size: 0.8rem;
    letter-spacing: 0.02em;
    color: var(--text-muted);
}

.service-card .includes b { color: var(--text); font-weight: 600; }

/* note banner spanning the full grid width */
.service-note {
    grid-column: 1 / -1;
    background: var(--ink);
    color: var(--text-on-ink-muted);
    border-radius: 18px;
    padding: clamp(26px, 3vw, 36px) clamp(28px, 3vw, 44px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.service-note p {
    margin: 0;
    max-width: 56ch;
    font-size: 0.95rem;
}

.service-note strong { color: var(--text-on-ink); font-weight: 600; }

.empty-state {
    grid-column: 1 / -1;
    padding: 56px 24px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* ── CTA band ───────────────────────────────────────── */
.cta-band {
    background: var(--paper-deep);
    border-top: 1px solid var(--paper-line);
    padding: clamp(64px, 9vw, 104px) clamp(20px, 4vw, 56px);
}

.cta-inner {
    max-width: 1180px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: clamp(32px, 5vw, 64px);
    align-items: start;
}

.cta-inner h2 {
    font-family: var(--font-display);
    font-weight: 560;
    font-size: clamp(2rem, 1.7rem + 1.4vw, 3rem);
    line-height: 1.12;
    margin: 0 0 20px;
    color: var(--text);
}

.cta-inner .lede {
    color: var(--text-muted);
    font-size: 1rem;
    max-width: 48ch;
    margin: 0;
}

.contact-card {
    background: var(--ink);
    color: var(--text-on-ink);
    padding: clamp(28px, 3vw, 40px);
}

.contact-card .eyebrow { color: var(--gold); margin-bottom: 18px; }

.contact-row {
    display: flex;
    align-items: baseline;
    gap: 12px;
    padding: 12px 0;
    border-top: 1px solid var(--ink-line);
    font-size: 0.95rem;
}

.contact-row:first-of-type { border-top: none; }
.contact-row .label { color: var(--text-on-ink-muted); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; flex: 0 0 90px; }

.contact-card .btn-gold { margin-top: 22px; width: 100%; justify-content: center; }

/* ── WhatsApp flotante ──────────────────────────────── */
.whatsapp-float {
    position: fixed;
    right: clamp(16px, 4vw, 28px);
    bottom: clamp(16px, 4vw, 28px);
    width: 58px;
    height: 58px;
    background: #25D366;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
    z-index: 900;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.whatsapp-float:hover {
    transform: scale(1.08);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.34);
    color: #fff;
}

/* ── Footer ─────────────────────────────────────────── */
.site-footer {
    background: var(--ink);
    color: var(--text-on-ink-muted);
    padding: clamp(32px, 4vw, 48px) clamp(20px, 4vw, 56px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    border-top: 1px solid var(--ink-line);
    font-size: 0.82rem;
}

.site-footer .brand {
    font-family: var(--font-display);
    font-size: 1.05rem;
    color: var(--text-on-ink);
    letter-spacing: 0.08em;
}

.site-footer nav { display: flex; gap: 22px; }
.site-footer nav a:hover { color: var(--text-on-ink); }

/* ── Detail modal ───────────────────────────────────── */
.detail-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: clamp(16px, 4vw, 40px);
}

.detail-modal.open { display: flex; }

.detail-modal-backdrop {
    position: absolute;
    inset: 0;
    background: oklch(15% 0.03 18 / 0.72);
    backdrop-filter: blur(2px);
    animation: romance-fade 0.2s ease;
}

.detail-modal-panel {
    position: relative;
    background: var(--paper);
    width: 100%;
    max-width: 560px;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    box-shadow: 0 24px 64px oklch(15% 0.03 18 / 0.35);
    animation: romance-pop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes romance-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes romance-pop { from { opacity: 0; transform: translateY(10px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }

.detail-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: oklch(15% 0.03 18 / 0.45);
    color: #fff;
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
}

.detail-modal-close:hover { background: oklch(15% 0.03 18 / 0.7); }

.detail-modal-media {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: linear-gradient(155deg, var(--gold), var(--gold-deep));
    position: relative;
    overflow: hidden;
}

.detail-modal-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-modal-body {
    padding: clamp(24px, 3vw, 36px);
}

.detail-modal-body .eyebrow {
    color: var(--gold-deep);
    margin-bottom: 10px;
}

.detail-modal-body h3 {
    font-family: var(--font-display);
    font-weight: 560;
    font-size: clamp(1.4rem, 1.2rem + 1vw, 1.9rem);
    margin: 0 0 12px;
    color: var(--text);
}

.detail-modal-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0 0 20px;
}

.detail-modal-list {
    list-style: none;
    margin: 0 0 4px;
    padding: 0;
    border-top: 1px solid var(--paper-line);
}

.detail-modal-list li {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 11px 0;
    border-bottom: 1px solid var(--paper-line);
    font-size: 0.92rem;
}

.detail-modal-list .item-name { color: var(--text); }
.detail-modal-list .item-price { color: var(--text-muted); white-space: nowrap; }

.detail-modal-total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 2px solid var(--text);
    font-family: var(--font-display);
}

.detail-modal-total .label { font-size: 0.95rem; color: var(--text-muted); font-family: var(--font-body); }
.detail-modal-total .value { font-size: 1.3rem; font-weight: 560; color: var(--text); }

/* ── Motion ─────────────────────────────────────────── */
.reveal {
    opacity: 0;
    transform: translateY(14px);
    animation: romance-reveal 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes romance-reveal {
    to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; animation: none; }
}

/* ── Mobile ─────────────────────────────────────────── */
@media (max-width: 860px) {
    .site-nav { display: none; }

    .nav-toggle { display: block; }

    .mobile-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        display: none;
        flex-direction: column;
        background: var(--ink-soft);
        border-bottom: 1px solid var(--ink-line);
        padding: 8px clamp(20px, 4vw, 56px) 18px;
    }

    .mobile-nav.open { display: flex; }

    .mobile-nav a {
        padding: 13px 2px;
        border-top: 1px solid var(--ink-line);
        font-size: 0.95rem;
        color: var(--text-on-ink-muted);
    }

    .mobile-nav a:first-child { border-top: none; }

    .mobile-nav .btn-ghost { margin-top: 14px; justify-content: center; }

    .hero-sidenote { display: none; }

    .service-card,
    .service-card:nth-child(1),
    .service-card:nth-child(2),
    .service-card:nth-child(n+3) { grid-column: 1 / -1; }

    .service-card:nth-child(1) .swatch,
    .service-card:nth-child(2) .swatch { aspect-ratio: 16 / 10; }

    .service-card:nth-child(1) h3 { font-size: 1.4rem; }

    .cta-inner { grid-template-columns: 1fr; }
}

@media (min-width: 861px) and (max-width: 1040px) {
    .service-card:nth-child(1) { grid-column: 1 / -1; }
    .service-card:nth-child(2),
    .service-card:nth-child(n+3) { grid-column: span 3; }
    .service-card:nth-child(1) .swatch { aspect-ratio: 21 / 9; }
    .service-card:nth-child(2) .swatch { aspect-ratio: 16 / 10; }

    /* 2-up rhythm from card 2 onward — stretch a lone trailing card. */
    .service-card:nth-child(even):last-child { grid-column: 1 / -1; }
}

@media (max-width: 480px) {
    .hero { padding-left: 20px; padding-right: 20px; }
    .contact-row { flex-direction: column; gap: 2px; }
    .contact-row .label { flex: none; }
}
