/* kompanionki24.com - v3 adamieva-style */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;600;700&display=swap');

:root {
    --primary: #e1108e;
    --primary-hover: #D00651;
    --btn-bg: #3466b1;
    --btn-hover: #3d4e9b;
    --bg: #111118;
    --bg-card: #1c1c26;
    --bg-panel: #252530;
    --text: #c8c8cc;
    --text-light: #fff;
    --text-muted: #888;
    --border: #2a2a3a;
    --radius: 8px;
    --shadow: 0 0 8px rgba(0,0,0,0.28);
    --transition: all 0.2s ease;
}

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

body {
    font-family: 'Open Sans', sans-serif;
    background: var(--bg);
    color: var(--text);
    font-size: 15px;
    line-height: 1.6;
    font-weight: 400;
    min-height: 100vh;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-hover); }
img { max-width: 100%; height: auto; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 12px; }

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 20px; border-radius: var(--radius);
    font-weight: 600; font-size: 14px; cursor: pointer;
    border: none; transition: var(--transition); text-decoration: none;
    font-family: 'Open Sans', sans-serif;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); color: #fff; }
.btn-blue { background: var(--btn-bg); color: #fff; }
.btn-blue:hover { background: var(--btn-hover); color: #fff; }
.btn-outline { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-block { display: flex; width: 100%; justify-content: center; }

/* ========== HEADER ========== */
.site-header {
    background: var(--bg); position: sticky; top: 0; z-index: 100;
}
.site-header::after {
    content: ''; position: absolute; bottom: -8px; left: 5%; right: 5%;
    height: 8px; background: transparent;
    box-shadow: 0 4px 8px rgba(0,0,0,0.4);
    border-radius: 100px / 12px;
}
.header-inner {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 0; position: relative;
}
.logo {
    display: flex; align-items: center; gap: 8px;
    font-size: 20px; font-weight: 700; color: var(--text-light);
}
.logo:hover { color: var(--primary); }
.logo-icon { font-size: 22px; }

/* Desktop nav */
.main-nav { display: flex; gap: 2px; align-items: center; }
.nav-link {
    color: var(--text-muted); padding: 8px 14px; border-radius: var(--radius);
    font-size: 14px; font-weight: 400;
}
.nav-link:hover, .nav-link.active { color: var(--primary); }
.nav-link i { font-size: 16px; }

/* Header right group */
.header-right {
    display: flex; align-items: center; gap: 12px;
}

/* Hamburger - always visible (desktop + mobile) */
.menu-toggle {
    display: flex; align-items: center; justify-content: center;
    background: none; border: 1px solid #444;
    color: var(--text); font-size: 20px; cursor: pointer;
    padding: 6px 10px; border-radius: var(--radius);
    transition: var(--transition);
}
.menu-toggle:hover { border-color: var(--primary); color: var(--primary); }

/* Slide-in sidebar menu (from right) */
.sidebar-menu {
    position: fixed; top: 0; right: -320px; width: 300px; height: 100%;
    background: var(--bg-card); z-index: 1000; transition: right 0.3s ease;
    overflow-y: auto; padding: 20px;
    box-shadow: -4px 0 20px rgba(0,0,0,0.5);
}
.sidebar-menu.open { right: 0; }
.sidebar-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.6);
    z-index: 999; display: none;
}
.sidebar-overlay.open { display: block; }
.sidebar-close {
    position: absolute; top: 12px; right: 12px;
    background: none; border: none; color: var(--text-muted);
    font-size: 24px; cursor: pointer; transition: color 0.2s;
}
.sidebar-close:hover { color: var(--primary); }
.sidebar-section-title {
    font-size: 11px; font-weight: 600; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 0.8px;
    padding: 4px 0 8px; margin-top: 4px;
}
.sidebar-menu a.sidebar-link.sidebar-highlight {
    color: var(--primary); font-weight: 600;
}
.sidebar-logo {
    font-size: 22px; font-weight: 700; color: var(--primary);
    margin-bottom: 24px; display: block;
}
.sidebar-menu a.sidebar-link {
    display: block; padding: 12px 0; color: var(--text);
    font-size: 16px; border-bottom: 1px solid var(--border);
}
.sidebar-menu a.sidebar-link:hover { color: var(--primary); }
.sidebar-menu a.sidebar-link i { width: 24px; margin-right: 8px; color: var(--text-muted); }

/* User auth links in header */
.header-auth { display: flex; gap: 12px; align-items: center; }
.header-auth a { font-size: 13px; font-weight: 300; color: var(--text-muted); }
.header-auth a:hover { color: var(--primary); }
.header-auth .reg-link { color: var(--primary); font-weight: 600; }

/* User dropdown */
.user-dropdown { position: relative; }
.user-dropdown-menu {
    display: none; position: absolute; top: 100%; right: 0; min-width: 180px;
    background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
    box-shadow: var(--shadow); z-index: 200; padding: 8px 0;
}
.user-dropdown:hover .user-dropdown-menu { display: block; }
.user-dropdown-menu a {
    display: block; padding: 8px 16px; color: var(--text); font-size: 14px;
}
.user-dropdown-menu a:hover { background: var(--bg-panel); color: var(--primary); }

/* ========== HERO / PAGE HEADER ========== */
.page-hero {
    padding: 40px 0 24px; text-align: center;
    border-bottom: 1px solid var(--border); margin-bottom: 20px;
}
.page-hero h1 { font-size: 26px; font-weight: 700; color: var(--text-light); margin-bottom: 8px; }
.page-hero p { color: var(--text-muted); font-size: 15px; font-weight: 300; }
.page-hero .count { color: var(--primary); font-weight: 600; }

/* ========== FILTER BAR ========== */
.hero-filter {
    background: var(--bg-panel); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 16px 20px; margin-bottom: 20px;
}
.hero-filter-row { display: flex; gap: 12px; align-items: end; flex-wrap: wrap; }
.hero-filter-item { flex: 1; min-width: 130px; }
.hero-filter-item label {
    display: block; font-size: 11px; font-weight: 600;
    color: var(--text-muted); margin-bottom: 4px;
    text-transform: uppercase; letter-spacing: 0.5px;
}
.hero-filter-btn { flex: 0 0 auto; }
.hero-filter-btn .btn { height: 40px; padding: 0 24px; }

.form-control {
    width: 100%; padding: 10px 14px; border: 1px solid var(--border);
    border-radius: var(--radius); font-size: 14px;
    font-family: 'Open Sans', sans-serif;
    background: var(--bg); color: var(--text);
    transition: border-color 0.2s;
}
.form-control:focus { outline: none; border-color: var(--primary); }
select.form-control {
    padding-right: 36px; appearance: none; -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='%23888' d='M8 11L2 5h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 10px center; background-size: 12px;
    cursor: pointer;
}
.form-group { margin-bottom: 14px; }
.form-group label {
    display: block; font-size: 13px; color: var(--text-muted);
    margin-bottom: 4px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.3px;
}

/* Expandable filter */
.filter-extra { display: none; margin-top: 12px; gap: 12px; flex-wrap: wrap; }
.filter-extra.open { display: flex; }
.filter-toggle {
    display: flex; align-items: center; justify-content: center; gap: 6px;
    width: 100%; padding: 10px; margin-top: 10px;
    background: none; border: 1px dashed var(--border); border-radius: var(--radius);
    color: var(--text-muted); font-size: 13px; cursor: pointer; transition: var(--transition);
}
.filter-toggle:hover { color: var(--primary); border-color: var(--primary); }

/* ========== AD CARD GRID (adamieva-style) ========== */
.pl-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    margin: 20px 0;
}
.pl-card {
    display: block; text-decoration: none; color: var(--text);
    background: var(--bg-card); border-radius: 4px; overflow: hidden;
    transition: var(--transition);
}
.pl-card:hover { color: var(--primary); }
.pl-card:hover .pl-card-photo img { transform: scale(1.05); }

