/* ===== RESET & VARIABLES ===== */
:root {
    --red: #C62828;
    --red-dark: #8E0000;
    --grey-dark: #212121;
    --grey-mid: #424242;
    --grey-light: #757575;
    --grey-bg: #F5F5F5;
    --white: #FFFFFF;
    --black: #000000;
    --font: 'Segoe UI', Roboto, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font);
    color: var(--grey-dark);
    line-height: 1.6;
    background: var(--white);
}

h1, h2, h3, h4 {
    font-weight: 700;
    color: var(--grey-dark);
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* ===== HEADER ===== */
header {
    background: var(--black);
    color: var(--white);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: 1px;
}

.logo span {
    color: var(--red);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

/* ===== NAV BASKET BUTTON ===== */
.nav-basket-btn {
    position: relative;
    background: var(--red);
    color: var(--white);
    border: none;
    border-radius: 6px;
    padding: 0.45rem 0.75rem;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: background 0.2s, transform 0.15s;
}

.nav-basket-btn:hover {
    background: var(--red-dark);
    transform: scale(1.06);
}

.nav-basket-btn .basket-count {
    display: none;
    background: var(--white);
    color: var(--red);
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: -6px;
    right: -6px;
}

.nav-basket-btn .basket-count.has-items {
    display: flex;
}


.nav-links a {
    font-weight: 500;
    transition: color 0.3s;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--red);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--white);
    margin: 3px 0;
    transition: 0.3s;
}

/* ===== HERO SLIDER ===== */
.swiper {
    width: 100%;
    height: 75vh;
    min-height: 400px;
}

.swiper-slide {
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.swiper-slide::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 1;
}

.slide-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
    max-width: 700px;
    padding: 2rem;
}

.slide-content h1 {
    font-size: 2.8rem;
    margin-bottom: 1rem;
    color: var(--white);
    text-shadow: 2px 2px 8px rgba(0,0,0,0.7);
}

.slide-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.btn {
    display: inline-block;
    background: var(--red);
    color: var(--white);
    padding: 0.8rem 2rem;
    font-weight: 600;
    border-radius: 5px;
    transition: background 0.3s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn:hover {
    background: var(--red-dark);
}

.swiper-button-next,
.swiper-button-prev {
    color: var(--white);
}

.swiper-pagination-bullet-active {
    background: var(--red);
}

/* ===== COUNTERS SECTION ===== */
.counters {
    background: var(--grey-dark);
    color: var(--white);
    padding: 3rem 0;
}

.counters .container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}

.counter-item h3 {
    font-size: 2.5rem;
    color: var(--red);
    margin-bottom: 0.5rem;
}

