/* =========================================================
   HEADER MOBILE MENU FINAL v66
   Sadece mobil drawer ve desktop geçiş davranışı.
========================================================= */

/* Desktopta mobil drawer hiçbir koşulda görünmez. */
@media (min-width:1081px){
  .fe-mobile-drawer{
    display:none!important;
    opacity:0!important;
    visibility:hidden!important;
    pointer-events:none!important;
  }
  .fe-mobile-drawer-panel{
    transform:translateX(100%)!important;
  }
}

/* Tablet / mobil */
@media (max-width:1080px){
  .fe-mobile-drawer{
    display:block!important;
  }

  .fe-mobile-drawer-panel{
    width:min(390px,92vw)!important;
    max-width:92vw!important;
    background:#0f2238!important;
    color:#eef6ff!important;
    border-left:1px solid #284661!important;
    box-shadow:-20px 0 52px rgba(0,0,0,.30)!important;
  }

  .fe-mobile-drawer-head{
    min-height:66px!important;
    padding:12px 18px!important;
    border-bottom:1px solid #29445f!important;
    background:#10243a!important;
  }

  .fe-mobile-drawer-head strong{
    color:#f4f8fc!important;
    font-size:19px!important;
    font-weight:800!important;
  }

  .fe-mobile-drawer-head button{
    width:36px!important;
    height:36px!important;
    color:#f2f7fb!important;
    border-radius:10px!important;
    font-size:28px!important;
  }

  .fe-mobile-drawer nav{
    padding:4px 18px 0!important;
    background:#0f2238!important;
  }

  .fe-mobile-drawer nav a{
    min-height:58px!important;
    grid-template-columns:38px minmax(0,1fr) 14px!important;
    gap:11px!important;
    padding:7px 0!important;
    color:#eef5fb!important;
    border-color:#29445f!important;
    font-size:15px!important;
    font-weight:780!important;
  }

  .fe-mobile-nav-icon{
    width:36px!important;
    height:36px!important;
    background:#173653!important;
    color:#72bfff!important;
  }

  .fe-mobile-nav-icon svg{
    width:20px!important;
    height:20px!important;
  }

  .fe-mobile-nav-chevron{
    color:#6f93b5!important;
    font-size:23px!important;
  }

  /* Alt aksiyonlar aynı ailede, beyaz blok yok. */
  .fe-mobile-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:8px!important;
    padding:10px 18px max(12px,env(safe-area-inset-bottom))!important;
    margin:0!important;
    background:#0c1d31!important;
    border-top:1px solid #29445f!important;
  }

  .fe-theme-toggle-mobile{
    grid-column:1 / -1!important;
    min-height:46px!important;
    height:46px!important;
    padding:0 12px!important;
    border:1px solid #2d4c69!important;
    border-radius:11px!important;
    background:#132a43!important;
    color:#eef6ff!important;
    box-shadow:none!important;
  }

  .fe-theme-toggle-mobile>.fe-theme-toggle-icon{
    width:30px!important;
    height:30px!important;
    background:#183b5c!important;
    color:#72bfff!important;
  }

  .fe-theme-toggle-copy strong{
    color:#eef6ff!important;
    font-size:12px!important;
  }

  .fe-theme-toggle-copy small{
    color:#9db3c8!important;
    font-size:9px!important;
  }

  .fe-mobile-login-btn,
  .fe-mobile-portfolio-btn{
    height:44px!important;
    min-height:44px!important;
    border-radius:11px!important;
    font-size:12px!important;
    font-weight:800!important;
    box-shadow:none!important;
  }

  .fe-mobile-login-btn{
    border:1px solid #35536f!important;
    background:#132a43!important;
    color:#eef6ff!important;
  }

  .fe-mobile-portfolio-btn{
    border:1px solid #1785f5!important;
    background:linear-gradient(135deg,#188aff,#0877ea)!important;
    color:#fff!important;
  }

  /* Drawer açıkken global floating butonlar menünün üstüne binmesin. */
  body.fe-lock .fe-global-float-stack{
    opacity:0!important;
    visibility:hidden!important;
    pointer-events:none!important;
  }
}

/* Küçük telefon */
@media (max-width:480px){
  .fe-mobile-drawer-panel{
    width:calc(100vw - 18px)!important;
    max-width:calc(100vw - 18px)!important;
  }

  .fe-mobile-drawer-head{
    min-height:60px!important;
    padding:10px 14px!important;
  }

  .fe-mobile-drawer nav{
    padding-left:14px!important;
    padding-right:14px!important;
  }

  .fe-mobile-drawer nav a{
    min-height:54px!important;
    grid-template-columns:34px minmax(0,1fr) 12px!important;
    gap:9px!important;
    font-size:14px!important;
  }

  .fe-mobile-nav-icon{
    width:33px!important;
    height:33px!important;
  }

  .fe-mobile-actions{
    padding-left:14px!important;
    padding-right:14px!important;
  }
}

