/* Homepage only: approved reference dimensions and responsive breakpoints. */
.sp-hero {
    position: relative; min-height: 465px; display: flex; align-items: center;
    background: #111 url("../images/hero-bmw-e30-m3-clean.webp") center 53% / cover no-repeat; color: #fff;
}
.sp-hero::before {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(90deg, rgb(0 0 0 / 67%) 0%, rgb(0 0 0 / 28%) 40%, transparent 75%);
}
.sp-hero .sp-wrap { position: relative; padding-top: 25px; padding-bottom: 85px; }
.sp-hero-copy { max-width: 515px; }
.sp-hero h1 {
    margin: 0; color: #fff; font-size: 52px; font-weight: 650;
    letter-spacing: .1px; text-shadow: 0 2px 10px #0004;
}
.sp-hero p { font-size: 16px; max-width: 375px; line-height: 1.65; margin: 17px 0 25px; color: #f0f0f0; }
.sp-hero-buttons { display: flex; gap: 14px; flex-wrap: wrap; }
.sp-button-outline { background: transparent; border-color: #ddd; }
.sp-button-outline:hover, .sp-button-outline:focus { background: #ffffff14; }
.sp-categories {
    position: relative; z-index: 2; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 16px; width: calc(100% - 48px); max-width: 840px; box-sizing: border-box; margin: -51px auto 0;
    padding: 0 20px; scroll-margin-top: 25px;
}
.sp-category { text-align: center; display: flex; align-items: center; flex-direction: column; gap: 9px; color: var(--sp-ink); text-decoration: none; }
.sp-category:visited, .sp-category:hover { color: var(--sp-ink); }
.sp-category-photo {
    box-sizing: border-box; border: 4px solid #fff; box-shadow: 0 3px 8px #0001;
    border-radius: 50%; width: 104px; height: 104px; flex-shrink: 0;
    /* Exact image crops from the prototype, without its demo product content. */
    background-size: cover; background-position: center; background-repeat: no-repeat;
    transition: transform .2s;
    overflow: hidden;
}
.sp-category-photo .sp-category-image { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.sp-category-fortvatt .sp-category-photo { background-image: url("../images/categories/category-fortvatt.webp"); }
.sp-category-biltvatt .sp-category-photo { background-image: url("../images/category-biltvatt.png"); }
.sp-category-lackskydd .sp-category-photo { background-image: url("../images/category-lackskydd.png"); }
.sp-category-interior .sp-category-photo { background-image: url("../images/categories/category-interior.webp"); }
.sp-category-paket-kit .sp-category-photo { background-image: url("../images/category-paket-kit.png"); }
.sp-category:hover .sp-category-photo { transform: translateY(-4px); }
.sp-category-name { font: 600 15px/1.18 var(--sp-heading); text-transform: uppercase; max-width: 125px; }
@media (min-width: 1500px) {
    .sp-hero { min-height: 520px; }
    .sp-hero .sp-wrap { padding-bottom: 100px; }
    .sp-hero h1 { font-size: 59px; }
}
@media (max-width: 1050px) {
    .sp-hero { min-height: 420px; }
    .sp-hero h1 { font-size: 45px; }
    .sp-categories { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 500px; }
}
@media (max-width: 760px) {
    .sp-hero { min-height: 430px; background-position: 62% center; }
    .sp-hero::before { background: linear-gradient(90deg, #000a, #0003); }
    .sp-hero .sp-wrap { padding-top: 20px; padding-bottom: 65px; }
    .sp-hero-copy { max-width: 360px; }
    .sp-hero h1 { font-size: 39px; max-width: 340px; }
    .sp-hero p { font-size: 14px; max-width: 285px; }
    .sp-hero-buttons { gap: 9px; }
    .sp-categories { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 8px; width: 100%; max-width: 420px; margin-top: -42px; padding: 0 20px; }
    .sp-category-photo { width: 88px; height: 88px; }
    .sp-category-name { font-size: 13px; }
}

/* GeneratePress keeps its header/footer; only the homepage content is full width. */
body.sp-homepage #page { max-width: none; width: 100%; margin: 0; background: #fff; }
body.sp-homepage #content { padding: 0; display: block; }
body.sp-homepage .sp-home-area { width: 100%; float: none; margin: 0; }
body.sp-homepage .sp-home { margin: 0; padding: 0; }
.sp-home, .sp-home * { box-sizing: border-box; }
.sp-home h2 { font-size: 34px; font-weight: 700; margin: 0; }
.sp-home h3 { margin: 0; }
.sp-home a { text-decoration: none; }
.sp-home-card a:not(.button), .sp-home-card a:not(.button):visited { color: inherit; }
.sp-home a:focus-visible { outline: 3px solid var(--sp-red); outline-offset: 4px; }
.sp-home-visual img { display: block; max-width: 100%; }
.sp-home .sp-home-cart a.button {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    background: var(--sp-red); color: #fff; border: 1px solid var(--sp-red); border-radius: 0;
    font-family: var(--sp-heading); font-weight: 500; line-height: 1.18;
    text-transform: uppercase; letter-spacing: .3px; text-decoration: none;
    white-space: normal; text-align: center; height: auto;
    transition: background .2s, transform .2s;
}
.sp-home .sp-home-cart a.button:hover, .sp-home .sp-home-cart a.button:focus { background: #a61720; color: #fff; transform: translateY(-1px); }
.sp-home-cart .added_to_cart { display: block; text-align: center; margin-top: 8px; font-size: 12px; text-decoration: underline; }
.sp-home-price .price { display: block; }
.sp-home-price .woocommerce-price-suffix { font-size: 11px; }
.sp-home-card h3 { overflow-wrap: anywhere; }
.sp-home-empty { padding-top: 30px; padding-bottom: 64px; text-align: center; }
#sp-paket { scroll-margin-top: 30px; }
.sp-home-product-section {
    padding:30px 0 64px;
}
.sp-home-heading {
    text-align:center;
    margin-bottom:24px;
}
.sp-home-heading p {
    font-size:12px;
    color:var(--sp-muted);
    margin:7px 0 0;
}
.sp-home-grid {
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:20px;
}
.sp-home-card {
    border:1px solid #eceeef;
    border-radius:4px;
    padding:15px 15px 14px;
    position:relative;
    box-shadow:0 3px 16px #17202306;
    background:white;
    display:flex;
    flex-direction:column;
    transition:box-shadow .2s,transform .2s;
    min-width:0;
}
.sp-home-card:hover {
    box-shadow:0 7px 24px #17202312;
    transform:translateY(-3px);
}
.sp-home-visual {
    height:190px;
    display:flex;
    align-items:center;
    justify-content:center;
    position:relative;
    margin-bottom:13px;
    overflow:hidden;
}
.sp-home-visual img {
    height:95%;
    width:100%;
    object-fit:contain;
}
.sp-home-sale {
    position:absolute;
    right:11px;
    top:11px;
    z-index:4;
    width:49px;
    height:49px;
    background:var(--sp-red);
    color:white;
    display:flex;
    align-items:center;
    justify-content:center;
    flex-direction:column;
    border-radius:50%;
    font:12px/1.15 var(--sp-heading);
    text-transform:uppercase;
    transform:rotate(-7deg);
    box-shadow:0 2px 4px #0002;
}
.sp-home-sale strong {
    font-size:18px;
}
.sp-home-card h3 {
    font-size:18px;
    font-weight:600;
    margin:0 0 9px;
    min-height:23px;
    text-align:center;
}
.sp-home-price {
    text-align:center;
    font-size:14px;
    display:flex;
    justify-content:center;
    align-items:center;
    gap:8px;
    margin-bottom:14px;
    margin-top:auto;
}
.sp-home-price ins {
    text-decoration:none;
    font-weight:700;
    color:#9e131c;
}
.sp-home-price del {
    font-size:12px;
    color:#80868a;
}
.sp-home-card .sp-home-cart .button {
    width:100%;
    padding:11px 8px;
    font-size:13px;
    min-height:42px;
}
.sp-home-secondary {
    padding:48px 0 62px;
    background:#f6f7f7;
}
.sp-home-eyebrow {
    font-family:var(--sp-heading);
    line-height:1.18;
    font-size:12px;
    color:var(--sp-red);
    letter-spacing:1.7px;
    text-transform:uppercase;
    margin-bottom:10px;
}
.sp-home-secondary .sp-home-heading {
    margin-bottom:30px;
}
.sp-home-values {
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:36px;
    text-align:center;
    padding:42px 0;
}
.sp-home-values .sp-icon {
    margin:0 auto 12px;
    width:28px;
    height:28px;
}
.sp-home-values h3 {
    font-weight:700;
    font-size:18px;
    margin-bottom:6px;
}
.sp-home-values p {
    margin:0;
    color:var(--sp-muted);
    font-size:13px;
}

@media (max-width: 1050px) {
    .sp-home-grid { gap: 15px; }
    .sp-home-visual { height: 170px; }
}
@media (max-width: 760px) {
    .sp-home h2 { font-size: 28px; }
    .sp-home-product-section { padding-top: 34px; padding-bottom: 40px; }
    .sp-home-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .sp-home-card { padding: 10px; }
    .sp-home-visual { height: 155px; }
    .sp-home-card h3 { font-size: 16px; min-height: 38px; }
    .sp-home-price { font-size: 13px; gap: 4px; flex-wrap: wrap; }
    .sp-home-price del { font-size: 11px; }
    .sp-home-sale { width: 40px; height: 40px; right: 6px; top: 6px; font-size: 10px; }
    .sp-home-sale strong { font-size: 15px; }
    .sp-home-card .sp-home-cart .button { font-size: 12px; }
    .sp-home-values { gap: 28px; grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    .sp-home-card, .sp-home .sp-home-cart a.button { transition: none; }
}
