/* Meva Emlak — Ana Stil Dosyası */

:root {
  --gold: #FCB813;
  --gold-light: #ffd24d;
  --charcoal: #404041;
  --navy: #0a0a0a;
  --navy-2: #141414;
  --bg: #ffffff;
  --bg-soft: #f7f7f8;
  --bg-card: #ffffff;
  --text: #1a1a1a;
  --text-muted: #5c5c5e;
  --line: #e8e8ea;
  --header-bg: rgba(255, 255, 255, 0.97);
  --shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.12);
  --radius: 14px;
  --whatsapp: #25d366;
}

[data-theme="dark"] {
  --navy: #000000;
  --navy-2: #111111;
  --bg: #0a0a0a;
  --bg-soft: #121212;
  --bg-card: #161616;
  --text: #f2f2f2;
  --text-muted: #b0b0b2;
  --line: #2a2a2c;
  --header-bg: rgba(10, 10, 10, 0.97);
  --shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.6);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 110px; }

body {
  font-family: "Poppins", "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-wrap: break-word;
  transition: background .3s ease, color .3s ease;
}

img { max-width: 100%; display: block; }

a { color: var(--gold); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--gold-light); }

.container { width: 94%; max-width: 1280px; margin-inline: auto; }

/* Preloader */
#preloader {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  background: var(--navy);
  transition: opacity .5s ease, visibility .5s ease;
}
#preloader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.preloader-logo { width: 180px; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .4; transform: scale(.98); } }

/* Topbar */
.topbar {
  background: var(--navy); color: #ddd;
  font-size: .88rem; padding: .45rem 0;
}
.topbar .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .8rem; }
.topbar a { color: #fff; font-weight: 500; }
.topbar a:hover { color: var(--gold); }
.topbar-contact { display: flex; gap: 1.2rem; flex-wrap: wrap; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: .65rem 0;
}
.brand { display: flex; align-items: center; color: var(--text); }
.brand:hover { color: var(--text); }

/* Logo — açık/koyu tema */
.brand-logo-img {
  height: 64px;
  width: auto;
  max-width: min(220px, 42vw);
  flex-shrink: 0;
  object-fit: contain;
}
.logo-theme-dark { display: none; }
[data-theme="dark"] .logo-theme-light { display: none; }
[data-theme="dark"] .logo-theme-dark { display: block; }

.agent-card .brand-logo-img {
  max-height: 56px;
  height: auto;
  width: auto;
  margin: 0 auto 1rem;
}

.theme-toggle { color: var(--text); }

.main-nav ul { display: flex; gap: 1.8rem; list-style: none; align-items: center; }
.main-nav a {
  color: var(--text); font-size: .95rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .04em;
  position: relative; padding: .3rem 0;
}
.main-nav a::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 0; height: 2px; background: var(--gold);
  transition: width .25s ease;
}
.main-nav a:hover::after, .main-nav a.active::after { width: 100%; }
.main-nav a.active { color: var(--gold); }

