/* Widget stilleri */

.widget {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: var(--shadow);
    padding: 20px;
    margin-bottom: 20px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.widget:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.widget-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent-color);
    color: var(--primary-color);
}

/* Sosyal medya ikonları */
.sozluk-social-icons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.social-icon-link {
    display: inline-block;
    transition: transform 0.3s;
}

.social-icon-link:hover {
    transform: scale(1.2);
}

/* Başlık istatistikleri widget */
.title-stats-widget .stat-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.title-stats-widget .stat-item:last-child {
    border-bottom: none;
}

.stat-label {
    font-weight: 500;
    color: var(--light-text);
}

.stat-value {
    font-weight: 600;
    color: var(--primary-color);
}

/* ==========================================================================
   SİDEBAR VE GENEL WİDGET STİLLERİ
   ========================================================================== */

/* Yan panel */
.sidebar {
    background-color: var(--white);
    border-radius: 4px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    overflow: hidden; /* İçerik taşmasını engelle */
    word-wrap: break-word;
    overflow-wrap: break-word;
    transition: var(--theme-transition);
}

.sidebar-header {
    padding: 12px 15px;
    margin: 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 1.1rem;
    color: var(--primary-color);
    background-color: var(--white);
    border-radius: 4px 4px 0 0;
}

.sidebar-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-item {
    padding: 10px 15px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    word-wrap: break-word;
    overflow-wrap: break-word;
    transition: background-color 0.3s ease;
}

.sidebar-item:last-child {
    border-bottom: none;
}

.sidebar-item:hover {
    background-color: var(--primary-5);
}

.sidebar-item a {
    color: var(--text-color);
    text-decoration: none;
    flex: 1;
    padding-right: 10px;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-width: 0; /* Flexbox içerikte önemli */
    max-width: 100%;
    transition: color 0.3s ease;
}

.sidebar-item a:hover {
    color: var(--primary-color);
}

.sidebar-item-count {
    background-color: var(--primary-10);
    color: var(--text-color);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    white-space: nowrap;
    margin-left: 8px;
}

/* Sidebar içindeki metin sadece li elemanları için */
.sidebar-item:not(:has(a)) {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    max-width: 100%;
    text-align: left;
    color: var(--light-text);
    font-style: italic;
}

/* Alternatif seçici (eski tarayıcılar için) */
.sidebar li {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    max-width: 100%;
}

.sidebar li:not(.sidebar-item) {
    padding: 10px 15px;
    border-bottom: 1px solid var(--border-color);
    color: var(--light-text);
    font-style: italic;
}

/* Sidebar boş mesajları için özel stil */
.sidebar-empty-message {
    padding: 10px 15px !important;
    border-bottom: 1px solid var(--border-color) !important;
    color: var(--light-text) !important;
    font-style: italic !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
    max-width: 100% !important;
    text-align: center !important;
    font-size: 0.9rem !important;
}

/* Sidebar içindeki özel elemanlar */
.sidebar .alfabe-nav {
    padding: 15px;
    margin-top: 0;
}

.sidebar .pagination-info {
    padding: 15px;
    background-color: var(--primary-5);
    margin-top: 10px;
    border-radius: 0 0 4px 4px;
}

.sidebar .pagination-info p {
    margin: 5px 0;
    font-size: 0.85rem;
    color: var(--light-text);
}

/* ==========================================================================
   ALFABETİK NAVİGASYON WİDGET
   ========================================================================== */

.alphabet-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
    margin-bottom: 10px;
}

.letter-link {
    display: inline-block;
    padding: 5px 8px;
    margin: 1px;
    background: var(--primary-5);
    color: var(--light-text);
    text-decoration: none;
    font-size: 12px;
    font-weight: bold;
    border: 1px solid var(--border-color);
    border-radius: 2px;
    min-width: 24px;
    text-align: center;
    transition: all 0.2s ease;
}

.letter-link:hover {
    background: var(--border-color);
    color: var(--text-color);
    text-decoration: none;
}

