:root {
    --bg: #eef0ee;
    --paper: #f8f8f5;
    --paper-2: #ffffff;
    --ink: #111312;
    --muted: #747b76;
    --line: rgba(17, 19, 18, 0.08);
    --line-strong: rgba(17, 19, 18, 0.14);
    --dark: #080a0a;
    --dark-2: #101313;
    --dark-3: #181d1c;
    --steel: #9aa3b2;
    --blue: #263c61;
    --violet: #4a3e6f;
    --ember: #b87835;
    --danger: #b42318;
    --radius: 14px;
    --radius-lg: 22px;
    --shadow: 0 26px 80px rgba(7, 9, 9, 0.22);
    --shadow-soft: 0 18px 46px rgba(7, 9, 9, 0.1);
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    overflow-y: auto;
    scrollbar-gutter: stable;
    background: var(--bg);
}

@supports not (scrollbar-gutter: stable) {
    html {
        overflow-y: scroll;
    }
}

body {
    min-height: 100%;
    margin: 0;
    color: var(--ink);
    background:
        linear-gradient(180deg, #e1e4e1 0, var(--bg) 360px),
        var(--bg);
    font-family: "Manrope", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    letter-spacing: 0;
    overflow-x: hidden;
}

button,
input,
select {
    font: inherit;
}

button {
    border: 0;
    cursor: pointer;
}

button:disabled {
    cursor: not-allowed;
    opacity: 0.58;
}

img {
    display: block;
    max-width: 100%;
}

.app-root {
    min-height: 100dvh;
}

.app-root:empty {
    background:
        linear-gradient(145deg, rgba(7, 8, 8, 0.96), rgba(20, 24, 24, 0.97)),
        repeating-linear-gradient(122deg, #242927 0 1px, #0e1110 1px 18px);
}

.boot-screen,
.login-screen {
    min-height: 100dvh;
    display: grid;
    place-items: center;
    padding: 24px;
}

.boot-screen {
    position: fixed;
    inset: 0;
    z-index: 1000;
    overflow: hidden;
    isolation: isolate;
    contain: layout paint;
    opacity: 1;
    transform: translateZ(0);
    transition: opacity 0.56s cubic-bezier(0.22, 1, 0.36, 1);
    background:
        radial-gradient(circle at 50% 44%, rgba(255, 255, 255, 0.16), transparent 18%),
        linear-gradient(145deg, rgba(7, 8, 8, 0.98), rgba(18, 22, 21, 0.98)),
        repeating-linear-gradient(122deg, #242927 0 1px, #0e1110 1px 18px);
}

.boot-screen::before,
.boot-screen::after {
    content: "";
    position: absolute;
    pointer-events: none;
}

.boot-screen::before {
    inset: -30%;
    background:
        conic-gradient(from 210deg at 50% 50%, transparent 0 21%, rgba(255, 255, 255, 0.16) 24%, transparent 30% 100%),
        radial-gradient(circle at 50% 50%, rgba(184, 120, 53, 0.2), transparent 25%);
    will-change: transform, opacity;
    animation: boot-light-sweep 1.34s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.boot-screen::after {
    inset: 0;
    background:
        linear-gradient(110deg, rgba(255, 255, 255, 0.14), transparent 20%, transparent 72%, rgba(255, 255, 255, 0.06)),
        linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.46));
}

.boot-logo-scene {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: min(420px, 72vw);
    min-height: 180px;
    perspective: 1200px;
}

.boot-logo-scene::before {
    content: "";
    position: absolute;
    width: min(360px, 64vw);
    height: 74px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    filter: blur(34px);
    transform: translateY(58px) scaleX(0.74);
    will-change: transform, opacity;
    animation: boot-shadow 1.34s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.boot-logo {
    position: relative;
    z-index: 1;
    width: min(330px, 68vw);
    height: auto;
    aspect-ratio: 8192 / 2705.3;
    filter: invert(1) drop-shadow(0 28px 48px rgba(0, 0, 0, 0.42));
    transform-origin: 50% 50%;
    transform: translate3d(0, 0, 0) scale(1);
    backface-visibility: hidden;
    will-change: transform, opacity;
    animation: boot-logo-arrive 1.58s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.boot-screen.boot-exit {
    pointer-events: none;
    opacity: 0;
    will-change: opacity;
}

body.auth-intro-active {
    overflow: hidden;
}

.auth-intro-screen {
    transition-duration: 0.2s;
    transition-timing-function: ease-out;
}

.auth-intro-screen.auth-intro-enter {
    opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.auth-intro-screen.auth-intro-enter-active {
    opacity: 1;
}

.auth-intro-screen.auth-intro-exit {
    pointer-events: none;
    opacity: 0;
    will-change: opacity;
}

.auth-intro-screen .boot-logo {
    animation: auth-intro-logo-story 5.6s linear both;
    will-change: transform, filter, opacity;
}

.auth-intro-screen .boot-logo-scene::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 3;
    width: 18px;
    aspect-ratio: 1;
    margin: -9px 0 0 -9px;
    border-radius: 50%;
    opacity: 0;
    pointer-events: none;
    background:
        radial-gradient(circle, #ffffff 0 18%, #fff2aa 35%, #f5aa38 65%, rgba(245, 170, 56, 0) 72%);
    box-shadow:
        0 0 16px 7px rgba(255, 239, 162, 0.9),
        0 0 50px 22px rgba(245, 170, 56, 0.5);
    animation: auth-intro-orb-flight 2.9s linear 1.3s both;
    will-change: transform, opacity;
}

.inline-loader {
    min-height: 320px;
    display: grid;
    place-items: center;
}

.inline-loader-logo {
    width: min(190px, 48vw);
    height: auto;
    aspect-ratio: 8192 / 2705.3;
    opacity: 0.26;
    animation: inline-logo-pulse 1.2s ease-in-out infinite;
}

.loader {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 3px solid rgba(17, 19, 18, 0.12);
    border-top-color: #111312;
    animation: spin 0.8s linear infinite;
}

.login-screen {
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(145deg, rgba(7, 8, 8, 0.96), rgba(20, 24, 24, 0.97)),
        repeating-linear-gradient(122deg, #242927 0 1px, #0e1110 1px 18px);
}

.login-screen::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(110deg, rgba(255, 255, 255, 0.1), transparent 22%, transparent 70%, rgba(255, 255, 255, 0.06)),
        linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.44));
    pointer-events: none;
}

.login-shell {
    position: relative;
    z-index: 1;
    width: min(980px, 100%);
    display: grid;
    justify-items: center;
    gap: 22px;
}

.password-shell {
    width: min(440px, 100%);
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
    transition:
        opacity 0.35s ease,
        transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: opacity, transform;
}

.password-shell.login-shell-exit {
    pointer-events: none;
    opacity: 0;
    transform: translate3d(0, -8px, 0) scale(0.985);
}

.login-logo {
    width: min(238px, 56vw);
    height: auto;
    aspect-ratio: 8192 / 2705.3;
    filter: invert(1);
    opacity: 0.98;
}

.login-logo-small {
    width: min(218px, 56vw);
}

.login-panel {
    width: 100%;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius-lg);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.055)),
        rgba(255, 255, 255, 0.045);
    box-shadow:
        0 26px 76px rgba(0, 0, 0, 0.32),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(24px) saturate(145%);
    -webkit-backdrop-filter: blur(24px) saturate(145%);
    animation: fade-up 0.32s ease both;
}

.password-panel {
    padding: 22px;
    background: rgba(248, 248, 245, 0.94);
}

.login-title {
    margin: 2px 0 14px;
    color: #ffffff;
    font-size: 22px;
    line-height: 1.14;
    font-weight: 800;
    text-align: center;
}

.password-panel .login-title {
    margin: 0;
    color: var(--ink);
    text-align: left;
}

.login-subtitle {
    margin: 6px 0 0;
    color: var(--muted);
    line-height: 1.45;
}

