/* movie-meta.css */
/* Основные стили для компактного блока информации о фильме */

.compact-meta-section {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #ffffff;
    border: 1px solid #e1e5e9;
    border-radius: 8px;
    padding: 16px;
    margin: 16px 0;
    font-size: 0.9em;
    color: #333;
    line-height: 1.4;
}

/* Контейнер для превью и контента */
.meta-content-wrapper {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

/* Стили для превью (постера) */
.meta-preview {
    flex-shrink: 0;
    width: 120px;
    position: relative;
}

.preview-image {
    width: 100%;
    height: auto;
    border-radius: 6px;
    display: block;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 1px solid #e9ecef;
    aspect-ratio: 2/3;
    object-fit: cover;
}

.preview-badge {
    position: absolute;
    bottom: 8px;
    left: 0;
    right: 0;
    background: rgba(229, 9, 20, 0.9);
    color: white;
    font-size: 0.75em;
    font-weight: 600;
    text-align: center;
    padding: 4px 6px;
    border-radius: 0 4px 4px 0;
}

/* Основной контент */
.meta-main-content {
    flex: 1;
    min-width: 0;
}

.meta-row.meta-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 10px;
}

.meta-title {
    margin: 0;
    font-size: 1.5em;
    font-weight: 700;
    color: #111;
    line-height: 1.2;
    flex: 1;
    min-width: 200px;
}

.meta-header-right {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-shrink: 0;
}

.meta-rating {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rating-stars {
    width: 80px;
    height: 14px;
    background-color: #e1e5e9;
    border-radius: 7px;
    overflow: hidden;
    position: relative;
}

.rating-fill {
    height: 100%;
    background: linear-gradient(90deg, #ffb347, #ffcc33);
    border-radius: 7px;
}

.rating-value {
    font-weight: 700;
    font-size: 1.3em;
    color: #111;
}

.rating-max {
    font-size: 0.9em;
    color: #6c757d;
}

/* Стили для кнопки закладки */
.bookmark-btn {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #6c757d;
    transition: all 0.2s ease;
    padding: 0;
}

.bookmark-btn:hover {
    background: #edf2ff;
    border-color: #3a86ff;
    color: #3a86ff;
    transform: translateY(-1px);
}

.bookmark-btn:active {
    transform: translateY(0);
}

.bookmark-icon {
    stroke-width: 1.8;
    transition: stroke-width 0.2s ease;
}

.meta-description {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f0f0f0;
}

.description-text {
    margin: 0;
    color: #444;
    font-size: 0.95em;
    line-height: 1.5;
}

.meta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px 20px;
}

.meta-item {
    display: flex;
    flex-direction: column;
}

.meta-item-full {
    grid-column: 1 / -1;
}

.meta-label {
    font-size: 0.85em;
    color: #6c757d;
    font-weight: 500;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.meta-value {
    font-weight: 500;
    color: #212529;
    word-break: break-word;
}

.meta-item .meta-value strong {
    color: #111;
    font-size: 1.05em;
}

time.meta-value {
    color: #495057;
}

.meta-link {
    color: #3a86ff;
    text-decoration: none;
    font-weight: 500;
}

.meta-link:hover {
    color: #2667cc;
    text-decoration: underline;
}

.meta-tag {
    display: inline-block;
    background: #edf2ff;
    color: #3a86ff;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.85em;
    margin-right: 6px;
    margin-bottom: 5px;
    text-decoration: none;
    font-weight: 500;
    border: 1px solid #d0ddff;
}

.meta-tag:hover {
    background: #d0ddff;
    color: #2667cc;
}

/* Адаптивность */
@media (max-width: 768px) {
    .compact-meta-section {
        padding: 14px;
        font-size: 0.88em;
    }
    
    .meta-content-wrapper {
        gap: 16px;
    }
    
    .meta-preview {
        width: 100px;
    }
    
    .meta-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 12px;
    }
    
    .meta-title {
        font-size: 1.3em;
    }
    
    .meta-header-right {
        gap: 10px;
    }
    
    .bookmark-btn {
        width: 36px;
        height: 36px;
    }
    
    .rating-stars {
        width: 70px;
    }
}

@media (max-width: 600px) {
    .meta-content-wrapper {
        flex-direction: column;
        gap: 16px;
    }
    
    .meta-preview {
        width: 100px;
        align-self: flex-start;
    }
    
    .meta-main-content {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .compact-meta-section {
        padding: 12px;
    }
    
    .meta-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .meta-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .meta-header-right {
        align-self: stretch;
        justify-content: space-between;
    }
    
    .meta-preview {
        width: 90px;
    }
}

/* Поддержка темной темы */
@media (prefers-color-scheme: dark) {
    .compact-meta-section {
        background: #1a1a1a;
        border-color: #333;
        color: #f0f0f0;
    }
    
    .meta-title {
        color: #fff;
    }
    
    .meta-value {
        color: #e0e0e0;
    }
    
    .meta-label {
        color: #aaa;
    }
    
    .description-text {
        color: #ccc;
    }
    
    .bookmark-btn {
        background: #2a2a2a;
        border-color: #444;
        color: #aaa;
    }
    
    .bookmark-btn:hover {
        background: #333;
        border-color: #3a86ff;
        color: #3a86ff;
    }
    
    .preview-image {
        border-color: #444;
    }
}