/* Stenvaag 2.0 — Design System (Power.no-inspired) */

/* ─── Variables ─── */
:root {
    --sv-primary: #1a3a1a;
    --sv-primary-light: #2d5a2d;
    --sv-secondary: #c49a1a;
    --sv-dark: #111;
    --sv-gray-100: #f8f9fa;
    --sv-gray-200: #e9ecef;
    --sv-gray-300: #dee2e6;
    --sv-gray-500: #6c757d;
    --sv-gray-700: #495057;
    --sv-gray-900: #212529;
    --sv-white: #fff;
    --sv-success: #198754;
    --sv-danger: #dc3545;
    --sv-warning: #ffc107;
    --sv-radius: 8px;
    --sv-shadow: 0 2px 8px rgba(0,0,0,0.08);
    --sv-shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
    --sv-header-height: 64px;
    --sv-container-width: 1280px;
    --sv-category-bar-height: 50px;
    --sv-site-font: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --sv-site-font-size: 1rem;
}

.sv-cart-thumb {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 4px;
    background: #f8f9fa;
}

@media (max-width: 767px) {
    .sv-cart-thumb {
        width: 28px;
        height: 28px;
    }
}

/* ─── Base ─── */
* { box-sizing: border-box; }

body {
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    color: var(--sv-gray-900);
    background: var(--sv-gray-100);
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main { flex: 1; }

.container {
    max-width: var(--sv-container-width);
    padding-left: 1rem;
    padding-right: 1rem;
}

a { color: var(--sv-primary); text-decoration: none; }
a:hover { color: var(--sv-primary-light); }

/* ─── Sticky Header ─── */
.sv-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: #000 url('/images/Stenvaag-header.jpg') center center / cover no-repeat;
    box-shadow: var(--sv-shadow);
}

.sv-header-inner {
    display: flex;
    align-items: center;
    height: var(--sv-header-height);
    padding: 0 1rem;
    gap: 1rem;
}

.sv-logo {
    color: white !important;
    font-weight: 700;
    font-size: 1.2rem;
    text-decoration: none !important;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.sv-logo:hover { opacity: 0.9; }

.sv-hamburger {
    background: none;
    border: none;
    color: white;
    font-size: 1.6rem;
    padding: 0.25rem;
    cursor: pointer;
    line-height: 1;
}

.sv-search-form {
    flex: 1;
    max-width: 600px;
    margin: 0 auto;
}

.sv-search-input {
    width: 100%;
    border-radius: 24px;
    border: none;
    padding: 0.5rem 1rem 0.5rem 2.5rem;
    font-size: 0.95rem;
    outline: none;
    transition: box-shadow 0.2s;
}

.sv-search-input:focus {
    box-shadow: 0 0 0 3px rgba(255,255,255,0.3);
}

.sv-cart-btn {
    color: white;
    position: relative;
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    margin-right: 8px;
    line-height: 1;
}

.sv-cart-btn:hover { opacity: 0.9; }

.sv-cart-badge {
    position: absolute;
    top: -5px;
    right: -8px;
    background: var(--sv-secondary);
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ─── Mobile Search Bar ─── */
.sv-header-search-mobile {
    display: none;
    padding: 0.5rem 1rem 0.75rem;
    background: transparent;
}

.sv-header-search-mobile input {
    width: 100%;
    border-radius: 20px;
    border: none;
    padding: 0.45rem 1rem;
    font-size: 0.9rem;
}

/* ─── Category Bar (Desktop) ─── */
.sv-category-bar {
    background: var(--sv-white);
    border-bottom: 1px solid var(--sv-gray-300);
    height: var(--sv-category-bar-height);
    overflow: visible;
}

.sv-category-bar-inner {
    max-width: var(--sv-container-width);
    margin: 0 auto;
    padding: 0 1rem;
}

.sv-category-bar-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0;
    height: var(--sv-category-bar-height);
    max-width: 100%;
}

.sv-category-bar-item {
    position: relative;
    flex-shrink: 0;
}

.sv-category-bar-item > a {
    display: flex;
    align-items: center;
    height: var(--sv-category-bar-height);
    padding: 0 1rem;
    color: var(--sv-gray-700);
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.15s;
    white-space: nowrap;
}

.sv-category-bar-item > a:hover {
    background: var(--sv-gray-100);
    color: var(--sv-primary);
}

/* ─── Mega-menu flyout ─── */
.sv-mega-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 600px;
    max-width: var(--sv-container-width);
    background: white;
    border-bottom: 3px solid var(--sv-primary);
    box-shadow: var(--sv-shadow-lg);
    padding: 1rem 1.5rem;
    display: none;
    z-index: 1020;
    border-radius: 0 0 var(--sv-radius) var(--sv-radius);
}

