/* ============================================
   TIENDA - CATÁLOGO Y FICHA DE PRODUCTO
   ============================================ */

/* Breadcrumb */
.product-breadcrumb-muted {
    opacity: 0.8;
}

/* Ficha de producto - imágenes */
.product-image-zoom {
    position: relative;
    cursor: zoom-in;
}

.product-main-image {
    max-height: 500px;
    object-fit: contain;
    background: rgba(255, 255, 255, 1);
}

.product-image-fallback {
    height: 500px;
    display: none;
}

.product-image-empty {
    height: 500px;
}

.thumbnail-image {
    height: 80px;
    object-fit: cover;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 1);
}

.thumbnail-image:hover {
    opacity: 0.8;
}

.thumbnail-image.active {
    border-color: var(--aitana-primary) !important;
}

.product-thumbnails {
    padding: 1.5rem 1.5rem 1.5rem;
}

.product-image-container {
    padding: 0;
    overflow: hidden;
}

.glass-card.product-image-container {
    padding: 0;
}

.product-image-container:hover {
    transform: none !important;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37) !important;
}

.product-image-container.glass-card:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    transform: none !important;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37) !important;
}

/* Ficha de producto - info */
.product-stock-box {
    background: rgba(255, 255, 255, 0.1);
}

.product-description {
    line-height: 1.8;
    opacity: 0.9;
}

.product-sku-code {
    background: rgba(255, 255, 255, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    color: #fff;
}

.product-alert-warning {
    background: rgba(255, 193, 7, 0.2);
    border: 1px solid rgba(255, 193, 7, 0.5);
    color: #fff;
}

.product-info-box {
    background: rgba(255, 255, 255, 0.05);
}

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

/* Modal de zoom */
.product-zoom-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: none;
    cursor: zoom-out;
}

.product-zoom-image {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 96%;
    max-height: 96vh;
    object-fit: contain;
}

.product-zoom-close {
    position: absolute;
    top: 20px;
    right: 30px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 30px;
    padding: 5px 15px;
    cursor: pointer;
    border-radius: 5px;
    backdrop-filter: blur(10px);
}

/* Catálogo - tarjeta producto */
.product-card {
    padding: 0;
}

.glass-card.product-card {
    padding: 0;
    overflow: hidden;
}

.product-card-image {
    border-radius: 20px 20px 0 0;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    background: rgba(255, 255, 255, 1);
    display: block;
    box-sizing: border-box;
    overflow: hidden;
}

.product-card-placeholder {
    aspect-ratio: 1 / 1;
    border-radius: 20px 20px 0 0;
}

.product-card-placeholder--hidden {
    display: none;
}

.product-card-body {
    padding: 2rem;
    padding-top: 1rem;
}

.product-card-description {
    height: 60px;
    overflow: hidden;
}

/* ============================================
   CARRITO
   ============================================ */
.cart-table-col-qty {
    width: 180px;
}

.cart-table-col-actions {
    width: 100px;
}

.cart-item-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
}

.cart-item-thumb-fallback {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item-thumb-icon {
    font-size: 24px;
}

.cart-qty-input-lg {
    width: 70px;
}

.cart-item-thumb-sm {
    width: 80px;
    height: 80px;
    object-fit: cover;
    flex-shrink: 0;
}

.cart-item-thumb-fallback-sm {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cart-item-thumb-icon-sm {
    font-size: 32px;
}

.cart-qty-input-sm {
    width: 60px;
}

.cart-mobile-subtotal-divider {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cart-info-list {
    list-style: none;
    padding: 0;
}

.cart-summary-divider {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.cart-shipping-note {
    max-width: 150px;
}

/* ============================================
   PEDIDOS
   ============================================ */
.order-address-pre,
.order-notes-pre {
    white-space: pre-wrap;
}

/* ============================================
   ADMIN - PRODUCTOS
   ============================================ */
.admin-inline-form {
    display: inline;
}

.admin-products-page .table-dark {
    --bs-table-bg: transparent;
    --bs-table-border-color: rgba(255, 255, 255, 0.1);
}

.admin-products-page .table-dark tbody tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

.admin-products-page .breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
}

.admin-products-page .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.5);
}

/* Admin - pedidos */
.admin-orders-page .table-dark,
.admin-order-view-page .table-dark {
    --bs-table-bg: transparent;
    --bs-table-border-color: rgba(255, 255, 255, 0.1);
}

.admin-orders-page .table-dark tbody tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

.admin-orders-page .breadcrumb,
.admin-order-view-page .breadcrumb,
.admin-product-edit-page .breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
}

.admin-orders-page .breadcrumb-item + .breadcrumb-item::before,
.admin-order-view-page .breadcrumb-item + .breadcrumb-item::before,
.admin-product-edit-page .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.5);
}

.admin-order-view-page .form-select:focus {
    background-color: #1a1a1a;
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.1);
}

.admin-product-edit-page .form-control:focus,
.admin-product-edit-page .form-select:focus {
    background-color: #1a1a1a;
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.1);
}

.admin-product-create-page .form-control:focus,
.admin-product-create-page .form-select:focus {
    background-color: #1a1a1a;
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.1);
}

/* Admin - editar producto */
.admin-product-image-preview {
    max-height: 200px;
    width: 100%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background-color: rgba(255, 255, 255, 1);
}

.admin-file-input-label {
    cursor: pointer;
}

.text-muted-80 {
    opacity: 0.8;
}

/* Admin - dashboard */
.admin-dashboard-page .hover-scale {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.admin-dashboard-page .hover-scale:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px 0 rgba(31, 38, 135, 0.5);
}

/* Header tienda */
.header-spacer {
    height: 76px;
}

.header__user {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #fff;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    font-size: 0.9rem;
}

.header__user:hover {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
}

.header__user-name {
    max-width: 180px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Checkout */
.checkout-breadcrumb {
    background: transparent;
    padding: 0;
}

.checkout-shipping-hidden {
    display: none;
}

.payment-method-card {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.payment-method-label {
    cursor: pointer;
}

.payment-method-radio {
    width: 20px;
    height: 20px;
    margin-right: 1rem;
}

.coupon-message {
    display: none;
}

.checkout-summary-sticky {
    top: 100px;
}

.order-item-divider {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.order-item-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.checkout-summary-hr {
    border-color: rgba(255, 255, 255, 0.2);
}

.payment-method-card input[type="radio"]:checked + div {
    color: var(--aitana-primary) !important;
}

.payment-method-card:has(input[type="radio"]:checked) {
    border-color: var(--aitana-primary) !important;
    background: rgba(204, 0, 0, 0.1) !important;
}

.payment-method-card:hover {
    border-color: var(--aitana-primary) !important;
    transform: translateY(-2px);
}

/* Checkout redirect */
.checkout-spinner {
    width: 4rem;
    height: 4rem;
}

/* Usuarios */
.user-auth-card {
    max-width: 600px;
    margin: 0 auto;
}

.user-auth-card--small {
    max-width: 520px;
    margin: 0 auto;
}

.invoice-address {
    white-space: pre-wrap;
}