.letter-link.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.letter-link.active:hover {
    background: var(--secondary-color);
    border-color: var(--secondary-color);
}

.letter-count {
    font-size: 10px;
    font-weight: normal;
    margin-left: 2px;
    opacity: 0.8;
}

/* ==========================================================================
   SİTE İSTATİSTİKLERİ WİDGET
   ========================================================================== */

.stats-container {
    padding: 5px 0;
}

.stats-row {
    display: flex;
    align-items: center;
    padding: 14px 15px;
    position: relative;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 6px;
    margin: 2px 0;
    background: var(--white);
    border: 1px solid var(--border-color);
}

.stats-row:hover {
    background: var(--white);
    transform: translateX(3px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-color: var(--primary-color);
}

.stats-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    margin-right: 12px;
    flex-shrink: 0;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.stats-row:hover .stats-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.stats-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.stats-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 2px;
    text-transform: capitalize;
}

.stats-subtitle {
    font-size: 11px;
    color: var(--light-text);
    opacity: 0.8;
    font-weight: 400;
}

.stats-value {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-color);
    margin-left: 12px;
    flex-shrink: 0;
    min-width: 45px;
    text-align: right;
    position: relative;
}

.stats-value::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 12px;
    background: linear-gradient(180deg, var(--primary-color), var(--secondary-color));
    border-radius: 1px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stats-row:hover .stats-value::before {
    opacity: 1;
}

/* ==========================================================================
   GÜNDEM WİDGET
   ========================================================================== */

.trending-list {
    list-style: none;
    margin: 0;
    padding: 5px 0;
}

.trending-item {
    margin: 2px 0;
    position: relative;
}

.trending-link {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 6px;
    margin: 0;
    background: var(--white);
    border: 1px solid var(--border-color);
    position: relative;
}

