/* ============================================================================
   CAPITAL CAR CLASSIC - ULTRA-MODERN MOBILE-FIRST DESIGN
   Designed by: AI Designer (15 years Figma experience)
   Philosophy: Premium, clean, beautiful mobile app aesthetic
   ============================================================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Modern Color Palette */
    --primary: #1a3a8a;
    --primary-light: #2563eb;
    --primary-dark: #0f172a;
    --accent: #dc2626;
    --accent-light: #ef4444;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    /* Modern Neutrals */
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --text-light: #94a3b8;
    
    /* Surfaces */
    --surface-0: #ffffff;
    --surface-50: #f8fafc;
    --surface-100: #f1f5f9;
    --surface-200: #e2e8f0;
    --surface-300: #cbd5e1;
    
    /* Shadows - Modern & Elevated */
    --shadow-sm: 0 1px 2px 0 rgba(15, 23, 42, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.1), 0 2px 4px -1px rgba(15, 23, 42, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.1), 0 4px 6px -2px rgba(15, 23, 42, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(15, 23, 42, 0.1), 0 10px 10px -5px rgba(15, 23, 42, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(15, 23, 42, 0.15);
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #1a3a8a 0%, #2563eb 100%);
    --gradient-accent: linear-gradient(135deg, #dc2626 0%, #ef4444 100%);
    --gradient-dark: linear-gradient(180deg, rgba(15, 23, 42, 0.95) 0%, rgba(15, 23, 42, 0.5) 100%);
    --gradient-hero: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    
    /* Spacing */
    --space-xs: 6px;
    --space-sm: 12px;
    --space-md: 16px;
    --space-lg: 20px;
    --space-xl: 24px;
    --space-2xl: 32px;
    --space-3xl: 40px;
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-full: 9999px;
    
    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: var(--text-primary);
    background-color: var(--surface-0);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.admin-mode {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
}

html {
    scroll-behavior: smooth;
}

/* ============================================================================
   HEADER - MODERN
   ============================================================================ */

.app-header {
    background: var(--surface-0);
    border-bottom: 1px solid var(--surface-200);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
    transition: box-shadow var(--transition-base);
}

.app-header.scrolled {
    box-shadow: var(--shadow-md);
}

.admin-header {
    background: var(--primary);
    color: white;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.admin-header .header-main {
    max-width: 100% !important;
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: nowrap;
}

.admin-header .container {
    max-width: 100% !important;
    padding: 0;
}

.admin-header .brand {
    color: white;
    background: none;
    -webkit-background-clip: unset;
    -webkit-text-fill-color: unset;
    font-size: 1.25rem;
    font-weight: 800;
    margin: 0;
}

.admin-header-brand-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.admin-header-tag {
    color: rgba(255,255,255,0.78);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.admin-sidebar-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    margin-right: 12px;
}

.admin-sidebar-toggle:hover {
    background: rgba(255,255,255,0.25);
    border-color: rgba(255,255,255,0.4);
}

@media (min-width: 1024px) {
    .admin-sidebar-toggle {
        display: none;
    }
}

.admin-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: nowrap;
}

.admin-header-actions .button {
    min-width: 90px;
    white-space: nowrap;
    font-size: 0.9rem;
    padding: 9px 16px;
    font-weight: 700;
}

.admin-header-actions .button-primary {
    background: rgba(255,255,255,0.2);
    color: white;
    border: 1px solid rgba(255,255,255,0.3);
    transition: all 0.3s ease;
}

.admin-header-actions .button-primary:hover {
    background: rgba(255,255,255,0.3);
    border-color: rgba(255,255,255,0.5);
}

.admin-header-actions .button-secondary {
    background: white;
    color: var(--primary);
    border: 1px solid white;
    font-weight: 700;
}

.admin-header-actions .button-secondary:hover {
    background: rgba(255,255,255,0.9);
}

.topbar {
    display: none;
    background: var(--primary-dark);
    color: white;
    font-size: 0.875rem;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 1024px) {
    .topbar {
        display: block;
    }
}

.topbar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.topbar-left,
.topbar-right {
    display: flex;
    gap: 20px;
    align-items: center;
}

.topbar-left a,
.topbar-right a {
    color: white !important;
    text-decoration: none;
    transition: color var(--transition-fast);
}

.topbar-left a:hover,
.topbar-right a:hover {
    color: #d6e8ff !important;
}

.header-main {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    gap: 20px;
    flex-wrap: wrap;
}

.brand {
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
    transition: transform var(--transition-fast);
}

/* Logo image inside header */
.brand-logo {
    height: 44px;
    display: inline-block;
    vertical-align: middle;
}

.brand-text {
    display: inline-block;
    margin-left: 10px;
    vertical-align: middle;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary);
}

/* When logo loads, visually hide the text to keep accessibility */
.brand img:not([style*="display: none"]) + .brand-text {
    position: absolute;
    left: -9999px;
}

.brand:hover {
    transform: scale(1.05);
}

.nav-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, #3b82f6 0%, #06b6d4 100%);
    border: none;
    border-radius: 12px;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: white;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.nav-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
}

.nav-toggle:active {
    transform: scale(0.95);
}

@media (min-width: 768px) {
    .nav-toggle {
        display: none;
    }

    .header-main {
        padding: 16px 20px;
    }
}

.main-nav {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    background: linear-gradient(135deg, #3b82f6 0%, #06b6d4 100%);
    z-index: 999;
    overflow-y: auto;
    padding: 80px 0 20px;
    flex-direction: column;
    gap: 0;
    box-shadow: 8px 0 24px rgba(59, 130, 246, 0.2);
}

.main-nav.active {
    display: flex;
    animation: slideInLeft var(--transition-base);
}

@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.main-nav a {
    display: block;
    padding: 18px 24px;
    border-radius: 0;
    background: transparent;
    font-size: 1.05rem;
    font-weight: 600;
    color: white;
    border-left: 4px solid transparent;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.main-nav a:hover {
    background: rgba(255, 255, 255, 0.1);
    border-left-color: white;
    padding-left: 28px;
}

.main-nav a:active,
.main-nav a.active {
    background: rgba(255, 255, 255, 0.2);
    border-left-color: #fff;
    padding-left: 28px;
}

@media (min-width: 768px) {
    .main-nav {
        display: flex;
        position: static;
        flex-direction: row;
        gap: 30px;
        padding: 0;
        overflow: visible;
        align-items: center;
        flex: 1;
    }

    .main-nav a {
        padding: 16px 0;
        border-bottom: none;
        font-size: 1rem;
    }

    .main-nav a::after {
        content: '';
        display: block;
        width: 0;
        height: 2px;
        background: var(--primary);
        transition: width var(--transition-fast);
        margin-top: 4px;
    }

    .main-nav a:hover::after,
    .main-nav a.active::after {
        width: 100%;
    }
}

.header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-left: auto;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.header-actions a {
    min-width: 120px;
}

@media (max-width: 767px) {
    .header-actions {
        width: 100%;
        justify-content: space-between;
    }
    .header-actions a {
        flex: 1 1 48%;
    }
}

/* ============================================================================
   HERO SECTION - ULTRA-MODERN
   ============================================================================ */

.search-hero-big {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    background: url('../../bg.png') center / contain no-repeat;
    background-attachment: scroll;
    background-color: #f0f4f8;
    overflow: hidden;
    margin-bottom: 32px;
    padding: 24px 0;
}

.search-hero-big::before,
.search-hero-big::after {
    content: none;
}

.search-center {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    width: 100%;
    padding: 32px 16px;
    max-width: 720px;
    margin: 0 auto;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-callout {
    width: 100%;
    background: var(--surface-50);
    padding: 24px 16px;
    display: grid;
    gap: 20px;
    border-top: 1px solid var(--surface-200);
}

@media (min-width: 768px) {
    .hero-callout {
        grid-template-columns: 1fr 1fr;
        align-items: center;
        gap: 32px;
        padding: 32px 24px;
    }
}

@media (min-width: 1024px) {
    .hero-callout {
        padding: 40px 32px;
        gap: 48px;
    }
}

.search-form-giant {
    width: 100%;
    min-width: 0;
}

.search-form-giant input,
.search-form-giant button {
    min-width: 0;
}

.search-tagline {
    font-size: 0.95rem;
    opacity: 0.95;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    text-transform: uppercase;
}

.search-form-giant {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.15);
    animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUpStagger {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.search-giant {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--surface-200);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--surface-50);
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.search-giant:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--surface-0);
    box-shadow: 0 0 0 3px rgba(26, 58, 138, 0.1);
}

.search-giant::placeholder {
    color: var(--text-light);
}

.search-giant-btn {
    width: 100% !important;
    min-height: 44px;
}

.search-keywords {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
    text-align: center;
}

.keywords-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.rotating-keywords {
    font-weight: 700;
    color: var(--primary);
    font-size: 1.125rem;
}

.keywords-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.keyword-pill {
    background: rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all var(--transition-fast);
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.keyword-pill:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

@media (min-width: 768px) {
    .search-hero-big {
        min-height: 300px;
        margin-bottom: 40px;
    }

    .search-center {
        padding: 40px 24px;
    }

    .search-form-giant {
        display: grid;
        grid-template-columns: 1fr 1fr auto;
        gap: 12px;
        align-items: flex-end;
    }

    .search-giant-btn {
        width: auto !important;
        min-width: 120px;
    }

    .search-tagline {
        font-size: 1.25rem;
        margin-bottom: 24px;
    }
}

/* ============================================================================
   BUTTONS - MODERN VARIANTS
   ============================================================================ */

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 20px;
    min-height: 44px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    user-select: none;
    text-decoration: none;
    white-space: nowrap;
}

.button:active {
    transform: scale(0.98);
}

.button-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-md);
}

