/* ===== 1. CORE STYLES ===== */
:root {
    --primary: #e63946;
    --primary-dark: #d62828;
    --secondary: #f1faee;
    --success: #2a9d8f;
    --gray: #ccc;
    --dark: #222;
    --light-bg: #f9f9f9;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0; 
    padding: 0;
    background: var(--light-bg);
    color: var(--dark);
    line-height: 1.6;
}

/* ===== 2. HEADER & NAVIGATION ===== */
header {
    background: var(--primary);
    color: white;
    padding: 15px 5%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

header h1 {
    font-size: 1.8rem;
    letter-spacing: 2px;
    margin: 0;
}

nav {
    display: flex;
    gap: 15px;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

nav a:hover, nav a.active {
    background-color: var(--secondary);
    color: var(--primary);
    box-shadow: 0 0 10px rgba(241, 250, 238, 0.5);
}

/* ===== 3. SECTION CONTROL ===== */
.section {
    max-width: 1100px;
    margin: 40px auto;
    padding: 20px;
    display: none; /* Hidden by default */
    animation: fadeIn 0.5s ease;
}

.section.active {
    display: block !important; /* Shown when active */
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===== 4. HOME / HERO SECTION ===== */
.hero-card {
    background: white;
    padding: 80px 40px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    border-top: 6px solid var(--primary);
}

.hero-card h2 { font-size: 2.5rem; color: var(--primary); }

.cta-button, .order-btn {
    background: var(--primary);
    color: white;
    padding: 15px 35px;
    font-size: 1.1rem;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 700;
    transition: 0.3s;
    margin-top: 20px;
}

.cta-button:hover, .order-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(230, 57, 70, 0.3);
}

/* ===== 5. PRODUCT GRID ===== */
.products {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    padding: 20px;
    text-align: center;
    transition: transform 0.3s ease;
}

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

.card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 15px;
}

.card button {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    width: 100%;
}

/* ===== 6. FORMS (LOGIN & FEEDBACK) ===== */
input, textarea, select {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    border-radius: 8px;
    border: 1px solid #ddd;
    box-sizing: border-box;
    font-size: 1rem;
}

.rating-stars {
    font-size: 2.5rem;
    cursor: pointer;
    display: flex;
    gap: 10px;
    justify-content: center;
    margin: 15px 0;
}

.star { 
    color: var(--gray); 
    transition: 0.2s; 
}

/* This is the key for your JavaScript to light up stars */
.star.active, .star:hover { 
    color: var(--primary); 
}

/* ===== 7. CART TABLE ===== */
table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 10px;
    overflow: hidden;
}

th { background: #eee; padding: 15px; }
td { padding: 15px; border-bottom: 1px solid #eee; text-align: center; }

button[onclick="checkout()"] {
    background: var(--success);
    width: 100%;
    padding: 15px;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    margin-top: 20px;
    cursor: pointer;
}
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 30px;
    text-align: center;
}

.contact-item {
    padding: 20px;
    background: #fdf2f2;
    border-radius: 12px;
    border: 1px solid #f8d7da;
    transition: transform 0.3s;
}

.contact-item:hover {
    transform: translateY(-5px);
    background: #fff;
    box-shadow: 0 5px 15px rgba(230, 57, 70, 0.1);
}

.contact-item h3 {
    color: #e63946;
    margin-bottom: 10px;
}

.contact-item p {
    margin: 5px 0;
    color: #444;
    font-weight: 500;
}

.social-links {
    margin-top: 40px;
    border-top: 1px solid #eee;
    padding-top: 20px;
    color: #777;
}

