/*
Theme Name: Bryansk Art Museum
Theme URI: https://example.com/
Author: Custom
Description: Гибкая тема для Брянского областного художественного музейно-выставочного центра. Слайдер, сайдбары, настраиваемые цвета и блоки.
Version: 1.0.0
License: GPL-2.0-or-later
Text Domain: bryansk-art
*/

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

body {
    font-family: 'Segoe UI', 'Georgia', serif;
    color: #201b23;
    background: #f5f2ed;
    line-height: 1.6;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; }

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

.layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    margin-bottom: 48px;
}

.layout.has-left-sidebar { grid-template-columns: 280px 1fr; }
.layout.has-right-sidebar { grid-template-columns: 1fr 280px; }
.layout.has-both-sidebars { grid-template-columns: 280px 1fr 280px; }

.header {
    background: var(--bam-header-bg, #201b23);
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 3px solid var(--bam-accent, #876940);
    box-shadow: 0 4px 20px rgba(32, 27, 35, 0.3);
}

.admin-bar .header { top: 32px; }

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}

.header-top-widgets,
.footer-widgets-top,
.footer-widgets-bottom {
    background: rgba(135, 105, 64, 0.08);
    border-bottom: 1px solid rgba(135, 105, 64, 0.2);
}

.footer-widgets-top,
.footer-widgets-bottom {
    border-top: 1px solid rgba(135, 105, 64, 0.15);
    border-bottom: none;
    padding: 16px 0;
    color: rgba(245, 242, 237, 0.7);
}

.header-top-widgets .container,
.footer-widgets-top .container,
.footer-widgets-bottom .container {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    align-items: center;
    justify-content: center;
    padding-top: 10px;
    padding-bottom: 10px;
}

.logo-area { display: flex; align-items: center; gap: 0; flex-shrink: 0; }

.logo-icon {
    width: 52px;
    height: 52px;
    background: var(--bam-accent, #876940);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 16px;
    flex-shrink: 0;
    box-shadow: 0 0 0 2px #2b383d, 0 4px 12px rgba(135, 105, 64, 0.3);
    position: relative;
    overflow: hidden;
}

.logo-icon img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }

.logo-icon::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    background: #f5f2ed;
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    opacity: 0.15;
}

.logo-text {
    font-size: 24px;
    font-weight: 700;
    color: #f5f2ed;
    line-height: 1.15;
    letter-spacing: 0.5px;
}

