/* Modern Tienda - CSS Overhaul */
/* Base Variables & Fonts */
:root {
    --bg-dark: #0f1012;
    --card-bg: #18191c;
    --card-hover: #222429;
    --accent-gold: #d4af37;
    --accent-blue: #3b82f6;
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --border-color: #2d3035;
}

body {
    background-color: var(--bg-dark) !important;
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(59, 130, 246, 0.05) 0%, transparent 25%), 
        radial-gradient(circle at 85% 30%, rgba(212, 175, 55, 0.05) 0%, transparent 25%);
    min-height: 100vh;
}

.tienda-container {
    padding: 60px 20px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Hero Section Styling */
.hero-title {
    font-family: 'Cinzel', serif;
    font-size: 3rem !important;
    font-weight: 700;
    margin-bottom: 20px;
    background: linear-gradient(to right, #ffffff, #9ca3af);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 2px;
    text-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.hero-subtitle {
    font-family: 'Roboto', sans-serif;
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 50px auto;
    line-height: 1.6;
}

/* Country Selector - Native Select Styled */
.country-selector-wrapper {
    position: relative;
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
    z-index: 100;
}

.country-select {
    appearance: none;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 8px 30px 8px 15px;
    border-radius: 5px;
    font-size: 0.9rem;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23ffffff' 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 10px center;
    outline: none;
    transition: all 0.2s;
}

.country-select:hover, .country-select:focus {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: var(--accent-gold);
}

.country-select option {
    background-color: #1e1e21;
    color: #fff;
    padding: 10px;
}

/* Products Grid */
.tienda-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 60px;
}

/* Premium Card Design */
.product-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    border-color: var(--accent-gold);
    z-index: 2;
}

/* Image Area */
.card-image-wrapper {
    height: 320px;
    overflow: hidden;
    position: relative;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.card-image {
    width: 100%;
    height: 100%;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transition: transform 0.5s ease;
}

.product-card:hover .card-image {
    transform: scale(1.08);
}

/* Store Badge - Floating Top Right */
.store-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 12px;
    border-radius: 30px;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.store-ml { background-color: #ffe600; color: #2d3277; }
.store-amazon { background-color: #fff; color: #000; border: 1px solid #ddd; }
.store-other { background-color: #374151; color: #fff; border: 1px solid #4b5563; }

/* Card Content */
.card-details {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    background: linear-gradient(to bottom, var(--card-bg), #1a1b1f);
}

.card-details h2 {
    font-family: 'Roboto', sans-serif;
    font-size: 1.15rem;
    font-weight: 500;
    color: var(--text-primary);
    margin: 0 0 15px 0;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 3.4em;
}

/* Price & Action */
.price-container {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.price {
    font-family: 'Cinzel', serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--accent-gold);
    letter-spacing: 0;
}

.btn-buy {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-buy::after {
    content: '→';
    font-family: monospace;
    transition: transform 0.3s ease;
    display: inline-block;
}

.product-card:hover .btn-buy {
    background: var(--text-primary);
    color: #000;
    border-color: var(--text-primary);
}

.product-card:hover .btn-buy::after {
    transform: translateX(4px);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-card {
    animation: fadeInUp 0.6s ease backwards;
}

.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.15s; }
.product-card:nth-child(3) { animation-delay: 0.2s; }
.product-card:nth-child(4) { animation-delay: 0.25s; }

/* Responsive */
@media (max-width: 768px) {
    .country-selector-wrapper {
        justify-content: center;
        margin-bottom: 20px;
    }
    .hero-title {
        font-size: 2.5rem !important;
    }
    .tienda-container {
        padding-top: 30px;
    }
}
