/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@300;500;600;700&family=Inter:wght@300;400;500;600&display=swap');

/* --- TEMEL AYARLAR --- */
:root {
    --primary-color: #7c3aed; /* Derin Mor */
    --secondary-color: #2563eb; /* Parlak Mavi */
    --glass-bg: rgba(5, 5, 10, 0.7); /* Daha koyu cam */
    --glass-border: rgba(255, 255, 255, 0.06);
    --glass-highlight: rgba(255, 255, 255, 0.03);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #000000;
    color: #e2e8f0;
    overflow-x: hidden;
    margin: 0;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .brand-font {
    font-family: 'Rajdhani', sans-serif;
    letter-spacing: 0.05em;
}

/* --- YILDIZ ARKA PLAN (KOYU & DERİN) --- */
#galaxy-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -999; 
    pointer-events: none;
    overflow: hidden;
    /* Daha derin, neredeyse tam siyah bir uzay */
    background: radial-gradient(circle at 50% 100%, #1a1a2e 0%, #000000 70%);
    will-change: transform;
}

.star {
    position: absolute;
    background: white;
    border-radius: 50%;
    opacity: 0;
    animation: twinkle var(--duration) ease-in-out infinite;
    animation-delay: var(--delay);
    will-change: opacity, transform;
    box-shadow: 0 0 2px rgba(255, 255, 255, 0.8); /* Yıldızlara hafif parlama */
}

@keyframes twinkle {
    0% { opacity: 0.1; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.2); box-shadow: 0 0 6px rgba(255, 255, 255, 0.9); }
    100% { opacity: 0.1; transform: scale(0.8); }
}

/* --- MODERN CAM PANELLER (DARK GLASS) --- */
.modern-glass {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.6);
    /* Hafif bir üst parlama efekti */
    background-image: linear-gradient(to bottom, var(--glass-highlight), transparent);
}

/* --- CUSTOM SCROLLBAR (İNCE & ŞIK) --- */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #020205;
}

::-webkit-scrollbar-thumb {
    background: #333340;
    border-radius: 3px;
    border: 1px solid #000000;
}

::-webkit-scrollbar-thumb:hover {
    background: #4c1d95;
}

.custom-scroll::-webkit-scrollbar {
    width: 4px;
}
.custom-scroll::-webkit-scrollbar-track {
    background: transparent;
}

/* --- ANİMASYONLAR --- */
@keyframes fade-in {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
    animation: fade-in 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes spin-slow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.animate-spin-slow {
    animation: spin-slow 12s linear infinite;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    15%, 45%, 75% { transform: translateX(-4px); }
    30%, 60%, 90% { transform: translateX(4px); }
}

.animate-shake {
    animation: shake 0.4s cubic-bezier(.36,.07,.19,.97) both;
}

/* --- NAVİGASYON & ETKİLEŞİM --- */
.nav-item {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-item:active {
    transform: scale(0.98);
}

.nav-active {
    background: linear-gradient(90deg, rgba(124, 58, 237, 0.15) 0%, transparent 100%) !important;
    border-left: 3px solid #8b5cf6 !important;
    color: #fff !important;
}

/* Modal Arka Planı */
.modal-overlay {
    background-color: rgba(0, 0, 0, 0.92); /* Daha koyu arka plan */
    backdrop-filter: blur(5px);
    transition: opacity 0.3s ease;
}

/* Form Elemanları */
input:focus, select:focus, textarea:focus {
    box-shadow: 0 0 0 2px rgba(124, 58, 237, 0.3);
    outline: none;
    background-color: #0d0d12 !important;
}

input::placeholder, textarea::placeholder {
    color: #52525b;
}

/* Dosya Yükleme Butonu */
input[type="file"]::file-selector-button {
    margin-right: 1rem;
    padding: 0.4rem 1rem;
    border-radius: 0.4rem 0 0 0.4rem;
    border: none;
    background-color: #2e1065;
    color: #d8b4fe;
    font-weight: 600;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

input[type="file"]::file-selector-button:hover {
    background-color: #4c1d95;
    color: white;
}

/* --- GÖRSEL DETAYLAR --- */
#detail-image-container img {
    box-shadow: 0 10px 40px -10px rgba(0,0,0,0.8);
    max-width: 100%;
}

/* Profil Avatar Glow */
#profile-avatar-container {
    box-shadow: 0 0 30px rgba(124, 58, 237, 0.2);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}
#profile-avatar-container:hover {
    transform: scale(1.03);
    box-shadow: 0 0 50px rgba(124, 58, 237, 0.4);
}

