/* ========================================
   VARIABLES & FONTS
   ======================================== */
:root {
    --primary-color: #ff6b6b;
    --secondary-color: #4ecdc4;
    --dark-bg: #1a1a1a;
    --dark-secondary: #2d2d2d;
    --dark-tertiary: #404040;
    --text-light: #f8f9fa;
    --text-muted: #adb5bd;
    --navbar-blur: rgba(26, 26, 26, 0.85);
    --footer-bg: #0d0d0d;
    --transition-speed: 0.3s;
    
    /* Bootstrap Color Overrides */
    --bs-primary: #ff6b6b;
    --bs-primary-rgb: 255, 107, 107;
    --bs-secondary: #4ecdc4;
    --bs-secondary-rgb: 78, 205, 196;
    --bs-success: #51cf66;
    --bs-success-rgb: 81, 207, 102;
    --bs-info: #66d9ef;
    --bs-info-rgb: 102, 217, 239;
    --bs-warning: #ffd93d;
    --bs-warning-rgb: 255, 217, 61;
    --bs-danger: #ff6b6b;
    --bs-danger-rgb: 255, 107, 107;
}

/* Bootstrap Button Overrides */
.btn-primary {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
    color: #fff;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #ff5252;
    border-color: #ff5252;
}

.btn-outline-primary {
    color: var(--bs-primary);
    border-color: var(--bs-primary);
}

.btn-outline-primary:hover {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
    color: #fff;
}

.btn-secondary {
    background-color: var(--bs-secondary);
    border-color: var(--bs-secondary);
    color: #fff;
}

.btn-secondary:hover,
.btn-secondary:focus {
    background-color: #45b8b0;
    border-color: #45b8b0;
}

.btn-outline-secondary {
    color: var(--bs-secondary);
    border-color: var(--bs-secondary);
}

.btn-outline-secondary:hover {
    background-color: var(--bs-secondary);
    border-color: var(--bs-secondary);
    color: #fff;
}

.badge.bg-primary {
    background-color: var(--bs-primary) !important;
}

.badge.bg-secondary {
    background-color: var(--bs-secondary) !important;
}

.text-primary {
    color: var(--bs-primary) !important;
}

.text-secondary {
    color: var(--bs-secondary) !important;
}

.bg-primary {
    background-color: var(--bs-primary) !important;
}

.bg-secondary {
    background-color: var(--bs-secondary) !important;
}

.card-header.bg-primary {
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
}

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

body {
    font-family: 'Raleway', sans-serif;
    color: #333;
    background-color: #f8f9fa;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Nunito Sans', sans-serif;
    font-weight: 700;
}

/* ========================================
   NAVBAR STYLES
   ======================================== */
#mainNav {
    padding: 1rem 0;
    background-color: var(--navbar-blur);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    transition: all var(--transition-speed) ease;
}

#mainNav .navbar-brand {
    font-family: 'Nunito Sans', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-light) !important;
    transition: all var(--transition-speed);
}

#mainNav .navbar-brand:hover {
    color: var(--primary-color) !important;
}

#mainNav .logo-img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

#mainNav .site-name {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

#mainNav .nav-link {
    color: var(--text-light) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: all var(--transition-speed);
    position: relative;
}

#mainNav .nav-link:hover,
#mainNav .nav-link.active {
    color: var(--primary-color) !important;
}

#mainNav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width var(--transition-speed);
}

#mainNav .nav-link:hover::after,
#mainNav .nav-link.active::after {
    width: 80%;
}

#mainNav .btn-outline-light {
    border-color: var(--text-light);
    color: var(--text-light);
    transition: all var(--transition-speed);
}

#mainNav .btn-outline-light:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

#mainNav .dropdown-menu-dark {
    background-color: var(--dark-secondary);
    border: none;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
}

#mainNav .dropdown-item {
    color: var(--text-light);
    transition: all var(--transition-speed);
}

#mainNav .dropdown-item:hover {
    background-color: var(--dark-tertiary);
    color: var(--primary-color);
}

/* Search Box in Navbar */
.search-box {
    position: relative;
    width: 250px;
}

.search-input {
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-light);
    padding: 0.5rem 2.5rem 0.5rem 1rem;
    border-radius: 25px;
    transition: all var(--transition-speed);
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.search-input:focus {
    background-color: rgba(255, 255, 255, 0.2);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(255, 107, 107, 0.25);
    color: white;
    outline: none;
}

.search-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.6);
    pointer-events: none;
}

.search-results {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    right: 0;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    max-height: 400px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
}

.search-results.show {
    display: block;
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #f0f0f0;
    text-decoration: none;
    color: #333;
    transition: all var(--transition-speed);
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background-color: #f8f9fa;
}

