:root {
    --primary: #e74c3c;
    --primary-dark: #c0392b;
    --secondary: #f39c12;
    --light: #f8f9fa;
    --dark: #343a40;
    --gray: #6c757d;
    --light-gray: #e9ecef;
    --border-radius: 8px;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s ease;
}

* {
    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);
    background-color: #fff;
}

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

/* Top Bar Styles */
.top-bar {
    background-color: var(--dark);
    color: white;
    font-size: 0.9rem;
    padding: 10px 0;
}

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

.top-bar-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.top-bar-left i {
    color: var(--primary);
    font-size: 1rem;
}

.top-bar-right {
    display: flex;
    gap: 15px;
    align-items: center;
}

.top-bar-right a {
    color: white;
    text-decoration: none;
    font-size: 0.95rem;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
}

.top-bar-right a:hover {
    color: var(--primary);
    background-color: white;
    transform: translateY(-2px);
}

/* Header Styles */
header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    position: relative;
}

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 80px;
    width: auto;
    object-fit: contain;
    transition: var(--transition);
}

.logo-img:hover {
    transform: scale(1.05);
}

nav .nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

nav .nav-menu>li {
    position: relative;
}

nav a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    font-size: 1.1rem;
    transition: var(--transition);
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 5px;
}

nav a:hover {
    color: var(--primary);
}

nav .nav-menu>li>a::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary);
    transition: var(--transition);
}

nav .nav-menu>li>a:hover::after {
    width: 100%;
}

/* Dropdown Styles */
.dropdown {
    position: relative;
}

.dropdown-toggle {
    cursor: pointer;
}

.dropdown-toggle i.fa-chevron-down {
    font-size: 0.8rem;
    transition: transform 0.3s ease;
}

.dropdown:hover .dropdown-toggle i.fa-chevron-down {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border-radius: var(--border-radius);
    min-width: 200px;
    padding: 10px 0;
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    margin: 0;
}

.dropdown-menu a {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--dark);
    font-size: 1rem;
    white-space: nowrap;
    transition: var(--transition);
}

.dropdown-menu a::after {
    display: none;
}

.dropdown-menu a:hover {
    background-color: var(--light-gray);
    color: var(--primary);
    padding-left: 25px;
}

.dropdown-menu i {
    width: 20px;
    text-align: center;
    color: var(--primary);
}

.search-bar {
    display: flex;
    align-items: center;
    background: var(--light-gray);
    border-radius: 30px;
    padding: 8px 15px;
    width: 250px;
}

.search-bar input {
    border: none;
    background: transparent;
    outline: none;
    width: 100%;
    font-size: 1rem;
}

.search-bar button {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary);
    cursor: pointer;
    padding: 10px;
    transition: var(--transition);
}

.mobile-menu-toggle:hover {
    color: var(--primary-dark);
}

.mobile-menu-toggle:active {
    transform: scale(0.95);
}

.mobile-menu-toggle i {
    pointer-events: none;
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('https://images.unsplash.com/photo-1504674900247-0877df9cc836?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80');
    background-size: cover;
    background-position: center;
    height: 500px;
    display: flex;
    align-items: center;
    color: white;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.hero h2 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
}

/* Category Hero */
.category-hero {
    height: 400px;
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    margin-bottom: 40px;
}

.category-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}

.category-hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 20px;
}

.category-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 15px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.category-hero p {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
}

.breadcrumb {
    margin-bottom: 20px;
    font-size: 0.9rem;
    opacity: 0.9;
}

.breadcrumb a {
    color: white;
    text-decoration: none;
}

.breadcrumb i {
    margin: 0 10px;
    font-size: 0.8rem;
}

.btn {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(231, 76, 60, 0.3);
}

/* Recipe Categories */
.section-title {
    text-align: center;
    margin: 50px 0 30px;
    position: relative;
}

.section-title h2 {
    font-size: 2.2rem;
    color: var(--dark);
    display: inline-block;
    padding-bottom: 10px;
}

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

.categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin: 40px 0;
}

.category-card {
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    height: 100%;
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.1);
}

.category-img {
    height: 200px;
    overflow: hidden;
}

.category-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.category-card:hover .category-img img {
    transform: scale(1.1);
}

.category-content {
    padding: 20px;
    background: white;
}

.category-content h3 {
    margin-bottom: 10px;
    color: var(--dark);
}

/* Featured Recipes */
.recipes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

.recipe-card {
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    background: white;
}

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

.recipe-img {
    height: 220px;
    overflow: hidden;
}

.recipe-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.recipe-card:hover .recipe-img img {
    transform: scale(1.05);
}