.sv-mega-menu.active {
    display: block;
}

/* Alle kategorier mega-menu */
#allCategoriesItem .sv-mega-menu {
    width: auto;
    min-width: 500px;
    max-width: var(--sv-container-width);
}

#allCategoriesItem .sv-mega-menu-columns {
    columns: 4;
    column-gap: 1.5rem;
}

.sv-mega-menu-columns {
    columns: 3;
    column-gap: 1.5rem;
}

.sv-mega-menu-column {
    break-inside: avoid;
    margin-bottom: 0.5rem;
}

.sv-mega-menu-column h6 {
    font-weight: 700;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--sv-primary);
    margin-bottom: 0.25rem;
    padding-bottom: 0.2rem;
    border-bottom: 1px solid var(--sv-gray-200);
}

.sv-mega-menu-column h6 a {
    color: inherit;
    text-decoration: none;
}

.sv-mega-menu-column h6 a:hover {
    text-decoration: underline;
}

.sv-mega-menu-column a {
    display: block;
    padding: 0.15rem 0;
    font-size: 0.8rem;
    color: var(--sv-gray-700);
    text-decoration: none;
    line-height: 1.4;
}

.sv-mega-menu-column a:hover {
    color: var(--sv-primary);
}

.sv-mega-menu-column h6 a:hover {
    text-decoration: underline;
}

.sv-mega-menu-column a {
    display: block;
    padding: 0.2rem 0;
    font-size: 0.85rem;
    color: var(--sv-gray-700);
    text-decoration: none;
}

.sv-mega-menu-column a:hover {
    color: var(--sv-primary);
}

/* ─── Mobile Menu ─── */
.sv-mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1040;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.sv-mobile-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.sv-mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 300px;
    max-width: 85vw;
    background: white;
    z-index: 1050;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.sv-mobile-menu.active {
    transform: translateX(0);
}

.sv-mobile-menu-header {
    background: #000;
    color: white;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sv-mobile-menu-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--sv-gray-200);
    color: var(--sv-gray-900);
    text-decoration: none;
    font-size: 0.95rem;
}

.sv-mobile-menu-item:hover {
    background: var(--sv-gray-100);
}

.sv-mobile-menu-back {
    padding: 0.75rem 1rem;
    background: var(--sv-gray-100);
    border-bottom: 1px solid var(--sv-gray-300);
    color: var(--sv-primary);
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sv-mobile-menu-back:hover {
    background: var(--sv-gray-200);
}

/* ─── Product Grid ─── */
.sv-product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

/* ─── Product Card ─── */
.sv-product-card {
    background: white;
    border-radius: var(--sv-radius);
    border: 1px solid var(--sv-gray-200);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.2s, transform 0.2s;
    position: relative;
}

.sv-product-card:hover {
    box-shadow: var(--sv-shadow-lg);
    transform: translateY(-2px);
}

.sv-product-card-link {
    text-decoration: none !important;
    color: inherit !important;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.sv-product-card-img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: contain;
    padding: 0.75rem;
    background: var(--sv-gray-100);
}

.sv-product-card-body {
    padding: 0.75rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.sv-product-card-producer {
    font-size: 0.75rem;
    color: var(--sv-gray-500);
    display: flex;
    align-items: center;
    gap: 4px;
}

.sv-producer-icon {
    max-height: 24px;
    max-width: 60px;
    object-fit: contain;
}

.sv-product-card-name {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0.3rem 0;
    color: var(--sv-gray-900);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.sv-product-card-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--sv-primary);
    margin-top: auto;
    padding-top: 0.5rem;
}

.sv-product-card-old-price {
    text-decoration: line-through;
    color: var(--sv-gray-500);
    font-weight: 400;
    font-size: 0.85rem;
}

.sv-product-card-special {
    color: var(--sv-danger);
    font-weight: 700;
}

.sv-product-card-cart {
    display: block;
    width: 100%;
    padding: 0.85rem;
    background: #16a34a;
    color: white;
    border: none;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.15s;
    text-align: center;
    letter-spacing: 0.02em;
}

.sv-product-card-cart:hover {
    background: #15803d;
    color: white;
}
.sv-product-card-cart.sv-cart-soldout {
    background: #6b7280;
    cursor: not-allowed;
}
.sv-product-card-cart.sv-cart-soldout:hover {
    background: #6b7280;
}

/* ─── Product Badges (full-width, stacked, in flow above the image so any number fits) ─── */
.sv-product-badges {
    display: flex;
    flex-direction: column;
}

.sv-product-card-media {
    position: relative;
}

.sv-product-badge {
    display: block;
    width: 100%;
    text-align: center;
    padding: 5px 0;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    color: white;
}

.sv-license-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 3;
    background: rgba(59, 66, 82, 0.9);
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    pointer-events: none;
}

