/* ============================================================
   engelsiz-mobile.css
   Engelsiz Hacettepe – Mobil Uyumluluk Düzeltmeleri
   Bu dosyayı engelsiz.css'in SONUNA ekleyin veya
   master.blade.php'de ayrı bir <link> olarak yükleyin.
   ============================================================ */

/* ── GENEL SIFIRLAMA ──────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

img, video, svg {
    max-width: 100%;
    height: auto;
}

/* ── TOPBAR ───────────────────────────────────────────────── */
@media (max-width: 768px) {
    .topbar { display: none; }          /* Küçük ekranda üst bar gizlenir */
}

/* ── NAVBAR / HEADER ──────────────────────────────────────── */
@media (max-width: 900px) {
    .navbar .inner {
        padding: 0 16px;
        height: 64px;
    }

    /* Desktop nav linklerini gizle */
    .navbar nav {
        display: none !important;
    }

    /* Hamburger her zaman görünsün */
    .hamburger {
        display: flex !important;
        flex-direction: column;
        gap: 5px;
        cursor: pointer;
        background: none;
        border: none;
        padding: 8px;
    }

    .hamburger span {
        display: block;
        width: 24px;
        height: 2px;
        background: var(--red, #B5121B);
        border-radius: 2px;
        transition: .3s;
    }

    /* Logo yazısı taşmasın */
    .logo-text .site-name {
        font-size: 13px;
    }
    .logo-text .site-sub {
        font-size: 11px;
    }
}

/* Mobile menü açık hali */
#mobile-menu {
    display: none;
    flex-direction: column;
    background: #fff;
    border-top: 2px solid var(--red, #B5121B);
    padding: 8px 0 16px;
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
}

#mobile-menu.open {
    display: flex;
}

#mobile-menu a {
    padding: 12px 20px;
    font-size: 15px;
    color: #222;
    text-decoration: none;
    border-bottom: 1px solid #f0f0f0;
    transition: background .15s;
}

#mobile-menu a:hover,
#mobile-menu a:focus {
    background: #faf0f0;
    color: var(--red, #B5121B);
    outline: 2px solid var(--red, #B5121B);
    outline-offset: -2px;
}

/* ── SLIDER ───────────────────────────────────────────────── */
.slider-wrap {
    position: relative;
    width: 100%;
    overflow: hidden;
}

/* Masaüstü yüksekliği */
.slider-wrap { height: 520px; }

@media (max-width: 900px) {
    .slider-wrap { height: 420px; }
}

@media (max-width: 600px) {
    /* Mobilde sabit yükseklik yerine aspect-ratio kullan */
    .slider-wrap {
        height: auto;
        aspect-ratio: 16 / 9;
        min-height: 220px;
        max-height: 380px;
    }
}

.slider-track {
    display: flex;
    height: 100%;
    transition: transform .5s ease;
    will-change: transform;
}

.slide {
    position: relative;
    min-width: 100%;
    height: 100%;
    overflow: hidden;
    flex-shrink: 0;
}

/* Slider görseli her zaman tam kaplar */
.slide-img {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    overflow: hidden;
}

.slide-img img,
.slider-wrap img {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    object-fit: cover !important;
    object-position: center !important;
    display: block !important;
}

.slide-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,.15) 0%,
        rgba(0,0,0,.55) 60%,
        rgba(0,0,0,.75) 100%
    );
    pointer-events: none;
}

/* Slide içeriği */
.slide-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 32px 40px;
    color: #fff;
    z-index: 2;
}

@media (max-width: 600px) {
    .slide-content {
        padding: 20px 16px;
    }

    .slide-content h2 {
        font-size: clamp(18px, 5vw, 28px);
        line-height: 1.3;
        margin-bottom: 8px;
    }

    .slide-content p {
        font-size: 13px;
        line-height: 1.5;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        margin-bottom: 12px;
    }

    .slide-badge {
        font-size: 11px;
        padding: 3px 10px;
        margin-bottom: 8px;
    }

    .slide-btn {
        font-size: 13px;
        padding: 9px 18px;
    }
}