.identity-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.identity-card {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1 / 1.12;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    gap: 9px;
    align-content: stretch;
    padding: 11px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius-lg);
    color: #ffffff;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.055)),
        rgba(255, 255, 255, 0.045);
    text-align: left;
    box-shadow:
        0 18px 48px rgba(0, 0, 0, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(22px) saturate(140%);
    -webkit-backdrop-filter: blur(22px) saturate(140%);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.identity-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.14), transparent 32%, rgba(0, 0, 0, 0.28)),
        radial-gradient(circle at 70% 14%, rgba(155, 180, 206, 0.2), transparent 34%);
    opacity: 0.86;
    pointer-events: none;
}

.identity-card:hover,
.identity-card:focus-visible {
    border-color: rgba(255, 255, 255, 0.38);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.075)),
        rgba(255, 255, 255, 0.06);
    box-shadow:
        0 26px 60px rgba(0, 0, 0, 0.34),
        inset 0 1px 0 rgba(255, 255, 255, 0.22);
    transform: translateY(-3px);
    outline: 0;
}

.identity-avatar {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    min-height: 0;
    align-self: stretch;
    border-radius: calc(var(--radius-lg) - 8px);
    object-fit: contain;
    object-position: center;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 247, 243, 0.86));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.72),
        0 10px 24px rgba(0, 0, 0, 0.16);
}

.identity-name {
    position: relative;
    z-index: 2;
    min-width: 0;
    min-height: 32px;
    display: block;
    padding: 8px 8px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    color: #ffffff;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06)),
        rgba(7, 9, 9, 0.42);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(16px) saturate(140%);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    font-size: 11px;
    font-weight: 800;
    line-height: 1.22;
    text-align: center;
    overflow: visible;
    text-overflow: clip;
    white-space: nowrap;
}

.selected-user {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 22px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(17, 19, 18, 0.1);
}

.selected-avatar {
    width: 82px;
    height: 82px;
    flex: 0 0 82px;
    border-radius: var(--radius);
    object-fit: contain;
    object-position: center;
    background: #f7f7f3;
}

.back-button {
    min-height: 32px;
    margin-bottom: 16px;
    padding: 0;
    color: var(--muted);
    background: transparent;
    font-size: 14px;
    font-weight: 720;
}

.back-button:hover,
.back-button:focus-visible {
    color: var(--ink);
    outline: 0;
}

.field {
    display: grid;
    gap: 8px;
    margin-bottom: 16px;
}

.field span {
    color: #313635;
    font-size: 14px;
    font-weight: 720;
}

.input,
.select {
    width: 100%;
    height: 46px;
    border: 1px solid rgba(17, 19, 18, 0.14);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.82);
    color: var(--ink);
    outline: 0;
    padding: 0 13px;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.input:focus,
.select:focus {
    border-color: rgba(17, 19, 18, 0.34);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(17, 19, 18, 0.075);
}

.btn {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: var(--radius);
    padding: 0 16px;
    color: var(--ink);
    background: #e8ebe7;
    font-weight: 740;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.btn:hover,
.btn:focus-visible {
    transform: translateY(-1px);
    outline: 0;
}

.btn-primary {
    width: 100%;
    color: #ffffff;
    background: #111312;
    box-shadow: 0 14px 28px rgba(17, 19, 18, 0.24);
}

.btn-primary:hover,
.btn-primary:focus-visible {
    background: #000000;
}

.btn-soft {
    color: #171b1a;
    background: #e8ebe7;
}

.btn-danger {
    color: var(--danger);
    background: #f7e5e1;
}

.layout {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 18px 0 42px;
}

.topbar {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 14px;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius);
    color: #ffffff;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.07), transparent),
        var(--dark);
    box-shadow: 0 20px 52px rgba(7, 9, 9, 0.24);
}

.brand {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 13px;
}

.brand-logo {
    width: 136px;
    height: auto;
    aspect-ratio: 8192 / 2705.3;
    filter: invert(1);
}

.brand h1 {
    margin: 0;
    font-size: 18px;
    line-height: 1.12;
    font-weight: 800;
}

.brand p {
    margin: 3px 0 0;
    color: #aeb5b1;
    font-size: 13px;
}

.topbar-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.topbar-user {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 4px 10px 4px 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    font-size: 14px;
    font-weight: 720;
}

.user-avatar,
.avatar,
.avatar-fallback {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    border-radius: var(--radius);
    object-fit: cover;
    object-position: center;
    background: var(--paper);
}

.user-avatar {
    width: 52px;
    height: 52px;
    flex-basis: 52px;
}

.topbar-user .user-avatar {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
    object-fit: contain;
    background: #f7f7f3;
}

.avatar-fallback {
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, #202427, #6b5b45);
    font-weight: 800;
}

.identity-avatar.avatar-fallback {
    width: 100%;
    height: 100%;
    flex-basis: auto;
    font-size: 42px;
}

.selected-avatar.avatar-fallback {
    width: 82px;
    height: 82px;
    flex-basis: 82px;
}

.topbar .btn {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.topbar .btn:hover,
.topbar .btn:focus-visible {
    background: rgba(255, 255, 255, 0.16);
}

.topbar .music-toggle {
    width: 42px;
    min-width: 42px;
    height: 42px;
    padding: 0;
    display: inline-grid;
    place-items: center;
    border-radius: 14px;
}

.music-toggle svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.topbar .music-toggle.is-muted {
    color: rgba(255, 255, 255, 0.62);
}

.tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 14px;
    overflow-x: auto;
    padding: 4px;
    border: 1px solid rgba(17, 19, 18, 0.06);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.46);
}

.tab {
    min-width: max-content;
    min-height: 38px;
    border-radius: 11px;
    padding: 0 14px;
    color: var(--muted);
    background: transparent;
    font-weight: 730;
}

.tab:hover,
.tab:focus-visible {
    color: var(--ink);
    outline: 0;
}

.tab.active {
    color: #ffffff;
    background: var(--dark-2);
    box-shadow: 0 10px 24px rgba(7, 9, 9, 0.16);
}

.dashboard-hero {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    min-height: 250px;
    margin-bottom: 20px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--radius-lg);
    color: #ffffff;
    background:
        radial-gradient(circle at 22% 0%, rgba(82, 103, 124, 0.34), transparent 34%),
        radial-gradient(circle at 82% 12%, rgba(91, 76, 110, 0.24), transparent 32%),
        linear-gradient(180deg, rgba(7, 9, 10, 0.88) 0%, rgba(23, 34, 40, 0.76) 52%, rgba(13, 18, 17, 0.84) 100%),
        rgba(8, 10, 10, 0.72);
    background-size: 260% 260%;
    box-shadow:
        0 34px 90px rgba(7, 9, 9, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        inset 0 -1px 0 rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(28px) saturate(150%);
    -webkit-backdrop-filter: blur(28px) saturate(150%);
    animation: gradient-shift 12s ease-in-out infinite;
}

.dashboard-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.18), transparent 20%, transparent 78%, rgba(255, 255, 255, 0.08)),
        linear-gradient(180deg, rgba(255, 255, 255, 0.14), transparent 42%, rgba(0, 0, 0, 0.26));
    z-index: 0;
    pointer-events: none;
}

.dashboard-hero::after {
    content: "";
    position: absolute;
    inset: 1px;
    border-radius: calc(var(--radius-lg) - 1px);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.16), transparent 22%, transparent 78%, rgba(255, 255, 255, 0.06));
    mix-blend-mode: screen;
    opacity: 0.74;
    z-index: 3;
    pointer-events: none;
}

.income-mood-rain {
    position: absolute;
    inset: 0;
    z-index: 1;
    overflow: hidden;
    contain: layout paint;
    pointer-events: none;
}