/* Kısa ekranlarda menü sığsın, alt butonlar ezilmesin */
@media (max-height:720px) and (max-width:1080px){
  .fe-mobile-drawer-head{
    min-height:54px!important;
    padding-top:8px!important;
    padding-bottom:8px!important;
  }

  .fe-mobile-drawer nav a{
    min-height:48px!important;
    padding-top:5px!important;
    padding-bottom:5px!important;
  }

  .fe-mobile-nav-icon{
    width:31px!important;
    height:31px!important;
  }

  .fe-mobile-actions{
    padding-top:8px!important;
    padding-bottom:max(8px,env(safe-area-inset-bottom))!important;
  }

  .fe-theme-toggle-mobile{
    height:42px!important;
    min-height:42px!important;
  }

  .fe-mobile-login-btn,
  .fe-mobile-portfolio-btn{
    height:40px!important;
    min-height:40px!important;
  }
}


/* =========================================================
   v67 — MOBİL DRAWER GERÇEK GÜNDÜZ/GECE + DİL MENÜSÜ
   Admin'de seçili diller burada otomatik listelenir.
========================================================= */

@media(max-width:1080px){

  /* ---------- Mobile language dropdown ---------- */
  .fe-mobile-language{
    grid-column:1 / -1;
    width:100%;
    min-width:0;
  }

  .fe-mobile-language>summary{
    list-style:none;
    min-height:46px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    padding:7px 12px;
    border:1px solid #2d4c69;
    border-radius:11px;
    background:#132a43;
    color:#eef6ff;
    cursor:pointer;
    user-select:none;
  }

  .fe-mobile-language>summary::-webkit-details-marker{
    display:none;
  }

  .fe-mobile-language-leading{
    display:flex;
    align-items:center;
    gap:10px;
    min-width:0;
  }

  .fe-mobile-language-flag{
    width:30px;
    height:30px;
    display:grid;
    place-items:center;
    flex:0 0 30px;
    border-radius:9px;
    background:#183b5c;
    border:1px solid #315674;
    font-size:18px;
    line-height:1;
  }

  .fe-mobile-language-copy{
    display:grid;
    gap:1px;
    min-width:0;
    text-align:left;
  }

  .fe-mobile-language-copy strong{
    font-size:12px;
    line-height:1.2;
    color:#eef6ff;
  }

  .fe-mobile-language-copy small{
    font-size:9px;
    line-height:1.2;
    color:#9db3c8;
  }

  .fe-mobile-language-chevron{
    font-size:16px;
    color:#83a6c4;
    transition:transform .18s ease;
  }

  .fe-mobile-language[open] .fe-mobile-language-chevron{
    transform:rotate(180deg);
  }

  .fe-mobile-language-list{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:6px;
    padding:7px 0 0;
  }

  .fe-mobile-language-list>a{
    min-width:0;
    min-height:44px;
    display:flex;
    align-items:center;
    gap:8px;
    padding:7px 9px;
    border:1px solid #294762;
    border-radius:10px;
    background:#10263d;
    color:#e9f3fb;
    text-decoration:none;
  }

  .fe-mobile-language-list>a.active{
    border-color:#248fff;
    background:#153653;
    box-shadow:inset 0 0 0 1px rgba(36,143,255,.12);
  }

  .fe-mobile-language-option-flag{
    font-size:18px;
    line-height:1;
    flex:0 0 auto;
  }

  .fe-mobile-language-list>a>span:nth-child(2){
    display:grid;
    gap:1px;
    min-width:0;
    flex:1;
  }

  .fe-mobile-language-list>a strong{
    font-size:10px;
    line-height:1.15;
  }

  .fe-mobile-language-list>a small{
    font-size:8px;
    line-height:1.1;
    opacity:.65;
  }

  .fe-mobile-language-list>a>b{
    width:18px;
    height:18px;
    display:grid;
    place-items:center;
    border-radius:50%;
    background:#1889ff;
    color:#fff;
    font-size:9px;
  }

  /* =====================================================
     LIGHT / GÜNDÜZ
     Drawer artık gerçekten açık temaya geçer.
  ===================================================== */
  html[data-fe-theme="light"] .fe-mobile-drawer-panel,
  html:not([data-fe-theme]) .fe-mobile-drawer-panel{
    background:#f8fbff!important;
    color:#102d4a!important;
    border-left-color:#d7e4f0!important;
    box-shadow:-18px 0 48px rgba(24,58,93,.16)!important;
  }

  html[data-fe-theme="light"] .fe-mobile-drawer-head,
  html:not([data-fe-theme]) .fe-mobile-drawer-head{
    background:#fff!important;
    border-bottom-color:#dce8f3!important;
  }

  html[data-fe-theme="light"] .fe-mobile-drawer-head strong,
  html:not([data-fe-theme]) .fe-mobile-drawer-head strong{
    color:#102d4a!important;
  }

  html[data-fe-theme="light"] .fe-mobile-drawer-head button,
  html:not([data-fe-theme]) .fe-mobile-drawer-head button{
    color:#173b5e!important;
    background:#f3f8fc!important;
  }

  html[data-fe-theme="light"] .fe-mobile-drawer nav,
  html:not([data-fe-theme]) .fe-mobile-drawer nav{
    background:#f8fbff!important;
  }

  html[data-fe-theme="light"] .fe-mobile-drawer nav a,
  html:not([data-fe-theme]) .fe-mobile-drawer nav a{
    color:#143451!important;
    border-color:#dce8f3!important;
  }

  html[data-fe-theme="light"] .fe-mobile-nav-icon,
  html:not([data-fe-theme]) .fe-mobile-nav-icon{
    background:#eaf4ff!important;
    color:#147edb!important;
  }

  html[data-fe-theme="light"] .fe-mobile-nav-chevron,
  html:not([data-fe-theme]) .fe-mobile-nav-chevron{
    color:#7d9ab5!important;
  }

  html[data-fe-theme="light"] .fe-mobile-actions,
  html:not([data-fe-theme]) .fe-mobile-actions{
    background:#fff!important;
    border-top-color:#dce8f3!important;
  }

  html[data-fe-theme="light"] .fe-theme-toggle-mobile,
  html:not([data-fe-theme]) .fe-theme-toggle-mobile{
    background:#f5f9fd!important;
    border-color:#d6e4ef!important;
    color:#143451!important;
  }

  html[data-fe-theme="light"] .fe-theme-toggle-mobile>.fe-theme-toggle-icon,
  html:not([data-fe-theme]) .fe-theme-toggle-mobile>.fe-theme-toggle-icon{
    background:#e8f3ff!important;
    color:#147edb!important;
  }

  html[data-fe-theme="light"] .fe-theme-toggle-copy strong,
  html:not([data-fe-theme]) .fe-theme-toggle-copy strong{
    color:#143451!important;
  }

  html[data-fe-theme="light"] .fe-theme-toggle-copy small,
  html:not([data-fe-theme]) .fe-theme-toggle-copy small{
    color:#718aa1!important;
  }

  html[data-fe-theme="light"] .fe-mobile-login-btn,
  html:not([data-fe-theme]) .fe-mobile-login-btn{
    background:#f7fbff!important;
    border-color:#cbddea!important;
    color:#153653!important;
  }

  /* Portfolio stays brand-blue in both themes. */
  html[data-fe-theme="light"] .fe-mobile-portfolio-btn,
  html:not([data-fe-theme]) .fe-mobile-portfolio-btn{
    color:#fff!important;
  }

  /* Light mobile language control */
  html[data-fe-theme="light"] .fe-mobile-language>summary,
  html:not([data-fe-theme]) .fe-mobile-language>summary{
    background:#f5f9fd!important;
    border-color:#d6e4ef!important;
    color:#143451!important;
  }

  html[data-fe-theme="light"] .fe-mobile-language-flag,
  html:not([data-fe-theme]) .fe-mobile-language-flag{
    background:#fff!important;
    border-color:#d6e4ef!important;
  }

  html[data-fe-theme="light"] .fe-mobile-language-copy strong,
  html:not([data-fe-theme]) .fe-mobile-language-copy strong{
    color:#143451!important;
  }

  html[data-fe-theme="light"] .fe-mobile-language-copy small,
  html:not([data-fe-theme]) .fe-mobile-language-copy small{
    color:#718aa1!important;
  }

  html[data-fe-theme="light"] .fe-mobile-language-chevron,
  html:not([data-fe-theme]) .fe-mobile-language-chevron{
    color:#7995ae!important;
  }

  html[data-fe-theme="light"] .fe-mobile-language-list>a,
  html:not([data-fe-theme]) .fe-mobile-language-list>a{
    background:#fff!important;
    border-color:#d7e4f0!important;
    color:#173956!important;
  }

  html[data-fe-theme="light"] .fe-mobile-language-list>a.active,
  html:not([data-fe-theme]) .fe-mobile-language-list>a.active{
    background:#edf6ff!important;
    border-color:#3097f3!important;
  }

  /* =====================================================
     DARK / GECE — v66 görünümünü kilitler
  ===================================================== */
  html[data-fe-theme="dark"] .fe-mobile-drawer-panel{
    background:#0f2238!important;
    color:#eef6ff!important;
  }
  html[data-fe-theme="dark"] .fe-mobile-drawer-head{
    background:#10243a!important;
    border-bottom-color:#29445f!important;
  }
  html[data-fe-theme="dark"] .fe-mobile-drawer nav{
    background:#0f2238!important;
  }
  html[data-fe-theme="dark"] .fe-mobile-actions{
    background:#0c1d31!important;
    border-top-color:#29445f!important;
  }
}

