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

body {
    font-family: GraphikLCG-Regular, sans-serif;
    background-color: white;
    padding: 20px;
}

.logo {
    font-family: Cocogoose, sans-serif;
    font-size: 50px;
    font-weight: 1000;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    margin: 20px 0 50px 0;
}

.top-filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.filter-tab {
    padding: 12px 24px;
    font-size: 16px;
    color: #000;
    cursor: pointer;
}

.filter-tab.active {
    font-weight: 700;
}

.main-wrapper {
    display: flex;
    gap: 20px;
    max-width: 1000px;
    margin: 0 auto;
}

/* Стили для панели фильтров */
.filters-panel {
    width: 250px;
    flex-shrink: 0;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 20px;
    height: fit-content;
    position: sticky;
    top: 20px;
}

.filter-section {
    margin-bottom: 25px;
    border-bottom: 1px solid #ffffff;
    padding-bottom: 20px;
}

.filter-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.filter-title {
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
    font-size: 16px;
}

.filter-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.filter-option {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.filter-option input[type="checkbox"],
.filter-option input[type="radio"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.filter-option label {
    cursor: pointer;
    font-size: 14px;
    color: #555;
}

.price-range {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.price-inputs {
    display: flex;
    gap: 10px;
}

.price-input {
    flex: 1;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.price-slider {
    width: 100%;
    margin: 10px 0;
}

.apply-filters {
    width: 100%;
    padding: 12px;
    background: #e60023;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease;
}

.apply-filters:hover {
    background: #ad001b;
}

.reset-filters {
    width: 100%;
    padding: 10px;
    background: #f0f0f0;
    color: #333;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    margin-top: 10px;
    transition: background 0.3s ease;
}

.reset-filters:hover {
    background: #e0e0e0;
}

.container {
    flex: 1;
    display: flex;
    flex-direction: row;
    gap: 20px;
    align-items: flex-start;
}

.column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-width: 0;
}

@media (max-width: 1200px) {
    .container {
        flex-wrap: wrap;
    }
    .column {
        flex: 1 1 calc(50% - 10px);
        min-width: calc(50% - 10px);
    }
    .filters-panel { width: 220px; }
}

@media (max-width: 900px) {
    .main-wrapper { flex-direction: column; }
    .filters-panel {
        width: 100%;
        position: static;
        margin-bottom: 20px;
    }
    .column {
        flex: 1 1 calc(50% - 10px);
        min-width: calc(50% - 10px);
    }
}

@media (max-width: 600px) {
    .column {
        flex: 1 1 100%;
        min-width: 100%;
    }
    .top-filters {
        gap: 10px;
    }
    .filter-tab {
        padding: 10px 20px;
        font-size: 14px;
    }
}

.card {
    width: 100%;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: auto;
}

.card.new-card {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.5s ease forwards;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card:hover {
    transform: translateY(-5px);
    transition: transform 0.3s;
}

/* Стили для рекламного блока */
.ad-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 30px 20px;
    min-height: 200px;
    position: relative;
    overflow: hidden;
}

.ad-card::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(255,255,255,0.1);
    transform: rotate(45deg);
    z-index: 1;
}

.ad-content {
    position: relative;
    z-index: 2;
}

.ad-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255,255,255,0.2);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: bold;
}

.ad-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 8px;
}

.ad-description {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 15px;
}