.income-mood-emoji {
    position: absolute;
    top: -12%;
    left: var(--mood-x);
    display: block;
    font-size: var(--mood-size);
    line-height: 1;
    opacity: 0;
    filter: saturate(0.9);
    text-shadow: 0 8px 18px rgba(0, 0, 0, 0.26);
    transform: translate3d(0, -24px, 0) rotate(0deg);
    animation: income-mood-fall var(--mood-duration) linear var(--mood-delay) infinite;
    will-change: top, transform, opacity;
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    gap: 20px;
}

.hero-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.hero-kicker {
    margin: 0 0 8px;
    color: #bfc6d2;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.hero-head h2 {
    margin: 0;
    font-size: 30px;
    line-height: 1.08;
    font-weight: 800;
}

.hero-note {
    margin: 8px 0 0;
    color: #c4cbd6;
    font-size: 13px;
    line-height: 1.4;
}

.hero-action {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-action:hover,
.hero-action:focus-visible {
    background: rgba(255, 255, 255, 0.16);
}

.kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.kpi-card {
    min-height: 112px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--radius);
    color: #ffffff;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.075)),
        rgba(255, 255, 255, 0.045);
    box-shadow:
        0 18px 42px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(22px) saturate(140%);
    -webkit-backdrop-filter: blur(22px) saturate(140%);
    animation: fade-up 0.24s ease both;
}

.kpi-card:nth-child(2) {
    animation-delay: 0.03s;
}

.kpi-card:nth-child(3) {
    animation-delay: 0.06s;
}

.kpi-card:nth-child(4) {
    animation-delay: 0.09s;
}

.kpi-card-negative {
    border-color: rgba(255, 145, 132, 0.42);
    background:
        linear-gradient(180deg, rgba(176, 65, 54, 0.3), rgba(176, 65, 54, 0.1)),
        rgba(255, 255, 255, 0.045);
}

.kpi-card-negative .kpi-value {
    color: #ffd0ca;
}

.kpi-label {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #c4cbd6;
    font-size: 13px;
    font-weight: 650;
}

.kpi-value {
    margin-top: 18px;
    font-size: 29px;
    line-height: 1;
    font-weight: 800;
}

.login-income-pending {
    visibility: hidden;
}

.login-income-counting {
    min-width: 7.5ch;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    will-change: contents, filter, transform;
}

.login-income-complete {
    animation: login-income-settle 0.42s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.info-hint {
    position: relative;
    z-index: 5;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    outline: 0;
}

.info-hint-icon {
    width: 17px;
    height: 17px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.86);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.06)),
        rgba(255, 255, 255, 0.08);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
    font-size: 11px;
    line-height: 1;
    font-weight: 900;
}

.info-hint-tooltip {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 10px);
    width: max-content;
    max-width: min(280px, calc(100vw - 48px));
    padding: 9px 11px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 12px;
    color: #ffffff;
    background: rgba(7, 9, 9, 0.78);
    box-shadow: 0 18px 38px rgba(0, 0, 0, 0.26);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    font-size: 12px;
    font-weight: 720;
    line-height: 1.35;
    text-transform: none;
    white-space: normal;
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, 6px) scale(0.96);
    transform-origin: 50% 100%;
    transition: opacity 0.16s ease, transform 0.16s ease;
}

.info-hint:hover .info-hint-tooltip,
.info-hint:focus-visible .info-hint-tooltip {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
}

.revenue-chart-panel {
    position: relative;
    overflow: hidden;
    --chart-x-pad: 16px;
    min-height: 248px;
    padding: 16px 16px 14px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.055)),
        rgba(255, 255, 255, 0.045);
    box-shadow:
        0 22px 52px rgba(0, 0, 0, 0.14),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(24px) saturate(145%);
    -webkit-backdrop-filter: blur(24px) saturate(145%);
    animation: fade-up 0.3s ease both;
    animation-delay: 0.12s;
}

.revenue-chart-panel::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.16), transparent 34%, rgba(255, 255, 255, 0.055)),
        radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.12), transparent 42%);
    opacity: 0.74;
    pointer-events: none;
}

.revenue-chart-panel::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.018)),
        radial-gradient(circle at 72% 35%, rgba(155, 180, 206, 0.16), transparent 34%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 -34px 70px rgba(255, 255, 255, 0.035);
    pointer-events: none;
}

.chart-head,
.chart-stage,
.chart-points {
    position: relative;
    z-index: 2;
}

.chart-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 10px;
}

.chart-label,
.chart-record-label {
    color: rgba(235, 240, 245, 0.72);
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.chart-total {
    margin-top: 6px;
    font-size: 24px;
    line-height: 1;
    font-weight: 850;
}

.chart-peak {
    min-width: 116px;
    text-align: right;
}

.chart-record-label {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
}

.record-trophy {
    width: 17px;
    height: 17px;
    display: inline-flex;
    color: #f1c77d;
    filter: drop-shadow(0 0 10px rgba(241, 199, 125, 0.28));
    transform-origin: 50% 70%;
}

.record-trophy svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.chart-peak strong {
    display: block;
    margin-top: 6px;
    font-size: 15px;
    white-space: nowrap;
}

.chart-stage {
    position: relative;
    height: 182px;
    display: grid;
    grid-template-rows: minmax(0, 1fr) 20px;
    isolation: isolate;
}

.chart-plot {
    position: relative;
    min-height: 0;
}

.revenue-chart,
.chart-stage-points,
.chart-points {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.revenue-chart {
    overflow: hidden;
}

.chart-stage-points {
    z-index: 2;
    pointer-events: none;
}

.chart-date-axis {
    position: relative;
    z-index: 2;
    height: 20px;
    pointer-events: none;
}

.chart-date-tick {
    position: absolute;
    bottom: 0;
    color: rgba(235, 240, 245, 0.48);
    font-size: 10px;
    font-weight: 780;
    line-height: 1;
    letter-spacing: 0;
    white-space: nowrap;
    transform: translateX(-50%);
}

.chart-date-tick-start {
    transform: translateX(0);
}

.chart-date-tick-end {
    transform: translateX(-100%);
}

.chart-plot-base {
    display: none;
}

.chart-grid-line {
    fill: none;
    stroke: rgba(255, 255, 255, 0.1);
    stroke-width: 0.35;
    vector-effect: non-scaling-stroke;
}

.chart-area {
    display: none;
}

.chart-line-track,
.chart-line {
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    vector-effect: non-scaling-stroke;
}

.chart-line-track {
    stroke: rgba(242, 248, 249, 0.46);
    stroke-width: 3.45;
    filter: drop-shadow(0 9px 18px rgba(0, 0, 0, 0.22));
}

.chart-line {
    stroke: url("#revenue-line");
    stroke-width: 2.25;
    filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.22));
}

.chart-points {
    position: absolute;
    top: 0;
    right: var(--chart-x-pad);
    bottom: 0;
    left: var(--chart-x-pad);
    width: auto;
    height: auto;
    pointer-events: none;
    overflow: visible;
}

.chart-point-target {
    position: absolute;
    top: 0;
    bottom: 0;
    z-index: 2;
    display: block;
    min-width: 0;
    padding: 0;
    border-radius: 0;
    background: transparent;
    transform: translateZ(0);
    pointer-events: auto;
}

.chart-point-target::before {
    content: "";
    position: absolute;
    left: var(--dot-left, 50%);
    top: 22px;
    bottom: 28px;
    width: 1px;
    border-radius: 999px;
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.22), transparent);
    opacity: 0;
    transform: translateX(-50%);
    transition: opacity 0.18s ease;
}

.chart-point-target:hover::before,
.chart-point-target:focus-visible::before {
    opacity: 1;
}

.chart-visual-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 8px;
    height: 8px;
    border: 2px solid rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    background: #9bb4ce;
    box-shadow: 0 0 0 5px rgba(155, 180, 206, 0), 0 8px 16px rgba(0, 0, 0, 0.18);
    opacity: 0;
    transform: translate(-50%, -50%) scale(1);
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
    animation: chart-dot-in 0.28s ease forwards;
    animation-delay: var(--point-delay, 360ms);
}

