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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background: #2c3e50;
    color: #fff;
    padding: 15px 0;
    margin-bottom: 30px;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.logo a {
    font-size: 1.8rem;
    font-weight: bold;
    color: #fff;
    text-decoration: none;
}

nav a {
    color: #ecf0f1;
    text-decoration: none;
    margin-left: 20px;
    transition: color 0.3s;
}

nav a:hover {
    color: #3498db;
}

/* Main */
main {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Footer */
footer {
    background: #2c3e50;
    color: #ecf0f1;
    text-align: center;
    padding: 20px 0;
    margin-top: 30px;
}

/* Products grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.product-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    background: #fff;
    transition: transform 0.2s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.product-card img, .no-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    background: #f0f0f0;
    border-radius: 5px;
    margin-bottom: 10px;
}

.product-card h3 {
    font-size: 1.2rem;
    margin: 10px 0;
}

.price {
    font-size: 1.3rem;
    font-weight: bold;
    color: #e67e22;
    margin: 10px 0;
}

.btn {
    display: inline-block;
    background: #3498db;
    color: #fff;
    padding: 8px 15px;
    border-radius: 5px;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-primary {
    background: #e67e22;
}

.btn:hover {
    background: #2980b9;
}

.btn-primary:hover {
    background: #d35400;
}

/* Product detail */
.product-detail {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.product-image {
    flex: 1;
    min-width: 250px;
}

.product-image img, .product-image .no-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.product-info {
    flex: 1;
}

.product-info h1 {
    margin-bottom: 15px;
}

.product-info .description {
    margin-bottom: 20px;
    color: #555;
}

.product-info .price {
    font-size: 1.8rem;
}

.product-info form {
    margin-top: 20px;
}

.product-info input[type="number"] {
    width: 80px;
    padding: 8px;
    margin-right: 10px;
}

/* Cart table */
.cart-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.cart-table th, .cart-table td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}

.cart-table th {
    background: #f2f2f2;
}

.cart-total {
    text-align: right;
    font-size: 1.2rem;
    margin: 20px 0;
}

.cart-buttons {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

/* Checkout form */
.checkout-form {
    max-width: 600px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.order-summary {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    margin: 20px 0;
}

.order-summary ul {
    list-style: none;
    margin: 10px 0;
}

.errors {
    background: #f8d7da;
    color: #721c24;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .product-detail {
        flex-direction: column;
    }
    .cart-table th, .cart-table td {
        padding: 8px;
    }
}