:root {
    --bg: #070b14;
    --bg-soft: #0d1424;
    --card: #111a2e;
    --card-2: #16213a;
    --line: rgba(255, 255, 255, .09);
    --text: #f8fafc;
    --muted: #94a3b8;
    --muted-2: #64748b;
    --primary: #22c55e;
    --primary-dark: #16a34a;
    --secondary: #38bdf8;
    --warning: #facc15;
    --danger: #ef4444;
    --success: #22c55e;
    --radius: 22px;
    --radius-sm: 14px;
    --shadow: 0 24px 60px rgba(0, 0, 0, .35);
    --shadow-soft: 0 12px 30px rgba(0, 0, 0, .25);
    --font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* {
    box-sizing: border-box;
}
html {
    min-height: 100%;
    background: var(--bg);
}
body {
    min-height: 100%;
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(56, 189, 248, .16), transparent 32rem),
        radial-gradient(circle at top right, rgba(34, 197, 94, .14), transparent 28rem),
        linear-gradient(180deg, #070b14 0%, #0b1020 100%);
}
a {
    color: inherit;
    text-decoration: none;
}
img {
    max-width: 100%;
    display: block;
}
button,
input,
select,
textarea {
    font-family: inherit;
}
.app-shell {
    width: 100%;
    min-height: 100vh;
}
.container {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}
.topbar {
    position: sticky;
    top: 0;
    z-index: 30;
    background: rgba(7, 11, 20, .78);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
}
.topbar-inner {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}
.brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    display: grid;
    place-items: center;
    color: #04111d;
    font-weight: 900;
    box-shadow: 0 14px 35px rgba(34, 197, 94, .22);
}
.brand-text strong {
    display: block;
    font-size: 17px;
    letter-spacing: -.02em;
}
.brand-text span {
    display: block;
    color: var(--muted);
    font-size: 12px;
    margin-top: 2px;
}
.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}
.hero {
    padding: 44px 0 28px;
}
.hero-card {
    background:
        linear-gradient(135deg, rgba(17, 26, 46, .94), rgba(13, 20, 36, .94)),
        radial-gradient(circle at 20% 20%, rgba(56, 189, 248, .14), transparent 24rem);
    border: 1px solid var(--line);
    border-radius: 32px;
    padding: 34px;
    box-shadow: var(--shadow);
    overflow: hidden;
    position: relative;
}
.hero-card:after {
    content: "";
    position: absolute;
    inset: auto -120px -160px auto;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: rgba(34, 197, 94, .12);
    filter: blur(20px);
}
.hero h1 {
    margin: 0;
    font-size: clamp(32px, 7vw, 58px);
    line-height: .96;
    letter-spacing: -.06em;
    max-width: 760px;
}
.hero p {
    margin: 18px 0 0;
    max-width: 620px;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.6;
}
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 26px;
}
.grid {
    display: grid;
    gap: 18px;
}
.grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
.grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
.section {
    padding: 26px 0;
}
.section-title {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}
.section-title h2 {
    margin: 0;
    font-size: 24px;
    letter-spacing: -.03em;
}
.section-title p {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 14px;
}
.card {
    background: linear-gradient(180deg, rgba(17, 26, 46, .94), rgba(13, 20, 36, .94));
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
}
.card-pad {
    padding: 20px;
}
.business-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}
.business-cover {
    height: 126px;
    background: linear-gradient(135deg, rgba(34, 197, 94, .22), rgba(56, 189, 248, .18));
    position: relative;
}
.business-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.business-logo {
    width: 64px;
    height: 64px;
    border-radius: 22px;
    border: 4px solid var(--card);
    background: var(--bg-soft);
    position: absolute;
    left: 18px;
    bottom: -28px;
    display: grid;
    place-items: center;
    overflow: hidden;
}
.business-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.business-body {
    padding: 42px 18px 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
}
.business-body h3 {
    margin: 0;
    font-size: 19px;
    letter-spacing: -.02em;
}
.business-body p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.45;
}
.product-card {
    display: grid;
    grid-template-columns: 92px 1fr;
    gap: 14px;
    padding: 14px;
}
.product-img {
    width: 92px;
    height: 92px;
    border-radius: 18px;
    background: var(--bg-soft);
    overflow: hidden;
}
.product-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.product-info h3 {
    margin: 0;
    font-size: 16px;
}
.product-info p {
    margin: 6px 0 10px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.35;
}
.price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.price {
    font-weight: 800;
    color: var(--primary);
}
.btn {
    appearance: none;
    border: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 16px;
    border-radius: 999px;
    background: var(--card-2);
    color: var(--text);
    font-weight: 700;
    cursor: pointer;
    transition: transform .18s ease, background .18s ease, border .18s ease, opacity .18s ease;
    border: 1px solid var(--line);
    font-size: 14px;
}
.btn:hover {
    transform: translateY(-1px);
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), #86efac);
    color: #05210e;
    border-color: rgba(34, 197, 94, .2);
}
.btn-secondary {
    background: linear-gradient(135deg, var(--secondary), #93c5fd);
    color: #04111d;
    border-color: rgba(56, 189, 248, .2);
}
.btn-danger {
    background: rgba(239, 68, 68, .14);
    color: #fecaca;
    border-color: rgba(239, 68, 68, .3);
}
.btn-warning {
    background: rgba(250, 204, 21, .14);
    color: #fde68a;
    border-color: rgba(250, 204, 21, .3);
}
.btn-small {
    min-height: 36px;
    padding: 0 12px;
    font-size: 12px;
}
.form {
    display: grid;
    gap: 14px;
}
.form-row {
    display: grid;
    gap: 8px;
}
.form-row label {
    font-size: 13px;
    color: var(--muted);
    font-weight: 700;
}
.input,
.select,
.textarea {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--line);
    background: rgba(7, 11, 20, .5);
    color: var(--text);
    border-radius: 16px;
    padding: 0 14px;
    outline: none;
}
.textarea {
    min-height: 100px;
    padding: 14px;
    resize: vertical;
}
.input:focus,
.select:focus,
.textarea:focus {
    border-color: rgba(56, 189, 248, .55);
    box-shadow: 0 0 0 4px rgba(56, 189, 248, .08);
}
.table-wrap {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid var(--line);
}
.table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
    background: rgba(17, 26, 46, .84);
}
.table th,
.table td {
    padding: 13px 14px;
    text-align: left;
    border-bottom: 1px solid var(--line);
    vertical-align: middle;
    font-size: 14px;
}
.table th {
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .08em;
}
.table tr:last-child td {
    border-bottom: 0;
}
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}
.badge-success {
    background: rgba(34, 197, 94, .14);
    color: #86efac;
    border: 1px solid rgba(34, 197, 94, .24);
}
.badge-danger {
    background: rgba(239, 68, 68, .14);
    color: #fecaca;
    border: 1px solid rgba(239, 68, 68, .24);
}
.badge-warning {
    background: rgba(250, 204, 21, .14);
    color: #fde68a;
    border: 1px solid rgba(250, 204, 21, .24);
}
.badge-info {
    background: rgba(56, 189, 248, .14);
    color: #bae6fd;
    border: 1px solid rgba(56, 189, 248, .24);
}
.badge-primary {
    background: rgba(34, 197, 94, .14);
    color: #bbf7d0;
    border: 1px solid rgba(34, 197, 94, .24);
}
.badge-muted {
    background: rgba(148, 163, 184, .12);
    color: #cbd5e1;
    border: 1px solid rgba(148, 163, 184, .18);
}
.alert {
    padding: 14px 16px;
    border-radius: 18px;
    margin: 0 0 16px;
    border: 1px solid var(--line);
    background: rgba(17, 26, 46, .75);
    color: var(--text);
}
.alert-success {
    border-color: rgba(34, 197, 94, .3);
    background: rgba(34, 197, 94, .12);
}
.alert-danger {
    border-color: rgba(239, 68, 68, .3);
    background: rgba(239, 68, 68, .12);
}
.alert-warning {
    border-color: rgba(250, 204, 21, .3);
    background: rgba(250, 204, 21, .12);
}
.panel-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    min-height: 100vh;
}
.sidebar {
    border-right: 1px solid var(--line);
    background: rgba(7, 11, 20, .7);
    padding: 20px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}