/* --- DROPDOWN & ARAMA --- */
#dropdown-options-list .dropdown-option,
#search-results-dropdown .search-result-item {
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    color: #d4d4d8;
}

#dropdown-options-list .dropdown-option:hover,
#search-results-dropdown .search-result-item:hover {
    background-color: rgba(124, 58, 237, 0.1);
    color: white;
    padding-left: 18px; /* Kayma efekti */
}

#search-results-dropdown .search-highlight {
    color: #c084fc;
    font-weight: 700;
}

/* --- EDITOR & MARKDOWN --- */
.rich-content strong { font-weight: 700; color: #f3f4f6; }
.rich-content em { font-style: italic; color: #a78bfa; }
.rich-content code {
    background: #18181b;
    padding: 2px 5px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    color: #f472b6;
    border: 1px solid #27272a;
    font-size: 0.85em;
}
.rich-content a { color: #60a5fa; text-decoration: none; border-bottom: 1px dashed #60a5fa; }
.rich-content a:hover { color: #93c5fd; border-style: solid; }

.editor-btn { transition: all 0.2s ease; color: #71717a; }
.editor-btn:hover { transform: translateY(-2px); color: #e4e4e7; background-color: rgba(255,255,255,0.05); }

/* --- BEĞENİ BUTONU --- */
.like-btn-anim:active { transform: scale(1.3); }
.liked-active {
    color: #ef4444 !important;
    text-shadow: 0 0 20px rgba(239, 68, 68, 0.5);
    animation: pulse-red 0.4s ease-out;
}
@keyframes pulse-red {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* --- TOAST BİLDİRİMİ --- */
.toast {
    background: #09090b;
    border: 1px solid #27272a;
    color: #e4e4e7;
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 280px;
    transform: translateX(120%);
    animation: slide-in 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    border-left: 3px solid #71717a;
    font-size: 0.85rem;
    font-weight: 500;
    z-index: 9999;
}

.toast.success { border-left-color: #22c55e; }
.toast.success i { color: #22c55e; }
.toast.error { border-left-color: #ef4444; }
.toast.error i { color: #ef4444; }
.toast.info { border-left-color: #3b82f6; }
.toast.info i { color: #3b82f6; }

@keyframes slide-in {
    to { transform: translateX(0); }
}
.toast.hiding {
    animation: slide-out 0.3s ease-in forwards;
}
@keyframes slide-out {
    to { transform: translateX(120%); opacity: 0; }
}

/* --- GİZLİ KATEGORİ (EASTER EGG) --- */
.secret-category-found {
    border: 1px solid rgba(220, 38, 38, 0.5) !important;
    background: linear-gradient(135deg, rgba(20, 0, 0, 0.9), rgba(40, 0, 0, 0.8)) !important;
    animation: secret-pulse 2s infinite alternate;
}
@keyframes secret-pulse {
    from { box-shadow: 0 0 10px rgba(220, 38, 38, 0.1); }
    to { box-shadow: 0 0 25px rgba(220, 38, 38, 0.3); }
}

/* --- DİĞER --- */
.admin-badge {
    background: linear-gradient(45deg, #b91c1c, #7f1d1d);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.6rem;
    font-weight: 700;
    color: white;
    margin-left: 6px;
    letter-spacing: 0.5px;
    border: 1px solid rgba(255,255,255,0.1);
    vertical-align: middle;
}