/* REVO_STANDARD v6.0 - Shared Sidebar (single source of truth para Mozini Advocacia)
   v6.0 (2026-05-15): rail-que-respira. Hover/focus-driven expand. Sem botão toggle. */

.revo-sidebar {
    width: var(--sidebar-collapsed-width, 80px);
    background-color: var(--bg-sidebar, #050505);
    border-right: 1px solid var(--border-color, rgba(255,255,255,0.08));
    display: flex;
    flex-direction: column;
    padding: 24px 0 16px;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.12) transparent;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-sidebar::-webkit-scrollbar { width: 4px; }
.revo-sidebar::-webkit-scrollbar-track { background: transparent; }
.revo-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.10); border-radius: 4px; }
.revo-sidebar:hover::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.20); }

@media (min-width: 769px) {
    .revo-sidebar:hover,
    .revo-sidebar:focus-within,
    .revo-sidebar:has(:focus-visible) {
        width: var(--sidebar-width, 250px);
        box-shadow: 4px 0 24px rgba(0,0,0,0.45);
    }
    body.light-mode .revo-sidebar:hover,
    body.light-mode .revo-sidebar:focus-within,
    body.light-mode .revo-sidebar:has(:focus-visible) {
        box-shadow: 4px 0 24px rgba(0,0,0,0.12);
    }
}

.revo-mobile-top-bar {
    display: none; position: fixed; top: 0; left: 0; right: 0;
    height: 60px; background: rgba(5,5,5,0.8);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color, rgba(255,255,255,0.08));
    z-index: 1100; padding: 0 20px;
    align-items: center; justify-content: space-between;
}
body.light-mode .revo-mobile-top-bar {
    background: rgba(255,255,255,0.85);
    border-bottom-color: var(--border-color, rgba(0,0,0,0.10));
}

.revo-sidebar-backdrop {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
    z-index: 950; opacity: 0; transition: opacity 0.3s ease; pointer-events: none;
}
.revo-sidebar-backdrop.active { display: block; opacity: 1; pointer-events: auto; }

