/**
 * Fanzade Blog Home - Frontend CSS v1.1
 */

/* Variables */
.fbh-container {
    --fbh-dark: #1a1a2e;
    --fbh-light: #f8fafc;
    --fbh-text: #334155;
    --fbh-text-light: #64748b;
    --fbh-border: #e2e8f0;
    --fbh-radius: 12px;
    --fbh-shadow: 0 4px 20px rgba(0,0,0,0.08);
    
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px 16px;
}

.fbh-container *, .fbh-container *::before, .fbh-container *::after {
    box-sizing: border-box;
}

/* ==================== CATEGORY MENU ==================== */
.fbh-category-menu {
    background: #fff;
    border-radius: var(--fbh-radius);
    margin-bottom: 24px;
    box-shadow: var(--fbh-shadow);
    padding: 8px;
}

.fbh-menu-inner {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 4px;
}

.fbh-menu-inner::-webkit-scrollbar {
    display: none;
}

.fbh-menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: var(--fbh-light);
    border-radius: 50px;
    text-decoration: none !important;
    color: var(--fbh-text) !important;
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.fbh-menu-item:hover {
    background: var(--cat-color) !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.fbh-menu-icon {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    object-fit: cover;
}

.fbh-menu-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* ==================== HERO SLIDER ==================== */
.fbh-hero {
    position: relative;
    margin-bottom: 30px;
    border-radius: var(--fbh-radius);
    overflow: hidden;
}

.fbh-hero-slider {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 4px;
    min-height: 450px;
}

.fbh-hero-item {
    position: relative;
    overflow: hidden;
}

.fbh-hero-link {
    display: block;
    height: 100%;
    text-decoration: none !important;
    color: #fff !important;
}

.fbh-hero-image {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.fbh-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.fbh-hero-item:hover .fbh-hero-image img {
    transform: scale(1.05);
}

.fbh-hero-placeholder {
    width: 100%;
    height: 100%;
}

/* GÜÇLÜ GRADIENT - yazılar okunabilir olsun */
.fbh-hero-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.95) 0%,
        rgba(0, 0, 0, 0.8) 25%,
        rgba(0, 0, 0, 0.4) 50%,
        rgba(0, 0, 0, 0.2) 75%,
        rgba(0, 0, 0, 0.1) 100%
    );
    z-index: 1;
}

.fbh-hero-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px;
    z-index: 2;
}

.fbh-badge {
    display: inline-block;
    padding: 6px 14px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 4px;
    color: #fff !important;
    text-decoration: none !important;
    margin-bottom: 12px;
}

.fbh-hero-title {
    font-size: 20px;
    font-weight: 800;
    line-height: 1.3;
    margin: 0;
    color: #fff !important;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.fbh-hero-featured .fbh-hero-title {
    font-size: 26px;
}

.fbh-hero-excerpt {
    margin: 12px 0 0;
    font-size: 14px;
    line-height: 1.6;
    color: rgba(255,255,255,0.9) !important;
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

/* ==================== MAIN LAYOUT ==================== */
.fbh-main-content {
    display: flex;
    gap: 30px;
}

.fbh-content-area {
    flex: 1;
    min-width: 0;
}

.fbh-sidebar {
    width: 340px;
    flex-shrink: 0;
}

/* ==================== CATEGORY SECTIONS ==================== */
.fbh-category-section {
    margin-bottom: 50px;
}

.fbh-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--fbh-border);
}

.fbh-section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 20px;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--fbh-dark);
    margin: 0;
}

.fbh-title-bar {
    width: 5px;
    height: 28px;
    border-radius: 3px;
    background-color: var(--section-color);
}

.fbh-section-nav {
    display: flex;
    gap: 8px;
}

.fbh-nav-btn {
    width: 38px;
    height: 38px;
    background: var(--section-color);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    transition: all 0.3s;
}

.fbh-nav-btn:hover {
    opacity: 0.85;
    transform: scale(1.05);
}

.fbh-nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.fbh-nav-btn svg {
    width: 18px;
    height: 18px;
}

/* Posts Slider */
.fbh-posts-slider-wrap {
    overflow: hidden;
}

.fbh-posts-slider {
    display: flex;
    gap: 20px;
    transition: transform 0.4s ease;
}

/* Post Card */
.fbh-post-card {
    flex: 0 0 calc(25% - 15px);
    min-width: 260px;
    background: #fff;
    border-radius: var(--fbh-radius);
    overflow: hidden;
    box-shadow: var(--fbh-shadow);
    transition: all 0.3s ease;
}

.fbh-post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 35px rgba(0,0,0,0.12);
}

.fbh-card-link {
    display: block;
    text-decoration: none !important;
    color: inherit !important;
}

.fbh-card-image {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: var(--fbh-light);
}

.fbh-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.fbh-post-card:hover .fbh-card-image img {
    transform: scale(1.08);
}

.fbh-card-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--fbh-light), #e2e8f0);
}

.fbh-card-image .fbh-badge {
    position: absolute;
    bottom: 12px;
    left: 12px;
    z-index: 2;
}