/* Ok butonları mobilde daha küçük */
@media (max-width: 600px) {
    .slider-prev,
    .slider-next {
        width: 36px;
        height: 36px;
        font-size: 16px;
        top: 50%;
        transform: translateY(-50%);
    }

    .slider-prev { left: 8px; }
    .slider-next { right: 8px; }

    .slider-dots { bottom: 12px; }
    .slider-progress { height: 3px; }
}

/* ── ARAMA BANDI ──────────────────────────────────────────── */
@media (max-width: 600px) {
    .search-band { padding: 10px 12px; }

    .search-band-btn {
        font-size: 13px;
        padding: 10px 14px;
        width: 100%;
        justify-content: flex-start;
        gap: 8px;
    }

    .search-band-btn kbd {
        display: none; /* Mobilde CTRL+K gösterme */
    }
}

/* ── HIZLI ERİŞİM ─────────────────────────────────────────── */
@media (max-width: 900px) {
    .quick-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .quick-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .quick-card {
        padding: 16px 12px;
    }

    .quick-card h3 {
        font-size: 13px;
    }

    .quick-card p {
        font-size: 12px;
        display: none; /* Çok küçük ekranda açıklama gizlenir */
    }

    .qc-icon {
        width: 44px;
        height: 44px;
        margin-bottom: 8px;
    }
}

/* ── DUYURULAR ────────────────────────────────────────────── */
@media (max-width: 600px) {
    .duyuru-item {
        padding: 14px 12px;
        gap: 12px;
    }

    .duyuru-date {
        min-width: 44px;
        padding: 6px 8px;
    }

    .duyuru-date .day { font-size: 20px; }
    .duyuru-date .mon { font-size: 11px; }

    .duyuru-content h3 {
        font-size: 14px;
        line-height: 1.4;
    }

    .duyuru-content p {
        font-size: 12px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

/* ── ETKİNLİKLER ──────────────────────────────────────────── */
@media (max-width: 900px) {
    .etk-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }
}

@media (max-width: 560px) {
    .etk-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .etk-card { border-radius: 10px; }

    .etk-img {
        height: 180px;
    }
}

/* ── İSTATİSTİKLER ────────────────────────────────────────── */
@media (max-width: 900px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
        padding: 24px 16px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        padding: 20px 12px;
    }

    .stat-item { padding: 16px 10px; }
    .stat-num  { font-size: 28px; }
    .stat-label{ font-size: 11px; }
    .stat-icon { font-size: 24px; }
}

/* ── HİZMETLER ────────────────────────────────────────────── */
@media (max-width: 900px) {
    .hiz-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }
}

@media (max-width: 480px) {
    .hiz-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .hiz-card {
        padding: 20px 16px;
        display: flex;
        flex-direction: column;
        gap: 6px;
    }
}

/* ── SSS (FAQ) ────────────────────────────────────────────── */
@media (max-width: 600px) {
    .faq-q {
        font-size: 14px;
        padding: 14px 16px;
        text-align: left;
        line-height: 1.4;
    }

    .faq-a {
        font-size: 13px;
        padding: 12px 16px;
        line-height: 1.6;
    }
}

/* ── CTA BÖLÜMÜ ───────────────────────────────────────────── */
@media (max-width: 600px) {
    .cta-section {
        padding: 40px 16px;
        text-align: center;
    }

    .cta-section h2 { font-size: 22px; }
    .cta-section p  { font-size: 13px; }

    .cta-btns {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .cta-btn-w,
    .cta-btn-t {
        width: 100%;
        justify-content: center;
        padding: 13px 20px;
        font-size: 14px;
    }
}

/* ── FOOTER ───────────────────────────────────────────────── */
@media (max-width: 900px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }
}

@media (max-width: 560px) {
    .footer-inner { padding: 32px 16px 16px; }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
        gap: 12px;
        font-size: 12px;
    }

    .footer-bottom div {
        justify-content: center;
        flex-wrap: wrap;
        gap: 10px;
    }
}

