.skip-link {
    position: fixed;
    z-index: 200;
    top: 8px;
    left: 50%;
    padding: 10px 15px;
    border-radius: 10px;
    color: var(--white);
    background: var(--terra-600);
    transform: translate(-50%, -150%);
}
.skip-link:focus { transform: translate(-50%, 0); }
.app-header {
    position: fixed;
    z-index: 50;
    top: 12px;
    right: 12px;
    left: 12px;
    height: var(--header-height);
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 0 18px;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 22px;
    color: var(--white);
    background: var(--forest-950);
    box-shadow: var(--shadow-float);
}
.app-header__menu { display: none; }
.app-brand {
    width: calc(var(--sidebar-width) - 18px);
    display: flex;
    align-items: center;
    gap: 11px;
    color: var(--white);
    text-decoration: none;
}
.app-brand__mark {
    width: 39px;
    height: 39px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 13px;
    color: var(--white);
    background: var(--terra-500);
}
.app-brand__mark svg { width: 21px; height: 21px; }
.app-brand strong { display: block; font-size: 14px; letter-spacing: .12em; }
.app-brand small { display: block; margin-top: 2px; color: #82968c; font-size: 9px; letter-spacing: .04em; }
.app-account { position: relative; margin-left: auto; }
.app-account__trigger {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 0;
    border: 0;
    color: var(--white);
    background: transparent;
}
.app-account__trigger > svg { width: 15px; color: #83958c; }
.app-avatar { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 50%; color: var(--forest-950); background: #e6ded1; font-size: 11px; font-weight: 800; }
.app-account__copy { min-width: 100px; text-align: left; }
.app-account__copy strong, .app-account__copy small { display: block; }
.app-account__copy strong { max-width: 170px; overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.app-account__copy small { margin-top: 2px; color: #82968c; font-size: 9px; }
.app-account__menu {
    position: absolute;
    top: 50px;
    right: 0;
    width: 190px;
    overflow: hidden;
    padding: 7px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    color: var(--ink-900);
    background: var(--paper);
    box-shadow: var(--shadow-float);
}
.app-account__menu a, .app-account__menu button { width: 100%; display: block; padding: 9px 10px; border: 0; border-radius: 8px; color: inherit; background: transparent; text-align: left; text-decoration: none; }
.app-account__menu a:hover, .app-account__menu button:hover { background: var(--cream-100); }
.app-sidebar {
    position: fixed;
    z-index: 35;
    top: 92px;
    bottom: 12px;
    left: 12px;
    width: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    overflow: auto;
    padding: 16px 12px;
    border-radius: 22px;
    color: #c9d3ce;
    background: var(--forest-950);
}
.app-nav__label { margin: 17px 12px 7px; color: #71857b; font-size: 9px; font-weight: 750; letter-spacing: .12em; text-transform: uppercase; }
.app-nav__label:first-child { margin-top: 2px; }
.app-nav__item {
    min-height: 43px;
    display: flex;
    align-items: center;
    gap: 11px;
    margin: 3px 0;
    padding: 0 12px;
    border-radius: 13px;
    color: #adbbb4;
    font-weight: 550;
    text-decoration: none;
}
.app-nav__item svg { width: 18px; height: 18px; flex: 0 0 auto; color: #71857b; }
.app-nav__item:hover { color: var(--white); background: rgba(255, 255, 255, .055); }
.app-nav__item.is-active { color: var(--forest-950); background: #efe8dc; font-weight: 720; }
.app-nav__item.is-active svg { color: var(--terra-600); }
.app-sidebar__status { display: flex; gap: 10px; margin-top: auto; padding: 16px 10px 4px; border-top: 1px solid rgba(255, 255, 255, .08); }
.app-sidebar__status strong, .app-sidebar__status small { display: block; }
.app-sidebar__status strong { color: #edf2ef; font-size: 11px; }
.app-sidebar__status small { margin-top: 3px; color: #72877c; font-size: 9px; }
.sync-dot { width: 9px; height: 9px; flex: 0 0 auto; margin-top: 4px; border-radius: 50%; background: #66c2a5; box-shadow: 0 0 0 4px rgba(102, 194, 165, .13); }
.sync-dot.is-error { background: #df786a; box-shadow: 0 0 0 4px rgba(223, 120, 106, .14); }
.app-main { min-height: 100vh; padding: 96px 30px 48px calc(var(--sidebar-width) + 40px); }
.app-content { max-width: 1600px; margin: 0 auto; }
.auth-main { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth-content { width: min(460px, 100%); }

@media (max-width: 1024px) {
    :root { --sidebar-width: 66px; }
    .app-brand { width: 54px; }
    .app-brand > span:last-child { display: none; }
    .app-sidebar { left: 8px; width: 66px; }
    .app-nav__label, .app-nav__item span, .app-sidebar__status { display: none; }
    .app-nav__item { justify-content: center; padding: 0; }
    .app-main { padding-right: 16px; padding-left: 92px; }
    .app-account__copy { display: none; }
}
@media (max-width: 760px) {
    .app-header { top: 8px; right: 8px; left: 8px; gap: 10px; padding: 0 10px; }
    .app-header__menu { display: grid; }
    .app-brand { width: 42px; }
    .app-brand__mark { width: 36px; height: 36px; }
    .app-account__trigger > svg { display: none; }
    .app-avatar { width: 36px; height: 36px; }
    .app-sidebar {
        z-index: 80;
        top: 8px;
        bottom: 8px;
        left: 8px;
        width: min(280px, calc(100vw - 40px));
        transform: translateX(calc(-100% - 16px));
        transition: transform .2s ease;
    }
    .app-sidebar.is-open { transform: translateX(0); }
    .app-sidebar .app-nav__label, .app-sidebar .app-nav__item span, .app-sidebar .app-sidebar__status { display: flex; }
    .app-sidebar .app-nav__label { display: block; }
    .app-sidebar .app-nav__item { justify-content: flex-start; padding: 0 12px; }
    .app-sidebar-backdrop { position: fixed; z-index: 70; inset: 0; background: rgba(17, 25, 22, .5); }
    .app-main { padding: 92px 12px 36px; }
}
@media (max-width: 590px) {
    .app-header { height: 60px; }
    .app-brand { display: none; }
    .app-main { padding-top: 80px; }
}