.sidebar .brand {
    margin-bottom: 22px;
}
.sidebar-nav {
    display: grid;
    gap: 8px;
}
.sidebar-nav a {
    padding: 12px 14px;
    border-radius: 15px;
    color: var(--muted);
    font-weight: 700;
    border: 1px solid transparent;
}
.sidebar-nav a:hover,
.sidebar-nav a.active {
    color: var(--text);
    background: rgba(255, 255, 255, .06);
    border-color: var(--line);
}
.panel-main {
    padding: 24px;
}
.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
}
.panel-header h1 {
    margin: 0;
    font-size: 28px;
    letter-spacing: -.04em;
}
.panel-header p {
    margin: 4px 0 0;
    color: var(--muted);
}
.stat-card {
    padding: 20px;
    border-radius: var(--radius);
    background: linear-gradient(180deg, rgba(17, 26, 46, .96), rgba(13, 20, 36, .96));
    border: 1px solid var(--line);
}
.stat-card span {
    color: var(--muted);
    font-size: 13px;
}
.stat-card strong {
    display: block;
    margin-top: 10px;
    font-size: 32px;
    letter-spacing: -.04em;
}
.login-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
}
.login-card {
    width: min(440px, 100%);
    padding: 26px;
}
.login-card h1 {
    margin: 0 0 8px;
    font-size: 30px;
    letter-spacing: -.04em;
}
.login-card p {
    margin: 0 0 22px;
    color: var(--muted);
}
.cart-float {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 50;
}
.cart-item {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    padding: 14px;
    border-bottom: 1px solid var(--line);
}
.cart-item:last-child {
    border-bottom: 0;
}
.qty-control {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, .04);
    border-radius: 999px;
    padding: 4px;
}
.qty-control button {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    border: 0;
    background: var(--card-2);
    color: var(--text);
    cursor: pointer;
}
.empty {
    text-align: center;
    padding: 44px 18px;
    color: var(--muted);
}
.detail-list {
    display: grid;
    gap: 12px;
}
.detail-row {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
}
.detail-row:last-child {
    border-bottom: 0;
}
.detail-row span {
    color: var(--muted);
    font-size: 13px;
}
.detail-row strong {
    color: var(--text);
    font-weight: 700;
}
.thumb {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    object-fit: cover;
    background: var(--bg-soft);
}
.doc-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
}
.doc-card {
    background: rgba(255, 255, 255, .04);
    border: 1px solid var(--line);
    border-radius: 16px;
    overflow: hidden;
}
.doc-card img {
    width: 100%;
    height: 140px;
    object-fit: cover;
}
.doc-card span {
    display: block;
    padding: 10px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}