.ad-button {
    background: white;
    color: #667eea;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.ad-button:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Стили для медиа-контейнера */
.media-container {
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

/* Стили для оверлея с текстом */
.text-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: white;
    padding: 20px 15px 15px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    pointer-events: none;
    z-index: 5;
}

.media-container:hover .text-overlay {
    transform: translateY(0);
}

.overlay-title {
    font-weight: bold;
    margin-bottom: 5px;
    font-size: 16px;
}

.overlay-description {
    font-size: 14px;
    line-height: 1.4;
    opacity: 0.9;
}

/* Стили для информации о пользователе */
.user-info {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 15px;
    margin-top: auto;
}

.user-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.user-name {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

/* Стили для карусели */
.carousel {
    position: relative;
    overflow: hidden;
    width: 100%;
}

.carousel-inner {
    display: flex;
    transition: transform 0.3s ease;
    width: 100%;
}

.carousel-item {
    min-width: 100%;
}

.carousel-img, .carousel-video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
    border: 1px solid #ccc;
}

.carousel-controls {
    position: absolute;
    top: 10px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 6px;
    z-index: 5;
}

.carousel-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transition: background 0.3s;
}

.carousel-dot.active {
    background: white;
}

/* Стили для секций карусели */
.carousel-sections {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    z-index: 6;
    pointer-events: none;
}

.carousel-section {
    flex: 1;
    height: 100%;
    pointer-events: auto;
    cursor: pointer;
}

/* Стили для кнопки избранного */
.favorite-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.3s ease;
    z-index: 10;
    pointer-events: auto;
}

.media-container:hover .favorite-btn {
    opacity: 1;
    transform: scale(1);
}

.favorite-btn:hover {
    background: white;
    transform: scale(1.1);
}

.favorite-btn.active {
    opacity: 1;
    transform: scale(1);
    background: white;
}

.favorite-icon {
    width: 18px;
    height: 18px;
    fill: #333;
    transition: fill 0.3s ease;
}

.favorite-btn.active .favorite-icon {
    fill: #e60023;
}

.favorite-btn:hover .favorite-icon {
    fill: #e60023;
}

/* Стили для кнопки поделиться */
.share-btn {
    position: absolute;
    top: 52px;
    right: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.3s ease;
    z-index: 10;
    pointer-events: auto;
}

.media-container:hover .share-btn {
    opacity: 1;
    transform: scale(1);
}

.share-btn:hover {
    background: white;
    transform: scale(1.1);
}

.share-icon {
    width: 18px;
    height: 18px;
    fill: #333;
    transition: fill 0.3s ease;
}

.share-btn:hover .share-icon {
    fill: #0070ba;
}

/* Стили для видео */
.video-container {
    position: relative;
    width: 100%;
}

.video-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 5;
}

.video-container:hover .video-play-btn {
    opacity: 1;
}

.video-play-icon {
    width: 24px;
    height: 24px;
    fill: #333;
    margin-left: 3px;
}

.video-play-btn:hover {
    background: white;
    transform: translate(-50%, -50%) scale(1.1);
}

.video-duration {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 5;
}

/* Стили для модального окна поделиться */
.share-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.share-modal.active {
    opacity: 1;
    visibility: visible;
}

.share-modal-content {
    background: white;
    border-radius: 12px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.share-modal.active .share-modal-content {
    transform: translateY(0);
}

.share-modal-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 16px;
    color: #333;
}

.share-options {
    display: flex;
    justify-content: space-around;
    margin-bottom: 20px;
}

.share-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.share-option:hover {
    transform: scale(1.05);
}

.share-option-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
}

.share-option.facebook {
    background: #3b5998;
}

.share-option.twitter {
    background: #1da1f2;
}

.share-option.pinterest {
    background: #e60023;
}

.share-option.copy {
    background: #666;
}

.share-option-text {
    font-size: 12px;
    color: #666;
}

.share-url {
    display: flex;
    margin-bottom: 16px;
}

.share-url-input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px 0 0 4px;
    font-size: 14px;
}

.copy-url-btn {
    padding: 8px 16px;
    background: #e60023;
    color: white;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 14px;
}

.close-modal {
    width: 100%;
    padding: 10px;
    background: #f0f0f0;
    color: #333;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.loading {
    text-align: center;
    padding: 40px 20px;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    margin: 20px 0;
}

/* Крутящийся прелоадер */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #e60023;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hidden {
    display: none;
}
