/**
 * NOPE360 V3 — Ana Layout Düzeltmeleri
 * ---------------------------------------------------------------------------
 * Yükleme sırası (index.php): en son → mevcut kuralları geçersiz kılar.
 */

/* ── NAVBAR: menüyü ortala, logo & aksiyonlar yanlara ─────────────────── */
header .nav-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

/* Menü orta bloğu — hem soldan hem sağdan otomatik boşlukla ortalanır */
header .nav-row #nav {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1 1 auto;
    gap: 22px;
    margin: 0 auto;
}

/* Logo ile menü arasına minimum güvenlik boşluğu */
header .nav-row .brand {
    margin-right: 14px;
    flex-shrink: 0;
}

/* Sağdaki aksiyonlar sıkışmasın */
header .nav-row .nav-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Mobil: navbar linkleri (masaüstü menü) gizli — hamburger ile açılır */
@media (max-width: 960px) {
    header .nav-row {
        justify-content: space-between;
        gap: 12px;
        min-height: 64px;
    }
    /* Masaüstü menüsünü mobilde tamamen gizle;
       hamburger butonuyla açılınca .open class'ı ile geri gelir. */
    header .nav-row #nav {
        display: none !important;
        flex: none;
        margin: 0;
    }
    header .nav-row #nav.open {
        display: flex !important;
        flex-direction: column;
        align-items: stretch;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        padding: 16px 20px;
        gap: 4px;
        border-bottom: 1px solid #e2e8f0;
        max-height: 78vh;
        overflow: auto;
        z-index: 40;
        box-shadow: 0 12px 24px -8px rgba(15,23,42,.15);
    }
    /* Hamburger butonu ana giriş noktası kalsın */
    header #menu-toggle {
        display: block !important;
        margin: 0;
        padding: 8px 12px;
        background: none;
        border: 0;
        font-size: 22px;
        color: #0f172a;
        cursor: pointer;
    }
    /* Sağdaki eylem butonları mobilde daha kompakt */
    header .nav-row .nav-actions {
        gap: 8px;
    }
    header .nav-row .nav-actions .btn.small {
        padding: 8px 12px;
        font-size: 12.5px;
    }
    /* Dropdown menüleri mobilde blok olarak */
    header .nav-row #nav .nav-group {
        display: block;
        width: 100%;
    }
    header .nav-row #nav .nav-drop {
        width: 100%;
        text-align: left;
    }
    header .nav-row #nav .dropdown {
        position: static;
        padding-left: 14px;
    }
}

/* ── Ekosistem bölümü (ana sayfa) ───────────────────────────────────── */
.eco-section { padding: 80px 0 30px; }
.eco-head { max-width: 720px; margin-bottom: 34px; }
.eco-head h2 { margin: 10px 0 12px; }
.eco-head p { margin: 0; }
.eco-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}
.eco-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 28px 26px 22px;
    background: linear-gradient(160deg, var(--eco-tint, #eff6ff), #fff 70%);
    border: 1px solid #dbe4f0;
    border-top: 4px solid var(--eco-accent, #2563eb);
    border-radius: 16px;
    color: #0f172a !important;
    text-decoration: none;
    transition: transform .18s, box-shadow .18s, border-color .18s;
}
.eco-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px -16px rgba(15, 23, 42, .28);
    border-color: var(--eco-accent, #2563eb);
}
.eco-icon {
    width: 48px; height: 48px;
    display: grid; place-items: center;
    font-size: 24px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}
.eco-card h3 { margin: 6px 0 0; font-size: 19px; color: #0f172a; }
.eco-card p { margin: 0; font-size: 13.5px; line-height: 1.65; color: #475569; flex: 1; }
.eco-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 10px;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
    font-size: 12px;
}
.eco-host { color: #64748b; font-family: ui-monospace, Consolas, monospace; }
.eco-link b { color: var(--eco-accent, #2563eb); font-weight: 700; white-space: nowrap; }
@media (max-width: 960px) {
    .eco-section { padding: 56px 0 16px; }
    .eco-grid { grid-template-columns: 1fr; }
}

/* Footer: 5 kolon (marka + 4 grup) */
@media (min-width: 961px) {
    footer .footer-main { grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr; gap: 36px; }
}

/* ── Medya / içerik detay sayfası navigasyonu ──────────────────────── */
.media-nav-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    margin: 0 0 20px;
    background: linear-gradient(135deg, #f0fdfa, #eff6ff);
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    font-size: 13px;
}
.media-nav-back {
    color: #0891b2 !important;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.media-nav-back:hover { color: #0e7490 !important; text-decoration: underline; }
.media-nav-pos {
    color: #64748b;
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: .04em;
}

.media-nav-bot {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 16px;
    margin: 40px 0 20px;
    padding-top: 24px;
    border-top: 1px solid #e2e8f0;
    align-items: stretch;
}
.media-nav-btn {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 14px 18px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    text-decoration: none;
    color: #0f172a !important;
    font-weight: 700;
    font-size: 13.5px;
    transition: all .15s;
    min-height: 64px;
}
.media-nav-btn small {
    display: block;
    font-weight: 400;
    font-size: 11.5px;
    color: #64748b;
    margin-top: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 240px;
}
.media-nav-btn.prev  { text-align: left; }
.media-nav-btn.next  { text-align: right; align-items: flex-end; }
.media-nav-btn:hover:not(.disabled) {
    border-color: #22d3ee;
    background: #f0fdfa;
    color: #0891b2 !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 14px -6px rgba(34,211,238,.35);
}
.media-nav-btn.disabled {
    opacity: .35;
    cursor: not-allowed;
    background: #f8fafc;
    color: #94a3b8 !important;
}
.media-nav-all {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 26px;
    background: linear-gradient(135deg, #0891b2, #2563eb);
    color: #fff !important;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 700;
    font-size: 13.5px;
    white-space: nowrap;
    box-shadow: 0 8px 20px -6px rgba(37,99,235,.4);
    transition: transform .1s;
    align-self: center;
}
.media-nav-all:hover { transform: translateY(-1px); }

@media (max-width: 720px) {
    .media-nav-bot {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .media-nav-btn.next { text-align: left; align-items: flex-start; }
    .media-nav-all { order: -1; }
    .media-nav-btn small { max-width: none; }
}

/* Küçük ekranlarda logo daha kompakt */
@media (max-width: 480px) {
    header .nav-row .brand-lockup {
        width: 120px !important;
        height: auto !important;
    }
    header .nav-row {
        gap: 8px;
    }
}

/* Belge (PDF) indirme butonu — içerik detay sayfası.
   layout-fix.css en son yüklendiği için visual-refresh.css'teki .btn
   kurallarını güvenle ezer. */
.btn.btn-pdf {
    gap: 10px;
    background: #d92d20;
    border-color: #d92d20;
    color: #fff;
    box-shadow: 0 6px 18px rgba(217, 45, 32, .28);
}
.btn.btn-pdf:hover {
    background: #b42318;
    border-color: #b42318;
    color: #fff;
    transform: translateY(-1px);
}
.btn.btn-pdf:focus-visible {
    outline: 2px solid #d92d20;
    outline-offset: 3px;
}
.btn.btn-pdf svg { flex: none; }