.search-result-image {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    object-fit: cover;
    margin-right: 1rem;
    background-color: #e9ecef;
}

.search-result-info {
    flex: 1;
}

.search-result-title {
    font-weight: 600;
    color: var(--dark-bg);
    margin: 0 0 0.25rem 0;
    font-size: 0.95rem;
}

.search-result-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.search-no-results {
    padding: 1.5rem;
    text-align: center;
    color: var(--text-muted);
}

.search-loading {
    padding: 1.5rem;
    text-align: center;
    color: var(--text-muted);
}

/* Mobile Navbar */
@media (max-width: 991px) {
    #mainNav .navbar-collapse {
        background-color: var(--dark-secondary);
        padding: 1rem;
        margin-top: 1rem;
        border-radius: 8px;
    }
    
    #mainNav .nav-link::after {
        display: none;
    }
}

/* ========================================
   MAIN CONTENT
   ======================================== */
.main-content {
    padding-top: 76px; /* Height of fixed navbar */
    min-height: calc(100vh - 400px);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(rgba(26, 26, 26, 0.7), rgba(45, 45, 45, 0.7)), url('../img/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--text-light);
    min-height: 50vh;
    display: flex;
    align-items: center;
    position: relative;
    width: 100%;
}

.hero-title {
    font-family: 'Nunito Sans', sans-serif;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    color: var(--text-muted);
    font-size: 1.25rem;
}

.hero-buttons .btn {
    border-radius: 50px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    transition: all var(--transition-speed);
}

.hero-buttons .btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
}

.hero-buttons .btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 107, 107, 0.4);
}

.hero-buttons .btn-outline-light:hover {
    background-color: white;
    color: var(--dark-bg);
    transform: translateY(-3px);
}

/* Section Titles */
.section-title {
    font-family: 'Nunito Sans', sans-serif;
    font-weight: 800;
    font-size: 2.5rem;
    color: var(--dark-bg);
    margin-bottom: 0.5rem;
}

.section-subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
}

/* Recipe Cards */
.recipe-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.recipe-card {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    transition: all var(--transition-speed);
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
}

.recipe-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.recipe-card-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

.recipe-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.7) 50%, transparent 100%);
    display: flex;
    align-items: flex-end;
    padding: 1.5rem;
    transition: all var(--transition-speed);
}

.recipe-card:hover .recipe-card-overlay {
    height: 60%;
}

.recipe-card-info {
    width: 100%;
}

.recipe-card-title {
    font-family: 'Nunito Sans', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: white;
    margin: 0 0 0.75rem 0;
    line-height: 1.3;
}

.recipe-card-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.9);
}

.recipe-card-meta span {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

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

/* Category Cards */
.category-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    transition: all var(--transition-speed);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    height: 100%;
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.category-icon {
    font-size: 3rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.category-card h3 {
    font-family: 'Nunito Sans', sans-serif;
    color: var(--dark-bg);
    margin-bottom: 1rem;
}

.category-card p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.category-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: all var(--transition-speed);
}

.category-link:hover {
    color: var(--secondary-color);
}

/* ========================================
   FOOTER STYLES
   ======================================== */
.footer-dark {
    background-color: var(--footer-bg);
    color: var(--text-light);
    margin-top: 4rem;
}

.footer-heading {
    font-family: 'Nunito Sans', sans-serif;
    font-weight: 700;
    color: var(--text-light);
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.75rem;
}

.footer-heading::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.footer-text {
    color: var(--text-muted);
    line-height: 1.8;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: var(--dark-secondary);
    color: var(--text-light);
    border-radius: 50%;
    text-decoration: none;
    transition: all var(--transition-speed);
}

.social-link:hover {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    transform: translateY(-3px);
}

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

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-speed);
}

.footer-links a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.footer-contact {
    list-style: none;
    padding: 0;
}

.footer-contact li {
    margin-bottom: 1rem;
    color: var(--text-muted);
}

.footer-contact a {
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-speed);
}

.footer-contact a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid var(--dark-secondary);
    padding: 2rem 0 1rem;
    margin-top: 2rem;
}

.copyright-text {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.copyright-text a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all var(--transition-speed);
}

.copyright-text a:hover {
    color: var(--secondary-color);
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .footer-heading::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-heading {
        text-align: center;
    }
    
    .social-links {
        justify-content: center;
    }
}

/* ========================================
   FLASH MESSAGES & ALERTS
   ======================================== */
.alert {
    border-radius: 10px;
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
}

.alert-danger {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
}

.alert-info {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    color: #0c5460;
}

.alert-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    color: #856404;
}

.alert .btn-close {
    background-size: 1rem;
}

/* ========================================
   LOGIN MODAL STYLES
   ======================================== */
