/* ============================================================
   ES KARADENİZ GAYRİMENKUL — Ortak Stiller
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600&display=swap');

:root {
    --navy:        #0d2137;
    --navy-light:  #1a3a5c;
    --teal:        #1a6b5a;
    --teal-light:  #2a8a75;
    --gold:        #d4a843;
    --gold-light:  #e8c060;
    --bg:          #f5f7fa;
    --white:       #ffffff;
    --text:        #2c3e50;
    --text-muted:  #6b7a8d;
    --border:      #e0e6ed;
    --shadow-sm:   0 2px 12px rgba(13,33,55,.06);
    --shadow:      0 4px 24px rgba(13,33,55,.10);
    --shadow-lg:   0 8px 48px rgba(13,33,55,.16);
    --radius:      12px;
    --radius-lg:   20px;
    --t:           .25s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html  { scroll-behavior: smooth; }
body  { font-family: 'Inter', sans-serif; background: var(--bg); color: var(--text); line-height: 1.6; }
img   { max-width: 100%; display: block; }
a     { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; outline: none; font-family: inherit; }
h1,h2,h3,h4 { font-family: 'Playfair Display', serif; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ── Demo Banner ──────────────────────────────────────────── */
.demo-banner {
    background: #fef3c7; border-bottom: 2px solid #fbbf24;
    padding: 10px 0; text-align: center;
    font-size: 13px; color: #92400e; font-weight: 500;
}
.demo-banner a { color: var(--teal); text-decoration: underline; }

/* ── Navbar ───────────────────────────────────────────────── */
.navbar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    padding: 18px 0;
    transition: background var(--t), box-shadow var(--t), padding var(--t);
}
.navbar.transparent { background: transparent; }
.navbar.solid       { background: var(--navy); box-shadow: 0 2px 20px rgba(0,0,0,.2); padding: 12px 0; }
.nav-inner  { display: flex; align-items: center; justify-content: space-between; }
.nav-logo   { display: flex; align-items: center; gap: 10px; color: var(--white); }
.logo-icon  { width: 42px; height: 42px; background: var(--gold); border-radius: 10px; display: grid; place-items: center; font-size: 20px; flex-shrink: 0; }
.logo-text  { line-height: 1.2; }
.logo-name  { font-family: 'Playfair Display', serif; font-size: 15px; font-weight: 700; }
.logo-sub   { font-size: 10px; letter-spacing: 2px; opacity: .7; text-transform: uppercase; }
.nav-links  { display: flex; gap: 32px; align-items: center; }
.nav-links a { color: rgba(255,255,255,.85); font-size: 14px; font-weight: 500; transition: color var(--t); }
.nav-links a:hover { color: var(--gold); }
.nav-cta    { background: var(--gold) !important; color: var(--navy) !important; padding: 8px 20px !important; border-radius: 8px; font-weight: 600 !important; }
.nav-cta:hover { background: var(--gold-light) !important; }
.hamburger  { display: none; flex-direction: column; gap: 5px; background: none; padding: 4px; }
.hamburger span { display: block; width: 24px; height: 2px; background: white; border-radius: 2px; transition: all var(--t); }

/* ── Hero ─────────────────────────────────────────────────── */
.hero {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--navy) 0%, #1a3a5c 55%, #0d4a3a 100%);
    position: relative; overflow: hidden;
    display: flex; align-items: center; padding: 120px 0 80px;
}
.hero::before {
    content: ''; position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/svg%3E");
}
.hero-content { position: relative; z-index: 1; color: white; max-width: 680px; }
.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(212,168,67,.18); border: 1px solid rgba(212,168,67,.4);
    color: var(--gold); padding: 6px 16px; border-radius: 100px;
    font-size: 13px; font-weight: 500; margin-bottom: 24px;
}
.hero h1 { font-size: clamp(30px,5vw,54px); line-height: 1.15; margin-bottom: 18px; }
.hero h1 span { color: var(--gold); }
.hero p { font-size: 18px; opacity: .8; margin-bottom: 40px; max-width: 520px; }