.button-primary:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.button-secondary {
    background: var(--surface-100);
    color: var(--text-primary);
    border: 2px solid var(--surface-300);
}

.button-secondary:hover {
    background: var(--surface-200);
    border-color: var(--surface-300);
}

.button-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.button-outline:hover {
    background: var(--primary);
    color: white;
}

/* ============================================================================
   SECTIONS & CARDS
   ============================================================================ */

.section-card {
    background: var(--surface-0);
    border-radius: 12px;
    padding: 24px 16px;
    margin-bottom: 32px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--surface-200);
    transition: all var(--transition-base);
    overflow: hidden;
}

@media (min-width: 768px) {
    .section-card {
        border-radius: 16px;
        padding: 32px;
        margin-bottom: 40px;
    }
}

.auth-section {
    max-width: 900px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(226, 232, 240, 0.95);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.06);
}

.auth-layout {
    display: grid;
    gap: 32px;
}

.auth-intro {
    max-width: 520px;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    margin-bottom: 24px;
    gap: 16px;
}

.page-header h2 {
    font-size: clamp(1.45rem, 2.3vw, 1.95rem);
    line-height: 1.1;
    margin: 0;
}

.page-header a.button {
    flex: 0 0 auto;
    white-space: nowrap;
}

/* ============================================================================
   FEATURED TRACK - CAROUSEL
   ============================================================================ */