.chart-visual-dot.active {
    background: #f1c77d;
    box-shadow: 0 0 0 7px rgba(241, 199, 125, 0.18), 0 12px 24px rgba(0, 0, 0, 0.26);
    transform: translate(-50%, -50%) scale(1.24);
}

.chart-point-target:focus-visible {
    outline: 0;
}

.chart-tooltip {
    position: absolute;
    left: var(--dot-left, 50%);
    top: calc(var(--point-y, 50%) - 12px);
    min-width: 136px;
    display: grid;
    gap: 3px;
    padding: 9px 10px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 12px;
    color: #ffffff;
    background: rgba(7, 9, 9, 0.76);
    box-shadow: 0 18px 38px rgba(0, 0, 0, 0.26);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    opacity: 0;
    transform: translate(-50%, calc(-100% + 6px)) scale(0.96);
    transform-origin: 50% 100%;
    pointer-events: none;
    transition: opacity 0.16s ease, transform 0.16s ease;
}

.chart-tooltip span,
.chart-tooltip em {
    color: rgba(235, 240, 245, 0.72);
    font-size: 11px;
    font-style: normal;
    font-weight: 700;
}

.chart-tooltip strong {
    font-size: 14px;
    white-space: nowrap;
}

.chart-point-target:hover .chart-tooltip,
.chart-point-target:focus-visible .chart-tooltip {
    opacity: 1;
    transform: translate(-50%, -100%) scale(1);
}

.chart-point-target.edge-start .chart-tooltip {
    left: 0;
    transform: translate(0, calc(-100% + 6px)) scale(0.96);
    transform-origin: 0 100%;
}

.chart-point-target.edge-start:hover .chart-tooltip,
.chart-point-target.edge-start:focus-visible .chart-tooltip {
    transform: translate(0, -100%) scale(1);
}

.chart-point-target.edge-end .chart-tooltip {
    left: auto;
    right: 0;
    transform: translate(0, calc(-100% + 6px)) scale(0.96);
    transform-origin: 100% 100%;
}

.chart-point-target.edge-end:hover .chart-tooltip,
.chart-point-target.edge-end:focus-visible .chart-tooltip {
    transform: translate(0, -100%) scale(1);
}

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 18px 0 14px;
}

.app-section {
    contain: layout style;
}

.section-head h2 {
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    flex-wrap: wrap;
    font-size: 21px;
    line-height: 1.18;
    font-weight: 800;
}

.section-count-badge {
    min-height: 24px;
    display: inline-flex;
    align-items: center;
    padding: 0 9px;
    border: 1px solid rgba(17, 19, 18, 0.08);
    border-radius: 999px;
    color: #313635;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(244, 246, 243, 0.72)),
        rgba(255, 255, 255, 0.66);
    box-shadow:
        0 10px 24px rgba(7, 9, 9, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.72);
    font-size: 12px;
    line-height: 1;
    font-weight: 820;
    white-space: nowrap;
}

.section-tools {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.sort-select {
    appearance: none;
    -webkit-appearance: none;
    width: max-content;
    min-width: 184px;
    height: 38px;
    border: 1px solid rgba(17, 19, 18, 0.1);
    border-radius: var(--radius);
    color: #171b1a;
    background:
        url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 2.25L6 6.25L10 2.25' stroke='%23232728' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 14px center / 12px 8px no-repeat,
        linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(244, 246, 243, 0.82)),
        #ffffff;
    box-shadow: 0 12px 30px rgba(7, 9, 9, 0.06);
    outline: 0;
    padding: 0 42px 0 13px;
    font-size: 13px;
    font-weight: 760;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.sort-select:hover,
.sort-select:focus {
    border-color: rgba(17, 19, 18, 0.22);
    box-shadow: 0 16px 36px rgba(7, 9, 9, 0.1);
    transform: translateY(-1px);
}

.view-toggle {
    height: 38px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px;
    border: 1px solid rgba(17, 19, 18, 0.1);
    border-radius: var(--radius);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(244, 246, 243, 0.78)),
        #ffffff;
    box-shadow: 0 12px 30px rgba(7, 9, 9, 0.06);
}

.view-button {
    width: 32px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    color: #59605d;
    background: transparent;
    transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.view-button:hover,
.view-button:focus-visible {
    color: #111312;
    outline: 0;
    transform: translateY(-1px);
}

.view-button.active {
    color: #ffffff;
    background: #111312;
    box-shadow: 0 8px 18px rgba(7, 9, 9, 0.18);
}

.view-icon {
    position: relative;
    width: 16px;
    height: 16px;
    display: block;
}

.view-icon-grid::before {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 5px;
    height: 5px;
    border-radius: 2px;
    background: currentColor;
    box-shadow: 7px 0 0 currentColor, 0 7px 0 currentColor, 7px 7px 0 currentColor;
}

.view-icon-list::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 2px;
    width: 12px;
    height: 2px;
    border-radius: 999px;
    background: currentColor;
    box-shadow: 0 5px 0 currentColor, 0 10px 0 currentColor;
}

.apps-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    align-items: start;
}

.apps-list {
    grid-template-columns: 1fr;
    gap: 8px;
}

[data-app-section-body] {
    transition: min-height 0.24s ease;
}

.panel,
.app-card,
.payout-card {
    border: 1px solid rgba(17, 19, 18, 0.07);
    border-radius: var(--radius);
    background: rgba(248, 248, 245, 0.9);
    box-shadow: var(--shadow-soft);
}

.app-card {
    position: relative;
    z-index: 0;
    overflow: visible;
    min-height: 176px;
    padding: 12px;
    contain: layout;
    animation: card-sort-in 0.26s cubic-bezier(0.2, 0.8, 0.2, 1) both;
    animation-delay: var(--card-delay, 0ms);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.app-card-static {
    animation: none;
}

.app-card:hover {
    z-index: 20;
    border-color: rgba(17, 19, 18, 0.18);
    box-shadow: 0 22px 52px rgba(7, 9, 9, 0.14);
    transform: translateY(-2px);
}

.app-card:focus-within {
    z-index: 20;
}

.app-card-link {
    cursor: pointer;
}

.app-card-link:focus-visible {
    outline: 0;
    border-color: rgba(17, 19, 18, 0.28);
    box-shadow:
        0 22px 52px rgba(7, 9, 9, 0.14),
        0 0 0 4px rgba(17, 19, 18, 0.08);
}

.apps-list .app-card {
    min-height: 94px;
    display: grid;
    grid-template-columns: minmax(220px, 0.85fr) minmax(440px, 1.15fr);
    align-items: center;
    gap: 18px;
    padding: 14px 16px;
}

.apps-grid-historical {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.app-card-historical {
    min-height: 124px;
    padding: 12px;
}

.app-card-historical .app-card-head {
    margin-bottom: 8px;
}

.apps-list.apps-grid-historical .app-card {
    min-height: 76px;
    grid-template-columns: minmax(220px, 1fr) minmax(140px, 0.38fr);
    gap: 12px;
    padding: 12px 16px;
}

.apps-list .app-card-head {
    margin-bottom: 0;
}

.apps-list .stat-list {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
}

.apps-list .stat-row {
    min-height: 46px;
    display: grid;
    align-content: center;
    justify-content: stretch;
    gap: 3px;
    padding: 7px 10px;
    border: 1px solid rgba(17, 19, 18, 0.07);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.44);
}

.apps-list .stat-row strong {
    text-align: left;
}

.app-card-rank {
    border-style: dashed;
    border-width: 2px;
}

.app-card-rank::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    border-radius: var(--radius);
    opacity: 0.76;
    pointer-events: none;
}

.app-card > * {
    position: relative;
    z-index: 1;
}

