/* =============================================================
   final-fix.css — ANEKS Medya v4
   styles.css'den SONRA yükleyin.
   ============================================================= */

/* ── 1. HAMBURGER NAV — header z-index stacking context düzeltmesi ── */
/*
 * header { position:fixed + z-index:1000 + backdrop-filter } bir stacking
 * context oluşturur. nav-menu içindeki z-index:10000 sadece bu context
 * içinde geçerlidir; root'ta efektif z-index = 1000 kalır.
 * nav-overlay body'de z-index:9999 → 9999 > 1000 → overlay linklerin
 * ÜSTÜNDE oturur → linkler tıklanamaz.
 * Çözüm: header z-index → 10001 (overlay'in üstünde)
 */
header {
    z-index: 10001 !important;
}

/* ── 5. NAV — 44pt dokunma alanı ── */
@media (max-width: 1024px) {
    .nav-menu a {
        min-height: 44px !important;
        display: flex !important;
        align-items: center !important;
        touch-action: manipulation !important;
        -webkit-tap-highlight-color: rgba(0, 207, 255, 0.12) !important;
    }
    .nav-menu .btn-login,
    .nav-menu .btn-register {
        min-height: 44px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        touch-action: manipulation !important;
    }
    .hamburger {
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        touch-action: manipulation;
    }
}

/* ── 6. SAFE AREA — iOS notch / home indicator ── */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .nav-menu {
        padding-bottom: calc(2rem + env(safe-area-inset-bottom, 0px)) !important;
    }
    #cookieBanner {
        padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px)) !important;
    }
}

/* ── 7. INPUT ZOOM ENGELİ — iOS 16px minimum ── */
@media (max-width: 768px) {
    input[type="email"],
    input[type="password"],
    input[type="text"],
    input[type="tel"],
    textarea,
    select {
        font-size: 16px !important; /* iOS: 16px altı zoom yapar */
        -webkit-text-size-adjust: 100%;
    }
}

/* ── 8. SİMÜLASYON MODAL ── */
.sim-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 20000 !important;
    display: none !important;
    justify-content: center !important;
    align-items: center !important;
}
.sim-overlay.active {
    display: flex !important;
}
@media (max-width: 480px) {
    .sim-phone {
        width: 95vw !important;
        max-width: 420px !important;
        height: 85svh !important;
        max-height: 85svh !important;
        border-radius: 24px !important;
    }
}

/* ── 9. GENEL PERFORMANS ── */
@media (max-width: 768px) {
    .floating-circle { display: none !important; }
    .phone-frame { animation: none !important; transform: none !important; }
    body::before { animation: none !important; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* ── Z-INDEX HİYERARŞİSİ (referans)
   99999 → #cookieBanner
   50000 → #teamModal
   20000 → .sim-overlay
   10001 → header  ← bu dosya
   10000 → .nav-menu (header stacking context içinde)
    9999 → .nav-overlay
    9998 → .tork-chat-window (masaüstü)
   10001 → .tork-chat-window (mobil, header ile eşit)
── */

/* ══════════════════════════════════════════════════════════════
   BÖLÜM A — RESPONSIVE BAŞLIK OTOMATİK ÖLÇEKLEME
   ══════════════════════════════════════════════════════════════ */
h1 {
    font-size: clamp(1.8rem, 6vw, 3.8rem);
    line-height: 1.15;
    overflow-wrap: break-word;
    word-break: break-word;
}
h2 {
    font-size: clamp(1.4rem, 4vw, 2.5rem);
    overflow-wrap: break-word;
}
.hero h1,
.hero-content h1 {
    font-size: clamp(1.8rem, 7vw, 3.8rem) !important;
    line-height: 1.15 !important;
    overflow-wrap: break-word !important;
}
.section-title {
    font-size: clamp(1.6rem, 5vw, 2.8rem) !important;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM B — TORK BENTO GRID (index.html #tork section)
   ══════════════════════════════════════════════════════════════ */
.tork-bento-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    max-width: 1200px;
    margin: 2rem auto 0;
    padding: 0 1rem;
}

/* Sol sütun: Bilgi bloğu */
.tork-bento-info {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.tork-bento-headline {
    background: rgba(0, 207, 255, 0.04);
    border: 1px solid rgba(0, 207, 255, 0.18);
    border-radius: 20px;
    padding: 2rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.tork-bento-headline h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(1.1rem, 2.5vw, 1.55rem);
    color: #fff;
    line-height: 1.4;
    margin-bottom: 1rem;
}

.tork-bento-headline p {
    color: rgba(255, 255, 255, 0.72);
    line-height: 1.7;
    font-size: 0.97rem;
}

/* Stat kartları alt satır */
.tork-bento-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.9rem;
}

.tork-stat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(0, 207, 255, 0.14);
    border-radius: 16px;
    padding: 1.1rem 0.8rem;
    text-align: center;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.25s ease;
}

.tork-stat-card:hover {
    background: rgba(0, 207, 255, 0.07);
    border-color: rgba(0, 207, 255, 0.35);
    transform: translateY(-3px);
}

.tork-stat-val {
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(1.3rem, 2.5vw, 1.7rem);
    font-weight: 900;
    line-height: 1;
    margin-bottom: 0.3rem;
    display: block;
}

.tork-stat-lbl {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.52);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
}

.tork-bento-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: linear-gradient(135deg, var(--cyan-primary, #00cfff), var(--cyan-secondary, #00f0c8));
    color: #071942;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 0.9rem 1.6rem;
    border-radius: 30px;
    text-decoration: none;
    transition: all 0.25s ease;
    align-self: flex-start;
    margin-top: 0.2rem;
}

.tork-bento-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(0, 207, 255, 0.45);
}

/* Sağ sütun: Görsel */
.tork-bento-visual {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    min-height: 360px;
    background: radial-gradient(ellipse at center, rgba(0, 207, 255, 0.06) 0%, rgba(7, 25, 66, 0.4) 100%);
    border: 1px solid rgba(0, 207, 255, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.tork-bento-visual::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 40%, rgba(0, 207, 255, 0.08) 0%, transparent 70%);
    pointer-events: none;
}

/* Liquid glass parıltı halkası */
.tork-bento-visual::after {
    content: '';
    position: absolute;
    top: -40px; right: -40px;
    width: 200px; height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 207, 255, 0.15) 0%, transparent 70%);
    pointer-events: none;
    animation: bentoGlow 4s ease-in-out infinite alternate;
}

