/* ÜNLÜ GAYRİMENKUL public header / navbar bileşeni */
.site-header {
  position: sticky;
  z-index: 100;
  top: 0;
  display: block;
  min-height: 74px;
  padding: 0;
  border: 0;
  border-bottom: 1px solid var(--color-line);
  background: rgb(255 255 255 / 97%);
  box-shadow: 0 2px 10px rgb(11 31 51 / 3%);
  backdrop-filter: blur(16px);
  transition: box-shadow .2s ease, background-color .2s ease;
}

.site-header.is-scrolled {
  min-height: 74px;
  background: rgb(255 255 255 / 98%);
  box-shadow: 0 8px 24px rgb(11 31 51 / 8%);
}

.site-header.home-header,
.site-header.home-header.is-scrolled {
  position: sticky;
  inset: auto;
  background: rgb(255 255 255 / 97%);
  border-bottom: 1px solid var(--color-line);
  box-shadow: 0 2px 10px rgb(11 31 51 / 3%);
  color: var(--color-text);
}

.header-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(178px, auto) minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(14px, 2vw, 28px);
  width: min(1320px, calc(100% - 56px));
  min-height: 74px;
  margin: 0 auto;
  transition: min-height .2s ease;
}

.site-header.is-scrolled .header-inner { min-height: 68px; }
.brand { grid-column: 1; grid-row: 1; min-width: 0; gap: 10px; text-decoration: none; }
.brand-mark { width: 42px; height: 42px; flex-basis: 42px; border-radius: 10px; }
.brand-logo { width: auto; max-width: 52px; max-height: 46px; }
.brand-name { color: var(--color-brand); font-size: 13px; letter-spacing: .09em; }
.brand-slogan { color: var(--color-muted); font-size: 9px; }

.main-nav {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  justify-content: center;
  gap: clamp(7px, 1.2vw, 17px);
  min-width: 0;
  padding: 0;
}

.main-nav a {
  position: relative;
  display: inline-flex;
  min-height: 74px;
  align-items: center;
  padding: 0 2px;
  color: #344054;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
  transition: color .18s ease;
}

.site-header.is-scrolled .main-nav a { min-height: 68px; }
.main-nav a::after {
  position: absolute;
  right: 2px;
  bottom: 17px;
  left: 2px;
  height: 2px;
  transform: scaleX(0);
  transform-origin: center;
  border-radius: 2px;
  background: var(--color-gold);
  content: "";
  transition: transform .18s ease;
}