@media(max-width:520px){
  .fe-mobile-language-list{
    grid-template-columns:1fr 1fr;
  }
}


/* =========================================================
   v172 — MOBİL ORTAK GERİ TUŞU FINAL
   Tüm uygun iç sayfalarda aynı oranlı, sade ikon görünümü.
========================================================= */
.fe-mobile-detail-back{display:none}

@media(max-width:1080px){
  .fe-mobile-detail-back[data-fe-detail-back]{
    display:inline-flex!important;
    flex:0 0 44px!important;
    width:44px!important;
    min-width:44px!important;
    height:44px!important;
    align-items:center!important;
    justify-content:flex-start!important;
    padding:0!important;
    margin:0!important;
    border:0!important;
    border-radius:0!important;
    background:transparent!important;
    box-shadow:none!important;
    color:#fff!important;
    cursor:pointer!important;
    -webkit-appearance:none!important;
    appearance:none!important;
    -webkit-tap-highlight-color:transparent!important;
  }
  .fe-mobile-detail-back .fe-mobile-detail-back-icon{
    width:31px!important;
    height:31px!important;
    display:block!important;
    stroke-width:1.8!important;
    color:currentColor!important;
    transition:transform .16s ease,opacity .16s ease!important;
  }
  .fe-mobile-detail-back:active .fe-mobile-detail-back-icon{
    transform:translateX(-2px)!important;
    opacity:.76!important;
  }
  .fe-mobile-detail-back:focus-visible{
    outline:2px solid currentColor!important;
    outline-offset:3px!important;
    border-radius:8px!important;
  }
  .fe-mobile-detail-back + .fe-logo.fe-logo-detail-page,
  .fe-logo.fe-logo-detail-page{display:none!important}
  .fe-header-inner:has(.fe-mobile-detail-back){gap:10px!important}

  html[data-fe-theme="light"] .fe-mobile-detail-back,
  html:not([data-fe-theme]) .fe-mobile-detail-back{color:#142f49!important}
  html[data-fe-theme="dark"] .fe-mobile-detail-back{color:#f7fbff!important}
}

@media(max-width:480px){
  .fe-mobile-detail-back[data-fe-detail-back]{
    flex-basis:42px!important;
    width:42px!important;
    min-width:42px!important;
    height:42px!important;
  }
  .fe-mobile-detail-back .fe-mobile-detail-back-icon{
    width:29px!important;
    height:29px!important;
  }
}


/* =========================================================
   v175 — MOBİL/DESKTOP MENÜ GEÇİŞ STABİLİTESİ
   Drawer breakpoint, basılı/odak durumları ve resize geçişi.
========================================================= */
@media (max-width:1080px){
  .fe-mobile-drawer{
    will-change:opacity!important;
  }
  .fe-mobile-drawer-panel{
    will-change:transform!important;
    backface-visibility:hidden!important;
    -webkit-backface-visibility:hidden!important;
  }
  html[data-fe-theme="dark"] .fe-mobile-drawer nav a:active,
  html[data-fe-theme="dark"] .fe-mobile-drawer nav a:focus-visible{
    background:#17324f!important;
    color:#f4f9ff!important;
    outline:none!important;
  }
  html[data-fe-theme="light"] .fe-mobile-drawer nav a:active,
  html[data-fe-theme="light"] .fe-mobile-drawer nav a:focus-visible,
  html:not([data-fe-theme]) .fe-mobile-drawer nav a:active,
  html:not([data-fe-theme]) .fe-mobile-drawer nav a:focus-visible{
    background:#eaf4ff!important;
    color:#103451!important;
    outline:none!important;
  }
}
@media (min-width:1081px){
  body.fe-lock{overflow:auto!important}
}