.featured-track {
    display: grid;
    grid-template-columns: repeat(4, minmax(220px, 1fr));
    gap: 20px;
    overflow: visible;
    margin: 0;
    padding: 0;
    grid-auto-rows: 1fr;
}

.featured-track::-webkit-scrollbar {
    display: none;
}

.featured-item {
}

@media (max-width: 1200px) {
    .featured-track {
        grid-template-columns: repeat(3, minmax(200px, 1fr));
        gap: 18px;
    }
}

@media (max-width: 900px) {
    .featured-track {
        grid-template-columns: repeat(2, minmax(180px, 1fr));
        gap: 16px;
    }
}

@media (max-width: 767px) {
    .page-header {
        align-items: flex-start;
    }

    .page-header h2 {
        width: 100%;
    }

    .page-header a.button {
        width: 100%;
        max-width: none;
    }

    .featured-track {
        grid-template-columns: 1fr !important;
        gap: 12px;
    }

    .section-card {
        padding: 20px 14px;
    }

    .search-form-giant {
        gap: 10px;
    }
}

.featured-item {
    animation: slideUp 0.6s ease-out;
}

.featured-item a {
    display: flex;
    flex-direction: column;
    height: 100%;
    text-decoration: none;
    color: inherit;
    border-radius: 16px;
    overflow: hidden;
    background: white;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
    transition: all var(--transition-base);
    border: 1px solid rgba(226, 232, 240, 0.5);
    position: relative;
}

.featured-item a::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.8) 0%, rgba(255, 255, 255, 0) 100%);
    opacity: 0;
    transition: opacity var(--transition-base);
    pointer-events: none;
    z-index: 1;
}

.featured-item a:hover {
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.15);
    transform: translateY(-8px);
    border-color: var(--primary-light);
}

.featured-item a:hover::before {
    opacity: 1;
}

.feat-thumb {
    width: 100% !important;
    aspect-ratio: 2 / 3 !important;
    overflow: hidden !important;
    background: linear-gradient(135deg, var(--surface-100) 0%, var(--surface-200) 100%) !important;
    position: relative !important;
    z-index: 0 !important;
    min-height: auto !important;
    height: auto !important;
    max-height: none !important;
}

.feat-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform var(--transition-base);
}

.featured-item a:hover .feat-thumb img {
    transform: scale(1.08);
}

.feat-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex: 1;
    min-height: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 1) 100%);
}

.feat-body h4 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-primary);
    line-height: 1.4;
    letter-spacing: -0.3px;
}

.feat-body .meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 12px;
    font-weight: 500;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.feat-body .price {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--primary);
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ============================================================================
   CALLOUT SECTION
   ============================================================================ */

.callout-section {
    display: none;
}

.hero-callout {
    display: grid;
    gap: 24px;
}

@media (min-width: 768px) {
    .hero-callout {
        grid-template-columns: 1fr 1fr;
        align-items: center;
        gap: 40px;
    }
}

.callout-copy h2 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    margin-bottom: 16px;
    color: var(--text-primary);
}

.callout-copy p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 0;
}

.callout-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

@media (min-width: 768px) {
    .callout-actions {
        flex-direction: row;
    }
}

.callout-actions .button {
    flex: 1;
}

main {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px 32px;
}

body.admin-mode main {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

@media (min-width: 640px) {
    main {
        padding: 0 20px 36px;
    }
}

@media (min-width: 1024px) {
    main {
        padding: 0 32px 48px;
    }
}

.section-card {
    max-width: 1180px;
    margin-left: auto;
    margin-right: auto;
    padding: 24px 18px;
}

/* ============================================================================
   LISTINGS PAGE
   ============================================================================ */

.listings-hero {
    padding: 80px 0 50px;
    background: linear-gradient(135deg, #0f172a 0%, #172554 50%, #1e40af 100%);
    color: #f8fafc;
    position: relative;
    overflow: hidden;
}

.listings-hero::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.listings-hero .container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 24px;
    position: relative;
    z-index: 1;
}

.hero-copy {
    max-width: 720px;
}

.listings-hero h1 {
    font-size: clamp(2.5rem, 5vw, 3.6rem);
    margin-bottom: 18px;
    color: #ffffff;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.listings-hero p {
    margin: 0;
    color: rgba(255, 255, 255, 0.85);
    font-size: clamp(1rem, 2vw, 1.15rem);
    line-height: 1.7;
    max-width: 720px;
    font-weight: 400;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.hero-badge strong {
    color: #fbbf24;
}

.listings-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 32px;
    align-items: start;
    margin: 0 auto 60px;
    max-width: 1100px;
    padding: 0 16px;
}

.filter-toggle {
    display: none;
    margin-bottom: 14px;
}

.filter-toggle .button {
    width: 100%;
}

.listings-sidebar {
    position: sticky;
    top: 120px;
    align-self: start;
}

/* Sidebar appears on the right even though it is placed before main in the HTML */
.listings-sidebar {
    grid-column: 2;
    width: 300px;
}

.listings-main {
    grid-column: 1;
}

.listings-sidebar .filter-box {
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 1);
    border-radius: 20px;
    padding: 28px;
    box-shadow: 0 12px 40px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(10px);
}

