/*
Theme Name: Haber Teması
Theme URI: https://turkiyerehber.com
Description: Modern, SEO uyumlu ve performans odaklı WordPress haber teması. Responsive tasarım, hızlı yükleme ve güvenlik özellikleri ile donatılmıştır.
Author: Türkiye Rehber
Author URI: https://turkiyerehber.com
Version: 1.0.0
Requires at least: 5.8
Tested up to: 6.4
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: haber
Tags: news, blog, responsive, seo-optimized, performance, modern, Turkish
*/

/* ===================================
   Reset & Base Styles
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #e74c3c;
    --secondary-color: #2c3e50;
    --text-color: #333;
    --light-bg: #f8f9fa;
    --white: #ffffff;
    --border-color: #dee2e6;
    --hover-color: #c0392b;
    --font-main: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

body {
    font-family: var(--font-main);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--light-bg);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

/* ===================================
   Typography
   =================================== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
}

/* ===================================
   Container & Layout
   =================================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-content {
    flex: 1;
    padding: 40px 0;
}

/* ===================================
   Centered Header Styles (Tasarım 3)
   =================================== */
.site-header {
    background: var(--white);
    box-shadow: 0 3px 20px rgba(0,0,0,0.06);
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* Üst Bar */
.header-top-bar {
    background: linear-gradient(135deg, var(--primary-color), #c0392b);
    color: var(--white);
    padding: 10px 0;
    font-size: 0.85rem;
}

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

.header-date {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.header-social-top {
    display: flex;
    gap: 15px;
}

.header-social-top a {
    color: var(--white);
    font-size: 1rem;
    transition: all 0.3s ease;
    opacity: 0.9;
}

.header-social-top a:hover {
    opacity: 1;
    transform: translateY(-2px);
}

/* Logo Section (Ortada) */
.header-logo-section {
    padding: 30px 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.site-branding {
    display: inline-block;
}

.site-branding .custom-logo-link {
    display: inline-block;
    line-height: 0;
}

.site-branding .custom-logo {
    max-width: 300px;
    max-height: 80px;
    width: auto;
    height: auto;
    display: block;
    margin: 0 auto;
}

.site-branding .site-title {
    margin: 0 0 10px;
    font-size: 3rem;
    font-weight: 900;
    line-height: 1;
}

.site-branding .site-title a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.site-branding .site-title a:hover {
    color: var(--secondary-color);
}

.site-description {
    color: #666;
    font-size: 1rem;
    font-style: italic;
    margin: 0;
}

/* Navigation Section (Ortada) */
.header-nav-section {
    background: var(--secondary-color);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.main-navigation {
    display: flex;
    justify-content: center;
}

.main-navigation ul {
    list-style: none;
    display: flex;
    gap: 0;
    margin: 0;
    padding: 0;
}

.main-navigation li {
    position: relative;
}

.main-navigation a {
    color: var(--white);
    font-weight: 600;
    font-size: 0.9rem;
    padding: 18px 25px;
    display: flex;
    align-items: center;
    gap: 6px;
    position: relative;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.main-navigation a:hover,
.main-navigation a.current {
    background: var(--primary-color);
}

.main-navigation a i {
    font-size: 0.85rem;
}

/* Arama Dropdown */
.search-menu-item {
    position: relative;
}

.search-toggle {
    cursor: pointer;
}

.header-search-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    padding: 15px;
    min-width: 300px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 100;
}

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

.header-search-dropdown form {
    display: flex;
    gap: 10px;
}

.header-search-dropdown input[type="search"] {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.95rem;
    transition: border-color 0.3s ease;
}

.header-search-dropdown input[type="search"]:focus {
    outline: none;
    border-color: var(--primary-color);
}

.header-search-dropdown button {
    background: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 12px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s ease;
}

.header-search-dropdown button:hover {
    background: #c0392b;
}

/* ===================================
   News Grid
   =================================== */
.news-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

.news-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.news-thumbnail {
    position: relative;
    padding-top: 65%;
    overflow: hidden;
    background: var(--light-bg);
}

.news-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.news-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--primary-color);
    color: var(--white);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.news-content {
    padding: 20px;
}

.news-title {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.news-title a {
    color: var(--secondary-color);
}

.news-title a:hover {
    color: var(--primary-color);
}

.news-meta {
    display: flex;
    gap: 15px;
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 10px;
}

.news-excerpt {
    color: #555;
    line-height: 1.6;
}

/* ===================================
   Sidebar
   =================================== */
.sidebar {
    background: var(--white);
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
}

.widget {
    margin-bottom: 30px;
}

.widget:last-child {
    margin-bottom: 0;
}

.widget-title {
    font-size: 1.3rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary-color);
}

.widget ul {
    list-style: none;
}

.widget ul li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.widget ul li:last-child {
    border-bottom: none;
}

/* ===================================
   Footer
   =================================== */
.site-footer {
    background: var(--secondary-color);
    color: var(--white);
    padding: 40px 0 20px;
    margin-top: 60px;
}

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

.footer-widget h3 {
    color: var(--white);
    margin-bottom: 15px;
}

.footer-widget ul {
    list-style: none;
}

.footer-widget ul li {
    margin-bottom: 8px;
}

.footer-widget a {
    color: rgba(255,255,255,0.8);
}

.footer-widget a:hover {
    color: var(--white);
}

.site-info {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.9rem;
}

/* Mobil Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: var(--primary-color);
    border: none;
    cursor: pointer;
    padding: 12px 15px;
    border-radius: 6px;
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1001;
}

.menu-icon {
    width: 25px;
    height: 3px;
    background: var(--white);
    transition: all 0.3s ease;
    border-radius: 3px;
}

/* ===================================
   Responsive Design
   =================================== */
@media (max-width: 992px) {
    /* Haber Grid - 2 Sütun (Değişmeden Kalıyor) */
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
    
    /* Header Navigation */
    .main-navigation ul {
        gap: 0;
    }
    
    .main-navigation a {
        padding: 16px 20px;
        font-size: 0.85rem;
    }
    
    /* Logo */
    .site-branding .custom-logo {
        max-width: 250px;
        max-height: 70px;
    }
    
    .site-branding .site-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }
    
    .header-nav-section {
        position: relative;
    }
    
    .main-navigation {
        position: fixed;
        top: 0;
        left: -100%;
        width: 280px;
        height: 100vh;
        background: var(--secondary-color);
        box-shadow: 3px 0 25px rgba(0,0,0,0.2);
        transition: left 0.3s ease;
        padding-top: 80px;
        z-index: 999;
        overflow-y: auto;
    }
    
    .main-navigation.active {
        left: 0;
    }
    
    .main-navigation ul {
        flex-direction: column;
    }
    
    .main-navigation a {
        padding: 18px 25px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .header-search-dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        margin: 10px 15px;
        min-width: auto;
    }
    
    .site-branding .custom-logo {
        max-width: 200px;
        max-height: 60px;
    }
    
    .site-branding .site-title {
        font-size: 2rem;
    }
    
    .header-logo-section {
        padding: 20px 0;
    }
    
    .header-social-top {
        gap: 10px;
    }
    
    .header-social-top a {
        font-size: 0.9rem;
    }
    
    .header-date {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .site-branding .site-title {
        font-size: 1.6rem;
    }
    
    .top-bar-content {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
}

/* ===================================
   Utility Classes
   =================================== */
.text-center { text-align: center; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