.header-actions { display: flex; align-items: center; gap: .6rem; }
.header-cta { display: none; }
.theme-toggle, .nav-toggle {
  background: transparent; border: 1px solid var(--line);
  border-radius: 10px; width: 42px; height: 42px;
  cursor: pointer; font-size: 1.1rem;
  display: flex; align-items: center; justify-content: center;
}
.nav-toggle { flex-direction: column; gap: 5px; padding: 8px; }
.nav-toggle span { display: block; width: 20px; height: 2px; background: var(--text); transition: .3s; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (min-width: 900px) { .header-cta { display: inline-flex; } }

@media (max-width: 899px) {
  .main-nav {
    position: fixed; top: 0; right: -100%; width: min(320px, 85vw);
    height: 100vh; background: var(--bg-card);
    border-left: 1px solid var(--line);
    padding: 5rem 1.5rem 2rem; transition: right .35s ease;
    box-shadow: var(--shadow-lg); z-index: 200;
  }
  .main-nav.open { right: 0; }
  .main-nav ul { flex-direction: column; align-items: flex-start; gap: 1.2rem; }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .75rem 1.5rem; border-radius: 10px;
  font-weight: 600; font-size: .92rem; border: 2px solid transparent;
  cursor: pointer; transition: all .2s ease;
}
.btn-gold { background: var(--gold); color: #111; border-color: var(--gold); }
.btn-gold:hover { background: var(--gold-light); border-color: var(--gold-light); color: #111; }
.btn-outline-dark { background: transparent; color: var(--text); border-color: var(--line); }
.btn-outline-dark:hover { border-color: var(--gold); color: var(--gold); }
.btn-whatsapp { background: var(--whatsapp); color: #fff; border-color: var(--whatsapp); }
.btn-whatsapp:hover { filter: brightness(1.08); color: #fff; }
.btn-sm { padding: .5rem 1rem; font-size: .85rem; }
.btn-lg { padding: .9rem 2rem; font-size: 1rem; }
.btn-block { width: 100%; margin-bottom: .6rem; }

/* Hero */
.hero-estate {
  background: linear-gradient(135deg, var(--navy) 0%, #1a1a1a 55%, #2a2200 100%);
  color: #fff; padding: 3.5rem 0 0;
  position: relative; overflow: hidden;
}
.hero-estate::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(252,184,19,.15), transparent 50%);
  pointer-events: none;
}
.hero-content { position: relative; max-width: 720px; padding-bottom: 2rem; }
.hero-kicker {
  color: var(--gold); font-weight: 600; font-size: .85rem;
  text-transform: uppercase; letter-spacing: .12em; margin-bottom: .8rem;
}
.hero-estate h1 { font-size: clamp(1.9rem, 4vw, 3rem); line-height: 1.15; margin-bottom: 1rem; font-weight: 700; }
.hero-estate h1 em { color: var(--gold); font-style: normal; }
.hero-estate p { color: rgba(255,255,255,.82); font-size: 1.05rem; max-width: 560px; }

.hero-filter-wrap { position: relative; transform: translateY(50%); margin-bottom: 4rem; z-index: 2; }
.search-filter {
  background: var(--bg-card); border-radius: var(--radius);
  padding: 1.2rem 1.4rem; box-shadow: var(--shadow-lg);
  border: 1px solid var(--line);
}
.search-filter-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: .8rem; align-items: end;
}
.search-filter .form-group label {
  display: block; font-size: .78rem; font-weight: 600;
  color: var(--text-muted); margin-bottom: .35rem; text-transform: uppercase; letter-spacing: .04em;
}
.search-filter select, .search-filter input {
  width: 100%; padding: .65rem .75rem; border: 1px solid var(--line);
  border-radius: 8px; background: var(--bg-soft); color: var(--text);
  font-family: inherit; font-size: .9rem;
}
.search-filter select:focus, .search-filter input:focus {
  outline: none; border-color: var(--gold);
}

/* Sections */
.section { padding: 4rem 0; }
.section-soft { background: var(--bg-soft); }
.section-head { margin-bottom: 2.5rem; }
.section-head.center { text-align: center; }
.section-kicker { color: var(--gold); font-weight: 600; font-size: .82rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: .5rem; }
.section-title { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 700; margin-bottom: .6rem; color: var(--text); }
.section-desc { color: var(--text-muted); max-width: 620px; }
.section-head.center .section-desc { margin-inline: auto; }

.page-hero {
  background: linear-gradient(135deg, var(--navy), #222);
  color: #fff; padding: 3rem 0;
}
.page-hero-compact { padding: 2.2rem 0; }
.page-hero h1 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: .5rem; }
.breadcrumb { color: rgba(255,255,255,.7); font-size: .88rem; }
.breadcrumb a { color: var(--gold); }
.breadcrumb span { margin: 0 .4rem; opacity: .5; }

/* Listing cards */
.listings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}
.listing-card {
  background: var(--bg-card); border-radius: var(--radius);
  border: 1px solid var(--line); overflow: hidden;
  box-shadow: var(--shadow); transition: transform .25s ease, box-shadow .25s ease;
}
.listing-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.listing-card-link { color: inherit; display: block; }
.listing-card-link:hover { color: inherit; }
.listing-card-media { position: relative; aspect-ratio: 4/3; overflow: hidden; background: var(--bg-soft); }
.listing-card-media img { width: 100%; height: 100%; object-fit: cover; }
.listing-placeholder {
  width: 100%; height: 100%; min-height: 200px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(145deg, var(--bg-soft), var(--line));
  color: var(--text-muted); font-size: 2.5rem;
}
.listing-placeholder.large { min-height: 360px; font-size: 3rem; }
.listing-badge {
  position: absolute; top: .75rem; left: .75rem;
  padding: .35rem .7rem; border-radius: 6px;
  font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
}
.listing-badge-sale { background: var(--gold); color: #111; }
.listing-badge-rent { background: var(--charcoal); color: #fff; }
.listing-card-body { padding: 1rem 1.1rem 1.2rem; }
.listing-price { font-size: 1.25rem; font-weight: 700; color: var(--gold); margin-bottom: .35rem; }
.listing-title { font-size: 1rem; font-weight: 600; margin-bottom: .4rem; color: var(--text); line-height: 1.35; }
.listing-location { font-size: .85rem; color: var(--text-muted); margin-bottom: .5rem; }
.listing-stats { display: flex; gap: .6rem; flex-wrap: wrap; }
.listing-stats span {
  font-size: .78rem; font-weight: 600; padding: .2rem .55rem;
  background: var(--bg-soft); border-radius: 6px; color: var(--text-muted);
}

/* Listings page layout */
.listings-page { padding-top: 2rem; }
.listings-layout { display: grid; grid-template-columns: 280px 1fr; gap: 2rem; align-items: start; }
.listings-sidebar {
  position: sticky; top: 100px;
  background: var(--bg-card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.2rem;
  box-shadow: var(--shadow);
}
.listings-sidebar h2 { font-size: 1.1rem; margin-bottom: 1rem; }
.listings-sidebar .search-filter { box-shadow: none; border: none; padding: 0; background: transparent; }
.listings-sidebar .search-filter-grid { grid-template-columns: 1fr; }
.filter-count { margin-top: 1rem; font-size: .88rem; color: var(--text-muted); }

@media (max-width: 899px) {
  .listings-layout { grid-template-columns: 1fr; }
  .listings-sidebar { position: static; }
  .hero-filter-wrap { transform: none; margin-bottom: 0; padding-bottom: 2rem; }
}

/* Listing detail */
.listing-detail { padding-top: 2rem; }
.listing-detail-grid { display: grid; grid-template-columns: 1fr 320px; gap: 2rem; align-items: start; }
.listing-detail-header { margin: 1.5rem 0; }
.listing-detail-header h1 { font-size: clamp(1.4rem, 3vw, 2rem); margin: .6rem 0; }
.listing-detail-price { font-size: 1.8rem; font-weight: 700; color: var(--gold); }

.listing-gallery { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.gallery-main { aspect-ratio: 16/10; background: var(--bg-soft); }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: flex; gap: .5rem; padding: .6rem; overflow-x: auto; background: var(--bg-soft); }
.gallery-thumb {
  flex: 0 0 72px; height: 54px; border: 2px solid transparent;
  border-radius: 8px; overflow: hidden; cursor: pointer; padding: 0; background: none;
}
.gallery-thumb.active, .gallery-thumb:hover { border-color: var(--gold); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }

.specs-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: .8rem; margin-top: 1rem;
}
.spec-item {
  background: var(--bg-soft); border-radius: 10px; padding: .75rem 1rem;
  border: 1px solid var(--line);
}
.spec-label { display: block; font-size: .75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.spec-value { font-weight: 600; font-size: .95rem; }

.eids-box {
  margin-top: 1.5rem; padding: 1rem 1.2rem;
  background: rgba(252,184,19,.1); border: 1px solid rgba(252,184,19,.35);
  border-radius: 10px; font-size: .92rem;
}
.eids-box strong { display: block; margin-bottom: .25rem; color: var(--text); }

.agent-card {
  position: sticky; top: 100px;
  background: var(--bg-card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.5rem;
  box-shadow: var(--shadow-lg); text-align: center;
}
.agent-logo { max-height: 56px; width: auto; margin: 0 auto 1rem; }
.agent-card .logo-theme-dark,
.agent-card .logo-theme-light { display: block; margin-inline: auto; }
.agent-card .logo-theme-dark { display: none; }
[data-theme="dark"] .agent-card .logo-theme-light { display: none; }
[data-theme="dark"] .agent-card .logo-theme-dark { display: block; }
.agent-card h2 { font-size: 1.2rem; margin-bottom: .2rem; }
.agent-sub { color: var(--text-muted); font-size: .85rem; margin-bottom: .8rem; }
.agent-desc { font-size: .88rem; color: var(--text-muted); margin-bottom: 1.2rem; text-align: left; }
.agent-contact { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--line); font-size: .88rem; text-align: left; }

@media (max-width: 899px) {
  .listing-detail-grid { grid-template-columns: 1fr; }
  .agent-card { position: static; }
}

/* About / trust */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.about-values { display: flex; flex-direction: column; gap: 1rem; margin: 1.5rem 0; }
.about-value { display: flex; gap: 1rem; align-items: flex-start; }
.about-value .icon { font-size: 1.5rem; flex-shrink: 0; }
.about-value strong { display: block; margin-bottom: .15rem; }
.about-value span { font-size: .9rem; color: var(--text-muted); }

.trust-card {
  background: var(--bg-card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 2rem;
  box-shadow: var(--shadow);
}
.trust-icon { font-size: 2.5rem; margin-bottom: .8rem; }
.trust-card h3 { margin-bottom: .6rem; }
.trust-card p { color: var(--text-muted); margin-bottom: 1.2rem; }
.trust-actions { display: flex; gap: .6rem; flex-wrap: wrap; }

@media (max-width: 768px) { .about-grid { grid-template-columns: 1fr; } }

/* CTA */
.cta-band {
  background: linear-gradient(135deg, var(--navy), #1a1a1a);
  color: #fff; text-align: center;
}
.cta-band h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin-bottom: .6rem; }
.cta-band p { color: rgba(255,255,255,.8); margin-bottom: 1.5rem; max-width: 560px; margin-inline: auto; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 2rem; margin-bottom: 2rem; }
.contact-info-card {
  background: var(--bg-card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.5rem;
}
.contact-info-item { display: flex; gap: .8rem; margin-bottom: 1rem; }
.contact-info-item .label { font-size: .78rem; color: var(--text-muted); text-transform: uppercase; }
.contact-info-item .value { font-weight: 500; }
.contact-hours { margin: 1.2rem 0; font-size: .9rem; color: var(--text-muted); }
.contact-quick-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1rem; }

.contact-form {
  background: var(--bg-card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.5rem;
}
.form-desc { color: var(--text-muted); font-size: .9rem; margin-bottom: 1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-weight: 600; font-size: .88rem; margin-bottom: .35rem; }
.form-group .req { color: #e53935; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: .7rem .85rem; border: 1px solid var(--line);
  border-radius: 8px; background: var(--bg-soft); color: var(--text);
  font-family: inherit; font-size: .92rem;
}
.form-group textarea { min-height: 120px; resize: vertical; }
.form-group.invalid input, .form-group.invalid textarea { border-color: #e53935; }
.form-error { display: none; color: #e53935; font-size: .78rem; margin-top: .25rem; }
.form-group.invalid .form-error { display: block; }
.form-success {
  display: none; padding: .85rem 1rem; background: rgba(37,211,102,.12);
  border: 1px solid rgba(37,211,102,.35); border-radius: 8px;
  color: #1b7a3e; margin-bottom: 1rem; font-size: .9rem;
}
.form-success.show { display: block; }
.form-note { font-size: .78rem; color: var(--text-muted); margin-top: .8rem; }
.map-wrap { margin-top: 1rem; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.map-iframe { width: 100%; min-height: 360px; border: 0; display: block; }

@media (max-width: 768px) {
  .contact-grid, .form-row { grid-template-columns: 1fr; }
}

/* Blog */
.posts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; }
.post-card {
  background: var(--bg-card); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); transition: transform .2s;
}
.post-card:hover { transform: translateY(-3px); }
.post-card img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.post-body { padding: 1rem 1.1rem 1.2rem; }
.post-meta { display: flex; gap: .8rem; font-size: .78rem; color: var(--text-muted); margin-bottom: .5rem; }
.post-meta .cat { color: var(--gold); font-weight: 600; }
.post-body h3 { font-size: 1rem; margin-bottom: .4rem; }
.post-body h3 a { color: var(--text); }
.post-body h3 a:hover { color: var(--gold); }
.post-cover { border-radius: var(--radius); margin-bottom: 1.5rem; }
.prose p { margin-bottom: 1rem; color: var(--text-muted); }
.prose h2 { font-size: 1.2rem; margin: 1.5rem 0 .6rem; color: var(--text); }

/* Footer */
.site-footer {
  background: var(--navy); color: rgba(255,255,255,.85);
  padding: 3rem 0 1.5rem; margin-top: 2rem;
}
.footer-main { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; margin-bottom: 2rem; }
.footer-brand .brand-name { font-weight: 600; margin-bottom: .6rem; color: #fff; }
.footer-brand .divider { color: var(--gold); margin: 0 .3rem; }
.footer-brand p { font-size: .88rem; color: rgba(255,255,255,.65); }
.footer-social { display: flex; gap: 1rem; margin-top: 1rem; }
.footer-social a { color: var(--gold); font-size: .88rem; font-weight: 600; }
.footer-col h4 { color: #fff; font-size: .92rem; margin-bottom: .8rem; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: .4rem; }
.footer-col a { color: rgba(255,255,255,.7); font-size: .88rem; }
.footer-col a:hover { color: var(--gold); }
.footer-contact li { display: flex; gap: .5rem; font-size: .88rem; color: rgba(255,255,255,.7); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 1.2rem; display: flex; justify-content: space-between;
  flex-wrap: wrap; gap: .8rem; font-size: .82rem; color: rgba(255,255,255,.55);
}
.footer-bottom a { color: rgba(255,255,255,.7); }
.footer-bottom .takvio {
  color: var(--gold);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.footer-bottom .takvio:hover { color: var(--gold-light); }
html:not(.light) .footer-bottom .takvio { color: var(--gold); }
html.light .footer-bottom .takvio { color: var(--gold-dark); }

@media (max-width: 899px) { .footer-main { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-main { grid-template-columns: 1fr; } }

/* 404 */
.error-page { text-align: center; padding: 5rem 0; }
.error-code { font-size: 5rem; font-weight: 700; color: var(--gold); line-height: 1; }
.error-page h1 { margin: 1rem 0; }
.error-page p { color: var(--text-muted); max-width: 480px; margin: 0 auto 1.5rem; }
.error-page .btn { margin: .3rem; }

.empty-msg { grid-column: 1 / -1; text-align: center; color: var(--text-muted); padding: 2rem; }
.recaptcha-slot, .img-placeholder {
  padding: 2rem; text-align: center; background: var(--bg-soft);
  border: 1px dashed var(--line); border-radius: var(--radius); color: var(--text-muted);
}

.hidden-listing { display: none !important; }