.listings-sidebar h3 {
    margin-top: 0;
    margin-bottom: 24px;
    font-size: 1.45rem;
    color: var(--text-primary);
    font-weight: 700;
    letter-spacing: -0.01em;
}

.filter-form .filter-group {
    margin-bottom: 18px;
}

.filter-form label {
    display: block;
    margin-bottom: 10px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.filter-input,
.filter-select {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid rgba(226, 232, 240, 0.8);
    border-radius: 12px;
    font-size: 0.95rem;
    color: var(--text-primary);
    background: #f8fafc;
    transition: all var(--transition-fast);
}

.filter-input:focus,
.filter-select:focus {
    outline: none;
    border-color: #3b82f6;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.filter-range {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.filter-actions {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.filter-actions .button {
    border-radius: 14px;
}

.listings-main {
    width: 100%;
}

/* Constrain main content width so cards align neatly under the hero */
.listings-main {
    padding-right: 20px;
}

.listings-main .results-header,
.listings-main .listings-grid {
    max-width: 660px;
}

.listings-grid {
    margin: 0; /* remove any external centering */
}

.results-header {
    margin-bottom: 40px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.results-header h2 {
    margin: 0;
    font-size: clamp(2rem, 3.5vw, 2.5rem);
    color: var(--text-primary);
    font-weight: 800;
    letter-spacing: -0.02em;
}

.results-subtitle {
    margin: 10px 0 0;
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
}

.listings-grid {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.listing-card {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
    border: 1px solid rgba(226, 232, 240, 0.8);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.listing-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.15);
    border-color: rgba(59, 130, 246, 0.3);
}

.listing-image {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
}

.listing-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.listing-card:hover .listing-image img {
    transform: scale(1.05);
}

.price-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
    color: white;
    padding: 10px 16px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 10px 30px rgba(30, 64, 175, 0.25);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    letter-spacing: 0.01em;
}

.listing-content {
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    flex-grow: 1;
}

.listing-hero {
    padding: 42px 0 34px;
    background: linear-gradient(135deg, rgba(8, 56, 120, 0.96) 0%, rgba(15, 93, 189, 0.95) 100%);
    color: #f8fafc;
}

.listing-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 18px;
    font-size: 0.95rem;
    color: rgba(248, 250, 252, 0.75);
}

.listing-breadcrumb a {
    color: rgba(248, 250, 252, 0.95);
    text-decoration: none;
    font-weight: 500;
}

.listing-breadcrumb span {
    color: rgba(248, 250, 252, 0.6);
}

.listing-hero h1 {
    font-size: clamp(2.4rem, 4vw, 3.4rem);
    color: #ffffff;
    margin: 0;
}

.listing-hero-meta {
    margin-top: 20px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.listing-hero-meta .meta-item {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.price-large {
    font-size: 1.25rem;
    font-weight: 800;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    padding: 12px 18px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.16);
}

.listing-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) 360px;
    gap: 30px;
    margin-bottom: 60px;
    align-items: start;
}

.listing-main {
    width: 100%;
}

.listing-gallery-main {
    display: grid;
    gap: 20px;
}

.gallery-featured {
    border-radius: 28px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.08);
}

.gallery-featured img {
    width: 100%;
    display: block;
    object-fit: cover;
}

.gallery-thumbnails {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.thumbnail {
    width: 96px;
    height: 72px;
    border-radius: 18px;
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    transition: border-color var(--transition-fast), transform var(--transition-fast);
}

.thumbnail:hover {
    transform: translateY(-2px);
}

.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.listing-details-card,
.listing-description-card,
.inquiry-card {
    background: #ffffff;
    border-radius: 28px;
    padding: 28px;
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.06);
}

.listing-details-card h2,
.listing-description-card h2 {
    margin-top: 0;
    margin-bottom: 16px;
    font-size: 1.6rem;
    color: var(--text-primary);
}

.specs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.spec-item {
    background: var(--surface-100);
    border-radius: 18px;
    padding: 18px;
}

