@font-face {
    font-family: Vazirmatn;
    src: url("../fonts/Vazirmatn-Variable.woff2") format("woff2");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}
:root {
    --navy: #142331;
    --gold: #d8b46a;
    --ink: #765318;
    --canvas: #f6f7f9;
    --line: #c8d1d9;
    --soft: #e7ebef;
    --text: #172632;
    --muted: #4d5d6b;
    --danger: #9b2d26;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 1rem; }
body {
    margin: 0;
    background: var(--canvas);
    color: var(--text);
    font: 15px/1.85 Vazirmatn, Tahoma, "Segoe UI", Arial, sans-serif;
}
a { color: #27546a; text-underline-offset: .2em; }
a:hover { color: var(--ink); }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; display: block; }
h1, h2, h3, p { margin: 0 0 .75rem; }
h1, h2, h3 { line-height: 1.45; overflow-wrap: anywhere; }
h1 { font-size: clamp(1.8rem, 3.5vw, 2.75rem); }
h2 { font-size: clamp(1.25rem, 2.2vw, 1.55rem); }
h3 { font-size: 1.08rem; }
small { font-size: .78rem; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #23778a; outline-offset: 3px; }
.site-header :focus-visible, .hero :focus-visible, .site-footer :focus-visible { outline-color: #f2ca75; }
.shell { width: min(1280px, 100% - clamp(28px, 8vw, 110px)); margin-inline: auto; }
.site-header { background: var(--navy); color: white; border-bottom: 1px solid #ffffff23; }
.navbar { min-height: 76px; display: flex; align-items: center; gap: clamp(12px, 3vw, 45px); justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: .65rem; color: inherit; text-decoration: none; font-size: 1.2rem; font-weight: 800; white-space: nowrap; }
.brand small { display: block; color: #c6d0d8; font-size: .64rem; font-weight: 400; line-height: 1.35; }
.navbar nav { display: flex; gap: clamp(12px, 2.6vw, 34px); align-items: center; margin-inline-end: auto; }
.navbar nav a, .site-footer a { color: #edf1f4; text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.navbar a:hover, .site-footer a:hover { color: #f3cd83; }
.navbar nav a[aria-current="page"] { color: #efc977; box-shadow: inset 0 -2px #d8b46a; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 44px; padding: .55rem 1.05rem; border: 1px solid transparent; border-radius: 9px; font-weight: 700; text-decoration: none; text-align: center; line-height: 1.4; max-width: 100%; overflow-wrap: anywhere; }
.btn, .pill, .category { transition: background-color .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.btn:disabled { opacity: .52; cursor: default; }
.btn.gold { background: var(--gold); color: var(--navy); }
.btn.gold:hover { background: #ebca86; color: var(--navy); }
.btn.primary { background: var(--navy); color: white; }
.btn.primary:hover { background: #29475b; }
.btn.outline { border-color: #a7b3bd; background: white; color: var(--navy); }
.btn.outline:hover { border-color: var(--ink); color: var(--ink); }
.btn.danger { border-color: #c7a29c; color: var(--danger); background: #fff8f7; }
.full { width: 100%; margin-bottom: .45rem; }
.hero { background: radial-gradient(ellipse at 23% 39%, #243d50 0, transparent 46%), var(--navy); color: white; overflow: hidden; }
.hero-inner { min-height: 410px; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: center; gap: clamp(16px, 3vw, 48px); }
.hero-copy { padding-block: 3rem; }
.hero h1 { font-size: clamp(2.1rem, 4.5vw, 4rem); line-height: 1.32; margin-bottom: 1rem; }
.hero h1 em { color: #efc977; font-style: normal; }
.hero p:not(.eyebrow) { color: #d9e1e7; max-width: 490px; margin-bottom: 1.3rem; }
.hero-visual { animation: hero-enter 850ms ease-out both; }
.hero-art { width: 100%; height: auto; transform: translate(var(--art-x, 0), var(--art-y, 0)); transition: transform .28s ease-out; }
.btn.hero-outline { color: #f6f7f9; border-color: #80909d; background: #ffffff0b; }
.btn.hero-outline:hover { color: #efc977; border-color: #efc977; }
@keyframes hero-enter {
    from { opacity: .15; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
.eyebrow { display: flex; align-items: center; gap: .5rem; color: #efc977; font-size: .8rem; font-weight: 700; }
.eyebrow.ink { color: var(--ink); }
.eyebrow span { width: 14px; height: 2px; background: currentColor; display: inline-block; }
.landing-content { display: grid; gap: clamp(30px, 5vw, 60px); padding-block: clamp(28px, 4.5vw, 58px); }
.landing-section h2 { font-size: clamp(1.45rem, 3vw, 2.1rem); }
.categories, .process-steps { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 16px; }
.category { display: flex; flex-direction: column; align-items: start; gap: .55rem; padding: clamp(16px, 2.5vw, 28px); background: white; border: 1px solid var(--soft); border-block-start: 3px solid var(--gold); border-radius: 16px; color: var(--text); text-decoration: none; min-width: 0; }
.category:hover, .category:focus-visible { border-color: #a68446; color: var(--text); box-shadow: 0 8px 24px #14233112; transform: translateY(-3px); }
.category-icon { background: #f3ecdc; color: var(--ink); border-radius: 11px; width: 48px; height: 48px; display: grid; place-items: center; font-size: 1.45rem; }
.category strong { font-size: clamp(1.05rem, 2vw, 1.35rem); }
.category > span:not(.category-icon, .category-link) { color: var(--muted); }
.category-link { display: flex; align-items: center; justify-content: space-between; width: 100%; margin-block-start: auto; padding-block-start: .5rem; color: var(--ink); font-weight: 700; }
.process-steps { margin: 0; padding: 0; list-style: none; }
.process-steps li { border-block-start: 1px solid var(--line); padding-block-start: 1rem; }
.process-steps li > span { color: var(--ink); font-weight: 800; }
.process-steps p { color: var(--muted); margin: 0; }
.landing-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; padding: clamp(16px, 3vw, 32px); }
.landing-cta p { margin: 0; }
.browse-head { margin-bottom: 1.6rem; }
.browse-categories { margin: .8rem 0 0; }
.market-search { background: white; border: 1px solid var(--soft); border-radius: 12px; display: grid; grid-template-columns: minmax(0,1fr) minmax(0,.48fr) auto; gap: 8px; padding: 8px; max-width: 660px; }
.market-grid { display: grid; grid-template-columns: minmax(215px,245px) minmax(0,1fr); gap: 24px; align-items: start; }
.surface { background: white; border: 1px solid var(--soft); border-radius: 16px; box-shadow: 0 2px 5px #14233106; min-width: 0; }
.filter-box { padding: 16px; }
summary { cursor: pointer; font-weight: 700; min-height: 44px; padding: .55rem 0; }
.filter-box form { padding-top: .3rem; }
.section-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: .85rem; }
.section-head h1, .section-head h2, .section-head .eyebrow { margin-bottom: 0; }
.muted, .tiny { color: var(--muted); }
.tiny { font-size: .72rem; }
.cards { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
.card { padding: 17px; display: flex; flex-direction: column; }
.card-top, .card-bottom { display: flex; align-items: center; justify-content: space-between; gap: .45rem; flex-wrap: wrap; }
.card h3 { margin: .65rem 0 .15rem; }
.card h3 a { color: var(--text); text-decoration: none; display: inline-flex; min-height: 44px; align-items: center; }
.card h3 a:hover { text-decoration: underline; color: var(--ink); }
.pill { display: inline-flex; align-items: center; border-radius: 40px; padding: .17rem .7rem; background: #edf1f4; color: #31475a; font-size: .76rem; font-weight: 700; text-decoration: none; line-height: 1.65; max-width: 100%; }
a.pill { min-height: 44px; }
.pill.active { background: #e9d6aa; color: #4b3511; }
.pill.warn { background: #faf0d8; color: #664719; }
.card-sides, .specs { margin: .5rem 0 1rem; }
.card-sides div, .specs div { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.5fr); gap: .55rem; padding: .45rem .6rem; border-bottom: 1px solid var(--soft); overflow-wrap: anywhere; }
.card-sides div { grid-template-columns: 4.2rem minmax(0,1fr); background: #f7f9fa; border-radius: 6px; margin-bottom: 4px; }
dt { color: var(--muted); }
dd { margin: 0; font-weight: 600; }
.card-bottom { margin-top: auto; color: var(--muted); border-top: 1px solid var(--soft); padding-top: .4rem; }
.card-bottom a { min-height: 44px; display: inline-flex; align-items: center; gap: .25rem; }
.subtypes { display: flex; flex-wrap: wrap; gap: .55rem; margin-bottom: 1rem; }
.subtypes:empty { display: none; }
.empty { padding: 2rem; text-align: center; }
.pager { margin-top: 1rem; }
.page { padding-block: clamp(1.4rem, 4vw, 3rem); min-height: 62vh; }
.narrow { max-width: 850px; }
.auth { max-width: 480px; }
.crumb { color: var(--muted); margin-bottom: 1rem; font-size: .86rem; }
.page-head { margin-bottom: 1.2rem; }
.detail-grid { display: grid; grid-template-columns: minmax(0,2.15fr) minmax(245px,1fr); align-items: start; gap: 18px; }
.profile-grid { grid-template-columns: minmax(245px, 1fr) minmax(0, 2.15fr); }
.profile-photo { display: flex; align-items: center; gap: 1rem; margin-block-end: 1.1rem; }
.profile-photo h2, .profile-photo p, .profile-upload p { margin-block-end: 0; }
.profile-avatar { display: grid; place-items: center; inline-size: 88px; block-size: 88px; flex: none; border-radius: 50%; overflow: hidden; background: #f3ecdc; color: var(--ink); font-size: 2rem; font-weight: 800; }
.profile-avatar img { inline-size: 100%; block-size: 100%; object-fit: cover; }
.profile-upload { margin-block-start: 1rem; }
.profile-upload input::file-selector-button, .profile-grid input::file-selector-button { font: inherit; }
.section { padding: clamp(16px, 2.75vw, 30px); overflow-wrap: anywhere; }
.section h2:not(:first-child) { margin-top: 1.3rem; }
.spaced { margin-top: 1rem; }
.split { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
.split.compact { gap: 6px; }
.deal { margin: 1.1rem 0; }
.deal div { padding: .85rem; background: #f5f7f9; border: 1px solid var(--soft); border-radius: 10px; }
.deal small, .deal strong { display: block; }
.deal small { color: var(--ink); }
.divider { margin-inline: .4rem; color: #697b8a; }
.notice { border: 1px solid #c2d2dc; background: #edf5f8; color: #254153; padding: .8rem 1rem; border-radius: 9px; margin: .7rem 0; overflow-wrap: anywhere; }
.notice.warn { background: #fff6e3; color: #61440e; border-color: #e0c88f; }
.notice.success { background: #e9f5ed; color: #21553a; border-color: #a3cbb1; }
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: .6rem; }
.stack { display: grid; gap: .75rem; }
.stack>label, .section>label, .split>label, .field>label { display: block; }
label { font-weight: 600; color: var(--text); }
label input:not([type=checkbox]), label select, label textarea, .field input, .field select { display: block; width: 100%; margin-top: .25rem; }
input:not([type=checkbox]):not([type=hidden]), select, textarea { background: white; color: var(--text); border: 1px solid #778895; border-radius: 8px; min-height: 44px; padding: .5rem .65rem; max-width: 100%; min-width: 0; }
textarea { resize: vertical; }
input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--navy); }
.check { display: flex !important; align-items: center; gap: .5rem; min-height: 44px; }
.field { min-width: 0; }
.error, .req { color: var(--danger); }
.error { font-size: .85rem; }
.validation-summary-valid { display: none; }
.validation-summary-errors { background: #fff1ee; border: 1px solid #dfb5ae; padding: .6rem 1rem; border-radius: 8px; }
.private-box { margin: .65rem 0; padding: .4rem .8rem; border: 1px solid var(--soft); border-radius: 9px; }
.result-map { margin-block: .8rem 1rem; padding: .3rem .85rem; }
.map-panel > p, .map-panel label { margin-block: .4rem .65rem; }
.map-canvas { position: relative; isolation: isolate; width: 100%; height: clamp(240px, 42vh, 410px); border: 1px solid var(--line); border-radius: 10px; background: #e9eef1; direction: ltr; }
.map-canvas.leaflet-container { font-family: inherit; }
.map-actions { margin-block-start: .6rem; }
.map-status:empty { display: none; }
.map-pin { border: 3px solid white; border-radius: 50%; background: #254d65; box-shadow: 0 0 0 2px #254d65, 0 3px 9px #14233155; }
.map-listings { margin: 0; padding-inline-start: 1rem; text-align: start; }
.preserve { white-space: pre-wrap; overflow-wrap: anywhere; }
.clean-list { padding: 0; list-style: none; margin: 0; }
.clean-list li, .queue-item { padding: .85rem 0; border-top: 1px solid var(--soft); }
.admin-filters { align-items: end; }
.admin-role-editor { flex-basis: min(100%, 17rem); }
.report-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: .25rem .9rem; }
.report-columns label { overflow-wrap: anywhere; }
.report-columns input { flex: none; }
.admin-table-scroll { overflow-x: auto; }
.admin-table { border-collapse: collapse; min-width: 100%; }
.admin-table th, .admin-table td { border-block-end: 1px solid var(--soft); padding: .6rem; text-align: start; vertical-align: top; min-width: 8rem; max-width: 24rem; }
.admin-table th { background: var(--canvas); }
.admin-table td { white-space: pre-wrap; }
.line-item { display: flex; align-items: center; justify-content: space-between; gap: .75rem; flex-wrap: wrap; }
.line-item small, td small { display: block; color: var(--muted); }
.comparison table { border-collapse: collapse; width: 100%; table-layout: fixed; }
.comparison th, .comparison td { padding: .65rem; text-align: start; vertical-align: top; border-block-end: 1px solid var(--line); }
.comparison td .btn { margin-top: .5rem; }
.metric-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(145px,1fr)); gap: .7rem; }
.metric { padding: .85rem; }
.metric strong, .metric span { display: block; }
.metric strong { font-size: 1.45rem; color: var(--ink); }
.site-footer { background: var(--navy); color: #d7e1e8; padding: 1.3rem 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.footer-inner p { margin: 0; }
.sr, .skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link:focus { position: absolute; z-index: 10; background: white; padding: .7rem; color: var(--navy); }
@media (max-width: 899px) {
    .market-grid, .detail-grid { grid-template-columns: minmax(0,1fr); gap: 16px; }
    .hero-inner { min-height: 320px; }
}
@media (max-width: 620px) {
    .navbar { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; padding-block: .5rem; }
    .navbar nav { grid-column: 1/-1; grid-row: 2; flex-wrap: wrap; }
    .navbar>.btn { grid-column: 2; grid-row: 1; }
    .hero-inner { grid-template-columns: minmax(0, 1fr); gap: 0; }
    .hero-copy { padding-block: 2rem 0; }
    .hero-visual { width: min(100%, 400px); margin-inline: auto; }
    .market-search { grid-template-columns: minmax(0,1fr) auto; }
    .market-search #browse-q { grid-column: 1/-1; }
    .categories, .process-steps, .cards, .split:not(.compact) { grid-template-columns: minmax(0,1fr); }
    .comparison table, .comparison tbody, .comparison tr, .comparison td { display: block; }
    .comparison thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
    .comparison td { padding: .45rem .15rem; }
    .comparison td[data-label]::before { content: attr(data-label) " · "; color: var(--muted); font-weight: 600; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
    .hero-art, .category:hover, .category:focus-visible { transform: none; }
}

.filter-section {
    min-width: 0;
    display: grid;
    gap: .5rem;
    margin: 0;
    padding: .65rem .75rem .75rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #f7f9fa;
}
.service-guide p { line-height: 2; overflow-wrap: anywhere; }
.service-guide section { margin-block: 1.8rem; }
.filter-section legend { padding-inline: .3rem; color: var(--ink); font-weight: 700; }
.filter-section small { line-height: 1.6; }
.filter-more { border-top: 1px solid var(--soft); }
.filter-more > label { display: block; margin-block-end: .55rem; }
.applied-filters { display: flex; flex-wrap: wrap; gap: .4rem; margin-block-end: .9rem; }
.applied-filters .pill { gap: .45rem; overflow-wrap: anywhere; }
.applied-filters .pill:hover { background: #f3e8d0; }

.listing-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin: 1rem 0; }
.listing-metrics div { padding: .7rem; background: var(--paper, #f5f7f8); border-radius: .7rem; }
.listing-metrics dt { font-size: .82rem; color: var(--muted, #526575); }
.listing-metrics dd { margin: .4rem 0 0; font-weight: 800; font-size: 1.15rem; }
.performance-item { padding: 1.2rem 0; border-bottom: 1px solid #dce4e8; }
.performance-item:last-child { border-bottom: 0; }
.journey-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .6rem; padding: 0; list-style-position: inside; }
.journey-steps li { padding: .8rem; border: 1px solid #dce4e8; border-radius: .7rem; background: #fff; }
.journey-steps .done { background: #e8f5ee; border-color: #6d9b82; }
.chat-messages { display: flex; flex-direction: column; gap: 1rem; margin-top: 1rem; }
.chat-message { max-width: 90%; padding: 1rem; border-radius: .8rem; background: #edf1f4; overflow-wrap: anywhere; }
.chat-message.mine { align-self: flex-end; background: #e8f5ee; }
.chat-message p { margin: .6rem 0; }
.support-messages { display: flex; flex-direction: column; gap: 1rem; margin-block-start: 1rem; }
.support-message { padding: 1rem; border-radius: .8rem; background: #edf1f4; overflow-wrap: anywhere; }
.support-message-admin { background: #e8f5ee; border-inline-start: 3px solid #6d9b82; }
.support-message p { margin-block-end: 0; }
@media (max-width: 600px) { .listing-metrics, .journey-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
