/**
 * HaberAdam - Modern Enhancements CSS
 * Modern dokunuşlar: animasyonlar, hover efektleri, dark mode, skeleton loading
 * v1.0
 */

/* ============================================
   CSS CUSTOM PROPERTIES (Değişkenler)
   ============================================ */
:root {
    --ha-transition-fast: 0.2s ease;
    --ha-transition-normal: 0.3s ease;
    --ha-transition-slow: 0.5s ease;
    --ha-shadow-sm: 0 1px 3px rgba(0,0,0,.08);
    --ha-shadow-md: 0 4px 12px rgba(0,0,0,.1);
    --ha-shadow-lg: 0 8px 30px rgba(0,0,0,.12);
    --ha-shadow-hover: 0 8px 25px rgba(0,0,0,.15);
    --ha-radius-sm: 6px;
    --ha-radius-md: 10px;
    --ha-radius-lg: 16px;
    --ha-radius-pill: 50px;

    /* Light mode renkleri */
    --ha-bg-primary: #ffffff;
    --ha-bg-secondary: #f8f9fa;
    --ha-bg-tertiary: #f0f2f5;
    --ha-text-primary: #1a1a2e;
    --ha-text-secondary: #5f6368;
    --ha-text-muted: #9aa0a6;
    --ha-border-color: #e8eaed;
    --ha-card-bg: #ffffff;
    --ha-overlay-gradient: linear-gradient(180deg, transparent 40%, rgba(0,0,0,.75) 100%);
    --ha-skeleton-base: #e8eaed;
    --ha-skeleton-shine: #f5f5f5;
}

/* ============================================
   DARK MODE
   ============================================ */
body.dark-mode,
html.dark-mode {
    --ha-bg-primary: #1a1a2e;
    --ha-bg-secondary: #16213e;
    --ha-bg-tertiary: #0f3460;
    --ha-text-primary: #e8eaed;
    --ha-text-secondary: #bdc1c6;
    --ha-text-muted: #9aa0a6;
    --ha-border-color: #2d3748;
    --ha-card-bg: #1e293b;
    --ha-skeleton-base: #2d3748;
    --ha-skeleton-shine: #374151;
}

body.dark-mode {
    background-color: var(--ha-bg-primary) !important;
    color: var(--ha-text-primary);
}

body.dark-mode .container,
body.dark-mode #home {
    color: var(--ha-text-primary);
}

body.dark-mode footer {
    background: var(--ha-bg-secondary) !important;
    color: var(--ha-text-primary);
}

body.dark-mode .newsBox > strong span,
body.dark-mode .newsBox > strong {
    color: var(--ha-text-primary) !important;
}

body.dark-mode .sixNews .newsBox > span img {
    opacity: 0.9;
}

body.dark-mode .sidebar .widget,
body.dark-mode .side-puandurumu,
body.dark-mode .leagueBox div,
body.dark-mode .quickComment {
    background: var(--ha-card-bg) !important;
    border-color: var(--ha-border-color) !important;
}

body.dark-mode .leagueBox .newPDHead {
    background: var(--ha-bg-tertiary) !important;
    border-color: var(--ha-border-color) !important;
}

body.dark-mode .leagueBox .newPDHead span,
body.dark-mode .leagueBox .newPDTeams .item .left span,
body.dark-mode .leagueBox .newPDTeams .item .left b,
body.dark-mode .leagueBox .newPDTeams .item ul li,
body.dark-mode .leagueBox .newPDTeams2 .item .left span,
body.dark-mode .leagueBox .newPDTeams2 .item .left b,
body.dark-mode .leagueBox .newPDTeams2 .item ul li {
    color: var(--ha-text-primary) !important;
}

body.dark-mode .leagueBox .newPDTeams .item,
body.dark-mode .leagueBox .newPDTeams2 .item {
    border-color: var(--ha-border-color) !important;
}

body.dark-mode .currencyTable {
    background: var(--ha-card-bg) !important;
    border-color: var(--ha-border-color) !important;
}

body.dark-mode .currencyTable tr {
    border-color: var(--ha-border-color) !important;
    color: var(--ha-text-primary) !important;
}

body.dark-mode .currencyTable tr:nth-child(even) {
    background: var(--ha-bg-secondary) !important;
}

