/* Modern Redesign - Premium Aesthetic */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600&family=Outfit:wght@400;700;900&display=swap');

:root {
    --bg-dark: #0f0f13;
    --bg-gradient: linear-gradient(135deg, #0f0f13 0%, #1a1a2e 100%);
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --accent-primary: #ff6a00;
    --accent-secondary: #ff9d00;
    --accent-rgb: 255, 106, 0;
    --accent-gradient: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --shadow-soft: 0 10px 40px rgba(0, 0, 0, 0.3);
    --radius: 16px;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    background: var(--bg-gradient);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.7;
    min-height: 100vh;
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: normal;
}

h1 { font-size: 3.5rem; margin-bottom: 1rem; }
h2 { 
    font-size: 2.5rem; 
    margin-bottom: 2rem; 
    text-align: center;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Text page specific overrides */
.page-container h2 {
    font-size: 1.5rem;
    text-align: left;
    background: none;
    -webkit-text-fill-color: var(--accent-primary);
    color: var(--accent-primary);
    margin-bottom: 0.5rem;
    margin-top: 2rem;
}

.badge {
    display: inline-block;
    padding: 5px 15px;
    background: rgba(var(--accent-rgb), 0.2);
    color: var(--accent-primary);
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 1rem;
    border: 1px solid rgba(var(--accent-rgb), 0.3);
}

/* Layout */
.product-layout {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 50px 20px;
}

.glass-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: 1400px;
    width: 100%;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
    animation: fadeIn 0.8s ease-out;
}

.product-gallery {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: rgba(0, 0, 0, 0.2);
}

.main-image {
    width: 100%;
    height: 500px;
    min-height: 500px;
    max-height: 500px;
    flex: none;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    background: #0a0a0c; /* Subtle dark background so different aspect ratios blend well */
    border-radius: 0;
}

.main-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.thumb-grid {
    display: flex;
    gap: 10px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.3);
}

.gallery-description {
    padding: 25px 20px;
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
    flex: 1;
}

.gallery-description h2, .mobile-description h2 {
    font-size: 1.5rem;
    text-align: left;
    background: none;
    -webkit-text-fill-color: var(--accent-primary);
    color: var(--accent-primary);
    margin-top: 0;
    margin-bottom: 4px;
}

.gallery-description ul, .mobile-description ul {
    margin-left: 20px;
    margin-bottom: 15px;
}

.gallery-description li, .mobile-description li {
    margin-bottom: 5px;
}

.gallery-description p, .mobile-description p {
    margin-bottom: 15px;
}

.mobile-description {
    display: none;
}

.thumb {
    width: 70px;
    height: 70px;
    border-radius: 8px;
    cursor: pointer;
    opacity: 0.6;
    border: 2px solid transparent;
    overflow: hidden;
    flex-shrink: 0;
}

.thumb.active {
    opacity: 1;
    border-color: var(--accent-primary);
}

