/* =============================================
   Sanaldevriye - Ana Stil Dosyası
   Dark mode, modern tasarım
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* -------- Değişkenler -------- */
:root {
    --bg-primary:    #0a0e1a;
    --bg-secondary:  #0f1629;
    --bg-card:       #131c30;
    --bg-card-hover: #1a2540;
    --border:        rgba(59, 130, 246, 0.15);
    --border-hover:  rgba(59, 130, 246, 0.4);

    --blue:     #3b82f6;
    --blue-dark:#1d4ed8;
    --cyan:     #06b6d4;
    --purple:   #8b5cf6;
    --red:      #ef4444;
    --orange:   #f97316;
    --green:    #10b981;
    --yellow:   #f59e0b;

    --text-primary:   #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted:     #64748b;

    --radius:    12px;
    --radius-sm: 8px;
    --shadow:    0 4px 24px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.6);
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* -------- Reset & Base -------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

a { color: var(--blue); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--cyan); }
img { max-width: 100%; height: auto; }
input, textarea, select, button { font-family: inherit; }

/* -------- Animated Background -------- */
body::before {
    content: '';
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(59, 130, 246, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(139, 92, 246, 0.06) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.container { max-width: 1280px; margin: 0 auto; padding: 0 20px; position: relative; z-index: 1; }

/* -------- Navbar -------- */
.navbar {
    background: rgba(10, 14, 26, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 0;
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    max-width: 1280px;
    margin: 0 auto;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.navbar-logo {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--blue), var(--purple));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.4);
}

.navbar-title {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, #fff, var(--cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.navbar-subtitle {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 400;
    letter-spacing: 2px;
    text-transform: uppercase;
    -webkit-text-fill-color: var(--text-muted);
}

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

.navbar-nav a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--transition);
}

.navbar-nav a:hover, .navbar-nav a.active {
    color: var(--text-primary);
    background: rgba(59, 130, 246, 0.12);
}

.navbar-ticker {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 20px;
    padding: 5px 14px;
    font-size: 12px;
    color: var(--red);
    font-weight: 600;
}

.ticker-dot {
    width: 7px;
    height: 7px;
    background: var(--red);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

/* -------- Hero / Breaking News -------- */
.breaking-bar {
    background: linear-gradient(90deg, var(--red) 0%, #dc2626 100%);
    padding: 10px 0;
    overflow: hidden;
}

.breaking-inner {
    display: flex;
    align-items: center;
    gap: 16px;
}

.breaking-label {
    background: rgba(0,0,0,0.3);
    padding: 3px 12px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    white-space: nowrap;
    flex-shrink: 0;
}

.breaking-text {
    white-space: nowrap;
    font-size: 13px;
    font-weight: 500;
    animation: marquee 30s linear infinite;
}

@keyframes marquee {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* -------- Hero Section -------- */
.hero {
    padding: 40px 0 30px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 24px;
}

/* Büyük öne çıkan haber */
.hero-main {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    min-height: 480px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    cursor: pointer;
    display: block;
    color: var(--text-primary);
    text-decoration: none;
}

.hero-main:hover { border-color: var(--border-hover); }

.hero-main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    inset: 0;
    opacity: 0.5;
    transition: transform 0.5s ease, opacity var(--transition);
}

.hero-main:hover .hero-main-img { transform: scale(1.03); opacity: 0.6; }

.hero-main-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10,14,26,0.98) 40%, rgba(10,14,26,0.3) 100%);
}

.hero-main-content {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 28px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    width: fit-content;
}