.spec-label {
    font-size: 0.82rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.spec-value {
    margin-top: 8px;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.inquiry-card h3 {
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 1.45rem;
    color: var(--text-primary);
}

.inquiry-subtitle {
    margin: 0 0 22px;
    color: var(--text-secondary);
    font-size: 0.98rem;
    line-height: 1.6;
}

.seller-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 12px 16px;
    border-radius: 999px;
    background: rgba(16, 185, 129, 0.12);
    color: #047857;
    font-weight: 700;
    margin-bottom: 22px;
}

.badge-check {
    display: inline-flex;
    width: 26px;
    height: 26px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #10b981;
    color: #ffffff;
    font-size: 0.95rem;
}

.inquiry-form .form-group {
    margin-bottom: 18px;
}

.inquiry-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.inquiry-form .form-input,
.inquiry-form .form-textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: 14px;
    background: #f8fbff;
    color: var(--text-primary);
    font-size: 0.95rem;
}

.inquiry-form .form-textarea {
    min-height: 150px;
    resize: vertical;
}

.contact-buttons {
    display: grid;
    gap: 12px;
    margin-top: 20px;
}

.button-whatsapp {
    background: #25d366;
    color: #ffffff;
    border-color: transparent;
}

.button-call {
    background: #1d4ed8;
    color: #ffffff;
    border-color: transparent;
}

.seller-info {
    margin-top: 28px;
}

.seller-info h4 {
    margin-bottom: 18px;
    font-size: 1.15rem;
    color: var(--text-primary);
}