.fbh-card-content {
    padding: 18px;
}

.fbh-card-title {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 10px;
    color: var(--fbh-dark) !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.fbh-card-meta {
    font-size: 12px;
    color: var(--fbh-text-light);
    margin-bottom: 10px;
}

.fbh-meta-author {
    color: var(--section-color);
    font-weight: 600;
}

.fbh-meta-sep {
    margin: 0 6px;
    opacity: 0.5;
}

.fbh-card-excerpt {
    font-size: 13px;
    line-height: 1.5;
    color: var(--fbh-text);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Section Footer - Daha Fazla Butonu */
.fbh-section-footer {
    margin-top: 24px;
    text-align: center;
}

.fbh-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    background: var(--section-color) !important;
    color: #fff !important;
    text-decoration: none !important;
    font-weight: 600;
    font-size: 14px;
    border-radius: 50px;
    transition: all 0.3s;
}

.fbh-more-btn:hover {
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
    color: #fff !important;
}

.fbh-more-btn svg {
    width: 18px;
    height: 18px;
}

/* ==================== SIDEBAR ==================== */
.fbh-sidebar-inner {
    position: sticky;
    top: 20px;
}

.fbh-widget {
    background: #fff;
    border-radius: var(--fbh-radius);
    box-shadow: var(--fbh-shadow);
    margin-bottom: 24px;
    overflow: hidden;
}

.fbh-widget-title {
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 18px 20px;
    margin: 0;
    background: linear-gradient(135deg, var(--fbh-dark), #2d3748);
    color: #fff;
}

/* Featured Posts Widget */
.fbh-featured-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.fbh-featured-item {
    border-bottom: 1px solid var(--fbh-border);
}

.fbh-featured-item:last-child {
    border-bottom: none;
}

.fbh-featured-item a {
    display: flex;
    gap: 14px;
    padding: 16px 20px;
    text-decoration: none !important;
    transition: background 0.3s;
}

.fbh-featured-item a:hover {
    background: var(--fbh-light);
}

.fbh-featured-thumb {
    width: 75px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--fbh-light);
}

.fbh-featured-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.fbh-thumb-placeholder {
    width: 100%;
    height: 100%;
}

.fbh-featured-info {
    flex: 1;
    min-width: 0;
}

.fbh-featured-info h4 {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;
    margin: 0 0 6px;
    color: var(--fbh-dark) !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.fbh-featured-meta {
    font-size: 11px;
    color: var(--fbh-text-light);
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 1200px) {
    .fbh-post-card {
        flex: 0 0 calc(33.333% - 14px);
    }
}

@media (max-width: 992px) {
    .fbh-main-content {
        flex-direction: column;
    }
    
    .fbh-sidebar {
        width: 100%;
    }
    
    .fbh-hero-slider {
        grid-template-columns: 1fr 1fr;
        min-height: 400px;
    }
    
    .fbh-hero-featured {
        grid-column: span 2;
    }
    
    .fbh-post-card {
        flex: 0 0 calc(50% - 10px);
    }
}

@media (max-width: 768px) {
    .fbh-hero-slider {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    
    .fbh-hero-item {
        min-height: 300px;
    }
    
    .fbh-hero-featured {
        grid-column: span 1;
    }
    
    .fbh-hero-title {
        font-size: 18px;
    }
    
    .fbh-hero-featured .fbh-hero-title {
        font-size: 20px;
    }
    
    .fbh-post-card {
        flex: 0 0 100%;
        min-width: 100%;
    }
    
    .fbh-section-title {
        font-size: 16px;
    }
    
    .fbh-menu-item {
        padding: 10px 16px;
        font-size: 13px;
    }
}

/* ==================== DARK MODE ==================== */
.dark-mode .fbh-container,
[data-theme="dark"] .fbh-container {
    --fbh-dark: #e2e8f0;
    --fbh-light: #1e293b;
    --fbh-text: #cbd5e1;
    --fbh-text-light: #94a3b8;
    --fbh-border: #334155;
}

.dark-mode .fbh-category-menu,
.dark-mode .fbh-post-card,
.dark-mode .fbh-widget,
[data-theme="dark"] .fbh-category-menu,
[data-theme="dark"] .fbh-post-card,
[data-theme="dark"] .fbh-widget {
    background: #1e293b;
}

.dark-mode .fbh-menu-item,
[data-theme="dark"] .fbh-menu-item {
    background: #334155;
    color: #e2e8f0 !important;
}

.dark-mode .fbh-card-content,
[data-theme="dark"] .fbh-card-content {
    background: #1e293b;
}

.dark-mode .fbh-featured-item a:hover,
[data-theme="dark"] .fbh-featured-item a:hover {
    background: #334155;
}

.dark-mode .fbh-card-title,
.dark-mode .fbh-featured-info h4,
[data-theme="dark"] .fbh-card-title,
[data-theme="dark"] .fbh-featured-info h4 {
    color: #e2e8f0 !important;
}