/* ── ERİŞİLEBİLİRLİK PANELİ (a11y) — SADECE MOBİL ────────── */
/*
   engelsiz.css mantığı:
     #a11y-toggle  → position:fixed; right:0; top:50%; writing-mode:vertical-rl
     #a11y-panel   → position:fixed; right:-320px; width:300px
     #a11y-panel.open → right:0

   Mobilde yapılan tek değişiklik:
   - Toggle butonu yatay, sağ-alt köşe
   - Panel tam ekran genişliğinde açılır (right:-100vw → right:0)
   - Açma/kapama .open class'ı JS'de aynen çalışmaya devam eder
*/
@media (max-width: 600px) {

    /* Toggle: dikey yazıyı kaldır, sağ alta taşı */
    #a11y-toggle {
        writing-mode: initial !important;
        transform: none !important;
        top: auto !important;
        bottom: 80px !important;
        right: 0 !important;
        border-radius: 8px 0 0 8px !important;
        padding: 10px 12px !important;
        font-size: 11px !important;
        letter-spacing: .5px !important;
        line-height: 1.4 !important;
        box-shadow: -2px 2px 12px rgba(0,0,0,.25) !important;
    }

    /* Panel: 300px yerine tam ekran genişliğinde aç.
       .open class gelince right:0 olur — JS'e dokunmuyoruz. */
    #a11y-panel {
        width: 100% !important;
        right: -100% !important;    /* kapalı: tamamen dışarı */
        overflow-y: auto;
        overscroll-behavior: contain;
        max-height: 100svh;
    }

    #a11y-panel.open {
        right: 0 !important;
    }

    /* Kapatma butonu — büyük dokunma hedefi (WCAG 44x44) */
    .a11y-close {
        min-width: 44px !important;
        min-height: 44px !important;
        font-size: 22px !important;
        display: flex !important;
        align-items: center;
        justify-content: center;
    }
}

/* Backdrop — sadece JS .visible ekleyince görünür.
   Masaüstünde hiçbir etkisi yok (display:none kalır). */
#a11y-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.5);
    z-index: 9998;   /* panel z-index:9999 altında */
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}
#a11y-backdrop.visible { display: block; }

/* ── ARAMA OVERLAY ────────────────────────────────────────── */
@media (max-width: 600px) {
    .search-fullscreen {
        padding: 0;
    }

    .search-fs-top {
        padding: 14px 16px;
        font-size: 13px;
    }

    .search-input-wrap {
        padding: 12px 16px;
    }

    .search-input-wrap input {
        font-size: 16px; /* iOS'ta zoom'u önler */
    }

    .search-body {
        padding: 16px;
    }

    .search-tags {
        gap: 8px;
    }

    .search-tags span {
        font-size: 12px;
        padding: 6px 10px;
    }

    .search-quick-links {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .search-quick-item {
        padding: 12px;
        font-size: 12px;
    }

    .sqi-icon {
        font-size: 20px;
        margin-bottom: 6px;
    }
}

/* ── TTS ÇUBUĞU ───────────────────────────────────────────── */
@media (max-width: 600px) {
    #tts-bar {
        font-size: 13px;
        padding: 8px 12px;
        flex-wrap: wrap;
        gap: 6px;
    }

    #tts-bar button {
        padding: 6px 12px;
        font-size: 12px;
    }
}

/* ── SECTION GENEL BOŞLUKLAR ──────────────────────────────── */
@media (max-width: 600px) {
    .section,
    .quick-section {
        padding: 32px 0;
    }

    .section-inner,
    .inner {
        padding-left: 16px;
        padding-right: 16px;
    }

    .sec-hdr {
        margin-bottom: 20px;
    }

    .sec-hdr h2 {
        font-size: 20px;
    }
}

/* ── ERİŞİLEBİLİRLİK – FOCUS ──────────────────────────────── */
/* Yüksek kontrast ve klavye kullanıcıları için */
:focus-visible {
    outline: 3px solid var(--red, #B5121B) !important;
    outline-offset: 3px;
    border-radius: 4px;
}

/* Dokunma hedefi minimum 44×44 (WCAG 2.5.5) */
button,
a,
[role="button"] {
    min-height: 44px;
    min-width: 44px;
}

/* Metin ölçekleme kırılmasını önle */
html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}
