/* Nerede Çekildi - Custom Styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #f8fafc;
    color: #1f2937;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* Custom Select Styling */
select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
}

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 10000;
    animation: slideIn 0.3s ease-out;
}

.toast.success { background-color: #10b981; }
.toast.error { background-color: #ef4444; }
.toast.info { background-color: #3b82f6; }

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e5e7eb;
    border-top-color: #1d4ed8;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Image Upload Area */
.upload-area {
    border: 2px dashed #d1d5db;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.upload-area:hover,
.upload-area.drag-over {
    border-color: #1d4ed8;
    background-color: #eff6ff;
}

/* Image Preview */
.image-preview {
    position: relative;
    display: inline-block;
}

.image-preview img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid #e5e7eb;
}

.image-preview .remove-btn {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

/* Primary color */
.text-primary { color: #1d4ed8; }
.bg-primary { background-color: #1d4ed8; }
.border-primary { border-color: #1d4ed8; }
.ring-primary { --tw-ring-color: #1d4ed8; }

/* Secondary color (green links) */
.text-secondary { color: #059669; }
.bg-secondary { background-color: #059669; }

/* Çapraz Yazı (Badge) - Orijinal Siteye Uygun */
.badge-diagonal {
    position: absolute;
    top: 20px;
    right: -35px;
    background-color: #1d4ed8;
    color: white;
    padding: 6px 40px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transform: rotate(45deg);
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    z-index: 10;
}

/* Ribbon Style Badge */
.badge-ribbon {
    position: absolute;
    top: 15px;
    right: -5px;
    background-color: #1d4ed8;
    color: white;
    padding: 8px 20px 8px 15px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    z-index: 10;
}

.badge-ribbon::before {
    content: '';
    position: absolute;
    right: 0;
    bottom: -5px;
    border-style: solid;
    border-width: 5px 5px 0 0;
    border-color: #1e3a8a transparent transparent transparent;
}

/* Slider Thumbnail Active State */
.thumbnail-btn.active,
.thumbnail-btn:focus {
    outline: none;
}

/* Lightbox */
#lightbox {
    background: rgba(0, 0, 0, 0.95);
}

#lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
}

/* Tag hover effects */
.tag-link {
    transition: all 0.2s ease;
}

.tag-link:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Autocomplete Dropdown */
#autocomplete-dropdown {
    max-height: 200px;
    overflow-y: auto;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

#autocomplete-dropdown > div:first-child {
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

#autocomplete-dropdown > div:last-child {
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

/* Actor Tags */
.actor-tag {
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* Responsive */
@media (max-width: 768px) {
    .mobile-menu {
        display: none;
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        background: white;
        border-bottom: 1px solid #e5e7eb;
        padding: 1rem;
        z-index: 40;
    }
    
    .mobile-menu.active {
        display: block;
    }
    
    /* Post detail sidebar stacks on mobile */
    .lg\:flex-row {
        flex-direction: column;
    }
    
    /* Badge smaller on mobile */
    .badge-ribbon {
        font-size: 11px;
        padding: 6px 15px 6px 12px;
    }
}

/* Print */
@media print {
    header, footer, .no-print {
        display: none !important;
    }
}

/* Focus visible for accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #1d4ed8;
    outline-offset: 2px;
}

/* Smooth image loading - disabled for now */
img {
    transition: opacity 0.3s ease;
    opacity: 1 !important;
}

/* ========================================
   REKLAM CONTAINER STİLLERİ
   ======================================== */

/* Tüm reklam containerları */
.ad-container {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Reklam container boşken gizle */
.ad-container:empty {
    display: none;
}

/* Header altı reklam */
.ad-header_below {
    background-color: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    min-height: 90px;
}

/* Footer üstü reklam */
.ad-footer_above {
    background-color: #f3f4f6;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    min-height: 90px;
}

/* Sidebar reklamları */
.ad-sidebar_top,
.ad-sidebar_bottom {
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 1rem;
    min-height: 250px;
}

/* Post içi reklamlar */
.ad-post_top,
.ad-post_middle {
    background-color: #fafafa;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    padding: 1rem;
    min-height: 100px;
}

/* İçerik arası (in-feed) reklamlar */
.ad-content_between {
    min-height: 250px;
}

/* Responsive reklam ayarları */
@media (max-width: 768px) {
    .ad-header_below,
    .ad-footer_above {
        min-height: 50px;
    }
    
    .ad-sidebar_top,
    .ad-sidebar_bottom {
        min-height: 100px;
    }
    
    .ad-container {
        padding: 0.5rem;
    }
}

/* Reklam içindeki script ve iframe responsive */
.ad-container ins,
.ad-container iframe {
    max-width: 100%;
}