/* Streetparts Design System */
:root {
    --white: #FFFFFF;
    --gray-light: #F4F4F4;
    --gray-medium: #AAAAAA;
    --gray-dark: #333333;
    --blue: #0056b3;
    --blue-dark: #003d80;
    --olive: #808000;
    --olive-dark: #556B2F;
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

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

body {
    font-family: var(--font-main);
    line-height: 1.6;
    color: var(--gray-dark);
    background-color: var(--white);
}

/* Typography */
h1,
h2,
h3 {
    text-transform: uppercase;
    letter-spacing: 1px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* Header & Nav */
header {
    background: var(--white);
    padding: 1rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--blue);
}

.logo span {
    color: var(--olive);
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 2rem;
}

nav ul li a:hover {
    color: var(--blue);
}

/* Hero Section */
.hero {
    height: 60vh;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('assets/hero.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: var(--white);
    text-align: center;
    padding: 2rem;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.cta-button {
    background: var(--blue);
    color: var(--white);
    padding: 0.8rem 2rem;
    border-radius: 5px;
    font-weight: 600;
    margin-top: 1rem;
}

.cta-button:hover {
    background: var(--blue-dark);
}

/* Sections */
section {
    padding: 4rem 10%;
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--olive);
}

/* Catalog Grid */
.catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
}

.product-card {
    background: var(--white);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    transition: var(--transition);
    border: 1px solid rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
    border-bottom-color: var(--olive);
}

.product-card img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    margin-bottom: 1rem;
    border-radius: 5px;
}

.product-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--blue);
    margin: 1rem 0;
}

/* Contact Info */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    background: var(--gray-light);
    padding: 3rem;
    border-radius: 10px;
}