.counter-item p {
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===== SECTION HEADINGS ===== */
.section-heading {
    text-align: center;
    margin: 3rem 0 2rem;
    font-size: 2.2rem;
    position: relative;
}

.section-heading::after {
    content: '';
    display: block;
    width: 80px;
    height: 3px;
    background: var(--red);
    margin: 0.5rem auto;
}

/* ===== FEATURED PRODUCTS (Home) ===== */
.featured-products {
    padding: 2rem 0 4rem;
    background: var(--grey-bg);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.product-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.3s;
}

.product-card:hover {
    transform: translateY(-5px);
}

.product-card img {
    height: 200px;
    width: 100%;
    object-fit: cover;
}

.product-card .card-body {
    padding: 1.5rem;
    text-align: center;
}

.product-card h4 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

/* ===== ABOUT, SERVICES, PRODUCT LIST PAGES ===== */
.page-hero {
    background: var(--grey-dark);
    color: var(--white);
    padding: 3rem 0;
    text-align: center;
}

.page-hero h1 {
    color: var(--white);
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.content-section {
    padding: 3rem 0;
}

.content-section p {
    margin-bottom: 1rem;
    color: var(--grey-mid);
}

/* product category grid */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.category-card {
    background: var(--grey-bg);
    border-radius: 8px;
    overflow: hidden;
    text-align: center;
    transition: transform 0.3s;
}

.category-card:hover {
    transform: translateY(-5px);
}

.category-card img {
    height: 180px;
    object-fit: cover;
}

.category-card h3 {
    padding: 1rem 1rem 0;
}

.category-card .btn {
    margin: 1rem 0 1.5rem;
}

/* product list items */
.product-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.product-item {
    display: flex;
    background: var(--white);
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.product-item img {
    width: 280px;
    object-fit: cover;
    background: #ddd;
}

.product-info {
    padding: 1.5rem;
    flex: 1;
}

.product-info h3 {
    margin-bottom: 0.5rem;
    color: var(--grey-dark);
}

.specs {
    list-style: none;
    margin: 1rem 0;
}

.specs li {
    margin-bottom: 0.3rem;
    font-size: 0.95rem;
}

.product-detail-page .product-detail-content {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.product-detail-page img {
    width: 400px;
    max-width: 100%;
    border-radius: 8px;
}

.details-text {
    flex: 1;
}

/* ===== CONTACT PAGE ===== */
.contact-info {
    display: flex;
    gap: 3rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.contact-details {
    flex: 1;
    min-width: 280px;
}

.contact-details i {
    color: var(--red);
    margin-right: 0.5rem;
    width: 20px;
}

.contact-form {
    flex: 2;
    min-width: 320px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 0.8rem;
    margin-bottom: 1rem;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: inherit;
}

.contact-form button {
    background: var(--red);
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.contact-form button:hover {
    background: var(--red-dark);
}

/* ===== FOOTER ===== */
footer {
    background: var(--black);
    color: var(--white);
    padding: 3rem 0 2rem;
    margin-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-col h4 {
    color: var(--white);
    margin-bottom: 1rem;
    font-size: 1.2rem;
    border-bottom: 2px solid var(--red);
    display: inline-block;
    padding-bottom: 0.3rem;
}

.footer-col p, .footer-col a {
    font-size: 0.95rem;
    color: #bbb;
    display: block;
    margin-bottom: 0.5rem;
}

.footer-col a:hover {
    color: var(--red);
}

.copyright {
    text-align: center;
    border-top: 1px solid var(--grey-mid);
    padding-top: 1.5rem;
    font-size: 0.85rem;
    color: #999;
}

/* ===== BACK TO TOP ===== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--red);
    color: white;
    width: 40px;
    height: 40px;
    text-align: center;
    line-height: 40px;
    border-radius: 50%;
    font-size: 1.5rem;
    display: none;
    z-index: 999;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.back-to-top.show {
    display: block;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .nav-right {
        gap: 1rem;
    }

    .nav-basket-btn {
        /* Keep visible on mobile, sits next to hamburger */
        padding: 0.4rem 0.6rem;
        font-size: 1rem;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background: var(--black);
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
        padding: 2rem 0;
        transform: translateY(-150%);
        transition: transform 0.3s;
        z-index: 999;
    }

    .nav-links.active {
        transform: translateY(0);
    }

    .hamburger {
        display: flex;
    }

    .counters .container {
        grid-template-columns: 1fr 1fr;
    }

    .product-grid, .footer-grid {
        grid-template-columns: 1fr;
    }

    .product-item {
        flex-direction: column;
    }

    .product-item img {
        width: 100%;
        height: 200px;
    }
}
/* ===== QUALITY BANNER ===== */
.quality-banner {
    background: var(--red);
    color: var(--white);
    padding: 0.8rem 0;
    text-align: center;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.quality-banner i {
    margin-right: 0.5rem;
}

/* ===== WHY US ===== */
.why-us {
    padding: 3rem 0 4rem;
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.why-card {
    text-align: center;
    padding: 2rem 1rem;
    background: var(--grey-bg);
    border-radius: 8px;
    transition: transform 0.3s;
}

.why-card:hover {
    transform: translateY(-5px);
}

.why-card i {
    font-size: 2.5rem;
    color: var(--red);
    margin-bottom: 1rem;
}

.why-card h4 {
    margin-bottom: 0.5rem;
}

/* ===== PRODUCT DETAIL ===== */
.product-detail-page .product-detail-content {
    display: flex;
    gap: 3rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.product-detail-page .product-img {
    width: 420px;
    max-width: 100%;
    border-radius: 8px;
    object-fit: cover;
}

.details-text { flex: 1; min-width: 280px; }
.details-text h2 { margin-bottom: 1rem; }
.details-text p { color: var(--grey-mid); margin-bottom: 1rem; }

.specs-table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.specs-table th, .specs-table td {
    padding: 0.6rem 1rem;
    text-align: left;
    border: 1px solid #ddd;
    font-size: 0.95rem;
}

.specs-table th {
    background: var(--grey-dark);
    color: var(--white);
}

.specs-table tr:nth-child(even) td {
    background: var(--grey-bg);
}

.badge {
    display: inline-block;
    background: var(--red);
    color: var(--white);
    padding: 0.2rem 0.7rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

@media (max-width: 768px) {
    .why-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
    .why-grid { grid-template-columns: 1fr; }
}

/* ===== BASKET / QUOTE SYSTEM ===== */

/* Floating basket button */
.basket-float {
    position: fixed;
    bottom: 30px;
    left: 30px;
    background: var(--red);
    color: var(--white);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    cursor: pointer;
    z-index: 1100;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
    transition: background 0.3s, transform 0.2s;
    border: none;
}

.basket-float:hover { background: var(--red-dark); transform: scale(1.08); }

.basket-float .basket-count {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--white);
    color: var(--red);
    font-size: 0.7rem;
    font-weight: 800;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    display: none;
}

.basket-float .basket-count.has-items { display: flex; }

/* Basket slide-out panel */
.basket-panel {
    position: fixed;
    top: 0;
    right: -420px;
    width: 420px;
    max-width: 100vw;
    height: 100vh;
    background: var(--white);
    box-shadow: -4px 0 20px rgba(0,0,0,0.2);
    z-index: 1200;
    display: flex;
    flex-direction: column;
    transition: right 0.35s ease;
}

.basket-panel.open { right: 0; }

.basket-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1150;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s;
}

.basket-overlay.open { opacity: 1; pointer-events: all; }

.basket-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.2rem 1.5rem;
    background: var(--grey-dark);
    color: var(--white);
    flex-shrink: 0;
}

.basket-header h3 { color: var(--white); font-size: 1.2rem; }

.basket-close {
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0 0.2rem;
    line-height: 1;
}

.basket-items {
    flex: 1;
    overflow-y: auto;
    padding: 1rem 1.5rem;
}

.basket-empty {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--grey-light);
}

.basket-empty i { font-size: 3rem; margin-bottom: 1rem; display: block; color: #ccc; }

.basket-item {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
    padding: 1rem 0;
    border-bottom: 1px solid #eee;
}

.basket-item-info { flex: 1; }
.basket-item-info strong { display: block; font-size: 0.95rem; color: var(--grey-dark); }
.basket-item-info .item-category { font-size: 0.8rem; color: var(--grey-light); margin-top: 0.1rem; }

.basket-item-controls {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 0.5rem;
}

.qty-btn {
    background: var(--grey-bg);
    border: 1px solid #ddd;
    width: 26px;
    height: 26px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 700;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.qty-btn:hover { background: #ddd; }

.qty-display {
    min-width: 28px;
    text-align: center;
    font-weight: 600;
    font-size: 0.95rem;
}

.item-notes {
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.3rem 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.82rem;
    font-family: inherit;
    resize: none;
    color: var(--grey-mid);
}

.remove-item {
    background: none;
    border: none;
    color: #bbb;
    cursor: pointer;
    font-size: 1rem;
    padding: 0.2rem;
    transition: color 0.2s;
    flex-shrink: 0;
}

.remove-item:hover { color: var(--red); }

.basket-footer {
    padding: 1.2rem 1.5rem;
    border-top: 2px solid var(--grey-bg);
    flex-shrink: 0;
}

.basket-footer .btn {
    width: 100%;
    text-align: center;
    display: block;
    font-size: 1rem;
    padding: 0.9rem;
}

.basket-footer .btn-clear {
    display: block;
    text-align: center;
    margin-top: 0.6rem;
    color: var(--grey-light);
    font-size: 0.85rem;
    cursor: pointer;
    background: none;
    border: none;
    width: 100%;
    font-family: inherit;
}

.basket-footer .btn-clear:hover { color: var(--red); }

/* Add to basket button on product pages */
.btn-basket {
    display: inline-block;
    background: var(--grey-dark);
    color: var(--white);
    padding: 0.6rem 1.3rem;
    font-weight: 600;
    border-radius: 5px;
    transition: background 0.3s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.85rem;
    border: none;
    cursor: pointer;
    font-family: inherit;
    margin-left: 0.5rem;
}

.btn-basket:hover { background: var(--red); }
.btn-basket i { margin-right: 0.4rem; }

/* Quote request modal */
.quote-modal {
    position: fixed;
    inset: 0;
    z-index: 1300;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.quote-modal.open { display: flex; }

.quote-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.6);
}

.quote-modal-box {
    position: relative;
    z-index: 1;
    background: var(--white);
    border-radius: 10px;
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 40px rgba(0,0,0,0.3);
}

.quote-modal-header {
    background: var(--grey-dark);
    color: var(--white);
    padding: 1.2rem 1.5rem;
    border-radius: 10px 10px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.quote-modal-header h3 { color: var(--white); }

.quote-modal-body { padding: 1.5rem; }
.quote-modal-body p { margin-bottom: 1rem; color: var(--grey-mid); font-size: 0.95rem; }

.quote-basket-summary {
    background: var(--grey-bg);
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.quote-basket-summary h4 { margin-bottom: 0.8rem; font-size: 0.95rem; }

.quote-summary-item {
    display: flex;
    justify-content: space-between;
    padding: 0.3rem 0;
    border-bottom: 1px solid #e0e0e0;
    color: var(--grey-mid);
}

.quote-summary-item:last-child { border-bottom: none; }
.quote-summary-item .item-name { font-weight: 600; color: var(--grey-dark); }

.quote-modal-body input,
.quote-modal-body textarea,
.quote-modal-body select {
    width: 100%;
    padding: 0.75rem;
    margin-bottom: 0.9rem;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: inherit;
    font-size: 0.95rem;
}

.quote-modal-body .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
}

.quote-modal-body .form-row input { margin-bottom: 0; }

.quote-modal-body button[type="submit"] {
    background: var(--red);
    color: white;
    border: none;
    padding: 0.9rem 2rem;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
    width: 100%;
    font-size: 1rem;
    font-family: inherit;
    margin-top: 0.3rem;
}

.quote-modal-body button[type="submit"]:hover { background: var(--red-dark); }

.quote-success {
    text-align: center;
    padding: 2rem;
    display: none;
}

.quote-success i { font-size: 3.5rem; color: #4CAF50; margin-bottom: 1rem; display: block; }
.quote-success h3 { margin-bottom: 0.5rem; }
.quote-success p { color: var(--grey-mid); }

/* Add-to-basket toast notification */
.toast {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--grey-dark);
    color: var(--white);
    padding: 0.7rem 1.4rem;
    border-radius: 6px;
    font-size: 0.9rem;
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    pointer-events: none;
    white-space: nowrap;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 480px) {
    .basket-panel { width: 100vw; }
    .quote-modal-body .form-row { grid-template-columns: 1fr; }
}

/* ===== SPEC SELECTOR ===== */
.spec-selector {
    background: #f9f9f9;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    padding: 1rem 1.2rem;
    margin: 1rem 0 1rem;
}

.spec-group {
    margin-bottom: 0.9rem;
}

.spec-group:last-child {
    margin-bottom: 0;
}

.spec-group > label {
    display: block;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--grey-dark);
    margin-bottom: 0.45rem;
}

.radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.radio-opt {
    display: flex;
    align-items: center;
    gap: 0;
    cursor: pointer;
}

.radio-opt input[type="radio"] {
    display: none;
}

.radio-opt span,
.radio-opt {
    font-size: 0.82rem;
}

/* Style the label as a pill when radio is checked */
.radio-opt {
    background: var(--white);
    border: 1.5px solid #d0d0d0;
    border-radius: 20px;
    padding: 0.25rem 0.75rem;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--grey-mid);
    transition: all 0.15s;
    user-select: none;
}

.radio-opt:hover {
    border-color: var(--red);
    color: var(--red);
}

.radio-opt:has(input:checked) {
    background: var(--red);
    border-color: var(--red);
    color: var(--white);
    font-weight: 600;
}
