/**
 * Estilos Personalizados - Iosfera E-commerce
 */

/* ==========================================
   GENERAL
   ========================================== */

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* ==========================================
   NAVBAR
   ========================================== */

.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

.navbar-dark .navbar-nav .nav-link {
    transition: color 0.3s;
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: #ffc107;
}

.navbar-dark .navbar-nav .nav-link.active {
    color: #ffc107;
    font-weight: 600;
}

/* ==========================================
   DROPDOWNS Y SUBMENÚS
   ========================================== */

.dropdown-menu {
    border-radius: 0.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: none;
}

.dropdown-item {
    padding: 0.5rem 1.5rem;
    transition: all 0.2s;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    padding-left: 1.75rem;
}

/* Submenús para desktop */
@media (min-width: 992px) {
    .dropdown-menu .dropdown-menu {
        left: 100%;
        top: -7px;
        margin-left: 0.125rem;
    }

    .dropend .dropdown-toggle::after {
        border-left: 0.3em solid transparent;
        border-right: 0;
        border-top: 0.3em solid transparent;
        border-bottom: 0.3em solid transparent;
        border-left-color: currentColor;
        margin-left: 0.5em;
    }

    .dropdown-menu .dropdown-menu {
        display: none;
    }

    .dropdown-menu .dropdown-item.dropdown-toggle:hover + .dropdown-menu,
    .dropdown-menu .dropdown-menu:hover {
        display: block;
    }
}

/* ==========================================
   PRODUCT CARDS
   ========================================== */

.product-card {
    transition: all 0.3s;
    border: none;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border-radius: 0.5rem;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.product-card .card-img-top {
    transition: transform 0.3s;
}

.product-card:hover .card-img-top {
    transform: scale(1.05);
}

.product-image {
  width: 100%;
  height: auto;
  object-fit: contain;
  padding: 1rem;
}

/* ==========================================
   PRECIOS
   ========================================== */

.price-original {
    text-decoration: line-through;
    color: #999;
    font-size: 0.9rem;
}

.price-promo {
    color: #dc3545;
    font-weight: bold;
    font-size: 1.2rem;
}

/* ==========================================
   BADGES
   ========================================== */

.badge {
    font-weight: 500;
    padding: 0.5em 0.75em;
}

/* ==========================================
   BANNER HERO
   ========================================== */

.bg-light.rounded-3 {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white;
}

.bg-light.rounded-3 h1,
.bg-light.rounded-3 p {
    color: white;
}

.bg-light.rounded-3 .btn-primary {
    background-color: white;
    color: #667eea;
    border-color: white;
}

.bg-light.rounded-3 .btn-primary:hover {
    background-color: #f8f9fa;
    color: #764ba2;
}

/* ==========================================
   FOOTER
   ========================================== */

footer {
    margin-top: auto;
    background-color: #212529 !important;
}

footer a {
    transition: color 0.3s;
}

footer a:hover {
    color: #ffc107 !important;
}

/* ==========================================
   BOTONES
   ========================================== */

.btn-primary {
    background-color: #0d6efd;
    border-color: #0d6efd;
    transition: all 0.3s;
}

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-outline-primary {
    transition: all 0.3s;
}

.btn-outline-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* ==========================================
   CARRITO BADGE
   ========================================== */

#cart-count {
    font-size: 0.7rem;
    min-width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* ==========================================
   NOTIFICACIONES
   ========================================== */

.cart-notification {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.cart-notification-content {
    display: flex;
    align-items: center;
    font-size: 14px;
    font-weight: 500;
}

/* ==========================================
   GALERÍA DE PRODUCTO
   ========================================== */

.thumbnail-card {
    transition: all 0.3s;
    border: 2px solid transparent;
    cursor: pointer;
}

.thumbnail-card:hover {
    border-color: #0d6efd;
    transform: scale(1.05);
}

.thumbnail-card.active {
    border-color: #0d6efd;
    box-shadow: 0 0 10px rgba(13, 110, 253, 0.5);
}

.thumbnail-image {
    transition: all 0.3s;
}

/* ==========================================
   RESPONSIVE
   ========================================== */

@media (max-width: 768px) {
    .product-image {
      width: 100%;
      height: auto;
      object-fit: contain;
    }

    .thumbnail-image {
        height: 60px;
    }

    .navbar-brand {
        font-size: 1.25rem;
    }

    .display-5 {
        font-size: 2rem;
    }
}

/* ==========================================
   UTILIDADES
   ========================================== */

.fw-bold {
    font-weight: 700;
}

.text-muted {
    color: #6c757d !important;
}

.shadow-sm {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}

.rounded-3 {
    border-radius: 0.5rem !important;
}

/* ==========================================
   FOOTER STYLES
========================================== */
footer a:hover {
    color: #fff !important;
    transition: color 0.3s ease;
}

.sic-link img {
    transition: opacity 0.3s ease;
}

.sic-link img:hover {
    opacity: 0.8;
}

/* ==========================================
   INFO PAGES
========================================== */
.content-page {
    font-size: 1.05rem;
}

.content-page h2 {
    color: #0d6efd;
    margin-top: 2rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e9ecef;
}

.content-page h3 {
    color: #495057;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.content-page p {
    line-height: 1.8;
    margin-bottom: 1rem;
    text-align: justify;
}

.content-page ul,
.content-page ol {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

.content-page li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}