.footer-space {
    height: 36px;
}
@media (max-width: 900px) {
    .grid-4,
    .grid-3,
    .grid-2 {
        grid-template-columns: 1fr;
    }
    .panel-layout {
        grid-template-columns: 1fr;
    }
    .sidebar {
        position: relative;
        height: auto;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }
    .sidebar-nav {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .panel-main {
        padding: 18px;
    }
    .panel-header {
        align-items: flex-start;
        flex-direction: column;
    }
    .doc-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .detail-row {
        grid-template-columns: 1fr;
        gap: 4px;
    }
}
@media (max-width: 560px) {
    .container {
        width: min(100% - 22px, 1180px);
    }
    .topbar-inner {
        min-height: 64px;
    }
    .brand-mark {
        width: 40px;
        height: 40px;
    }
    .brand-text span {
        display: none;
    }
    .nav-actions {
        gap: 6px;
    }
    .hero {
        padding: 24px 0 18px;
    }
    .hero-card {
        padding: 24px;
        border-radius: 26px;
    }
    .product-card {
        grid-template-columns: 82px 1fr;
    }
    .product-img {
        width: 82px;
        height: 82px;
    }
    .btn {
        min-height: 42px;
        padding: 0 14px;
    }
    .sidebar-nav {
        grid-template-columns: 1fr;
    }
    .doc-grid {
        grid-template-columns: 1fr;
    }
}
.ph {
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.btn .ph {
    font-size: 18px;
    margin-right: 7px;
}
.badge .ph {
    font-size: 13px;
    margin-right: 4px;
}
.cart-link {
    width: 46px;
    height: 46px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(17, 26, 46, .96), rgba(13, 20, 36, .96));
    color: var(--text);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: var(--shadow-soft);
    transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.cart-link:hover {
    transform: translateY(-1px);
    border-color: rgba(34, 197, 94, .35);
    background: linear-gradient(180deg, rgba(22, 33, 58, .98), rgba(13, 20, 36, .98));
}
.cart-icon-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.cart-icon-wrap .ph {
    font-size: 25px;
    color: var(--text);
}
.cart-badge {
    position: absolute;
    top: -12px;
    right: -14px;
    min-width: 21px;
    height: 21px;
    padding: 0 6px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), #86efac);
    color: #05210e;
    font-size: 11px;
    font-weight: 900;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg);
    box-shadow: 0 8px 18px rgba(34, 197, 94, .25);
}
.floating-cart-link {
    min-height: 52px;
    padding: 0 16px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), #86efac);
    color: #05210e;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 900;
    box-shadow: 0 18px 45px rgba(34, 197, 94, .25);
    border: 1px solid rgba(34, 197, 94, .35);
}
.floating-cart-link .ph {
    font-size: 23px;
}
.floating-cart-link strong {
    min-width: 23px;
    height: 23px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(5, 33, 14, .16);
    color: #05210e;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}
.product-img-placeholder {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    color: var(--muted);
    background: linear-gradient(135deg, rgba(34, 197, 94, .10), rgba(56, 189, 248, .10));
}
.product-img-placeholder .ph {
    font-size: 34px;
}
@media (max-width: 560px) {
    .cart-link {
        width: 42px;
        height: 42px;
        border-radius: 16px;
    }
    .cart-icon-wrap .ph {
        font-size: 23px;
    }
    .cart-badge {
        top: -11px;
        right: -13px;
    }
    .floating-cart-link {
        min-height: 48px;
        padding: 0 14px;
    }
}
/* =========================================================
   Negocios Locales V6 - Pulido visual, imágenes y formularios
   ========================================================= */
:root {
    --field-bg: rgba(7, 11, 20, .62);
    --field-border: rgba(148, 163, 184, .18);
    --field-border-focus: rgba(56, 189, 248, .55);
}
.input,
.select,
.textarea,
input[type="text"],
input[type="number"],
input[type="password"],
input[type="email"],
input[type="tel"],
select,
textarea {
    border: 1px solid var(--field-border);
    background: var(--field-bg);
    color: var(--text);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.03);
}
input[type="file"].input,
input[type="file"] {
    min-height: 52px;
    padding: 8px 10px;
    border-radius: 16px;
    border: 1px dashed rgba(56,189,248,.30);
    background: linear-gradient(180deg, rgba(7,11,20,.72), rgba(15,23,42,.72));
    color: var(--muted);
    cursor: pointer;
}
input[type="file"].input:hover,
input[type="file"]:hover {
    border-color: rgba(34,197,94,.42);
    background: linear-gradient(180deg, rgba(15,23,42,.86), rgba(17,26,46,.86));
}
input[type="file"]::file-selector-button {
    appearance: none;
    border: 1px solid rgba(34,197,94,.28);
    min-height: 34px;
    margin-right: 12px;
    padding: 0 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), #86efac);
    color: #05210e;
    font-weight: 900;
    cursor: pointer;
}
input[type="file"]::-webkit-file-upload-button {
    appearance: none;
    border: 1px solid rgba(34,197,94,.28);
    min-height: 34px;
    margin-right: 12px;
    padding: 0 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), #86efac);
    color: #05210e;
    font-weight: 900;
    cursor: pointer;
}
.form-row small,
.help-text,
.muted {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
}
label:has(input[type="checkbox"]),
.nl-check {
    min-height: 42px;
    padding: 10px 12px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border-radius: 15px;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.04);
    color: var(--text);
    font-weight: 800;
}
input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}
.product-img,
.index-product-preview,
.index-product-mini-img,
.product-thumb,
.nl-product-image-box {
    background: linear-gradient(180deg, #ffffff, #f8fafc) !important;
    border: 1px solid rgba(255,255,255,.12);
    box-shadow: inset 0 0 0 1px rgba(2,6,23,.04);
}
.product-img img,
.index-product-preview img,
.index-product-mini-img img,
.product-thumb img,
.nl-product-image-box img {
    width: 100%;
    height: 100%;
    object-fit: contain !important;
    object-position: center;
    padding: 5px;
}
.index-business-logo,
.business-logo,
.nl-business-logo {
    background: linear-gradient(180deg, #ffffff, #eef7f4) !important;
}
.index-business-logo img,
.business-logo img,
.nl-business-logo img {
    object-fit: contain !important;
    padding: 5px;
}
.index-business-cover > img,
.business-cover > img,
.nl-business-cover > img {
    object-fit: cover !important;
    object-position: center;
}
.product-card {
    align-items: stretch;
}
.product-info {
    min-width: 0;
}
.product-info h3,
.index-product-mini strong {
    overflow-wrap: anywhere;
}
.price-row {
    flex-wrap: wrap;
}
.product-thumb {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    overflow: hidden;
    display: grid;
    place-items: center;
}
.product-thumb .ph,
.product-img-placeholder .ph,
.nl-image-placeholder .ph {
    color: rgba(15,23,42,.45);
}
.nl-image-placeholder {
    width: 100%;
    height: 100%;
    min-height: 72px;
    display: grid;
    place-items: center;
    background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
    border: 1px dashed rgba(148,163,184,.22);
    border-radius: inherit;
}
.table td,
.table th {
    vertical-align: middle;
}
.card h2,
.card h3,
.panel-main h1,
.panel-main h2,
.panel-main h3 {
    text-wrap: balance;
}
.btn,
button,
a.btn {
    text-align: center;
    line-height: 1.15;
}
.form-actions,
.nl-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}
@media (max-width: 700px) {
    .product-card {
        grid-template-columns: 86px 1fr;
        gap: 12px;
    }
    .product-img {
        width: 86px;
        height: 86px;
    }
    input[type="file"]::file-selector-button,
    input[type="file"]::-webkit-file-upload-button {
        display: block;
        width: 100%;
        margin: 0 0 8px 0;
    }
}

/* === V7: carrito y confirmación de pedidos === */
.cart-item-v7 {
    display: grid;
    grid-template-columns: 66px 1fr auto auto;
    gap: 12px;
    align-items: center;
}
.cart-item-main {
    min-width: 0;
}
.cart-item-img {
    width: 66px;
    height: 66px;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,.10);
    background: rgba(255,255,255,.045);
    display: grid;
    place-items: center;
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.03);
}
.cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 5px;
    background: rgba(255,255,255,.96);
}
.cart-item-img .ph {
    font-size: 25px;
    color: var(--muted);
}
.nl-order-success {
    text-align: center;
}
.nl-success-icon {
    width: 74px;
    height: 74px;
    border-radius: 26px;
    margin: 0 auto 14px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, rgba(34,197,94,.22), rgba(56,189,248,.16));
    border: 1px solid rgba(34,197,94,.25);
    box-shadow: 0 20px 50px rgba(34,197,94,.14);
}
.nl-success-icon .ph {
    font-size: 42px;
    color: var(--primary);
}
.nl-order-note {
    border: 1px solid rgba(56,189,248,.18);
    background: rgba(56,189,248,.08);
    color: var(--muted);
    padding: 12px 14px;
    border-radius: 18px;
    font-size: 13px;
    line-height: 1.45;
}
@media (max-width: 720px) {
    .cart-item-v7 {
        grid-template-columns: 58px 1fr;
    }
    .cart-item-v7 .qty-control,
    .cart-item-v7 .btn {
        grid-column: 2;
        justify-self: start;
    }
    .cart-item-img {
        width: 58px;
        height: 58px;
        border-radius: 16px;
    }
}