.seller-detail {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.seller-label {
    font-weight: 700;
    color: var(--text-primary);
}

.seller-value {
    color: var(--text-secondary);
    text-align: right;
}

.share-section {
    margin-top: 28px;
}

.share-section h4 {
    margin-bottom: 12px;
    color: var(--text-primary);
}

.share-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.share-btn {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    border: 1px solid rgba(226, 232, 240, 0.95);
    background: #ffffff;
    color: var(--text-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(15, 23, 42, 0.08);
}

.share-btn.facebook {
    color: #1877f2;
}

.share-btn.whatsapp {
    color: #25d366;
}

.share-btn.email {
    color: #9333ea;
}

@media (max-width: 1023px) {
    .listing-grid {
        grid-template-columns: 1fr;
    }

    .listing-sidebar {
        position: static;
        top: auto;
    }
}

@media (max-width: 768px) {
    .listing-hero {
        padding: 38px 0 28px;
    }

    .listing-hero-meta {
        gap: 10px;
    }

    .listing-grid {
        gap: 22px;
    }

    .gallery-thumbnails {
        justify-content: center;
    }

    .thumbnail {
        width: 76px;
        height: 64px;
    }

    .listing-details-card,
    .listing-description-card,
    .inquiry-card {
        padding: 22px;
    }
}

@media (max-width: 640px) {
    .listing-hero h1 {
        font-size: 2.15rem;
    }

    .listing-hero-meta {
        flex-direction: column;
        align-items: flex-start;
    }

    .listing-grid {
        gap: 18px;
    }

    .share-buttons {
        justify-content: flex-start;
    }
}

.view-switcher {
    display: flex;
    gap: 10px;
    background: #f0f4f8;
    padding: 4px;
    border-radius: 12px;
}

.view-toggle {
    border: 1px solid var(--surface-200);
    background: var(--surface-0);
    color: var(--text-primary);
    transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}

.view-toggle.active,
.view-toggle:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.listings-grid.grid-view {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.listings-grid.list-view {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.listings-grid.list-view .listing-card {
    flex-direction: row;
    min-height: 160px;
    align-items: center;
}

.listings-grid.list-view .listing-image {
    width: 280px;
    min-width: 200px;
    max-width: 42%;
    aspect-ratio: 16 / 10;
    border-radius: 16px 0 0 16px;
    overflow: hidden;
}

.listings-grid.list-view .listing-image img {
    height: 100%;
    width: 100%;
    object-fit: cover;
}

.listings-grid.list-view .listing-content {
    padding: 24px 22px;
}

.listings-grid.list-view .listing-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.listing-title {
    margin: 0;
    font-size: 1.2rem;
    color: var(--text-primary);
    line-height: 1.3;
}

.listing-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.meta-item {
    background: var(--surface-100);
    border-radius: 14px;
    padding: 12px 14px;
    display: grid;
    gap: 4px;
}

.meta-label {
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.meta-value {
    font-size: 0.95rem;
    color: var(--text-primary);
    font-weight: 600;
}

.empty-state {
    text-align: center;
    padding: 48px 24px;
    background: white;
    border: 1px solid var(--surface-200);
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
}

.empty-icon {
    font-size: 2.8rem;
    margin-bottom: 18px;
}

.empty-state h3 {
    margin: 0 0 10px;
    color: var(--text-primary);
}

.empty-state p {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

@media (max-width: 1023px) {
    .listings-container {
        display: block;
    }

    .filter-toggle {
        display: block;
    }

    .listings-sidebar {
        display: none;
        position: fixed;
        inset: 80px 12px 12px;
        z-index: 200;
        max-height: calc(100vh - 110px);
    }

    .listings-sidebar.open {
        display: block;
    }

    .listings-sidebar .filter-box {
        padding: 22px;
    }

    .results-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .listing-meta {
        grid-template-columns: 1fr;
    }

    .listings-grid.list-view .listing-card {
        flex-direction: column;
        min-height: auto;
    }

    .listings-grid.list-view .listing-image {
        width: 100%;
        min-width: auto;
        max-width: 100%;
        border-radius: 22px 22px 0 0;
    }

    .listings-grid.list-view .listing-content {
        padding: 18px;
    }
}

@media (max-width: 640px) {
    .listings-hero {
        padding: 34px 0 22px;
    }

    .listings-grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
    }

    .listing-card {
        border-radius: 12px;
        box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
    }

    .listing-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 16px rgba(15, 23, 42, 0.1);
    }

    .listing-image {
        aspect-ratio: 1 / 1;
    }

    .listing-content {
        padding: 10px;
    }

    .listing-title {
        font-size: 0.85rem !important;
        margin: 6px 0 4px !important;
    }

    .listing-meta {
        font-size: 0.75rem !important;
        margin-bottom: 6px;
    }

    .listing-price {
        font-size: 0.9rem !important;
        font-weight: 700;
    }

    .filter-range {
        grid-template-columns: 1fr;
    }

    .filter-actions {
        grid-template-columns: 1fr;
    }

    .listing-content {
        padding: 18px;
    }
}

@media (min-width: 640px) {
    .section-card {
        padding: 28px 22px;
    }
}

@media (min-width: 1024px) {
    .section-card {
        padding: 32px 28px;
    }
}

.section-card.featured-container {
    padding: 0;
    display: flex;
    flex-direction: column;
}

.featured-container .featured-section {
    padding: 28px 20px;
    border-bottom: 1px solid var(--surface-200);
}

.featured-container .featured-section:last-child {
    border-bottom: none;
}

@media (min-width: 768px) {
    .featured-container .featured-section {
        padding: 32px 24px;
    }
}

@media (min-width: 1024px) {
    .featured-container .featured-section {
        padding: 32px 28px;
    }
}

.section-card.featured-strip,
.section-card.nearby-strip,
.section-card.latest-strip {
    padding: 28px 20px;
}

@media (min-width: 768px) {
    main {
        padding: 0 24px 40px;
    }
}

/* ============================================================================
   FOOTER - MODERN
   ============================================================================ */

.app-footer,
.site-footer {
    background: linear-gradient(180deg, var(--primary-dark) 0%, #0a0f1e 100%);
    color: white;
    padding: 40px 16px 24px;
    margin-top: 48px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 768px) {
    .app-footer,
    .site-footer {
        padding: 56px 32px 32px;
    }
}

.footer-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding-bottom: 12px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.footer-grid::-webkit-scrollbar {
    display: none;
}

.footer-grid {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.footer-column {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 240px;
    flex: 0 0 auto;
    scroll-snap-align: start;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
}

.footer-column h4 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: #ffffff;
}

@media (min-width: 768px) {
    .footer-grid {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 24px;
        overflow: visible;
        padding-bottom: 0;
    }

    .footer-column {
        min-width: auto;
        border: none;
        background: transparent;
        padding: 0;
    }
}

@media (min-width: 1024px) {
    .footer-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }
    
    .footer-column {
        color: white;
    }
    
    .footer-column h4 {
        color: #ffffff;
    }
    
    .footer-column a {
        color: rgba(255, 255, 255, 0.9);
    }
    
    .footer-column a:hover {
        color: #ffffff;
    }
    
    .site-footer,
    .app-footer {
        color: white;
    }
    
    .footer-newsletter h4 {
        color: #ffffff;
    }
    
    .footer-newsletter {
        background: rgba(255, 255, 255, 0.1);
    }
    
    .footer-bottom {
        color: rgba(255, 255, 255, 0.85);
    }
}

.footer-column h4 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.footer-column a {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: color var(--transition-fast);
}

.footer-column a:hover {
    color: #ffffff;
}

.footer-newsletter {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    backdrop-filter: blur(10px);
}

.footer-newsletter h4 {
    margin-bottom: 12px;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.newsletter-form input {
    width: 100%;
    padding: 11px 14px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    font-size: 0.9rem;
    transition: all var(--transition-fast);
}

.newsletter-form input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-form input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

.newsletter-form button {
    width: 100%;
    min-height: 42px;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: center;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.6);
}

@media (min-width: 768px) {
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
}

/* ============================================================================
   WHATSAPP POPUP
   ============================================================================ */

.whatsapp-popup {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 999;
    animation: slideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.whatsapp-popup-content {
    background: linear-gradient(135deg, #25d366 0%, #20ba5a 100%);
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 12px 40px rgba(37, 211, 102, 0.3);
    color: white;
    text-align: center;
    position: relative;
    min-width: 200px;
}

.whatsapp-popup-close {
    position: absolute;
    top: 8px;
    right: 12px;
    background: rgba(255, 255, 255, 0.25);
    border: none;
    color: white;
    font-size: 1.8rem;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.whatsapp-popup-close:hover {
    background: rgba(255, 255, 255, 0.4);
}

.whatsapp-popup-icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
}

.whatsapp-popup-text {
    margin: 0 0 16px;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.4;
}

.whatsapp-popup-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
    padding: 12px 20px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.whatsapp-popup-btn:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: scale(1.05);
    border-color: rgba(255, 255, 255, 0.6);
}

.whatsapp-popup-btn:active {
    transform: scale(0.98);
}

@media (max-width: 640px) {
    .whatsapp-popup {
        bottom: 16px;
        right: 16px;
    }

    .whatsapp-popup-content {
        min-width: 160px;
        padding: 18px;
    }

    .whatsapp-popup-icon {
        font-size: 2rem;
    }

    .whatsapp-popup-text {
        font-size: 0.95rem;
    }
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-top: 32px;
}

.pagination-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.92);
    transition: all 0.25s ease;
}

.pagination-item.active,
.pagination-item:hover {
    background: var(--primary);
    color: white;
    border-color: transparent;
}

.section-card.site-section {
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.95);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.05);
    margin-bottom: 24px;
}

.section-card.site-section .page-header {
    margin-bottom: 28px;
}

.section-grid {
    display: grid;
    gap: 28px;
}

.steps-grid,
.sitemap-grid,
.contact-grid {
    display: grid;
    gap: 20px;
}

.steps-grid {
    display: flex;
    flex-direction: row;
    gap: 16px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 8px 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.steps-grid::-webkit-scrollbar {
    display: none;
}

.steps-grid {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.faq-grid {
    display: flex;
    flex-direction: row;
    gap: 16px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 8px 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.faq-grid::-webkit-scrollbar {
    display: none;
}

.faq-grid {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.policy-grid {
    display: flex;
    flex-direction: row;
    gap: 16px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 8px 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.policy-grid::-webkit-scrollbar {
    display: none;
}

.policy-grid {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

@media (min-width: 768px) {
    .section-grid {
        grid-template-columns: 1.2fr 0.8fr;
    }
    .steps-grid {
        display: flex;
        flex-direction: row;
        gap: 20px;
        overflow-x: auto;
        padding: 8px 0;
    }
    .step-card {
        width: 300px !important;
        min-width: 300px !important;
        height: 300px !important;
    }
    .faq-grid {
        display: flex;
        flex-direction: row;
        gap: 20px;
        overflow-x: auto;
        padding: 8px 0;
    }
    .faq-card {
        width: 300px !important;
        min-width: 300px !important;
        height: 300px !important;
    }
    .policy-grid {
        display: flex;
        flex-direction: row;
        gap: 20px;
        overflow-x: auto;
        padding: 8px 0;
    }
    .policy-card {
        width: 300px !important;
        min-width: 300px !important;
        height: 300px !important;
    }
    .sitemap-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }
    .contact-grid {
        grid-template-columns: 1.4fr 0.8fr;
    }
}

@media (max-width: 767px) {
    .sitemap-grid,
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .steps-grid {
        display: flex;
        flex-direction: row;
        gap: 12px;
        overflow-x: auto;
    }

    .step-card {
        width: 240px !important;
        min-width: 240px !important;
        height: 240px !important;
        padding: 16px !important;
    }

    .step-card h3 {
        font-size: 1rem !important;
        margin-bottom: 10px !important;
        margin-top: 4px !important;
    }

    .step-card p {
        font-size: 0.85rem !important;
    }

    .step-number {
        width: 36px !important;
        height: 36px !important;
        font-size: 1.2rem !important;
    }

    .faq-grid {
        display: flex;
        flex-direction: row;
        gap: 12px;
        overflow-x: auto;
    }

    .faq-card {
        width: 240px !important;
        min-width: 240px !important;
        height: 240px !important;
        padding: 16px !important;
    }

    .faq-card h3 {
        font-size: 1rem !important;
        margin-bottom: 10px !important;
    }

    .faq-card p {
        font-size: 0.85rem !important;
    }

    .policy-grid {
        display: flex;
        flex-direction: row;
        gap: 12px;
        overflow-x: auto;
    }

    .policy-card {
        width: 240px !important;
        min-width: 240px !important;
        height: 240px !important;
        padding: 16px !important;
    }

    .policy-card h3 {
        font-size: 1rem !important;
        margin-bottom: 10px !important;
    }

    .policy-card p {
        font-size: 0.85rem !important;
    }

    #safety .section-grid {
        display: flex !important;
        flex-direction: row !important;
        gap: 16px !important;
        align-items: flex-start !important;
    }

    #safety .section-image {
        flex-shrink: 0 !important;
        width: 110px !important;
        min-width: 110px !important;
    }

    .small-image {
        max-width: 110px !important;
        width: 110px !important;
        min-width: 110px !important;
    }

    .small-image svg {
        width: 110px !important;
        height: auto !important;
        display: block !important;
    }

    #safety .section-grid > div:last-child {
        flex: 1 !important;
    }

    #safety h2 {
        font-size: 1.15rem !important;
        margin-bottom: 6px !important;
        line-height: 1.3 !important;
    }

    #safety p {
        font-size: 0.85rem !important;
        margin-bottom: 8px !important;
        line-height: 1.4 !important;
    }

    #safety .section-label {
        font-size: 0.7rem !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
        margin-bottom: 2px !important;
        display: block !important;
    }

    #safety .feature-list {
        margin: 6px 0 0 0 !important;
        padding: 0 !important;
    }

    #safety .feature-list li {
        margin-bottom: 4px !important;
        font-size: 0.8rem !important;
        line-height: 1.3 !important;
    }

    #safety .feature-list li::before {
        margin-right: 6px !important;
    }
}
}