.app-card-rank-1 {
    border-color: rgba(218, 161, 38, 0.9);
    background:
        linear-gradient(180deg, rgba(255, 248, 219, 0.74), rgba(248, 248, 245, 0.92)),
        rgba(248, 248, 245, 0.94);
    box-shadow: 0 20px 52px rgba(218, 161, 38, 0.2), var(--shadow-soft);
}

.app-card-rank-1::before {
    background: linear-gradient(135deg, rgba(255, 213, 86, 0.42), transparent 40%, rgba(198, 138, 18, 0.22));
    filter: blur(10px);
}

.app-card-rank-2 {
    border-color: rgba(77, 111, 143, 0.94);
    background:
        linear-gradient(180deg, rgba(231, 239, 247, 0.9), rgba(248, 248, 245, 0.92)),
        rgba(248, 248, 245, 0.94);
    box-shadow: 0 20px 52px rgba(77, 111, 143, 0.22), var(--shadow-soft);
}

.app-card-rank-2::before {
    background: linear-gradient(135deg, rgba(144, 172, 198, 0.4), transparent 39%, rgba(55, 82, 110, 0.22));
    filter: blur(10px);
}

.app-card-rank-3 {
    border-color: rgba(154, 74, 42, 0.92);
    background:
        linear-gradient(180deg, rgba(255, 231, 215, 0.72), rgba(248, 248, 245, 0.92)),
        rgba(248, 248, 245, 0.94);
    box-shadow: 0 20px 52px rgba(154, 74, 42, 0.2), var(--shadow-soft);
}

.app-card-rank-3::before {
    background: linear-gradient(135deg, rgba(198, 91, 49, 0.34), transparent 42%, rgba(103, 45, 25, 0.24));
    filter: blur(10px);
}

.app-card-head {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    margin-bottom: 12px;
}

.app-avatar-wrap {
    position: relative;
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
}

.rank-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    z-index: 2;
    width: 23px;
    height: 23px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.78);
    border-radius: 50%;
    font-size: 11px;
    line-height: 1;
    font-weight: 900;
    box-shadow: 0 9px 18px rgba(7, 9, 9, 0.22);
}

.rank-badge-1 {
    width: 23px;
    height: 23px;
    color: #211707;
    background: linear-gradient(145deg, #ffe59b, #c88920 58%, #7a4b10);
}

.rank-badge-2 {
    color: #20262a;
    background: linear-gradient(145deg, #f6f8f8, #aeb7bf 60%, #68727b);
}

.rank-badge-3 {
    color: #241407;
    background: linear-gradient(145deg, #f0b37a, #b86c36 58%, #6e3a1d);
}

.store-icon-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    z-index: 2;
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.82);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 9px 18px rgba(7, 9, 9, 0.2);
    pointer-events: none;
}

.store-icon-badge img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.store-icon-badge-rustore {
    overflow: hidden;
    border-width: 1.5px;
    background: #0a83f6;
}

.store-icon-badge-rustore img {
    object-fit: cover;
}

.store-icon-badge-google_play {
    overflow: hidden;
    background: #ffffff;
}

.store-icon-badge-google_play img {
    width: 76%;
    height: 76%;
    object-fit: contain;
}

.app-title {
    min-width: 0;
    flex: 1;
}

.app-title h3 {
    margin: 0;
    overflow: hidden;
    max-width: 100%;
    font-size: 15px;
    line-height: 1.24;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-title p {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 13px;
}

.platform-badge,
.share-badge {
    min-height: 20px;
    display: inline-flex;
    align-items: center;
    width: max-content;
    border-radius: 999px;
    padding: 0 7px;
    color: #232728;
    background: #ecefeb;
    font-size: 11px;
    font-weight: 780;
    white-space: nowrap;
}

.share-badge {
    color: #f7f7f3;
    background: #1b1f20;
}

.owner-chip {
    min-height: 22px;
    max-width: 136px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    overflow: hidden;
    border: 1px solid rgba(17, 19, 18, 0.08);
    border-radius: 999px;
    padding: 2px 8px 2px 3px;
    color: rgba(17, 19, 18, 0.78);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.42)),
        rgba(238, 240, 238, 0.7);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.74),
        0 8px 18px rgba(7, 9, 9, 0.06);
    font-size: 11px;
    font-weight: 780;
    white-space: nowrap;
}

.owner-chip span:last-child {
    overflow: hidden;
    min-width: 0;
    text-overflow: ellipsis;
}

.owner-chip-avatar {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
    background: #f7f7f3;
    box-shadow: 0 0 0 1px rgba(17, 19, 18, 0.08);
}

.owner-chip-fallback {
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, #202427, #7b6a4d);
    font-size: 8px;
    font-weight: 900;
}

.platform-google_play {
    color: #143d28;
    background: #dff3e7;
}

.platform-app_store {
    color: #663145;
    background: #f7dfe9;
}

.platform-rustore {
    color: #17375f;
    background: #dfeaf8;
}

.stat-list {
    display: grid;
    gap: 5px;
}

.stat-row {
    min-height: 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: var(--muted);
    border-bottom: 1px solid rgba(17, 19, 18, 0.08);
    font-size: 13px;
}

.stat-row > span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.stat-row .info-hint-icon {
    width: 16px;
    height: 16px;
    border-color: rgba(17, 19, 18, 0.12);
    color: rgba(17, 19, 18, 0.68);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.48)),
        rgba(17, 19, 18, 0.04);
    font-size: 10px;
}

.stat-row:last-child {
    border-bottom: 0;
}

.stat-row strong {
    color: var(--ink);
    text-align: right;
    white-space: nowrap;
}

.app-card-historical .stat-list {
    margin-top: 7px;
}

.stat-list-historical {
    gap: 0;
}

.stat-list-historical .stat-row {
    min-height: 32px;
    padding: 0;
    border-bottom: 0;
    color: rgba(17, 19, 18, 0.58);
    font-weight: 760;
}

.stat-list-historical .stat-row span {
    font-size: 13px;
}

.stat-list-historical .stat-row strong {
    font-size: 17px;
    font-weight: 880;
}

.apps-list .stat-list.stat-list-historical {
    grid-template-columns: minmax(0, 1fr);
}

.apps-list .app-card-historical .stat-list {
    margin-top: 0;
}

.apps-list .stat-list-historical .stat-row {
    min-height: 34px;
}

.panel {
    padding: 18px;
    animation: fade-up 0.24s ease both;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.form-grid .wide {
    grid-column: 1 / -1;
}

.file-input {
    min-height: 46px;
    padding: 10px 12px;
}

.admin-list {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.admin-row,
.payout-card {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(120px, 0.75fr) minmax(180px, 1fr);
    align-items: center;
    gap: 14px;
    padding: 14px;
}

.admin-row {
    grid-template-columns: minmax(0, 1.35fr) minmax(110px, 0.45fr) minmax(190px, 1fr) max-content;
    border: 1px solid rgba(17, 19, 18, 0.07);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.72);
}

.admin-row > .btn {
    justify-self: end;
}

.admin-row-edit {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: end;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.68)),
        rgba(255, 255, 255, 0.72);
    box-shadow: 0 18px 42px rgba(7, 9, 9, 0.08);
    animation: fade-up 0.18s ease both;
}

.admin-row-edit .field {
    margin-bottom: 0;
}

.admin-edit-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.admin-edit-actions .btn {
    width: auto;
    min-width: 116px;
}

.admin-row-title,
.payout-name {
    min-width: 0;
    font-weight: 800;
    overflow-wrap: anywhere;
}

.admin-meta,
.payout-meta {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
}

.share-pills {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.pill {
    min-height: 26px;
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0 9px;
    color: #6f4a1d;
    background: #f8eddf;
    font-size: 12px;
    font-weight: 780;
}

.payouts-grid {
    display: grid;
    gap: 12px;
}

.payout-card {
    grid-template-columns: minmax(0, 1fr) minmax(140px, auto) minmax(140px, 160px) minmax(118px, auto);
}

.payout-amount {
    display: grid;
    gap: 6px;
}

.payout-amount span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 720;
}

