/* ================================================================
   CODEX · cotizacion.css — Configurador estilo Porsche
   Con UI preview animada por módulo
   ================================================================ */

:root {
    --cfg-topbar-h: 58px;
    --cfg-panel-w: 400px;
    --cfg-transition: cubic-bezier(0.22, 1, 0.36, 1);
}

[data-theme="dark"] {
    --cfg-preview-bg: #0a0a0c;
}

.configurator-page {
    background: var(--bg);
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* ================================================================
   TOP BAR
   ================================================================ */
.cfg-topbar {
    height: var(--cfg-topbar-h);
    background: var(--hdr-bg, rgba(250, 250, 250, 0.95));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    gap: 1rem;
    flex-shrink: 0;
    z-index: 100;
    transition: background .4s ease;
}

.cfg-topbar-left {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.cfg-topbar-right {
    display: flex;
    align-items: center;
    gap: .75rem;
}

.cfg-back {
    display: flex;
    align-items: center;
    gap: .4rem;
    font-size: .82rem;
    color: var(--ink-2, #6e6e73);
    text-decoration: none;
    padding: .3rem .6rem;
    border-radius: 6px;
    transition: color .15s, background .15s;
}

.cfg-back:hover {
    color: var(--ink, #1d1d1f);
    background: var(--bg-2, #f5f5f7);
}

.cfg-topbar-title {
    display: flex;
    align-items: center;
    gap: .75rem;
}

.cfg-logo {
    height: 28px;
    width: auto;
}

.cfg-title-sep {
    color: var(--line, #d2d2d7);
    font-size: 1.2rem;
    font-weight: 200;
}

.cfg-title-text {
    font-size: .84rem;
    font-weight: 500;
    color: var(--ink-2, #6e6e73);
}

.cfg-price-display {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    margin-right: .25rem;
}

.cfg-price-amount {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    letter-spacing: -.02em;
    line-height: 1;
    transition: color .3s, transform .2s;
}

.cfg-price-label {
    font-size: .68rem;
    color: var(--ink-3, #aeaeb2);
    text-transform: uppercase;
    letter-spacing: .06em;
}

.cfg-btn-summary {
    display: flex;
    align-items: center;
    gap: .35rem;
    padding: .38rem 1rem;
    border-radius: 6px;
    border: 1px solid var(--line, #d2d2d7);
    background: transparent;
    color: var(--ink-2, #6e6e73);
    font-size: .82rem;
    font-weight: 500;
    cursor: pointer;
    transition: all .2s;
}

.cfg-btn-summary:hover {
    border-color: var(--primary, #3d0022);
    color: var(--primary, #3d0022);
}

.cfg-btn-contact {
    padding: .42rem 1.25rem;
    border-radius: 6px;
    border: 1.5px solid var(--ink, #1d1d1f);
    background: transparent;
    color: var(--ink, #1d1d1f);
    font-size: .82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

.cfg-btn-contact:hover {
    background: var(--ink, #1d1d1f);
    color: var(--bg, #fafafa);
}

.theme-toggle {
    width: 34px;
    height: 34px;
    border: none;
    background: none;
    border-radius: 50%;
    color: var(--ink-2, #6e6e73);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 7px;
    transition: background .15s, transform .3s;
}

.theme-toggle:hover {
    background: var(--bg-2, #f5f5f7);
    transform: rotate(20deg);
}

.theme-icon {
    width: 100%;
    height: 100%;
    stroke: currentColor;
}

/* ================================================================
   LAYOUT
   ================================================================ */
.cfg-layout {
    display: flex;
    flex: 1;
    overflow: hidden;
    height: calc(100vh - var(--cfg-topbar-h));
}

/* ================================================================
   PREVIEW — columna izquierda (el "carro" de Porsche)
   ================================================================ */
.cfg-preview {
    flex: 1;
    background: var(--cfg-preview-bg, #f0f0f2);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    transition: background .6s ease;
}

/* ── Stage donde viven los dashboards animados ── */
.cfg-preview-stage {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 2rem 2.5rem 1rem;
}

/* Empty state */
.cfg-stage-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    text-align: center;
    color: var(--ink-3, #aeaeb2);
    animation: fadeUp .5s ease both;
}

.cfg-stage-empty-orb {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--line-2, #e8e8ed), var(--bg-card, #fff));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, .06);
}

.cfg-stage-empty-orb svg {
    stroke: var(--ink-3, #aeaeb2);
}

.cfg-stage-empty h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ink-2, #6e6e73);
    margin-bottom: .25rem;
}

.cfg-stage-empty p {
    font-size: .84rem;
    line-height: 1.6;
    max-width: 220px;
}

/* ── Dashboard frames — cada módulo tiene el suyo ── */
.cfg-dashboard {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 2.5rem 1rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity .55s cubic-bezier(0.22, 1, 0.36, 1);
}

.cfg-dashboard.active {
    opacity: 1;
    pointer-events: auto;
}

/* Browser chrome wrapper */
.cfg-browser {
    width: 100%;
    max-width: 680px;
    background: var(--bg-card, #fff);
    border-radius: 12px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .14), 0 4px 16px rgba(0, 0, 0, .06);
    overflow: hidden;
    transition: background .4s;
}

.cfg-browser-bar {
    height: 36px;
    background: var(--bg-2, #f5f5f7);
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    display: flex;
    align-items: center;
    padding: 0 .85rem;
    gap: .5rem;
    flex-shrink: 0;
}

.cfg-browser-dots {
    display: flex;
    gap: .35rem;
}

.cfg-browser-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.cfg-browser-dot:nth-child(1) {
    background: #ff5f56;
}

.cfg-browser-dot:nth-child(2) {
    background: #ffbd2e;
}

.cfg-browser-dot:nth-child(3) {
    background: #27c93f;
}

.cfg-browser-url {
    flex: 1;
    height: 20px;
    background: var(--bg-card, #fff);
    border-radius: 4px;
    margin: 0 .75rem;
    display: flex;
    align-items: center;
    padding: 0 .5rem;
    font-size: .65rem;
    color: var(--ink-3, #aeaeb2);
    border: 1px solid var(--line-2, #e8e8ed);
}

.cfg-browser-content {
    position: relative;
    overflow: hidden;
}

/* ================================================================
   DASHBOARD — RESTAURANT
   ================================================================ */
.dash-restaurant {
    display: grid;
    grid-template-columns: 180px 1fr;
    height: 340px;
    font-size: 11px;
}

/* Sidebar */
.dash-sidebar {
    background: var(--primary, #3d0022);
    padding: .85rem .6rem;
    display: flex;
    flex-direction: column;
    gap: .3rem;
}

.dash-sidebar-logo {
    color: rgba(255, 255, 255, .9);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .06em;
    padding: .3rem .5rem .7rem;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
    margin-bottom: .3rem;
}

.dash-nav-item {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .45rem .6rem;
    border-radius: 6px;
    color: rgba(255, 255, 255, .55);
    font-size: .72rem;
    cursor: default;
    transition: background .2s, color .2s;
}

.dash-nav-item.active {
    background: rgba(255, 255, 255, .12);
    color: rgba(255, 255, 255, .95);
}

.dash-nav-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor;
    flex-shrink: 0;
}

/* Main area */
.dash-main {
    background: var(--bg, #fafafa);
    padding: .85rem;
    overflow: hidden;
}

.dash-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: .75rem;
}

.dash-title {
    font-size: .82rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

.dash-badge {
    font-size: .65rem;
    background: var(--primary, #3d0022);
    color: white;
    padding: .15rem .45rem;
    border-radius: 99px;
}

/* KPIs */
.dash-kpis {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: .5rem;
    margin-bottom: .75rem;
}

.dash-kpi {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .55rem .6rem;
}

.dash-kpi-val {
    font-size: .95rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    letter-spacing: -.02em;
    line-height: 1;
}

.dash-kpi-lbl {
    font-size: .62rem;
    color: var(--ink-3, #aeaeb2);
    margin-top: .15rem;
}

/* Mesas grid */
.dash-tables-label {
    font-size: .68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--ink-3, #aeaeb2);
    margin-bottom: .4rem;
}

.dash-tables {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: .4rem;
}

.dash-table {
    aspect-ratio: 1;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-size: .6rem;
    font-weight: 600;
    cursor: default;
    border: 1.5px solid transparent;
    transition: transform .3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dash-table:hover {
    transform: scale(1.08);
}

.dash-table.libre {
    background: #e8f5e9;
    color: #2e7d32;
    border-color: #c8e6c9;
}

.dash-table.ocupada {
    background: #fff3e0;
    color: #e65100;
    border-color: #ffe0b2;
}

.dash-table.pedido {
    background: #e3f2fd;
    color: #1565c0;
    border-color: #bbdefb;
}

.dash-table.pago {
    background: var(--primary-glow, rgba(61, 0, 34, .08));
    color: var(--primary, #3d0022);
    border-color: var(--primary, #3d0022);
}

.dash-table-num {
    font-size: .75rem;
    font-weight: 700;
}

/* Live ticker */
.dash-ticker {
    margin-top: .6rem;
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .5rem .65rem;
    display: flex;
    align-items: center;
    gap: .5rem;
}

.dash-ticker-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #27c93f;
    animation: pulse 1.5s infinite;
    flex-shrink: 0;
}

.dash-ticker-text {
    font-size: .68rem;
    color: var(--ink-2, #6e6e73);
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
}

.dash-ticker-time {
    font-size: .62rem;
    color: var(--ink-3, #aeaeb2);
}

/* ================================================================
   DASHBOARD — PARKING
   ================================================================ */
.dash-parking {
    height: 340px;
    background: var(--bg, #fafafa);
    padding: .85rem;
    display: flex;
    flex-direction: column;
    gap: .65rem;
}

.dash-parking-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dash-parking-title {
    font-size: .84rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

.dash-parking-live {
    display: flex;
    align-items: center;
    gap: .35rem;
    font-size: .68rem;
    color: #27c93f;
    font-weight: 600;
}

.dash-parking-live span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #27c93f;
    animation: pulse 1.5s infinite;
}

.dash-parking-kpis {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .5rem;
}

.dash-parking-kpi {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .55rem .6rem;
}

.dash-parking-kpi-val {
    font-size: .9rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

.dash-parking-kpi-lbl {
    font-size: .6rem;
    color: var(--ink-3, #aeaeb2);
}

/* Planta del parking */
.dash-parking-map {
    flex: 1;
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .6rem;
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: .3rem;
    align-content: start;
}

.dash-spot {
    height: 28px;
    border-radius: 4px;
    border: 1.5px solid transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .55rem;
    font-weight: 600;
    transition: transform .25s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: default;
}

.dash-spot:hover {
    transform: scale(1.12);
}

.dash-spot.libre {
    background: #e8f5e9;
    border-color: #c8e6c9;
    color: #2e7d32;
}

.dash-spot.ocupado {
    background: #ffebee;
    border-color: #ffcdd2;
    color: #c62828;
}

.dash-spot.reservado {
    background: #e3f2fd;
    border-color: #bbdefb;
    color: #1565c0;
}

.dash-spot.entrada {
    background: var(--primary, #3d0022);
    color: white;
    border-color: transparent;
    font-size: .5rem;
    grid-column: span 2;
}

.dash-parking-entry {
    display: flex;
    gap: .5rem;
}

.dash-entry-row {
    flex: 1;
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .5rem .75rem;
    display: flex;
    align-items: center;
    gap: .5rem;
}

.dash-entry-plate {
    background: var(--ink, #1d1d1f);
    color: white;
    font-size: .68rem;
    font-weight: 700;
    padding: .2rem .45rem;
    border-radius: 4px;
    letter-spacing: .05em;
}

.dash-entry-info {
    flex: 1;
}

.dash-entry-time {
    font-size: .68rem;
    color: var(--ink-2, #6e6e73);
}

.dash-entry-cost {
    font-size: .72rem;
    font-weight: 700;
    color: var(--primary, #3d0022);
}

/* ================================================================
   DASHBOARD — HOTEL
   ================================================================ */
.dash-hotel {
    display: grid;
    grid-template-columns: 160px 1fr;
    height: 340px;
    font-size: 11px;
}

.dash-hotel-sidebar {
    background: linear-gradient(160deg, #1a000d 0%, #3d0022 100%);
    padding: .75rem .6rem;
    display: flex;
    flex-direction: column;
    gap: .4rem;
}

.dash-hotel-logo {
    color: rgba(255, 255, 255, .9);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    padding: .2rem .4rem .65rem;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
    margin-bottom: .3rem;
}

.dash-hotel-room {
    border-radius: 6px;
    padding: .45rem .55rem;
    background: rgba(255, 255, 255, .07);
    margin-bottom: .2rem;
    cursor: default;
}

.dash-hotel-room.occupied {
    background: rgba(255, 255, 255, .14);
}

.dash-room-num {
    font-size: .7rem;
    font-weight: 700;
    color: rgba(255, 255, 255, .9);
}

.dash-room-guest {
    font-size: .6rem;
    color: rgba(255, 255, 255, .5);
}

.dash-room-status {
    display: inline-block;
    font-size: .55rem;
    font-weight: 600;
    padding: .1rem .4rem;
    border-radius: 99px;
    margin-top: .15rem;
}

.dash-room-status.occ {
    background: rgba(255, 189, 46, .2);
    color: #ffbd2e;
}

.dash-room-status.free {
    background: rgba(39, 201, 63, .2);
    color: #27c93f;
}

.dash-room-status.check {
    background: rgba(194, 71, 110, .3);
    color: #f090b0;
}

.dash-hotel-main {
    background: var(--bg, #fafafa);
    padding: .85rem;
}

.dash-hotel-kpis {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: .5rem;
    margin-bottom: .65rem;
}

/* Ocupación bar chart animado */
.dash-occ-label {
    font-size: .68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--ink-3, #aeaeb2);
    margin-bottom: .4rem;
}

.dash-occ-bars {
    display: flex;
    align-items: flex-end;
    gap: .35rem;
    height: 70px;
}

.dash-occ-bar-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .2rem;
}

.dash-occ-bar {
    width: 100%;
    border-radius: 3px 3px 0 0;
    background: linear-gradient(to top, var(--primary, #3d0022), var(--accent, #c2476e));
    transform-origin: bottom;
    animation: barGrow .8s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes barGrow {
    from {
        transform: scaleY(0)
    }

    to {
        transform: scaleY(1)
    }
}

.dash-occ-day {
    font-size: .55rem;
    color: var(--ink-3, #aeaeb2);
}

.dash-hotel-checkins {
    margin-top: .65rem;
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .5rem .65rem;
}

.dash-checkin-title {
    font-size: .68rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
    margin-bottom: .35rem;
}

.dash-checkin-row {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .3rem 0;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
}

.dash-checkin-row:last-child {
    border-bottom: none;
}

.dash-checkin-avatar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .6rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

.dash-checkin-name {
    flex: 1;
    font-size: .68rem;
    color: var(--ink, #1d1d1f);
}

.dash-checkin-room {
    font-size: .65rem;
    color: var(--ink-2, #6e6e73);
}

.dash-checkin-badge {
    font-size: .6rem;
    padding: .1rem .4rem;
    border-radius: 99px;
    font-weight: 600;
}

.dash-checkin-badge.in {
    background: #e8f5e9;
    color: #2e7d32;
}

.dash-checkin-badge.out {
    background: #fff3e0;
    color: #e65100;
}

/* ================================================================
   DASHBOARD — RETAIL / POS
   ================================================================ */
.dash-retail {
    height: 340px;
    background: var(--bg, #fafafa);
    padding: .85rem;
    display: flex;
    gap: .65rem;
}

.dash-retail-left {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.dash-retail-right {
    width: 160px;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.dash-pos-search {
    display: flex;
    align-items: center;
    gap: .4rem;
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 7px;
    padding: .4rem .6rem;
    font-size: .7rem;
    color: var(--ink-3, #aeaeb2);
}

.dash-products {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .4rem;
    flex: 1;
}

.dash-product {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .5rem;
    display: flex;
    flex-direction: column;
    gap: .2rem;
    cursor: default;
    transition: border-color .2s, transform .25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dash-product:hover {
    border-color: var(--primary, #3d0022);
    transform: translateY(-2px);
}

.dash-product-icon {
    font-size: 1.1rem;
}

.dash-product-name {
    font-size: .6rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
    line-height: 1.2;
}

.dash-product-price {
    font-size: .65rem;
    color: var(--primary, #3d0022);
    font-weight: 700;
}

/* Ticket */
.dash-ticket {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .6rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.dash-ticket-title {
    font-size: .7rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    margin-bottom: .4rem;
    border-bottom: 1px dashed var(--line-2, #e8e8ed);
    padding-bottom: .35rem;
}

.dash-ticket-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: .65rem;
    padding: .2rem 0;
    animation: fadeUp .3s ease both;
}

.dash-ticket-row-name {
    color: var(--ink-2, #6e6e73);
}

.dash-ticket-row-price {
    font-weight: 600;
    color: var(--ink, #1d1d1f);
}

.dash-ticket-total {
    border-top: 1.5px solid var(--line, #d2d2d7);
    margin-top: .35rem;
    padding-top: .35rem;
    display: flex;
    justify-content: space-between;
    font-size: .78rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

.dash-ticket-btn {
    margin-top: .4rem;
    background: var(--primary, #3d0022);
    color: white;
    border: none;
    border-radius: 6px;
    padding: .4rem;
    font-size: .68rem;
    font-weight: 600;
    width: 100%;
    cursor: default;
    animation: pulse 2s infinite;
}

/* ================================================================
   DASHBOARD — FARMACIA
   ================================================================ */
.dash-farma {
    height: 340px;
    background: var(--bg, #fafafa);
    padding: .85rem;
    display: flex;
    flex-direction: column;
    gap: .6rem;
}

.dash-farma-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dash-farma-kpis {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .5rem;
}

.dash-farma-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .5rem;
    flex: 1;
}

.dash-farma-alerts {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .55rem .65rem;
    overflow: hidden;
}

.dash-farma-alerts-title {
    font-size: .68rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    margin-bottom: .4rem;
}

.dash-alert-row {
    display: flex;
    align-items: center;
    gap: .4rem;
    padding: .3rem 0;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    font-size: .65rem;
}

.dash-alert-row:last-child {
    border-bottom: none;
}

.dash-alert-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    flex-shrink: 0;
}

.dash-alert-dot.red {
    background: #ef4444;
    animation: pulse 1.2s infinite;
}

.dash-alert-dot.orange {
    background: #f97316;
}

.dash-alert-dot.green {
    background: #22c55e;
}

.dash-alert-name {
    flex: 1;
    color: var(--ink, #1d1d1f);
}

.dash-alert-qty {
    color: var(--ink-3, #aeaeb2);
}

.dash-farma-recetas {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .55rem .65rem;
}

.dash-receta-row {
    display: flex;
    align-items: center;
    gap: .4rem;
    padding: .3rem 0;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
}

.dash-receta-row:last-child {
    border-bottom: none;
}

.dash-receta-avatar {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary-glow, rgba(61, 0, 34, .1));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .55rem;
    font-weight: 700;
    color: var(--primary, #3d0022);
    flex-shrink: 0;
}

.dash-receta-info {
    flex: 1;
}

.dash-receta-name {
    font-size: .65rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
}

.dash-receta-med {
    font-size: .6rem;
    color: var(--ink-2, #6e6e73);
}

.dash-receta-badge {
    font-size: .58rem;
    padding: .1rem .35rem;
    border-radius: 99px;
    font-weight: 600;
}

.dash-receta-badge.ok {
    background: #e8f5e9;
    color: #2e7d32;
}

.dash-receta-badge.pend {
    background: #fff3e0;
    color: #e65100;
}

/* ================================================================
   DASHBOARD — VET
   ================================================================ */
.dash-vet {
    height: 340px;
    background: var(--bg, #fafafa);
    padding: .85rem;
    display: flex;
    gap: .65rem;
}

.dash-vet-left {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.dash-vet-right {
    width: 155px;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.dash-vet-agenda {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .55rem .65rem;
    flex: 1;
}

.dash-vet-agenda-title {
    font-size: .68rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    margin-bottom: .4rem;
}

.dash-cita-row {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .32rem 0;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
}

.dash-cita-row:last-child {
    border-bottom: none;
}

.dash-cita-time {
    font-size: .62rem;
    font-weight: 700;
    color: var(--ink-2, #6e6e73);
    width: 28px;
    flex-shrink: 0;
}

.dash-cita-bar {
    width: 3px;
    height: 24px;
    border-radius: 99px;
    flex-shrink: 0;
}

.dash-cita-info {
    flex: 1;
}

.dash-cita-pet {
    font-size: .68rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
}

.dash-cita-owner {
    font-size: .6rem;
    color: var(--ink-2, #6e6e73);
}

.dash-cita-type {
    font-size: .58rem;
    padding: .1rem .35rem;
    border-radius: 99px;
    font-weight: 600;
    background: var(--primary-glow, rgba(61, 0, 34, .08));
    color: var(--primary, #3d0022);
}

.dash-vet-patient {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .55rem .65rem;
}

.dash-vet-patient-title {
    font-size: .68rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    margin-bottom: .35rem;
}

.dash-pet-card {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .4rem;
    background: var(--bg-2, #f5f5f7);
    border-radius: 7px;
    margin-bottom: .35rem;
}

.dash-pet-icon {
    font-size: 1.2rem;
}

.dash-pet-name {
    font-size: .68rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

.dash-pet-breed {
    font-size: .6rem;
    color: var(--ink-2, #6e6e73);
}

.dash-vac-bar-wrap {
    margin-top: .3rem;
}

.dash-vac-label {
    display: flex;
    justify-content: space-between;
    font-size: .6rem;
    color: var(--ink-2, #6e6e73);
    margin-bottom: .2rem;
}

.dash-vac-track {
    height: 4px;
    background: var(--line-2, #e8e8ed);
    border-radius: 99px;
    overflow: hidden;
}

.dash-vac-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary, #3d0022), var(--accent, #c2476e));
    border-radius: 99px;
    animation: barGrow .9s ease both;
}

/* ================================================================
   SHARED KPI styles
   ================================================================ */
.dash-kpi,
.dash-parking-kpi,
.dash-hotel-kpi,
.dash-farma-kpi {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .5rem .6rem;
}

.dash-hotel-kpi-val,
.dash-farma-kpi-val {
    font-size: .88rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

.dash-hotel-kpi-lbl,
.dash-farma-kpi-lbl {
    font-size: .6rem;
    color: var(--ink-3, #aeaeb2);
}

/* ── Module label overlay ── */
.cfg-module-label {
    position: absolute;
    bottom: .75rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, .55);
    backdrop-filter: blur(8px);
    color: white;
    font-size: .75rem;
    font-weight: 600;
    padding: .32rem .9rem;
    border-radius: 99px;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity .3s;
    letter-spacing: .02em;
}

.cfg-dashboard.active .cfg-module-label {
    opacity: 1;
}

/* ================================================================
   THUMBNAILS
   ================================================================ */
.cfg-preview-thumbs {
    padding: .65rem 1.25rem;
    border-top: 1px solid var(--line-2, #e8e8ed);
    display: flex;
    gap: .5rem;
    align-items: center;
    background: var(--bg-card, #fff);
    min-height: 62px;
    transition: background .4s;
    overflow-x: auto;
}

.cfg-preview-thumbs::-webkit-scrollbar {
    display: none;
}

.cfg-thumbs-empty {
    font-size: .78rem;
    color: var(--ink-3, #aeaeb2);
}

.cfg-thumb {
    width: 46px;
    height: 46px;
    border-radius: 10px;
    background: var(--bg-2, #f5f5f7);
    border: 2px solid transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    position: relative;
    transition: border-color .2s, transform .3s cubic-bezier(0.34, 1.56, 0.64, 1), background .2s;
}

.cfg-thumb:hover {
    transform: scale(1.1);
    background: var(--line-2, #e8e8ed);
}

.cfg-thumb.active {
    border-color: var(--primary, #3d0022);
    background: var(--primary-glow, rgba(61, 0, 34, .08));
}

.cfg-thumb svg {
    width: 20px;
    height: 20px;
    stroke: var(--primary, #3d0022);
}

.cfg-thumb-remove {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--ink, #1d1d1f);
    color: white;
    font-size: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: opacity .15s;
    border: none;
    line-height: 1;
}

.cfg-thumb:hover .cfg-thumb-remove {
    opacity: 1;
}

/* ================================================================
   STEPS BAR
   ================================================================ */
.cfg-steps-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: .65rem 1.5rem;
    background: var(--bg-card, #fff);
    border-top: 1px solid var(--line-2, #e8e8ed);
    gap: 0;
    transition: background .4s;
}

.cfg-step {
    display: flex;
    align-items: center;
    gap: .4rem;
    font-size: .75rem;
    color: var(--ink-3, #aeaeb2);
    transition: color .3s;
}

.cfg-step.active {
    color: var(--primary, #3d0022);
}

.cfg-step.done {
    color: var(--ink-2, #6e6e73);
}

.cfg-step-num {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1.5px solid currentColor;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .7rem;
    font-weight: 600;
    flex-shrink: 0;
    transition: background .3s, color .3s;
}

.cfg-step.active .cfg-step-num {
    background: var(--primary, #3d0022);
    color: white;
    border-color: transparent;
}

.cfg-step.done .cfg-step-num {
    background: var(--ink-2, #6e6e73);
    color: white;
    border-color: transparent;
}

.cfg-step-lbl {
    font-weight: 500;
}

.cfg-step-line {
    flex: 1;
    min-width: 20px;
    height: 1px;
    background: var(--line-2, #e8e8ed);
    margin: 0 .5rem;
    transition: background .3s;
}

.cfg-step-line.done {
    background: var(--ink-2, #6e6e73);
}

/* ================================================================
   PANEL DERECHO
   ================================================================ */
.cfg-panel {
    width: var(--cfg-panel-w);
    flex-shrink: 0;
    background: var(--bg-card, #fff);
    border-left: 1px solid var(--line-2, #e8e8ed);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: background .4s, border-color .3s;
}

.cfg-pane {
    display: none;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
}

.cfg-pane.active {
    display: flex;
    animation: cfgPaneIn .35s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes cfgPaneIn {
    from {
        opacity: 0;
        transform: translateX(12px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.cfg-pane-header {
    padding: 1.75rem 1.75rem 1rem;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    flex-shrink: 0;
}

.cfg-pane-header h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    letter-spacing: -.02em;
    margin-bottom: .2rem;
}

.cfg-pane-header p {
    font-size: .82rem;
    color: var(--ink-2, #6e6e73);
}

/* Search */
.cfg-search {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin: .75rem 1.25rem;
    padding: .55rem .85rem;
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    background: var(--bg-2, #f5f5f7);
    transition: border-color .2s;
    flex-shrink: 0;
}

.cfg-search:focus-within {
    border-color: var(--primary, #3d0022);
}

.cfg-search svg {
    stroke: var(--ink-3, #aeaeb2);
    flex-shrink: 0;
}

.cfg-search input {
    flex: 1;
    border: none;
    background: transparent;
    font-size: .84rem;
    color: var(--ink, #1d1d1f);
    outline: none;
}

.cfg-search input::placeholder {
    color: var(--ink-3, #aeaeb2);
}

/* Filters */
.cfg-filters {
    display: flex;
    gap: .35rem;
    padding: 0 1.25rem .75rem;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.cfg-filter {
    padding: .26rem .75rem;
    border-radius: 99px;
    border: 1px solid var(--line-2, #e8e8ed);
    background: transparent;
    color: var(--ink-2, #6e6e73);
    font-size: .76rem;
    font-weight: 500;
    cursor: pointer;
    transition: all .18s;
    white-space: nowrap;
}

.cfg-filter:hover {
    border-color: var(--primary, #3d0022);
    color: var(--primary, #3d0022);
}

.cfg-filter.active {
    background: var(--primary, #3d0022);
    border-color: var(--primary, #3d0022);
    color: white;
}

/* Module list */
.cfg-module-list {
    flex: 1;
    overflow-y: auto;
    padding: .25rem 0;
}

.cfg-module-list::-webkit-scrollbar {
    width: 4px;
}

.cfg-module-list::-webkit-scrollbar-thumb {
    background: var(--line-2, #e8e8ed);
    border-radius: 4px;
}

.cfg-module-row {
    display: flex;
    align-items: center;
    gap: .9rem;
    padding: .85rem 1.5rem;
    cursor: pointer;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    transition: background .2s;
    position: relative;
}

.cfg-module-row:last-child {
    border-bottom: none;
}

.cfg-module-row:hover {
    background: var(--bg-2, #f5f5f7);
}

.cfg-module-row.hidden {
    display: none;
}

.cfg-module-row.selected {
    background: var(--primary-glow, rgba(61, 0, 34, .05));
}

.cfg-module-row.selected::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--primary, #3d0022);
    border-radius: 0 3px 3px 0;
}

.cfg-module-row.preview-hover {
    background: var(--bg-2, #f5f5f7);
}

.cfg-module-row-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--primary-glow, rgba(61, 0, 34, .08));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background .25s;
}

.cfg-module-row.selected .cfg-module-row-icon,
.cfg-module-row:hover .cfg-module-row-icon {
    background: var(--primary, #3d0022);
}

.cfg-module-row-icon svg {
    stroke: var(--primary, #3d0022);
    transition: stroke .25s;
}

.cfg-module-row.selected .cfg-module-row-icon svg,
.cfg-module-row:hover .cfg-module-row-icon svg {
    stroke: white;
}

.cfg-module-row-info {
    flex: 1;
    min-width: 0;
}

.cfg-module-row-name {
    font-size: .88rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
    margin-bottom: .1rem;
}

.cfg-module-row-desc {
    font-size: .74rem;
    color: var(--ink-2, #6e6e73);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cfg-module-row-price {
    font-size: .84rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    white-space: nowrap;
    flex-shrink: 0;
}

.cfg-module-row-check {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 1.5px solid var(--line, #d2d2d7);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 10px;
    color: transparent;
    transition: all .2s;
}

.cfg-module-row.selected .cfg-module-row-check {
    background: var(--primary, #3d0022);
    border-color: var(--primary, #3d0022);
    color: white;
}

/* Custom CTA */
.cfg-custom-cta {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .85rem 1.25rem;
    border-top: 1px solid var(--line-2, #e8e8ed);
    background: var(--bg-2, #f5f5f7);
    flex-shrink: 0;
}

.cfg-custom-cta-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--primary-glow, rgba(61, 0, 34, .08));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cfg-custom-cta-icon svg {
    stroke: var(--primary, #3d0022);
}

.cfg-custom-cta-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: .1rem;
}

.cfg-custom-cta-text strong {
    font-size: .82rem;
    color: var(--ink, #1d1d1f);
}

.cfg-custom-cta-text span {
    font-size: .74rem;
    color: var(--ink-2, #6e6e73);
}

.cfg-custom-btn {
    padding: .32rem .85rem;
    border-radius: 6px;
    border: 1px solid var(--primary, #3d0022);
    background: transparent;
    color: var(--primary, #3d0022);
    font-size: .78rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
    white-space: nowrap;
}

.cfg-custom-btn:hover {
    background: var(--primary, #3d0022);
    color: white;
}

/* Pane footer */
.cfg-pane-footer {
    padding: 1.25rem 1.5rem;
    border-top: 1px solid var(--line-2, #e8e8ed);
    flex-shrink: 0;
}

.cfg-pane-footer--2col {
    display: flex;
    gap: .75rem;
}

/* Buttons */
.cfg-btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    width: 100%;
    padding: .75rem 1.5rem;
    border-radius: 8px;
    background: var(--ink, #1d1d1f);
    color: white;
    font-size: .88rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: opacity .2s, transform .25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cfg-btn-primary:hover:not(:disabled) {
    opacity: .88;
    transform: translateY(-1px);
}

.cfg-btn-primary:disabled {
    opacity: .35;
    cursor: not-allowed;
}

.cfg-btn-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    padding: .75rem 1.25rem;
    border-radius: 8px;
    border: 1px solid var(--line, #d2d2d7);
    background: transparent;
    color: var(--ink-2, #6e6e73);
    font-size: .88rem;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    transition: border-color .2s, color .2s;
}

.cfg-btn-secondary:hover {
    border-color: var(--ink-2, #6e6e73);
    color: var(--ink, #1d1d1f);
}

.cfg-btn-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    flex: 1;
    padding: .75rem 1.5rem;
    border-radius: 8px;
    background: var(--primary, #3d0022);
    color: white;
    font-size: .88rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: opacity .2s, transform .25s;
}

.cfg-btn-submit:hover {
    opacity: .88;
    transform: translateY(-1px);
}

.cfg-btn-submit:disabled {
    opacity: .4;
    cursor: not-allowed;
}

/* ================================================================
   ADD-ONS — paso 2
   ================================================================ */
.cfg-module-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    padding: 0 1.25rem;
    overflow-x: auto;
    flex-shrink: 0;
}

.cfg-module-tabs::-webkit-scrollbar {
    display: none;
}

.cfg-module-tab {
    padding: .75rem 1rem;
    font-size: .82rem;
    font-weight: 500;
    color: var(--ink-2, #6e6e73);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
    transition: color .2s, border-color .2s;
    background: none;
    border-top: none;
    border-left: none;
    border-right: none;
}

.cfg-module-tab:hover {
    color: var(--ink, #1d1d1f);
}

.cfg-module-tab.active {
    color: var(--primary, #3d0022);
    border-bottom-color: var(--primary, #3d0022);
}

.cfg-addon-sections {
    flex: 1;
    overflow-y: auto;
    padding: .5rem 0;
}

.cfg-addon-sections::-webkit-scrollbar {
    width: 4px;
}

.cfg-addon-sections::-webkit-scrollbar-thumb {
    background: var(--line-2);
    border-radius: 4px;
}

.cfg-addon-tab-content {
    display: none;
}

.cfg-addon-tab-content.active {
    display: block;
    animation: cfgPaneIn .3s ease both;
}

.cfg-addon-section-header {
    padding: 1rem 1.5rem .5rem;
    font-size: .7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--ink-3, #aeaeb2);
    border-bottom: 1px solid var(--line-2, #e8e8ed);
}

.cfg-addon-row {
    display: flex;
    align-items: center;
    gap: .85rem;
    padding: .85rem 1.5rem;
    cursor: pointer;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    transition: background .2s;
}

.cfg-addon-row:last-child {
    border-bottom: none;
}

.cfg-addon-row:hover {
    background: var(--bg-2, #f5f5f7);
}

.cfg-addon-row.selected {
    background: var(--primary-glow, rgba(61, 0, 34, .05));
}

.cfg-addon-check {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 1.5px solid var(--line, #d2d2d7);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 10px;
    color: transparent;
    transition: all .2s;
}

.cfg-addon-row.selected .cfg-addon-check {
    background: var(--primary, #3d0022);
    border-color: var(--primary, #3d0022);
    color: white;
}

.cfg-addon-info {
    flex: 1;
}

.cfg-addon-name {
    font-size: .87rem;
    font-weight: 500;
    color: var(--ink, #1d1d1f);
    margin-bottom: .1rem;
}

.cfg-addon-desc {
    font-size: .76rem;
    color: var(--ink-2, #6e6e73);
}

.cfg-addon-price {
    font-size: .84rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
    white-space: nowrap;
}

.cfg-addon-no-addons {
    padding: 1.5rem;
    font-size: .84rem;
    color: var(--ink-3, #aeaeb2);
    font-style: italic;
    text-align: center;
}

/* ================================================================
   FORM — paso 3
   ================================================================ */
.cfg-form {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cfg-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.cfg-field {
    display: flex;
    flex-direction: column;
    gap: .35rem;
}

.cfg-field--full {
    grid-column: 1 / -1;
}

.cfg-field label {
    font-size: .78rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
}

.cfg-field input,
.cfg-field textarea {
    padding: .6rem .8rem;
    border: 1.5px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    background: var(--bg-card, #fff);
    color: var(--ink, #1d1d1f);
    font-size: .86rem;
    font-family: inherit;
    outline: none;
    transition: border-color .2s;
    resize: vertical;
}

.cfg-field input:focus,
.cfg-field textarea:focus {
    border-color: var(--primary, #3d0022);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.cfg-field input.error {
    border-color: #e5484d;
}

.cfg-field-error {
    font-size: .74rem;
    color: #e5484d;
    min-height: .9rem;
}

/* ================================================================
   RESUMEN — paso 4
   ================================================================ */
#quoteSummaryContent {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem 1.5rem;
}

#quoteSummaryContent::-webkit-scrollbar {
    width: 4px;
}

#quoteSummaryContent::-webkit-scrollbar-thumb {
    background: var(--line-2);
    border-radius: 4px;
}

.cfg-summary-block {
    margin-bottom: 1.5rem;
}

.cfg-summary-block h4 {
    font-size: .7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--ink-3);
    margin-bottom: .75rem;
}

.cfg-summary-line {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: .65rem 0;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    gap: 1rem;
}

.cfg-summary-line:last-child {
    border-bottom: none;
}

.cfg-summary-line-left {
    flex: 1;
}

.cfg-summary-line-name {
    font-size: .88rem;
    font-weight: 600;
    color: var(--ink, #1d1d1f);
    margin-bottom: .2rem;
}

.cfg-summary-line-addons {
    font-size: .76rem;
    color: var(--ink-2, #6e6e73);
    line-height: 1.6;
}

.cfg-summary-line-price {
    font-size: .88rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    white-space: nowrap;
}

.cfg-summary-client {
    background: var(--bg-2, #f5f5f7);
    border-radius: 10px;
    padding: 1rem 1.25rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .5rem .75rem;
    margin-bottom: 1.25rem;
}

.cfg-summary-client-field {
    display: flex;
    flex-direction: column;
    gap: .1rem;
}

.cfg-summary-client-label {
    font-size: .68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--ink-3);
}

.cfg-summary-client-value {
    font-size: .84rem;
    color: var(--ink, #1d1d1f);
}

.cfg-summary-total-block {
    border-top: 1px solid var(--line, #d2d2d7);
    margin-top: 1rem;
    padding-top: 1rem;
}

.cfg-summary-total-row {
    display: flex;
    justify-content: space-between;
    font-size: .84rem;
    color: var(--ink-2, #6e6e73);
    padding: .25rem 0;
}

.cfg-summary-total-row.main {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    padding-top: .6rem;
}

.cfg-summary-total-row.main span:last-child {
    color: var(--primary, #3d0022);
}

.cfg-quote-badge {
    display: inline-block;
    background: var(--primary-glow);
    color: var(--primary, #3d0022);
    font-size: .72rem;
    font-weight: 700;
    padding: .25rem .75rem;
    border-radius: 99px;
    margin-bottom: 1rem;
}

.custom-tag {
    display: inline-block;
    background: var(--primary-glow);
    color: var(--primary, #3d0022);
    font-size: .64rem;
    font-weight: 600;
    padding: .1rem .45rem;
    border-radius: 99px;
    vertical-align: middle;
    margin-left: .25rem;
}

/* ================================================================
   SUCCESS
   ================================================================ */
.cfg-success {
    text-align: center;
    padding: 2.5rem 1.5rem;
}

.cfg-success-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #e8f5e9;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
}

.cfg-success-icon svg {
    stroke: #2e7d32;
}

.cfg-success h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: .5rem;
}

.cfg-success p {
    font-size: .86rem;
    color: var(--ink-2, #6e6e73);
    margin-bottom: .4rem;
}

.cfg-success-actions {
    display: flex;
    gap: .75rem;
    justify-content: center;
    margin-top: 1.25rem;
    flex-wrap: wrap;
}

.cfg-success-actions button,
.cfg-success-actions a {
    padding: .6rem 1.25rem;
    border-radius: 7px;
    font-size: .84rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all .2s;
}

.cfg-success-actions button {
    border: 1.5px solid var(--primary, #3d0022);
    color: var(--primary, #3d0022);
    background: transparent;
}

.cfg-success-actions button:hover {
    background: var(--primary, #3d0022);
    color: white;
}

.cfg-success-actions a {
    background: var(--ink, #1d1d1f);
    color: white;
    border: 1.5px solid transparent;
}

.cfg-success-actions a:hover {
    opacity: .85;
}

/* ================================================================
   SUMMARY DRAWER
   ================================================================ */
.cfg-summary-drawer {
    position: fixed;
    top: var(--cfg-topbar-h);
    right: 0;
    width: 300px;
    max-height: calc(100vh - var(--cfg-topbar-h));
    background: var(--bg-card, #fff);
    border-left: 1px solid var(--line, #d2d2d7);
    box-shadow: var(--sh-lg, 0 20px 60px rgba(0, 0, 0, .12));
    z-index: 200;
    overflow-y: auto;
    animation: drawerIn .3s cubic-bezier(0.22, 1, 0.36, 1) both;
    transition: background .4s;
}

.cfg-summary-drawer.hidden {
    display: none;
}

@keyframes drawerIn {
    from {
        transform: translateX(100%);
        opacity: 0
    }

    to {
        transform: translateX(0);
        opacity: 1
    }
}

.cfg-summary-drawer-inner {
    padding: 1.25rem;
}

.cfg-summary-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: .75rem;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
}

.cfg-summary-drawer-header h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

.cfg-summary-drawer-header button {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--ink-2, #6e6e73);
    padding: .2rem;
    border-radius: 5px;
    transition: background .15s;
}

.cfg-summary-drawer-header button:hover {
    background: var(--bg-2, #f5f5f7);
}

.cfg-summary-list {
    margin-bottom: 1rem;
}

.cfg-summary-item {
    display: flex;
    justify-content: space-between;
    padding: .5rem 0;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    font-size: .84rem;
}

.cfg-summary-item:last-child {
    border-bottom: none;
}

.cfg-summary-item-name {
    color: var(--ink, #1d1d1f);
    font-weight: 500;
}

.cfg-summary-item-price {
    color: var(--ink-2, #6e6e73);
}

.cfg-drawer-empty {
    font-size: .82rem;
    color: var(--ink-3, #aeaeb2);
    font-style: italic;
}

.cfg-summary-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    padding: .75rem 0;
    border-top: 1px solid var(--line, #d2d2d7);
}

.cfg-summary-note {
    font-size: .72rem;
    color: var(--ink-3, #aeaeb2);
    line-height: 1.5;
    margin-top: .5rem;
}

/* ================================================================
   MODAL
   ================================================================ */
.cfg-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 300;
    background: rgba(0, 0, 0, .5);
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.cfg-modal-overlay.hidden {
    display: none;
}

.cfg-modal {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line, #d2d2d7);
    border-radius: 20px;
    padding: 2rem;
    max-width: 480px;
    width: 100%;
    position: relative;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .18);
    animation: cfgModalIn .35s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes cfgModalIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(20px)
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0)
    }
}

.cfg-modal-close {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 28px;
    height: 28px;
    border: none;
    background: var(--bg-2, #f5f5f7);
    border-radius: 50%;
    cursor: pointer;
    color: var(--ink-2, #6e6e73);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s, transform .2s;
}

.cfg-modal-close:hover {
    background: var(--line, #d2d2d7);
    transform: rotate(90deg);
}

.cfg-modal-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: var(--primary-glow);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.cfg-modal-icon svg {
    stroke: var(--primary, #3d0022);
}

.cfg-modal h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    margin-bottom: .4rem;
}

.cfg-modal>p {
    font-size: .84rem;
    color: var(--ink-2, #6e6e73);
    line-height: 1.6;
    margin-bottom: 1.25rem;
}

.cfg-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: .75rem;
    margin-top: 1.25rem;
}

/* ================================================================
   SPINNER / UTILS
   ================================================================ */
.cfg-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .75rem;
    padding: 2.5rem;
    color: var(--ink-2, #6e6e73);
    font-size: .84rem;
}

.cfg-spinner {
    width: 22px;
    height: 22px;
    border: 2.5px solid var(--line-2, #e8e8ed);
    border-top-color: var(--primary, #3d0022);
    border-radius: 50%;
    animation: spin .7s linear infinite;
}

.btn-spinner {
    width: 18px;
    height: 18px;
    border-width: 2px;
}

@keyframes spin {
    to {
        transform: rotate(360deg)
    }
}

.hidden {
    display: none !important;
}

/* Shared animations */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(16px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1
    }

    50% {
        opacity: .4
    }
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width:900px) {
    :root {
        --cfg-panel-w: 320px;
    }
}

@media (max-width:700px) {
    .cfg-layout {
        flex-direction: column;
    }

    .cfg-preview {
        height: 260px;
        flex-shrink: 0;
    }

    .cfg-panel {
        width: 100%;
        border-left: none;
        border-top: 1px solid var(--line-2, #e8e8ed);
    }

    .cfg-title-text,
    .cfg-btn-contact {
        display: none;
    }

    .cfg-summary-drawer {
        width: 100%;
    }

    .cfg-form-row {
        grid-template-columns: 1fr;
    }

    .dash-restaurant,
    .dash-hotel {
        grid-template-columns: 1fr;
    }

    .dash-sidebar,
    .dash-hotel-sidebar {
        display: none;
    }

    .dash-retail {
        flex-direction: column;
    }

    .dash-retail-right {
        width: 100%;
    }
}

/* ================================================================
   DASHBOARD — 8 CODEX Sistema Real
   Layout unificado con sidebar + main
   ================================================================ */

.dash-8codex {
    display: grid;
    grid-template-columns: 160px 1fr;
    height: 340px;
    font-size: 11px;
}

/* ── Tabla de inventario/facturas/clientes ── */
.dash-inv-table {
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    overflow: hidden;
    margin-top: .25rem;
}

.dash-inv-row {
    display: grid;
    grid-template-columns: 2fr 1.4fr .8fr .9fr;
    align-items: center;
    padding: .35rem .6rem;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
    gap: .25rem;
    font-size: .62rem;
}

.dash-inv-row:last-child {
    border-bottom: none;
}

.dash-inv-row.header {
    background: var(--bg-2, #f5f5f7);
    font-weight: 700;
    font-size: .58rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--ink-3, #aeaeb2);
}

.dash-inv-row span:not(.dash-inv-badge) {
    color: var(--ink-2, #6e6e73);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dash-inv-row .dash-inv-badge {
    justify-self: start;
}

.dash-inv-badge {
    display: inline-block;
    font-size: .55rem;
    font-weight: 600;
    padding: .1rem .4rem;
    border-radius: 99px;
    white-space: nowrap;
}

.dash-inv-badge.ok {
    background: #e8f5e9;
    color: #2e7d32;
}

.dash-inv-badge.bajo {
    background: #fff3e0;
    color: #e65100;
}

.dash-inv-badge.agotado {
    background: #ffebee;
    color: #c62828;
}

/* ── Estado grid — dashboard principal ── */
.dash-estado-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .4rem;
    margin-bottom: .6rem;
}

.dash-estado-card {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .45rem .5rem;
    text-align: center;
}

.dash-estado-card.alerta {
    border-color: #fecaca;
    background: #fff5f5;
}

.dash-estado-card.warning {
    border-color: #fed7aa;
    background: #fffaf5;
}

.dash-estado-num {
    font-size: 1rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
    line-height: 1;
}

.dash-estado-lbl {
    font-size: .55rem;
    color: var(--ink-3, #aeaeb2);
    margin-top: .15rem;
    line-height: 1.2;
}

/* ── Caja métodos de pago ── */
.dash-caja-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .4rem;
    margin-top: .25rem;
}

.dash-caja-metodo {
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    padding: .5rem .45rem;
    text-align: center;
}

.dash-caja-icon {
    font-size: 1rem;
    margin-bottom: .15rem;
}

.dash-caja-label {
    font-size: .58rem;
    color: var(--ink-3, #aeaeb2);
    margin-bottom: .15rem;
}

.dash-caja-val {
    font-size: .72rem;
    font-weight: 700;
    color: var(--ink, #1d1d1f);
}

/* ── Empleados list ── */
.dash-emp-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    background: var(--bg-card, #fff);
    border: 1px solid var(--line-2, #e8e8ed);
    border-radius: 8px;
    overflow: hidden;
    margin-top: .25rem;
}

.dash-emp-row {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .35rem .6rem;
    border-bottom: 1px solid var(--line-2, #e8e8ed);
}

.dash-emp-row:last-child {
    border-bottom: none;
}

/* Responsive overrides for 8codex layout */
@media (max-width:700px) {
    .dash-8codex {
        grid-template-columns: 1fr;
    }

    .dash-8codex .dash-sidebar {
        display: none;
    }

    .dash-estado-grid,
    .dash-caja-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .dash-inv-row {
        grid-template-columns: 1.5fr 1fr .8fr;
    }

    .dash-inv-row span:nth-child(2) {
        display: none;
    }
}