.badge-red    { background: rgba(239,68,68,0.2);  color: #fca5a5; border: 1px solid rgba(239,68,68,0.3); }
.badge-blue   { background: rgba(59,130,246,0.2); color: #93c5fd; border: 1px solid rgba(59,130,246,0.3); }
.badge-green  { background: rgba(16,185,129,0.2); color: #6ee7b7; border: 1px solid rgba(16,185,129,0.3); }
.badge-purple { background: rgba(139,92,246,0.2); color: #c4b5fd; border: 1px solid rgba(139,92,246,0.3); }
.badge-cyan   { background: rgba(6,182,212,0.2);  color: #67e8f9; border: 1px solid rgba(6,182,212,0.3); }
.badge-yellow { background: rgba(245,158,11,0.2); color: #fcd34d; border: 1px solid rgba(245,158,11,0.3); }

.hero-main-title {
    font-size: clamp(22px, 2.5vw, 32px);
    font-weight: 800;
    line-height: 1.3;
    margin: 10px 0 12px;
    letter-spacing: -0.5px;
}

.hero-main-summary {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Yan haberler */
.hero-sidebar {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hero-side-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    display: flex;
    gap: 14px;
    transition: all var(--transition);
    cursor: pointer;
    text-decoration: none;
    color: var(--text-primary);
}

.hero-side-card:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateX(4px);
}

.hero-side-img {
    width: 90px;
    height: 70px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    flex-shrink: 0;
    background: var(--bg-secondary);
}

.hero-side-title {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--text-primary);
}

.hero-side-meta {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* -------- Kategori Bar -------- */
.category-bar {
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
    margin-bottom: 32px;
}

.category-tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.category-tabs::-webkit-scrollbar { display: none; }

.cat-tab {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 18px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
    border: 1px solid transparent;
    background: var(--bg-card);
    color: var(--text-secondary);
    text-decoration: none;
}

.cat-tab:hover, .cat-tab.active {
    color: var(--text-primary);
    background: rgba(59, 130, 246, 0.15);
    border-color: var(--border-hover);
}

/* -------- Haber Kartları -------- */
.news-section { padding: 0 0 60px; }

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.section-title {
    font-size: 20px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: -0.3px;
}

.section-title::before {
    content: '';
    width: 4px;
    height: 24px;
    background: linear-gradient(180deg, var(--blue), var(--purple));
    border-radius: 2px;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.news-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: all var(--transition);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: var(--text-primary);
}

.news-card:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.news-card-img-wrap {
    height: 200px;
    overflow: hidden;
    position: relative;
    background: var(--bg-secondary);
}

.news-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.news-card-no-img {
    height: 200px;
    background: linear-gradient(135deg, var(--bg-secondary), var(--bg-card));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    opacity: 0.3;
}

.news-card-source-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(4px);
    border-radius: 6px;
    padding: 3px 8px;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
}

.news-card-body {
    padding: 18px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.news-card-title {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.5;
    margin: 8px 0 10px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--text-primary);
}

.news-card-summary {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}

.news-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
    font-size: 11px;
    color: var(--text-muted);
}

.news-source-icon {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    object-fit: contain;
}

/* -------- Twitter/Sosyal Medya Kartı -------- */
.news-card.type-twitter .news-card-img-wrap { display: none; }
.news-card.type-twitter { background: linear-gradient(135deg, #0f1629, #061025); }
.news-card.type-twitter:hover { border-color: rgba(29, 161, 242, 0.4); }

.news-card.type-instagram .news-card-img-wrap { display: none; }
.news-card.type-instagram { background: linear-gradient(135deg, #1a0a2e, #0f1020); }
.news-card.type-instagram:hover { border-color: rgba(193, 53, 132, 0.4); }

.tweet-content { font-size: 15px; line-height: 1.6; color: var(--text-primary); margin: 8px 0 12px; }
.tweet-author { font-size: 13px; color: #1d9bf0; font-weight: 600; }

/* -------- Sosyal Medya Bölümü -------- */
.social-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 40px;
}

.social-column-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    font-size: 16px;
    font-weight: 700;
}

/* -------- İstatistik Bar -------- */
.stats-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px 10px;
    text-align: center;
    transition: all var(--transition);
}

.stat-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
}

.stat-number {
    font-size: 22px;
    font-weight: 900;
    background: linear-gradient(135deg, var(--blue), var(--cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.stat-label {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
}

/* -------- Sayfalama -------- */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 40px 0;
}

.page-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
}

.page-btn:hover, .page-btn.active {
    background: var(--blue);
    border-color: var(--blue);
    color: white;
}

/* -------- Footer -------- */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    padding: 40px 0 24px;
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 32px;
}

.footer-brand h3 {
    font-size: 20px;
    font-weight: 800;
    background: linear-gradient(135deg, #fff, var(--cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
}

.footer-brand p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.7;
}

.footer-links h4 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--text-secondary); margin-bottom: 14px; }
.footer-links a { display: block; font-size: 14px; color: var(--text-muted); padding: 4px 0; transition: color var(--transition); }
.footer-links a:hover { color: var(--text-primary); }

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
}

/* -------- Arama -------- */
.search-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 30px;
    padding: 8px 16px;
    transition: border-color var(--transition);
}

.search-bar:focus-within { border-color: var(--border-hover); }

.search-bar input {
    background: none;
    border: none;
    outline: none;
    color: var(--text-primary);
    font-size: 14px;
    width: 200px;
}

.search-bar input::placeholder { color: var(--text-muted); }

.search-bar button {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0;
    display: flex;
    transition: color var(--transition);
}

.search-bar button:hover { color: var(--blue); }

/* -------- Animasyonlar -------- */
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.6; transform: scale(0.85); }
}

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

.animate-in { animation: fadeInUp 0.5s ease forwards; }

/* -------- Responsive -------- */
@media (max-width: 1024px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-sidebar { display: grid; grid-template-columns: 1fr 1fr; }
    .stats-bar { grid-template-columns: repeat(2, 1fr); }
    .social-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
    .navbar-nav { display: none; }
    .hero-sidebar { grid-template-columns: 1fr; }
    .news-grid { grid-template-columns: 1fr; }
    .stats-bar { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr; }
    .footer-bottom { flex-direction: column; gap: 10px; text-align: center; }
    .search-bar { display: none; }
}

/* -------- Yüklenme İndikatörü -------- */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s, visibility 0.5s;
}

.loading-overlay.hidden { opacity: 0; visibility: hidden; }

.loader {
    width: 48px;
    height: 48px;
    border: 3px solid rgba(59,130,246,0.2);
    border-top-color: var(--blue);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* -------- Toast Bildirimleri -------- */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9998;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    font-size: 14px;
    box-shadow: var(--shadow);
    animation: slideIn 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 280px;
}

.toast.success { border-color: rgba(16,185,129,0.4); }
.toast.error   { border-color: rgba(239,68,68,0.4); }

@keyframes slideIn {
    from { transform: translateX(100px); opacity: 0; }
    to   { transform: translateX(0); opacity: 1; }
}

/* -------- Relevance Score Göstergesi -------- */
.relevance-bar {
    height: 3px;
    background: var(--bg-secondary);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 8px;
}

.relevance-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--blue), var(--cyan));
    border-radius: 2px;
    transition: width 0.5s ease;
}
