/* === Global Styles === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2c5364;
    --primary-light: #3e6d7d;
    --primary-dark: #1f3a47;
    --accent-color: #21b573;
    --accent-hover: #1da862;
    --text-dark: #1a1a1a;
    --text-gray: #666;
    --text-light: #999;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --border-color: #e0e0e0;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.15);
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.08);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica', 'Arial', sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-light);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* === Header === */
.header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    gap: 0.25rem;
}

.logo-text {
    color: var(--primary-color);
}

.logo-accent {
    color: var(--accent-color);
}

.nav {
    display: flex;
    gap: 2rem;
    flex: 1;
    justify-content: center;
}

.nav-link {
    color: var(--text-gray);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent-color);
}

.header-actions {
    display: flex;
    gap: 1rem;
}

.btn-primary,
.btn-secondary {
    padding: 0.625rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.btn-primary {
    background: var(--accent-color);
    color: white;
}

.btn-primary:hover {
    background: var(--accent-hover);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

/* === Hero Section === */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: white;
    padding: 4rem 0 5rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="40" fill="rgba(255,255,255,0.05)"/></svg>');
    opacity: 0.1;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-highlight {
    display: block;
    background: linear-gradient(90deg, var(--accent-color), #2dd87e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.25rem;
    line-height: 1.6;
    opacity: 0.95;
    margin-bottom: 2rem;
}

.hero-features {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.feature-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    padding: 0.75rem 1.25rem;
    border-radius: 50px;
    font-weight: 500;
}

.feature-icon {
    width: 20px;
    height: 20px;
    stroke-width: 2.5;
}

/* === Objects Section === */
.objects-section {
    padding: 4rem 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 1.5rem;
}

/* === Filters Panel === */
.filters-panel {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding: 1rem 1.5rem;
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.filter-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-gray);
    white-space: nowrap;
}

.filter-select {
    padding: 0.6rem 2rem 0.6rem 1rem;
    font-size: 0.95rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-white);
    color: var(--text-dark);
    cursor: pointer;
    min-width: 200px;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-select:hover {
    border-color: var(--primary-color);
}

.filter-select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(33, 181, 115, 0.15);
}

.btn-reset-filters {
    padding: 0.6rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-gray);
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-reset-filters:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
    background: rgba(44, 83, 100, 0.05);
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.section-title-center {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-dark);
    text-align: center;
    margin-bottom: 3rem;
}

.section-description {
    color: var(--text-gray);
    font-size: 1rem;
}

.btn-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: gap 0.2s;
}

.btn-link:hover {
    gap: 0.75rem;
}

.btn-arrow {
    width: 20px;
    height: 20px;
    stroke-width: 2.5;
}

/* === Objects Grid === */
.objects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.object-card {
    background: var(--bg-white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.object-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.object-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: linear-gradient(135deg, #e8f0f3 0%, #dce5e8 100%);
}

.object-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
    background: var(--bg-light);
}

.object-image img[src*="data:image/svg"] {
    object-fit: contain;
    background: linear-gradient(135deg, #e8f0f3 0%, #dce5e8 100%);
}

.object-card:hover .object-image img {
    transform: scale(1.05);
}

.object-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 0.375rem 0.875rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-color);
}

.object-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.object-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
    line-height: 1.4;
    min-height: 3em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.object-location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.location-icon {
    width: 16px;
    height: 16px;
    stroke-width: 2;
}

.object-features {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    min-height: 3.5rem;
}

.feature-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
}

.feature-label {
    color: var(--text-light);
}

.feature-value {
    color: var(--text-dark);
    font-weight: 500;
}

.object-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
}

.price-label {
    color: var(--text-gray);
    font-size: 0.9rem;
}

.price-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--accent-color);
}

.btn-card {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: auto;
}

.btn-card:hover {
    background: var(--primary-light);
    box-shadow: var(--shadow-hover);
}

.btn-icon {
    width: 18px;
    height: 18px;
    stroke-width: 2.5;
}

