:root {
      --main: #f4e9d0;
    --accent: #8b0000;        /* кроваво-красный */
    --second-accent: #d4af37; /* золотой */
}

html {
    scroll-behavior: smooth;
}

/* ===== СБРОС ===== */
* {
    font-family: 'Merriweather', serif;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* ===== СПИСКИ ===== */
ul {
    list-style: none;
}

/* ===== НАВИГАЦИЯ ===== */
nav {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 70px;

    background: var(--accent);

    z-index: 1000;
}

nav.show {
    top: 0;
}

/* ===== МЕНЮ ===== */
.topmenu {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
}

.topmenu a {
    text-decoration: none;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    height: 70px;
    padding: 0 24px;

    transition: .3s ease;
}

/* пункты */
.topmenu > li > a {
    color: var(--second-accent);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
    font-size: 15px;
}

/* hover */
.topmenu li a:hover {
    color: var(--accent);
    background: var(--second-accent);
}

/* элементы */
.topmenu > li {
    position: relative;
    display: flex;
    align-items: center;
}

/* разделители */
.topmenu > li:after {
    content: "";
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 30px;
    background: var(--second-accent);
    opacity: 0.6;
}

.topmenu > li:last-child:after {
    display: none;
}

/* ===== ВЫПАДАЮЩЕЕ ===== */
.submenu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-10px);

    width: 200px;

    background: #1e1e1e;
    border-radius: 6px;

    z-index: 9999;

    visibility: hidden;
    opacity: 0;

    transition: all 0.3s ease;
}

.topmenu > li:hover .submenu {
    visibility: visible;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* пункты */
.submenu li a {
    display: flex;
    justify-content: center;
    align-items: center;

    height: 36px;
    padding: 0 10px;

    font-size: 14px;
    color: var(--second-accent);

    background: #1e1e1e;

    transition: all 0.25s ease;
    border-bottom: 1px solid var(--accent);
}

/* hover */
.submenu li a:hover {
    background: var(--second-accent);
    color: var(--main);
    border: 1px solid var(--accent);
}

/* ===== АДАПТИВ ===== */
@media (max-width: 599px) {
    nav {
        flex-wrap: wrap;
        height: auto;
        padding: 10px 0;
    }

    .topmenu {
        position: static;
        transform: none;
        justify-content: center;
        flex-wrap: wrap;
        width: 100%;
    }

    .topmenu a {
        height: 50px;
        padding: 0 14px;
    }
}