.search-box {
    background: white; border-radius: var(--radius-lg); padding: 24px;
    box-shadow: var(--shadow-lg);
    display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: 12px; align-items: end;
}
.search-field label  { display: block; font-size: 11px; font-weight: 600; color: var(--text-muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .5px; }
.search-field select { width: 100%; padding: 10px 14px; border: 1.5px solid var(--border); border-radius: 8px; font-size: 14px; color: var(--text); background: white; appearance: none; transition: border-color var(--t); }
.search-field select:focus { outline: none; border-color: var(--teal); }
.btn-search { background: var(--teal); color: white; padding: 12px 28px; border-radius: 8px; font-size: 15px; font-weight: 600; transition: background var(--t); white-space: nowrap; height: 42px; }
.btn-search:hover { background: var(--teal-light); }

/* ── Sections ─────────────────────────────────────────────── */
.section { padding: 80px 0; }
.section-alt { background: white; }
.section-header { text-align: center; margin-bottom: 52px; }
.section-label { color: var(--teal); font-size: 12px; font-weight: 700; letter-spacing: 2.5px; text-transform: uppercase; margin-bottom: 10px; }
.section-title { font-size: clamp(24px,3.5vw,38px); color: var(--navy); margin-bottom: 14px; }
.section-subtitle { color: var(--text-muted); font-size: 16px; max-width: 540px; margin: 0 auto; }

/* ── Badges ───────────────────────────────────────────────── */
.badge { padding: 4px 12px; border-radius: 100px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; }
.badge-satilik { background: var(--teal); color: white; }
.badge-kiralik { background: #2563eb; color: white; }
.badge-featured { background: var(--gold); color: var(--navy); }

/* ── Property Card ────────────────────────────────────────── */
.listings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 24px; }
.property-card { background: white; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); transition: transform var(--t), box-shadow var(--t); }
.property-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.card-img { position: relative; height: 220px; overflow: hidden; background: var(--bg); }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.property-card:hover .card-img img { transform: scale(1.05); }
.card-badges { position: absolute; top: 14px; left: 14px; display: flex; gap: 6px; }
.card-feat { position: absolute; top: 14px; right: 14px; }
.card-body { padding: 20px; }
.card-category { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 7px; }
.card-title { font-family: 'Playfair Display', serif; font-size: 17px; color: var(--navy); margin-bottom: 12px; line-height: 1.35; }
.card-meta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }
.meta-item { display: flex; align-items: center; gap: 5px; font-size: 13px; color: var(--text-muted); }
.meta-icon { font-size: 13px; }
.card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 14px; border-top: 1px solid var(--border); }
.card-price { font-size: 19px; font-weight: 700; color: var(--navy); }
.btn-detail { background: var(--navy); color: white; padding: 8px 18px; border-radius: 8px; font-size: 13px; font-weight: 600; transition: background var(--t); }
.btn-detail:hover { background: var(--teal); }

/* ── Stats ────────────────────────────────────────────────── */
.stats-section { background: var(--navy); padding: 64px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; text-align: center; }
.stat-item { color: white; }
.stat-number { font-family: 'Playfair Display', serif; font-size: 48px; font-weight: 700; color: var(--gold); line-height: 1; }
.stat-label { font-size: 14px; opacity: .65; margin-top: 6px; }

/* ── Services ─────────────────────────────────────────────── */
.services-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 24px; }
.service-card { background: white; border-radius: var(--radius-lg); padding: 32px 28px; box-shadow: var(--shadow-sm); transition: transform var(--t), box-shadow var(--t); }
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.service-icon { font-size: 40px; margin-bottom: 14px; }
.service-title { font-size: 18px; color: var(--navy); margin-bottom: 10px; }
.service-desc { color: var(--text-muted); font-size: 14px; line-height: 1.75; }

