/* --- БАЗОВЫЕ НАСТРОЙКИ --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: Arial, sans-serif;
    color: #333;
    background-color: #f0f0f0; /* Светлый фон вокруг контента, вместо темно-зеленого */
    line-height: 1.4;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

.container {
    max-width: 980px;
    margin: 0 auto;
    background-color: #fff;
}

/* --- ШАПКА (Зеленый фон) --- */
.site-header {
    background-color: #999966; 
    padding: 5px 0; 
    border-bottom: 1px solid #fff;
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 0 10px;
}

.logo {
    max-height: 50px; 
}

.header-text p {
    color: #fff;
    font-size: 11px;
    margin-bottom: 0;
}

.header-text h1 {
    color: #fff;
    font-size: 20px; 
    font-style: italic;
    font-family: 'Georgia', serif;
    font-weight: bold;
}

/* --- МЕНЮ (Зеленый фон) --- */
.main-nav {
    background-color: #c4c49a; 
    padding: 2px 0;
}

.nav-list {
    list-style: none;
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 5px;
    padding-left: 10px;
}

.nav-list a {
    display: block;
    padding: 5px 8px;
    color: #000;
    font-weight: bold;
    font-size: 13px;
}

.nav-list a:hover {
    color: #660000;
}

/* --- ОСНОВНОЙ КОНТЕНТ (Белый фон) --- */
main {
    padding: 15px;
    background-color: #fff;
}

/* Верхний блок */
.hero-wrapper {
    display: flex;
    flex-wrap: wrap; 
    gap: 15px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.hero-image {
    flex: 0 0 640px; 
    position: relative;
}

.age-limit {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #fff;
    padding: 2px 5px;
    font-weight: bold;
    border: 1px solid #ccc;
}

.hero-info {
    flex: 1; 
    min-width: 250px;
}

.author {
    color: #808000;
    font-size: 14px;
    margin-bottom: 5px;
    text-align: right;
}

.play-title {
    color: #808000;
    font-size: 26px;
    margin-bottom: 10px;
    text-align: center;
    font-family: 'Georgia', serif;
}

.subtitle, .premiere {
    color: #808000;
    font-style: italic;
    margin-bottom: 10px;
    text-align: center;
    font-size: 13px;
}

.credits p {
    margin-bottom: 5px;
    font-size: 13px;
}

.credits .duration {
    margin-top: 10px;
    font-weight: bold;
}

/* Кнопки */
.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background-color: #c99e3b;
    padding: 10px;
    width: 130px; 
    border: 1px solid #a67c00;
}

.btn {
    color: #660000;
    text-decoration: underline;
    font-weight: bold;
    font-size: 13px;
    text-align: center;
}

.btn:hover {
    color: #000;
}

/* --- АКТЁРЫ --- */
.cast-section {
    clear: both;
    margin-top: 20px;
}

.section-title {
    text-align: center;
    color: #333;
    font-size: 14px;
    margin-bottom: 15px;
    text-decoration: underline;
    text-transform: uppercase;
}

.cast-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 колонки */
    gap: 15px;
}

.actor-card {
    background: #f4f4f0;
    border: 1px solid #ccc;
    text-align: center;
    padding: 10px;
}

/* Картинки теперь показываются целиком */
.actor-card img {
    width: 100%;
    height: auto; /* Убрали фиксированную высоту */
    max-height: 450px; /* Ограничили максимальную высоту, чтобы блок не был слишком длинным */
    object-fit: contain; /* Показывать картинку целиком, не обрезая */
    margin: 0 auto 10px auto; /* Центрируем картинку */
}

.actor-card h4 {
    font-size: 14px;
    margin-bottom: 5px;
    color: #000;
}

.actor-card p {
    font-size: 13px;
    color: #333;
}

.actor-card p a {
    color: #0056b3;
    text-decoration: underline;
}

.actor-card p a:hover {
    color: #660000;
    text-decoration: none;
}

/* --- ТЕКСТ О СПЕКТАКЛЕ --- */
.about-section {
    background-color: #f4f4f0;
    padding: 15px;
    border: 1px solid #ccc;
    margin-top: 20px;
    font-size: 13px;
}

.about-section p {
    margin-bottom: 10px;
    text-align: justify;
}

/* --- ПОДВАЛ --- */
.site-footer {
    background-color: #999966;
    color: #fff;
    text-align: center;
    padding: 10px 0;
    font-size: 12px;
}

/* --- АДАПТИВНОСТЬ --- */
@media (max-width: 900px) {
    .hero-wrapper {
        flex-direction: column;
    }
    
    .hero-image {
        flex: 1;
        width: 100%;
    }

    .action-buttons {
        width: 100%;
        flex-direction: row;
        justify-content: center;
    }

    .cast-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}