/* 
 * Sistema de Diseño FWL v2 - Farmacia Yoama
 */

:root {
    /* Colors */
    --fwl-primary: #2a6496;
    --fwl-primary-hover: #1f4a6f;
    --fwl-primary-light: #6c8dab;
    --fwl-primary-dark: #1a3a5c;
    --fwl-secondary: #6c757d;
    --fwl-secondary-hover: #5a6268;
    --fwl-success: #28a745;
    --fwl-success-hover: #218838;
    --fwl-error: #dc3545;
    --fwl-error-hover: #c82333;
    --fwl-warning: #ffc107;
    --fwl-warning-hover: #e0a800;
    --fwl-info: #17a2b8;
    --fwl-bg: #f9fafb;
    --fwl-bg-alt: #ffffff;
    --fwl-text: #1f2937;
    --fwl-text-light: #6b7280;
    --fwl-border: #e5e7eb;

    /* Spacing */
    --fwl-space-xs: 0.25rem;
    --fwl-space-sm: 0.5rem;
    --fwl-space-md: 1rem;
    --fwl-space-lg: 1.5rem;
    --fwl-space-xl: 2rem;

    /* Radius */
    --fwl-radius-sm: 8px;
    --fwl-radius-md: 12px;
    --fwl-radius-lg: 16px;
    --fwl-radius-pill: 50px;

    /* Shadows */
    --fwl-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --fwl-shadow-md: 0 4px 6px rgba(0, 0, 0, 0.05);
    --fwl-shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --fwl-shadow-premium: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

    /* Gradients */
    --fwl-grad-primary: linear-gradient(135deg, #2a6496 0%, #1a3a5c 100%);
    --fwl-grad-accent: linear-gradient(135deg, #4ab7af 0%, #2a6496 100%);
    --fwl-grad-surface: linear-gradient(to bottom, #ffffff 0%, #f9fafb 100%);
}

body {
    background-color: var(--fwl-bg);
    color: var(--fwl-text);
    font-family: 'Poppins', sans-serif;
    line-height: 1.5;
}

@media (min-width: 1200px) {

    .h1,
    h1 {
        font-size: 1.8rem !important;
    }
}

.small,
small {
    font-size: 0.80rem;
}



.fwl-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--fwl-space-md);
}

/* Grids */
.fwl-grid-1 {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--fwl-space-md);
}

.fwl-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--fwl-space-md);
}

.fwl-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--fwl-space-md);
}

.fwl-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--fwl-space-md);
}