.trending-link:hover {
    background: var(--white);
    transform: translateX(3px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border-color: var(--primary-color);
    text-decoration: none;
    color: var(--text-color);
}

.trending-link::before {
    content: '🔥';
    font-size: 12px;
    margin-right: 8px;
    opacity: 0.7;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.trending-link:hover::before {
    opacity: 1;
    transform: scale(1.1);
}

.trending-title {
    flex: 1;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.3;
    margin-right: 16px;
    color: var(--text-color);
    transition: color 0.3s ease;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    padding-right: 8px;
}

.trending-link:hover .trending-title {
    color: var(--primary-color);
    font-weight: 600;
}

.trending-count {
    background: linear-gradient(135deg, var(--light-bg), var(--primary-10));
    color: var(--primary-color);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    min-width: 24px;
    text-align: center;
    flex-shrink: 0;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-left: 12px;
}

.trending-link:hover .trending-count {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-color: var(--primary-color);
    transform: scale(1.1);
    box-shadow: 0 2px 6px var(--primary-20);
}

.trending-count::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 12px;
    background: linear-gradient(180deg, var(--primary-color), var(--secondary-color));
    border-radius: 1px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.trending-link:hover .trending-count::before {
    opacity: 1;
}

.no-trending {
    font-size: 13px;
    color: var(--light-text);
    font-style: italic;
    margin: 0;
    text-align: center;
    padding: 20px 15px;
    background: var(--light-bg);
    border-radius: 6px;
    border: 1px dashed var(--border-color);
    position: relative;
}

.no-trending::before {
    content: '📫';
    font-size: 24px;
    display: block;
    margin-bottom: 8px;
    opacity: 0.5;
}

/* Gündem Widget için özel sıralama göstergesi */
.trending-item:nth-child(1) .trending-link::before { content: '🥇'; }
.trending-item:nth-child(2) .trending-link::before { content: '🥈'; }
.trending-item:nth-child(3) .trending-link::before { content: '🥉'; }
.trending-item:nth-child(n+4) .trending-link::before { content: '🔥'; }

/* Popülerlik seviyesi renkleri */
.trending-item:nth-child(1) .trending-count {
    background: linear-gradient(135deg, var(--accent-color), var(--accent-hover));
    color: var(--text-color);
    border-color: var(--accent-color);
}

.trending-item:nth-child(2) .trending-count {
    background: linear-gradient(135deg, var(--border-color), var(--light-text));
    color: var(--text-color);
    border-color: var(--border-color);
}

.trending-item:nth-child(3) .trending-count {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    color: var(--white);
    border-color: var(--secondary-color);
}

/* ==========================================================================
   AKTİF YAZARLAR WİDGET
   ========================================================================== */

.active-authors-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.author-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    background: var(--light-bg);
    border-radius: 4px;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.author-item:hover {
    background: var(--primary-5);
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.author-avatar {
    flex-shrink: 0;
}

.author-avatar img {
    border-radius: 50%;
    border: 2px solid var(--border-color);
    width: 32px;
    height: 32px;
}

.author-info {
    flex: 1;
    min-width: 0;
}

.author-name {
    display: block;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    font-size: 12px;
    margin-bottom: 2px;
}

.author-name:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.author-stats {
    display: flex;
    gap: 8px;
    font-size: 10px;
    color: var(--light-text);
}

.post-count {
    font-weight: bold;
    color: var(--primary-color);
}

.last-activity {
    color: var(--light-text);
}

.no-authors {
    font-size: 12px;
    color: var(--light-text);
    font-style: italic;
    margin: 0;
    text-align: center;
    padding: 10px 0;
}

/* ==========================================================================
   RASTGELE BAŞLIK WİDGET
   ========================================================================== */

.random-post {
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background: var(--light-bg);
    padding: 12px;
    transition: all 0.2s ease;
}

.random-post:hover {
    background: var(--primary-5);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.random-title {
    margin: 0 0 8px 0;
    font-size: 13px;
    font-weight: bold;
    line-height: 1.3;
}

.random-title a {
    color: var(--primary-color);
    text-decoration: none;
}

.random-title a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.random-excerpt {
    font-size: 11px;
    color: var(--light-text);
    line-height: 1.4;
    margin-bottom: 8px;
}

.random-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 10px;
    color: var(--light-text);
    margin-bottom: 10px;
}

.random-author {
    color: var(--primary-color);
    font-weight: bold;
}

.random-date {
    color: var(--light-text);
}

.random-comments {
    background: var(--border-color);
    color: var(--light-text);
    padding: 1px 5px;
    border-radius: 8px;
    font-weight: bold;
}

.random-refresh {
    text-align: center;
}

.refresh-random {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 5px 12px;
    border-radius: 3px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.refresh-random:hover {
    background: var(--secondary-color);
    transform: translateY(-1px);
}

.no-random {
    font-size: 12px;
    color: var(--light-text);
    font-style: italic;
    margin: 0;
    text-align: center;
    padding: 10px 0;
}

/* ==========================================================================
   SİDEBAR WİDGET STİLLERİ
   ========================================================================== */

.sidebar-widget {
    background-color: var(--white);
    border-radius: 4px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    overflow: hidden;
    word-wrap: break-word;
    overflow-wrap: break-word;
    transition: var(--theme-transition);
}

.sidebar-widget:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.sidebar-widget-title {
    padding: 12px 15px;
    margin: 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 1.1rem;
    color: var(--primary-color);
    background-color: var(--light-bg);
    border-radius: 4px 4px 0 0;
    position: relative;
}

.sidebar-widget-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 15px;
    width: 30px;
    height: 2px;
    background: var(--primary-color);
}

.sidebar-widget .widget {
    padding: 15px;
}

.sidebar-widget ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-widget li {
    padding: 8px 15px;
    border-bottom: 1px solid var(--border-color);
    word-wrap: break-word;
    overflow-wrap: break-word;
    transition: background-color 0.3s ease;
}

.sidebar-widget li:last-child {
    border-bottom: none;
}

.sidebar-widget li:hover {
    background-color: var(--light-bg);
}

.sidebar-widget a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

.sidebar-widget a:hover {
    color: var(--primary-color);
}

/* ==========================================================================
   FOOTER WİDGET STİLLERİ
   ========================================================================== */

.footer-widgets {
    padding: 50px 0 30px;
    background: linear-gradient(135deg, var(--header-bg) 0%, var(--secondary-color) 100%);
    position: relative;
}

.footer-widgets::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.1);
    pointer-events: none;
}

.footer-widget-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    position: relative;
    z-index: 1;
}