/* =========================================================
   Negocios Locales V9 - Pantalla de detalle de productos
   ========================================================= */
.product-img-link {
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.product-img-link:hover {
    transform: translateY(-2px);
    border-color: rgba(56,189,248,.36);
    box-shadow: 0 14px 35px rgba(0,0,0,.20);
}
.price-row-v9 {
    align-items: center;
    justify-content: flex-start;
}
.price-row-v9 .price {
    margin-right: auto;
}
.product-detail-section {
    padding-top: 34px;
}
.product-detail-layout {
    display: grid;
    grid-template-columns: minmax(300px, .95fr) minmax(320px, 1.05fr);
    gap: 20px;
    align-items: stretch;
}
.product-detail-media {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.product-detail-image {
    min-height: 460px;
    height: min(60vh, 620px);
    border-radius: 24px;
    background: linear-gradient(180deg, #fff, #f8fafc);
    border: 1px solid rgba(255,255,255,.13);
    display: grid;
    place-items: center;
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(2,6,23,.04);
}
.product-detail-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    padding: 20px;
}
.product-detail-image .product-img-placeholder {
    color: rgba(15,23,42,.55);
    background: linear-gradient(180deg, #fff, #eef2f7);
}
.product-detail-image .product-img-placeholder .ph {
    font-size: 74px;
}
.product-detail-media-note {
    min-height: 44px;
    padding: 0 14px;
    border-radius: 16px;
    background: rgba(56,189,248,.08);
    border: 1px solid rgba(56,189,248,.16);
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 8px;
}
.product-detail-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.product-detail-kicker {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.product-detail-info h1 {
    margin: 0;
    font-size: clamp(32px, 5vw, 56px);
    line-height: .98;
    letter-spacing: -.06em;
    text-wrap: balance;
}
.product-detail-price {
    width: fit-content;
    max-width: 100%;
    padding: 14px 18px;
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(34,197,94,.18), rgba(56,189,248,.10));
    border: 1px solid rgba(34,197,94,.26);
    color: #86efac;
    font-size: clamp(22px, 3vw, 34px);
    font-weight: 950;
    letter-spacing: -.04em;
}
.product-detail-desc {
    margin: 0;
    color: var(--muted);
    font-size: 16px;
    line-height: 1.65;
}
.product-detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.product-detail-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}
.product-detail-facts > div {
    min-height: 74px;
    padding: 13px;
    border-radius: 18px;
    background: rgba(255,255,255,.045);
    border: 1px solid rgba(255,255,255,.075);
}
.product-detail-facts span {
    display: block;
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .08em;
    font-weight: 900;
}
.product-detail-facts strong {
    display: block;
    margin-top: 7px;
    color: var(--text);
    font-size: 14px;
    overflow-wrap: anywhere;
}
.product-detail-locations {
    padding: 16px;
    border-radius: 22px;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.035);
}
.product-detail-locations h3 {
    margin: 0 0 10px;
    font-size: 15px;
}
.product-business-strip {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}
.product-business-main {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}
.product-business-logo {
    width: 74px;
    height: 74px;
    border-radius: 24px;
    background: linear-gradient(180deg, #fff, #eef7f4);
    border: 1px solid rgba(255,255,255,.12);
    display: grid;
    place-items: center;
    overflow: hidden;
    flex: 0 0 auto;
}
.product-business-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 6px;
}
.product-business-logo .ph {
    font-size: 34px;
    color: var(--muted);
}
.product-business-main h2 {
    margin: 0;
    font-size: 22px;
    letter-spacing: -.03em;
}
.product-business-main p {
    margin: 5px 0 0;
    color: var(--muted);
    line-height: 1.45;
}
.compact-actions {
    margin-top: 10px;
}
.suggested-grid {
    align-items: stretch;
}
.suggested-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}
.suggested-img {
    height: 170px;
    background: linear-gradient(180deg, #fff, #f8fafc);
    display: grid;
    place-items: center;
    overflow: hidden;
    border-bottom: 1px solid rgba(255,255,255,.08);
}
.suggested-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 12px;
}
.suggested-body {
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}
.suggested-body > span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.suggested-body h3 {
    margin: 0;
    font-size: 16px;
    line-height: 1.25;
    overflow-wrap: anywhere;
}
.suggested-body strong {
    color: var(--primary);
    font-weight: 950;
}
.suggested-body em {
    color: #fde68a;
    font-size: 12px;
    font-style: normal;
    line-height: 1.35;
}
.suggested-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: auto;
}
@media (max-width: 980px) {
    .product-detail-layout {
        grid-template-columns: 1fr;
    }
    .product-detail-image {
        min-height: 340px;
        height: min(52vh, 520px);
    }
    .product-business-strip {
        flex-direction: column;
        align-items: flex-start;
    }
}
@media (max-width: 620px) {
    .product-detail-media {
        padding: 10px;
    }
    .product-detail-image {
        min-height: 280px;
        border-radius: 20px;
    }
    .product-detail-image img {
        padding: 12px;
    }
    .product-detail-facts {
        grid-template-columns: 1fr;
    }
    .product-business-main {
        align-items: flex-start;
    }
    .suggested-img {
        height: 150px;
    }
    .price-row-v9 .price {
        width: 100%;
        margin-right: 0;
    }
}