.payout-amount .input {
    height: 40px;
}

.payout-card-overpaid {
    border-color: rgba(176, 65, 54, 0.22);
    background:
        linear-gradient(135deg, rgba(255, 247, 245, 0.96), rgba(248, 248, 245, 0.9));
}

.payout-balance {
    display: grid;
    gap: 3px;
}

.payout-balance-negative strong,
.payout-overpayment {
    color: #a13d34;
}

.payout-overpayment {
    width: max-content;
    max-width: 100%;
    padding: 3px 7px;
    border-radius: 999px;
    background: rgba(176, 65, 54, 0.1);
    font-size: 11px;
    font-weight: 780;
    line-height: 1.35;
}

.payout-adjustment {
    width: max-content;
    max-width: 100%;
    margin-top: 7px;
    color: #36714d;
    font-size: 12px;
    font-weight: 740;
    line-height: 1.4;
}

.payout-adjustment span {
    color: var(--muted);
    font-weight: 650;
}

.payout-adjustment-negative {
    color: #a13d34;
}

.payout-journal {
    margin-top: 24px;
}

.payout-journal .section-head {
    margin-bottom: 14px;
}

.payout-journal-scroll {
    overflow-x: auto;
    border: 1px solid rgba(17, 19, 18, 0.07);
    border-radius: calc(var(--radius) - 4px);
    background: rgba(255, 255, 255, 0.62);
}

.payout-journal-table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
    font-size: 13px;
}

.payout-journal-table th,
.payout-journal-table td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(17, 19, 18, 0.07);
    text-align: left;
    vertical-align: middle;
}

.payout-journal-table th {
    color: var(--muted);
    background: rgba(248, 248, 245, 0.88);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.payout-journal-table tbody tr:last-child td {
    border-bottom: 0;
}

.payout-journal-table tbody tr:hover {
    background: rgba(17, 19, 18, 0.025);
}

.payout-operation-id {
    display: block;
    max-width: 190px;
    overflow: hidden;
    color: #505957;
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.payout-journal-amount {
    font-weight: 800;
    white-space: nowrap;
}

.payout-journal-empty {
    padding: 18px;
}

.empty-state {
    padding: 26px;
    border: 1px dashed rgba(17, 19, 18, 0.22);
    border-radius: var(--radius);
    color: var(--muted);
    background: rgba(255, 255, 255, 0.58);
    text-align: center;
}

.toast {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 20;
    max-width: min(360px, calc(100% - 40px));
    padding: 13px 16px;
    border-radius: var(--radius);
    color: #ffffff;
    background: var(--dark);
    box-shadow: var(--shadow);
    opacity: 0;
    transform: translateY(12px);
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

.toast.error {
    background: var(--danger);
}

.date-switcher {
    position: fixed;
    top: 50%;
    left: 0;
    z-index: 35;
    transform: translateY(-50%);
}

.date-rail-button {
    width: 38px;
    min-height: 112px;
    display: grid;
    place-items: center;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-left: 0;
    border-radius: 0 13px 13px 0;
    color: #ffffff;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.05)),
        rgba(8, 10, 10, 0.88);
    box-shadow: 0 16px 38px rgba(7, 9, 9, 0.24);
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    font-size: 12px;
    font-weight: 860;
    line-height: 1;
    transition: width 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.date-rail-button::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 3px;
    opacity: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.94), transparent);
    transform: translateX(-100%);
    transition: opacity 0.12s ease;
}

.is-date-loading .date-rail-button::after {
    opacity: 1;
    animation: date-rail-loading 0.76s ease-in-out infinite;
}

.date-rail-button span {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
}

.date-rail-button:hover,
.date-rail-button:focus-visible,
.date-switcher.open .date-rail-button {
    width: 42px;
    outline: 0;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.07)),
        rgba(8, 10, 10, 0.94);
}

.date-drawer {
    position: absolute;
    top: 50%;
    left: 48px;
    width: 184px;
    display: grid;
    gap: 6px;
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--radius);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.07)),
        rgba(8, 10, 10, 0.84);
    box-shadow: 0 28px 70px rgba(7, 9, 9, 0.3);
    backdrop-filter: blur(24px) saturate(145%);
    -webkit-backdrop-filter: blur(24px) saturate(145%);
    opacity: 0;
    pointer-events: none;
    transform: translate(-14px, -50%) scale(0.96);
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.date-switcher.open .date-drawer {
    opacity: 1;
    pointer-events: auto;
    transform: translate(0, -50%) scale(1);
}

.date-option {
    min-height: 44px;
    display: grid;
    align-content: center;
    justify-items: start;
    gap: 3px;
    border-radius: 10px;
    padding: 7px 10px;
    color: rgba(255, 255, 255, 0.74);
    background: transparent;
    text-align: left;
    transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.date-option span {
    font-size: 13px;
    font-weight: 820;
    line-height: 1.12;
}

.date-option small {
    color: rgba(255, 255, 255, 0.46);
    font-size: 10px;
    font-weight: 760;
    line-height: 1;
}

.date-option:hover,
.date-option:focus-visible {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
    outline: 0;
    transform: translateX(2px);
}

.date-option.active {
    color: #111312;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(7, 9, 9, 0.18);
}

.date-option.active small {
    color: rgba(17, 19, 18, 0.56);
}

#content {
    transform-origin: center top;
}

.vt-section-head-own {
    contain: layout paint;
}

.vt-section-head-partner {
    contain: layout paint;
}

.content-swap-static .kpi-card,
.content-swap-static .revenue-chart-panel,
.content-swap-static .panel,
.content-swap-static .app-card {
    animation: none;
}

.content-swap-static .chart-point-target::before {
    animation: none;
    opacity: 1;
}

.dashboard-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 14px;
}

.dashboard-add-app,
.compact-primary {
    width: auto;
    min-width: 168px;
}

.kpi-value-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
}

.kpi-value-row .kpi-value {
    margin-top: 0;
}

.stat-value {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 7px;
    min-width: 0;
}

.trend-indicator {
    position: relative;
    z-index: 5;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 50%;
    outline: 0;
}

.trend-circle {
    width: 22px;
    height: 22px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #ffffff;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.34),
        0 7px 16px rgba(7, 9, 9, 0.18);
    font-size: 13px;
    line-height: 1;
    font-weight: 900;
}