/* === Features Section === */
.features-section {
    padding: 4rem 0 5rem;
    background: var(--bg-white);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    text-align: center;
    padding: 2rem 1.5rem;
    border-radius: 12px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card);
}

.feature-card-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
}

.feature-card p {
    color: var(--text-gray);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* === Footer === */
.footer {
    background: var(--text-dark);
    color: white;
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-column h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: white;
}

.footer-description {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-top: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--accent-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* === Responsive === */
@media (max-width: 968px) {
    .hero-title {
        font-size: 2.25rem;
    }

    .objects-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }

    .header-content {
        flex-wrap: wrap;
    }

    .nav {
        order: 3;
        width: 100%;
        justify-content: flex-start;
    }
    
    .filters-panel {
        flex-wrap: wrap;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 0 15px;
    }
    
    /* Header mobile */
    .header {
        padding: 0.75rem 0;
    }
    
    .header-content {
        gap: 0.75rem;
    }
    
    .logo {
        font-size: 1.3rem;
    }
    
    .nav {
        display: none; /* Скрываем навигацию на мобильных */
    }
    
    .header-actions {
        width: 100%;
        order: 2;
        gap: 0.5rem;
    }

    .btn-primary,
    .btn-secondary {
        flex: 1;
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }
    
    /* Hero mobile */
    .hero {
        padding: 2.5rem 0 3rem;
    }

    .hero-title {
        font-size: 1.6rem;
        margin-bottom: 1rem;
    }

    .hero-description {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-features {
        gap: 0.75rem;
    }
    
    .feature-badge {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
        border-radius: 30px;
    }
    
    .feature-icon {
        width: 16px;
        height: 16px;
    }
    
    /* Objects section mobile */
    .objects-section {
        padding: 2rem 0;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .section-title-center {
        font-size: 1.4rem;
        margin-bottom: 2rem;
    }
    
    .filters-panel {
        padding: 0.875rem 1rem;
        gap: 0.75rem;
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-group {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .filter-select {
        min-width: unset;
        width: 100%;
    }
    
    .btn-reset-filters {
        align-self: flex-start;
    }

    .objects-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    
    .object-card {
        border-radius: 12px;
    }
    
    .object-image {
        height: 180px;
    }
    
    .object-content {
        padding: 1.25rem;
    }
    
    .object-title {
        font-size: 1rem;
        min-height: 2.5em;
    }
    
    .object-location {
        font-size: 0.85rem;
        margin-bottom: 0.75rem;
    }
    
    .object-features {
        margin-bottom: 0.75rem;
        padding-bottom: 0.75rem;
    }
    
    .price-value {
        font-size: 1.15rem;
    }
    
    .btn-card {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
    
    /* Features section mobile */
    .features-section {
        padding: 2.5rem 0 3rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    
    .feature-card {
        padding: 1.5rem 1.25rem;
    }
    
    .feature-card-icon {
        font-size: 2.5rem;
    }
    
    .feature-card h3 {
        font-size: 1rem;
    }
    
    .feature-card p {
        font-size: 0.9rem;
    }
    
    /* Footer mobile */
    .footer {
        padding: 2rem 0 1.25rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .footer-column h4 {
        margin-bottom: 0.75rem;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
}

/* Очень маленькие экраны */
@media (max-width: 380px) {
    .hero-title {
        font-size: 1.4rem;
    }
    
    .hero-description {
        font-size: 0.9rem;
    }
    
    .feature-badge {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
    
    .section-title {
        font-size: 1.3rem;
    }
    
    .btn-primary,
    .btn-secondary {
        font-size: 0.8rem;
        padding: 0.5rem 0.75rem;
    }
}

/* === Loading State === */
.loading-state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    color: var(--text-gray);
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-state p {
    font-size: 1rem;
    margin: 0;
}

/* === No Results === */
.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-gray);
}

.no-results p:first-child {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.no-results p:last-child {
    font-size: 0.95rem;
}

/* === Load More === */
.load-more-container {
    display: flex;
    justify-content: center;
    padding: 2rem 0 1rem;
}

.btn-load-more {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2.5rem;
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-load-more:hover {
    background: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-hover);
}