.modal-content {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: 15px 15px 0 0;
    padding: 1.5rem;
}

.modal-header .modal-title {
    font-family: 'Nunito Sans', sans-serif;
    font-weight: 700;
}

.modal-header .btn-close {
    filter: brightness(0) invert(1);
}

.modal-body {
    background-color: white;
}

.modal-footer {
    background-color: #f8f9fa;
    border-radius: 0 0 15px 15px;
    padding: 1.5rem;
}

#loginForm .form-control {
    border-radius: 8px;
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    transition: all var(--transition-speed);
}

#loginForm .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(255, 107, 107, 0.25);
}

#loginForm .btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
    border-radius: 8px;
    padding: 0.75rem;
    font-weight: 600;
    transition: all var(--transition-speed);
}

#loginForm .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.3);
}

.modal-footer .btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 8px;
    padding: 0.75rem;
    font-weight: 600;
    transition: all var(--transition-speed);
}

.modal-footer .btn-outline-primary:hover {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-color: transparent;
    color: white;
    transform: translateY(-2px);
}

/* ========================================
   RECIPE DETAIL PAGE
   ======================================== */
.recipe-detail-hero {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 50vh;
    max-height: 600px;
    height: 50vh;
    display: flex;
    align-items: flex-end;
    position: relative;
    width: 100%;
}

.recipe-detail-overlay {
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.5) 70%, transparent 100%);
    width: 100%;
    padding: 2rem 0 2.5rem;
}

.recipe-detail-title {
    font-family: 'Nunito Sans', sans-serif;
    font-size: 2.5rem;
    font-weight: 800;
    color: white;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
    line-height: 1.2;
}

.recipe-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.recipe-detail-meta .badge {
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    font-weight: 500;
}

.recipe-section {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.recipe-section-title {
    font-family: 'Nunito Sans', sans-serif;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--dark-bg);
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 3px solid var(--primary-color);
}

.recipe-description {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
}

.recipe-ingredients {
    list-style: none;
    padding: 0;
}

.recipe-ingredients li {
    padding: 0.75rem 0;
    padding-left: 2rem;
    border-bottom: 1px solid #f0f0f0;
    position: relative;
    font-size: 1.05rem;
}

.recipe-ingredients li:last-child {
    border-bottom: none;
}

.recipe-ingredients li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
    font-size: 1.2rem;
}

.recipe-instructions {
    padding-left: 1.5rem;
}

.recipe-instructions li {
    padding: 1rem 0;
    padding-left: 1rem;
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333;
}

.recipe-instructions li::marker {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.recipe-tips {
    background: linear-gradient(135deg, #fff9e6 0%, #fff3cc 100%);
    border-left: 4px solid var(--primary-color);
    padding: 1.5rem;
    border-radius: 8px;
}

.recipe-tips p {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.8;
}

.recipe-info-card {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.recipe-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.gallery-thumbnail {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 1 / 1;
}

.gallery-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-speed);
}

.gallery-thumbnail:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-speed);
}

.gallery-thumbnail:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay i {
    color: white;
    font-size: 1.5rem;
}

#imageModal .modal-content {
    background: transparent;
    border: none;
}

#imageModal .modal-body {
    border-radius: 10px;
    overflow: hidden;
}

.recipe-info-title {
    font-family: 'Nunito Sans', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--dark-bg);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #f0f0f0;
}

.recipe-info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f8f9fa;
}

.recipe-info-item:last-child {
    border-bottom: none;
}

.recipe-info-item i {
    font-size: 1.5rem;
}

.recipe-info-item div {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.recipe-author {
    text-align: center;
    padding: 1rem 0;
}

.recipe-author h5 {
    margin: 0.5rem 0 0.25rem;
    font-weight: 600;
}

.recipe-share-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.recipe-share-buttons .btn {
    padding: 0.75rem;
    border-radius: 8px;
    color: white;
    text-decoration: none;
    transition: all var(--transition-speed);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-facebook {
    background-color: #1877f2;
}

.btn-facebook:hover {
    background-color: #145dbf;
    transform: translateY(-2px);
}

.btn-twitter {
    background-color: #1da1f2;
}

.btn-twitter:hover {
    background-color: #1a8cd8;
    transform: translateY(-2px);
}

.btn-whatsapp {
    background-color: #25d366;
}

.btn-whatsapp:hover {
    background-color: #20ba5a;
    transform: translateY(-2px);
}

.btn-pinterest {
    background-color: #e60023;
}

.btn-pinterest:hover {
    background-color: #c8001f;
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .recipe-detail-title {
        font-size: 2rem;
    }
    
    .recipe-section {
        padding: 1.5rem;
    }
}