.revo-brand {
    padding: 0;
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    transition: padding 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                align-items 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-logo-svg {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 24px;
    background: transparent;
    padding: 0;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                height 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                border-radius 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                object-fit 0s;
}
@media (min-width: 769px) {
    .revo-sidebar:hover .revo-brand,
    .revo-sidebar:focus-within .revo-brand,
    .revo-sidebar:has(:focus-visible) .revo-brand {
        padding: 0 28px;
        align-items: flex-start;
    }
    .revo-sidebar:hover .revo-logo-svg,
    .revo-sidebar:focus-within .revo-logo-svg,
    .revo-sidebar:has(:focus-visible) .revo-logo-svg {
        width: 96px;
        height: auto;
        object-fit: contain;
        border-radius: 16px;
        padding: 0;
    }
}

.revo-nav-menu {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 0 10px;
    transition: padding 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 12px 14px;
    border-radius: 10px;
    color: var(--text-muted, rgba(255,255,255,0.55));
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    outline: none;
}
.revo-nav-item i {
    font-size: 20px;
    min-width: 20px;
    flex-shrink: 0;
    transition: color 0.2s ease;
}
.revo-nav-item span {
    max-width: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.15s ease;
}
.revo-nav-item:hover,
.revo-nav-item:focus-visible {
    background-color: var(--bg-card-alt, #1A1A1A);
    color: var(--text, #fff);
}
.revo-nav-item.active {
    background-color: var(--revo-red, rgb(224,0,0));
    color: #FFFFFF;
    font-weight: 600;
}
.revo-nav-item.active i { color: #FFFFFF; }
.revo-nav-item.active:hover {
    background-color: var(--revo-red-hover, #b30000);
    color: #FFFFFF;
}

@media (min-width: 769px) {
    .revo-nav-menu { padding: 0 14px; }
    .revo-sidebar:hover .revo-nav-item,
    .revo-sidebar:focus-within .revo-nav-item,
    .revo-sidebar:has(:focus-visible) .revo-nav-item {
        justify-content: flex-start;
        gap: 12px;
    }
    .revo-sidebar:hover .revo-nav-item span,
    .revo-sidebar:focus-within .revo-nav-item span,
    .revo-sidebar:has(:focus-visible) .revo-nav-item span {
        max-width: 200px;
        opacity: 1;
        transition: max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity 0.2s 0.15s ease;
    }
}

.revo-client-card {
    margin-top: auto;
    padding: 8px 0;
    transition: padding 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-client-info {
    background: transparent;
    border: none;
    padding: 0;
    border-radius: 0;
    display: flex;
    align-items: center;
    gap: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-client-avatar {
    width: 100%;
    height: 48px;
    min-width: unset;
    border-radius: 6px;
    background: var(--bg-card, #121212);
    color: var(--text, #fff);
    border: 1px solid var(--border-color, rgba(255,255,255,0.08));
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    font-size: 14px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-client-details {
    display: none;
}
.revo-client-details h4 { font-size: 13px; font-weight: 600; margin: 0; padding: 0; }
.revo-client-details p { font-size: 11px; color: var(--text-muted); margin: 2px 0 0; padding: 0; }

@media (min-width: 769px) {
    .revo-sidebar:hover .revo-client-card,
    .revo-sidebar:focus-within .revo-client-card,
    .revo-sidebar:has(:focus-visible) .revo-client-card {
        padding: 0 20px;
    }
    .revo-sidebar:hover .revo-client-info,
    .revo-sidebar:focus-within .revo-client-info,
    .revo-sidebar:has(:focus-visible) .revo-client-info {
        background: var(--bg-card, #121212);
        border: 1px solid var(--border-color, rgba(255,255,255,0.08));
        padding: 16px;
        border-radius: 10px;
        gap: 12px;
        justify-content: center;
    }
    .revo-sidebar:hover .revo-client-avatar,
    .revo-sidebar:focus-within .revo-client-avatar,
    .revo-sidebar:has(:focus-visible) .revo-client-avatar {
        width: 38px;
        height: 38px;
        min-width: 38px;
        border-radius: 50%;
        background: linear-gradient(135deg, var(--revo-red-dark, #260404), #111);
        border: 1px solid rgba(224,0,0,0.4);
        color: #fff;
        font-size: 16px;
        font-weight: 800;
    }
    .revo-sidebar:hover .revo-client-details,
    .revo-sidebar:focus-within .revo-client-details,
    .revo-sidebar:has(:focus-visible) .revo-client-details {
        display: block;
    }
}

.revo-theme-wrap {
    padding: 0 10px;
    margin-top: 12px;
    transition: padding 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
#revoThemeToggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 12px 0;
    width: 100%;
    border-radius: 10px;
    background: transparent;
    border: 1px solid var(--border-color, rgba(255,255,255,0.08));
    color: var(--text-muted);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    overflow: hidden;
}
#revoThemeToggle i { font-size: 18px; flex-shrink: 0; }
#revoThemeLabel {
    max-width: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.15s ease;
}
#revoThemeToggle:hover {
    color: var(--text, #fff);
    border-color: var(--border-hover, rgba(255,255,255,0.15));
}

@media (min-width: 769px) {
    .revo-sidebar:hover .revo-theme-wrap,
    .revo-sidebar:focus-within .revo-theme-wrap,
    .revo-sidebar:has(:focus-visible) .revo-theme-wrap {
        padding: 0 20px;
    }
    .revo-sidebar:hover #revoThemeToggle,
    .revo-sidebar:focus-within #revoThemeToggle,
    .revo-sidebar:has(:focus-visible) #revoThemeToggle {
        justify-content: center;
        gap: 10px;
        padding: 10px 16px;
    }
    .revo-sidebar:hover #revoThemeLabel,
    .revo-sidebar:focus-within #revoThemeLabel,
    .revo-sidebar:has(:focus-visible) #revoThemeLabel {
        max-width: 200px;
        opacity: 1;
        transition: max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity 0.2s 0.15s ease;
    }
}

.revo-logout-wrap {
    padding: 8px 10px 0;
    transition: padding 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-logout-btn {
    width: 100%;
    padding: 12px 0;
    border-radius: 10px;
    background: transparent;
    border: 1px solid var(--border-color, rgba(255,255,255,0.08));
    color: var(--text-muted, rgba(255,255,255,0.55));
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    white-space: nowrap;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.revo-logout-btn i { font-size: 16px; flex-shrink: 0; }
.revo-logout-btn span {
    max-width: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.15s ease;
}
.revo-logout-btn:hover {
    color: var(--revo-red, rgb(224,0,0));
    border-color: var(--revo-red, rgb(224,0,0));
}

@media (min-width: 769px) {
    .revo-sidebar:hover .revo-logout-wrap,
    .revo-sidebar:focus-within .revo-logout-wrap,
    .revo-sidebar:has(:focus-visible) .revo-logout-wrap {
        padding: 8px 20px 16px;
    }
    .revo-sidebar:hover .revo-logout-btn,
    .revo-sidebar:focus-within .revo-logout-btn,
    .revo-sidebar:has(:focus-visible) .revo-logout-btn {
        justify-content: center;
        gap: 10px;
        padding: 10px 16px;
    }
    .revo-sidebar:hover .revo-logout-btn span,
    .revo-sidebar:focus-within .revo-logout-btn span,
    .revo-sidebar:has(:focus-visible) .revo-logout-btn span {
        max-width: 200px;
        opacity: 1;
        transition: max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity 0.2s 0.15s ease;
    }
}

.revo-content-wrap {
    flex: 1;
    margin-left: var(--sidebar-collapsed-width, 80px);
    transition: margin-left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 768px) {
    .revo-mobile-top-bar { display: flex; }
    .revo-sidebar {
        transform: translateX(-100%);
        width: 280px;
        opacity: 0;
        top: 0;
        height: 100vh;
        z-index: 2000;
    }
    .revo-sidebar.active {
        transform: translateX(0);
        opacity: 1;
    }
    .revo-sidebar.active .revo-nav-item {
        justify-content: flex-start;
        gap: 12px;
    }
    .revo-sidebar.active .revo-nav-item span,
    .revo-sidebar.active #revoThemeLabel,
    .revo-sidebar.active .revo-logout-btn span {
        opacity: 1;
        max-width: 200px;
    }
    .revo-sidebar.active .revo-brand {
        padding: 0 28px;
        align-items: flex-start;
    }
    .revo-sidebar.active .revo-logo-svg {
        width: 96px;
        height: auto;
        object-fit: contain;
        border-radius: 16px;
        padding: 0;
    }
    .revo-sidebar.active .revo-client-card {
        padding: 0 20px;
    }
    .revo-sidebar.active .revo-client-info {
        background: var(--bg-card, #121212);
        border: 1px solid var(--border-color, rgba(255,255,255,0.08));
        padding: 16px;
        border-radius: 10px;
        gap: 12px;
        justify-content: center;
    }
    .revo-sidebar.active .revo-client-avatar {
        width: 38px;
        height: 38px;
        min-width: 38px;
        border-radius: 50%;
        background: linear-gradient(135deg, var(--revo-red-dark, #260404), #111);
        border: 1px solid rgba(224,0,0,0.4);
        font-size: 16px;
        font-weight: 800;
    }
    .revo-sidebar.active .revo-client-details { display: block; }
    .revo-sidebar.active .revo-theme-wrap { padding: 0 20px; }
    .revo-sidebar.active #revoThemeToggle {
        justify-content: center;
        gap: 10px;
        padding: 10px 16px;
    }
    .revo-sidebar.active .revo-logout-wrap { padding: 8px 20px 16px; }
    .revo-sidebar.active .revo-logout-btn {
        gap: 10px;
        padding: 10px 16px;
    }
    .revo-content-wrap { margin-left: 0 !important; padding-top: 60px !important; }
}

/* MacBook 13"/14" e laptops 1366x768, viewport curto */
@media (min-width: 769px) and (max-height: 820px) {
    .revo-sidebar { padding: 16px 0 12px; }
    .revo-brand { margin-bottom: 20px; gap: 12px; }
    .revo-sidebar:hover .revo-logo-svg,
    .revo-sidebar:focus-within .revo-logo-svg,
    .revo-sidebar:has(:focus-visible) .revo-logo-svg { width: 84px; padding: 0; }
    .revo-nav-menu { gap: 3px; padding: 0 12px; }
    .revo-nav-item { padding: 10px 13px; font-size: 13.5px; }
    .revo-nav-item i { font-size: 19px; min-width: 19px; }
    .revo-sidebar:hover .revo-client-avatar,
    .revo-sidebar:focus-within .revo-client-avatar,
    .revo-sidebar:has(:focus-visible) .revo-client-avatar {
        width: 34px; height: 34px; min-width: 34px; font-size: 14px;
    }
    .revo-client-details h4 { font-size: 12.5px; }
    .revo-client-details p { font-size: 10.5px; }
    .revo-sidebar:hover .revo-theme-wrap,
    .revo-sidebar:focus-within .revo-theme-wrap,
    .revo-sidebar:has(:focus-visible) .revo-theme-wrap { padding: 0 16px; margin-top: 8px; }
    .revo-sidebar:hover #revoThemeToggle,
    .revo-sidebar:focus-within #revoThemeToggle,
    .revo-sidebar:has(:focus-visible) #revoThemeToggle { padding: 8px 14px; font-size: 12.5px; }
    #revoThemeToggle i { font-size: 16px; }
}

@media (min-width: 769px) and (max-height: 720px) {
    .revo-sidebar { padding: 12px 0 8px; }
    .revo-brand { margin-bottom: 14px; gap: 10px; }
    .revo-sidebar:hover .revo-logo-svg,
    .revo-sidebar:focus-within .revo-logo-svg,
    .revo-sidebar:has(:focus-visible) .revo-logo-svg { width: 72px; padding: 0; }
    .revo-nav-item { padding: 8px 12px; font-size: 13px; }
    .revo-nav-item i { font-size: 18px; min-width: 18px; }
    .revo-sidebar:hover .revo-client-info,
    .revo-sidebar:focus-within .revo-client-info,
    .revo-sidebar:has(:focus-visible) .revo-client-info { padding: 10px; }
}

/* Light mode self-contained */
body.light-mode .revo-sidebar {
    background-color: #FFFFFF;
    border-right-color: rgba(0,0,0,0.10);
}
body.light-mode .revo-nav-item {
    color: rgba(0,0,0,0.55);
}
body.light-mode .revo-nav-item:hover,
body.light-mode .revo-nav-item:focus-visible {
    background-color: #E8E8E8;
    color: #111;
}
body.light-mode .revo-nav-item.active {
    background-color: var(--revo-red, rgb(224,0,0));
    color: #FFFFFF;
}
body.light-mode .revo-nav-item.active i { color: #FFFFFF; }
body.light-mode .revo-nav-item.active:hover {
    background-color: var(--revo-red-hover, #b30000);
}
body.light-mode .revo-client-avatar {
    background: #F0F0F2;
    color: #111;
    border-color: rgba(0,0,0,0.10);
}
@media (min-width: 769px) {
    body.light-mode .revo-sidebar:hover .revo-client-info,
    body.light-mode .revo-sidebar:focus-within .revo-client-info,
    body.light-mode .revo-sidebar:has(:focus-visible) .revo-client-info {
        background: #F0F0F2;
        border-color: rgba(0,0,0,0.10);
    }
    body.light-mode .revo-sidebar:hover .revo-client-avatar,
    body.light-mode .revo-sidebar:focus-within .revo-client-avatar,
    body.light-mode .revo-sidebar:has(:focus-visible) .revo-client-avatar {
        background: linear-gradient(135deg, var(--revo-red-dark, #6a0000), #ccc);
        color: #fff;
    }
}
body.light-mode .revo-client-details h4 { color: #111; }
body.light-mode .revo-client-details p { color: rgba(0,0,0,0.50); }
body.light-mode #revoThemeToggle {
    border-color: rgba(0,0,0,0.12);
    color: rgba(0,0,0,0.55);
}
body.light-mode #revoThemeToggle:hover {
    background: rgba(0,0,0,0.05);
    color: #111;
}
body.light-mode .revo-logo-svg { background: transparent; }
body.light-mode .revo-logout-btn {
    border-color: rgba(0,0,0,0.12);
    color: rgba(0,0,0,0.50);
}
body.light-mode .revo-logout-btn:hover {
    color: var(--revo-red, rgb(224,0,0));
    border-color: var(--revo-red, rgb(224,0,0));
}

/* Ocultar Vercel Toolbar em produção */
vercel-live-feedback,
[data-vercel-toolbar],
iframe[src*="vercel.live"],
div[id^="vercel-live"],
div[class*="vercel-toolbar"] { display: none !important; visibility: hidden !important; }