.step-card,
.contact-box {
    background: #f9fbff;
    border-radius: 20px;
    padding: 22px;
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.step-card {
    width: 280px !important;
    min-width: 280px !important;
    height: 280px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    scroll-snap-align: start;
}

.step-card h3 {
    font-size: 1.1rem;
    margin-bottom: 12px;
    color: var(--text-primary);
    line-height: 1.3;
    margin-top: 8px;
}

.step-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

.faq-card {
    width: 280px !important;
    min-width: 280px !important;
    height: 280px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    scroll-snap-align: start;
}

.faq-card h3 {
    font-size: 1.1rem;
    margin-bottom: 12px;
    color: var(--text-primary);
    line-height: 1.3;
}

.faq-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

.policy-card {
    width: 280px !important;
    min-width: 280px !important;
    height: 280px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    scroll-snap-align: start;
    background: #f9fbff;
    border-radius: 20px;
    padding: 22px;
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.policy-card h3 {
    font-size: 1.1rem;
    margin-bottom: 12px;
    color: var(--text-primary);
    line-height: 1.3;
}

.policy-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    font-weight: 700;
    margin-bottom: 16px;
}

.section-label {
    display: inline-block;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.78rem;
    color: var(--primary);
    font-weight: 700;
}

.feature-list,
.contact-list {
    list-style: none;
    padding: 0;
    margin: 18px 0 0;
}

.feature-list li,
.contact-list li {
    margin-bottom: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 12px;
}

.feature-list li::before {
    content: '•';
    margin-right: 10px;
    color: var(--primary);
}

.contact-list li::before {
    display: none;
}

.contact-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.phone-icon {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.email-icon {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.whatsapp-icon {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
}

.contact-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.contact-content strong {
    color: var(--text-primary);
    font-weight: 600;
}

.contact-content a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--transition-fast);
}

.contact-content a:hover {
    color: var(--primary-light);
}

.sitemap-grid a {
    display: inline-flex;
    padding: 14px 16px;
    border-radius: 16px;
    background: #f8fafc;
    border: 1px solid rgba(226, 232, 240, 0.95);
    color: var(--text-primary);
    text-decoration: none;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.sitemap-grid a:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
}

.small-footer-section {
    padding: 20px 22px;
    background: #f8fbff;
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: 20px;
    margin-bottom: 16px;
}

.contact-box h3 {
    margin-top: 0;
    margin-bottom: 16px;
}

.contact-box .button {
    width: 100%;
}

.whatsapp-float {
    position: fixed;
    bottom: 22px;
    left: 22px;
    z-index: 999;
}

.whatsapp-float a {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: 999px;
    background: #25d366;
    color: white;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 18px 40px rgba(37, 211, 102, 0.2);
}

@media (max-width: 640px) {
    .whatsapp-float {
        bottom: 14px;
        left: 14px;
    }
}

/* ============================================================================
   FORMS
   ============================================================================ */

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid var(--surface-200);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--surface-50);
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--surface-0);
    box-shadow: 0 0 0 3px rgba(26, 58, 138, 0.1);
}

