/* =========================
   SAINT HUB – GLOBAL
   ========================= */
:root {
    --bg-main: #0f0f0f;
    --bg-card: #161616;
    --bg-soft: #1e1e1e;
    --text-main: #f5f5f5;
    --text-muted: #a1a1a1;
    --accent: #e6c36a; /* dorado suave street */
    --accent-2: #8b5cf6; /* morado discreto */
    --success: #16a34a;
    --warning: #f59e0b;
    --danger: #dc2626;
    --radius: 14px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
}

/* =========================
   NAVBAR
   ========================= */
.navbar-saint {
    background-color: rgba(15,15,15,0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #222;
}

.navbar-brand {
    font-weight: 800;
    letter-spacing: 1px;
    color: var(--text-main) !important;
}

    .navbar-brand span {
        color: var(--accent);
    }

.nav-link {
    color: var(--text-muted) !important;
    transition: color .2s;
}

    .nav-link:hover {
        color: var(--text-main) !important;
    }

/* =========================
   CONTAINER
   ========================= */
.container-saint {
    max-width: 1300px;
    margin: auto;
    padding: 2rem 1rem;
}

/* =========================
   HERO
   ========================= */
.hero {
    background: linear-gradient(180deg, #111, #0a0a0a);
    border-radius: var(--radius);
    padding: 3rem 2rem;
    margin-bottom: 3rem;
}

    .hero h1 {
        font-size: 2.5rem;
        font-weight: 900;
    }

    .hero p {
        color: var(--text-muted);
        max-width: 600px;
    }

/* =========================
   PRODUCT GRID
   ========================= */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.5rem;
}

.product-card {
    background-color: var(--bg-card);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform .25s ease, box-shadow .25s ease;
    border: 1px solid #222;
}

    .product-card:hover {
        transform: translateY(-6px);
        box-shadow: 0 20px 40px rgba(0,0,0,.6);
    }

.product-img {
    height: 220px;
    background-color: #0b0b0b;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .product-img img {
        max-width: 90%;
        max-height: 90%;
        object-fit: contain;
    }

.product-body {
    padding: 1.2rem;
}

.product-title {
    font-weight: 600;
    margin: 0 0 .3rem 0;
}

.product-price {
    font-weight: 700;
    font-size: 1.1rem;
}

.badge {
    display: inline-block;
    padding: .3rem .6rem;
    border-radius: 999px;
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .5px;
}

.badge-stock {
    background-color: rgba(22,163,74,.15);
    color: var(--success);
}

.badge-encargo {
    background-color: rgba(245,158,11,.15);
    color: var(--warning);
}

/* =========================
   DETAILS
   ========================= */
.product-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

    .product-details img {
        width: 100%;
        border-radius: var(--radius);
        background-color: #0b0b0b;
    }

.size-grid {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.size-btn {
    padding: .5rem .8rem;
    border-radius: 8px;
    border: 1px solid #333;
    background: transparent;
    color: var(--text-main);
    cursor: pointer;
}

    .size-btn:hover {
        border-color: var(--accent);
        color: var(--accent);
    }

/* =========================
   BUTTONS – SAINT HUB
========================= */

.btn-saint {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: .7rem 1.4rem;
    border-radius: 10px;
    background: #f5c451; /* dorado suave */
    color: #111;
    font-weight: 600;
    font-size: .95rem;
    letter-spacing: .02em;
    text-decoration: none;
    border: none;
    transition: background .2s ease, transform .15s ease;
}

    .btn-saint:hover {
        background: #e5b847;
        transform: translateY(-1px);
    }

/* Outline elegante (feature section) */
.btn-saint-outline {
    
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: .65rem 3.4rem;
    padding-top: 10PX;
    border-radius: 10px;
    background: transparent;
    color: #f5c451;
    font-weight: 600;
    font-size: .95rem;
    letter-spacing: .02em;
    text-decoration: none;
    border: 1px solid rgba(245,196,81,.6);
    transition: background .2s ease, color .2s ease;
}

    .btn-saint-outline:hover {
        background: rgba(245,196,81,.08);
        color: #f5c451;
    }


/* =========================
   FOOTER
   ========================= */
footer {
    border-top: 1px solid #222;
    color: var(--text-muted);
    padding: 2rem 1rem;
    text-align: center;
}
/* =========================
   CART UI
   ========================= */
.card-saint {
    background: var(--bg-card);
    border: 1px solid #222;
    border-radius: var(--radius);
    padding: 1.2rem;
}

.table-saint {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
    overflow: hidden;
    border-radius: 12px;
}

    .table-saint th, .table-saint td {
        padding: 1rem;
        border-bottom: 1px solid #262626;
        text-align: left;
    }

    .table-saint th {
        color: var(--text-muted);
        font-size: .85rem;
        letter-spacing: .4px;
        text-transform: uppercase;
    }

.cart-item {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.cart-thumb {
    width: 64px;
    height: 64px;
    border-radius: 12px;
    background: #0b0b0b;
    border: 1px solid #222;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

    .cart-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.kpi {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 1rem;
}

    .kpi .pill {
        padding: .6rem 1rem;
        border-radius: 999px;
        background: #111;
        border: 1px solid #222;
        color: var(--text-main);
        font-weight: 700;
    }

.input-saint, .select-saint {
    width: 100%;
    padding: .8rem 1rem;
    border-radius: 10px;
    border: 1px solid #2a2a2a;
    background: #0f0f0f;
    color: var(--text-main);
    outline: none;
}

    .input-saint:focus, .select-saint:focus {
        border-color: var(--accent);
    }

.cart-actions {
    display: flex;
    gap: .6rem;
    align-items: center;
}

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    border: 1px solid #2a2a2a;
    background: #121212;
    color: var(--text-main);
    text-decoration: none;
}

    .icon-btn:hover {
        border-color: var(--accent);
        color: var(--accent);
    }

.nav-pill {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .45rem .8rem;
    border-radius: 999px;
    border: 1px solid #222;
    background: #121212;
    color: var(--text-main);
    text-decoration: none;
    margin-left: .6rem;
}

    .nav-pill small {
        color: var(--text-muted);
    }

.counter {
    min-width: 22px;
    height: 22px;
    border-radius: 999px;
    background: var(--accent);
    color: #000;
    font-weight: 900;
    font-size: .8rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 .35rem;
}
/* ===== IMAGENES ADMIN ===== */

.drop-zone {
    border: 2px dashed #333;
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: border .2s, background .2s;
    margin-top: .6rem;
}

    .drop-zone:hover {
        border-color: var(--accent);
        background: rgba(255, 255, 255, 0.02);
    }

.preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    gap: .6rem;
    margin-top: .8rem;
}

    .preview-grid img {
        width: 100%;
        height: 90px;
        object-fit: cover;
        border-radius: 8px;
        border: 1px solid #333;
    }
/* ===== CARRITO ===== */

.cart-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cart-item {
    display: grid;
    grid-template-columns: 80px 1fr auto auto auto;
    gap: 1rem;
    align-items: center;
    padding: 1rem;
    border-radius: 14px;
    background: rgba(255,255,255,0.02);
}

    .cart-item img {
        width: 80px;
        height: 80px;
        object-fit: cover;
        border-radius: 10px;
    }

.cart-info small {
    display: block;
    color: var(--text-muted);
    font-size: .8rem;
}

.cart-qty {
    display: flex;
    align-items: center;
    gap: .4rem;
}

    .cart-qty button {
        width: 28px;
        height: 28px;
        border-radius: 50%;
        border: 1px solid #444;
        background: none;
        color: #fff;
        cursor: pointer;
    }

        .cart-qty button:disabled {
            opacity: .3;
            cursor: not-allowed;
        }

.cart-subtotal {
    font-weight: bold;
}

.remove {
    background: none;
    border: none;
    color: #ff5c7a;
    font-size: 1.2rem;
    cursor: pointer;
}

.cart-summary {
    margin-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-actions {
    display: flex;
    gap: 1rem;
}
.product-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.product-main-img {
    width: 100%;
    border-radius: 16px;
    background: #111;
}

.product-info h1 {
    font-size: 2rem;
}

.price {
    margin: .5rem 0 1rem;
    font-size: 1.6rem;
    color: var(--accent);
}

.description {
    margin: 1rem 0 2rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.variant-form {
    margin-top: 2rem;
}


.checkout-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2.5rem;
}

.checkout-item {
    display: grid;
    grid-template-columns: 80px 1fr auto;
    gap: 1rem;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid #222;
}

    .checkout-item img {
        width: 80px;
        border-radius: 10px;
    }

.checkout-summary .row {
    display: flex;
    justify-content: space-between;
    margin: 1rem 0;
}

.success-wrapper {
    display: flex;
    justify-content: center;
    padding: 4rem 1rem;
}

.success-card {
    background: #121212;
    border-radius: 16px;
    padding: 2.5rem;
    max-width: 520px;
    width: 100%;
    box-shadow: 0 0 40px rgba(0,0,0,.5);
    text-align: center;
}

.success-icon {
    font-size: 3rem;
    color: #f2c94c;
    margin-bottom: 1rem;
}

.success-subtitle {
    color: #bbb;
    margin-bottom: 2rem;
}

.order-info {
    display: grid;
    gap: .75rem;
    text-align: left;
    margin-bottom: 1.5rem;
}

    .order-info span {
        color: #888;
    }

.badge-pending {
    background: rgba(242, 201, 76, 0.15);
    color: #f2c94c;
    padding: .2rem .6rem;
    border-radius: 6px;
    font-size: .85rem;
}

.order-item {
    display: flex;
    justify-content: space-between;
    font-size: .95rem;
    margin-bottom: .5rem;
}

.btn-whatsapp {
    display: block;
    margin-top: 2rem;
    background: #25D366;
    color: #000;
    padding: .9rem;
    border-radius: 10px;
    font-weight: 600;
    text-decoration: none;
    transition: transform .15s ease;
}

    .btn-whatsapp:hover {
        transform: scale(1.03);
    }

.success-foot {
    margin-top: 1.5rem;
    font-size: .85rem;
    color: #888;
}
.admin-wrapper {
    max-width: 1100px;
    margin: 3rem auto;
}

.card-saint {
    background: #121212;
    border-radius: 14px;
    padding: 1.5rem;
}

.table-saint {
    width: 100%;
    border-collapse: collapse;
}

    .table-saint th,
    .table-saint td {
        padding: .75rem;
        border-bottom: 1px solid #222;
    }

.status-form {
    display: flex;
    gap: .5rem;
}

.select-saint {
    background: #1a1a1a;
    color: #fff;
    border: 1px solid #333;
    border-radius: 6px;
    padding: .3rem .5rem;
}

.btn-saint {
    background: #f2c94c;
    border: none;
    border-radius: 6px;
    padding: .3rem .8rem;
    font-weight: 600;
}

/* =========================
   ADMIN PRODUCT EDIT
========================= */

.admin-section {
    margin-top: 2.5rem;
}

    .admin-section h2 {
        margin-bottom: 1rem;
    }

/* ---------- IMÁGENES ---------- */

.image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.image-card {
    background: #111;
    border-radius: 12px;
    padding: 0.75rem;
    text-align: center;
    position: relative;
}

    .image-card img {
        width: 100%;
        height: 180px;
        object-fit: cover;
        border-radius: 8px;
    }

    .image-card.primary {
        outline: 2px solid #f5c86a;
    }

.image-actions {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

    .image-actions button {
        flex: 1;
        font-size: 0.85rem;
    }

/* ---------- VARIANTES ---------- */

.variant-table input[type="number"],
.variant-table input[type="text"] {
    width: 100%;
    padding: 0.35rem;
}

.variant-actions {
    display: flex;
    gap: 0.5rem;
}

    .variant-actions button {
        white-space: nowrap;
    }

/* ---------- ADD VARIANT ---------- */

.add-variant {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 0.75rem;
    margin-top: 1rem;
}

/* ---------- BOTONES ---------- */

.btn-danger {
    background: #a33;
    color: #fff;
}

.btn-secondary {
    background: #333;
    color: #fff;
}


/* =========================
   ADMIN – INPUTS
========================= */

input[type="text"],
input[type="number"],
textarea {
    background: #0f0f0f;
    border: 1px solid #222;
    color: #fff;
    border-radius: 8px;
    padding: 0.55rem 0.7rem;
}

input[type="number"] {
    max-width: 120px;
}

/* =========================
   BOTONES
========================= */

.btn-saint {
    background: #f5c86a;
    color: #000;
    border-radius: 999px;
    padding: 0.45rem 1rem;
    font-weight: 600;
    border: none;
}

    .btn-saint.small {
        padding: 0.35rem 0.8rem;
        font-size: 0.85rem;
    }

.btn-secondary {
    background: #1f1f1f;
    color: #ddd;
    border-radius: 999px;
    padding: 0.35rem 0.8rem;
    font-size: 0.8rem;
}

.btn-danger {
    background: transparent;
    color: #e57373;
    border: 1px solid #333;
    border-radius: 999px;
    padding: 0.35rem 0.8rem;
    font-size: 0.8rem;
}

/* =========================
   IMÁGENES
========================= */

.image-grid {
    justify-content: flex-start;
}

.image-actions {
    justify-content: center;
}

/* =========================
   VARIANTES
========================= */

.variant-row {
    display: grid;
    grid-template-columns: 120px 120px auto;
    align-items: center;
    gap: 0.75rem;
}

.variant-actions {
    display: flex;
    gap: 0.5rem;
}

.add-variant {
    grid-template-columns: 160px 120px auto;
    align-items: center;
}
    .add-variant.clean {
        margin-top: 1.5rem;
    }

.variant-add-row {
    display: grid;
    grid-template-columns: 180px 180px 1fr;
    gap: 1rem;
    align-items: center;
}

    .variant-add-row input {
        background: #0f0f0f;
        border: 1px solid #2a2a2a;
        border-radius: 8px;
        padding: 0.6rem 0.8rem;
        color: #fff;
    }

.btn-saint.wide {
    width: 100%;
    height: 42px;
}


/* =========================
   CUSTOM ORDER FORM
========================= */

.custom-order-header {
    max-width: 720px;
    margin-bottom: 2.5rem;
}

    .custom-order-header p {
        color: var(--text-muted);
    }

.form-section {
    margin-bottom: 2.5rem;
}

    .form-section h3 {
        margin-bottom: 1rem;
    }

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.custom-form textarea {
    margin-top: 1rem;
}

.form-actions {
    margin-top: 2rem;
    text-align: left;
}

.form-note {
    margin-top: 1rem;
    font-size: .85rem;
    color: var(--text-muted);
}
/* =========================
   CUSTOM ORDER SUCCESS
========================= */

.custom-success {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 1rem;
}

.success-card {
    max-width: 520px;
    background: #0f0f0f;
    border: 1px solid #1f1f1f;
    border-radius: 24px;
    padding: 3rem;
    text-align: center;
    box-shadow: 0 30px 60px rgba(0,0,0,.45);
}

.success-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--accent);
    color: #000;
    font-size: 2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.success-text {
    margin: 1rem 0 1.5rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.success-info {
    background: #141414;
    border: 1px solid #1f1f1f;
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    text-align: left;
}

    .success-info ul {
        margin: .8rem 0 0;
        padding-left: 1.2rem;
    }

    .success-info li {
        margin-bottom: .4rem;
        color: var(--text-muted);
    }

.success-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

@media (max-width: 768px) {

    .container-saint {
        padding: 1.5rem 1rem;
    }

    .hero {
        padding: 2rem 1.5rem;
    }

        .hero h1 {
            font-size: 2rem;
        }
}
@media (max-width: 600px) {

    .product-grid {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }

    .product-img {
        height: 200px;
    }
}
@media (max-width: 900px) {

    .product-details,
    .product-details-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .product-main-img {
        max-height: 420px;
    }

    .product-info h1 {
        font-size: 1.7rem;
    }
}
@media (max-width: 768px) {

    .cart-item {
        grid-template-columns: 1fr;
        gap: .6rem;
    }

        .cart-item img {
            width: 100%;
            height: 220px;
        }

    .cart-actions {
        flex-direction: column;
        align-items: stretch;
    }
}
@media (max-width: 900px) {

    .checkout-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .checkout-item {
        grid-template-columns: 1fr;
        gap: .6rem;
    }
}
@media (max-width: 768px) {

    .table-saint th {
        display: none;
    }

    .table-saint tr {
        display: block;
        margin-bottom: 1rem;
        background: rgba(255,255,255,.03);
        border-radius: 14px;
        padding: .8rem;
    }

    .table-saint td {
        display: flex;
        justify-content: space-between;
        border: none;
        padding: .4rem 0;
        font-size: .85rem;
    }
}
@media (max-width: 900px) {

    .admin-wrapper {
        padding: 0 1rem;
    }

    .image-grid {
        grid-template-columns: 1fr;
    }

    .variant-row,
    .variant-add-row,
    .add-variant {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 768px) {

    .form-grid {
        grid-template-columns: 1fr;
    }

    .success-card {
        padding: 2rem 1.5rem;
    }
}
@media (max-width: 600px) {

    .btn-saint,
    .btn-saint-outline,
    .btn-whatsapp {
        width: 100%;
        justify-content: center;
    }

    .nav-pill {
        margin-left: 0;
    }
}
.product-preview-img {
    transition: opacity .25s ease;
}

    .product-preview-img.fade-out {
        opacity: 0;
    }
.product-image {
    position: relative;
    overflow: hidden;
    width: 100%;
    aspect-ratio: 1 / 1;
}

    .product-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        position: absolute;
        inset: 0;
        transform: translateX(0);
        transition: transform .55s cubic-bezier(.4,0,.2,1);
    }

        /* Imagen que entra */
        .product-image img.slide-in {
            transform: translateX(100%);
        }

        /* Imagen que sale */
        .product-image img.slide-out {
            transform: translateX(-100%);
        }
.product-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (max-width: 768px) {

    .product-card {
        gap: .8rem;
    }

    .product-image {
        aspect-ratio: 4 / 3; /* ?? más natural en mobile */
    }

    .product-info {
        padding-top: .3rem;
    }

        .product-info h3 {
            font-size: .95rem;
            line-height: 1.3;
        }

        .product-info .price {
            font-size: .9rem;
        }

    .product-card .btn-saint {
        padding: .55rem .8rem;
        font-size: .85rem;
    }
}

/* =========================
   SEARCH – OVERRIDE DEFINITIVO
========================= */
@media (max-width: 1200px) {

    .topbar .nav-left form.saint-search-form.desktop-search {
        flex: 1 !important;
        width: 100% !important;
        max-width: none !important;
        min-width: 0 !important;
        display: flex !important;
    }

    .topbar .nav-left .saint-search-wrapper {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }

    .topbar .nav-left input.saint-search {
        width: 100% !important;
    }
}
