/* ============================================
   Iranhaircare / Golare — Salon Finder
   Layout rebuild — same palette, new structure:
   split hero + stats, floating toolbar, accordion,
   editorial result rows.
   ============================================ */

/* Safety net: prevent any stray horizontal overflow from shifting
   the RTL layout and showing a gap on the left edge. */
html, body { overflow-x: hidden; max-width: 100%; }

/* ---------- Hero ---------- */
.contact-hero {
    position: relative;
    background: linear-gradient(135deg, #1A1215 0%, #3B1A22 50%, #6B2D3E 100%);
    padding: 130px 0 40px;
    overflow: visible; /* let toolbar float below */
    border-radius: 0 0 24px 24px;
}
.contact-hero::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(circle at 15% 30%, rgba(201,83,106,0.18) 0%, transparent 55%);
    border-radius: inherit;
    pointer-events: none;
}

.hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 40px;
    align-items: center;
    padding-bottom: 12px;
}

.hero-headline { text-align: right; color: #fff; }
.hero-headline h1 {
    font-size: 32px;
    font-weight: 900;
    line-height: 1.35;
    margin-bottom: 14px;
}
.hero-headline h1 .hero-em {
    font-style: normal;
    background: linear-gradient(90deg, #C9536A, #C8A96E);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-headline p {
    color: rgba(255,255,255,0.72);
    font-size: 15px;
    line-height: 1.9;
    max-width: 480px;
}

.hero-stats {
    display: flex;
    justify-content: flex-start;
    gap: 0;
    border-right: 1px solid rgba(200,169,110,0.25);
    padding-right: 24px;
}
.hero-stat {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 0 20px;
    border-left: 1px solid rgba(200,169,110,0.2);
}
.hero-stat:last-child { border-left: none; }
.hero-stat-num {
    font-size: 24px;
    font-weight: 800;
    color: var(--gold-light, #C8A96E);
}
.hero-stat-label {
    font-size: 12px;
    color: rgba(255,255,255,0.6);
    margin-top: 4px;
}

/* ---------- Floating search toolbar ---------- */
.search-toolbar {
    position: relative;
    z-index: 5;
    margin-top: 28px;
    background: var(--surface);
    border: 1px solid rgba(200,169,110,0.2);
    border-radius: 20px;
    box-shadow: 0 24px 50px rgba(0,0,0,0.35);
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.toolbar-field { flex: 1; min-width: 0; padding: 6px 14px; }
.toolbar-field label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.2px;
    color: var(--muted);
    margin-bottom: 4px;
}
.toolbar-city { flex: 0 0 190px; }
.toolbar-divider {
    width: 1px; align-self: stretch;
    background: rgba(201,83,106,0.15);
    margin: 6px 0;
}

.dropdown-filter { position: relative; width: 100%; }
.dropdown-select {
    display: flex; align-items: center; justify-content: space-between;
    cursor: pointer; color: var(--dark); font-size: 14px; font-weight: 600;
    user-select: none;
}
.dropdown-select i {
    font-size: 11px; color: var(--primary-light);
    transition: transform 0.25s ease;
}
.dropdown-filter.open .dropdown-select i { transform: rotate(180deg); }

.dropdown-list {
    position: absolute;
    top: calc(100% + 14px);
    right: 0; left: 0;
    background: #161012;
    border: 1px solid rgba(200,169,110,0.2);
    border-radius: 14px;
    max-height: 260px; overflow-y: auto;
    opacity: 0; visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    z-index: 50;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    padding: 6px;
}
.dropdown-filter.open .dropdown-list { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-item {
    padding: 10px 14px; font-size: 14px; color: #E5D5DA;
    cursor: pointer; border-radius: 10px;
    display: flex; align-items: center; justify-content: space-between;
    transition: background 0.2s ease, color 0.2s ease;
}
.dropdown-item:hover { background: rgba(201,83,106,0.15); color: #fff; }
.dropdown-item.selected { background: rgba(200,169,110,0.1); color: #fff; }
.dropdown-item.selected::after { content: '✓'; color: var(--gold-light, #C8A96E); font-weight: 700; }

.search-wrapper { position: relative; }
.search-wrapper input {
    width: 100%;
    border: none;
    background: transparent;
    font-size: 14px;
    color: var(--dark);
    font-family: inherit;
    padding: 4px 0;
}
.search-wrapper input:focus { outline: none; }

#suggestions {
    background: var(--primary-pale) !important;
    border: 1px solid var(--primary-hover) !important;
    border-radius: 12px;
    position: absolute; top: calc(100% + 10px); right: 0; left: 0; z-index: 60;
    max-height: 320px; overflow-y: auto;
}

.suggestion-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    text-decoration: none;
    border-bottom: 1px solid var(--primary-hover);
    transition: background 0.15s ease;
}
.suggestion-item:last-child { border-bottom: none; }
.suggestion-item:hover { background: rgba(201,83,106,0.15); }
.suggestion-name {
    font-size: 13.5px; font-weight: 700; color: var(--muted);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.suggestion-addr {
    font-size: 12px; color: #9B8790; flex: 1; margin: 0 4px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.suggestion-rating {
    font-size: 12px; color: var(--primary-hover); font-weight: 700; flex-shrink: 0; white-space: nowrap;
    background: var(--border-gold);
    border-radius: 8px;
    padding: 5px;
}

.btn-search-submit {
    flex: 0 0 auto;
    background: linear-gradient(135deg, #C9536A, #9B2C42);
    color: var(--white);
    padding: 14px 30px;
    border: none;
    border-radius: 14px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 15px rgba(201,83,106,0.3);
    font-family: 'Vazirmatn', sans-serif;
}
.btn-search-submit:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(201,83,106,0.45); }

/* ---------- Content section below hero ---------- */
.salon-search-section { padding: 56px 0 80px; background: var(--bg); direction: rtl; }
.calculator-wrapper { max-width: 850px; margin: 0 auto; }

#searchHint {
    font-size: 13px; color: var(--muted); text-align: right;
    margin-bottom: 4px;
}
#searchStatus {
    font-size: 13px; color: var(--secondary-color); text-align: right;
    min-height: 20px; margin-bottom: 10px;
}

/* ---------- Results — editorial rows, not a card grid ---------- */
.results-section { margin-bottom: 44px; }
.results-title { font-size: 16px; font-weight: 800; color: var(--dark, #1A1215); margin-bottom: 14px; }

.results-grid { display: flex; flex-direction: column; gap: 10px; }

.result-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--surface);
    border: 1px solid rgba(201,83,106,0.14);
    border-radius: 14px;
    padding: 12px 16px;
    text-decoration: none;
    transition: border-color 0.2s ease, background 0.2s ease;
}
.result-card:hover { border-color: var(--primary, #C9536A); background: var(--surface-hover, var(--surface)); }

.result-thumb { width: 58px; height: 58px; flex-shrink: 0; border-radius: 10px; overflow: hidden; background: rgba(201,83,106,0.08); }
.result-thumb img { width: 100%; height: 100%; object-fit: cover; }
.result-thumb-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 22px; opacity: 0.5; }
.result-thumb-placeholder img{width: 35px; height: 35px;}
.result-body { min-width: 0; flex: 1; display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.result-name { font-size: 14px; font-weight: 700; color: var(--dark, #1A1215); white-space: nowrap; min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.result-addr { font-size: 12px; color: var(--muted, #9B7A82); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; flex: 1 1 auto; }
.result-meta { display: flex; align-items: center; gap: 8px; margin-right: auto; font-size: 12px; }
.result-rating { color: #C8A96E; font-weight: 700; }
.result-reviews { color: var(--muted, #9B7A82); }
.result-status { padding: 2px 10px; border-radius: 20px; font-weight: 600; font-size: 11px; }
.result-status.open { background: rgba(39,174,96,0.12); color: #27ae60; }
.result-status.closed { background: rgba(231,76,60,0.1); color: #e74c3c; }

.skeleton-card { pointer-events: none; }
.skeleton-box {
    background: linear-gradient(90deg, rgba(201,83,106,0.08) 25%, rgba(201,83,106,0.15) 50%, rgba(201,83,106,0.08) 75%);
    background-size: 200% 100%;
    animation: resultShimmer 1.5s infinite;
}
@keyframes resultShimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

.results-empty { text-align: center; padding: 46px 20px; color: var(--muted, #9B7A82); box-shadow: 0 20px 48px rgba(0, 0, 0, 0.28);
    border-radius: 22px;
    border: 1.5px solid var(--gold); }
.results-empty-icon { font-size: 32px; display: block; margin-bottom: 10px; opacity: 0.6; }
.results-empty p { font-size: 14px;}

/* ---------- Pagination ---------- */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 22px;
    direction: ltr; 
}
.page-btn {
    min-width: 38px;
    height: 38px;
    padding: 0 10px;
    border: 1px solid rgba(201,83,106,0.2);
    background: var(--surface);
    color: var(--dark, #1A1215);
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    font-family: 'Vazirmatn', sans-serif;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}
.page-btn:hover:not([disabled]):not(.active) {
    border-color: var(--primary, #C9536A);
    color: var(--primary, #C9536A);
}
.page-btn.active {
    background: linear-gradient(135deg, #C9536A, #9B2C42);
    border-color: transparent;
    color: #fff;
}
.page-btn.page-nav { font-family: 'Vazirmatn', sans-serif; }
.page-btn[disabled] {
    opacity: 0.35;
    cursor: default;
}
.page-dots {
    color: var(--muted, #9B7A82);
    font-size: 13px;
    padding: 0 4px;
}
@media (max-width: 480px) {
    .page-btn { min-width: 34px; height: 34px; font-size: 12px; }
}

/* ---------- Info accordion (replaces the 3 SEO color blocks) ---------- */
.info-accordion {
   box-shadow: 0 20px 48px rgba(0, 0, 0, 0.28);
   border-radius: 22px;
   border: 1.5px solid var(--gold);
   padding: 10px 20px;
}
.info-item {
    border-bottom: 1px solid rgba(200,169,110,0.15);
}
.info-item summary {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 20px 4px;
    cursor: pointer;
}
.info-item summary::-webkit-details-marker { display: none; }
.info-item summary::after {
    content: '+';
    margin-right: auto;
    font-size: 20px;
    font-weight: 300;
    color: var(--primary-dark);
    transition: transform 0.25s ease;
}
.info-item[open] summary::after { transform: rotate(45deg); }

.info-icon {
    width: 36px; height: 36px; flex-shrink: 0;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: rgba(201,83,106,0.1);
    font-size: 13px;
    font-weight: 800;
    border: 1px solid var(--gold);
    color: var(--primary, #C9536A);
}
.info-icon svg {
    width: 18px;
    height: 18px;
}
.info-title { font-size: 16px; font-weight: 700; color: var(--dark, #1A1215); }

.info-body { padding: 0 4px 24px 50px; animation: infoReveal 0.25s ease; }
@keyframes infoReveal { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }
.info-body p { font-size: 14.5px; line-height: 1.9; color: var(--muted); margin-bottom: 12px; text-align: justify; }
.info-body h4 { font-size: 15px; font-weight: 700; color: var(--dark); margin-bottom: 8px; }
.info-body ul { list-style: none; }
.info-body li {
    padding: 7px 0 7px 0; padding-right: 18px; position: relative;
    font-size: 14px; color: var(--muted); line-height: 1.7;
}
.info-body li::before { content: "✦"; position: absolute; right: 0; color: var(--primary); font-size: 11px; }
.info-body li strong { color: var(--dark); font-weight: 700; }


/* ===========================================================
   Hub grid cards - used on /salons/ (city list) and
   /salons/{city}/ (district list). See listing-render.php:
   renderSalonsRootPage() and renderCityHubPage().
   =========================================================== */
.hub-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.hub-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 16px;
    border-top: 4px solid var(--gold);
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
    padding: 22px;
    text-decoration: none;
    color: inherit;
    transition: box-shadow .2s ease, transform .2s ease;
}
.hub-card:nth-child(2n) {
    border-top-color: #D4AF37;
}
.hub-card:hover {
    box-shadow: 0 10px 26px rgba(0,0,0,.09);
    transform: translateY(-3px);
}
 
.hub-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 16px;
}
.hub-card-badge {
    background: var(--gold-light-x2);
    border: 1px solid var(--primary-hover);
    color: #C9536A;
    font-size: .75rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 20px;
    white-space: nowrap;
}
.hub-card:nth-child(2n) .hub-card-badge {
    background: var(--gold-light-x2);
    color: var(--primary);
}
.hub-card-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--border-gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.hub-card:nth-child(2n) .hub-card-icon {
    background: #FBF3D9;
}
 
.hub-card-title {
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 8px;
}
.hub-card-desc {
    color: #808080;
    font-size: .88rem;
    line-height: 1.7;
    margin-bottom: 20px;
    flex: 1;
}
 
.hub-card-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.hub-card-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--primary-pale);
    color: #555;
    font-size: .78rem;
    padding: 5px 10px;
    border-radius: 20px;
    white-space: nowrap;
}
.hub-card-cta {
    color: var(--accent,var(--primary-dark));
    font-weight: 600;
    font-size: .8rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}


/* ===========================================================
   Advanced-search floating action button - shown on every
   /salons/... page. See listing-render.php: renderAdvancedSearchFab().
   =========================================================== */
.advanced-search-fab {
    position: fixed;
    bottom: 22px;
    left: 22px;
    z-index: 999;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--gold-light);
    color: var(--muted);
    text-decoration: none;
    font-weight: 600;
    font-size: .85rem;
    padding: 12px 18px;
    border-radius: 30px;
    border: 1px solid var(--primary-light);
    /* Two-layer shadow: the soft dark blur gives depth on light
       backgrounds, and the semi-opaque white ring keeps the button's
       edge crisp and visible even when it sits over a dark section
       (e.g. the footer) - without the ring, the dark blur alone reads
       as an ugly black smudge against a dark background. */
    box-shadow: 0 4px 14px rgba(0,0,0,.22), 0 0 0 2px rgba(255,255,255,.85);
    transition: transform .15s ease, box-shadow .15s ease;
}
.advanced-search-fab .fab-icon {
    font-size: 1.15rem;
    line-height: 1;
}
.advanced-search-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0,0,0,.28), 0 0 0 2px rgba(255,255,255,.9);
}
/* ---------- Category filter bar (district-only landing page) ---------- */
.category-filter-wrap {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}
.category-filter-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 4px 2px 4px;
}
.category-filter-bar::-webkit-scrollbar { display: none; }

.category-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    padding: 9px 16px;
    border-radius: 30px;
    border: 1px solid rgba(201,83,106,0.2);
    background: var(--surface);
    color: var(--dark, #1A1215);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.category-chip:hover {
    border-color: var(--primary, #C9536A);
    color: var(--primary, #C9536A);
    transform: translateY(-1px);
}
.category-chip.active {
    background: linear-gradient(135deg, #C9536A, #9B2C42);
    border-color: transparent;
    color: #fff;
}
.category-chip .chip-count {
    background: rgba(0,0,0,0.06);
    border-radius: 20px;
    padding: 1px 7px;
    font-size: 11px;
    font-weight: 700;
}
.category-chip.active .chip-count {
    background: rgba(255,255,255,0.25);
    color: #fff;
}
.filter-nav-btn {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(201,83,106,0.25);
    background: var(--surface);
    color: var(--primary, #C9536A);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}
.filter-nav-btn:hover {
    background: linear-gradient(135deg, #C9536A, #9B2C42);
    color: #fff;
    border-color: transparent;
}
.filter-nav-btn.is-disabled {
    opacity: 0.35;
    pointer-events: none;
}
.meta-icon{
    width: 20px;
    height: 20px;
}
.chevron-icon {
    width: 16px;
    height: 16px;
    display: block;
}
/* ---------- Results title row (title + count) ---------- */
.results-title-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}
.results-title-row .results-title {
    margin-bottom: 0;
}
.search-result-count {
    font-size: 13px;
    font-weight: 600;
    color: var(--muted, #9B7A82);
    white-space: nowrap;
}

/* ===== BREADCRUMB ===== */
.breadcrumb-container{margin:0 0 24px 0;font-size:.82rem;width:100%}
.breadcrumb-list{
  display:flex;align-items:center;flex-wrap:nowrap;
  list-style:none;padding:0;margin:0;gap:6px;width:100%;
}
.breadcrumb-item{
  display:inline-flex;align-items:center;
  color:var(--text-muted,#a0a0a0);white-space:nowrap;flex-shrink:0;
}
.breadcrumb-item a{
  color:var(--muted);text-decoration:none;transition:color .3s ease;
  display:inline-flex;align-items:center;gap:4px;
}
.breadcrumb-item a:hover{color:#C8A96E}
.breadcrumb-item + .breadcrumb-item::before{
  content:"◀";font-size:.55rem;color:#C8A96E;margin-left:6px;
}
.breadcrumb-item.active{color:var(--primary-dark);font-weight:600}
.breadcrumb-home{display:flex;flex-shrink:0}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-stats { border-right: none; padding-right: 0; padding-top: 16px; }
}
@media (max-width: 768px) {
    .hero-headline h1 { font-size: 28px; }
    .search-toolbar { flex-direction: row; flex-wrap: wrap; align-items: stretch; border-radius: 20px; }
    .toolbar-divider { display: none; }
    .toolbar-city { flex: 1 1 100%; }
    .toolbar-query { flex: 1 1 auto; min-width: 0; }
    .btn-search-submit { width: auto; flex: 0 0 auto; padding: 14px 20px; }    
    .info-body { padding: 0 4px 24px 20px; }
    .search-wrapper { position: static; }
    #suggestions { top: 100%; }
    .suggestion-item { flex-wrap: wrap; row-gap: 4px; }
    .suggestion-name { order: 1; flex: 1 1 auto; max-width: none; }
    .suggestion-rating { order: 2; }
    .suggestion-addr {
        order: 3;
        flex: 1 1 100%;
        margin: 0;
        white-space: normal;
    }
    .hub-grid { grid-template-columns: repeat(2, 1fr); }
    .advanced-search-fab {
        bottom: 78px;
        left: 14px;
        width: 50px;
        height: 50px;
        padding: 0;
        border-radius: 50%;
        justify-content: center;
    }
    .advanced-search-fab .fab-label {
        display: none;
    }
    .category-filter-wrap{margin-bottom: 4px;}
    .category-chip { padding: 7px 12px; font-size: 12.5px; }
    .category-filter-bar { gap: 6px; padding-bottom: 40px; }
    .filter-nav-btn { display: none; }
    .breadcrumb-container{
        overflow-x:auto;white-space:nowrap;-webkit-overflow-scrolling:touch;
        scrollbar-width:none;-ms-overflow-style:none;padding-bottom:4px;
    }
    .breadcrumb-container::-webkit-scrollbar{display:none}
    .breadcrumb-list{display:inline-flex;flex-wrap:nowrap;gap:6px}
    .breadcrumb-item{flex-shrink:0}
    .breadcrumb-item a,.breadcrumb-item.active{white-space:nowrap}
    .results-title-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }
    .meta-icon{
        width: 28px;
        height: 28px;
    }
}

@media (max-width: 480px) {
    .search-toolbar { padding: 8px 10px; gap: 6px; }
    .toolbar-field { padding: 4px 8px; }
    .toolbar-field label { font-size: 10px; }
    .search-wrapper input { font-size: 13px; }
    .btn-search-submit { padding: 12px 14px; font-size: 13px; }
    .hub-grid { grid-template-columns: 1fr; }
    
}