/* ── CTA ──────────────────────────────────────────────────── */
.cta-section { background: linear-gradient(135deg, var(--teal) 0%, #0d4a3a 100%); padding: 80px 0; color: white; text-align: center; }
.cta-section h2 { font-size: clamp(24px,3.5vw,38px); margin-bottom: 14px; }
.cta-section p { font-size: 17px; opacity: .82; margin-bottom: 36px; max-width: 520px; margin-left: auto; margin-right: auto; }
.cta-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.btn-wa { background: #25d366; color: white; padding: 14px 32px; border-radius: 10px; font-size: 15px; font-weight: 600; display: inline-flex; align-items: center; gap: 10px; transition: transform var(--t), background var(--t); }
.btn-wa:hover { background: #1db954; transform: translateY(-2px); }
.btn-call { background: rgba(255,255,255,.15); border: 1.5px solid rgba(255,255,255,.5); color: white; padding: 14px 32px; border-radius: 10px; font-size: 15px; font-weight: 600; display: inline-flex; align-items: center; gap: 10px; transition: background var(--t); }
.btn-call:hover { background: rgba(255,255,255,.25); }

/* ── Footer ───────────────────────────────────────────────── */
.footer { background: var(--navy); color: white; padding: 60px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 48px; margin-bottom: 48px; }
.footer-brand p { font-size: 14px; opacity: .6; margin-top: 14px; max-width: 280px; line-height: 1.8; }
.footer-col h4 { font-family: 'Inter', sans-serif; font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: var(--gold); margin-bottom: 16px; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a,
.footer-col ul li span { font-size: 14px; opacity: .7; transition: opacity var(--t); display: flex; align-items: flex-start; gap: 8px; }
.footer-col ul li a:hover { opacity: 1; color: var(--gold); }
hr.footer-divider { border: none; border-top: 1px solid rgba(255,255,255,.1); margin-bottom: 20px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; }
.footer-bottom p { font-size: 13px; opacity: .45; }

/* ── Page Header ──────────────────────────────────────────── */
.page-header { background: var(--navy); padding: 120px 0 56px; color: white; }
.page-header h1 { font-size: 36px; margin-bottom: 10px; }
.page-header p { opacity: .7; font-size: 15px; }
.breadcrumb { display: flex; gap: 8px; align-items: center; font-size: 13px; opacity: .65; margin-bottom: 16px; }
.breadcrumb a { color: var(--gold); }
.breadcrumb span { opacity: .5; }

/* ── Filter Bar ───────────────────────────────────────────── */
.filter-bar {
    background: white; border-radius: var(--radius-lg); padding: 20px 24px;
    box-shadow: var(--shadow-sm); display: flex; gap: 12px; flex-wrap: wrap;
    align-items: flex-end; margin-bottom: 32px;
}
.filter-group { display: flex; flex-direction: column; gap: 5px; }
.filter-group label { font-size: 11px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: .5px; }
.filter-group select,
.filter-group input { padding: 9px 12px; border: 1.5px solid var(--border); border-radius: 8px; font-size: 14px; color: var(--text); min-width: 130px; background: white; }
.filter-group select:focus,
.filter-group input:focus { outline: none; border-color: var(--teal); }
.btn-filter { background: var(--teal); color: white; padding: 9px 22px; border-radius: 8px; font-size: 14px; font-weight: 600; }
.btn-filter:hover { background: var(--teal-light); }
.btn-filter-reset { background: transparent; color: var(--text-muted); border: 1.5px solid var(--border); padding: 9px 16px; border-radius: 8px; font-size: 14px; font-weight: 500; }
.btn-filter-reset:hover { border-color: var(--text-muted); color: var(--text); }
.filter-count { color: var(--text-muted); font-size: 14px; margin-left: auto; align-self: center; }

/* ── İlan Detay ───────────────────────────────────────────── */
.gallery { display: grid; grid-template-columns: 2fr 1fr; gap: 8px; border-radius: var(--radius-lg); overflow: hidden; max-height: 480px; margin-bottom: 32px; }
.gallery-main { overflow: hidden; }
.gallery-main img { width: 100%; height: 480px; object-fit: cover; cursor: pointer; transition: transform .3s; }
.gallery-main:hover img { transform: scale(1.02); }
.gallery-thumbs { display: grid; grid-template-rows: 1fr 1fr; gap: 8px; }
.gallery-thumb { overflow: hidden; position: relative; }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; cursor: pointer; transition: transform .3s; }
.gallery-thumb:hover img { transform: scale(1.05); }
.gallery-more { position: absolute; inset: 0; background: rgba(13,33,55,.72); display: flex; align-items: center; justify-content: center; color: white; font-size: 22px; font-weight: 700; cursor: pointer; }

.detail-layout { display: grid; grid-template-columns: 1fr 360px; gap: 32px; align-items: start; }
.detail-sidebar { position: sticky; top: 96px; }
.property-title  { font-size: 28px; color: var(--navy); margin-bottom: 8px; }
.property-price  { font-size: 26px; font-weight: 700; color: var(--teal); margin-bottom: 14px; }
.property-loc    { color: var(--text-muted); font-size: 14px; display: flex; align-items: center; gap: 6px; margin-bottom: 20px; }
.property-badges { display: flex; gap: 8px; margin-bottom: 20px; }
.specs-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 24px; }
.spec-item { background: var(--bg); border-radius: 10px; padding: 14px 16px; }
.spec-label { font-size: 11px; text-transform: uppercase; letter-spacing: .5px; color: var(--text-muted); font-weight: 600; margin-bottom: 4px; }
.spec-value { font-size: 16px; font-weight: 600; color: var(--navy); }
.description-block h3 { font-size: 20px; color: var(--navy); margin-bottom: 12px; }
.description-block p  { color: var(--text-muted); line-height: 1.85; }

.contact-card { background: white; border-radius: var(--radius-lg); padding: 28px; box-shadow: var(--shadow); }
.contact-card h3 { font-size: 20px; color: var(--navy); margin-bottom: 20px; }
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 11px; font-weight: 600; color: var(--text-muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .5px; }
.form-group input,
.form-group textarea,
.form-group select { width: 100%; padding: 11px 14px; border: 1.5px solid var(--border); border-radius: 8px; font-size: 14px; color: var(--text); font-family: inherit; transition: border-color var(--t); background: white; }
.form-group input:focus,
.form-group textarea:focus { outline: none; border-color: var(--teal); }
.form-group textarea { resize: vertical; min-height: 80px; }
.btn-submit { width: 100%; background: var(--teal); color: white; padding: 13px; border-radius: 8px; font-size: 15px; font-weight: 600; border: none; cursor: pointer; transition: background var(--t); }
.btn-submit:hover { background: var(--teal-light); }
.btn-wa-full { width: 100%; background: #25d366; color: white; padding: 12px; border-radius: 8px; font-size: 14px; font-weight: 600; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px; transition: background var(--t); }
.btn-wa-full:hover { background: #1db954; }
.divider-or { text-align: center; color: var(--text-muted); font-size: 13px; margin: 14px 0; position: relative; }
.divider-or::before { content: ''; position: absolute; top: 50%; left: 0; right: 0; height: 1px; background: var(--border); }
.divider-or span { background: white; position: relative; padding: 0 10px; }

/* ── İletişim Sayfası ─────────────────────────────────────── */
.contact-page-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }
.contact-info h2 { font-size: 30px; color: var(--navy); margin-bottom: 14px; }
.contact-info > p { color: var(--text-muted); margin-bottom: 32px; line-height: 1.8; }
.info-items { display: flex; flex-direction: column; gap: 20px; }
.info-item { display: flex; gap: 16px; align-items: flex-start; }
.info-icon { width: 44px; height: 44px; background: linear-gradient(135deg, var(--teal), var(--teal-light)); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.info-item h4 { font-family: 'Inter', sans-serif; font-size: 12px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 3px; }
.info-item p  { font-size: 15px; font-weight: 500; color: var(--text); }
.map-wrap { margin-top: 28px; border-radius: var(--radius-lg); overflow: hidden; height: 200px; }
.map-wrap iframe { width: 100%; height: 100%; border: none; }
.contact-form-card { background: white; border-radius: var(--radius-lg); padding: 36px; box-shadow: var(--shadow); }
.contact-form-card h2 { font-size: 26px; color: var(--navy); margin-bottom: 8px; }
.contact-form-card > p { color: var(--text-muted); font-size: 14px; margin-bottom: 24px; }

/* ── Toast ────────────────────────────────────────────────── */
.toast { position: fixed; bottom: 28px; right: 28px; background: var(--navy); color: white; padding: 14px 20px; border-radius: 10px; font-size: 14px; font-weight: 500; box-shadow: var(--shadow-lg); z-index: 9999; transform: translateY(80px); opacity: 0; transition: all .3s ease; max-width: 320px; }
.toast.show { transform: translateY(0); opacity: 1; }
.toast.success { background: var(--teal); }
.toast.error   { background: #dc2626; }
.toast.info    { background: var(--navy-light); }

/* ── Loading ──────────────────────────────────────────────── */
.loading { display: flex; justify-content: center; padding: 60px; }
.spinner { width: 36px; height: 36px; border: 3px solid var(--border); border-top-color: var(--teal); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-muted); }
.empty-state .empty-icon { font-size: 52px; margin-bottom: 16px; }
.empty-state p { font-size: 16px; }

/* ── ADMIN ────────────────────────────────────────────────── */
.login-screen { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--navy), #1a3a5c); }
.login-card { background: white; border-radius: var(--radius-lg); padding: 40px; width: 100%; max-width: 400px; box-shadow: var(--shadow-lg); }
.login-logo { text-align: center; margin-bottom: 28px; }
.login-logo .logo-icon { width: 56px; height: 56px; font-size: 26px; border-radius: 14px; margin: 0 auto 12px; }
.login-card h2 { font-size: 22px; color: var(--navy); margin-bottom: 4px; text-align: center; }
.login-card .login-sub { color: var(--text-muted); font-size: 14px; margin-bottom: 28px; text-align: center; }
.login-card .form-group { margin-bottom: 16px; }
.btn-login { width: 100%; background: var(--navy); color: white; padding: 13px; border-radius: 8px; font-size: 15px; font-weight: 600; border: none; cursor: pointer; transition: background var(--t); }
.btn-login:hover { background: var(--navy-light); }

.admin-wrap { min-height: 100vh; display: flex; }
.admin-sidebar { width: 240px; background: var(--navy); flex-shrink: 0; display: flex; flex-direction: column; }
.sidebar-logo { padding: 24px 20px; border-bottom: 1px solid rgba(255,255,255,.1); }
.sidebar-logo .logo-name { font-size: 14px; }
.sidebar-logo .logo-sub  { font-size: 10px; }
.sidebar-nav { padding: 12px 0; flex: 1; }
.sidebar-nav a { display: flex; align-items: center; gap: 12px; padding: 11px 20px; color: rgba(255,255,255,.68); font-size: 14px; transition: all var(--t); }
.sidebar-nav a:hover,
.sidebar-nav a.active { background: rgba(255,255,255,.09); color: white; }
.sidebar-nav a .nav-icon { font-size: 17px; width: 20px; text-align: center; }
.sidebar-logout { padding: 16px 20px; border-top: 1px solid rgba(255,255,255,.1); }
.btn-logout { color: rgba(255,255,255,.55); font-size: 14px; display: flex; align-items: center; gap: 10px; background: none; padding: 8px; }
.btn-logout:hover { color: white; }

.admin-main { flex: 1; overflow-y: auto; padding: 0; background: #f1f5f9; }
.admin-topbar { background: white; padding: 16px 28px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.admin-topbar h1 { font-size: 22px; color: var(--navy); }
.admin-content { padding: 28px; }

.dash-cards { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-bottom: 28px; }
.dash-card { background: white; border-radius: var(--radius); padding: 20px 24px; box-shadow: var(--shadow-sm); display: flex; justify-content: space-between; align-items: center; }
.dash-card .dc-left {}
.dash-card .dc-num { font-family: 'Playfair Display', serif; font-size: 36px; font-weight: 700; color: var(--navy); line-height: 1; }
.dash-card .dc-label { font-size: 13px; color: var(--text-muted); margin-top: 4px; }
.dash-card .dc-icon { font-size: 36px; }

.panel-card { background: white; border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); overflow: hidden; }
.panel-header { padding: 18px 24px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.panel-header h2 { font-size: 18px; color: var(--navy); }
.panel-body { padding: 0; }
.btn-add { background: var(--teal); color: white; padding: 9px 20px; border-radius: 8px; font-size: 14px; font-weight: 600; }
.btn-add:hover { background: var(--teal-light); }

.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th { text-align: left; padding: 12px 16px; font-size: 11px; text-transform: uppercase; letter-spacing: .5px; color: var(--text-muted); background: #f8f9fa; border-bottom: 1px solid var(--border); font-family: 'Inter', sans-serif; font-weight: 600; }
.admin-table td { padding: 13px 16px; border-bottom: 1px solid var(--border); font-size: 14px; vertical-align: middle; }
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: #f8fafc; }
.table-actions { display: flex; gap: 6px; }
.btn-sm { padding: 5px 12px; border-radius: 6px; font-size: 12px; font-weight: 600; }
.btn-sm-edit   { background: #eff6ff; color: #2563eb; }
.btn-sm-delete { background: #fef2f2; color: #dc2626; }
.btn-sm-view   { background: #f0fdf4; color: #16a34a; }
.btn-sm-read   { background: #f0fdf4; color: #16a34a; }
.badge-unread  { background: #fef3c7; color: #92400e; padding: 2px 8px; border-radius: 100px; font-size: 11px; font-weight: 600; }
.badge-read    { background: #f1f5f9; color: var(--text-muted); padding: 2px 8px; border-radius: 100px; font-size: 11px; }

.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 2000; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal-box { background: white; border-radius: var(--radius-lg); width: 100%; max-width: 720px; max-height: 92vh; overflow-y: auto; box-shadow: var(--shadow-lg); }
.modal-head { padding: 22px 28px 16px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; position: sticky; top: 0; background: white; z-index: 1; }
.modal-head h2 { font-size: 20px; color: var(--navy); }
.modal-close { background: none; font-size: 24px; color: var(--text-muted); width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: 6px; line-height: 1; }
.modal-close:hover { background: var(--bg); }
.modal-body { padding: 24px 28px; }
.modal-foot { padding: 16px 28px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 12px; background: white; position: sticky; bottom: 0; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
.img-input-list { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; }
.img-input-row { display: flex; gap: 8px; }
.img-input-row input { flex: 1; padding: 8px 12px; border: 1.5px solid var(--border); border-radius: 8px; font-size: 13px; }
.img-input-row input:focus { outline: none; border-color: var(--teal); }
.btn-rm-img { padding: 8px 12px; border-radius: 8px; background: #fef2f2; color: #dc2626; font-size: 16px; line-height: 1; }
.btn-add-img { background: #f0fdf4; color: #16a34a; border: 1.5px dashed #86efac; padding: 9px; border-radius: 8px; font-size: 13px; font-weight: 600; width: 100%; }
.btn-cancel { background: white; color: var(--text); border: 1.5px solid var(--border); padding: 10px 24px; border-radius: 8px; font-size: 14px; font-weight: 600; }
.btn-save   { background: var(--teal); color: white; padding: 10px 28px; border-radius: 8px; font-size: 14px; font-weight: 600; }
.btn-save:hover { background: var(--teal-light); }
.switch-wrap { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; color: var(--text); cursor: pointer; }
.switch-wrap input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--teal); }

.msg-card { padding: 20px 24px; border-bottom: 1px solid var(--border); transition: background var(--t); }
.msg-card:last-child { border-bottom: none; }
.msg-card:hover { background: #f8fafc; }
.msg-card.unread { border-left: 3px solid var(--teal); }
.msg-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 8px; }
.msg-name { font-size: 15px; font-weight: 600; color: var(--navy); }
.msg-date { font-size: 12px; color: var(--text-muted); }
.msg-listing { font-size: 12px; color: var(--teal); margin-bottom: 6px; }
.msg-text { font-size: 14px; color: var(--text-muted); line-height: 1.6; }
.msg-actions { display: flex; gap: 8px; margin-top: 10px; }

/* ── Pagination ───────────────────────────────────────────── */
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 40px; }
.page-btn { padding: 9px 16px; border-radius: 8px; border: 1.5px solid var(--border); background: white; font-size: 14px; color: var(--text); transition: all var(--t); }
.page-btn:hover { border-color: var(--teal); color: var(--teal); }
.page-btn.active { background: var(--teal); color: white; border-color: var(--teal); }

/* ── Tabs ─────────────────────────────────────────────────── */
.tab-bar { display: flex; border-bottom: 2px solid var(--border); margin-bottom: 28px; gap: 0; }
.tab-btn { padding: 12px 24px; font-size: 14px; font-weight: 500; color: var(--text-muted); background: none; border: none; border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all var(--t); }
.tab-btn.active { color: var(--teal); border-bottom-color: var(--teal); font-weight: 600; }
.tab-btn:hover { color: var(--teal); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 900px) {
    .detail-layout { grid-template-columns: 1fr; }
    .detail-sidebar { position: static; }
    .dash-cards { grid-template-columns: 1fr 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .contact-page-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .nav-links { display: none; position: fixed; inset: 0; background: var(--navy); padding: 80px 32px 32px; flex-direction: column; gap: 16px; z-index: 999; }
    .nav-links.open { display: flex; }
    .nav-links.open a { font-size: 20px; padding: 8px 0; }
    .hamburger { display: flex; }
    .search-box { grid-template-columns: 1fr; }
    .gallery { grid-template-columns: 1fr; }
    .gallery-thumbs { grid-template-rows: none; grid-template-columns: 1fr 1fr; }
    .gallery-main img { height: 260px; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; }
    .filter-bar { flex-direction: column; }
    .filter-group select, .filter-group input { min-width: 100%; }
    .admin-sidebar { display: none; }
    .form-row, .form-row-3 { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .hero p { font-size: 16px; }
    .dash-cards { grid-template-columns: 1fr; }
    .listings-grid { grid-template-columns: 1fr; }
}