.footer-widget-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.footer-widget {
    background: rgba(255, 255, 255, 0.1);
    padding: 25px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.footer-widget:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.footer-widget-title {
    color: var(--header-text);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent-color);
    position: relative;
}

.footer-widget-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--accent-color);
    box-shadow: 0 0 10px var(--accent-color);
}

.footer-widget p {
    color: var(--header-text);
    opacity: 0.9;
    line-height: 1.6;
    margin: 0 0 10px 0;
}

.footer-widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-widget li {
    margin-bottom: 8px;
}

.footer-widget a {
    color: var(--header-text);
    opacity: 0.8;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    display: inline-block;
}

.footer-widget a:hover {
    color: var(--accent-color);
    opacity: 1;
    transform: translateX(5px);
}

.footer-widget a::before {
    content: '→';
    position: absolute;
    left: -15px;
    opacity: 0;
    transition: all 0.3s ease;
}

.footer-widget a:hover::before {
    opacity: 1;
    left: -20px;
}

/* Footer Links Listesi */
.footer-links {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.footer-links a {
    padding: 5px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-links a:hover {
    border-bottom-color: var(--accent-color);
}

/* ==========================================================================
   YUKARI ÇIK BUTONU
   ========================================================================== */

.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px var(--primary-20);
    border: 2px solid var(--white);
}

.scroll-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 16px var(--primary-20);
}

.scroll-to-top:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px var(--primary-20);
}

/* Yukarı çık butonu animasyonları */
@keyframes scrollToTopPulse {
    0% { 
        box-shadow: 0 4px 12px var(--primary-20);
    }
    50% {
        box-shadow: 0 4px 12px var(--primary-20), 0 0 0 8px var(--primary-10);
    }
    100% {
        box-shadow: 0 4px 12px var(--primary-20);
    }
}

.scroll-to-top:hover {
    animation: scrollToTopPulse 2s infinite;
}

/* Responsive */
@media (max-width: 768px) {
    .widget {
        padding: 15px;
    }
    
    .widget-title {
        font-size: 16px;
    }
    
    /* Mobil için yukarı çık butonu */
    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .alphabet-nav {
        gap: 2px;
    }
    
    .letter-link {
        padding: 4px 6px;
        font-size: 11px;
        min-width: 20px;
    }
    
    .trending-link {
        font-size: 11px;
    }
    
    .trending-count {
        font-size: 9px;
        padding: 1px 4px;
        min-width: 16px;
    }
    
    .author-item {
        padding: 6px;
        gap: 8px;
    }
    
    .author-avatar img {
        width: 28px;
        height: 28px;
    }
    
    .author-name {
        font-size: 11px;
    }
    
    .author-stats {
        gap: 6px;
        font-size: 9px;
    }
    
    .random-post {
        padding: 10px;
    }
    
    .random-title {
        font-size: 12px;
    }
    
    .random-excerpt {
        font-size: 10px;
    }
    
    .random-meta {
        font-size: 9px;
        gap: 6px;
    }
    
    .refresh-random {
        padding: 4px 10px;
        font-size: 10px;
    }
}

/* Widget responsive tasarım */
@media (max-width: 992px) {
    .footer-widget-columns {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .footer-widgets {
        padding: 40px 0 25px;
    }
    
    .footer-widget {
        padding: 20px;
    }
}

@media (max-width: 768px) {
    .footer-widget-columns {
        gap: 20px;
    }
    
    .footer-widget {
        padding: 15px;
    }
    
    .footer-widget-title {
        font-size: 1rem;
    }
}