.thumb img { width: 100%; height: 100%; object-fit: contain; border-radius: 6px; background: #111; }

.product-details {
    padding: 1.5rem 2.5rem 2.5rem 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.price-tag {
    font-size: 3rem;
    font-weight: 900;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem;
}

.description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 45px;
    border-radius: var(--radius);
    text-transform: uppercase;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 1.1rem;
    font-family: var(--font-heading);
}

.btn-primary {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 10px 30px rgba(var(--accent-rgb), 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(var(--accent-rgb), 0.6);
}

/* Variant Buttons */
.variant-btn {
    padding: 10px 20px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    border-radius: 8px;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.2s ease;
}

.variant-btn:hover:not(:disabled) {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.3);
}

.variant-btn.selected {
    border-color: var(--accent-primary);
    background: rgba(var(--accent-rgb), 0.15);
    box-shadow: 0 0 15px rgba(var(--accent-rgb), 0.3);
}

.variant-btn.out-of-stock {
    opacity: 0.5;
    cursor: not-allowed;
    background: rgba(0,0,0,0.2);
    text-decoration: line-through;
}

/* Quantity Box */
.qty-box {
    display: flex;
    align-items: center;
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    flex-shrink: 0;
    height: 50px;
}

.qty-box button {
    background: transparent;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 1.5rem;
    width: 40px;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.2s;
}

.qty-box button:hover {
    background: rgba(255, 255, 255, 0.1);
}

.qty-box input {
    width: 40px;
    height: 100%;
    text-align: center;
    background: transparent;
    border: none;
    color: white;
    font-size: 1.2rem;
    font-weight: bold;
    padding: 0;
    -moz-appearance: textfield;
}

.qty-box input::-webkit-outer-spin-button,
.qty-box input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.shipping-info {
    margin-top: 15px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-align: center;
}

/* Sections */
section { padding: 50px 20px; }
.section-container { max-width: 1200px; margin: 0 auto; }

.features { background: rgba(255, 255, 255, 0.02); }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.feature-card { background: var(--glass-bg); padding: 30px 25px 25px; border-radius: var(--radius); border: 1px solid var(--glass-border); text-align: center; }
.feature-card .icon { font-size: 3rem; margin-bottom: 12px; }
.feature-card h3 { margin-bottom: 12px; font-size: 1.1rem; }
.feature-card p { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.6; }

.reviews { background: transparent; }
.review-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.review-card { background: var(--glass-bg); padding: 30px; border-radius: var(--radius); border-left: 4px solid #ff7e5f; }
.review-card .stars { color: #feb47b; margin-bottom: 10px; }
.review-card .author { display: block; margin-top: 15px; font-weight: 600; color: var(--text-secondary); }

.faq { padding: 50px 20px; }
.faq h2 { text-align: center; margin-bottom: 50px; }
.faq-dynamic-content { max-width: 800px; margin: 0 auto; line-height: 1.8; color: var(--text-secondary); }
.faq-dynamic-content h3 {
    font-size: 1.15rem;
    color: var(--text-primary);
    margin-top: 0;
    margin-bottom: 4px;
    font-weight: 700;
}
.faq-dynamic-content h4 {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-top: 0;
    margin-bottom: 4px;
}
.faq-dynamic-content p {
    margin-bottom: 15px;
}
.faq-dynamic-content strong { 
    color: var(--accent-secondary); 
    font-size: 1.2rem;
}

footer { padding: 80px 20px; background-color: #080a0c; border-top: 1px solid var(--glass-border); text-align: center; color: var(--text-secondary); }

.video-container { margin-top: 2rem; border-radius: 12px; overflow: hidden; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 992px) {
    .glass-container { grid-template-columns: 1fr; }
    .product-details { padding: 3rem 2rem; }
    h1 { font-size: 2.5rem; }
    .main-image { height: 500px !important; min-height: 500px !important; }
}

/* Header & Nav */
.site-header {
    background: rgba(15, 15, 19, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 5px 0;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.8rem;
    cursor: pointer;
    z-index: 102;
    width: 40px;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 900;
    color: #fff;
    text-decoration: none;
    letter-spacing: 1px;
}

.desktop-nav { display: flex; gap: 20px; }
.desktop-nav a { color: var(--text-secondary); text-decoration: none; font-weight: 600; transition: color 0.3s; }
.desktop-nav a:hover { color: #ff7e5f; }

.cart-toggle {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: #fff;
    padding: 8px 15px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}
.cart-toggle:hover { background: rgba(255,255,255,0.1); }

/* Language Switcher */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-right: 8px;
}
.lang-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 4px 6px;
    border-radius: 4px;
    transition: color 0.2s, background 0.2s;
}
.lang-link:hover {
    color: #fff;
    background: rgba(255,255,255,0.08);
}
.lang-link.active {
    color: var(--accent-primary);
}
.lang-sep {
    color: var(--glass-border);
    font-size: 0.8rem;
}
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.currency-switcher select {
    background: rgba(255,255,255,0.08);
    color: #ccc;
    border: 1px solid var(--glass-border);
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 0.8rem;
    font-family: inherit;
    cursor: pointer;
    appearance: auto;
    -webkit-appearance: auto;
    outline: none;
    transition: border-color 0.2s, color 0.2s;
}
.currency-switcher select:hover,
.currency-switcher select:focus {
    border-color: var(--accent-primary);
    color: #fff;
}
.currency-switcher select option {
    background: #1a1a2e;
    color: #fff;
}
.badge-count { background: #ff7e5f; color: #fff; padding: 2px 6px; border-radius: 10px; font-size: 0.8rem; display: none; }

/* Cart Modal */
.cart-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.7); backdrop-filter: blur(5px);
    z-index: 999; opacity: 0; pointer-events: none; transition: opacity 0.3s;
}
.cart-overlay.active { opacity: 1; pointer-events: auto; }

.cart-modal {
    position: fixed; top: 0; right: -400px; width: 400px; max-width: 100%; height: 100vh;
    background: #1a1a2e; z-index: 1000; transition: right 0.3s ease;
    border-left: 1px solid var(--glass-border); display: flex; flex-direction: column;
}
.cart-modal.active { right: 0; }

.cart-header { padding: 20px; border-bottom: 1px solid var(--glass-border); display: flex; justify-content: space-between; align-items: center; }
.close-btn { background: none; border: none; color: #fff; font-size: 2rem; cursor: pointer; }
.cart-items { padding: 20px; flex-grow: 1; overflow-y: auto; }
.cart-footer { padding: 20px; border-top: 1px solid var(--glass-border); background: rgba(0,0,0,0.2); }
.cart-total { display: flex; justify-content: space-between; font-size: 1.2rem; font-weight: bold; margin-bottom: 15px; }

.cart-item { display: flex; gap: 15px; margin-bottom: 20px; border-bottom: 1px solid rgba(255,255,255,0.05); padding-bottom: 15px; }
.cart-item img { width: 60px; height: 60px; border-radius: 8px; object-fit: cover; }
.cart-item-details h4 { font-size: 1rem; margin-bottom: 5px; }
.cart-item-price { color: #ff7e5f; font-weight: bold; }
.cart-qty-controls { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.cart-qty-controls button { background: var(--glass-bg); border: 1px solid var(--glass-border); color: #fff; width: 25px; height: 25px; border-radius: 5px; cursor: pointer; }

/* Cookie Banner */
.cookie-banner {
    position: fixed; bottom: 0; left: 0; right: 0;
    background: rgba(15, 15, 19, 0.95); backdrop-filter: blur(10px);
    border-top: 1px solid var(--glass-border); padding: 15px; z-index: 1000;
    display: flex; justify-content: center;
}
.cookie-content { display: flex; align-items: center; gap: 20px; max-width: 1200px; width: 100%; justify-content: space-between; }
.cookie-content p { font-size: 0.9rem; margin: 0; }

/* Mobile Adjustments */
@media (max-width: 768px) {
    .header-container { padding: 0 20px; }
    
    /* Show hamburger button */
    .menu-toggle { display: block; }
    
    /* Nav becomes a full-width dropdown */
    .desktop-nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: #1a1a2e;
        padding: 20px;
        border-bottom: 1px solid var(--glass-border);
        z-index: 101;
        gap: 15px;
        text-align: center;
        box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    }
    .desktop-nav.active { display: flex; }
    
    /* Hide "Varukorg" text, keep icon + badge */
    .cart-text { display: none; }
    .cart-toggle { padding: 8px 10px; gap: 4px; }
    .cart-toggle svg { margin: 0 !important; }

    .product-layout { padding: 20px 0; }
    .glass-container { border-radius: 0; border-left: none; border-right: none; }
    .product-details { padding: 2rem 1.5rem; }
    .cookie-content { flex-direction: column; text-align: center; }
    
    /* Mobile Gallery - strictly fixed height, no jumping */
    .product-gallery { 
        position: relative !important; 
        overflow: hidden !important;
        height: auto !important;
        flex: none !important;
    }
    .main-image { 
        min-height: 350px !important;
        height: 350px !important;
        max-height: 350px !important;
        width: 100% !important;
        overflow: hidden !important;
        flex: none !important;
        border-radius: 8px !important;
        background: #0a0a0c !important;
    }
    .main-image img { 
        object-fit: contain !important; 
        width: 100% !important; 
        height: 100% !important; 
        display: block !important;
    }
    .thumb img { object-fit: contain !important; background: #111; }
    .thumb-grid { justify-content: center; overflow-x: auto; padding-bottom: 10px; flex-wrap: nowrap; }
    .gallery-description { display: none; }
    
    .mobile-description {
        display: block;
        margin-top: 15px;
        color: var(--text-secondary);
        font-size: 1rem;
        line-height: 1.6;
    }
    
    /* Make buttons more compact on mobile */
    .btn {
        padding: 12px 20px;
        font-size: 0.95rem;
    }
    
    .buy-action {
        flex-direction: row;
        align-items: stretch;
    }
    
    .qty-box {
        height: 48px;
    }
    
    .qty-box button {
        width: 35px;
    }
    
    .qty-box input {
        width: 35px;
    }
}

/* Description H2 Styling */
.gallery-description {
    margin-top: 15px;
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
}
.gallery-description h2, .mobile-description h2 {
    font-size: 1.5rem;
    text-align: left;
    margin-top: 2rem;
    margin-bottom: 0.5rem;
    padding: 0;
    line-height: 1.3;
}
.gallery-description h2:first-child, .mobile-description h2:first-child {
    margin-top: 0;
}
.gallery-description ul, .mobile-description ul {
    margin-left: 20px;
    margin-bottom: 1rem;
}