.sidebar {
    width: 104px;
    height: 100dvh;
    border-right: 1px solid hsla(200, 31%, 94%, 1);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: width 0.25s ease;
    padding-top: env(safe-area-inset-top, 0px);
    padding-bottom: env(safe-area-inset-bottom, 0px);
}

/* ===== LOGO (collapsed) ===== */
.sidebar__logo {
    width: 67px;
    height: 54px;
    padding: 8px;
    box-sizing: border-box;
    margin-top: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sidebar__logo--expanded { display: none; }
.sidebar__logo--collapsed { width: 100%; height: 100%; object-fit: contain; }

/* ===== КНОПКИ (collapsed) ===== */
.sidebar__btn {
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    flex-shrink: 0;
}

.sidebar__btn img { display: block; }

.sidebar__btn--create { width: 52px; height: 52px; margin-top: 65px; }
.sidebar__btn--add    { width: 52px; height: 52px; margin-top: 16px; }

.sidebar__btn--file {
    width: 104px; height: 52px;
    padding: 8px 26px; box-sizing: border-box;
    margin-top: 27px;
}
.sidebar__btn--rubbish {
    width: 104px; height: 52px;
    padding: 8px 26px; box-sizing: border-box;
    margin-top: auto;
}
.sidebar__btn--hide {
    width: 104px; height: 52px;
    padding: 8px 26px; box-sizing: border-box;
    margin-top: auto;
    margin-bottom: 54px;
}

/* Скрыто в collapsed */
.sidebar__label    { display: none; }
.sidebar__btn-plus { display: none; }

/* ===== EXPANDED STATE ===== */
.sidebar--expanded {
    width: 313px;
    align-items: flex-start;
}

/* Logo */
.sidebar--expanded .sidebar__logo {
    width: 266px; height: 63px;
    padding: 0; margin-left: 24px;
}
.sidebar--expanded .sidebar__logo--collapsed { display: none; }
.sidebar--expanded .sidebar__logo--expanded {
    display: block; width: 100%; height: 100%; object-fit: contain;
}

/* Показываем метки */
.sidebar--expanded .sidebar__label { display: inline; }
.sidebar--expanded .sidebar__btn-plus { display: block; flex-shrink: 0; }

/* Кнопка Создать */
.sidebar--expanded .sidebar__btn--create {
    width: 265px;
    height: 52px;
    border-radius: 15px;
    padding: 16px 23px;
    box-sizing: border-box;
    justify-content: space-between;
    margin-left: 24px;
    margin-top: 65px;
    background: linear-gradient(88.98deg, var(--color-primary) 43.24%, var(--color-primary-hover) 99.13%);
}

.sidebar--expanded .sidebar__btn--create > img { display: none; }

.sidebar--expanded .sidebar__btn--create .sidebar__label {
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    line-height: 18px;
    font-family: "Wix Madefor Display", sans-serif;
    white-space: nowrap;
}

/* Кнопка Добавить */
.sidebar--expanded .sidebar__btn--add {
    width: 265px;
    height: 52px;
    border-radius: 15px;
    padding: 16px 23px;
    box-sizing: border-box;
    justify-content: space-between;
    margin-left: 24px;
    margin-top: 16px;
    background: linear-gradient(90deg, hsla(151, 68%, 60%, 1) 0%, hsla(151, 87%, 68%, 1) 100%);
}

.sidebar--expanded .sidebar__btn--add > img { display: none; }

.sidebar--expanded .sidebar__btn--add .sidebar__label {
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    line-height: 18px;
    font-family: "Wix Madefor Display", sans-serif;
    white-space: nowrap;
}

/* Кнопка Мероприятия */
.sidebar--expanded .sidebar__btn--file {
    width: 313px;
    height: 52px;
    padding: 16px 24px;
    box-sizing: border-box;
    justify-content: flex-start;
    gap: 8px;
    margin-left: 0;
    background: hsla(0, 0%, 100%, 1);
}

.sidebar--expanded .sidebar__btn--file .sidebar__label {
    font-size: 14px;
    font-weight: 500;
    font-family: "Wix Madefor Display", sans-serif;
    color: #1a1d2e;
    white-space: nowrap;
}

/* Текст в кнопке Мероприятия */
.sidebar--expanded .sidebar__btn--file .sidebar__label {
    font-size: 14px;
    font-weight: 500;
    font-family: "Wix Madefor Display", sans-serif;
    color: #9ea3b0;
    white-space: nowrap;
}

/* Корзина — такая же как Мероприятия */
.sidebar--expanded .sidebar__btn--rubbish {
    width: 313px;
    height: 52px;
    padding: 16px 24px;
    box-sizing: border-box;
    justify-content: flex-start;
    gap: 8px;
    margin-top: auto;
    background: hsla(0, 0%, 100%, 1);
}

.sidebar--expanded .sidebar__btn--rubbish .sidebar__label {
    display: inline;
    font-size: 14px;
    font-weight: 500;
    font-family: "Wix Madefor Display", sans-serif;
    color: #9ea3b0;
    white-space: nowrap;
}

/* Свернуть меню */
.sidebar--expanded .sidebar__btn--hide {
    width: 313px;
    height: 52px;
    padding: 16px 24px;
    box-sizing: border-box;
    justify-content: flex-start;
    gap: 8px;
    margin-top: auto;
    margin-bottom: 54px;
    background: hsla(0, 0%, 100%, 1);
}

.sidebar--expanded .sidebar__btn--hide .sidebar__label {
    display: inline;
    font-size: 14px;
    font-weight: 500;
    font-family: "Wix Madefor Display", sans-serif;
    color: #9ea3b0;
    white-space: nowrap;
}

.sidebar__btn {
    transition: all 0.2s ease;
}

.sidebar:not(.sidebar--expanded) .sidebar__btn:hover {
    filter: brightness(0.92);
}

.sidebar__btn:hover {
    background: transparent;
    transform: none;
}

.sidebar--expanded .sidebar__btn--create:hover,
.sidebar--expanded .sidebar__btn--add:hover {
    box-shadow: inset 0 100px 0 0 rgba(255,255,255,0.15),
                0 6px 16px rgba(111, 2, 255, 0.25);
}

.sidebar--expanded .sidebar__btn:hover .sidebar__label {
    color: var(--color-primary);
    transition: 0.2s;
}

.sidebar--expanded .sidebar__btn--file:hover,
.sidebar--expanded .sidebar__btn--rubbish:hover,
.sidebar--expanded .sidebar__btn--hide:hover {
    background: rgba(111, 2, 255, 0.06);
}

.sidebar--expanded .sidebar__btn--file:hover .sidebar__label,
.sidebar--expanded .sidebar__btn--rubbish:hover .sidebar__label,
.sidebar--expanded .sidebar__btn--hide:hover .sidebar__label {
    color: var(--color-primary);
}

.sidebar__btn img {
    transition: filter 0.2s ease;
}

.sidebar__btn:hover img {
    filter: brightness(0.8);
}

/* плавность и подготовка */
.sidebar--expanded .sidebar__btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.sidebar--expanded .sidebar__btn:hover {
    box-shadow: inset 0 100px 0 0 rgba(111, 2, 255, 0.12);
}

/* контейнер в шапке списка мероприятий */
.auth {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

/* общие стили кнопок */
.auth__btn {
    padding: 10px 18px;
    border-radius: 10px;
    border: none;

    font-size: 14px;
    font-weight: 600;

    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

/* Войти (серый) */
.auth__btn--login {
    background: #2f3136;
    color: #fff;
}

.auth__btn--login:hover {
    background: #3a3d42;
}

/* Регистрация (зелёная) */
.auth__btn--register {
    background: rgba(111, 2, 255, 0.25);
    color: #0f172a;
}

.auth__btn--register:hover {
    background: rgba(61, 7, 133, 0.25);
}

/* эффект нажатия */
.auth__btn:active {
    transform: scale(0.96);
}

.auth__btn::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.15);
    transform: scaleY(0);
    transform-origin: bottom;
    transition: transform 0.3s ease;
    z-index: -1;
}

.auth__btn:hover::before {
    transform: scaleY(1);
}

.auth__btn--login::before {
    background: rgba(255, 255, 255, 0.1);
}

.auth__btn--register::before {
    background: rgba(0, 0, 0, 0.08);
}

.auth__user {
    display: inline-flex;
    align-items: center;
    padding: 10px 14px;
    font-size: 14px;
    font-weight: 600;
    color: #1a1d2e;
}