body.dark-mode #newsRead .bottom .left .detail,
body.dark-mode #newsRead .bottom .left .detail p {
    color: var(--ha-text-primary) !important;
}

body.dark-mode .cb-veriler,
body.dark-mode .cb-veri,
body.dark-mode .puan-durumu-cont {
    background: var(--ha-card-bg) !important;
}

body.dark-mode .policy {
    background: var(--ha-bg-secondary) !important;
}

/* ============================================
   SMOOTH SCROLL
   ============================================ */
html {
    scroll-behavior: smooth;
}

/* ============================================
   GENEL GEÇİŞ ANIMASYONLARI
   ============================================ */
.scrollTop, .load-more a {
    transition: all var(--ha-transition-normal) !important;
}

.newsBox > strong {
    transition: color var(--ha-transition-normal) !important;
}

/* ============================================
   HABER KARTLARI - MODERN HOVER EFEKTLERİ
   ============================================ */

/* Kart image zoom efekti */
.newsBox > span {
    position: relative;
}

.newsBox > span img {
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
    will-change: transform;
}

.newsBox:hover > span img {
    transform: scale(1.04);
}

/* Kart başlık hover */
.newsBox > strong span {
    transition: color var(--ha-transition-fast) !important;
}

/* Video icon animasyonu */
.newsBox .icon-play-arrow {
    transition: transform 0.3s ease !important;
}

.newsBox:hover .icon-play-arrow {
    transform: scale(1.1) !important;
}

/* ============================================
   SİXNEWS GRID
   ============================================ */

/* ============================================
   KATEGORİ ETİKETLERİ
   ============================================ */
.tag {
    font-weight: 700 !important;
    letter-spacing: 0.3px !important;
    text-transform: uppercase !important;
    font-size: 12px !important;
}

/* Kategori/Son Dakika etiketleri resmin üzerinde kalmalı */
.newsBox > span .news-four-in-tag,
.newsBox > span > strong.news-four-in-tag {
    z-index: 2 !important;
    position: absolute !important;
}

/* ============================================
   ALT KATEGORİ NAVİGASYON
   ============================================ */
.alt-cat ul li a:hover {
    opacity: 0.85;
}

/* ============================================
   SCROLL TO TOP - MODERN
   ============================================ */
.scrollTop {
    border-radius: 50% !important;
    width: 48px !important;
    height: 48px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    box-shadow: var(--ha-shadow-lg) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all var(--ha-transition-normal) !important;
}

.scrollTop.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scrollTop:hover {
    transform: translateY(-3px) !important;
    box-shadow: var(--ha-shadow-hover) !important;
}

/* ============================================
   PUAN DURUMU
   ============================================ */
.cb-veri ul li {
    transition: background-color var(--ha-transition-fast) !important;
}

.cb-veri ul li:hover {
    background-color: rgba(0,0,0,.02);
}

/* ============================================
   SİDEBAR
   ============================================ */

/* ============================================
   DAHA FAZLA YÜKLE
   ============================================ */
.load-more a {
    position: relative;
    overflow: hidden;
    font-weight: 600 !important;
}

.load-more a:hover {
    opacity: 0.9;
}

/* Loading state */
.load-more a.loading span {
    opacity: 0;
}

.load-more a.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255,255,255,.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: ha-spin 0.6s linear infinite;
    top: 50%;
    left: 50%;
    margin: -10px 0 0 -10px;
}

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

/* ============================================
   SON DAKİKA - MODERN PULSE
   ============================================ */
.sonDakikaWidget::before,
[class*="son-dakika"]::before {
    animation: ha-pulse 2s ease-in-out infinite !important;
}

@keyframes ha-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* ============================================
   SKELETON LOADING
   ============================================ */
.ha-skeleton {
    background: var(--ha-skeleton-base);
    background-image: linear-gradient(
        90deg,
        var(--ha-skeleton-base) 0%,
        var(--ha-skeleton-shine) 50%,
        var(--ha-skeleton-base) 100%
    );
    background-size: 200% 100%;
    animation: ha-skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: var(--ha-radius-sm);
}

.ha-skeleton-text {
    height: 14px;
    margin-bottom: 8px;
    border-radius: 4px;
}

.ha-skeleton-text:last-child {
    width: 70%;
}

.ha-skeleton-img {
    width: 100%;
    padding-top: 56.25%; /* 16:9 */
    border-radius: var(--ha-radius-sm);
}