.recipe-content {
    padding: 20px;
}

.recipe-meta {
    display: flex;
    justify-content: space-between;
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.recipe-title {
    margin-bottom: 10px;
}

.recipe-title h3 {
    font-size: 1.3rem;
    color: var(--dark);
}

.recipe-excerpt {
    color: var(--gray);
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.recipe-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--light-gray);
    padding-top: 15px;
}

.rating {
    color: var(--secondary);
}

/* Newsletter */
.newsletter {
    background: linear-gradient(to right, var(--primary), var(--secondary));
    padding: 60px 0;
    margin: 60px 0;
    text-align: center;
    color: white;
}

.newsletter h2 {
    font-size: 2.2rem;
    margin-bottom: 20px;
}

.newsletter p {
    max-width: 600px;
    margin: 0 auto 30px;
}

.newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 15px 20px;
    border: none;
    border-radius: 30px 0 0 30px;
    font-size: 1rem;
}

.newsletter-form button {
    background: var(--dark);
    color: white;
    border: none;
    padding: 0 30px;
    border-radius: 0 30px 30px 0;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.newsletter-form button:hover {
    background: #1a1a1a;
}

/* Footer */
footer {
    background: #3a444e;
    color: white;
    padding: 60px 0 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 0;
    padding-bottom: 40px;
}

/* Shift the first column (Logo & Text) slightly left */
.footer-column:first-child {
    margin-left: -15px;
}

.footer-logo-icon {
    height: 120px;
    width: auto;
    max-width: 250px;
    margin-bottom: 20px;
    object-fit: contain;
}

.footer-column h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background: var(--primary);
}

.footer-column p {
    color: #adb5bd;
    margin-bottom: 20px;
    line-height: 1.8;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #adb5bd;
    text-decoration: none;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-links a i {
    color: #e67e50;
    width: 18px;
}

.footer-links a:hover {
    color: white;
}

.footer-author {
    color: #adb5bd;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 0;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-author i {
    color: #e67e50;
    width: 18px;
}

.footer-social-icons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.footer-social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: #495057;
    color: white;
    transition: var(--transition);
    font-size: 1.1rem;
}

.footer-social-icons a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.footer-bottom {
    background: #1a1f25;
    padding: 25px 0;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #adb5bd;
    font-size: 0.9rem;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-bottom-left p {
    margin: 0;
}

.footer-bottom-right {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
}

.footer-bottom-right a {
    color: #adb5bd;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.9rem;
}

.footer-bottom-right a:hover {
    color: #e67e50;
}

/* Tablet and small desktop adjustments */
@media (max-width: 1024px) {
    .container {
        padding: 0 15px;
    }

    nav .nav-menu {
        gap: 20px;
    }

    nav a {
        font-size: 1rem;
    }

    .hero h2 {
        font-size: 3rem;
    }

    .recipes-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 25px;
    }
}