.logo-text .accent { color: var(--bam-accent, #876940); }

.logo-text small {
    font-weight: 400;
    font-size: 13px;
    color: rgba(245, 242, 237, 0.5);
    display: block;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    margin-top: 1px;
}

.nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
    justify-content: center;
    flex: 1 1 auto;
}

.nav ul { display: flex; list-style: none; gap: 4px; flex-wrap: wrap; justify-content: center; }

.nav a {
    padding: 8px 18px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 500;
    color: rgba(245, 242, 237, 0.7);
    transition: all 0.3s;
    white-space: nowrap;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.nav a:hover { color: #f5f2ed; background: rgba(135, 105, 64, 0.2); }
.nav .current-menu-item > a,
.nav .current_page_item > a { color: #f5f2ed; background: var(--bam-accent, #876940); box-shadow: 0 4px 16px rgba(135, 105, 64, 0.3); }

.nav .menu-item-has-children { position: relative; }
.nav .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--bam-header-bg, #201b23);
    min-width: 220px;
    padding: 8px;
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0,0,0,0.3);
    display: none;
    flex-direction: column;
    z-index: 50;
    border: 1px solid rgba(135, 105, 64, 0.2);
}
.nav .menu-item-has-children:hover > .sub-menu { display: flex; }
.nav .sub-menu a { padding: 8px 14px; font-size: 13px; border-radius: 8px; }

.btn-ticket {
    background: var(--bam-accent, #876940) !important;
    color: #f5f2ed !important;
    padding: 10px 28px !important;
    border-radius: 30px !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    box-shadow: 0 4px 16px rgba(135, 105, 64, 0.3);
    transition: all 0.3s;
    margin-left: 6px;
    display: inline-block;
}

.btn-ticket:hover { background: #a07d4f !important; transform: translateY(-2px); }

.hero {
    background: linear-gradient(145deg, var(--bam-hero-from, #2b383d) 0%, var(--bam-hero-to, #201b23) 100%);
    border-radius: 24px;
    margin: 32px auto 36px;
    padding: 52px;
    position: relative;
    overflow: hidden;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 32px;
    border: 1px solid rgba(135, 105, 64, 0.2);
    box-shadow: 0 12px 48px rgba(32, 27, 35, 0.3);
}

.hero::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(135, 105, 64, 0.06) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.hero-content { position: relative; z-index: 2; max-width: 480px; flex: 1 1 300px; }

.hero-content .hero-badge {
    display: inline-block;
    background: rgba(135, 105, 64, 0.15);
    color: var(--bam-accent, #876940);
    padding: 4px 18px;
    border-radius: 30px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 16px;
    border: 1px solid rgba(135, 105, 64, 0.2);
}

.hero-content h1 {
    font-size: 42px;
    font-weight: 700;
    color: #f5f2ed;
    line-height: 1.15;
    margin-bottom: 14px;
}

.hero-content h1 span { color: var(--bam-accent, #876940); }
.hero-content p { font-size: 18px; color: rgba(245, 242, 237, 0.7); margin-bottom: 28px; line-height: 1.7; }
.hero-buttons { display: flex; gap: 14px; flex-wrap: wrap; }

.btn-primary {
    background: var(--bam-accent, #876940);
    color: #f5f2ed;
    padding: 14px 38px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.3s;
    display: inline-block;
    box-shadow: 0 4px 20px rgba(135, 105, 64, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.btn-primary:hover { background: #a07d4f; transform: translateY(-3px); }

.btn-secondary {
    background: rgba(245, 242, 237, 0.08);
    backdrop-filter: blur(4px);
    color: #f5f2ed;
    padding: 14px 38px;
    border-radius: 30px;
    font-weight: 500;
    font-size: 16px;
    border: 1px solid rgba(245, 242, 237, 0.15);
    transition: all 0.3s;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.btn-secondary:hover { background: rgba(245, 242, 237, 0.15); transform: translateY(-3px); }

.hero-slider {
    position: relative;
    z-index: 2;
    flex: 1 1 400px;
    min-width: 280px;
    max-width: 560px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
    aspect-ratio: 16 / 9;
    background: #201b23;
    border: 1px solid rgba(135, 105, 64, 0.15);
}

.hero-slider .slider-track { display: flex; width: 100%; height: 100%; transition: transform 1s ease-in-out; }
.hero-slider .slider-slide { flex: 0 0 100%; height: 100%; background-size: cover; background-position: center; background-repeat: no-repeat; }
.hero-slider .slider-dots {
    position: absolute;
    bottom: 14px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 10px;
    z-index: 10;
}

.hero-slider .slider-dots span {
    display: block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(245, 242, 237, 0.25);
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid rgba(245, 242, 237, 0.1);
}

.hero-slider .slider-dots span.active { background: var(--bam-accent, #876940); transform: scale(1.2); border-color: var(--bam-accent, #876940); box-shadow: 0 0 12px rgba(135, 105, 64, 0.4); }
.hero-slider .slider-dots span:hover { background: rgba(245, 242, 237, 0.6); }

.info-banner {
    background: #f5f2ed;
    border-radius: 16px;
    padding: 28px 32px;
    margin: 0 0 36px 0;
    box-shadow: 0 2px 12px rgba(32, 27, 35, 0.06);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    border: 1px solid rgba(43, 56, 61, 0.08);
}

.info-banner-item { display: flex; align-items: center; gap: 16px; }
.info-banner-item .icon { font-size: 30px; line-height: 1; }
.info-banner-item .text { font-size: 14px; color: #2b383d; }
.info-banner-item .text strong { display: block; font-size: 16px; color: #201b23; }

.section-title { font-size: 30px; font-weight: 700; color: #201b23; margin-bottom: 4px; letter-spacing: -0.5px; }
.section-title span { color: var(--bam-accent, #876940); }
.section-subtitle { color: #2b383d; font-size: 16px; margin-bottom: 28px; opacity: 0.7; }

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}

.section-header .link-all {
    color: var(--bam-accent, #876940);
    font-weight: 500;
    font-size: 15px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s;
    padding-bottom: 2px;
}

.section-header .link-all:hover { border-bottom-color: var(--bam-accent, #876940); }

.afisha-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.afisha-card {
    background: #f5f2ed;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(32, 27, 35, 0.04);
    border: 1px solid rgba(43, 56, 61, 0.06);
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
}

.afisha-card:hover { transform: translateY(-6px); box-shadow: 0 12px 36px rgba(32, 27, 35, 0.1); border-color: var(--bam-accent, #876940); }

.afisha-card .card-image {
    height: 160px;
    background: linear-gradient(135deg, #2b383d, #201b23);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    color: rgba(245, 242, 237, 0.3);
    position: relative;
    background-size: cover;
    background-position: center;
}

.afisha-card .card-body { padding: 20px 22px 24px; flex: 1; display: flex; flex-direction: column; background: #fff; }
.afisha-card .card-tag {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--bam-accent, #876940);
    background: rgba(135, 105, 64, 0.08);
    padding: 3px 14px;
    border-radius: 30px;
    align-self: flex-start;
    margin-bottom: 10px;
}

.afisha-card .card-title { font-size: 17px; font-weight: 600; color: #201b23; margin-bottom: 8px; line-height: 1.3; }
.afisha-card .card-desc { font-size: 14px; color: #2b383d; opacity: 0.7; flex: 1; margin-bottom: 16px; }
.afisha-card .card-link { color: var(--bam-accent, #876940); font-weight: 500; font-size: 14px; display: inline-flex; align-items: center; gap: 6px; transition: all 0.3s; }
.afisha-card .card-link:hover { gap: 12px; color: #a07d4f; }

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.news-item {
    background: #fff;
    border-radius: 14px;
    padding: 22px 24px;
    border: 1px solid rgba(43, 56, 61, 0.06);
    transition: all 0.3s;
}

.news-item:hover { border-color: var(--bam-accent, #876940); box-shadow: 0 4px 20px rgba(32, 27, 35, 0.06); }
.news-item .news-date { font-size: 12px; color: var(--bam-accent, #876940); font-weight: 600; text-transform: uppercase; letter-spacing: 0.8px; margin-bottom: 6px; }
.news-item .news-title { font-size: 15px; font-weight: 600; color: #201b23; margin-bottom: 6px; }
.news-item .news-title a:hover { color: var(--bam-accent, #876940); }
.news-item .news-excerpt { font-size: 14px; color: #2b383d; opacity: 0.7; }

.widget-area { display: flex; flex-direction: column; gap: 24px; }

.widget {
    background: #fff;
    border-radius: 14px;
    padding: 22px 24px;
    border: 1px solid rgba(43, 56, 61, 0.06);
}

.widget-title {
    font-size: 16px;
    font-weight: 700;
    color: #201b23;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(135, 105, 64, 0.25);
}

.widget ul { list-style: none; }
.widget ul li { padding: 6px 0; font-size: 14px; border-bottom: 1px dashed rgba(43, 56, 61, 0.08); }
.widget ul li:last-child { border-bottom: none; }
.widget a:hover { color: var(--bam-accent, #876940); }

.footer {
    background: var(--bam-footer-bg, #201b23);
    color: rgba(245, 242, 237, 0.6);
    padding: 52px 0 32px;
    margin-top: 16px;
    border-top: 3px solid var(--bam-accent, #876940);
}

.footer-inner {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
    margin-bottom: 32px;
}

.footer h4 { color: #f5f2ed; font-size: 16px; margin-bottom: 12px; letter-spacing: 0.5px; }
.footer h4 span { color: var(--bam-accent, #876940); }
.footer p { font-size: 14px; line-height: 1.8; }
.footer a { color: rgba(245, 242, 237, 0.6); transition: color 0.3s; }
.footer a:hover { color: var(--bam-accent, #876940); }
.footer .phone { color: #f5f2ed; font-size: 20px; font-weight: 600; }
.footer .phone span { color: var(--bam-accent, #876940); }

.footer-bottom {
    border-top: 1px solid rgba(245, 242, 237, 0.06);
    padding-top: 20px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 13px;
}

@media (max-width: 992px) {
    .layout.has-left-sidebar,
    .layout.has-right-sidebar,
    .layout.has-both-sidebars { grid-template-columns: 1fr; }
    .hero { padding: 36px 32px; flex-direction: column; text-align: center; }
    .hero-content { max-width: 100%; }
    .hero-content h1 { font-size: 32px; }
    .hero-buttons { justify-content: center; }
    .hero-slider { max-width: 100%; width: 100%; }
}

@media (max-width: 768px) {
    .header-inner { flex-direction: column; align-items: stretch; }
    .logo-area { justify-content: center; }
    .logo-text { text-align: center; font-size: 20px; }
    .logo-icon { margin-right: 12px; width: 44px; height: 44px; }
    .nav { justify-content: center; }
    .nav a { font-size: 12px; padding: 6px 14px; }
    .btn-ticket { padding: 8px 18px !important; font-size: 12px !important; }
    .hero { padding: 24px 18px; min-height: auto; margin: 20px auto 24px; }
    .hero-content h1 { font-size: 26px; }
    .hero-content p { font-size: 15px; }
    .info-banner { flex-direction: column; align-items: stretch; padding: 20px; }
    .afisha-grid { grid-template-columns: 1fr 1fr; }
    .news-grid { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr; gap: 24px; }
    .footer-bottom { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
    .afisha-grid { grid-template-columns: 1fr; }
    .container { padding: 0 16px; }
    .section-title { font-size: 24px; }
    .logo-text { font-size: 17px; }
    .logo-text small { font-size: 11px; }
    .logo-icon { width: 38px; height: 38px; margin-right: 10px; }
}