.trend-up .trend-circle {
    background: linear-gradient(145deg, #39c781, #15834f);
}

.trend-down .trend-circle {
    background: linear-gradient(145deg, #f06b61, #bb2f2a);
}

.trend-steady .trend-circle {
    background: linear-gradient(145deg, #a4aaa7, #6d7571);
}

.trend-tooltip {
    position: absolute;
    z-index: 30;
    right: -6px;
    bottom: calc(100% + 9px);
    width: max-content;
    max-width: min(280px, calc(100vw - 40px));
    padding: 8px 10px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 11px;
    color: #ffffff;
    background: rgba(7, 9, 9, 0.88);
    box-shadow: 0 16px 34px rgba(7, 9, 9, 0.24);
    backdrop-filter: blur(16px) saturate(140%);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    font-size: 11px;
    font-weight: 720;
    line-height: 1.35;
    white-space: normal;
    opacity: 0;
    pointer-events: none;
    transform: translateY(5px) scale(0.97);
    transform-origin: 100% 100%;
    transition: opacity 0.16s ease, transform 0.16s ease;
}

.trend-indicator:hover .trend-tooltip,
.trend-indicator:focus-visible .trend-tooltip {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.page-section-head {
    margin-bottom: 14px;
}

.page-section-head h2 {
    margin-bottom: 5px;
}

.section-description {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
}

.studio-list {
    display: grid;
    gap: 9px;
}

.studio-row {
    min-height: 78px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) max-content;
    align-items: center;
    gap: 16px;
    padding: 11px 12px;
    border: 1px solid rgba(17, 19, 18, 0.07);
    border-radius: var(--radius);
    background: rgba(248, 248, 245, 0.92);
    box-shadow: var(--shadow-soft);
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.studio-row-link {
    cursor: pointer;
}

.studio-row:hover,
.studio-row:focus-visible {
    border-color: rgba(17, 19, 18, 0.18);
    box-shadow: 0 20px 46px rgba(7, 9, 9, 0.12);
    transform: translateY(-1px);
    outline: 0;
}

.studio-main {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.studio-logo {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    border-radius: var(--radius);
    object-fit: cover;
    object-position: center;
    background: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(17, 19, 18, 0.06);
}

.studio-copy {
    min-width: 0;
}

.studio-copy h3 {
    margin: 0;
    overflow: hidden;
    font-size: 15px;
    line-height: 1.25;
    font-weight: 820;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.studio-copy p {
    margin: 5px 0 0;
    overflow: hidden;
    color: var(--muted);
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.studio-actions {
    display: flex;
    align-items: center;
    gap: 7px;
}

.icon-button {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(17, 19, 18, 0.08);
    border-radius: 12px;
    color: #232725;
    background: rgba(255, 255, 255, 0.72);
    font-size: 20px;
    font-weight: 800;
    transition: transform 0.16s ease, background 0.16s ease, color 0.16s ease;
}

.icon-button:hover,
.icon-button:focus-visible {
    background: #ffffff;
    outline: 0;
    transform: translateY(-1px);
}

.icon-button-danger {
    color: var(--danger);
    background: #f8e9e6;
}

.employee-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.employee-card {
    min-height: 208px;
    padding: 13px;
    border: 1px solid rgba(17, 19, 18, 0.07);
    border-radius: var(--radius);
    background: rgba(248, 248, 245, 0.92);
    box-shadow: var(--shadow-soft);
    cursor: pointer;
    animation: card-sort-in 0.26s cubic-bezier(0.2, 0.8, 0.2, 1) both;
    animation-delay: var(--card-delay, 0ms);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.employee-card:hover,
.employee-card:focus-visible {
    border-color: rgba(17, 19, 18, 0.18);
    box-shadow: 0 22px 52px rgba(7, 9, 9, 0.14);
    transform: translateY(-2px);
    outline: 0;
}

.employee-card-negative {
    border-color: rgba(180, 35, 24, 0.28);
    background: linear-gradient(180deg, rgba(255, 238, 235, 0.92), rgba(248, 248, 245, 0.94));
}

.employee-card-head {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 13px;
}

.employee-card-avatar {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    border-radius: var(--radius);
    object-fit: contain;
    object-position: center;
    background: #f7f7f3;
}

.employee-card-head h3 {
    margin: 0;
    font-size: 15px;
    line-height: 1.2;
    font-weight: 820;
}

.employee-card-head p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 11px;
    font-weight: 680;
}

body.modal-open {
    overflow: hidden;
}

#overlay-root {
    position: relative;
    z-index: 80;
}

.context-menu {
    position: fixed;
    z-index: 90;
    width: 190px;
    display: grid;
    gap: 4px;
    padding: 6px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 14px;
    color: #ffffff;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.04)),
        rgba(8, 10, 10, 0.9);
    box-shadow: 0 24px 64px rgba(7, 9, 9, 0.34);
    backdrop-filter: blur(22px) saturate(145%);
    -webkit-backdrop-filter: blur(22px) saturate(145%);
    animation: context-menu-in 0.14s ease both;
}

.context-menu button {
    min-height: 38px;
    border-radius: 9px;
    padding: 0 11px;
    color: rgba(255, 255, 255, 0.9);
    background: transparent;
    text-align: left;
    font-size: 13px;
    font-weight: 740;
}

.context-menu button:hover,
.context-menu button:focus-visible {
    color: #111312;
    background: #ffffff;
    outline: 0;
}

.context-menu .context-menu-danger {
    color: #ffaaa2;
}

.context-menu .context-menu-danger:hover,
.context-menu .context-menu-danger:focus-visible {
    color: #a5271e;
    background: #ffe8e4;
}

.modal-layer {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: grid;
    place-items: center;
    padding: 16px;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: rgba(7, 9, 9, 0.56);
    backdrop-filter: blur(9px);
    -webkit-backdrop-filter: blur(9px);
    cursor: default;
    animation: modal-backdrop-in 0.18s ease both;
}

.modal-card {
    position: relative;
    z-index: 1;
    width: min(720px, 100%);
    max-height: calc(100dvh - 32px);
    overflow: auto;
    border: 1px solid rgba(255, 255, 255, 0.52);
    border-radius: var(--radius-lg);
    background: rgba(248, 248, 245, 0.97);
    box-shadow:
        0 36px 100px rgba(7, 9, 9, 0.38),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    animation: modal-card-in 0.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.modal-card-small {
    width: min(480px, 100%);
}

.modal-card-medium {
    width: min(580px, 100%);
}

.modal-card-wide {
    width: min(980px, 100%);
}

.modal-head {
    position: sticky;
    top: 0;
    z-index: 4;
    min-height: 66px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(17, 19, 18, 0.08);
    background: rgba(248, 248, 245, 0.92);
    backdrop-filter: blur(18px) saturate(145%);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
}

.modal-head h2 {
    margin: 0;
    font-size: 20px;
    line-height: 1.2;
    font-weight: 840;
}

.modal-close {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #3c4240;
    background: rgba(17, 19, 18, 0.06);
    font-size: 25px;
    line-height: 1;
}

.modal-close:hover,
.modal-close:focus-visible {
    color: #111312;
    background: rgba(17, 19, 18, 0.11);
    outline: 0;
}

.modal-body {
    padding: 18px;
}

.modal-form-grid .field {
    margin-bottom: 0;
}

.modal-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 9px;
    margin-top: 4px;
}

.modal-actions .btn {
    width: auto;
    min-width: 116px;
}

.modal-danger-button {
    color: #ffffff;
    background: #b42318;
}

.delete-modal-text {
    margin: 0 0 22px;
    color: #4e5551;
    font-size: 14px;
    line-height: 1.6;
}

.modal-loader {
    min-height: 160px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 720;
}

.insight-entity-head {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 14px;
}

.insight-avatar {
    width: 62px;
    height: 62px;
    flex: 0 0 62px;
    border-radius: var(--radius);
    object-fit: contain;
    object-position: center;
    background: #ffffff;
}

.insight-entity-head h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 840;
}

.insight-entity-head p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.insight-kpis {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.insight-kpi {
    min-height: 78px;
    display: grid;
    align-content: center;
    gap: 9px;
    padding: 11px;
    border: 1px solid rgba(17, 19, 18, 0.07);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.66);
}

.insight-kpi > span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 720;
}

.insight-kpi > div {
    display: flex;
    align-items: center;
    gap: 7px;
}

.insight-kpi strong {
    font-size: 16px;
    line-height: 1.1;
    font-weight: 840;
    white-space: nowrap;
}

.insight-kpi-negative {
    border-color: rgba(180, 35, 24, 0.2);
    background: #fff0ed;
}

.insight-kpi-negative strong {
    color: var(--danger);
}

.modal-chart-shell {
    overflow: hidden;
    padding: 1px;
    border-radius: var(--radius);
    background:
        radial-gradient(circle at 18% 0%, rgba(82, 103, 124, 0.34), transparent 34%),
        linear-gradient(180deg, #182226, #0d1212);
}

.modal-chart-shell .revenue-chart-panel {
    margin: 0;
    animation-delay: 0s;
}

.modal-chart-shell .chart-total,
.modal-chart-shell .chart-peak strong,
.modal-chart-shell .chart-tooltip strong {
    color: #ffffff;
}

.toast {
    z-index: 130;
}

@keyframes context-menu-in {
    from {
        opacity: 0;
        transform: translateY(-4px) scale(0.97);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes modal-backdrop-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes modal-card-in {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (max-width: 1060px) {
    .kpi-grid,
    .apps-grid,
    .employee-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .apps-list,
    .apps-list .app-card {
        grid-template-columns: 1fr;
    }

    .apps-list .stat-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-row {
        grid-template-columns: 1fr;
    }

    .payout-card {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 700px) {
    .layout {
        width: min(100% - 24px, 1280px);
        padding-top: 12px;
    }

    .login-screen {
        padding: 14px;
    }

    .login-logo {
        width: min(238px, 68vw);
    }

    .identity-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .topbar,
    .hero-head,
    .section-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .section-tools {
        width: 100%;
        align-items: stretch;
        flex-direction: column;
    }

    .topbar-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .topbar-user,
    .topbar-actions .btn,
    .hero-action,
    .section-head .btn,
    .sort-select {
        width: 100%;
    }

    .topbar-actions .music-toggle {
        width: 42px;
        flex: 0 0 42px;
    }

    .view-toggle {
        width: 100%;
    }

    .view-button {
        flex: 1;
    }

    .kpi-grid,
    .apps-grid,
    .employee-grid,
    .insight-kpis,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .apps-list .stat-list {
        grid-template-columns: 1fr;
    }

    .dashboard-hero {
        padding: 14px;
    }

    .chart-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .chart-peak {
        min-width: 0;
        text-align: left;
    }

    .chart-stage {
        height: 150px;
    }

    .hero-head h2 {
        font-size: 26px;
    }

    .payout-card {
        grid-template-columns: 1fr;
    }

    .modal-layer {
        padding: 8px;
    }

    .modal-card {
        max-height: calc(100dvh - 16px);
        border-radius: 18px;
    }

    .modal-body {
        padding: 14px;
    }

    .modal-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .modal-actions .btn,
    .compact-primary {
        width: 100%;
    }

    .studio-row {
        gap: 9px;
    }

    .studio-copy p {
        max-width: 52vw;
    }
}

@media (max-width: 520px) {
    .income-mood-emoji:nth-child(n + 11) {
        display: none;
    }

    .login-shell {
        gap: 18px;
    }

    .identity-grid {
        width: min(500px, 100%);
        justify-self: center;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .identity-card {
        aspect-ratio: 1 / 1.14;
        gap: 7px;
        padding: 8px;
    }

    .identity-avatar {
        width: 100%;
        height: 100%;
    }

    .identity-name {
        left: auto;
        right: auto;
        bottom: auto;
        min-height: 28px;
        padding: 7px 5px;
        font-size: 10px;
    }

    .login-title {
        font-size: 22px;
    }

    .studio-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .studio-actions {
        justify-content: flex-end;
    }

    .studio-copy p {
        max-width: 58vw;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-intro-screen,
    .auth-intro-screen::before,
    .auth-intro-screen .boot-logo,
    .auth-intro-screen .boot-logo-scene::before,
    .auth-intro-screen .boot-logo-scene::after,
    .password-shell,
    .login-income-counting,
    .login-income-complete,
    .context-menu,
    .modal-backdrop,
    .modal-card,
    .employee-card,
    .studio-row {
        animation: none;
        transition: none;
    }

    .income-mood-rain {
        display: none;
    }
}

@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes fade-up {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes card-sort-in {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes date-rail-loading {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(100%);
    }
}

@keyframes chart-dot-in {
    to {
        opacity: 1;
    }
}

@keyframes auth-intro-logo-story {
    0% {
        opacity: 0.45;
        filter:
            invert(1)
            brightness(1)
            drop-shadow(0 28px 48px rgba(0, 0, 0, 0.42))
            drop-shadow(0 0 0 rgba(255, 255, 255, 0))
            drop-shadow(0 0 0 rgba(255, 255, 255, 0));
        transform: translate3d(0, 24px, 0) scale(0.78);
        animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
    }
    8% {
        opacity: 1;
    }
    48.214% {
        opacity: 1;
        filter:
            invert(1)
            brightness(1)
            drop-shadow(0 28px 48px rgba(0, 0, 0, 0.42))
            drop-shadow(0 0 0 rgba(255, 255, 255, 0))
            drop-shadow(0 0 0 rgba(255, 255, 255, 0));
        transform: translate3d(0, 0, 0) scale(1.02);
    }
    53.571% {
        opacity: 1;
        filter:
            invert(1)
            brightness(1.4)
            drop-shadow(0 0 14px rgba(255, 255, 255, 1))
            drop-shadow(0 0 46px rgba(255, 255, 255, 0.82))
            drop-shadow(0 0 96px rgba(255, 255, 255, 0.46));
        transform: translate3d(0, 0, 0) scale(1.1);
        animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    }
    85.714%,
    100% {
        opacity: 1;
        filter:
            invert(1)
            brightness(1)
            drop-shadow(0 28px 48px rgba(0, 0, 0, 0.42))
            drop-shadow(0 0 0 rgba(255, 255, 255, 0))
            drop-shadow(0 0 0 rgba(255, 255, 255, 0));
        transform: translate3d(0, 0, 0) scale(1);
    }
}

@keyframes auth-intro-orb-flight {
    0% {
        left: calc(50% + clamp(-210px, -28vw, -108px));
        opacity: 0;
        transform: translate3d(0, 24px, 0) scale(0.55);
    }
    10% {
        opacity: 1;
    }
    12.5% {
        transform: translate3d(0, -41px, 0) scale(0.7);
    }
    25% {
        transform: translate3d(0, -89px, 0) scale(0.95);
    }
    37.5% {
        transform: translate3d(0, -120px, 0) scale(1.3);
    }
    50% {
        transform: translate3d(0, -134px, 0) scale(1.9);
    }
    62.5% {
        transform: translate3d(0, -130px, 0) scale(2.8);
    }
    75% {
        transform: translate3d(0, -110px, 0) scale(4);
    }
    82% {
        opacity: 1;
    }
    87.5% {
        transform: translate3d(0, -72px, 0) scale(5.7);
    }
    100% {
        left: calc(50% + 72vw);
        opacity: 0;
        transform: translate3d(0, -18px, 0) scale(8);
    }
}

@keyframes income-mood-fall {
    0% {
        top: -12%;
        opacity: 0;
        transform: translate3d(0, -24px, 0) rotate(0deg);
    }
    10% {
        opacity: 0.31;
    }
    84% {
        opacity: 0.28;
    }
    100% {
        top: 112%;
        opacity: 0;
        transform: translate3d(var(--mood-drift), 24px, 0) rotate(var(--mood-spin));
    }
}

@keyframes boot-logo-arrive {
    0% {
        opacity: 0;
        transform: translate3d(0, 38px, 0) scale(0.9);
    }
    68% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
    }
    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
    }
}

@keyframes boot-light-sweep {
    0% {
        opacity: 0;
        transform: rotate(-18deg) scale(0.92);
    }
    42% {
        opacity: 1;
    }
    100% {
        opacity: 0.64;
        transform: rotate(12deg) scale(1.08);
    }
}

@keyframes boot-shadow {
    0% {
        opacity: 0;
        transform: translateY(74px) scaleX(0.42);
    }
    58% {
        opacity: 0.72;
        transform: translateY(58px) scaleX(0.86);
    }
    100% {
        opacity: 0.48;
        transform: translateY(58px) scaleX(0.74);
    }
}

@keyframes login-income-settle {
    0% {
        filter: brightness(1.45);
        transform: translateY(-2px) scale(1.025);
    }
    100% {
        filter: brightness(1);
        transform: translateY(0) scale(1);
    }
}

@keyframes inline-logo-pulse {
    0%, 100% {
        opacity: 0.2;
        transform: scale(0.98);
    }
    50% {
        opacity: 0.42;
        transform: scale(1);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}