/* Mobile Responsive Design */
@media (max-width: 768px) {

    /* Top Bar Mobile */
    .top-bar {
        font-size: 0.8rem;
        padding: 10px 0;
    }

    .top-bar-container {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .top-bar-left {
        justify-content: center;
        font-size: 0.9rem;
    }

    .top-bar-left i {
        font-size: 1.1rem;
    }

    .top-bar-right {
        gap: 12px;
    }

    .top-bar-right a {
        width: 35px;
        height: 35px;
        font-size: 0.95rem;
    }

    /* Header Mobile */
    .header-container {
        padding: 15px 0;
        position: relative;
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .logo {
        order: 2;
        display: flex;
        justify-content: center;
        width: 100%;
    }

    .logo-img {
        height: 60px;
    }

    /* Mobile Menu Toggle */
    .mobile-menu-toggle {
        display: block !important;
        position: absolute;
        left: 10px;
        top: 50%;
        transform: translateY(-50%);
        z-index: 1001;
        color: var(--primary);
        font-size: 1.8rem;
        padding: 5px 10px;
        min-width: 44px;
        min-height: 44px;
    }

    /* Mobile Navigation */
    .main-nav {
        position: fixed;
        top: 0;
        left: -100%;
        width: 280px;
        height: 100vh;
        background: white;
        box-shadow: 5px 0 15px rgba(0, 0, 0, 0.1);
        transition: left 0.3s ease;
        z-index: 1000;
        overflow-y: auto;
        padding-top: 20px;
    }

    .main-nav.active {
        left: 0;
    }


    nav .nav-menu {
        flex-direction: column;
        gap: 0;
        padding: 60px 0 20px;
    }

    nav .nav-menu>li {
        width: 100%;
        border-bottom: 1px solid var(--light-gray);
    }

    nav .nav-menu>li>a {
        padding: 15px 20px;
        font-size: 1.05rem;
        justify-content: space-between;
    }

    nav .nav-menu>li>a::after {
        display: none;
    }

    /* Mobile Dropdown */
    .dropdown-toggle i.fa-chevron-down {
        margin-left: auto;
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        background: var(--light-gray);
        border-radius: 0;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    .dropdown.active .dropdown-menu {
        max-height: 500px;
    }

    .dropdown-menu a {
        padding: 12px 20px 12px 40px;
        font-size: 0.95rem;
    }

    .dropdown-menu a:hover {
        padding-left: 45px;
    }

    /* Search Bar Mobile */
    .search-bar {
        width: 100%;
        max-width: 100%;
        order: 3;
        margin: 0;
        padding: 10px 15px;
        border-radius: 8px;
        background: var(--light-gray);
    }

    .search-bar input {
        font-size: 1rem;
        padding: 0;
    }

    .search-bar button {
        font-size: 1.1rem;
    }

    /* Hero Mobile */
    .hero {
        height: 450px;
        padding: 40px 20px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero h2 {
        font-size: 2.2rem;
        margin-bottom: 15px;
        line-height: 1.2;
    }

    .hero p {
        font-size: 1rem;
        margin-bottom: 25px;
        line-height: 1.5;
    }

    .btn {
        padding: 10px 25px;
        font-size: 0.95rem;
    }

    /* Section Titles Mobile */
    .section-title {
        margin: 35px 0 25px;
    }

    .section-title h2 {
        font-size: 1.8rem;
    }

    /* Categories Mobile */
    .categories {
        grid-template-columns: 1fr;
        gap: 20px;
        margin: 30px 0;
    }

    .category-card {
        max-width: 400px;
        margin: 0 auto;
    }

    /* Recipes Grid Mobile */
    .recipes-grid {
        grid-template-columns: 1fr;
        gap: 25px;
        margin: 30px 0;
    }

    .recipe-card {
        max-width: 400px;
        margin: 0 auto;
    }

    .recipe-meta {
        font-size: 0.85rem;
    }

    .recipe-title h3 {
        font-size: 1.2rem;
    }

    /* Newsletter Mobile */
    .newsletter {
        padding: 40px 0;
        margin: 40px 0;
    }

    .newsletter h2 {
        font-size: 1.8rem;
        margin-bottom: 15px;
    }

    .newsletter p {
        font-size: 0.95rem;
    }

    .newsletter-form {
        flex-direction: column;
        gap: 10px;
    }

    .newsletter-form input,
    .newsletter-form button {
        width: 100%;
        border-radius: 30px;
        padding: 12px 20px;
    }

    /* Footer Mobile */
    footer {
        padding: 40px 0 15px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
        margin-bottom: 30px;
    }

    .footer-column {
        text-align: center;
    }

    .footer-logo {
        height: 50px;
        margin: 0 auto 15px;
    }

    .footer-column h3 {
        font-size: 1.2rem;
        margin-bottom: 15px;
    }

    .footer-column h3::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-links {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .footer-links a {
        justify-content: center;
    }

    .footer-social-icons {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        max-width: 300px;
        margin: 20px auto 0;
    }

    .footer-social-icons a {
        width: 42px;
        height: 42px;
        font-size: 1rem;
    }

    .footer-bottom {
        padding: 15px 0;
    }

    .footer-bottom-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        font-size: 0.75rem;
        gap: 10px;
    }

    .footer-bottom-left p {
        font-size: 0.75rem;
    }

    .footer-bottom-right {
        justify-content: flex-end;
        gap: 10px;
        flex-wrap: wrap;
    }

    .footer-bottom-right a {
        font-size: 0.75rem;
    }
}

/* Small Mobile Phones */
@media (max-width: 480px) {
    .top-bar {
        font-size: 0.7rem;
        padding: 6px 0;
    }

    .top-bar-right a {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }

    .logo-img {
        height: 55px;
    }

    .mobile-menu-toggle {
        font-size: 1.6rem;
    }

    .hero {
        height: 400px;
        padding: 30px 15px;
    }

    .hero h2 {
        font-size: 1.9rem;
    }

    .hero p {
        font-size: 0.95rem;
    }

    .section-title h2 {
        font-size: 1.5rem;
    }

    .newsletter h2 {
        font-size: 1.5rem;
    }

    .footer-social-icons {
        max-width: 250px;
    }

    .footer-social-icons a {
        width: 38px;
        height: 38px;
        font-size: 0.9rem;
    }
}