.contact-info h3 {
    margin-bottom: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.contact-item i {
    color: var(--blue);
    margin-right: 1rem;
    width: 20px;
}

/* Footer */
footer {
    background: var(--gray-dark);
    color: var(--white);
    text-align: center;
    padding: 2rem;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 8px;
    width: 90%;
    max-width: 400px;
    position: relative;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.close-modal {
    color: var(--gray-medium);
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-modal:hover,
.close-modal:focus {
    color: var(--gray-dark);
}

.modal-content h2 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.modal-content p {
    margin-bottom: 1rem;
    font-weight: 600;
    color: var(--blue);
}

.form-group {
    margin-bottom: 1rem;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.form-group input {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--gray-medium);
    border-radius: 4px;
    font-family: inherit;
}

/* Checkout Form Refinements */
.checkout-header {
    text-align: center;
    background: var(--gray-light);
    padding: 3rem 1rem;
    margin-bottom: 2rem;
}

.checkout-header p {
    color: var(--gray-medium);
    margin-top: 0.5rem;
}

.checkout-container {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 2rem;
    align-items: start;
    padding: 0 5%;
}

.checkout-section {
    background: var(--white);
    border: 1px solid var(--gray-light);
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.checkout-section-header {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--gray-light);
}

.step-number {
    background: var(--blue);
    color: var(--white);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 1rem;
}

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

.radio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.custom-radio {
    cursor: pointer;
}

.custom-radio input {
    display: none;
}

.radio-content {
    border: 1px solid var(--gray-medium);
    border-radius: 6px;
    padding: 1rem;
    text-align: center;
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.radio-content i {
    font-size: 1.5rem;
    color: var(--gray-dark);
}

.custom-radio input:checked+.radio-content {
    border-color: var(--blue);
    background-color: rgba(0, 86, 179, 0.05);
}

.custom-radio input:checked+.radio-content i,
.custom-radio input:checked+.radio-content span {
    color: var(--blue);
}

.payment-options {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.payment-option {
    display: flex;
    align-items: center;
    padding: 1rem;
    border: 1px solid var(--gray-light);
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
}

.payment-option:hover {
    background: var(--gray-light);
}

.payment-option input {
    margin-right: 1rem;
    accent-color: var(--blue);
}

.order-summary-sticky {
    position: sticky;
    top: 100px;
    background: var(--white);
    border: 1px solid var(--gray-light);
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.cart-summary-list {
    list-style: none;
    margin-bottom: 1.5rem;
}

.cart-summary-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--gray-light);
}

.item-details {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.item-name {
    font-weight: 600;
}

.item-qty {
    color: var(--gray-medium);
    font-size: 0.9rem;
}

.summary-totals {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.grand-total {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 2px solid var(--gray-dark);
    font-weight: bold;
}

textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--gray-medium);
    border-radius: 4px;
    font-family: inherit;
    resize: vertical;
}

/* Cart Badge & Premium Button */
.nav-cart {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(0, 86, 179, 0.1);
    padding: 0.5rem 1.2rem;
    border-radius: 50px;
    border: 1px solid rgba(0, 86, 179, 0.2);
    margin-left: 1.5rem;
    transition: var(--transition);
}

.nav-cart:hover {
    background: var(--blue);
}

.nav-cart:hover a,
.nav-cart:hover a i,
.nav-cart:hover a span {
    color: var(--white) !important;
}

.nav-cart a {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #ff3e3e;
    color: white;
    font-size: 0.75rem;
    font-weight: 800;
    min-width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(255, 62, 62, 0.4);
    border: 2px solid var(--white);
    transition: var(--transition);
}

.cart-badge.empty {
    background: var(--gray-medium);
    box-shadow: none;
    opacity: 0.7;
}

/* Animations */
@keyframes cart-bump {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

.cart-bump {
    animation: cart-bump 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Cart Toast Notification */
.cart-toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    z-index: 9999;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border-left: 5px solid #28a745;
}

.cart-toast.show {
    transform: translateY(0);
    opacity: 1;
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.toast-content i {
    font-size: 1.8rem;
    color: #28a745;
}

.toast-text {
    display: flex;
    flex-direction: column;
}

.toast-title {
    font-weight: 800;
    font-size: 0.9rem;
    color: var(--gray-dark);
}

.toast-product {
    font-size: 0.85rem;
    color: var(--gray-medium);
}

.toast-link {
    background: var(--blue);
    color: var(--white);
    padding: 0.4rem 1rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.85rem;
}

.toast-link:hover {
    background: var(--blue-dark);
}

/* Cart Page Styles */
.cart-page-header {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('https://images.unsplash.com/photo-1486262715619-67b85e0b08d3?q=80&w=1000&auto=format&fit=crop');
    background-size: cover;
    background-position: center;
    color: var(--white);
    text-align: center;
    padding: 4rem 1rem;
}

.cart-main-container {
    max-width: 1000px;
    margin: -2rem auto 4rem;
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    padding: 2rem;
    position: relative;
    z-index: 10;
}

.cart-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
}

.cart-table th {
    text-align: left;
    padding: 1rem;
    border-bottom: 2px solid var(--gray-light);
    color: var(--gray-medium);
    text-transform: uppercase;
    font-size: 0.8rem;
}

.cart-table td {
    padding: 1.5rem 1rem;
    border-bottom: 1px solid var(--gray-light);
    vertical-align: middle;
}

.cart-product {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cart-product img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    background: var(--gray-light);
    border-radius: 4px;
}

.cart-product-info h4 {
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.cart-qty-input {
    width: 60px;
    padding: 0.5rem;
    border: 1px solid var(--gray-medium);
    border-radius: 4px;
    text-align: center;
}

.remove-btn {
    background: none;
    border: none;
    color: #ff4444;
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition);
}

.remove-btn:hover {
    color: #cc0000;
    transform: scale(1.1);
}

.cart-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-top: 2px solid var(--gray-light);
    padding-top: 2rem;
}

.cart-total-box {
    text-align: right;
    min-width: 250px;
}

.total-amount {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--blue);
    margin-bottom: 1rem;
}

.empty-cart-message {
    text-align: center;
    padding: 4rem 1rem;
}

.empty-cart-message i {
    font-size: 4rem;
    color: var(--gray-medium);
    margin-bottom: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 1rem;
    }

    nav ul li {
        margin: 0 1rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }

    .checkout-container {
        grid-template-columns: 1fr;
        padding: 0 5%;
    }

    .form-row,
    .radio-grid {
        grid-template-columns: 1fr;
    }

    .order-summary-sticky {
        position: static;
        margin-top: 2rem;
    }
}