/* dosya: assets/css/header.css
   (Sadece bu sayfadaki DESKTOP HEADER / TOPBAR stilleri)
*/

:root{
  --topbar-bg: #3f4f5f;
  --topbar-bg-2: #2f3f50;
  --cta: #2c74d6;
  --border: #e6e9ee;

  /* container / shell */
  --shell-w: 1060px;
  --shell-gap: 18px;
}

/* =========================
   SHELL (header container)
========================= */
.shell{
  width: min(var(--shell-w), calc(100% - (var(--shell-gap) * 2)));
  margin-inline: auto;
}
.shell--topbar{
  height: 56px;
  display:flex;
  align-items:center;
}

/* sahibinden gibi: bar full width, içerik container */
.shell.shell--topbar{
  max-width: 1200px;   /* istersen 1280 yap */
  margin: 0 auto;
  padding: 0 14px;
}

/* =========================
   TOPBAR
========================= */
.topbar{
  position: sticky;
  top:0;
  z-index: 50;
  background: linear-gradient(180deg, var(--topbar-bg) 0%, var(--topbar-bg-2) 100%);
  height: 56px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.topbar__inner{
  height: 56px;
  width: 100%;
  display:flex;
  align-items:center;
  gap:14px;
  padding: 0 10px;
}

/* logo */
.brand{
  text-decoration:none;
  display:flex;
  align-items:center;
  flex: 0 0 auto;
}
.brand__badge{
  background: #ffdc00;
  color:#111827;
  font-weight: 700;
  padding: 6px 10px;
  border-radius: 2px;
  letter-spacing: .2px;
  line-height: 1;
  box-shadow: 0 1px 0 rgba(0,0,0,.12);
}

/* search */
.topbar__search{
  flex: 1 1 auto;
  min-width: 0;
  display:flex;
  align-items:center;
  gap: 10px;
}
.topbar__search .input-group{
  flex: 1 1 auto;
  min-width: 380px;   /* küçük ekranda burası daralacak */
  max-width: 760px;   /* sağ blokla çakışmayı engeller */
}

.topbar__searchIcon{
  background: rgba(255,255,255,.12) !important;
  border: 1px solid rgba(255,255,255,.22) !important;
  color:#fff;
}
.topbar__searchInput{
  background: rgba(255,255,255,.12) !important;
  border: 1px solid rgba(255,255,255,.22) !important;
  color:#fff !important;
}
.topbar__searchInput::placeholder{ color: rgba(255,255,255,.75); }

/* (HTML’de yok ama dursun) */
.topbar__advLink{
  color: rgba(255,255,255,.9);
  text-decoration:none;
  font-size: 13px;
  white-space: nowrap;
}
.topbar__advLink:hover{ text-decoration: underline; }

/* right block */
.topbar__right{
  flex: 0 0 auto;
  margin-left: auto;
  display:flex;
  align-items:center;
  gap: 10px;
  white-space: nowrap;
}

/* user button */
.topbar__user{
  color:#fff;
  font-size: 13px;
  display:flex;
  align-items:center;
  gap: 6px;
  padding: 6px 8px;
  border-radius: 4px;
  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.18);
}
.topbar__userName{ font-weight: 600; }

/* icon buttons */
.topbar__icons{
  display:flex;
  gap: 6px;
  align-items:center;
  flex: 0 0 auto;
}
.iconbtn{
  width: 34px;
  height: 34px;
  border-radius: 4px;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.10);
  color:#fff;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  position: relative; /* badge için */
}
.iconbtn:hover{ background: rgba(255,255,255,.14); }

/* CTA */
.topbar__cta{
  background: var(--cta) !important;
  border-color: rgba(255,255,255,.15) !important;
  font-weight: 600;
  white-space: nowrap;
}

/* Bootstrap dropdown toggle caret'ını kapat (biz ikon kullanıyoruz) */
.user-dd .dropdown-toggle::after,
.msg-dd .dropdown-toggle::after,
.noti-dd .dropdown-toggle::after,
.fav-dd .dropdown-toggle::after{
  display:none !important;
}

/* dropdown genel */
.dropdown-menu{
  border-radius: 0;
  border: 1px solid #d9dee7;
  box-shadow: 0 10px 24px rgba(0,0,0,.12);
}

