/* ==========================================================================
   Meksim — Başlıktaki hesap öğesi (Giriş Yap / üye menüsü). Her sayfada.
   İki hâlin iskeleti sunucudan gelir, hangisinin görüneceğini hesap.js seçer.
   ========================================================================== */

.hesap { position: relative; flex: none; }
/* hidden niteliği display kurallarına yenilmesin */
.hesap [hidden] { display: none !important; }
.hesap .ik { width: 18px; height: 18px; flex: none; }

.hesap__giris {
  display: inline-flex; align-items: center; gap: 8px;
  height: 42px; padding: 0 16px 0 13px;
  border: 1.5px solid var(--line); border-radius: 999px;
  background: #fff;
  font-family: var(--font-display); font-weight: 600; font-size: 14px; color: var(--navy-800);
  white-space: nowrap;
  transition: border-color .22s var(--ease), color .22s var(--ease), transform .22s var(--ease), box-shadow .22s var(--ease);
}
.hesap__giris:hover, .hesap__giris[aria-current="page"] { border-color: var(--orange); color: var(--orange); }
.hesap__giris:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.hesap__giris:focus-visible, .hesap__dugme:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }

.hesap__dugme {
  display: inline-flex; align-items: center; gap: 8px;
  height: 42px; padding: 0 12px 0 4px;
  border: 1.5px solid var(--line); border-radius: 999px;
  background: #fff; color: var(--navy-800);
  transition: border-color .22s var(--ease), box-shadow .22s var(--ease);
}
.hesap__dugme:hover, .hesap__dugme[aria-expanded="true"] { border-color: var(--orange); box-shadow: var(--shadow-sm); }
.hesap__avatar {
  display: grid; place-items: center; flex: none;
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--grad-brand); color: #fff;
  font-family: var(--font-display); font-size: 12.5px; font-weight: 700; letter-spacing: .02em;
}
.hesap__ad {
  max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-family: var(--font-display); font-weight: 600; font-size: 14px;
}
.hesap__dugme > .ik { width: 15px; height: 15px; color: var(--muted); transition: transform .22s var(--ease); }
.hesap__dugme[aria-expanded="true"] > .ik { transform: rotate(180deg); }

.hesap__acilir {
  position: absolute; top: calc(100% + 12px); right: 0; z-index: 130;
  width: 260px; padding: 7px;
  border: 1px solid var(--line); border-radius: 16px;
  background: #fff; box-shadow: var(--shadow-lg);
  animation: hesapAc .22s var(--ease);
}
@keyframes hesapAc { from { opacity: 0; transform: translateY(-8px); } }
.hesap__acilir::before {
  content: ""; position: absolute; top: -6px; right: 22px;
  width: 12px; height: 12px; transform: rotate(45deg);
  background: #fff; border-left: 1px solid var(--line); border-top: 1px solid var(--line);
  border-radius: 2px;
}
.hesap__kim { display: flex; flex-direction: column; gap: 2px; padding: 10px 11px 12px; margin-bottom: 5px; border-bottom: 1px solid var(--line); }
.hesap__kim strong { font-family: var(--font-display); font-size: 15px; color: var(--ink); overflow-wrap: anywhere; }
.hesap__kim span { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hesap__acilir a, .hesap__acilir button {
  display: flex; align-items: center; gap: 11px; width: 100%;
  padding: 10px 11px; border-radius: 11px;
  font-size: 14px; font-weight: 500; color: var(--body); text-align: start;
  transition: background .18s var(--ease), color .18s var(--ease);
}
.hesap__acilir a:hover, .hesap__acilir button:hover { background: var(--bg-alt); color: var(--ink); }
.hesap__acilir a .ik, .hesap__acilir button .ik { color: var(--orange); }
.hesap__acilir button { margin-top: 4px; border-top: 1px solid var(--line); border-radius: 0 0 11px 11px; padding-top: 12px; }

.mk-rtl .hesap__acilir { right: auto; left: 0; }
.mk-rtl .hesap__acilir::before { right: auto; left: 22px; }

/* Başlık dar: yazılar düşer, yuvarlak düğme kalır (dil seçiciyle aynı boy) */
@media (max-width: 1180px) {
  .hesap__giris { width: 42px; padding: 0; justify-content: center; }
  .hesap__giris span, .hesap__ad, .hesap__dugme > .ik { display: none; }
  .hesap__dugme { width: 42px; padding: 0; justify-content: center; }
}
@media (max-width: 980px) {
  .hesap__giris, .hesap__dugme { width: 38px; height: 38px; }
  .hesap__avatar { width: 30px; height: 30px; font-size: 12px; }
}