@media (max-width: 992px) {
    .fwl-grid-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .fwl-grid-3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 576px) {

    .fwl-grid-4,
    .fwl-grid-3,
    .fwl-grid-2 {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Grid Helpers */
.col-span-1 {
    grid-column: span 1;
}

.col-span-2 {
    grid-column: span 2;
}

.col-span-3 {
    grid-column: span 3;
}

.col-span-4 {
    grid-column: span 4;
}

.col-span-full {
    grid-column: 1 / -1;
}

/* Gaps */
.fwl-gap-xs {
    gap: var(--fwl-space-xs) !important;
}

.fwl-gap-sm {
    gap: var(--fwl-space-sm) !important;
}

.fwl-gap-md {
    gap: var(--fwl-space-md) !important;
}

.fwl-gap-lg {
    gap: var(--fwl-space-lg) !important;
}

.fwl-gap-xl {
    gap: var(--fwl-space-xl) !important;
}

.fwl-gap-x-xs {
    column-gap: var(--fwl-space-xs) !important;
}

.fwl-gap-x-sm {
    column-gap: var(--fwl-space-sm) !important;
}

.fwl-gap-x-md {
    column-gap: var(--fwl-space-md) !important;
}

.fwl-gap-x-lg {
    column-gap: var(--fwl-space-lg) !important;
}

.fwl-gap-y-xs {
    row-gap: var(--fwl-space-xs) !important;
}

.fwl-gap-y-sm {
    row-gap: var(--fwl-space-sm) !important;
}

.fwl-gap-y-md {
    row-gap: var(--fwl-space-md) !important;
}

.fwl-gap-y-lg {
    row-gap: var(--fwl-space-lg) !important;
}

/* Cards */
.fwl-card {
    background: var(--fwl-bg-alt);
    border-radius: var(--fwl-radius-md);
    padding: var(--fwl-space-lg);
    border: 1px solid var(--fwl-border);
    transition: transform 0.2s, box-shadow 0.2s;
}

.fwl-card:hover {
    box-shadow: var(--fwl-shadow-lg);
}

/* Buttons */
.fwl-btn-primary,
.fwl-btn-secondary,
.fwl-btn-danger,
.fwl-btn-success {
    padding: 0.75rem 1.5rem;
    border-radius: var(--fwl-radius-pill);
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.fwl-btn-primary {
    background: var(--fwl-primary);
    color: white;
}

.fwl-btn-primary:hover {
    background: var(--fwl-primary-hover);
}

.fwl-btn-secondary {
    background: #e2e8f0;
    color: #475569 !important;
    border: 1px solid #475569 !important;
}

.fwl-btn-secondary:hover {
    background: #cbd5e1;
    color: #1e293b !important;
    border-color: #1e293b !important;
}

.fwl-btn-danger {
    background: var(--fwl-error);
    color: white;
}

.fwl-btn-danger:hover {
    background: var(--fwl-error-hover);
}

.fwl-btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.fwl-btn-lg {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

/* Forms */
.fwl-form-group {
    margin-bottom: var(--fwl-space-md);
}

.fwl-label {
    display: block;
    margin-bottom: var(--fwl-space-xs);
    font-weight: 500;
    font-size: 0.875rem;
    color: var(--fwl-text-light);
}

.fwl-input,
.fwl-select,
.fwl-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: var(--fwl-radius-sm);
    border: 1px solid var(--fwl-border);
    background: var(--fwl-bg-alt);
    transition: border-color 0.2s;
}

.fwl-input:focus,
.fwl-select:focus,
.fwl-textarea:focus {
    border-color: var(--fwl-primary);
    box-shadow: 0 0 0 3px rgba(42, 100, 150, 0.1);
    outline: none;
}

.fwl-select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%236b7280' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 12px;
    padding-right: 2.5rem;
    cursor: pointer;
}

/* Utilities */
.fwl-mb-xs {
    margin-bottom: var(--fwl-space-xs);
}

.fwl-mb-sm {
    margin-bottom: var(--fwl-space-sm);
}

.fwl-mb-md {
    margin-bottom: var(--fwl-space-md);
}

.fwl-mb-lg {
    margin-bottom: var(--fwl-space-lg);
}

.fwl-mb-xl {
    margin-bottom: var(--fwl-space-xl);
}

/* Spacing Helpers (Custom) */
.fwl-p-xs {
    padding: var(--fwl-space-xs) !important;
}

.fwl-p-sm {
    padding: var(--fwl-space-sm) !important;
}

.fwl-p-md {
    padding: var(--fwl-space-md) !important;
}

.fwl-p-lg {
    padding: var(--fwl-space-lg) !important;
}

.fwl-p-xl {
    padding: var(--fwl-space-xl) !important;
}

.fwl-px-md {
    padding-left: var(--fwl-space-md) !important;
    padding-right: var(--fwl-space-md) !important;
}

.fwl-py-md {
    padding-top: var(--fwl-space-md) !important;
    padding-bottom: var(--fwl-space-md) !important;
}

.fwl-py-lg {
    padding-top: var(--fwl-space-lg) !important;
    padding-bottom: var(--fwl-space-lg) !important;
}

.fwl-py-xl {
    padding-top: var(--fwl-space-xl) !important;
    padding-bottom: var(--fwl-space-xl) !important;
}

.fwl-m-md {
    margin: var(--fwl-space-md) !important;
}

.fwl-mr-xs {
    margin-right: var(--fwl-space-xs) !important;
}

.fwl-mr-sm {
    margin-right: var(--fwl-space-sm) !important;
}

.fwl-mr-md {
    margin-right: var(--fwl-space-md) !important;
}

.fwl-ml-md {
    margin-left: var(--fwl-space-md) !important;
}

.fwl-mt-md {
    margin-top: var(--fwl-space-md) !important;
}

.fwl-mt-xl {
    margin-top: var(--fwl-space-xl) !important;
}

.fwl-text-primary {
    color: var(--fwl-primary) !important;
}

.fwl-text-secondary {
    color: var(--fwl-secondary) !important;
}

.fwl-text-success {
    color: var(--fwl-success) !important;
}

.fwl-text-danger {
    color: var(--fwl-error) !important;
}

.fwl-text-warning {
    color: var(--fwl-warning) !important;
}

.fwl-text-info {
    color: var(--fwl-info) !important;
}

.fwl-text-light {
    color: var(--fwl-text-light) !important;
}

.fwl-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.fwl-badge-success {
    background: #d1fae5;
    color: #065f46;
}

.fwl-badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.fwl-badge-error {
    background: #fee2e2;
    color: #991b1b;
}

.fwl-badge-info {
    background: #e0f2fe;
    color: #075985;
}

/* Tables */
.fwl-table {
    width: 100%;
    border-collapse: collapse;
}

.fwl-table th,
.fwl-table td {
    padding: var(--fwl-space-md);
    text-align: left;
    border-bottom: 1px solid var(--fwl-border);
}

.fwl-table th {
    background: var(--fwl-bg-alt);
    font-weight: 600;
    color: var(--fwl-text-light);
}

/* Utilities & Display */
.d-none {
    display: none !important;
}

.d-block {
    display: block !important;
}

.d-flex {
    display: flex !important;
}

.d-inline-flex {
    display: inline-flex !important;
}

@media (min-width: 768px) {
    .d-md-block {
        display: block !important;
    }

    .d-md-flex {
        display: flex !important;
    }

    .d-md-none {
        display: none !important;
    }
}

.flex-column {
    flex-direction: column !important;
}

.align-items-center {
    align-items: center !important;
}

.justify-content-center {
    justify-content: center !important;
}

.justify-content-between {
    justify-content: space-between !important;
}

.flex-grow-1 {
    flex-grow: 1 !important;
}

.flex-wrap {
    flex-wrap: wrap !important;
}

.w-100 {
    width: 100% !important;
}

.h-100 {
    height: 100% !important;
}

.text-center {
    text-align: center !important;
}

.text-end {
    text-align: right !important;
}

.text-start {
    text-align: left !important;
}

.text-uppercase {
    text-transform: uppercase !important;
}

.position-relative {
    position: relative !important;
}

.position-absolute {
    position: absolute !important;
}

.sticky-top {
    position: sticky;
    top: 0;
    z-index: 1020;
}

.overflow-hidden {
    overflow: hidden !important;
}

.opacity-75 {
    opacity: 0.75 !important;
}

.opacity-50 {
    opacity: 0.5 !important;
}

.opacity-25 {
    opacity: 0.25 !important;
}

.cursor-pointer {
    cursor: pointer !important;
}

.rounded-pill {
    border-radius: var(--fwl-radius-pill) !important;
}

.rounded-circle {
    border-radius: 50% !important;
}

.rounded-4 {
    border-radius: 1rem !important;
}

.rounded-3 {
    border-radius: 0.5rem !important;
}

/* Spacing Helpers */
.me-1 {
    margin-right: 0.25rem !important;
}

.me-2 {
    margin-right: 0.5rem !important;
}

.me-3 {
    margin-right: 1rem !important;
}

.ms-1 {
    margin-left: 0.25rem !important;
}

.ms-2 {
    margin-left: 0.5rem !important;
}

.mt-1 {
    margin-top: 0.25rem !important;
}

.mt-2 {
    margin-top: 0.5rem !important;
}

.mt-3 {
    margin-top: 1rem !important;
}

.mb-0 {
    margin-bottom: 0 !important;
}

.mb-1 {
    margin-bottom: 0.25rem !important;
}

.mb-2 {
    margin-bottom: 0.5rem !important;
}

.p-2 {
    padding: 0.5rem !important;
}

.p-3 {
    padding: 1rem !important;
}

.px-3 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
}

.px-4 {
    padding-left: 1.5rem !important;
    padding-right: 1.5rem !important;
}

.px-5 {
    padding-left: 3rem !important;
    padding-right: 3rem !important;
}

.py-2 {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}

.py-3 {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
}

.pt-3 {
    padding-top: 1rem !important;
}

.pt-4 {
    padding-top: 1.5rem !important;
}

/* Botón Flotante del Carrito */
.floating-cart-button {
    position: fixed;
    bottom: 30px;
    right: 20px;
    background-color: rgba(42, 100, 150, 0.85);
    border-radius: 50%;
    width: 55px;
    /* Ligeramente ajustado para armonía */
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white !important;
    text-decoration: none !important;
    font-size: 24px;
    z-index: 1050;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.floating-cart-button:hover {
    background-color: rgba(42, 100, 150, 1);
    transform: scale(1.1);
}

@media (max-width: 576px) {
    .floating-cart-button {
        right: 12px;
        bottom: 30px;
        /* Sincronizado con scroll-to-top */
        width: 48px;
        height: 48px;
        font-size: 20px;
    }

    .floating-cart-button .cart-count {
        width: 20px;
        height: 20px;
        font-size: 10px;
    }
}

.floating-cart-button .cart-count {
    position: absolute;
    top: 0;
    right: 0;
    background-color: #e74c3c;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: white;
    font-weight: bold;
    border: 2px solid #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Lightbox / Modal de Imagen */
.lightbox-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    cursor: pointer;
    backdrop-filter: blur(5px);
}

.lightbox-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 90%;
    max-height: 90vh;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border: 5px solid white;
    border-radius: 4px;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 25px;
    color: white;
    font-size: 45px;
    cursor: pointer;
    background: none;
    border: none;
    line-height: 1;
    z-index: 10000;
}

/* Ajustes Tarjetas de Productos */
.img-product {
    cursor: pointer;
    transition: transform 0.3s ease;
}

.img-product:hover {
    transform: scale(1.05);
}

.product-card-title {
    font-weight: bold;
    color: #333;
    font-size: 14px;
    line-height: 1.3;
    margin-bottom: 5px;
}

.product-card-principio {
    font-size: 12px;
    color: var(--fwl-primary);
    text-decoration: underline;
    line-height: 1.2;
    display: inline-block;
}

/* Dashboard Cards Modern */
.dashboard-card-modern {
    background: white;
    border-radius: 20px;
    padding: 35px 20px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid #f0f4f8;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.dashboard-card-modern:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: var(--fwl-secondary);
}

.dashboard-card-modern i {
    font-size: 3rem;
    color: var(--fwl-secondary);
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.dashboard-card-modern:hover i {
    color: var(--fwl-primary);
    transform: scale(1.1);
}

.dashboard-card-modern span {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    display: block;
}

.dashboard-card-modern::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--fwl-secondary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

/* Glassmorphism & Premium Utilities */
.fwl-glass {
    background: rgba(255, 255, 255, 0.7) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
}

.fwl-bg-primary {
    background: var(--fwl-primary) !important;
    color: white !important;
}

.fwl-bg-secondary {
    background: var(--fwl-grad-accent) !important;
    color: white !important;
}

.fwl-bg-accent {
    background: #4ab7af !important;
    color: white !important;
}

.fwl-bg-light {
    background: #f1f5f9 !important;
}

.fwl-bg-success {
    background: #28a745 !important;
    color: white !important;
}

.fwl-bg-danger,
.fwl-bg-error {
    background: #dc3545 !important;
    color: white !important;
}

.fwl-bg-info {
    background: #17a2b8 !important;
    color: white !important;
}

.fwl-bg-warning {
    background: #ffc107 !important;
    color: white !important;
}

.fwl-bg-dark {
    background: #1f2937 !important;
    color: white !important;
}

.hover-up {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.hover-up:hover {
    transform: translateY(-8px) !important;
    box-shadow: var(--fwl-shadow-premium) !important;
}

.extra-small {
    font-size: 0.75rem !important;
}

.fwl-border {
    border: 1px solid var(--fwl-border) !important;
}

.fwl-border-top {
    border-top: 1px solid var(--fwl-border) !important;
}

.fwl-border-bottom {
    border-bottom: 1px solid var(--fwl-border) !important;
}

.fwl-pagination-container {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

.fwl-pagination {
    display: flex;
    list-style: none;
    padding: 0;
    gap: 0.25rem;
    flex-wrap: wrap;
    justify-content: center;
}

@media (min-width: 768px) {
    .fwl-pagination {
        gap: 0.5rem;
        flex-wrap: nowrap;
    }
}

.fwl-pagination .page-item .page-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid var(--fwl-border);
    background: white;
    color: var(--fwl-text);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.fwl-pagination .page-item.active .page-link {
    background: var(--fwl-primary);
    color: white;
    border-color: var(--fwl-primary);
}

.fwl-label-small {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--fwl-text-light);
    margin-bottom: 0.5rem;
    display: block;
}

[x-cloak] {
    display: none !important;
}

/* Loading Overlay Styles Global */
.fwl-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(8px);
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.fwl-loader {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(25, 135, 84, 0.1);
    border-top: 5px solid #198754;
    border-radius: 50%;
    animation: fwl-spin 1s linear infinite;
    margin-bottom: 2rem;
}

@keyframes fwl-spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* REVISION: Dynamic Height for Desktop Product Cards */
@media (min-width: 768px) {
    .product-card {
        height: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
    }

    /* Ensure content expands to push buttons down */
    .product-card>div:nth-child(2) {
        flex-grow: 1 !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: flex-start !important;
    }
}

/* --- APP-FIRST E-COMMERCE DESIGN SYSTEM --- */

/* 1. Quick Action Chips */
.fwl-chips-container {
    display: flex;
    overflow-x: auto;
    gap: 10px;
    padding: 5px 2px 15px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
}

.fwl-chips-container::-webkit-scrollbar {
    display: none;
}

.fwl-chip {
    white-space: nowrap;
    padding: 8px 20px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 500;
    color: #495057;
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
}

.fwl-chip:hover,
.fwl-chip.active {
    background: var(--fwl-primary);
    color: white !important;
    border-color: var(--fwl-primary);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 150, 204, 0.25);
}

/* 2. Executive Product Card */
.fwl-card-premium {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 24px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.fwl-card-premium:hover {
    transform: translateY(-6px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1) !important;
}

.fwl-product-img-wrapper {
    overflow: hidden;
    position: relative;
    border-radius: 20px 20px 0 0;
}

.fwl-product-img-wrapper img {
    transition: transform 0.5s ease;
}

.fwl-card-premium:hover .fwl-product-img-wrapper img {
    transform: scale(1.08);
}

/* 3. Glass Badge */
.fwl-badge-glass {
    background: rgba(40, 167, 69, 0.82) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: white !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-weight: 700;
    font-size: 0.7rem;
    letter-spacing: 0.5px;
}

@media (max-width: 576px) {
    .fwl-badge-glass {
        font-size: 0.85rem !important;
        /* Aumentado para móvil */
        padding: 4px 12px !important;
    }

    #search-results-header h3 {
        font-size: 1rem !important;
    }
}

/* 4. Compact Stepper */
.fwl-stepper {
    display: inline-flex;
    align-items: center;
    background: #f1f3f5;
    border-radius: 50px;
    padding: 4px;
    transition: background 0.2s;
}

.fwl-stepper.has-items {
    background: rgba(0, 150, 204, 0.08);
}

.fwl-stepper button {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border: none;
    color: var(--fwl-primary);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: all 0.2s;
}

.fwl-stepper button:active {
    transform: scale(0.9);
}

.fwl-stepper button:disabled {
    opacity: 0.5;
    color: #adb5bd;
}

/* 5. Price Hierarchy */
.fwl-price-main {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--fwl-primary);
    letter-spacing: -0.5px;
}

.fwl-price-sub {
    font-size: 0.9rem;
    color: #6c757d;
    font-weight: 500;
}

.fwl-price-old {
    font-size: 0.85rem;
    text-decoration: line-through;
    color: #adb5bd;
}

/* 6. Search & Filter Layout */
.fwl-search-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

@media (min-width: 768px) {
    .fwl-search-container {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}

.fwl-btn-reset {
    background: #e2e8f0;
    color: #475569 !important;
    border: 1px solid #475569 !important;
    border-radius: 10px;
    padding: 0.5rem 1rem;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 38px;
}

.fwl-btn-reset:hover {
    background: #cbd5e1;
    color: #1e293b !important;
    border-color: #1e293b !important;
}

.fwl-mobile-filter-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 10px;
}

@media (min-width: 768px) {
    .fwl-mobile-filter-row {
        margin-top: 0;
        justify-content: flex-end;
    }
}

/* --- UTILITIES & POLISH --- */

.transition-all {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.hover-grow {
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.hover-grow:hover {
    transform: scale(1.02);
}

.hover-text-primary {
    transition: color 0.2s ease !important;
}

.hover-text-primary:hover {
    color: var(--fwl-primary) !important;
}

.font-bold {
    font-weight: 700 !important;
}

.uppercase {
    text-transform: uppercase !important;
}

.grayscale-filter {
    filter: grayscale(1);
    opacity: 0.7;
}

.shadow-md {
    box-shadow: var(--fwl-shadow-md) !important;
}

.shadow-lg {
    box-shadow: var(--fwl-shadow-lg) !important;
}

.shadow-premium {
    box-shadow: var(--fwl-shadow-premium) !important;
}