/* =========================
   USER DROPDOWN
========================= */
.user-dd__menu{
  width: 240px;
  padding: 0;
  margin-top: 8px;
}
.user-dd__head{
  padding: 12px 14px 10px 14px;
}
.user-dd__name{
  font-weight: 700;
  color:#1f2937;
  font-size: 14px;
}
.user-dd__item{
  padding: 10px 14px;
  font-size: 13px;
}
.user-dd__item:hover{ background:#f3f5f9; }
.user-dd__div{ margin:0; opacity: .9; }
.user-dd__logout{ color:#374151; }
.user-dd__logout i{ opacity:.75; }

/* =========================
   MESSAGES DROPDOWN (büyük panel)
========================= */
.msg-dd{ position: relative; }
.msg-dd__btn{ padding:0; }
.msg-dd__badge{
  position:absolute;
  top:-6px;
  right:-6px;
  height: 16px;
  min-width: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background:#d94141;
  color:#fff;
  font-size: 11px;
  line-height: 16px;
  font-weight: 700;
  text-align:center;
  border: 1px solid rgba(255,255,255,.6);
}

.msg-dd__menu{
  width: 620px;
  margin-top: 8px;
  border-radius: 0;
  overflow:hidden;
}

.msg-dd__tabs{
  display:flex;
  gap: 18px;
  padding: 10px 14px 0 14px;
  background:#fff;
  border-bottom: 1px solid #e6e9ee;
}
.msg-dd__tab{
  font-size: 13px;
  color:#111827;
  text-decoration:none;
  padding: 10px 0 12px 0;
  position:relative;
  white-space: nowrap;
}
.msg-dd__tab.is-active{ color:#2c74d6; }
.msg-dd__tab.is-active::after{
  content:"";
  position:absolute;
  left:0;
  bottom:-1px;
  height:2px;
  width:100%;
  background:#2c74d6;
}
.msg-dd__pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  height: 16px;
  min-width: 16px;
  padding: 0 5px;
  border-radius: 999px;
  background:#d94141;
  color:#fff;
  font-size: 11px;
  font-weight:700;
  margin-left: 6px;
}

.msg-dd__list{
  max-height: 300px;
  overflow:auto;
  background:#fff;
}
.msg-dd__row{
  display:flex;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid #eef1f5;
  text-decoration:none;
  color: inherit;
}
.msg-dd__row:hover{ background:#f7f8fb; }

.msg-dd__avatar{
  width: 40px;
  height: 40px;
  border-radius: 4px;
  background: linear-gradient(180deg,#f3f5f9,#e8ecf4);
  border: 1px solid #e5e9f2;
  flex: 0 0 auto;
}
.msg-dd__avatar--icon{
  display:flex;
  align-items:center;
  justify-content:center;
  color:#6b7280;
}
.msg-dd__body{ flex:1; min-width: 0; }

.msg-dd__top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
}
.msg-dd__name{
  font-size: 13px;
  font-weight: 600;
  color:#1f2937;
}
.msg-dd__time{
  font-size: 12px;
  color:#6b7280;
  white-space: nowrap;
}
.msg-dd__text{
  margin-top: 3px;
  font-size: 13px;
  color:#374151;
  white-space: nowrap;
  overflow:hidden;
  text-overflow: ellipsis;
}

.msg-dd__footer{
  background:#fff;
  padding: 10px 14px;
  border-top: 1px solid #e6e9ee;
  display:flex;
  justify-content:center;
}
.msg-dd__more{
  font-size: 13px;
  color:#2c74d6;
  text-decoration:none;
}
.msg-dd__more:hover{ text-decoration: underline; }

/* =========================
   NOTIFICATIONS DROPDOWN (küçük panel)
========================= */
.noti-dd__menu{
  width: 320px;
  margin-top: 8px;
  overflow:hidden;
}
.noti-dd__head{
  padding: 10px 14px 0 14px;
  border-bottom: 1px solid #e6e9ee;
  background:#fff;
}
.noti-dd__tab{
  display:inline-block;
  font-size: 13px;
  padding: 10px 0 12px 0;
  color:#111827;
  position:relative;
}
.noti-dd__tab.is-active{ color:#2c74d6; }
.noti-dd__tab.is-active::after{
  content:"";
  position:absolute;
  left:0;
  bottom:-1px;
  height:2px;
  width:120px;
  background:#2c74d6;
}
.noti-dd__empty{
  background:#fff;
  padding: 30px 14px 34px 14px;
  text-align:center;
}
.noti-dd__emptyText{
  color:#9aa3af;
  font-size: 14px;
  line-height: 1.35;
}

/* =========================
   FAVORITES DROPDOWN (küçük panel)
========================= */
.fav-dd__menu{
  width: 260px;
  margin-top: 8px;
  overflow:hidden;
}
.fav-dd__head{
  padding: 10px 14px 0 14px;
  border-bottom: 1px solid #e6e9ee;
  background:#fff;
}
.fav-dd__tab{
  display:inline-block;
  font-size: 13px;
  padding: 10px 0 12px 0;
  color:#111827;
  position:relative;
}
.fav-dd__tab.is-active{ color:#2c74d6; }
.fav-dd__tab.is-active::after{
  content:"";
  position:absolute;
  left:0;
  bottom:-1px;
  height:2px;
  width:90px;
  background:#2c74d6;
}
.fav-dd__item{
  display:block;
  padding: 10px 14px;
  font-size: 13px;
  color:#111827;
  text-decoration:none;
  background:#fff;
  border-bottom: 1px solid #eef1f5;
}
.fav-dd__item:hover{ background:#f7f8fb; }

/* =========================
   RESPONSIVE (header)
========================= */
@media (max-width: 1100px){
  .topbar__search .input-group{ max-width: 560px; }
}
@media (max-width: 992px){
  .topbar__search .input-group{ min-width: 320px; max-width: 420px; }
  .msg-dd__menu{ width: min(620px, calc(100vw - 24px)); }
}

/* 768 altı: web topbar kapansın (mobil shell var) */
@media (max-width: 768px){
  .topbar{ display:none; }
}