@keyframes bentoGlow {
    from { opacity: 0.4; transform: scale(0.9); }
    to   { opacity: 1;   transform: scale(1.1); }
}

.tork-bento-img {
    width: 85%;
    max-width: 340px;
    height: auto;
    object-fit: contain;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 0 30px rgba(0, 207, 255, 0.25));
    animation: bentoFloat 5s ease-in-out infinite;
}

@keyframes bentoFloat {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-12px); }
}

@media (max-width: 900px) {
    .tork-bento-grid {
        grid-template-columns: 1fr;
    }
    .tork-bento-visual {
        order: -1; /* Mobilde görsel üste */
        min-height: 260px;
    }
    .tork-bento-img {
        max-width: 220px;
    }
    .tork-bento-stats {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .tork-bento-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.5rem;
    }
    .tork-stat-card { padding: 0.8rem 0.5rem; }
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM C — BLOG "TORK ÖZETLESİN" BUTONU GÜÇLENDIRILMIŞ
   ══════════════════════════════════════════════════════════════ */
.btn-ai-summary {
    background: linear-gradient(135deg,
        rgba(0, 207, 255, 0.25) 0%,
        rgba(0, 255, 136, 0.18) 50%,
        rgba(0, 207, 255, 0.22) 100%) !important;
    border: 1.5px solid rgba(0, 207, 255, 0.7) !important;
    box-shadow:
        0 0 16px rgba(0, 207, 255, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
    position: relative;
    overflow: hidden;
}

/* Shimmer sweep */
.btn-ai-summary::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 60%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    animation: aiShimmer 2.4s ease-in-out infinite;
    pointer-events: none;
}

@keyframes aiShimmer {
    0%   { left: -100%; }
    60%  { left: 140%;  }
    100% { left: 140%;  }
}

.btn-ai-summary:hover {
    background: linear-gradient(135deg,
        rgba(0, 207, 255, 0.55),
        rgba(0, 255, 136, 0.38)) !important;
    border-color: #00cfff !important;
    box-shadow: 0 0 28px rgba(0, 207, 255, 0.5) !important;
    transform: translateY(-2px);
    color: #fff !important;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM D — İLETİŞİM FORMU MAX-WIDTH & PADDING
   ══════════════════════════════════════════════════════════════ */
.forms-section {
    max-width: 700px !important;
    margin: 3rem auto 0 !important;
}

.form-input,
.form-textarea {
    padding: 0.9rem 1.1rem !important;
    font-size: 16px !important; /* iOS zoom önleme */
    border-radius: 12px !important;
}

.submit-btn {
    padding: 0.9rem 2rem !important;
    font-size: 1rem !important;
    border-radius: 30px !important;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM E — TERMİNAL TAŞMA & VİDEO ORANIM FİX
   ══════════════════════════════════════════════════════════════ */
.terminal-window {
    max-width: 95vw !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
}

.video-wrapper,
.report-video-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 0 0 12px 12px;
}

.software-video,
.report-video {
    position: absolute !important;
    top: 0 !important; left: 0 !important;
    width: 100% !important; height: 100% !important;
    object-fit: cover !important;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM F — PAKET KARTI İKON & ARALIĞI
   ══════════════════════════════════════════════════════════════ */
.pkg-icon {
    font-size: 2.4rem !important;
    max-width: 60px !important;
    margin: 0 auto 0.8rem !important;
    display: block !important;
}

.pkg-header {
    padding: 1.6rem 1.8rem 1rem !important;
}

.price-sub {
    font-size: 0.85rem !important;
    line-height: 1.45 !important;
    margin-bottom: 1rem !important;
}

.pkg-body {
    padding: 1.4rem 1.8rem !important;
}

.pkg-features li {
    font-size: 0.88rem !important;
    margin-bottom: 0.7rem !important;
}

/* Buton her zaman dipte */
.pkg-cta {
    padding: 0 1.8rem 1.8rem !important;
    margin-top: auto !important;
}

.btn-start {
    padding: 0.85rem 1rem !important;
    font-size: 0.82rem !important;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM G — AKORDİYON OVERRIDE (tüm sayfalara)
   UYARI: max-height !important KULLANILMAMALI — JS inline style ezemez
   ══════════════════════════════════════════════════════════════ */
.capability-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

/* styles.css'teki static 900px değerini sıfırla —
   JS inline style her zaman CSS'i yener (important olmadan) */
.capability-item.active .capability-content {
    max-height: 900px; /* JS set etmezse fallback */
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM H — MOBİL MODAL X BUTONU FİX (yazilim.html)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
    .modal-content {
        padding: 1.5rem !important;
        padding-top: 4.5rem !important; /* X butonuna alan — shorthand'den SONRA gelir */
    }

    .modal-close {
        position: fixed !important;  /* Scroll edilince de görünür kalır */
        top: 1.2rem !important;
        right: 1.2rem !important;
        z-index: 10002 !important;   /* header (10001) üzerinde */
        width: 44px !important;
        height: 44px !important;
    }
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM I — MICRO-INTERACTIONS & BUTON GERİ BİLDİRİMİ
   ══════════════════════════════════════════════════════════════ */

/* Tüm tıklanabilir butonlara evrensel aktif state */
button:active,
a.btn-start:active,
a.btn-ask:active,
.btn-neon-blue:active,
.btn-neon-orange:active,
.btn-neon-coffee:active,
.btn-neon-yellow:active,
.btn-login:active,
.btn-register:active,
.btn-submit:active,
.modal-btn:active {
    transform: scale(0.96) !important;
    filter: brightness(0.9);
}

/* Hover glow — neon butonlar */
.btn-neon-blue:hover   { box-shadow: 0 0 28px rgba(0,207,255,0.55) !important; }
.btn-neon-orange:hover { box-shadow: 0 0 28px rgba(255,100,0,0.55) !important; }
.btn-neon-coffee:hover { box-shadow: 0 0 28px rgba(199,141,83,0.55) !important; }
.btn-neon-yellow:hover { box-shadow: 0 0 28px rgba(255,189,0,0.55) !important; }

/* Nav linkleri hover — altı çizgi kayması */
.nav-menu a {
    position: relative;
}
.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--cyan-primary, #00cfff);
    border-radius: 2px;
    transition: width 0.25s ease;
}
.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM J — HAMBURGERİN MOBİL HIT AREA GENİŞLETMESİ
   KURAL: display:flex SADECE mobil media query içinde tanımlanır.
   Masaüstünde hamburger ASLA görünmez.
   ══════════════════════════════════════════════════════════════ */

/* 1025px ve üzeri: hamburger kesinlikle gizli */
@media (min-width: 1025px) {
    .hamburger {
        display: none !important;
    }
    /* Masaüstünde nav-menu her zaman görünür, fixed konumunu sıfırla */
    .nav-menu {
        display: flex !important;
        position: static !important;
        flex-direction: row !important;
        background: transparent !important;
        backdrop-filter: none !important;
        padding: 0 !important;
        width: auto !important;
        height: auto !important;
        top: auto !important;
        right: auto !important;
    }
}

/* 1024px ve altı: hamburger görünür + hit area genişletme */
@media (max-width: 1024px) {
    .hamburger {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        min-width: 48px !important;
        min-height: 48px !important;
        cursor: pointer !important;
        touch-action: manipulation !important;
        -webkit-tap-highlight-color: rgba(0,207,255,0.15) !important;
        padding: 8px !important;
        margin: -8px !important;
        border-radius: 10px !important;
        transition: background 0.2s ease !important;
        z-index: 10002 !important;
    }
    .hamburger:hover,
    .hamburger:active {
        background: rgba(0, 207, 255, 0.08) !important;
    }
    /* Nav menu: kapalı halde fixed panel olarak sağdan kayar */
    .nav-menu {
        display: none !important;
        position: fixed !important;
        top: 0 !important;
        right: -100% !important;
        left: auto !important;
        width: min(300px, 85vw) !important;
        height: 100svh !important;
        flex-direction: column !important;
        background: rgba(5, 8, 20, 0.98) !important;
        backdrop-filter: blur(20px) !important;
        -webkit-backdrop-filter: blur(20px) !important;
        padding: 5rem 2rem 2rem !important;
        gap: 1.2rem !important;
        z-index: 10000 !important;
        overflow-y: auto !important;
        transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        border-left: 1px solid rgba(0,207,255,0.15) !important;
    }
    .nav-menu.active {
        display: flex !important;
        right: 0 !important;
    }
    .auth-buttons {
        flex-direction: column !important;
        width: 100% !important;
    }
    .btn-login,
    .btn-register {
        width: 100% !important;
        text-align: center !important;
    }
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM K — KONTRAST İYİLEŞTİRMESİ
   ══════════════════════════════════════════════════════════════ */

/* Düşük kontrastlı alt metinleri iyileştir */
.hero-subtitle,
.hero-subtitle p {
    color: rgba(255, 255, 255, 0.88) !important;
}

.hero-subtitle span {
    color: var(--cyan-primary, #00cfff) !important;
}

/* Section alt başlıklar */
.section-subtitle,
.about-content p,
.layer-desc,
.capability-content p {
    color: rgba(255, 255, 255, 0.82) !important;
}

/* Paket feature text */
.pkg-features li span:last-child {
    color: rgba(255, 255, 255, 0.88) !important;
}

/* Blog excerpt */
.blog-excerpt {
    color: rgba(255, 255, 255, 0.80) !important;
}

/* Footer linkleri */
.footer-section a {
    color: rgba(255, 255, 255, 0.78) !important;
    transition: color 0.2s ease !important;
}
.footer-section a:hover {
    color: var(--cyan-primary, #00cfff) !important;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM L — SİMÜLASYON MODAL Z-INDEX & MOBİL UYUM
   ══════════════════════════════════════════════════════════════ */
.sim-overlay {
    z-index: 20000 !important; /* header (10001) ve TORK widget (10500) üzerinde */
}

@media (max-width: 480px) {
    .sim-phone {
        width: 94vw !important;
        max-width: 420px !important;
        height: 88svh !important;
        max-height: 88svh !important;
        border-radius: 24px !important;
    }
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM M — MODAL (yazilim.html) Z-INDEX GUARANTEE
   Her zaman TORK widget'ın üzerinde
   ══════════════════════════════════════════════════════════════ */
.modal-overlay {
    z-index: 10600 !important; /* TORK FAB (10500) ve chat window (10499) üzerinde */
}

.modal-close {
    z-index: 10601 !important;
}

/* ══════════════════════════════════════════════════════════════
   BÖLÜM N — TORK WIDGET BOTTOM (TEMİZ VERSİYON)
   Eski visibility:hidden/[style*="bottom"] mantığı kaldırıldı.
   Bottom artık tork-widget.css'te CSS ile tanımlı.
   Bu blok sadece bilgi amaçlıdır.
   ══════════════════════════════════════════════════════════════ */
/* FAB her zaman doğru pozisyonda */
.tork-toggle-btn {
    bottom: calc(var(--fab-bottom, 20px) + var(--safe-bot, 0px)) !important;
    right:  calc(var(--fab-right, 20px)  + var(--safe-rgt, 0px)) !important;
}