.form-textarea {
    resize: vertical;
    min-height: 140px;
}

.create-listing-form {
    display: block;
    margin-top: 16px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.form-grid .full-width {
    grid-column: 1 / -1;
}

.form-actions {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 18px;
}

.form-actions .button {
    width: 100%;
    min-width: 140px;
}

.form-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.form-links a {
    color: var(--primary);
    text-decoration: none;
}

.form-links a:hover {
    text-decoration: underline;
}

.form-card.auth-form {
    padding: 28px;
    border-radius: 24px;
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.95);
}

@media (max-width: 640px) {
    .auth-section {
        padding: 24px 18px;
    }

    .auth-layout {
        gap: 24px;
    }

    .form-actions {
        flex-direction: column;
    }
}

.color-picker-row {
    display: flex;
    gap: 12px;
    align-items: center;
}

.color-picker {
    width: 56px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid var(--surface-200);
    padding: 0;
    background: white;
}

.checkbox-row {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.checkbox-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.checkbox-label input {
    width: 18px;
    height: 18px;
}

@media (min-width: 768px) {
    .form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1024px) {
    .form-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    .form-grid .full-width {
        grid-column: 1 / -1;
    }
}

/* ============================================================================
   UTILITIES
   ============================================================================ */

.text-center {
    text-align: center;
}

.mt-md {
    margin-top: 16px;
}

.mb-md {
    margin-bottom: 16px;
}

.mt-lg {
    margin-top: 20px;
}

.mb-lg {
    margin-bottom: 20px;
}

.gap-md {
    gap: 16px;
}

.gap-lg {
    gap: 20px;
}

/* ============================================================================
   RESPONSIVE & ACCESSIBILITY
   ============================================================================ */

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

@media (prefers-color-scheme: dark) {
    body {
        background-color: #0f172a;
        color: #f8fafc;
    }

    .section-card,
    .featured-item a {
        background: #1e293b;
        border-color: #334155;
    }

    .form-input,
    .form-textarea,
    .form-select {
        background: #0f172a;
        border-color: #334155;
        color: #f8fafc;
    }
}