/* === V11: notificaciones internas y modales del sistema === */
.nl-notify-wrap {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 100000;
    display: grid;
    gap: 10px;
    max-width: min(420px, calc(100vw - 28px));
}
.nl-notify {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 14px;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,.12);
    background: linear-gradient(135deg, rgba(17,26,46,.98), rgba(9,14,25,.98));
    color: var(--text, #f8fafc);
    box-shadow: 0 18px 50px rgba(0,0,0,.38);
    animation: nlNotifyIn .18s ease both;
    font-weight: 850;
    line-height: 1.35;
}
.nl-notify i { font-size: 21px; flex: 0 0 auto; }
.nl-notify span { flex: 1; }
.nl-notify button {
    width: 26px;
    height: 26px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,.12);
    background: rgba(255,255,255,.07);
    color: var(--text, #f8fafc);
    cursor: pointer;
    font-size: 17px;
    line-height: 1;
}
.nl-notify-success i { color: #4ade80; }
.nl-notify-warning i { color: #facc15; }
.nl-notify-error i { color: #fb7185; }
.nl-notify-info i { color: #38bdf8; }
.nl-notify.is-leaving { animation: nlNotifyOut .18s ease both; }
@keyframes nlNotifyIn { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes nlNotifyOut { from { opacity: 1; transform: translateY(0) scale(1); } to { opacity: 0; transform: translateY(8px) scale(.98); } }
.nl-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(2,6,23,.70);
    backdrop-filter: blur(12px);
    animation: nlModalBgIn .16s ease both;
}
.nl-modal-overlay.is-leaving { animation: nlModalBgOut .16s ease both; }
.nl-modal {
    width: min(480px, 100%);
    display: flex;
    gap: 14px;
    padding: 18px;
    border-radius: 28px;
    border: 1px solid rgba(255,255,255,.13);
    background: linear-gradient(160deg, rgba(17,26,46,.98), rgba(9,14,25,.98));
    box-shadow: 0 28px 90px rgba(0,0,0,.55);
    color: var(--text, #f8fafc);
    animation: nlModalIn .16s ease both;
}
.nl-modal-icon {
    width: 48px;
    height: 48px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    background: rgba(56,189,248,.12);
    border: 1px solid rgba(56,189,248,.20);
}
.nl-modal-icon i { font-size: 25px; color: #7dd3fc; }
.nl-modal-warning .nl-modal-icon { background: rgba(250,204,21,.12); border-color: rgba(250,204,21,.22); }
.nl-modal-warning .nl-modal-icon i { color: #facc15; }
.nl-modal-danger .nl-modal-icon { background: rgba(251,113,133,.12); border-color: rgba(251,113,133,.22); }
.nl-modal-danger .nl-modal-icon i { color: #fb7185; }
.nl-modal-content { flex: 1; min-width: 0; }
.nl-modal-content h3 { margin: 0 0 7px; font-size: 21px; letter-spacing: -.03em; }
.nl-modal-content p { margin: 0; color: var(--muted, #94a3b8); line-height: 1.48; font-weight: 650; }
.nl-modal-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
@keyframes nlModalBgIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes nlModalBgOut { from { opacity: 1; } to { opacity: 0; } }
@keyframes nlModalIn { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
@media (max-width: 620px) {
    .nl-notify-wrap { left: 14px; right: 14px; bottom: 14px; }
    .nl-modal { flex-direction: column; border-radius: 24px; }
    .nl-modal-actions { display: grid; grid-template-columns: 1fr; }
}

/* Auditoría visual V47: documentos con media robusta y fallback visible */
.doc-media-link{display:block;position:relative;text-decoration:none;color:inherit;background:var(--bg-soft,#f4f7fb);min-height:140px}
.doc-media-link img{display:block;width:100%;height:140px;object-fit:cover}
.doc-media-fallback{display:none;min-height:140px;padding:18px;align-items:center;justify-content:center;text-align:center;color:var(--muted);font-size:12px;font-weight:700}
.doc-card.doc-missing .doc-media-fallback{display:flex}
.doc-card.doc-missing .doc-media-link{background:var(--bg-soft,#f4f7fb)}
.doc-card:not(.doc-missing) .doc-media-link:hover{filter:brightness(.98)}