.sv-cart-license {
    background: #3B4252 !important;
    color: #fff !important;
    transition: background 0.2s;
}
.sv-cart-license:hover {
    background: #434C5E !important;
}

.sv-badge-offer { background: var(--sv-badge-offer, #e11d48); }
.sv-badge-bestseller { background: var(--sv-badge-bestseller, #0d9488); }
.sv-badge-new { background: var(--sv-badge-new, #2563eb); }
.sv-badge-featured { background: var(--sv-badge-featured, #d97706); }
.sv-badge-superdeal { background: var(--sv-badge-superdeal, #ea580c); }

/* ─── Stock Text (subtle) ─── */
.sv-stock-text { font-size: 0.8rem; font-weight: 500; }
.sv-stock-in { color: #16a34a; }
.sv-stock-low { color: #ea580c; font-weight: 600; }
.sv-stock-expected { color: #ca8a04; }
.sv-stock-out { color: #dc2626; }

/* ─── Product Detail ─── */
.sv-product-gallery {
    position: sticky;
    top: calc(var(--sv-header-height) + var(--sv-category-bar-height) + 1rem);
}

.sv-product-main-image {
    width: 100%;
    aspect-ratio: 1;
    object-fit: contain;
    background: var(--sv-white);
    border-radius: var(--sv-radius);
    padding: 1rem;
    border: 1px solid var(--sv-gray-200);
}

.sv-product-thumbs {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.25rem;
}

.sv-product-thumb {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border: 2px solid transparent;
    border-radius: 4px;
    cursor: pointer;
    padding: 4px;
    background: var(--sv-gray-100);
    flex-shrink: 0;
    transition: border-color 0.15s;
}

.sv-product-thumb:hover {
    border-color: var(--sv-gray-500);
}

.sv-product-thumb.active {
    border-color: var(--sv-primary);
}

.sv-product-info h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.sv-product-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--sv-primary);
    margin: 0.5rem 0;
}

.sv-product-add-cart {
    display: flex;
    gap: 0.5rem;
    margin: 1.5rem 0;
    align-items: stretch;
}

.sv-product-add-cart .btn {
    padding: 0.75rem 2rem;
    font-size: 1.1rem;
}

/* ─── Quantity Control ─── */
.sv-qty-control {
    display: flex;
    align-items: center;
    border: 1px solid var(--sv-gray-300);
    border-radius: var(--sv-radius);
    background: var(--sv-white);
}

.sv-qty-btn {
    background: none;
    border: none;
    padding: 0.5rem 0.75rem;
    font-size: 1.1rem;
    cursor: pointer;
    color: var(--sv-gray-700);
    line-height: 1;
    transition: background 0.15s;
}

.sv-qty-btn:hover {
    background: var(--sv-gray-100);
}

.sv-qty-value {
    width: 40px;
    text-align: center;
    border: none;
    font-weight: 600;
    font-size: 1rem;
    background: transparent;
    -moz-appearance: textfield;
}

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

.sv-qty-control-sm .sv-qty-btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.9rem;
}

.sv-qty-control-sm .sv-qty-value {
    width: 28px;
    font-size: 0.85rem;
}

/* ─── Cart Drawer ─── */
.sv-cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 400px;
    max-width: 90vw;
    background: white;
    z-index: 1060;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    box-shadow: var(--sv-shadow-lg);
    display: flex;
    flex-direction: column;
}

.sv-cart-drawer.active {
    transform: translateX(0);
}

.sv-cart-drawer-header {
    padding: 1rem;
    border-bottom: 1px solid var(--sv-gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.sv-cart-drawer-items {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 1rem;
}

.sv-cart-drawer-footer {
    padding: 1rem;
    border-top: 1px solid var(--sv-gray-200);
    background: var(--sv-gray-100);
    flex-shrink: 0;
}

.sv-cart-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--sv-gray-200);
    align-items: flex-start;
}

.sv-cart-item:last-child {
    border-bottom: none;
}

.sv-cart-item-img {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 4px;
    background: var(--sv-gray-100);
    flex-shrink: 0;
}

/* ─── Breadcrumb ─── */
.sv-breadcrumb {
    padding: 0.75rem 0;
    font-size: 0.85rem;
}

.sv-breadcrumb a {
    color: var(--sv-gray-500);
    text-decoration: none;
}

.sv-breadcrumb a:hover {
    color: var(--sv-primary);
    text-decoration: underline;
}

/* ─── Tabs ─── */
.sv-tabs .nav-link {
    color: var(--sv-gray-700);
    font-weight: 500;
}

.sv-tabs .nav-link.active {
    color: var(--sv-primary);
    border-color: var(--sv-primary);
}

/* ─── Merkevare-grid ─── */
.sv-brand-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (min-width: 768px) {
    .sv-brand-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 992px) {
    .sv-brand-grid { grid-template-columns: repeat(4, 1fr); }
}

.sv-brand-card {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--sv-gray-100);
    border-radius: var(--sv-radius);
    padding: 2rem 1.5rem;
    transition: all 0.2s;
    border: 1px solid var(--sv-gray-200);
    text-decoration: none;
    min-height: 120px;
}

.sv-brand-card:hover {
    background: var(--sv-white);
    box-shadow: var(--sv-shadow-lg);
    transform: translateY(-2px);
}

.sv-brand-logo {
    max-height: 80px;
    max-width: 200px;
    object-fit: contain;
}

/* ─── Seksjonsdeler ─── */
.sv-section-divider {
    background: var(--sv-primary);
    margin: 2rem -1rem 0;
    padding: 0;
}

.sv-section-divider-inner {
    max-width: var(--sv-container-width);
    margin: 0 auto;
    padding: 0.9rem 1.5rem;
    color: #fff;
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.sv-section-divider i {
    margin-right: 0.4rem;
}

@media (max-width: 767px) {
    .sv-section-divider {
        background: transparent;
        margin: 1rem 0 0;
        border-top: 1px solid var(--sv-gray-300);
        padding: 0;
    }

    .sv-section-divider-inner {
        display: none;
    }
}

/* ─── "Vis alle produkter"-knapp ─── */
.sv-show-all-btn {
    background: #2563eb;
    color: #fff;
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    transition: background 0.2s;
}

.sv-show-all-btn:hover {
    background: #16a34a;
    color: #fff;
}

/* ─── Footer ─── */
.sv-footer {
    background: var(--sv-dark);
    color: rgba(255,255,255,0.7);
    padding: 2rem 0 1rem;
    margin-top: 3rem;
}

.sv-footer h6 {
    color: white;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.sv-footer a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
}

.sv-footer a:hover {
    color: white;
}

/* ─── Hero Banner ─── */
.sv-hero-banner {
    max-width: var(--sv-container-width);
    margin: 0 auto;
    padding: 0 1rem;
    line-height: 0;
}

.sv-hero-banner img {
    width: 100%;
    height: auto;
    display: block;
}

@media (max-width: 767px) {
    .sv-hero-banner {
        max-width: 100%;
        padding: 0;
    }
}

/* ─── Content Pages ─── */
.sv-content-page,
.sv-product-description,
.article-body,
.sv-product-specs {
    font-family: var(--sv-site-font);
    font-size: var(--sv-site-font-size);
}

.sv-content-page h1 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.sv-content-page img {
    max-width: 100%;
    height: auto;
    border-radius: var(--sv-radius);
}


/* Image alignment classes from TinyMCE */
.img-align-left {
    float: left;
    margin: 0 1.5rem 1rem 0;
    max-width: 50%;
    height: auto;
}

.img-align-center {
    display: block;
    margin: 1rem auto;
    max-width: 100%;
    height: auto;
}

.img-align-right {
    float: right;
    margin: 0 0 1rem 1.5rem;
    max-width: 50%;
    height: auto;
}

.img-full-width {
    display: block;
    width: 100%;
    height: auto;
    margin: 1rem 0;
}

figure.image {
    display: inline-block;
    margin: 1rem 0;
    max-width: 100%;
}

figure.image img {
    max-width: 100%;
    height: auto;
}

figure.image figcaption {
    font-size: 0.85rem;
    color: var(--sv-gray-500);
    text-align: center;
    padding: 0.5rem 0;
    font-style: italic;
}

/* ─── Section ─── */
.sv-section { padding: 1.5rem 0; }

.sv-section-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--sv-gray-900);
}

/* ─── Toast ─── */
.sv-toast-container {
    position: fixed;
    bottom: 1.5rem;
    right: 1rem;
    z-index: 9999;
}

/* ─── Loading ─── */
.sv-loading {
    display: flex;
    justify-content: center;
    padding: 3rem;
}

/* ─── User/Account Button ─── */
.sv-user-btn {
    color: white;
    font-size: 1.4rem;
    padding: 0.25rem 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    line-height: 1;
    text-decoration: none !important;
    transition: opacity 0.15s;
}

.sv-user-btn:hover { color: white; opacity: 0.85; }

.sv-user-label {
    font-size: 0.82rem;
    font-weight: 500;
    white-space: nowrap;
}

@media (max-width: 575.98px) {
    .sv-user-label { display: none; }
    .sv-register-btn { display: none !important; }
}

/* ─── Auth Card (Register, Login, Min Side) ─── */
.sv-auth-card {
    background: var(--sv-white);
    border-radius: var(--sv-radius);
    border: 1px solid var(--sv-gray-200);
    padding: 2rem;
    box-shadow: var(--sv-shadow);
}

.sv-auth-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

/* ─── Buyer Type Radio Group ─── */
.sv-buyer-type-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.sv-buyer-type-option {
    cursor: pointer;
    flex: 1;
    min-width: 120px;
}

.sv-buyer-type-option input[type="radio"] {
    display: none;
}

.sv-buyer-type-option span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.6rem 1rem;
    border: 2px solid var(--sv-gray-300);
    border-radius: var(--sv-radius);
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.15s;
    text-align: center;
}

.sv-buyer-type-option input[type="radio"]:checked + span {
    border-color: var(--sv-primary);
    background: rgba(26, 58, 26, 0.06);
    color: var(--sv-primary);
    font-weight: 600;
}

.sv-buyer-type-option:hover span {
    border-color: var(--sv-gray-500);
}

/* ─── Conditional Fields (Firma/Skytterlag) ─── */
.sv-conditional-fields {
    background: var(--sv-gray-100);
    border-radius: var(--sv-radius);
    padding: 1rem;
    margin-bottom: 0.5rem;
    border: 1px solid var(--sv-gray-200);
}

/* ─── Responsive: Desktop (992px+) ─── */
@media (min-width: 992px) {
    .sv-hamburger { display: none; }
    .sv-header-search-mobile { display: none !important; }

    .sv-product-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ─── Responsive: Tablet (768px - 991px) ─── */
@media (min-width: 768px) and (max-width: 991px) {
    .sv-product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ─── Responsive: Mobile (< 992px) ─── */
@media (max-width: 991px) {
    .sv-category-bar { display: none; }
    .sv-search-form { display: none; }
    .sv-header-search-mobile { display: block; }

    .sv-header-inner {
        padding: 0 0.5rem;
    }

    .sv-header-search-mobile {
        padding: 0.5rem 0.5rem 0.75rem;
    }

    .sv-product-gallery {
        position: static;
    }
}

/* ─── Responsive: Small Mobile (< 768px) ─── */
@media (max-width: 767px) {
    .img-align-left, .img-align-right {
        float: none;
        display: block;
        margin: 1rem auto;
        max-width: 100%;
    }

    .sv-product-info h1 {
        font-size: 1.2rem;
    }

    .sv-product-price {
        font-size: 1.5rem;
    }

    .sv-product-add-cart {
        flex-direction: column;
    }

    .sv-product-add-cart .btn {
        width: 100%;
    }

    .sv-product-card-img {
        padding: 0.5rem;
    }

    .sv-product-card-body {
        padding: 0.5rem;
    }

    .sv-product-card-name {
        font-size: 0.85rem;
    }

    .sv-product-card-price {
        font-size: 0.95rem;
    }

    .sv-auth-card {
        padding: 1.25rem;
    }

    .sv-buyer-type-group {
        flex-direction: column;
    }

    .sv-buyer-type-option {
        min-width: 100%;
    }

    /* Merkevare-grid: mindre padding på mobil */
    .sv-brand-card {
        padding: 1rem 0.75rem;
        min-height: 80px;
    }

    .sv-brand-logo {
        max-height: 40px;
    }

    /* Footer: sentrert og større på mobil */
    .sv-footer {
        text-align: center;
        padding: 1.5rem 0 1rem;
        font-size: 1rem;
    }

    .sv-footer h6 {
        font-size: 1.2rem;
        margin-bottom: 0.5rem;
    }

    .sv-footer .small {
        font-size: 1rem !important;
    }

    .sv-footer p.small {
        font-size: 1rem !important;
    }

    .sv-footer ul li {
        margin-bottom: 0.4rem;
        font-size: 1rem;
    }
}

/* ─── Checkout ─── */
.sv-checkout-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
}

.sv-step {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--sv-gray-500);
    font-weight: 500;
}

.sv-step.active {
    color: var(--sv-primary);
}

.sv-step .step-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    background: var(--sv-gray-300);
    color: var(--sv-gray-500);
}

.sv-step.active .step-num {
    background: var(--sv-primary);
    color: #fff;
}

.sv-step-line {
    width: 60px;
    height: 2px;
    background: var(--sv-gray-300);
    margin: 0 1rem;
}

.sv-checkout-panel {
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    padding: 1.25rem;
    margin-bottom: 1rem;
}

.sv-checkout-panel h5 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--sv-gray-900);
}

.sv-checkout-items {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.sv-checkout-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sv-checkout-item img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    padding: 4px;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    background: #f8f9fa;
    flex-shrink: 0;
}

.sv-checkout-item .item-info {
    flex: 1;
    min-width: 0;
}

.sv-checkout-item .item-name {
    font-size: 1.05rem;
    font-weight: 500;
}

.sv-checkout-item .item-qty {
    font-size: 0.88rem;
    color: var(--sv-gray-500);
}

.sv-checkout-item .item-price {
    font-weight: 600;
    font-size: 1.1rem;
    white-space: nowrap;
}

.sv-checkout-totals {
    border-top: 1px solid #e9ecef;
    padding-top: 0.75rem;
}

/* Payment method selector */
.sv-payment-methods {
    border-top: 1px solid #e9ecef;
    padding-top: 1rem;
}

.sv-payment-option {
    display: block;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 0.85rem 1rem;
    margin-bottom: 0.5rem;
    cursor: pointer;
    transition: all 0.15s ease;
    background: #fff;
}

.sv-payment-option:hover {
    border-color: #b0b8c1;
    background: #f8f9fa;
}

.sv-payment-option.selected {
    border-color: #198754;
    background: #f0faf4;
    box-shadow: 0 0 0 1px #198754;
}

.sv-payment-option input[type="radio"] {
    display: none;
}

.sv-payment-option-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sv-payment-option-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sv-payment-radio {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid #ced4da;
    flex-shrink: 0;
    position: relative;
    transition: all 0.15s ease;
}

.sv-payment-option.selected .sv-payment-radio {
    border-color: #198754;
}

.sv-payment-option.selected .sv-payment-radio::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #198754;
}

.sv-payment-logos {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
}

.sv-payment-logos svg {
    border-radius: 3px;
}

/* Shipping option selector */
.sv-shipping-option {
    display: block;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    margin-bottom: 0.4rem;
    cursor: pointer;
    transition: all 0.15s ease;
    background: #fff;
}

.sv-shipping-option:hover {
    border-color: #b0b8c1;
    background: #f8f9fa;
}

.sv-shipping-option.selected {
    border-color: #1a3a1a;
    background: #f0f7f0;
}

.sv-shipping-option input[type="radio"] {
    display: none;
}

.sv-order-success-icon {
    font-size: 4rem;
    color: #198754;
}

.sv-order-success-icon i {
    animation: checkPop 0.4s ease-out;
}

@keyframes checkPop {
    0% { transform: scale(0.5); opacity: 0; }
    70% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}