.main-nav a:hover,
.main-nav a.is-active,
.main-nav a[aria-current="page"] { color: var(--color-brand); }
.main-nav a:focus-visible,
.header-actions > a:focus-visible,
.header-actions button:focus-visible,
.nav-toggle:focus-visible {
  outline: 3px solid rgb(201 164 92 / 55%);
  outline-offset: 3px;
}
.main-nav a:hover::after,
.main-nav a.is-active::after,
.main-nav a[aria-current="page"]::after { transform: scaleX(1); }
.site-header.home-header .brand-name { color: var(--color-brand); }
.site-header.home-header .brand-slogan { color: var(--color-muted); }
.site-header.home-header .main-nav a { color: #344054; }
.site-header.home-header .main-nav a:hover,
.site-header.home-header .main-nav a.is-active,
.site-header.home-header .main-nav a[aria-current="page"] { color: var(--color-brand); }
.site-header.home-header .header-actions > a:not(.header-whatsapp) { color: #344054; }
.site-header.home-header .header-actions > a:not(.header-whatsapp):hover,
.site-header.home-header .header-actions > a:not(.header-whatsapp).is-active,
.site-header.home-header .header-actions > a:not(.header-whatsapp)[aria-current="page"] { color: var(--color-brand); }

.header-contact.header-actions {
  grid-column: 3;
  grid-row: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  min-width: 0;
  margin: 0;
}

.header-actions > a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 9px;
  color: #344054;
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
  transition: color .18s ease, background-color .18s ease, border-color .18s ease;
}

.header-actions > a:hover,
.header-actions > a.is-active,
.header-actions > a[aria-current="page"] {
  border-color: #e9dfcb;
  background: #fbf8f1;
  color: var(--color-brand);
}

.header-actions .action-symbol { color: var(--color-gold-ink); font-size: 18px; line-height: 1; }
.header-actions .action-label { white-space: nowrap; }
.header-actions .header-favorites b {
  display: inline-grid;
  min-width: 18px;
  height: 18px;
  place-items: center;
  padding: 0 4px;
  border-radius: 6px;
  background: #f3ead7;
  color: var(--color-brand);
  font-size: 10px;
}
.header-actions .header-favorites { position: relative; }
.header-actions .header-notifications { position: relative; }
.header-actions .header-notifications b { display:inline-grid; min-width:18px; height:18px; place-items:center; padding:0 4px; border-radius:6px; background:#f3ead7; color:var(--color-brand); font-size:10px; }

.header-account { max-width: 150px; overflow: hidden; text-overflow: ellipsis; }
.header-user-name { display: none; }
.header-register { border-color: var(--color-line-strong)!important; }
.header-logout { display: inline-flex; flex: 0 0 auto; margin: 0; }
.header-logout button {
  min-height: 38px;
  padding: 0 8px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--color-muted);
  font: 600 11px var(--font-sans);
  cursor: pointer;
}
.header-logout button:hover { background: var(--color-page); color: var(--color-brand); }

.header-actions .header-phone {
  width: 38px;
  min-width: 38px;
  padding: 0;
  border-color: var(--color-line);
  color: var(--color-brand);
}
.header-phone span { display: none; }
.header-actions .header-whatsapp {
  min-height: 40px;
  padding: 0 11px;
  border-color: var(--color-brand);
  border-radius: 9px;
  background: var(--color-brand);
  color: #fff;
}
.header-actions .header-whatsapp:hover { border-color: var(--color-brand-soft); background: var(--color-brand-soft); color: #fff; }
.header-actions .header-whatsapp .ui-icon { width: 16px; height: 16px; }

.nav-toggle {
  grid-column: 3;
  grid-row: 1;
  display: none;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid var(--color-line);
  border-radius: 10px;
  background: #fff;
  color: var(--color-brand);
  cursor: pointer;
}
.nav-toggle .ui-icon { width: 20px; height: 20px; }
.menu-close-icon { display: none; }
.nav-toggle[aria-expanded="true"] .menu-open-icon { display: none; }
.nav-toggle[aria-expanded="true"] .menu-close-icon { display: inline-flex; }

@media (max-width: 1100px) {
  .header-inner { grid-template-columns: minmax(0, 1fr) auto auto; gap: 10px; width: calc(100% - 40px); }
  .main-nav { position: absolute; z-index: 5; top: calc(100% + 1px); right: 0; left: 0; display: none; grid-column: 1 / -1; grid-row: 2; flex-direction: column; align-items: stretch; gap: 0; padding: 8px 18px 14px; border: 1px solid var(--color-line); border-top: 0; border-radius: 0 0 14px 14px; background: #fff; box-shadow: 0 18px 34px rgb(11 31 51 / 12%); }
  .main-nav.is-open { display: flex; animation: header-drawer-in .18s ease-out both; }
  .main-nav a, .site-header.is-scrolled .main-nav a { min-height: 48px; padding: 0 5px; border-bottom: 1px solid #eef0f3; font-size: 13px; }
  .main-nav a:last-child { border-bottom: 0; }
  .main-nav a::after { right: auto; bottom: 8px; left: 5px; width: 24px; }
  .nav-toggle { grid-column: 3; display: inline-flex; }
  .header-contact.header-actions { grid-column: 2; gap: 3px; }
  .header-actions .header-phone { display: none; }
  .header-actions .header-account { max-width: 110px; }
  .site-header.home-header .main-nav.is-open { color: var(--color-text); background: #fff; }
  .site-header.home-header .main-nav.is-open a { color: #344054; }
}

@media (max-width: 680px) {
  .site-header, .site-header.is-scrolled { min-height: 66px; }
  .header-inner, .site-header.is-scrolled .header-inner { grid-template-columns: minmax(0, 1fr) auto auto; width: calc(100% - 30px); min-height: 66px; gap: 8px; }
  .brand { gap: 8px; }
  .brand-mark { width: 38px; height: 38px; flex-basis: 38px; font-size: 13px; }
  .brand-logo { max-width: 44px; max-height: 40px; }
  .brand-name { font-size: 11px; letter-spacing: .07em; }
  .brand-slogan { max-width: 150px; font-size: 8px; }
  .header-contact.header-actions { gap: 2px; }
  .header-actions > a { width: 36px; min-width: 36px; min-height: 38px; gap: 0; padding: 0; }
  .header-actions .action-label, .header-actions .header-register, .header-actions .header-logout { display: none; }
  .header-actions .action-symbol { font-size: 19px; }
  .header-actions .header-favorites b { position: absolute; min-width: 15px; height: 15px; margin: -22px 0 0 24px; padding: 0 3px; font-size: 9px; }
  .header-actions .header-notifications b { position:absolute; min-width:15px; height:15px; margin:-22px 0 0 24px; padding:0 3px; font-size:9px; }
  .header-actions .header-whatsapp { display: none; }
  .nav-toggle { width: 38px; height: 38px; }
}

@media (max-width: 370px) {
  .header-inner, .site-header.is-scrolled .header-inner { width: calc(100% - 22px); gap: 5px; }
  .brand-slogan { max-width: 118px; }
  .header-actions > a { width: 32px; min-width: 32px; }
  .header-actions .header-favorites b { margin-left: 21px; }
  .nav-toggle { width: 35px; height: 35px; }
}

@keyframes header-drawer-in {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .site-header, .header-inner, .main-nav a, .header-actions > a { transition: none; }
  .main-nav.is-open { animation: none; }
}
