/* --- 1. GLOBAL AYARLAR VE DEĞİŞKENLER --- */
:root {
    --primary-color: #8B0000;
    --secondary-color: #FCB514;
    --light-gray: #f4f4f4;
    --dark-gray: #333;
    --white-color: #ffffff;
    --text-color: #333;
    --header-height: 70px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: 'Poppins', sans-serif; background-color: var(--white-color); color: var(--text-color); line-height: 1.6; }
body.menu-open { overflow: hidden; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: inherit; }

/* --- 2. YARDIMCI BİLEŞENLER --- */
.alert { padding: 15px 20px; margin: 0; text-align: center; font-weight: 500; border-bottom: 1px solid #ddd; }
.alert-success { background-color: #d4edda; color: #155724; }
.alert-error { background-color: #f8d7da; color: #721c24; }
.section-title { text-align: center; font-size: 2.5rem; margin: 3rem 0 2rem 0; color: var(--primary-color); }
.page-title { font-size: 2.5rem; text-align: center; margin: 2rem 0; color: var(--primary-color); padding-bottom: 1rem; border-bottom: 2px solid var(--secondary-color); }
.no-results { text-align: center; font-size: 1.2rem; padding: 3rem; background-color: var(--light-gray); border-radius: 8px; color: var(--primary-color); }

/* --- 3. LAYOUT (HEADER, MENUS, FOOTER) --- */
.site-header { background-color: var(--primary-color); color: var(--white-color); height: var(--header-height); padding: 0 1.5rem; position: sticky; top: 0; z-index: 1000; display: flex; align-items: center; box-shadow: 0 2px 10px rgba(0,0,0,0.2); }
.menu-toggle-btn { background: none; border: none; color: var(--secondary-color); font-size: 1.8rem; cursor: pointer; padding: 0; margin-right: 1.5rem; }
.header-container { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--secondary-color); font-size: 1.6rem; font-weight: 700; }
.logo-img { height: 40px; }
.logo-mobile { display: none; }
.header-actions { display: flex; align-items: center; gap: 1rem; }
.header-btn { background-color: transparent; border: 1px solid var(--white-color); color: var(--white-color); padding: 8px 16px; border-radius: 20px; font-size: 0.9rem; transition: all 0.3s ease; }
.header-btn:hover { background-color: var(--white-color); color: var(--primary-color); }
.header-btn.login-btn { background-color: var(--secondary-color); color: var(--primary-color); border-color: var(--secondary-color); font-weight: 600; }
.welcome-user { font-weight: 600; }
.recipe-book-btn { display: inline-flex; align-items: center; gap: 0.5rem; background-color: var(--secondary-color); color: var(--primary-color); border-color: var(--secondary-color); font-weight: 600; }
.recipe-book-btn:hover { background-color: #ffca40; border-color: #ffca40; }
.side-menu { position: fixed; top: 0; left: -320px; width: 320px; height: 100%; background-color: #2c3e50; color: #ecf0f1; z-index: 1100; overflow-y: auto; box-shadow: 5px 0 25px rgba(0,0,0,0.3); transition: left 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.side-menu.open { left: 0; }
.side-menu .close-btn { position: absolute; top: 15px; right: 20px; font-size: 2.5rem; background: none; border: none; color: #7f8c8d; transition: transform 0.3s, color 0.3s; }
.side-menu .close-btn:hover { color: var(--white-color); transform: rotate(90deg); }
.side-menu .menu-content { margin-top: 60px; display: flex; flex-direction: column; }
.side-menu a { display: flex; align-items: center; gap: 15px; padding: 15px 25px; border-bottom: 1px solid #34495e; transition: background-color 0.3s, padding-left 0.3s; font-size: 1rem; font-weight: 500; }
.side-menu a:hover { background-color: var(--primary-color); padding-left: 30px; }
.side-menu .menu-category-title { font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--secondary-color); padding: 25px 25px 10px; font-size: 0.8rem; }
.menu-user-info { padding: 20px 25px; background-color: rgba(0, 0, 0, 0.2); text-align: center; line-height: 1.5; border-bottom: 1px solid #34495e; }
.menu-user-info strong { color: var(--white-color); display: block; font-size: 1.1rem; }
.sticky-nav-wrapper { position: sticky; top: var(--header-height); z-index: 999; background-color: var(--white-color); box-shadow: 0 4px 6px rgba(0,0,0,0.05); transition: transform 0.3s ease-in-out; }
.sticky-nav-wrapper.is-hidden { transform: translateY(-100%); }
.category-nav { display: none; background-color: #f8f8f8; border-bottom: 1px solid #e7e7e7; padding: 0.25rem 0; }
.search-bar-container { padding: 1.5rem 20px; }
.search-form { display: flex; max-width: 700px; margin: 0 auto; border-radius: 30px; overflow: hidden; box-shadow: 0 5px 15px rgba(0,0,0,0.08); }
.search-input { flex-grow: 1; padding: 15px 25px; border: 1px solid #ddd; border-right: none; font-size: 1rem; border-radius: 30px 0 0 30px; }
.search-input:focus { outline: none; border-color: var(--secondary-color); }
.search-button { border: none; background-color: var(--primary-color); color: var(--white-color); padding: 0 25px; font-size: 1.2rem; cursor: pointer; transition: background-color 0.3s; border-radius: 0 30px 30px 0; }
.search-button:hover { background-color: #610101; }
.site-footer { background-color: var(--dark-gray); color: #f2f2f2; padding-top: 3rem; padding-bottom: 0; margin-top: 3rem; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2rem; padding-bottom: 3rem; }
.footer-title { font-size: 1.2rem; font-weight: 600; color: var(--secondary-color); margin-bottom: 1.5rem; position: relative; padding-bottom: 0.5rem; }
.footer-title::after { content: ''; position: absolute; bottom: 0; left: 0; width: 40px; height: 2px; background-color: var(--primary-color); }
.footer-text { line-height: 1.8; color: #ccc; }
.footer-links { list-style: none; padding: 0; }
.footer-links li { margin-bottom: 0.8rem; }
.footer-links a { color: #ccc; transition: color 0.3s, padding-left 0.3s; }
.footer-links a:hover { color: var(--white-color); padding-left: 5px; }
.social-icons a { display: inline-flex; justify-content: center; align-items: center; width: 40px; height: 40px; border-radius: 50%; background-color: rgba(255, 255, 255, 0.1); color: var(--white-color); font-size: 1rem; margin-right: 0.5rem; transition: background-color 0.3s, transform 0.3s; }
.social-icons a:hover { background-color: var(--secondary-color); color: var(--dark-gray); transform: translateY(-3px); }
.footer-bottom { background-color: rgba(0, 0, 0, 0.2); padding: 1.5rem 0; text-align: center; font-size: 0.9rem; }
.footer-bottom p { margin: 0; color: #aaa; }

/* --- 4. İÇERİK BİLEŞENLERİ --- */
/* HERO BANNER (VİDEO VERSİYONU) */
.hero-banner {
    position: relative; /* İçindeki diğer elementleri konumlandırmak için */
    height: 70vh; /* Ekran yüksekliğinin %70'i kadar olsun */
    min-height: 450px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden; /* Taşan video kısımlarını gizle */
}
.video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1; /* En arkada */
}
.video-background video {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Videoyu orantısını bozmadan alana sığdır */
}
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Yazıların okunabilirliği için yarı şeffaf katman */
    z-index: 2;
}
.hero-content {
    position: relative; /* Diğer katmanların üzerinde kalması için */
    z-index: 3;
    max-width: 800px;
    padding: 20px;
}
.hero-content h1 {
    font-size: clamp(2rem, 5vw, 3.5rem); /* Farklı ekranlara göre esnek font boyutu */
    color: var(--white-color);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5); /* Yazıya gölge ekleyerek okunurluğu artır */
}
.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}
.hero-btn {
    background: var(--secondary-color);
    color: var(--primary-color);
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 2px solid var(--secondary-color);
}
.hero-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    background-color: #ffca40;
    border-color: #ffca40;
}
/* TARİF KARTLARI (DÜZELTİLMİŞ GRID) */
.recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); /* DÜZELTME: auto-fit yerine auto-fill */
    gap: 2rem;
}
.recipe-card { background: var(--white-color); border-radius: 10px; box-shadow: 0 4px 15px rgba(0,0,0,0.08); overflow: hidden; transition: all 0.3s ease; display: flex; flex-direction: column; height: 100%; position: relative; border-bottom: 4px solid transparent; }
.recipe-card:hover { transform: translateY(-8px); box-shadow: 0 8px 25px rgba(139, 0, 0, 0.15); border-bottom-color: var(--primary-color); }
.recipe-card-image-link { display: block; width: 100%; height: 200px; }
.recipe-card img { width: 100%; height: 100%; object-fit: cover; border-radius: 10px 10px 0 0; }
.recipe-card-content { padding: 1.5rem; flex-grow: 1; display: flex; flex-direction: column; }
.recipe-author { font-size: 0.8rem; color: #777; margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.4rem; }
.recipe-author i { color: var(--primary-color); }
.recipe-card h3 { font-size: 1.3rem; margin-bottom: 1rem; color: var(--primary-color); }
.recipe-card h3 a { color: inherit; text-decoration: none; }
.recipe-card-meta { display: flex; justify-content: space-around; flex-wrap: wrap; gap: 0.5rem 1rem; margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--light-gray); font-size: 0.8rem; color: #555; }
.meta-item { display: flex; align-items: center; gap: 0.5rem; }
.meta-item i { color: var(--secondary-color); }
.meta-item.rating i { color: #f39c12; }

.pagination { display: flex; justify-content: center; gap: 0.5rem; margin-top: 3rem; }
.pagination a { padding: 10px 18px; border: 1px solid #ddd; color: var(--primary-color); background-color: white; border-radius: 5px; font-weight: 600; transition: all 0.3s; }
.pagination a:hover, .pagination a.active { background-color: var(--primary-color); color: white; }

.recipe-detail-page { margin-top: 2rem; margin-bottom: 2rem; }
.recipe-article { background-color: #fff; padding: 2rem; border-radius: 8px; box-shadow: 0 5px 25px rgba(0,0,0,0.08); }
.recipe-header-detail h1 { font-size: 2.8rem; color: var(--primary-color); text-align: center; margin-bottom: 1.5rem; }
.recipe-meta-bar-detail { display: flex; justify-content: center; align-items: center; gap: 1rem 2rem; background-color: var(--light-gray); padding: 1rem; border-radius: 8px; margin: 1.5rem 0; font-size: 0.9rem; color: #555; flex-wrap: wrap; }
.recipe-meta-bar-detail span { display: flex; align-items: center; gap: 0.6rem; }
.recipe-meta-bar-detail i { color: var(--primary-color); font-size: 1.1rem; }
.recipe-meta-bar-detail strong { color: #000; }
.recipe-image-detail { width: 100%; max-height: 500px; object-fit: cover; border-radius: 8px; margin-bottom: 1.5rem; }
.recipe-description-detail { font-size: 1.1rem; text-align: center; color: #555; margin-bottom: 2rem; }
.recipe-content-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 3rem; }
.ingredients-section h2, .instructions-section h2 { font-size: 1.8rem; color: var(--primary-color); margin-bottom: 1rem; border-bottom: 2px solid var(--secondary-color); padding-bottom: 0.5rem; }
/* TARİF DETAY LİSTE STİLLERİ (ALT BAŞLIK DESTEKLİ) */
.ingredients-section ul, 
.instructions-section ol { 
    list-style: none; 
    padding-left: 0; 
}
.ingredients-section li, 
.instructions-section li { 
    position: relative; 
    padding-left: 2.5em; 
    margin-bottom: 1rem; 
    line-height: 1.7; 
}

/* Malzemeler Bölümü (değişiklik yok) */
.ingredients-section li::before { content: '\f058'; font-family: 'Font Awesome 6 Free'; font-weight: 900; position: absolute; left: 0; top: 5px; color: var(--secondary-color); font-size: 1.2em; }

/* Hazırlanış Bölümü (GÜNCELLENDİ) */
.instructions-section ol { 
    counter-reset: step-counter; 
}
.instructions-section li { 
    counter-increment: step-counter; /* Her madde sayacı artırır */
}
.instructions-section li::before { 
    content: counter(step-counter); 
    position: absolute; 
    left: 0; 
    top: 0; 
    font-weight: 700; 
    color: var(--white-color); 
    background-color: var(--primary-color); 
    font-size: 0.9em; 
    width: 2em; 
    height: 2em; 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    box-shadow: 0 2px 4px rgba(0,0,0,0.15); 
}

/* YENİ EKLENEN ALT BAŞLIK STİLİ */
.instruction-subheading {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--dark-gray);
    margin-top: 2rem; /* Üstündeki adımdan biraz daha fazla boşluk bırakır */
    margin-bottom: 1rem;
    padding-left: 0;
}
/* --- ANASAYFA GÖVDE VE KENAR ÇUBUĞU (SIDEBAR) --- */
.anasayfa-govde {
    display: flex;
    flex-wrap: wrap;
    gap: 2.5rem; /* Sütunlar arası boşluk */
    margin-top: 3rem;
    align-items: flex-start; /* Sütunların üstten hizalanmasını sağlar */
}

.anasayfa-tarifler {
    flex: 3; /* Geniş sütun */
    min-width: 300px;
}

.anasayfa-sidebar {
    flex: 1; /* Dar sütun */
    min-width: 280px;
    
    /* DÜZELTME: Yapışkanlığı bu ana kapsayıcıya taşıdık */
    position: sticky;
    top: 100px; /* Header ve yapışkan panelden sonraki boşluk */
    
    display: flex;
    flex-direction: column;
    gap: 2rem; /* Widget'lar arasına boşluk koyar */
}

.sidebar-widget {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    /* DÜZELTME: Her bir widget'tan yapışkanlığı kaldırdık */
}
    
    /* YENİ: Yapışkanlığı bu ana kapsayıcıya taşıdık */
    position: sticky;
    top: 150px; /* Header ve yapışkan panelden sonraki boşluk */
}

.sidebar-widget {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    margin-bottom: 2rem; /* Widget'lar arasına boşluk koyar */
}
.sidebar-widget:last-child {
    margin-bottom: 0;
}

.widget-title { font-size: 1.5rem; color: var(--primary-color); margin-top: 0; margin-bottom: 1.5rem; text-align: center; border-bottom: 2px solid var(--secondary-color); padding-bottom: 0.5rem; }
.widget-article-list { display: flex; flex-direction: column; gap: 1rem; }
.widget-article-item { display: flex; align-items: center; gap: 1rem; text-decoration: none; color: inherit; padding-bottom: 1rem; border-bottom: 1px solid var(--light-gray); }
.widget-article-item:last-child { border-bottom: none; }
.widget-article-img { width: 80px; height: 60px; object-fit: cover; border-radius: 5px; flex-shrink: 0; }
.widget-article-content h4 { font-size: 0.95rem; font-weight: 600; margin: 0 0 0.3rem 0; line-height: 1.4; transition: color 0.3s; }
.widget-article-content span { font-size: 0.8rem; color: #777; display: flex; align-items: center; gap: 0.4rem; }
.widget-article-item:hover h4 { color: var(--primary-color); }

.swiper-slide { height: auto; align-self: stretch; }
.swiper-slide .recipe-card { height: 100%; }
.swiper-button-next, .swiper-button-prev { color: var(--primary-color); top: 50%; transform: translateY(-70%); }
.swiper-pagination-bullet-active { background-color: var(--primary-color); }

/* --- 5. ETKİLEŞİM BİLEŞENLERİ --- */
.quick-favorite-btn { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; background-color: rgba(0, 0, 0, 0.5); color: white; border: none; border-radius: 50%; font-size: 1rem; display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 5; transition: all 0.3s ease; }
.quick-favorite-btn:hover { background-color: rgba(0, 0, 0, 0.8); transform: scale(1.1); }
.quick-favorite-btn.favorited { background-color: var(--secondary-color); color: var(--primary-color); }
.quick-favorite-btn.favorited i.fa-bookmark::before { content: '\f02e'; font-weight: 900; }
.favorite-action { text-align: center; margin-bottom: 2rem; }
.favorite-btn { display: inline-flex; align-items: center; gap: 0.75rem; background-color: transparent; color: var(--primary-color); border: 2px solid var(--primary-color); padding: 10px 25px; border-radius: 30px; font-weight: 600; font-size: 1rem; cursor: pointer; transition: all 0.3s ease; }
.favorite-btn:hover { background-color: var(--primary-color); color: var(--white-color); }
.favorite-btn.favorited { background-color: var(--primary-color); color: var(--white-color); }
.favorite-btn.favorited:hover { background-color: #610101; border-color: #610101; }
.login-prompt-for-favorite, .login-prompt-for-comment { font-weight: 500; background-color: var(--light-gray); padding: 1rem; border-radius: 8px; text-align: center; }
.login-prompt-for-favorite a, .login-prompt-for-comment a { color: var(--primary-color); font-weight: 700; text-decoration: underline; }
.rating-summary-box { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; margin-bottom: 1.5rem; }
.stars-display { position: relative; font-size: 2rem; color: #d3d3d3; }
.stars-display::before { content: '★★★★★'; }
.stars-display-inner { position: absolute; top: 0; left: 0; white-space: nowrap; overflow: hidden; height: 100%; }
.stars-display-inner::before { content: '★★★★★'; color: #f39c12; }
.rating-text { font-size: 1rem; color: #555; }
.rating-text strong { font-size: 1.2rem; color: #000; }
.rating-form-container { padding: 1.5rem 0; text-align: center; border-top: 1px solid var(--light-gray); border-bottom: 1px solid var(--light-gray); margin-top: 1.5rem; }
.rating-form-stars { border: none; padding: 0; margin: 0 auto; display: inline-flex; flex-direction: row-reverse; justify-content: center; }
.rating-form-stars legend { width: 100%; font-weight: 600; margin-bottom: 0.5rem; text-align: center; font-size: 1.1rem; }
.rating-form-stars input[type="radio"] { display: none; }
.rating-form-stars label { font-size: 2.5rem; color: #e0e0e0; cursor: pointer; transition: color 0.2s ease-in-out; padding: 0 0.1em; }
.rating-form-stars label:hover, .rating-form-stars label:hover ~ label { color: var(--secondary-color); }
.rating-form-stars input[type="radio"]:checked ~ label { color: var(--secondary-color); }
#rating-message { margin-top: 1rem; font-weight: bold; color: var(--primary-color); min-height: 1.2em; }
.comments-section { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--light-gray); }
.comments-section h2 { color: var(--primary-color); margin-bottom: 2rem; text-align: center; }
.comment-form-container { background-color: #f9f9f9; padding: 2rem; border-radius: 8px; margin-bottom: 2rem; }
.comment-form-container h4 { margin-top: 0; margin-bottom: 1rem; font-size: 1.2rem; }
.comment-form textarea { width: 100%; padding: 10px; border: 1px solid #ddd; border-radius: 5px; font-size: 1rem; min-height: 100px; margin-bottom: 1rem; }
.comment-form button { background-color: var(--primary-color); color: white; border: none; padding: 10px 25px; border-radius: 20px; font-weight: 600; cursor: pointer; transition: background-color 0.3s; }
.comment-form button:hover { background-color: #610101; }
.comment-list { display: flex; flex-direction: column; gap: 1.5rem; }
.comment-item { padding: 1.5rem; border: 1px solid #e7e7e7; border-left: 5px solid var(--secondary-color); border-radius: 5px; }
.comment-header { position: relative; display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; border-bottom: 1px dashed #ddd; padding-bottom: 0.5rem; }
.comment-author { font-weight: 700; color: var(--primary-color); }
.comment-actions { position: absolute; top: 0.5rem; right: 0.5rem; }
.comment-options-btn { background: none; border: none; cursor: pointer; color: #aaa; padding: 5px; border-radius: 50%; }
.comment-options-btn:hover { background-color: #f0f0f0; color: #333; }
.comment-options-dropdown { display: none; position: absolute; right: 0; top: 100%; background-color: white; border: 1px solid #ddd; border-radius: 5px; box-shadow: 0 2px 5px rgba(0,0,0,0.1); z-index: 10; overflow: hidden; min-width: 100px; }
.comment-options-dropdown.active { display: block; }
.comment-options-dropdown a { display: block; padding: 8px 12px; color: #333; font-size: 0.9rem; }
.comment-options-dropdown a:hover { background-color: #f4f4f4; }
.comment-options-dropdown .delete-comment-link { color: #dc3545; }
.comment-body { margin-top: 1rem; }
.comment-body p { margin: 0; line-height: 1.7; }
.comment-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 1rem; }
.comment-date { font-size: 0.8rem; color: #888; }
.edited-indicator { font-size: 0.8em; font-style: italic; color: #888; }
.edit-comment-form textarea { width: 100%; min-height: 80px; padding: 10px; border: 1px solid #ccc; border-radius: 4px; margin-bottom: 10px; font-family: inherit; }
.edit-actions { display: flex; justify-content: flex-end; gap: 10px; }
.edit-actions button { padding: 8px 16px; border-radius: 5px; border: 1px solid #ddd; cursor: pointer; }
.edit-actions button[type="submit"] { background-color: var(--primary-color); color: white; border-color: var(--primary-color); }

/* --- 6. MODAL PENCERE --- */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.6); display: flex; justify-content: center; align-items: center; z-index: 2000; opacity: 0; visibility: hidden; transition: all 0.3s ease; }
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal-content { background-color: var(--white-color); padding: 2rem 2.5rem; border-radius: 8px; box-shadow: 0 5px 20px rgba(0,0,0,0.3); position: relative; width: 100%; max-width: 400px; text-align: center; transform: translateY(-20px); transition: transform 0.3s ease; }
.modal-overlay.open .modal-content { transform: translateY(0); }
.modal-close-btn { position: absolute; top: 10px; right: 15px; font-size: 2rem; color: #aaa; background: none; border: none; line-height: 1; }
.modal-close-btn:hover { color: #333; }
.modal-content h2 { color: var(--primary-color); margin-bottom: 0.5rem; }
.modal-content p { margin-bottom: 1.5rem; color: #666; }
.modal-form { display: flex; flex-direction: column; gap: 1rem; }
.modal-form input { padding: 12px; border: 1px solid #ddd; border-radius: 5px; font-size: 1rem; }
.modal-form button { padding: 12px; background-color: var(--primary-color); color: var(--white-color); border: none; border-radius: 5px; font-size: 1rem; font-weight: 600; transition: background-color 0.3s; }
.modal-form button:hover { background-color: #610101; }
.modal-switch { margin-top: 1.5rem; font-size: 0.9rem; }
.modal-switch a { color: var(--primary-color); font-weight: 600; }
.form-consent { display: flex; align-items: flex-start; text-align: left; gap: 10px; font-size: 0.85rem; margin: 0.5rem 0; padding: 8px; border: 2px solid transparent; border-radius: 5px; transition: all 0.3s ease-in-out; }
.form-consent input[type="checkbox"] { margin-top: 3px; }
.form-consent a { text-decoration: underline; }
.form-consent.warning { border-color: #dc3545; background-color: #f8d7da; }

/* --- 7. MOBİL UYUMLULUK --- */
@media (min-width: 769px) {
    .category-nav { display: block !important; }
    .category-nav ul { display: flex; justify-content: center; align-items: center; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
    .category-nav li a { display: block; padding: 0.75rem 1.25rem; margin: 0.25rem; font-weight: 600; color: var(--dark-gray); transition: color 0.2s, background-color 0.2s; border-radius: 20px; font-size: 0.9rem; }
    .category-nav li a:hover { color: var(--primary-color); background-color: #e9e9e9; }
}
@media (max-width: 992px) {
    .anasayfa-govde { flex-direction: column; }
    .anasayfa-sidebar { position: static; top: auto; }
}
@media (max-width: 768px) {
    .header-actions .welcome-user, .header-actions .logout-btn, .header-actions .register-btn, .header-actions .login-btn { display: none; }
    .recipe-book-btn-text { display: none; }
    .recipe-book-btn { display: inline-flex; background: transparent; border: none; padding: 0.5rem; font-size: 1.4rem; color: var(--secondary-color); }
    .recipe-book-btn:hover { background: transparent; color: var(--white-color); }
    .header-container { justify-content: space-between; }
    .logo-mobile { display: block; height: 98px; width: auto; }
    .logo-desktop, .logo-text { display: none; }
    .category-nav { display: none !important; }
    .section-title, .page-title { font-size: 2rem; }
    .hero-content h1 { font-size: 1.8rem; }
    .hero-content p { font-size: 1rem; }
    .recipe-content-grid { grid-template-columns: 1fr; }
}

/* --- KULLANICI TARİF GÖNDERME FORMU --- */
.user-form { max-width: 800px; margin: 0 auto; background-color: #fff; padding: 2.5rem; border-radius: 8px; box-shadow: 0 5px 25px rgba(0,0,0,0.1); border: 1px solid #eee; }
.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; font-weight: 600; margin-bottom: 0.5rem; color: #444; }
.form-group input[type="text"], .form-group input[type="file"], .form-group textarea, .form-group select, .form-group input[type="number"] { width: 100%; padding: 12px; border: 1px solid #ccc; border-radius: 5px; font-size: 1rem; font-family: inherit; transition: border-color 0.2s, box-shadow 0.2s; }
.form-group input:focus, .form-group textarea:focus, .form-group select:focus { outline: none; border-color: var(--primary-color); box-shadow: 0 0 0 2px rgba(139, 0, 0, 0.1); }
.form-group textarea { resize: vertical; min-height: 120px; }
.btn-submit-recipe { display: block; width: 100%; padding: 1rem; font-size: 1.2rem; font-weight: 700; color: var(--white-color); background-color: var(--primary-color); border: none; border-radius: 5px; cursor: pointer; transition: background-color 0.3s; }
.btn-submit-recipe:hover { background-color: #610101; }

/* --- SIDEBAR WIDGET FORM STİLLERİ --- */
.widget-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.form-group-widget {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.form-group-widget label {
    font-weight: 600;
    font-size: 0.9rem;
    color: #555;
}
.form-group-widget input,
.form-group-widget select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
    font-size: 1rem;
}
.widget-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-top: 0.5rem;
}
.widget-btn:hover {
    background-color: #610101;
}
.widget-result {
    margin-top: 1rem;
    padding: 1rem;
    background-color: var(--light-gray);
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    min-height: 1.5em;
    line-height: 1.5;
}
.widget-result span {
    display: block;
    font-size: 1.5rem;
    color: var(--primary-color);
}
.fa-spinner.fa-spin {
    animation: fa-spin 1s infinite linear;
}
@keyframes fa-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
.fa-spinner.fa-spin {
    animation: fa-spin 1s infinite linear;
}
@keyframes fa-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.favorite-btn.favorited {
    background-color: var(--primary-color);
    color: var(--white-color);
}

.favorite-btn.favorited:hover {
    background-color: #610101;
    border-color: #610101;
}

.favorite-btn.favorited {
    background-color: #c0392b; /* koyu kırmızı */
    color: #fff;
}

/* --- KULLANICI PROFİL SAYFASI --- */
.profile-page {
    margin-top: 2rem;
}
.profile-header {
    background-color: var(--dark-gray);
    color: white;
    padding: 2rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    text-align: center;
}
.profile-info h1 {
    color: var(--secondary-color);
    margin: 0;
}
.profile-join-date {
    color: #ccc;
    font-size: 0.9rem;
}
.profile-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2.5rem;
    align-items: flex-start;
}
.profile-sidebar {
    flex: 1;
    min-width: 280px;
    position: sticky;
    top: 100px;
}
.profile-sidebar textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
    font-size: 0.9rem;
    min-height: 120px;
    margin-bottom: 1rem;
    resize: vertical;
}
.profile-main {
    flex: 3;
    min-width: 300px;
}
.profile-tabs {
    display: flex;
    border-bottom: 1px solid #ddd;
    margin-bottom: 2rem;
}
.tab-link {
    padding: 1rem 1.5rem;
    font-weight: 600;
    color: #777;
    border-bottom: 3px solid transparent;
    margin-bottom: -1px;
}
.tab-link:hover {
    color: #000;
}
.tab-link.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

/* --- HEADER PROFİL İKONU STİLLERİ --- */

/* Tüm header butonlarının dikeyde tam hizalı olmasını sağla */
.header-actions .header-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Profil ikon butonunun özel stilleri */
.header-btn.profile-btn {
    padding: 8px; /* İç boşluğu ayarla */
    width: 40px;  /* Genişliği sabitle */
    height: 40px; /* Yüksekliği sabitle */
    border-radius: 50%; /* Tam yuvarlak yap */
    font-size: 1.4rem; /* İkonu büyüt */
}

/* Mobilde "Tarif Defterim" ve "Profil" ikonlarının yan yana durmasını sağla */
@media (max-width: 768px) {
    .header-actions .recipe-book-btn,
    .header-actions .profile-btn {
        display: inline-flex; /* Mobilde de görünür yap */
    }

    .header-actions .profile-btn {
        background: transparent;
        border: none;
        font-size: 1.6rem;
        color: var(--secondary-color);
    }
    .header-actions .profile-btn:hover {
        background: transparent;
        color: var(--white-color);
    }
}
.recipe-author a, .recipe-meta-bar-detail a {
    text-decoration: none;
    color: inherit;
    font-weight: inherit;
}
.recipe-author a:hover, .recipe-meta-bar-detail a:hover {
    text-decoration: underline;
    color: var(--primary-color);
}

/* --- ARAMA SONUÇLARI SAYFASI (YENİ KART TASARIMI) --- */
.search-results-grid {
    display: grid;
    /* Ekrana sığdığı kadar kartı yan yana dizer, her biri en az 200px olur */
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

.search-result-card {
    background-color: var(--white-color);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
    text-decoration: none;
    color: var(--text-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.search-result-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.12);
}

.search-result-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.search-result-content {
    padding: 1rem;
}

.search-result-content h3 {
    font-size: 1.1rem;
    margin: 0 0 0.5rem 0;
    color: var(--primary-color);
}

.search-result-content p {
    font-size: 0.8rem;
    color: #777;
    margin: 0;
}
/* --- BLOG SAYFALARI STİLLERİ --- */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.article-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}
.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.article-card-image-link {
    display: block;
    height: 200px;
}
.article-card-image-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.article-meta {
    display: flex;
    gap: 1.5rem;
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 0.75rem;
}
.article-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.article-card h3 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
}
.article-card h3 a {
    text-decoration: none;
    color: var(--dark-gray);
}
.article-card h3 a:hover {
    color: var(--primary-color);
}

.article-card p {
    flex-grow: 1;
    margin-bottom: 1.5rem;
    color: #666;
}

/* Tekil Yazı Sayfası Stilleri */
.article-full {
    max-width: 800px;
    margin: 0 auto;
}

.article-full h1 {
    font-size: 2.8rem;
    text-align: center;
    line-height: 1.3;
}

.article-full-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    color: #777;
    margin: 1rem 0 2rem 0;
    font-size: 0.9rem;
}
.article-full-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.article-full-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 2.5rem;
}

/* --- BLOG YAZISI İÇİNDEKİ ALT BAŞLIKLAR --- */
.text-content h2 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-top: 2.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--secondary-color);
}

/* --- BLOG YAZISI İÇİNDEKİ ALT BAŞLIKLAR (H3) --- */
.text-content h3 {
    font-size: 1.4rem;
    color: var(--dark-gray);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

/* --- SOSYAL MEDYA PAYLAŞIM BUTONLARI --- */
.social-share-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--light-gray);
    text-align: center;
}
.social-share-section h3 {
    font-size: 1.2rem;
    color: var(--dark-gray);
    margin-bottom: 1.5rem;
    font-weight: 600;
}
.social-share-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
}
.share-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    text-decoration: none;
    transition: transform 0.3s, opacity 0.3s;
}
.share-btn:hover {
    transform: translateY(-4px);
    opacity: 0.9;
}
.share-btn.facebook { background-color: #1877F2; }
.share-btn.twitter { background-color: #1DA1F2; }
.share-btn.whatsapp { background-color: #25D366; }
.share-btn.email { background-color: #7f8c8d; }
/* YENİ EKLENEN MALZEME ALT BAŞLIK STİLİ */
.ingredient-subheading {
    list-style: none; /* Madde işaretini kaldırır */
    padding-left: 0 !important; /* Sol boşluğu sıfırlar */
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dark-gray);
    margin-top: 1.5rem; /* Üstündeki maddeden biraz daha fazla boşluk bırakır */
}
.ingredient-subheading::before {
    content: none !important; /* Madde ikonunu tamamen kaldırır */
}
.ingredient-subheading:first-child {
    margin-top: 0; /* Eğer listenin ilk elemanıysa üst boşluğu kaldır */
}