.pl-card-photo {
    width: 100%; height: 220px; overflow: hidden;
    background: #222;
}
.pl-card-photo img {
    width: 100%; height: 100%; object-fit: cover; object-position: center top;
    transition: transform 1.5s cubic-bezier(.07,.13,.19,.97);
}
.pl-card-count {
    position: absolute; bottom: 6px; right: 6px;
    background: rgba(0,0,0,0.6); color: #fff; padding: 2px 6px;
    border-radius: 4px; font-size: 11px;
}
.pl-card-photo { position: relative; }

.pl-card-info {
    padding: 8px 6px; text-align: center; font-size: 13px;
    line-height: 1.4;
}
.pl-card-stats { font-weight: 300; }
.pl-card-city { font-weight: 300; }
.pl-card-price {
    font-size: 14px; font-weight: 600; color: var(--primary);
    margin-top: 2px;
}

/* Keep old listing-grid for backwards compat */
.listing-grid {
    display: grid; grid-template-columns: repeat(7, 1fr);
    gap: 6px; margin: 20px 0;
}
.listing-card {
    background: var(--bg-card); border-radius: 4px;
    overflow: hidden; transition: var(--transition);
}
.listing-card:hover { box-shadow: var(--shadow); }
.listing-card:hover .card-image img { transform: scale(1.05); }
.card-image { position: relative; height: 220px; overflow: hidden; background: #222; }
.card-image img {
    width: 100%; height: 100%; object-fit: cover; object-position: center top;
    transition: transform 1.5s cubic-bezier(.07,.13,.19,.97);
}
.card-badge {
    position: absolute; top: 6px; left: 6px;
    background: var(--primary); color: #fff; padding: 2px 8px;
    border-radius: 12px; font-size: 10px; font-weight: 600; text-transform: uppercase;
}
.card-badge.verified { background: #2196f3; }
.card-images-count {
    position: absolute; bottom: 6px; right: 6px;
    background: rgba(0,0,0,0.6); color: #fff; padding: 2px 6px;
    border-radius: 4px; font-size: 11px;
}
.card-body {
    padding: 8px 6px; text-align: center; font-size: 13px; line-height: 1.4;
}
.card-info-line { font-weight: 300; }
.card-price { font-size: 14px; font-weight: 600; color: var(--primary); margin-top: 2px; }

/* ========== INFINITE SCROLL SPINNER ========== */
.load-spinner {
    display: flex; align-items: center; justify-content: center; gap: 10px;
    color: var(--text-muted); font-size: 14px; padding: 16px 0;
}
.spinner {
    width: 24px; height: 24px; border: 3px solid var(--border);
    border-top-color: var(--primary); border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ========== STORIES / RECOMMENDED ========== */
.stories-wrap { margin-bottom: 20px; overflow: hidden; }
.stories-scroll {
    display: flex; gap: 16px; overflow-x: auto; padding: 8px 0 12px;
    scrollbar-width: none;
}
.stories-scroll::-webkit-scrollbar { display: none; }
.story-item {
    display: flex; flex-direction: column; align-items: center;
    gap: 6px; flex-shrink: 0; text-decoration: none; width: 74px;
}
.story-ring {
    width: 66px; height: 66px; border-radius: 50%;
    background: linear-gradient(135deg, #e84393, #fd79a8, #e84393);
    padding: 3px; display: flex; align-items: center; justify-content: center;
    transition: transform 0.2s;
}
.story-item:hover .story-ring { transform: scale(1.1); }
.story-img {
    width: 100%; height: 100%; border-radius: 50%;
    background-size: cover; background-position: center;
    background-color: var(--bg-card); border: 2px solid var(--bg);
}
.story-name {
    font-size: 11px; color: var(--text-muted); text-align: center;
    max-width: 74px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    font-weight: 300;
}
.story-item:hover .story-name { color: var(--primary); }

/* ========== DISTRICTS GRID ========== */
.districts-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px; margin: 20px 0;
}
.district-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 16px;
    display: flex; justify-content: space-between; align-items: center;
    transition: var(--transition); text-decoration: none; color: var(--text);
}
.district-card:hover { border-color: var(--primary); color: var(--primary); }
.district-card h3 { font-size: 15px; font-weight: 500; }
.district-count { color: var(--text-muted); font-size: 13px; font-weight: 300; }

/* ========== PROFILE PAGE ========== */
.profile-header { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin: 16px 0; }

.gallery { position: relative; }
.gallery-main { border-radius: var(--radius); overflow: hidden; aspect-ratio: 3/4; background: #222; cursor: pointer; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 8px; }
.gallery-thumb { border-radius: 4px; overflow: hidden; aspect-ratio: 1; cursor: pointer; border: 2px solid transparent; transition: 0.2s; }
.gallery-thumb:hover, .gallery-thumb.active { border-color: var(--primary); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }

.profile-info {}
.profile-name { font-size: 24px; font-weight: 700; color: var(--text-light); margin-bottom: 8px; }
.profile-meta { display: flex; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--text-muted); margin-bottom: 16px; }
.profile-meta span, .profile-meta a { display: flex; align-items: center; gap: 4px; }
.profile-meta i { color: var(--primary); font-size: 12px; }

/* Contact buttons */
.profile-contact { display: flex; gap: 10px; margin-bottom: 16px; }
.contact-btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 20px; border-radius: var(--radius); font-size: 15px;
    font-weight: 600; cursor: pointer; border: none; transition: 0.2s;
}
.contact-btn.phone { background: var(--primary); color: #fff; }
.contact-btn.phone:hover { background: var(--primary-hover); }
.contact-btn.whatsapp { background: #25d366; color: #fff; }
.contact-btn.whatsapp:hover { background: #1ebe5d; }
.contact-blurred { filter: blur(4px); transition: 0.3s; user-select: none; }

.profile-description {
    max-height: 160px; overflow: hidden; position: relative; transition: max-height 0.3s;
}
.profile-description::after {
    content: ''; position: absolute; bottom: 0; left: 0; right: 0;
    height: 60px; background: linear-gradient(transparent, var(--bg-card));
    pointer-events: none;
}
.profile-description.expanded { max-height: none; }
.profile-description.expanded::after { display: none; }
.read-more { text-align: center; margin-top: -20px; position: relative; z-index: 1; }

/* Details grid */
.details-grid {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px;
}
.detail-item {
    display: flex; justify-content: space-between; padding: 8px 0;
    border-bottom: 1px solid var(--border); font-size: 14px;
}
.detail-label { color: var(--text-muted); font-weight: 300; }
.detail-value { font-weight: 500; color: var(--text-light); }

/* Services */
.services-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.service-badge {
    background: rgba(225,16,142,0.12); color: var(--primary);
    padding: 4px 12px; border-radius: 20px; font-size: 12px; font-weight: 500;
    transition: 0.2s;
}
.service-badge:hover { background: var(--primary); color: #fff; }

/* Reactions */
.reactions { display: flex; gap: 8px; margin: 16px 0; }
.reaction-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 16px; border-radius: 20px;
    background: var(--bg-panel); border: 1px solid var(--border);
    color: var(--text-muted); cursor: pointer; font-size: 14px; transition: 0.2s;
}
.reaction-btn:hover { border-color: var(--primary); color: var(--primary); }
.active-like { background: rgba(76,175,80,0.15); border-color: #4caf50; color: #4caf50; }
.active-dislike { background: rgba(244,67,54,0.15); border-color: #f44336; color: #f44336; }

/* ========== LIGHTBOX ========== */
.lightbox {
    position: fixed; inset: 0; background: rgba(0,0,0,0.95);
    z-index: 10000; display: none; align-items: center; justify-content: center;
    flex-direction: column;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 90%; max-height: 80vh; border-radius: 4px; }
.lightbox-close {
    position: absolute; top: 16px; right: 16px; color: #fff;
    font-size: 28px; cursor: pointer; background: none; border: none; z-index: 10001;
}
.lightbox-prev, .lightbox-next {
    position: absolute; top: 50%; transform: translateY(-50%);
    color: #fff; font-size: 32px; cursor: pointer;
    background: rgba(255,255,255,0.1); border: none;
    width: 44px; height: 60px; border-radius: 4px;
}
.lightbox-prev { left: 12px; }
.lightbox-next { right: 12px; }
.lightbox-counter { color: #aaa; font-size: 14px; margin-top: 12px; }

/* Lightbox contact */
.lightbox-contact {
    position: absolute; bottom: 0; left: 0; right: 0;
    display: flex; justify-content: center; gap: 12px;
    padding: 16px; background: linear-gradient(transparent, rgba(0,0,0,0.9));
}
.lightbox-wa-btn, .lightbox-phone-btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 24px; border-radius: 30px; font-size: 15px;
    font-weight: 600; text-decoration: none; transition: 0.2s;
}
.lightbox-wa-btn { background: #25d366; color: #fff; }
.lightbox-wa-btn:hover { background: #1ebe5d; color: #fff; }
.lightbox-phone-btn { background: var(--primary); color: #fff; }
.lightbox-phone-btn:hover { background: var(--primary-hover); color: #fff; }

/* ========== SEARCH PAGE ========== */
.search-filter-grid {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-bottom: 20px;
}

/* ========== AUTH FORMS ========== */
.auth-container {
    max-width: 480px; margin: 40px auto;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 32px;
}
.auth-container h1 { color: var(--text-light); font-size: 24px; margin-bottom: 24px; text-align: center; }
.auth-link { text-align: center; margin-top: 16px; color: var(--text-muted); font-size: 14px; }

/* POST AD FORM */
.post-ad-form {
    max-width: 800px; margin: 24px auto;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 32px;
}
.post-ad-form h1 { color: var(--text-light); font-size: 24px; margin-bottom: 24px; }
.post-ad-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.checkbox-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 8px; }
.checkbox-grid label { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--text); cursor: pointer; }
.checkbox-grid input[type="checkbox"] { accent-color: var(--primary); }

/* ========== ALERTS ========== */
.alert { padding: 12px 16px; border-radius: var(--radius); margin-bottom: 16px; font-size: 14px; }
.alert-success { background: rgba(76,175,80,0.15); color: #4caf50; border: 1px solid rgba(76,175,80,0.3); }
.alert-error { background: rgba(244,67,54,0.15); color: #f44336; border: 1px solid rgba(244,67,54,0.3); }

/* ========== FOOTER ========== */
.site-footer {
    background: #0a0a10; padding: 40px 0 20px; margin-top: 40px;
    border-top: 1px solid var(--border);
}
.footer-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.footer-col h4 { color: var(--text-light); margin-bottom: 12px; font-size: 15px; font-weight: 600; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 6px; }
.footer-col ul li a { color: var(--text-muted); font-size: 13px; font-weight: 300; }
.footer-col ul li a:hover { color: var(--primary); }
.footer-col p { font-size: 13px; font-weight: 300; line-height: 1.6; }
.footer-bottom { border-top: 1px solid var(--border); margin-top: 24px; padding-top: 16px; text-align: center; }
.footer-bottom p { font-size: 12px; color: #555; font-weight: 300; }

/* ========== PAGINATION ========== */
.pagination { display: flex; justify-content: center; gap: 4px; margin: 24px 0; }
.pagination a, .pagination span {
    padding: 8px 14px; border-radius: var(--radius); font-size: 14px;
    border: 1px solid var(--border); color: var(--text);
}
.pagination a:hover { border-color: var(--primary); color: var(--primary); }
.pagination .active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ========== PAGE CONTENT ========== */
.page-content {
    background: var(--bg-card); border-radius: var(--radius);
    padding: 32px; max-width: 800px; margin: 24px auto; line-height: 1.8;
}
.page-content h1 { color: var(--text-light); margin-bottom: 20px; }
.page-content h2 { color: var(--text-light); margin: 20px 0 10px; }

/* Breadcrumb */
nav[style*="padding: 16px"] a { color: var(--text-muted); }
nav[style*="padding: 16px"] a:hover { color: var(--primary); }

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
    .pl-grid, .listing-grid { grid-template-columns: repeat(5, 1fr); }
}
@media (max-width: 1000px) {
    .main-nav { display: none; }
    .header-auth { display: none; }
    .pl-grid, .listing-grid { grid-template-columns: repeat(4, 1fr); }
    .profile-header { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 768px) {
    .pl-grid, .listing-grid { grid-template-columns: repeat(3, 1fr); gap: 4px; }
    .pl-card-photo, .card-image { height: 180px; }
    .search-filter-grid { grid-template-columns: 1fr; }
    .post-ad-grid { grid-template-columns: 1fr; }
    .filter-extra { flex-direction: column; }
    .details-grid { grid-template-columns: 1fr; }
    .gallery-thumbs { grid-template-columns: repeat(4, 1fr); }
    .lightbox-contact { flex-direction: column; align-items: center; }
    .districts-grid { grid-template-columns: repeat(2, 1fr); }
    /* Filter: 2-column grid on mobile */
    .hero-filter { padding: 12px 14px; }
    .hero-filter-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; align-items: end; }
    .hero-filter-btn { grid-column: 1 / -1; }
    .hero-filter-btn .btn { height: 44px; font-size: 15px; }
    .hero-filter-item label { font-size: 10px; margin-bottom: 3px; }
    .hero-filter .form-control { padding: 9px 10px; padding-right: 32px; font-size: 13px; }
    .hero-filter-collapse { display: none; }
    .hero-filter-collapse.open { display: flex; flex-direction: column; gap: 8px; }
    .sidebar { display: none; }
}
@media (max-width: 480px) {
    .pl-grid, .listing-grid { grid-template-columns: repeat(2, 1fr); gap: 4px; }
    .pl-card-photo, .card-image { height: 160px; }
    .pl-card-info, .card-body { font-size: 12px; padding: 6px 4px; }
    .districts-grid { grid-template-columns: 1fr; }
    .page-hero h1 { font-size: 20px; }
}
/* Partners section */
.footer-partners { border-top: 1px solid var(--border); padding: 20px 0 16px; }
.footer-partners h4 { font-size: 13px; color: var(--text-light); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 14px; }
.partners-banners { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.partners-banners img { max-width: 100%; height: auto; }
/* ========== SECTION INTRO ========== */
.section-intro {
    margin-bottom: 20px;
}
.section-intro > .container {
    background: var(--bg-panel); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 18px 20px;
}
.section-intro h2 {
    font-size: 17px; font-weight: 600; color: var(--text-light); margin-bottom: 8px;
}
.section-intro p {
    font-size: 14px; line-height: 1.65; color: var(--text); font-weight: 300;
}
.section-intro ul {
    margin: 10px 0 0; padding: 0; list-style: none;
    display: flex; flex-wrap: wrap; gap: 6px 20px;
}
.section-intro li {
    font-size: 13px; color: var(--text-muted); padding-left: 16px; position: relative;
}
.section-intro li::before {
    content: ""; position: absolute; left: 0; top: 7px;
    width: 6px; height: 6px; border-radius: 50%; background: var(--primary);
}
@media (max-width: 640px) {
    .section-intro > .container { padding: 14px 16px; }
    .section-intro h2 { font-size: 16px; }
    .section-intro ul { flex-direction: column; gap: 6px; }
}

/* ========== LISTING PAGE + SIDEBAR ========== */
/* .layout-with-sidebar / .sidebar-box / .sidebar-list / .count-badge were used
   in the markup but never had any rules, so the whole block dropped below the
   grid unstyled. */
.layout-with-sidebar {
    display: grid; grid-template-columns: minmax(0, 1fr) 280px;
    gap: 24px; align-items: start;
}
.sidebar { position: sticky; top: 76px; display: flex; flex-direction: column; gap: 14px; }
.sidebar-box {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 14px 16px;
}
.sidebar-box h3 {
    font-size: 13px; font-weight: 600; color: var(--text-light);
    text-transform: uppercase; letter-spacing: 0.6px;
    padding-bottom: 10px; margin-bottom: 4px; border-bottom: 1px solid var(--border);
}
.sidebar-list { list-style: none; margin: 0; padding: 0; }
.sidebar-list li + li { border-top: 1px solid var(--border); }
.sidebar-list a {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding: 9px 2px; font-size: 14px; color: var(--text);
}
.sidebar-list a:hover { color: var(--primary); }
.count-badge {
    flex: 0 0 auto; min-width: 26px; text-align: center;
    background: var(--bg-panel); border: 1px solid var(--border); border-radius: 20px;
    padding: 1px 8px; font-size: 11px; font-weight: 600; color: var(--text-muted);
}
.sidebar-list a:hover .count-badge { border-color: var(--primary); color: var(--primary); }

@media (max-width: 980px) {
    .layout-with-sidebar { grid-template-columns: minmax(0, 1fr); }
    .sidebar { position: static; flex-direction: row; flex-wrap: wrap; }
    .sidebar-box { flex: 1 1 260px; }
}

/* ========== CITY ARTICLE + FAQ ========== */
.city-article {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 26px 30px; margin: 8px 0 20px;
}
.city-article h2 {
    font-size: 19px; font-weight: 600; color: var(--text-light);
    margin: 26px 0 10px; line-height: 1.35;
}
.city-article h2:first-child { margin-top: 0; }
.city-article p {
    font-size: 14.5px; line-height: 1.8; color: var(--text);
    font-weight: 300; margin-bottom: 12px;
}
.city-article p:last-child { margin-bottom: 0; }
.city-article a { color: var(--primary); }
.city-article a:hover { text-decoration: underline; }

.city-faq { margin: 0 0 34px; }
.city-faq h2 {
    font-size: 17px; font-weight: 600; color: var(--text-light); margin-bottom: 12px;
}
.city-faq details {
    border-bottom: 1px solid var(--border);
}
.city-faq details:first-of-type { border-top: 1px solid var(--border); }
.city-faq summary {
    list-style: none; cursor: pointer; position: relative;
    padding: 14px 34px 14px 2px;
    font-size: 15px; color: var(--text-light); font-weight: 400;
}
.city-faq summary::-webkit-details-marker { display: none; }
.city-faq summary::after {
    content: ""; position: absolute; right: 8px; top: 50%;
    width: 8px; height: 8px; margin-top: -6px;
    border-right: 2px solid var(--text-muted); border-bottom: 2px solid var(--text-muted);
    transform: rotate(45deg); transition: var(--transition);
}
.city-faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.city-faq summary:hover { color: var(--primary); }
.city-faq details p {
    padding: 0 34px 16px 2px; margin: 0;
    font-size: 14px; line-height: 1.75; color: var(--text-muted); font-weight: 300;
}

@media (max-width: 640px) {
    .city-article { padding: 18px 18px; }
    .city-article h2 { font-size: 17px; margin-top: 20px; }
    .city-article p { font-size: 14px; }
}

/* ========== INFINITE SCROLL ========== */
/* .load-spinner / .spinner were referenced by the homepage feed but never
   styled, so the loading state was invisible. */
#infinite-scroll-trigger { text-align: center; padding: 26px 0 10px; min-height: 40px; }
.load-spinner {
    display: none; align-items: center; justify-content: center; gap: 10px;
    color: var(--text-muted); font-size: 14px;
}
.spinner {
    width: 18px; height: 18px; border-radius: 50%;
    border: 2px solid var(--border); border-top-color: var(--primary);
    animation: k24spin 0.7s linear infinite;
}
@keyframes k24spin { to { transform: rotate(360deg); } }
.feed-end { color: var(--text-muted); font-size: 14px; padding: 8px 0; }

/* ============================================================
   REFINEMENT LAYER
   Loaded last, so these win over the earlier rules on ties.
   Goal: one spacing scale, one radius scale, real type hierarchy,
   and no emoji standing in for icons.
   ============================================================ */

:root {
    /* spacing scale - every margin/padding below picks from this */
    --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
    --sp-5: 24px; --sp-6: 32px; --sp-7: 48px;

    /* radius scale - cards were 4px while everything else was 8px */
    --r-sm: 6px; --r-md: 10px; --r-lg: 14px; --r-pill: 999px;

    /* type scale */
    --fs-xs: 11px; --fs-sm: 13px; --fs-base: 14px;
    --fs-md: 16px; --fs-lg: 20px; --fs-xl: 26px; --fs-2xl: 32px;

    --elev-1: 0 1px 2px rgba(0,0,0,.35);
    --elev-2: 0 6px 20px rgba(0,0,0,.45);
    --ring: 0 0 0 2px rgba(225,16,142,.35);

    --bg-hover: #23232f;
}

body { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }

::selection { background: var(--primary); color: #fff; }

:focus-visible {
    outline: none;
    box-shadow: var(--ring);
    border-radius: var(--r-sm);
}

/* ---------- header ---------- */
.site-header {
    border-bottom: 1px solid var(--border);
    background: rgba(17,17,24,.88);
    backdrop-filter: saturate(140%) blur(10px);
}
.site-header::after { display: none; }   /* the old fake drop-shadow strip */
.header-inner { padding: var(--sp-3) 0; }
.logo { font-size: 19px; letter-spacing: -.2px; }

.main-nav { gap: var(--sp-1); }
.nav-link {
    position: relative;
    padding: var(--sp-2) var(--sp-3);
    font-size: var(--fs-base);
    font-weight: 400;
    border-radius: var(--r-sm);
}
.nav-link:hover { color: var(--text-light); background: var(--bg-panel); }
.nav-link.active { color: var(--text-light); background: transparent; }
.nav-link.active::after {
    content: ""; position: absolute; left: var(--sp-3); right: var(--sp-3); bottom: 2px;
    height: 2px; border-radius: 2px; background: var(--primary);
}

/* ---------- page hero ---------- */
.page-hero {
    padding: var(--sp-6) 0 var(--sp-4);
    text-align: left;
    border-bottom: none;
    margin-bottom: var(--sp-3);
}
.page-hero h1 {
    font-size: var(--fs-xl);
    font-weight: 700;
    letter-spacing: -.4px;
    line-height: 1.2;
    margin-bottom: var(--sp-2);
}
.page-hero p { font-size: var(--fs-base); color: var(--text-muted); }
.page-hero .count { color: var(--text-light); font-weight: 600; }

/* ---------- facet chips ---------- */
.facet-bar {
    display: flex; flex-wrap: wrap; gap: var(--sp-2);
    margin: 0 0 var(--sp-4);
}
.facet-chip {
    display: inline-flex; align-items: center; gap: var(--sp-2);
    padding: 7px var(--sp-3);
    border: 1px solid var(--border); border-radius: var(--r-pill);
    background: var(--bg-card); color: var(--text);
    font-size: var(--fs-sm); font-weight: 400; white-space: nowrap;
    transition: var(--transition);
}
.facet-chip i { font-size: 12px; color: var(--text-muted); }
.facet-chip:hover { border-color: var(--primary); color: var(--text-light); }
.facet-chip:hover i { color: var(--primary); }
.facet-chip.is-active {
    background: var(--primary); border-color: var(--primary); color: #fff;
}
.facet-chip.is-active i { color: #fff; }
.facet-chip .n { color: var(--text-muted); font-size: var(--fs-xs); }
.facet-chip.is-active .n { color: rgba(255,255,255,.75); }

/* ---------- section heading ---------- */
.section-head {
    display: flex; align-items: baseline; justify-content: space-between;
    gap: var(--sp-4); margin: var(--sp-6) 0 var(--sp-4);
}
.section-head h2 {
    font-size: var(--fs-lg); font-weight: 700; color: var(--text-light);
    letter-spacing: -.3px;
}
.section-head .section-link {
    font-size: var(--fs-sm); color: var(--text-muted); white-space: nowrap;
}
.section-head .section-link:hover { color: var(--primary); }

/* ---------- cards ---------- */
.listing-grid, .pl-grid { gap: var(--sp-3); margin: 0 0 var(--sp-5); }

.pl-card {
    border-radius: var(--r-md);
    border: 1px solid var(--border);
    background: var(--bg-card);
    box-shadow: var(--elev-1);
}
.pl-card:hover {
    border-color: #3a3a4d;
    transform: translateY(-2px);
    box-shadow: var(--elev-2);
}
.pl-card-photo {
    height: auto; aspect-ratio: 3 / 4;
    border-radius: var(--r-md) var(--r-md) 0 0;
}
.pl-card-count {
    bottom: var(--sp-2); right: var(--sp-2);
    background: rgba(0,0,0,.62); backdrop-filter: blur(4px);
    border-radius: var(--r-pill); padding: 3px 8px;
    font-size: var(--fs-xs); letter-spacing: .2px;
}
.pl-card-info {
    padding: var(--sp-3) var(--sp-3) var(--sp-3);
    text-align: left;
}
.pl-card-stats {
    font-size: var(--fs-sm); color: var(--text-light); font-weight: 600;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pl-card-city {
    font-size: var(--fs-xs); color: var(--text-muted); font-weight: 400;
    margin-top: 2px; text-transform: uppercase; letter-spacing: .4px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pl-card-price {
    margin-top: var(--sp-2); font-size: var(--fs-sm);
    font-weight: 700; color: var(--primary);
}

/* ---------- detail specs (were emoji) ---------- */
.details-grid { gap: var(--sp-2); }
.detail-item {
    display: flex; align-items: center; justify-content: space-between;
    gap: var(--sp-3);
    padding: 10px var(--sp-3);
    background: var(--bg-panel); border: 1px solid var(--border);
    border-radius: var(--r-sm);
}
.detail-label {
    display: inline-flex; align-items: center; gap: var(--sp-2);
    font-size: var(--fs-sm); color: var(--text-muted); white-space: nowrap;
}
.detail-label i { width: 14px; text-align: center; color: var(--primary); opacity: .8; }
.detail-value { font-size: var(--fs-sm); color: var(--text-light); font-weight: 600; text-align: right; }

/* ---------- editorial blocks ---------- */
.city-article, .home-article { border-radius: var(--r-lg); }
.city-article h2 { letter-spacing: -.2px; }
.section-intro > .container { border-radius: var(--r-lg); }

/* ---------- sidebar ---------- */
.sidebar-box { border-radius: var(--r-md); }
.sidebar-box h3 { font-size: var(--fs-xs); letter-spacing: .8px; }

/* ---------- districts ---------- */
.district-card {
    border-radius: var(--r-md); border: 1px solid var(--border);
    transition: var(--transition);
}
.district-card:hover { border-color: var(--primary); transform: translateY(-2px); }

/* ---------- buttons ---------- */
.btn { border-radius: var(--r-sm); font-weight: 600; letter-spacing: .1px; }
.btn-sm { font-size: var(--fs-sm); }

/* ---------- pagination / feed end ---------- */
.pagination a, .pagination span { border-radius: var(--r-sm); }

@media (max-width: 640px) {
    .page-hero { padding: var(--sp-5) 0 var(--sp-3); }
    .page-hero h1 { font-size: var(--fs-lg); }
    .section-head { margin: var(--sp-5) 0 var(--sp-3); }
    .pl-card-info { padding: var(--sp-2); }
    .facet-bar { gap: 6px; }
    .facet-chip { padding: 6px 10px; font-size: 12px; }
}

/* ---------- logo mark (was a 💋 emoji) ---------- */
.logo-mark {
    display: inline-flex; align-items: center; justify-content: center;
    width: 28px; height: 28px; flex: 0 0 28px;
    background: var(--primary); color: #fff;
    border-radius: 8px;
    font-weight: 700; font-size: 15px; line-height: 1;
    letter-spacing: -.5px;
}
.logo-text { font-weight: 700; }
.logo-accent { color: var(--primary); }
.logo:hover { color: var(--text-light); }
.logo:hover .logo-mark { background: var(--primary-hover); }
.sidebar-logo { display: flex; align-items: center; gap: 8px; color: var(--text-light); }

/* ---------- admin: phone queue ---------- */
.admin-flash { background: rgba(225,16,142,.1); border: 1px solid var(--primary);
    border-radius: var(--r-sm); padding: 10px 14px; margin-bottom: var(--sp-4); font-size: var(--fs-base); }
.admin-flash .warn { color: #e0a83a; margin-left: 8px; }
.admin-empty, .admin-hint { color: var(--text-muted); font-size: var(--fs-base); margin-bottom: var(--sp-4); }
.phone-queue { display: flex; flex-direction: column; gap: var(--sp-2); }
.phone-row {
    display: grid; grid-template-columns: 56px minmax(0,1fr) 190px auto;
    align-items: center; gap: var(--sp-3);
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--r-md); padding: var(--sp-2) var(--sp-3);
}
.phone-thumb { width: 56px; height: 72px; object-fit: cover; border-radius: var(--r-sm); }
.phone-name { color: var(--text-light); font-size: var(--fs-base); font-weight: 600;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.phone-city { color: var(--text-muted); font-size: var(--fs-sm); }
.phone-src { font-size: var(--fs-sm); }
.phone-input { font-size: var(--fs-md); letter-spacing: .5px; }
.phone-actions { margin: var(--sp-5) 0 var(--sp-7); }
@media (max-width: 720px) {
    .phone-row { grid-template-columns: 48px 1fr; }
    .phone-input, .phone-skip { grid-column: 1 / -1; }
}

/* ---------- footer: tags ---------- */
.footer-tags { border-top: 1px solid var(--border); padding: var(--sp-4) 0 0; margin-top: var(--sp-4); }
.footer-tags h4 {
    font-size: var(--fs-xs); letter-spacing: .9px; text-transform: uppercase;
    color: var(--text-light); margin-bottom: var(--sp-3);
}
.fp-views { color: var(--text-muted); font-size: var(--fs-xs); }
.tag-row { display: flex; flex-wrap: wrap; gap: var(--sp-2); padding-bottom: var(--sp-4); }
.tag {
    padding: 5px 11px; border-radius: var(--r-pill);
    background: var(--bg-panel); border: 1px solid var(--border);
    font-size: 12.5px; color: var(--text-muted); transition: var(--transition);
}
.tag:hover { border-color: var(--primary); color: var(--primary); }
.footer-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--sp-5);
}
.footer-col ul { margin: 0; padding: 0; list-style: none; }
.footer-col li { margin: 0; }
.footer-col a { font-size: 13.5px; line-height: 1.55; }
.footer-col h4 { margin-bottom: var(--sp-2); }
/* the popular column carries the longest strings - let it wrap instead of
   pushing the other three out of the row */
.footer-col a { display: inline-block; }
.fp-views { white-space: nowrap; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }


/* --- Gumb "sve fotografije" preko glavne slike (kompanionki24.com) --- */
.gallery-main { position: relative; }
.gallery-all-btn {
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 14px;
    border: 0;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.62);
    color: #fff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
    transition: background 0.2s, transform 0.2s;
}
.gallery-all-btn:hover,
.gallery-all-btn:focus-visible {
    background: var(--primary);
    transform: translateY(-1px);
}
.gallery-all-btn i { font-size: 14px; }
@media (max-width: 768px) {
    .gallery-all-btn { right: 8px; bottom: 8px; padding: 8px 12px; font-size: 12px; }
}

/* ===== LIGHTBOX CONTACT BAR — 2026-09-11 v2 =====
   The WhatsApp/phone bar was absolutely positioned over the photo, so on phones the green
   pill covered the bottom third of the picture. It now sits in the lightbox's flex column
   under the image.
   Written to cover both layouts in this family: on kompanionki24/erotik-anzeigen .lightbox
   is already a flex column with the bar at bottom:0, while putas46/escortia/lystnorge/…
   centre a flex row and place the bar at bottom:12px with translateX(-50%) — hence the
   explicit left/bottom/transform resets below.
   z-index: that second variant sits at 1000, below the z-index:9001 sticky contact bar,
   which then painted over the open lightbox. */
.lightbox {
    z-index: 10000;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 52px 8px 12px;
}
.lightbox.open { display: flex; }
.lightbox img { max-height: 68vh; max-width: 92vw; object-fit: contain; }
.lightbox-contact {
    position: static;
    top: auto; right: auto; bottom: auto; left: auto;
    transform: none;
    width: auto;
    background: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    padding: 12px 0 0;
}
@media (max-width: 768px) {
    .lightbox { padding: 48px 6px 10px; }
    .lightbox img { max-height: 56vh; }
    /* one wrapping row — stacked, the buttons ate half the screen */
    .lightbox-contact { flex-direction: row; gap: 8px; padding: 10px 4px 0; }
    .lightbox-wa-btn, .lightbox-phone-btn { padding: 10px 16px; font-size: 14px; }
}

/* Trans cams bar — /trans only, printed by all-listing.php */
.trans-cams {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    margin: 0 0 18px; padding: 12px 16px; border-radius: 10px; color: #fff;
    background: linear-gradient(135deg, #7b1fa2 0%, #e91e63 100%);
}
.trans-cams-title { font-weight: 600; font-size: 15px; display: flex; align-items: center; gap: 8px; margin-right: auto; }
.trans-cams-dot { width: 9px; height: 9px; border-radius: 50%; background: #43d675; animation: transCamsDot 1.6s infinite; }
@keyframes transCamsDot { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
.trans-cams a {
    background: rgba(255,255,255,0.18); color: #fff; text-decoration: none;
    font-size: 14px; padding: 8px 16px; border-radius: 6px; white-space: nowrap; transition: background 0.2s;
}
.trans-cams a:hover { background: rgba(255,255,255,0.32); }
@media (max-width: 600px) {
    .trans-cams-title { width: 100%; font-size: 14px; }
    .trans-cams a { flex: 1; text-align: center; }
}