.ha-skeleton-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

@keyframes ha-skeleton-shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* ============================================
   FOOTER - MODERN STİL
   ============================================ */
footer {
    border-top: 1px solid var(--ha-border-color);
}

.footer-top {
    position: relative;
    overflow: hidden;
}

.footer-links {
    border-top: 1px solid rgba(255,255,255,.1);
}

.footer-links a {
    transition: color var(--ha-transition-fast), 
                transform var(--ha-transition-fast) !important;
}

.footer-links a:hover {
    transform: translateX(3px);
}

/* ============================================
   FORM ELEMANLARI
   ============================================ */
input[type="text"]:focus,
input[type="email"]:focus,
input[type="search"]:focus,
textarea:focus {
    outline: none;
}

/* ============================================
   YORUM ALANI
   ============================================ */
.quickComment {
    transition: box-shadow var(--ha-transition-normal) !important;
}

.quickComment:hover {
    box-shadow: var(--ha-shadow-sm) !important;
}

/* ============================================
   DÖVİZ / KRİPTO TABLOSU
   ============================================ */
.currencyTable span.increase,
.currencyTable span.decrease {
    font-weight: 600 !important;
}

/* ============================================
   BREADCRUMB
   ============================================ */
.breadcrumb a,
.siteMap a {
    transition: color var(--ha-transition-fast) !important;
}

/* ============================================
   RESPONSIVE İYİLEŞTİRMELER
   ============================================ */
@media screen and (max-width: 768px) {
    .newsBox:hover > span img {
        transform: none;
    }
    
    .scrollTop {
        width: 42px !important;
        height: 42px !important;
        right: 15px !important;
        bottom: 15px !important;
    }
}

/* ============================================
   SCROLLBAR STİLİ (Modern)
   ============================================ */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--ha-bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: #bdc1c6;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #9aa0a6;
}

body.dark-mode ::-webkit-scrollbar-track {
    background: var(--ha-bg-secondary);
}

body.dark-mode ::-webkit-scrollbar-thumb {
    background: #4a5568;
}

/* ============================================
   SEÇİM / FOCUS STİLLERİ
   ============================================ */
::selection {
    background: rgba(201, 9, 20, 0.2);
    color: inherit;
}

:focus-visible {
    outline: 2px solid rgba(201, 9, 20, 0.5);
    outline-offset: 2px;
}

/* ============================================
   DARK MODE TOGGLE BUTON
   ============================================ */
.ha-dark-toggle {
    position: relative;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 18px;
    transition: all var(--ha-transition-fast);
    margin-left: 10px;
}

.ha-dark-toggle:hover {
    background: rgba(255,255,255,.15);
    transform: rotate(20deg);
}

.ha-dark-toggle .ha-sun {
    display: none;
}

.ha-dark-toggle .ha-moon {
    display: inline;
}

body.dark-mode .ha-dark-toggle .ha-sun {
    display: inline;
}

body.dark-mode .ha-dark-toggle .ha-moon {
    display: none;
}

/* ============================================
   IMAGE LOADING
   ============================================ */
img {
    opacity: 1;
}

/* ============================================
   BEĞENİ / PAYLAŞIM İKONLARI
   ============================================ */
.options-icons .icon-border {
    transition: all var(--ha-transition-fast) !important;
}

.options-icons:hover .icon-border {
    transform: scale(1.1);
}

/* ============================================
   OKUMA SÜRESİ
   ============================================ */
.ha-read-time {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    color: var(--ha-text-muted);
    font-weight: 500;
}

.ha-read-time svg {
    width: 14px;
    height: 14px;
    fill: currentColor;
}

/* ============================================
   İLERLEME ÇUBUĞU (Okuma Progress)
   ============================================ */
.ha-reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, #c90914, #ff4a69);
    z-index: 99999;
    transition: width 0.1s linear;
    border-radius: 0 2px 2px 0;
}

/* ============================================
   HABER PAYLAŞIM ÇUBUĞU (Sticky)
   ============================================ */
.shareDivArea {
    transition: all var(--ha-transition-normal) !important;
}

.shareDivArea a {
    transition: transform var(--ha-transition-fast) !important;
}

.shareDivArea a:hover {
    transform: scale(1.15);
}
