/* Global Styles */
:root {
    --primary-color: #ff6b6b;
    --secondary-color: #ffa502;
    --dark-color: #2f3542;
    --light-color: #f1f2f6;
    --success-color: #2ed573;
    --white-color: #ffffff;
    --black-color: #000000;
    --gray-color: #a4b0be;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
    background-color: var(--light-color);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    background: var(--primary-color);
    color: var(--white-color);
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    font-size: 16px;
    transition: all 0.3s ease;
}

.btn:hover {
    background: #ff5252;
    transform: translateY(-2px);
}

/* Header Styles */
header {
    background-color: var(--white-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.logo h1 {
    color: var(--primary-color);
    font-size: 24px;
}

.logo i {
    margin-right: 10px;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 500;
    transition: color 0.3s ease;
}

nav ul li a:hover, nav ul li a.active {
    color: var(--primary-color);
}

.search-box {
    display: flex;
    align-items: center;
}

.search-box input {
    padding: 8px 15px;
    border: 1px solid var(--gray-color);
    border-radius: 5px 0 0 5px;
    outline: none;
}

.search-box button {
    background: var(--primary-color);
    color: var(--white-color);
    border: none;
    padding: 8px 15px;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
}

.mobile-menu {
    display: none;
    font-size: 24px;
    cursor: pointer;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('../images/hero-bg.jpg') no-repeat center center/cover;
    height: 80vh;
    display: flex;
    align-items: center;
    text-align: center;
    color: var(--white-color);
    margin-top: 70px;
}

.hero h2 {
    font-size: 48px;
    margin-bottom: 20px;
}

.hero p {
    font-size: 20px;
    margin-bottom: 30px;
}

/* Featured Recipes */
.featured-recipes {
    padding: 60px 0;
}

.featured-recipes h2 {
    text-align: center;
    margin-bottom: 40px;
    font-size: 36px;
    color: var(--dark-color);
}

.recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.recipe-card {
    background: var(--white-color);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.recipe-card:hover {
    transform: translateY(-10px);
}

.recipe-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.recipe-card h3 {
    padding: 15px 20px 5px;
    font-size: 22px;
}

.recipe-card p {
    padding: 0 20px 15px;
    color: var(--gray-color);
}

.recipe-card .btn {
    display: block;
    margin: 0 20px 20px;
    text-align: center;
}

/* Newsletter */
.newsletter {
    background: var(--primary-color);
    color: var(--white-color);
    padding: 60px 0;
    text-align: center;
}

.newsletter h2 {
    font-size: 32px;
    margin-bottom: 15px;
}

.newsletter p {
    font-size: 18px;
    margin-bottom: 30px;
}

.newsletter form {
    display: flex;
    justify-content: center;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter input {
    flex: 1;
    padding: 12px 15px;
    border: none;
    border-radius: 5px 0 0 5px;
    outline: none;
}

.newsletter button {
    background: var(--dark-color);
    color: var(--white-color);
    border: none;
    padding: 12px 20px;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
    transition: background 0.3s ease;
}

.newsletter button:hover {
    background: #1e272e;
}

/* Footer */
footer {
    background: var(--dark-color);
    color: var(--white-color);
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h3 {
    font-size: 20px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 2px;
    background: var(--primary-color);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: var(--gray-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--white-color);
}

.social-icons {
    margin-top: 20px;
}

.social-icons a {
    display: inline-block;
    margin-right: 15px;
    color: var(--white-color);
    font-size: 20px;
    transition: color 0.3s ease;
}

.social-icons a:hover {
    color: var(--primary-color);
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--gray-color);
}

/* Recipe Page Styles */
.recipe-header {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), var(--recipe-image) no-repeat center center/cover;
    height: 400px;
    display: flex;
    align-items: flex-end;
    color: var(--white-color);
    margin-top: 70px;
    padding: 40px 0;
    position: relative;
}

.recipe-header::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(to bottom, transparent, var(--light-color));
}

.recipe-header-content {
    position: relative;
    z-index: 1;
}

.recipe-header h1 {
    font-size: 48px;
    margin-bottom: 15px;
}

.recipe-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.recipe-meta-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.recipe-content {
    padding: 60px 0;
}

.recipe-container {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
}

.recipe-ingredients, .recipe-instructions {
    background: var(--white-color);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
}

.recipe-sidebar {
    position: sticky;
    top: 90px;
    height: fit-content;
}

.recipe-card-sidebar {
    background: var(--white-color);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
}

.recipe-card-sidebar h3 {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--gray-color);
}

.section-title {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--primary-color);
    position: relative;
    padding-bottom: 10px;
}

.section-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 3px;
    background: var(--secondary-color);
}

.ingredient-list {
    list-style: none;
}

.ingredient-list li {
    padding: 8px 0;
    border-bottom: 1px dashed var(--gray-color);
    display: flex;
}

.ingredient-list li:last-child {
    border-bottom: none;
}

.ingredient-quantity {
    font-weight: bold;
    margin-right: 10px;
    min-width: 80px;
}

.instruction-list {
    list-style: none;
    counter-reset: instruction-counter;
}

.instruction-list li {
    counter-increment: instruction-counter;
    margin-bottom: 20px;
    padding-left: 40px;
    position: relative;
}

.instruction-list li::before {
    content: counter(instruction-counter);
    position: absolute;
    left: 0;
    top: 0;
    background: var(--primary-color);
    color: var(--white-color);
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.nutrition-facts {
    width: 100%;
    border-collapse: collapse;
}

.nutrition-facts th, .nutrition-facts td {
    padding: 8px 0;
    border-bottom: 1px solid var(--gray-color);
    text-align: left;
}

.nutrition-facts tr:last-child th, 
.nutrition-facts tr:last-child td {
    border-bottom: none;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .recipe-container {
        grid-template-columns: 1fr;
    }
    
    .recipe-sidebar {
        position: static;
        order: -1;
    }
}

@media (max-width: 768px) {
    nav {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 80%;
        height: calc(100vh - 70px);
        background: var(--white-color);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
        transition: all 0.3s ease;
    }
    
    nav.active {
        left: 0;
    }
    
    nav ul {
        flex-direction: column;
        padding: 20px;
    }
    
    nav ul li {
        margin: 15px 0;
    }
    
    .mobile-menu {
        display: block;
    }
    
    .search-box {
        display: none;
    }
    
    .hero h2 {
        font-size: 36px;
    }
    
    .hero p {
        font-size: 18px;
    }
    
    .recipe-header h1 {
        font-size: 36px;
    }
}

@media (max-width: 576px) {
    .hero {
        height: 60vh;
    }
    
    .recipe-meta {
        flex-direction: column;
        gap: 10px;
    }
}