/* Basic styles for Property250 marketplace */
* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

html, body {
    margin: 0;
    min-height: 100%;
}

body {
    font-family: 'Inter', Arial, sans-serif;
    background: linear-gradient(180deg, #eef2f7 0%, #f8fafc 100%);
    color: #1f2937;
    line-height: 1.6;
}

a { color: inherit; text-decoration: none; }

button, select, input {
    font: inherit;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 32px;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(148, 163, 184, 0.28);
    position: sticky;
    top: 0;
    z-index: 10;
}

.logo {
    font-size: 1.45rem;
    font-weight: 700;
    color: #1f2937;
}


.site-header nav {
    display: flex;
    align-items: center;
    gap: 22px;
}

.site-header nav a {
    font-size: 0.95rem;
    color: #334155;
}

.site-header nav a:hover {
    color: #1d4ed8;
}

.site-header nav a.admin-logout-button {
    color: #b91c1c;
    border: 1px solid rgba(185, 28, 28, 0.18);
    padding: 8px 14px;
    border-radius: 999px;
}

.site-header nav a.admin-logout-button:hover {
    color: #7f1d1d;
    background: rgba(254, 202, 202, 0.45);
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

/* Profile dropdown */
.user-profile { position: relative; }
.profile-dropdown {
    position: absolute;
    top: 46px;
    right: 0;
    background: #fff;
    border: 1px solid rgba(148,163,184,0.12);
    box-shadow: 0 6px 18px rgba(15,23,42,0.06);
    border-radius: 8px;
    min-width: 220px;
    z-index: 40;
    display: none;
    padding: 8px 0;
}
.profile-dropdown a {
    display: block;
    padding: 10px 14px;
    color: #0f172a;
    text-decoration: none;
    font-size: 0.95rem;
}
.profile-dropdown a:hover { background: #f8fafc; }
.user-profile.show-dropdown .profile-dropdown { display: block; }

.profile-photo {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #e2e8f0;
    border: 2px solid #cbd5e1;
    object-fit: cover;
    display: block;
}

.profile-username {
    font-size: 0.9rem;
    color: #334155;
    font-weight: 500;
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-banner {
    max-width: 1200px;
    margin: 16px auto;
    padding: 18px 24px;
    border-radius: 20px;
    background: #e0f2fe;
    border: 1px solid #bae6fd;
    color: #0369a1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.admin-banner p {
    margin: 0;
    font-weight: 700;
}

.admin-banner a {
    display: inline-flex;
}

.hero {
    width: 100%;
    min-height: 100vh;
    background-image: url('background.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    margin-bottom: 40px;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
}

.overlay {
    width: 100%;
    min-height: 100vh;
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
}

.content {
    width: 50%;
    margin-left: 8%;
    color: white;
}

.content h1 {
    font-size: clamp(3rem, 4vw, 4.8rem);
    line-height: 1.08;
    margin-bottom: 20px;
    max-width: 12ch;
}

.content p {
    font-size: 1.05rem;
    line-height: 1.75;
    margin-bottom: 30px;
    max-width: 46ch;
    color: rgba(255, 255, 255, 0.91);
}

.buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 22px;
}

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 15px 35px;
    border-radius: 6px;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.btn-primary {
    background: #0d6efd;
    color: white;
}

.btn-primary:hover {
    background: #0b5ed7;
    transform: translateY(-1px);
}

.btn-secondary {
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background: white;
    color: black;
    transform: translateY(-1px);
}

.badge {
    display: inline-flex;
    padding: 8px 14px;
    border-radius: 999px;
    background: #eef2ff;
    color: #2563eb;
    font-size: 0.85rem;
    margin-bottom: 18px;
}

.hero-copy h1 {
    margin: 0 0 22px;
    font-size: clamp(2.5rem, 4vw, 4.4rem);
    line-height: 1.02;
    color: #0f172a;
}

.hero-copy p {
    margin: 0 0 28px;
    color: #475569;
    max-width: 580px;
    font-size: 1.05rem;
}

.search-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-top: 0;
    padding: 0;
}

.search-item {
    background: #ffffff;
    border-radius: 20px;
    padding: 22px;
    box-shadow: 0 22px 46px rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(226, 232, 240, 0.95);
}

.search-item label {
    display: block;
    margin-bottom: 10px;
    color: #475569;
    font-size: 0.9rem;
}

.search-item input,
.search-item select {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    background: #f8fafc;
    color: #0f172a;
}

.button-item {
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.button-item button {
    width: 100%;
    padding: 16px 18px;
    border: none;
    border-radius: 16px;
    background: #1d4ed8;
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.button-item button:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.panel-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 260px;
    padding: 16px 22px;
    border-radius: 18px;
    background: #2563eb;
    color: #ffffff;
    font-weight: 700;
    text-decoration: none;
    border: none;
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

.panel-button:hover,
.panel-button:focus-visible {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.18);
}

.panel-button.secondary {
    background: #e2e8f0;
    color: #0f172a;
}

.panel-button.secondary:hover,
.panel-button.secondary:focus-visible {
    background: #cbd5e1;
}

/* Modal for listing choice */
.rl-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.rl-modal {
    background: #ffffff;
    border-radius: 12px;
    padding: 20px 22px;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.2);
    color: #0f172a;
}

.rl-modal h3 { margin-top: 0; }

.rl-modal .rl-actions { display:flex; gap:12px; margin-top:12px; }
.rl-modal button.primary, .rl-modal .primary {
    background: #2563eb; color: #fff; border: none; padding: 10px 14px; border-radius: 8px; cursor:pointer; font-weight:700;
}
.rl-modal button.secondary, .rl-modal .secondary {
    background: #f1f5f9; color: #0f172a; border: 1px solid #cbd5e1; padding: 10px 14px; border-radius: 8px; cursor:pointer; font-weight:700;
}
.rl-modal .ghost {
    background: transparent; border: none; color: #475569; padding: 8px 10px; cursor: pointer; font-weight:600;
}
.rl-modal .ghost.close { color: #ef4444; }
.rl-modal .ghost.back { color: #374151; }

/* small utility for auth area buttons */
.auth-panel .panel-button { max-width: 220px; }


.panel-button.disabled,
.panel-button.disabled:hover,
.panel-button.disabled:focus-visible {
    background: #e2e8f0;
    color: #64748b;
    cursor: default;
    transform: none;
    box-shadow: none;
}

@media (max-width: 640px) {
    .site-header { padding: 12px 16px; }
    .logo { font-size: 1.15rem; }
}

.dashboard-card .panel-button {
    margin-top: 18px;
}

.home-categories {
    max-width: 1200px;
    margin: 20px auto 0;
    padding: 0 24px 24px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.device-support {
    max-width: 1200px;
    margin: 16px auto 0;
    padding: 0 24px 28px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.device-card {
    background: #ffffff;
    border-radius: 24px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    padding: 26px 22px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.06);
}

.device-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border-radius: 16px;
    background: #dbeafe;
    color: #1d4ed8;
    margin-bottom: 18px;
}

.device-icon svg {
    width: 28px;
    height: 28px;
}

.device-card h3 {
    margin: 0 0 10px;
    font-size: 1.05rem;
}

.device-card p {
    margin: 0;
    color: #475569;
    line-height: 1.65;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 28px;
}

.hero-actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 170px;
    padding: 16px 24px;
    border-radius: 999px;
    font-weight: 700;
    transition: transform 0.2s ease, background 0.2s ease;
}

.hero-actions .primary {
    background: #2563eb;
    color: #ffffff;
}

.hero-actions .primary:hover {
    background: #1d4ed8;
}

.hero-actions .secondary {
    background: #f8fafc;
    color: #0f172a;
    border: 1px solid #cbd5e1;
}

.hero-actions .secondary:hover {
    background: #eef2ff;
}

.hero-caption {
    margin-top: 24px;
    color: #334155;
    font-size: 0.96rem;
}

.hero-caption a {
    color: #2563eb;
    text-decoration: none;
    font-weight: 700;
}

.hero-caption a:hover {
    text-decoration: underline;
}

.search-section {
    max-width: 1200px;
    margin: 0 auto 32px;
    padding: 0 24px;
}

.category-card {
    background: #0f172a;
    border-radius: 24px;
    padding: 28px;
    color: #f8fafc;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.18);
}

.category-card h3 {
    margin: 0 0 14px;
}

.category-card p {
    margin: 0 0 18px;
    color: #cbd5e1;
}

.category-card a {
    color: #ffffff;
    font-weight: 700;
}

.results-preview {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.section-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.section-header h2 {
    margin: 0;
    font-size: 1.8rem;
}

.section-header p {
    margin: 6px 0 0;
    color: #475569;
}

.section-header a {
    color: #1d4ed8;
    font-weight: 700;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
    margin-bottom: 32px;
}

.listing-detail {
    max-width: 1200px;
    margin: 0 auto 28px;
    padding: 0 24px;
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 24px;
    align-items: start;
}

.listing-detail img {
    width: 100%;
    border-radius: 18px;
    object-fit: cover;
    max-height: 440px;
}

/* Make listing detail stack on narrower viewports */
@media (max-width: 900px) {
    .listing-detail {
        grid-template-columns: 1fr;
        padding: 0 24px;
        gap: 16px;
    }

    .listing-detail img {
        max-height: 380px;
    }
}
.listing-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.card-body {
    padding: 18px 18px 20px;
}

.card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.card-type {
    background: #e2e8f0;
    padding: 6px 12px;
    border-radius: 999px;
    color: #334155;
    font-size: 0.8rem;
}

.tag {
    display: inline-flex;
    padding: 6px 12px;
    border-radius: 999px;
    background: #dbeafe;
    color: #1d4ed8;
    font-size: 0.8rem;
}

.card-body h3 {
    margin: 0 0 10px;
    font-size: 1.15rem;
}

.card-body p {
    margin: 0 0 16px;
    color: #475569;
}

.card-body strong {
    color: #0f172a;
}

.image-slider {
    background: #ffffff;
    border-radius: 24px;
    padding: 20px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
}

.slider-window {
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 16px;
}

.slider-window img {
    width: 100%;
    display: block;
    object-fit: cover;
    height: 520px;
}

.slider-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.image-gallery-note {
    margin: 0 0 12px;
    color: #475569;
    font-size: 0.95rem;
}

.slider-controls button {
    border: 1px solid #cbd5e1;
    background: #f8fafc;
    color: #1f2937;
    padding: 10px 16px;
    border-radius: 12px;
    cursor: pointer;
}

.slider-controls span {
    color: #475569;
    font-weight: 600;
}

.thumbnail-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.thumbnail {
    border: 2px solid transparent;
    border-radius: 16px;
    overflow: hidden;
    padding: 0;
    background: transparent;
    cursor: pointer;
}

.thumbnail.active {
    border-color: #1d4ed8;
}

.thumbnail img {
    display: block;
    width: 100%;
    height: 80px;
    object-fit: cover;
}

.listing-item { position: relative; }
.listing-actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 18px 0 16px; }
.action-btn { display: inline-flex; align-items: center; justify-content: center; min-width: 120px; padding: 10px 14px; gap: 8px; border-radius: 999px; border: 1px solid rgba(15,23,42,0.12); background: #ffffff; color: #0f172a; font-weight: 700; text-decoration: none; cursor: pointer; transition: background 0.2s ease, transform 0.2s ease; }
.action-btn:hover { transform: translateY(-1px); }
.action-btn svg { display: block; width: 18px; height: 18px; }
.whatsapp-btn { background: #ecfdf5; border-color: rgba(37,211,102,0.25); color: #166534; }
.share-btn { background: #f8fafc; border-color: rgba(148,163,184,0.25); color: #0f172a; }

@media (max-width: 640px) {
    .listing-actions { flex-wrap: wrap; gap: 10px; margin: 14px 0; }
    .action-btn { min-width: 100px; padding: 10px 12px; font-size: 0.9rem; }
    .action-btn svg { width: 16px; height: 16px; }
}

/* Mobile adjustments: reduce slider image height and thumbnail sizes */
@media (max-width: 640px) {
    .image-slider {
        padding: 12px;
    }

    .slider-window img {
        height: 320px;
    }

    .thumbnail-row {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 8px;
    }

    .thumbnail img {
        height: 60px;
    }
}

@media (max-width: 420px) {
    .image-slider {
        padding: 10px;
    }

    .slider-window img {
        height: 220px;
    }

    .thumbnail-row {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
    }

    .thumbnail img {
        height: 48px;
        border-radius: 12px;
    }
}

.feature-row {
    max-width: 1200px;
    margin: 0 auto 36px;
    padding: 0 24px;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
    padding: 28px 32px;
}

.features-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 16px;
}

.features-list span {
    background: #eef2ff;
    color: #1d4ed8;
    padding: 10px 16px;
    border-radius: 999px;
    font-size: 0.92rem;
}

.request-section {
    max-width: 1200px;
    margin: 0 auto 40px;
    padding: 0 24px;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
    padding: 28px 32px;
}

.request-section > div {
    margin-bottom: 28px;
}

.request-section > div h3 {
    margin: 0;
    font-size: 1.8rem;
}

.request-section > div p {
    margin: 6px 0 0;
    color: #475569;
    max-width: 720px;
}

.request-section > div .request-notice {
    margin-top: 18px;
}

.request-section .request-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 28px;
    margin-top: 24px;
    align-items: start;
}

.request-section .request-form,
.request-section .request-summary {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 24px;
    padding: 24px;
    min-width: 0;
}

.request-section .request-form .form-row {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 18px;
}

.request-section .request-form input,
.request-section .request-form textarea,
.request-section .request-form select {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    padding: 14px 16px;
    background: #ffffff;
    color: #0f172a;
}

.request-section .request-form textarea {
    min-height: 140px;
    resize: vertical;
}

.request-section .request-summary h4 {
    margin-top: 0;
    margin-bottom: 18px;
    font-size: 1.1rem;
}

.request-section .request-summary ul {
    margin: 0;
    padding-left: 20px;
    color: #475569;
}

.request-section .request-summary ul li {
    margin-bottom: 12px;
}

.request-section .request-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-top: 26px;
}

.request-section .request-card {
    background: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 22px;
    padding: 22px;
    box-shadow: 0 15px 30px rgba(15, 23, 42, 0.05);
}

/* Smaller centered subscription/request cards for broker dashboard */
.subscription-request-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    max-width: 760px;
    margin: 0 auto;
    padding: 12px 18px;
}

.subscription-card {
    width: 100%;
    max-width: 560px;
    padding: 18px 20px;
    border-radius: 14px;
    background: #ffffff;
    border: 1px solid rgba(148,163,184,0.12);
    box-shadow: 0 8px 20px rgba(15,23,42,0.04);
}

.subscription-card h3 { margin: 0 0 6px; font-size: 1.15rem; }
.subscription-card p { margin: 8px 0 12px; color: #475569; font-size: 0.95rem; }
.subscription-card .save-button {
    padding: 12px 18px;
    border-radius: 14px;
    font-size: 0.95rem;
}

@media (max-width: 900px) {
    .subscription-request-grid { padding: 8px 12px; }
    .subscription-card { padding: 14px; }
}

/* Responsive adjustments for tablets and phones */
@media (max-width: 900px) {
    .content { width: calc(100% - 48px); margin: 24px; }
    .hero { min-height: 60vh; }
    .content h1 { font-size: clamp(2rem, 6vw, 3rem); max-width: 100%; }
    .content p { max-width: 100%; }
    .search-grid { grid-template-columns: 1fr; }
    .home-categories { grid-template-columns: 1fr; padding: 0 16px; }
    .request-grid { grid-template-columns: 1fr; }
    .card-grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
    .site-header { padding: 12px 16px; }
    .site-header nav { gap: 12px; flex-wrap: wrap; }
    .profile-username { display: none; }
    .listing-card img { height: 160px; }
    .card-body { padding: 16px 16px 18px; }
    .card-body h3 { font-size: 1.05rem; }
    .slider-window img, .listing-detail img { height: auto; max-height: 420px; }
    .request-form textarea { min-height: 100px; }
    .device-support { grid-template-columns: 1fr; padding: 0 16px 28px; }
    .device-card { padding: 20px 18px; }
}

@media (max-width: 420px) {
    .content { margin: 16px; width: calc(100% - 32px); }
    .btn-primary, .btn-secondary { padding: 12px 20px; }
    .card-grid { gap: 10px; }
    .listing-card img { height: 140px; }
    .card-body { padding: 14px 14px 16px; }
    .card-body h3 { font-size: 1rem; }
    .thumbnail-row { grid-template-columns: repeat(3, 1fr); }
    .thumbnail img { height: 60px; }
    .profile-photo { width: 32px; height: 32px; }
    .search-item { padding: 14px; border-radius: 14px; }
    .device-icon { width: 48px; height: 48px; }
}

.request-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 28px;
    margin-top: 24px;
    align-items: start;
}

.request-form,
.request-summary {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 24px;
    padding: 24px;
    min-width: 0;
}

@media (max-width: 900px) {
    .request-grid,
    .request-cards {
        grid-template-columns: 1fr;
    }
}

.request-form .form-row {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 18px;
}

.request-form label {
    font-weight: 600;
    color: #334155;
}

.request-form input,
.request-form textarea,
.request-form select {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    padding: 14px 16px;
    background: #ffffff;
    color: #0f172a;
}

.request-form textarea {
    min-height: 140px;
    resize: vertical;
}

.request-summary h4 {
    margin-top: 0;
    margin-bottom: 18px;
    font-size: 1.1rem;
}

.request-summary ul {
    margin: 0;
    padding-left: 20px;
    color: #475569;
}

.request-summary ul li {
    margin-bottom: 12px;
}

.request-notice {
    margin-top: 18px;
    padding: 18px 20px;
    border-radius: 18px;
    background: #ecfdf5;
    color: #166534;
    border: 1px solid #a7f3d0;
}

.request-notice.error {
    background: #fef2f2;
    color: #991b1b;
    border-color: #fecaca;
}

.request-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-top: 26px;
}

.request-card {
    background: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 22px;
    padding: 22px;
    box-shadow: 0 15px 30px rgba(15, 23, 42, 0.05);
}

.request-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.request-card .tag {
    background: #eff6ff;
    color: #1d4ed8;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 0.9rem;
}

.request-card-meta {
    font-size: 0.95rem;
    color: #64748b;
    margin-bottom: 12px;
}

.request-contact {
    margin-top: 14px;
    font-size: 0.95rem;
    color: #334155;
}

.request-contact-info {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
    font-size: 0.95rem;
}

.request-contact-info p {
    margin: 8px 0;
    color: #334155;
}

.request-contact-info strong {
    color: #0f172a;
}

@media (max-width: 900px) {

    .request-grid,
    .request-cards {
        grid-template-columns: 1fr;
    }
}

.pricing-section {
    max-width: 1200px;
    margin: 0 auto 50px;
    padding: 0 24px 40px;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.pricing-card {
    background: rgba(15, 23, 42, 0.95);
    border-radius: 28px;
    padding: 32px 30px;
    color: #f8fafc;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.22);
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    border: 1px solid rgba(148, 163, 184, 0.12);
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 28px 90px rgba(15, 23, 42, 0.3);
}

.pricing-card.popular {
    border-color: #2563eb;
    box-shadow: 0 28px 90px rgba(37, 99, 235, 0.18);
}

.pricing-top {
    margin-bottom: 30px;
}

.plan-label {
    display: inline-flex;
    padding: 9px 16px;
    border-radius: 999px;
    background: rgba(59, 130, 246, 0.18);
    color: #bfdbfe;
    font-size: 0.82rem;
    letter-spacing: 0.02em;
    margin-bottom: 18px;
}

.plan-title {
    margin: 0;
    font-size: 2.4rem;
    line-height: 1.05;
}

.plan-price {
    margin: 10px 0 0;
    font-size: 2rem;
    color: #f8fafc;
}

.plan-subtitle {
    margin: 10px 0 0;
    color: #94a3b8;
}

.plan-features {
    list-style: none;
    padding: 0;
    margin: 0 0 28px;
}

.plan-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    color: #d1d5db;
    font-size: 0.95rem;
}

.plan-features li:first-child {
    border-top: none;
}

.plan-features li::before {
    content: '\2713';
    display: inline-flex;
    width: 22px;
    height: 22px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #14b8a6;
    color: #fff;
    font-size: 0.75rem;
}

.plan-features li.disabled {
    opacity: 0.5;
    color: #94a3b8;
}

.plan-features li.disabled::before {
    content: '\2715';
    background: rgba(148, 163, 184, 0.3);
}

.plan-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 16px 18px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: transparent;
    color: #f8fafc;
    font-weight: 700;
    text-align: center;
}

.plan-button:hover {
    background: rgba(255, 255, 255, 0.06);
}

.plan-button::after {
    content: '\2192';
    margin-left: 10px;
}

.page-heading,
.dashboard-grid {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px 24px;
}

.page-heading {
    padding-top: 36px;
}

.page-heading h1 {
    margin: 0 0 10px;
    font-size: clamp(2rem, 2.5vw, 2.5rem);
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-areas:
        "form preview"
        "saved performance";
    gap: 24px;
    margin-bottom: 0;
    align-items: start;
}

.dashboard-grid > .dashboard-card:nth-child(1) {
    grid-area: form;
}

.dashboard-grid > .listing-review-card {
    grid-area: preview;
}

.dashboard-grid > .saved-listings-card {
    grid-area: saved;
}

.dashboard-grid > .dashboard-card:nth-child(4) {
    grid-area: performance;
}

.dashboard-card {
    background: #ffffff;
    border-radius: 24px;
    padding: 28px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
}

.private-note-card {
    margin-bottom: 18px !important;
}

.subscription-request-card {
    margin-bottom: 18px !important;
}

/* Saved posts card (private dashboard) */
.saved-listings { display: flex; flex-direction: column; gap: 18px; }
.saved-post-card {
    display: flex;
    gap: 18px;
    align-items: stretch;
    padding: 18px;
    border-radius: 18px;
    background: #f7fbfe;
    border: 1px solid rgba(226,232,240,0.9);
}
.saved-thumb {
    position: relative;
    width: 120px;
    min-width: 120px;
    border-radius: 16px;
    overflow: hidden;
    background: #eef6fb;
    display: flex;
    align-items: center;
    justify-content: center;
}
.saved-thumb img { width: 100%; height: 100%; object-fit: cover; display:block; }
.thumb-overlay {
    position: absolute;
    inset: 8px 8px auto 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: flex-start;
}
.thumb-price {
    background: rgba(255,255,255,0.9);
    color: #0f172a;
    font-weight: 800;
    padding: 10px 12px;
    border-radius: 16px;
    text-align: center;
    font-size: 1rem;
}
.thumb-location { background: transparent; color: #334155; padding: 6px 8px; border-radius: 10px; font-size: 0.9rem; }
.thumb-images { font-size: 0.85rem; color: #64748b; padding: 6px 8px; }
.saved-body { flex: 1; display: flex; flex-direction: column; gap: 10px; }
.saved-top { display:flex; justify-content:space-between; align-items:center; }
.saved-title { margin: 0; font-size: 1.15rem; letter-spacing: 0.02em; }
.saved-desc { margin: 0; color: #475569; }
.saved-meta { color: #475569; font-size: 0.95rem; }
.saved-actions { display:flex; gap:12px; margin-top:8px; align-items:center; }
.saved-actions .btn { padding:10px 16px; border-radius:12px; font-weight:700; border:none; cursor:pointer; text-decoration:none; }
.btn-review { background:#2563eb; color:white; }
.btn-edit { background:#ffffff; color:#0f172a; border:1px solid #eef2ff; box-shadow: 0 6px 18px rgba(99,102,241,0.06); }
.btn-uploads { background:#eef6ff; color:#2563eb; border:1px solid rgba(37,99,235,0.08); display:inline-flex; align-items:center; }
.btn-delete { background:#ef4444; color:white; }

@media (max-width: 800px) {
    .saved-post-card { flex-direction: column; align-items: stretch; }
    .saved-thumb { width: 100%; min-width: auto; height: 180px; }
}

@media (max-width: 1024px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
        grid-template-areas: none;
    }

    .dashboard-grid > .dashboard-card,
    .dashboard-grid > .listing-review-card,
    .dashboard-grid > .saved-listings-card {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
        gap: 18px;
        padding: 20px 16px;
    }

    .dashboard-card {
        padding: 20px;
        border-radius: 18px;
    }

    .saved-listings-card {
        padding: 20px;
    }

    .saved-listings {
        gap: 14px;
    }

    .saved-post-card {
        flex-direction: column;
        align-items: stretch;
    }

    .saved-thumb {
        width: 100%;
        height: 200px;
        min-width: auto;
    }

    .private-note-card,
    .subscription-request-card {
        margin-bottom: 16px !important;
        padding: 16px !important;
    }
}

@media (max-width: 480px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 16px 12px;
        max-width: 100%;
    }

    .dashboard-card {
        padding: 16px;
        border-radius: 16px;
        box-shadow: 0 10px 20px rgba(15, 23, 42, 0.06);
    }

    .saved-post-card {
        padding: 12px;
        margin-bottom: 12px;
    }

    .saved-thumb {
        height: 160px;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions button {
        width: 100%;
    }

    .page-heading {
        padding: 24px 16px 0;
    }

    .page-heading h1 {
        font-size: 1.5rem;
    }

    .page-heading p {
        font-size: 0.95rem;
    }

    .private-note-card,
    .subscription-request-card {
        margin-bottom: 14px !important;
        padding: 14px !important;
        border-radius: 14px;
    }

    .private-note-card .form-note,
    .subscription-request-card .form-note {
        font-size: 0.9rem;
        margin: 0;
    }
}

@media (max-width: 640px) {
    .dashboard-grid {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 18px;
        padding: 20px 12px 28px;
        scroll-padding-left: 14px;
        position: relative;
        scrollbar-width: thin;
        scrollbar-color: rgba(37,99,235,0.35) transparent;
    }

    .dashboard-grid::-webkit-scrollbar {
        height: 8px;
    }

    .dashboard-grid::-webkit-scrollbar-track {
        background: transparent;
    }

    .dashboard-grid::-webkit-scrollbar-thumb {
        background: rgba(37,99,235,0.35);
        border-radius: 999px;
    }

    .dashboard-grid > .dashboard-card {
        flex: 0 0 min(92vw, 420px);
        width: min(92vw, 420px);
        scroll-snap-align: start;
        min-width: 320px;
        padding: 20px;
    }

    .dashboard-grid > .dashboard-card:first-child {
        margin-left: 4px;
    }

    .dashboard-grid > .dashboard-card:last-child {
        margin-right: 4px;
    }
}

.broker-form label {
    display: block;
    font-weight: 600;
    margin-top: 18px;
    margin-bottom: 8px;
    color: #334155;
}

.broker-form input,
.broker-form select,
.broker-form textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid #cbd5e1;
    background: #f8fafc;
    color: #0f172a;
    outline: none;
}

.broker-form textarea {
    resize: vertical;
    min-height: 140px;
}

.broker-form input[type="file"] {
    background: #ffffff;
    padding: 10px 12px;
}

.image-preview {
    margin-top: 12px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 10px;
    padding: 12px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
    color: #475569;
    min-height: 72px;
}

.image-preview img {
    width: 100%;
    height: 72px;
    border-radius: 14px;
    object-fit: cover;
}

.image-name-list {
    margin-top: 10px;
    padding: 12px 14px;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    background: #ffffff;
    color: #334155;
    font-size: 0.95rem;
    line-height: 1.4;
    min-height: 42px;
}

.image-name-item {
    padding: 4px 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.image-name-item:last-child {
    border-bottom: none;
}

.form-actions {
    margin-top: 22px;
    display: flex;
    justify-content: flex-start;
}

.save-button {
    background: #2563eb;
    color: #ffffff;
    border: none;
    border-radius: 16px;
    padding: 14px 22px;
    cursor: pointer;
    font-weight: 700;
}

.save-button:disabled {
    background: #94a3b8;
    cursor: not-allowed;
}

/* Make nav links look like buttons on hover and provide modal styles */
.site-header nav a.listing-link,
.site-header nav a.dashboard-button {
    transition: background 0.15s ease, color 0.15s ease, transform 0.12s ease;
}
.site-header nav a.listing-link:hover,
.site-header nav a.dashboard-button:hover {
    background: #1d4ed8;
    color: #fff;
    padding: 8px 12px;
    border-radius: 8px;
    transform: translateY(-2px);
}
.site-header nav a.dashboard-button {
    background: #2563eb;
    color: #ffffff;
    border-radius: 999px;
    padding: 8px 12px;
    margin-left: 10px;
    font-weight: 700;
}

/* Modal */
.rl-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(2,6,23,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}
.rl-modal {
    background: #fff;
    color: #0f172a;
    padding: 20px;
    border-radius: 12px;
    width: 92%;
    max-width: 520px;
    box-shadow: 0 30px 60px rgba(2,6,23,0.35);
}
.rl-modal h3 {
    margin: 0 0 12px;
}
.rl-modal .rl-actions {
    display: flex;
    gap: 12px;
    margin-top: 14px;
}
.rl-modal .rl-actions button {
    flex: 1;
    padding: 12px 14px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    font-weight: 700;
}
.rl-modal .rl-actions button.primary { background: #2563eb; color: #fff; }
.rl-modal .rl-actions button.secondary { background: #eef2ff; color: #1d4ed8; border: 1px solid #cbd5e1; }
.rl-modal .rl-actions .ghost { background: transparent; border: 1px solid #e5e7eb; color: #0f172a; }


.form-status {
    margin-top: 16px;
    color: #475569;
    font-size: 0.95rem;
}

.form-status.valid {
    color: #166534;
}

.auth-panel {
    min-height: calc(100vh - 88px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    background: linear-gradient(180deg, #f8fbff 0%, #eef4fb 100%);
}
.auth-panel .auth-card,
.auth-panel form {
    width: 100%;
    max-width: 520px;
}
.auth-card {
    background: #ffffff;
    border-radius: 28px;
    padding: 34px;
    box-shadow: 0 30px 70px rgba(15, 23, 42, 0.08);
}
.auth-panel h1 {
    margin-bottom: 18px;
    font-size: clamp(2rem, 2.4vw, 2.7rem);
    color: #0f172a;
}
.auth-panel p {
    color: #475569;
}
.auth-panel .auth-card a {
    color: #2563eb;
    font-weight: 700;
}
.auth-error {
    background: #fee2e2;
    color: #991b1b;
    border-radius: 14px;
    padding: 14px 16px;
    margin-bottom: 16px;
}
.auth-card form {
    display: grid;
    gap: 18px;
}
.auth-card label {
    margin-bottom: 8px;
    font-weight: 700;
    color: #334155;
}
.auth-card input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
    color: #0f172a;
}
.auth-card button {
    width: 100%;
    padding: 16px 18px;
    border-radius: 18px;
    border: none;
    background: #2563eb;
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
}
.auth-card button:hover {
    background: #1d4ed8;
}

.auth-card {
    background: #ffffff;
    border-radius: 32px;
    padding: 36px;
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.08);
    max-width: 720px;
    margin: 32px auto;
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.auth-card h2 {
    margin-top: 0;
    font-size: 1.85rem;
    color: #0f172a;
}

.auth-card label {
    display: block;
    margin-top: 18px;
    margin-bottom: 10px;
    color: #334155;
    font-weight: 700;
}

.auth-card input,
.auth-card textarea,
.auth-card select {
    width: 100%;
    padding: 14px 18px;
    border-radius: 18px;
    border: 1px solid #cbd5e1;
    background: #f8fafc;
    color: #0f172a;
    font-size: 0.98rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-card input:focus,
.auth-card textarea:focus,
.auth-card select:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.auth-card textarea {
    min-height: 140px;
    resize: vertical;
}

.auth-card .form-note {
    margin-top: 12px;
    color: #64748b;
}

.page-action-link {
    margin: 0 0 16px;
}

.page-action-link a {
    color: #2563eb;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.page-action-link a:hover {
    text-decoration: underline;
}

.auth-card .form-actions {
    margin-top: 24px;
    display: flex;
    justify-content: flex-start;
    gap: 12px;
    flex-wrap: wrap;
}

.auth-card button,
.auth-card .promote-btn,
.auth-card .save-button {
    width: auto;
    padding: 14px 22px;
    border-radius: 16px;
    border: none;
    background: #2563eb;
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

@media (max-width: 768px) {
    .auth-card {
        padding: 24px 20px;
        margin: 20px 16px;
    }

    .auth-card input,
    .auth-card textarea,
    .auth-card select {
        padding: 12px 14px;
    }

    .auth-card .form-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .page-action-link {
        margin-bottom: 20px;
    }
}

.auth-card button:hover,
.auth-card .promote-btn:hover,
.auth-card .save-button:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

.auth-card .form-actions {
    margin-top: 24px;
    display: flex;
    justify-content: flex-start;
}

.auth-card .profile-photo-preview {
    width: 96px;
    height: 96px;
    border-radius: 22px;
    overflow: hidden;
    background: #e2e8f0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.auth-card .profile-photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.auth-message {
    margin-bottom: 18px;
    padding: 14px 16px;
    border-radius: 16px;
}

.auth-message.error {
    background: #fee2e2;
    color: #991b1b;
}

.auth-message.warning {
    background: #fef3c7;
    color: #92400e;
}

.auth-message.valid {
    background: #dcfce7;
    color: #166534;
}

.form-note {
    margin-top: 16px;
    color: #475569;
}

.notice-card {
    position: relative;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    padding: 18px 20px 18px 20px;
    border-radius: 18px;
    margin-top: 20px;
}

.notice-card .notice-heading {
    margin: 0 0 8px;
    font-weight: 700;
    color: #0f172a;
}

.notice-card .notice-body {
    margin: 0;
    color: #334155;
    line-height: 1.6;
}

.notice-card .notice-close {
    position: absolute;
    top: 14px;
    right: 14px;
    background: transparent;
    border: none;
    color: #475569;
    font-size: 18px;
    cursor: pointer;
    line-height: 1;
}

.category-guide {
    background: #f0f9ff;
    border-left: 4px solid #2563eb;
    padding: 16px;
    border-radius: 8px;
    margin-top: 12px;
    margin-bottom: 16px;
}

.guide-title {
    margin: 0 0 12px 0;
    font-weight: 600;
    color: #1e40af;
    font-size: 0.95rem;
}

.mandatory-fields {
    margin: 0 0 14px 20px;
    padding: 0;
    list-style-type: disc;
}

.mandatory-fields li {
    color: #334155;
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.template-btn {
    background: #2563eb;
    color: #ffffff;
    border: none;
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.template-btn:hover {
    background: #1d4ed8;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.template-btn:active {
    transform: scale(0.98);
}

.subscription-options,
.payment-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 16px;
    margin: 16px 0 24px;
}

.subscription-options label,
.payment-options label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border: 2px solid #cbd5e1;
    border-radius: 16px;
    background: #ffffff;
    cursor: pointer;
    transition: all 0.25s ease;
    font-weight: 600;
    color: #334155;
    position: relative;
}

.subscription-options label:hover,
.payment-options label:hover {
    border-color: #2563eb;
    background: #f0f9ff;
}

.subscription-options input,
.payment-options input {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 20px;
    height: 20px;
    min-width: 20px;
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    background: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.subscription-options input:hover,
.payment-options input:hover {
    border-color: #2563eb;
    background: #eef2ff;
}

.subscription-options input:checked,
.payment-options input:checked {
    border-color: #2563eb;
    background: #2563eb;
    box-shadow: inset 0 0 0 3px #ffffff;
}

.subscription-options label:has(input:checked),
.payment-options label:has(input:checked) {
    border-color: #2563eb;
    background: #eef2ff;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.subscription-options label:has(input:checked) strong,
.payment-options label:has(input:checked) strong {
    color: #2563eb;
}

@media (max-width: 640px) {
    .subscription-options,
    .payment-options {
        grid-template-columns: 1fr;
    }
}

.saved-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.saved-post-card {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.saved-post-card:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.saved-post-thumb {
    width: 65px;
    min-width: 65px;
    height: 55px;
    overflow: hidden;
    border-radius: 10px;
    background: #f8fafc;
    flex-shrink: 0;
}

.saved-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.saved-post-header {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
    font-size: 0.9rem;
}

.saved-post-header strong {
    font-weight: 700;
    color: #1f2937;
}

.saved-post-header span {
    font-size: 0.8rem;
    color: #64748b;
}

.saved-post-card p {
    margin: 6px 0;
    color: #475569;
    font-size: 0.85rem;
    line-height: 1.3;
}

.saved-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 6px 0 10px;
    color: #64748b;
    font-size: 0.8rem;
}

.thumbnail {
    position: relative;
    border: 1px solid transparent;
    border-radius: 18px;
    overflow: hidden;
    background: #ffffff;
    padding: 0;
}

.thumbnail.active {
    border-color: #1d4ed8;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.15);
}

.thumbnail img {
    width: 100%;
    height: 70px;
    object-fit: cover;
    display: block;
}

.thumbnail-index {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(15, 23, 42, 0.85);
    color: #ffffff;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 0.75rem;
    line-height: 1;
}

.image-names-display {
    margin-top: 16px;
    padding: 12px 16px;
    background: #f0f9ff;
    border-left: 4px solid #1d4ed8;
    border-radius: 8px;
    color: #1f2937;
    font-size: 0.95rem;
    line-height: 1.5;
}

.image-names-display strong {
    color: #1d4ed8;
}
.saved-listings {
    display: grid;
    gap: 16px;
    margin-top: 18px;
}

.saved-post-card {
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid #cbd5e1;
    border-radius: 20px;
    padding: 16px;
    background: #f8fafc;
    flex-wrap: wrap;
}

.saved-post-thumb {
    width: 92px;
    min-width: 92px;
    height: 92px;
    min-height: 92px;
    border-radius: 18px;
    overflow: hidden;
    background: #e2e8f0;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
}

.saved-post-summary {
    flex: 1 1 320px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.saved-post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.saved-post-header strong {
    font-weight: 700;
    color: #1f2937;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.saved-post-header span {
    font-size: 0.8rem;
    color: #64748b;
    white-space: nowrap;
}

.saved-post-description {
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.saved-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    color: #475569;
    font-size: 0.8rem;
    margin: 0;
}

.saved-actions {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.saved-actions button,
.saved-actions .view-button {
    border: none;
    border-radius: 12px;
    padding: 9px 16px;
    font-weight: 700;
    cursor: pointer;
    font-size: 0.82rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 0 0 rgba(15, 23, 42, 0.08);
}

.saved-actions button:hover,
.saved-actions .view-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.review-button {
    background: #2563eb;
    color: #ffffff;
}

.review-button:hover {
    background: #1d4ed8;
}

.edit-button {
    background: #ffffff;
    color: #0f172a;
    border: 1px solid #cbd5e1;
}

.edit-button:hover {
    background: #f8fafc;
}

.view-button {
    background: #f0f9ff;
    color: #1d4ed8;
    border: 1px solid transparent;
}

.view-button:hover {
    background: #dbeafe;
}

.delete-button {
    background: #ef4444;
    color: #ffffff;
    border: 1px solid rgba(239, 68, 68, 0.25);
    box-shadow: 0 6px 14px rgba(239, 68, 68, 0.18);
    min-width: 92px;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.delete-button:hover {
    background: #dc2626;
    box-shadow: 0 12px 20px rgba(220, 34, 38, 0.22);
    transform: translateY(-1px);
}

.delete-button:focus-visible {
    outline: 2px solid rgba(220, 34, 38, 0.35);
    outline-offset: 2px;
}

/* Ensure saved post cards keep a consistent size regardless of image dimensions */
.saved-listings .saved-post-card {
    min-height: auto;
}

.saved-listings .saved-post-thumb {
    width: 92px;
    min-width: 92px;
    height: 92px;
    min-height: 92px;
    border-radius: 18px;
    overflow: hidden;
    background: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    text-align: center;
    flex-shrink: 0;
}

.saved-listings .saved-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.saved-post-thumb .thumb-details {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.saved-post-thumb .thumb-price {
    font-weight: 700;
    color: #0f172a;
    font-size: 0.95rem;
}

.saved-post-thumb .thumb-location {
    font-size: 0.78rem;
    color: #475569;
}

.saved-post-thumb .thumb-images {
    font-size: 0.75rem;
    color: #64748b;
}

@media (max-width: 640px) {
    .saved-post-card {
        flex-direction: column;
        align-items: stretch;
    }

    .saved-post-summary {
        order: 2;
    }

    .saved-actions {
        order: 3;
        width: 100%;
        justify-content: flex-start;
    }

    .saved-listings .saved-post-thumb {
        width: 100%;
        min-width: auto;
        height: 120px;
        min-height: 120px;
        border-radius: 20px;
    }
}

.listing-review {
    margin-top: 16px;
    color: #334155;
    line-height: 1.8;
}

.listing-review p {
    margin: 12px 0;
}

.listing-review strong {
    color: #0f172a;
}

.workflow-panel,
.applications-panel {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px 24px;
}

.workflow-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 18px;
    margin-top: 20px;
}

.workflow-step {
    background: #ffffff;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 18px 35px rgba(15, 23, 42, 0.08);
    min-height: 160px;
}

.workflow-step span {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #dbeafe;
    color: #1d4ed8;
    font-weight: 700;
    margin-bottom: 16px;
}

.workflow-step strong {
    display: block;
    margin-bottom: 10px;
    font-size: 1rem;
}

.workflow-step p {
    margin: 0;
    color: #475569;
    line-height: 1.5;
}

.workflow-step.completed {
    border: 1px solid #d1fae5;
}

.workflow-step.active {
    border: 1px solid #60a5fa;
    background: #eef6ff;
}

.workflow-step.pending {
    border: 1px solid #fcd34d;
    background: #fffbeb;
}

.analytics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.analytics-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.06);
}

.analytics-card .analytics-icon {
    display: inline-flex;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    font-size: 1.2rem;
    margin-bottom: 14px;
    background: rgba(255, 255, 255, 0.75);
}

.analytics-card strong {
    display: block;
    font-size: 1.7rem;
    color: #0f172a;
    margin-bottom: 6px;
}

.analytics-card span {
    color: #475569;
    font-size: 0.95rem;
    font-weight: 600;
}

.analytics-card.visits {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}

.analytics-card.share {
    background: linear-gradient(135deg, #fefce8 0%, #fef3c7 100%);
}

.analytics-card.whatsapp {
    background: linear-gradient(135deg, #ecfdf5 0%, #dcfce7 100%);
}

.application-table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 18px 35px rgba(15, 23, 42, 0.08);
}

.application-table th,
.application-table td {
    padding: 18px 20px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.application-table thead {
    background: #f8fafc;
}

.application-table tr:last-child td {
    border-bottom: none;
}

.status {
    display: inline-flex;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 700;
}

.status-pending {
    background: #fef3c7;
    color: #92400e;
}

.status-approved {
    background: #dcfce7;
    color: #166534;
}

.status-rejected {
    background: #fee2e2;
    color: #991b1b;
}

.action-button {
    border: none;
    border-radius: 12px;
    padding: 10px 14px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease, box-shadow 0.2s ease;
}

.action-button:hover {
    transform: translateY(-1px);
}

.action-button.approve {
    background: #16a34a;
    color: #ffffff;
    margin-right: 8px;
}

.action-button.reject {
    background: #dc2626;
    color: #ffffff;
}

.action-button.delete {
    background: #f97316;
    color: #ffffff;
    margin-left: 8px;
}

.action-button.disabled {
    background: #e2e8f0;
    color: #64748b;
    cursor: default;
}

.broker-review-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.broker-review-field {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

.broker-review-field label {
    font-weight: 700;
    color: #334155;
}

.broker-review-field input,
.broker-review-field textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid #cbd5e1;
    background: #f8fafc;
    color: #0f172a;
}

.broker-review-field textarea {
    min-height: 120px;
    resize: vertical;
}

.document-preview {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.document-card {
    border-radius: 18px;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    text-align: center;
    padding: 16px;
}

.document-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 1px solid #e2e8f0;
}

.document-card strong {
    display: block;
    margin-top: 12px;
    font-size: 0.95rem;
}

.review-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 26px;
    align-items: center;
}

@media (max-width: 900px) {
    .broker-review-grid {
        grid-template-columns: 1fr;
    }
}

.filter-top {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 22px;
}

.filter-top input,
.filter-top select,
.filter-top button {
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid #cbd5e1;
    background: #ffffff;
}

.filter-top button {
    background: #1d4ed8;
    color: #fff;
    border: none;
    cursor: pointer;
}

.results-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 24px;
    padding: 0 24px 40px;
}

.sidebar-card {
    background: #ffffff;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
}

.sidebar-card h2 {
    margin-top: 0;
    margin-bottom: 18px;
}

.sidebar-filters {
    display: grid;
    gap: 14px;
}

.sidebar-button {
    border: none;
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    background: #1d4ed8;
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
}

.sidebar-button:hover {
    background: #2563eb;
}

.sidebar-card label {
    display: block;
    margin: 16px 0 8px;
    color: #475569;
}

.sidebar-card select {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    padding: 12px 14px;
    background: #f8fafc;
}

.sidebar-filters {
    display: grid;
    gap: 16px;
}

.sidebar-button {
    border: none;
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    background: #1d4ed8;
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
}

.sidebar-button:hover {
    background: #2563eb;
}

.search-results {
    display: grid;
    gap: 18px;
}

.result-card {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 0;
    background: #ffffff;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease;
}

.result-card:hover {
    transform: translateY(-2px);
}

.result-card img {
    width: 100%;
    object-fit: cover;
    min-height: 100%;
}

.result-body {
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.result-header {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    margin-bottom: 14px;
}

.result-header h3 {
    margin: 0;
}

.result-body p {
    margin: 0 0 14px;
    color: #475569;
}

.result-meta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    color: #475569;
    font-size: 0.9rem;
}

.empty-state {
    background: #ffffff;
    padding: 40px;
    border-radius: 24px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
}

.site-footer {
    text-align: center;
    padding: 24px;
    color: #64748b;
    margin-top: 24px;
}

@media (max-width: 1080px) {
    .search-grid,
    .home-categories,
    .pricing-grid,
    .results-layout {
        grid-template-columns: 1fr;
    }

    .button-item,
    .filter-top {
        grid-template-columns: 1fr;
    }

    .result-card {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .site-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }

    .site-header nav a {
        margin-left: 0;
    }

    .hero {
        min-height: 80vh;
        padding: 0;
    }

    .overlay {
        align-items: flex-start;
        padding-top: 80px;
        min-height: 80vh;
    }

    .content {
        width: auto;
        margin-left: 8%;
        max-width: 92%;
    }

    .hero-copy {
        padding: 0;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .search-grid,
    .home-categories,
    .pricing-grid {
        gap: 14px;
    }

    .search-item {
        padding: 18px;
    }
}

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

    .dashboard-grid > * {
        min-width: 0;
    }

    .broker-review-grid {
        grid-template-columns: 1fr;
    }

    .application-table {
        display: block;
        overflow-x: auto;
        width: 100%;
    }

    .application-table th,
    .application-table td {
        white-space: nowrap;
    }
}

@media (max-width: 900px) {
    .site-header {
        flex-direction: column;
        align-items: flex-start;
        padding: 18px 20px;
    }

    .site-header nav {
        flex-wrap: wrap;
        gap: 10px;
    }

    .site-header nav a {
        margin-left: 0;
        padding: 10px 14px;
    }

    .panel-button,
    .action-button,
    .button-item button,
    .sidebar-button {
        width: 100%;
        max-width: none;
    }

    .dashboard-card {
        padding: 22px;
    }

    .saved-post-card {
        gap: 14px;
    }
}

@media (max-width: 768px) {
    .page-heading,
    .dashboard-grid,
    .workflow-panel,
    .applications-panel {
        padding-left: 16px;
        padding-right: 16px;
    }

    .listing-review-card,
    .saved-listings-card {
        padding: 20px;
    }

    .notice-card,
    .category-guide,
    .image-preview,
    .image-name-list {
        padding: 16px;
    }

    .saved-listings {
        gap: 14px;
    }

    .saved-post-card {
        flex-direction: column;
        align-items: stretch;
    }
}

/* Admin Login Page */
body.admin-login-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 24px;
}

.login-wrapper {
    width: 100%;
    max-width: 420px;
}

.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.login-header h1 {
    margin: 0 0 8px;
    font-size: 2rem;
    color: #0f172a;
    font-weight: 700;
}

.login-header p {
    margin: 0;
    color: #475569;
    font-size: 0.95rem;
}

.login-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 22px 46px rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(226, 232, 240, 0.95);
}

.login-card .form-group {
    margin-bottom: 24px;
}

.login-card .form-group:last-of-type {
    margin-bottom: 28px;
}

.login-card label {
    display: block;
    margin-bottom: 10px;
    color: #475569;
    font-size: 0.9rem;
    font-weight: 500;
}

.login-card input[type="text"],
.login-card input[type="password"] {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    background: #f8fafc;
    color: #0f172a;
    font-size: 0.95rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.login-card input[type="text"]:focus,
.login-card input[type="password"]:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.login-card button {
    width: 100%;
    padding: 16px 18px;
    border: none;
    border-radius: 16px;
    background: #2563eb;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.login-card button:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.18);
}

.login-card button:active {
    transform: translateY(0);
}

.login-card .error {
    background: #fee2e2;
    color: #991b1b;
    padding: 14px 16px;
    border-radius: 14px;
    margin-bottom: 24px;
    border: 1px solid #fecaca;
    font-size: 0.9rem;
}
