:root {
    --roxo-principal: #7648c9;
    --roxo-claro: #a576dd;
    --roxo-escuro: #4e256c;
    --verde-principal: #48c976;
    --verde-claro: #76dda5;
    --verde-escuro: #256c4e;
    --cinza-claro: #dadada;
    --cinza-medio: #575756;
    --cinza-escuro: #3c3c3b;
    --branco: #ffffff;
    --azul: #2f80ed;
    --amarelo: #f2c94c;
    --vermelho: #d94848;
    --laranja: #f2994a;
    --sombra: 0 18px 45px rgba(32, 22, 48, 0.14);
    --borda: rgba(78, 37, 108, 0.12);
}

html.theme-dark {
    color-scheme: dark;
}

* {
    box-sizing: border-box;
}

[hidden] {
    display: none !important;
}

html {
    min-height: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--cinza-escuro);
    background: #f7f8fa;
    font-family: Arial, Verdana, sans-serif;
}

html.theme-dark body {
    color: #f1eef7;
    background: #11131a;
}

body.auth-page {
    background:
        linear-gradient(135deg, rgba(78, 37, 108, 0.96), rgba(118, 72, 201, 0.9) 48%, rgba(72, 201, 118, 0.92));
}

a {
    color: var(--roxo-principal);
    text-decoration: none;
}

a:hover {
    color: var(--roxo-escuro);
}

button,
input,
select,
textarea {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
}

.auth-wrapper {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 28px;
}

.auth-shell {
    width: min(100%, 460px);
}

.auth-card,
.form-panel,
.metric-card,
.table-section {
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: var(--branco);
    box-shadow: var(--sombra);
}

.auth-card {
    position: relative;
    overflow: hidden;
    padding: 34px;
}

.auth-card > :not(.infinity-field) {
    position: relative;
    z-index: 1;
}

.admin-auth-page {
    background:
        linear-gradient(135deg, rgba(37, 108, 78, 0.96), rgba(78, 37, 108, 0.92) 48%, rgba(118, 72, 201, 0.94));
}

.admin-auth-card {
    border-color: rgba(72, 201, 118, 0.25);
}

.auth-logo,
.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--roxo-escuro);
    font-weight: 700;
    letter-spacing: 0;
}

.auth-logo {
    margin-bottom: 22px;
}

.brand-mark {
    display: inline-grid;
    position: relative;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 50%;
    color: var(--branco);
    background: linear-gradient(135deg, var(--roxo-principal), var(--verde-principal));
    font-family: Verdana, Arial, sans-serif;
    font-weight: 800;
}

.admin-entry-mark {
    isolation: isolate;
    box-shadow: 0 0 0 0 rgba(72, 201, 118, 0.34);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.admin-entry-mark:hover,
.admin-entry-mark.active {
    color: var(--branco);
    transform: translateY(-1px) scale(1.04);
    box-shadow: 0 0 0 8px rgba(72, 201, 118, 0.12);
}

.admin-entry-mark::after {
    position: absolute;
    inset: -9px;
    border: 1px solid rgba(72, 201, 118, 0.46);
    border-radius: 50%;
    content: "";
    animation: infinityPulse 2.2s ease-in-out infinite;
}

.admin-entry-mark small {
    position: absolute;
    right: -7px;
    bottom: -7px;
    display: grid;
    width: 21px;
    height: 21px;
    place-items: center;
    border: 2px solid var(--branco);
    border-radius: 50%;
    color: var(--roxo-escuro);
    background: var(--verde-claro);
    font-size: 1rem;
    line-height: 1;
    animation: infinityFloat 2.8s ease-in-out infinite;
}

.infinity-field {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.infinity-field span {
    position: absolute;
    color: rgba(118, 72, 201, 0.12);
    font-family: Verdana, Arial, sans-serif;
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    animation: infinityDrift 7s ease-in-out infinite;
}

.infinity-field span:nth-child(1) {
    top: 18px;
    right: 22px;
}

.infinity-field span:nth-child(2) {
    left: 18px;
    bottom: 28px;
    color: rgba(72, 201, 118, 0.14);
    animation-delay: -2s;
}

.infinity-field span:nth-child(3) {
    right: 68px;
    bottom: 82px;
    color: rgba(165, 118, 221, 0.11);
    font-size: 3.3rem;
    animation-delay: -4s;
}

.infinity-field span:nth-child(4) {
    top: 108px;
    left: 62px;
    color: rgba(72, 201, 118, 0.12);
    font-size: 2.8rem;
    animation-delay: -5.2s;
}

.auth-card h1,
.page-heading h1,
.section-heading h2 {
    margin: 0;
    font-family: Verdana, Arial, sans-serif;
    color: var(--cinza-escuro);
    letter-spacing: 0;
}

.auth-card h1 {
    font-size: 2rem;
    line-height: 1.18;
}

.auth-card p,
.page-heading p {
    margin: 10px 0 0;
    color: var(--cinza-medio);
    line-height: 1.55;
}

.auth-highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

.auth-highlights span {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    border-radius: 999px;
    color: var(--roxo-escuro);
    background: #f1ecfa;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0 12px;
}

.admin-highlights span {
    color: var(--verde-escuro);
    background: #e7f8ee;
}

.form-stack,
.indication-form {
    margin-top: 24px;
}

.form-stack {
    display: grid;
    gap: 16px;
}

label {
    display: grid;
    gap: 7px;
    color: var(--cinza-medio);
    font-size: 0.92rem;
    font-weight: 500;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid #d8d4df;
    border-radius: 8px;
    background: var(--branco);
    color: var(--cinza-escuro);
    outline: none;
    padding: 12px 13px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

textarea {
    resize: vertical;
    min-height: 108px;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--roxo-principal);
    box-shadow: 0 0 0 3px rgba(118, 72, 201, 0.16);
}

input.is-filled,
select.is-filled,
textarea.is-filled {
    border-color: rgba(72, 201, 118, 0.72);
    background: linear-gradient(180deg, #ffffff, #f7fff9);
}

.password-field {
    position: relative;
    display: block;
}

.password-field input {
    padding-right: 48px;
}

.password-toggle {
    position: absolute;
    right: 6px;
    top: 50%;
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border: 0;
    border-radius: 50%;
    color: var(--roxo-principal);
    background: #f1ecfa;
    cursor: pointer;
    transform: translateY(-50%);
}

.password-toggle:hover {
    color: var(--verde-escuro);
    background: #e7f8ee;
}

.password-toggle svg {
    width: 19px;
    height: 19px;
}

input[readonly] {
    background: #f2f0f6;
    color: var(--cinza-medio);
}

.primary-button,
.secondary-button,
.ghost-button,
.primary-action,
.small-button,
.sidebar-logout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 600;
    line-height: 1.1;
    padding: 0 18px;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button svg,
.secondary-button svg,
.ghost-button svg,
.primary-action svg,
.small-button svg {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    margin-right: 8px;
}

.primary-button,
.primary-action {
    color: var(--branco);
    background: var(--verde-principal);
    box-shadow: 0 12px 22px rgba(72, 201, 118, 0.28);
}

.primary-button:hover,
.primary-action:hover {
    color: var(--branco);
    background: var(--verde-escuro);
    transform: translateY(-1px);
}

.secondary-button {
    color: var(--branco);
    background: var(--roxo-principal);
}

.secondary-button:hover {
    color: var(--branco);
    background: var(--roxo-escuro);
}

.ghost-button {
    color: var(--roxo-principal);
    background: #f1ecfa;
}

.ghost-button:hover {
    color: var(--roxo-escuro);
    background: #e6ddf5;
}

.small-button {
    min-height: 36px;
    color: var(--branco);
    background: var(--roxo-principal);
    padding: 0 14px;
}

.small-button:hover {
    background: var(--roxo-escuro);
}

.ghost-mini-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    border-radius: 999px;
    color: var(--roxo-principal);
    background: #f1ecfa;
    font-weight: 600;
    padding: 0 14px;
}

.ghost-mini-button:hover {
    color: var(--roxo-escuro);
    background: #e6ddf5;
}

.danger-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    border: 0;
    border-radius: 999px;
    color: var(--branco);
    background: var(--vermelho);
    cursor: pointer;
    font-weight: 600;
    padding: 0 14px;
}

.danger-button:hover {
    background: #a92d2d;
}

button:disabled {
    cursor: wait;
    opacity: 0.72;
}

.auth-switch {
    margin-top: 20px;
    text-align: center;
}

.compact-switch {
    margin-top: 10px;
}

.auth-switch a {
    font-weight: 600;
}

.flash-stack {
    display: grid;
    gap: 10px;
    margin-bottom: 18px;
}

.flash {
    border-radius: 8px;
    padding: 12px 14px;
    color: var(--cinza-escuro);
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    font-weight: 500;
}

.flash-success {
    color: #174d30;
    background: #e7f8ee;
    border-color: rgba(72, 201, 118, 0.45);
}

.flash-error {
    color: #7f1d1d;
    background: #fdecec;
    border-color: rgba(217, 72, 72, 0.35);
}

.flash-warning {
    color: #6b4d12;
    background: #fff7d7;
    border-color: rgba(242, 201, 76, 0.55);
}

.app-shell {
    display: grid;
    position: relative;
    grid-template-columns: 280px minmax(0, 1fr);
    min-height: 100vh;
    overflow-x: hidden;
    background:
        linear-gradient(135deg, #faf9fd, #f1fbf5 58%, #f8fafc);
    transition: grid-template-columns 0.2s ease;
}

.sidebar {
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding: 24px;
    color: var(--branco);
    background: linear-gradient(180deg, var(--roxo-escuro), var(--roxo-principal) 58%, var(--verde-escuro));
}

.sidebar,
.main-panel {
    position: relative;
    z-index: 1;
}

.sidebar .brand {
    color: var(--branco);
    margin-bottom: 34px;
}

.sidebar .brand-mark {
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.28);
}

.brand-text {
    font-family: Verdana, Arial, sans-serif;
    font-size: 0.98rem;
    line-height: 1.2;
}

.nav-menu {
    display: grid;
    align-content: start;
    gap: 8px;
    min-height: 0;
    overflow-y: auto;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.86);
    font-weight: 500;
    padding: 0 14px;
}

.nav-link svg {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
}

.nav-link:hover,
.nav-link.active {
    color: var(--branco);
    background: rgba(255, 255, 255, 0.14);
}

.sidebar-logout {
    margin-top: auto;
    color: var(--branco);
    background: rgba(255, 255, 255, 0.14);
}

.sidebar-logout:hover {
    color: var(--branco);
    background: rgba(255, 255, 255, 0.22);
}

.main-panel {
    min-width: 0;
}

.system-infinity-field {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.system-infinity-field span {
    position: absolute;
    color: rgba(118, 72, 201, 0.07);
    font-family: Verdana, Arial, sans-serif;
    font-size: 6rem;
    font-weight: 800;
    line-height: 1;
    animation: infinityDrift 9s ease-in-out infinite;
}

.system-infinity-field span:nth-child(1) {
    top: 92px;
    right: 7vw;
}

.system-infinity-field span:nth-child(2) {
    top: 42vh;
    left: 25vw;
    color: rgba(72, 201, 118, 0.08);
    font-size: 4.8rem;
    animation-delay: -2s;
}

.system-infinity-field span:nth-child(3) {
    right: 20vw;
    bottom: 12vh;
    color: rgba(165, 118, 221, 0.08);
    font-size: 7rem;
    animation-delay: -4s;
}

.system-infinity-field span:nth-child(4) {
    top: 18vh;
    left: 46vw;
    color: rgba(72, 201, 118, 0.07);
    font-size: 3.8rem;
    animation-delay: -5.5s;
}

.system-infinity-field span:nth-child(5) {
    bottom: 8vh;
    left: 9vw;
    color: rgba(78, 37, 108, 0.08);
    font-size: 5.4rem;
    animation-delay: -7s;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 72px;
    padding: 0 30px;
    border-bottom: 1px solid rgba(78, 37, 108, 0.08);
    background: rgba(255, 255, 255, 0.86);
    backdrop-filter: blur(14px);
}

.topbar strong {
    display: block;
    font-family: Verdana, Arial, sans-serif;
    color: var(--cinza-escuro);
    font-weight: 600;
}

.topbar span {
    display: block;
    color: var(--cinza-medio);
    font-size: 0.9rem;
}

.topbar-user {
    display: flex;
    align-items: center;
    gap: 14px;
}

.topbar-user span {
    color: var(--cinza-escuro);
    font-weight: 500;
}

.topbar-user a {
    font-weight: 500;
}

.user-pill {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    border: 0;
    color: var(--cinza-escuro);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    cursor: pointer;
    padding: 5px 10px 5px 5px;
}

.user-pill > svg {
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
}

.theme-toggle {
    display: inline-grid;
    place-items: center;
}

.user-menu {
    position: relative;
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 30;
    display: grid;
    min-width: 190px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: var(--branco);
    box-shadow: var(--sombra);
    padding: 8px;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.user-menu.open .user-dropdown {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.user-dropdown a {
    border-radius: 8px;
    color: var(--cinza-escuro);
    padding: 10px 12px;
}

.user-dropdown a:hover {
    color: var(--roxo-escuro);
    background: #f1ecfa;
}

.avatar {
    display: inline-grid;
    width: 38px;
    height: 38px;
    place-items: center;
    overflow: hidden;
    border: 2px solid rgba(72, 201, 118, 0.38);
    border-radius: 50%;
    color: var(--branco);
    background: linear-gradient(135deg, var(--roxo-principal), var(--verde-principal));
    font-size: 0.82rem;
    font-weight: 600;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.small-avatar {
    width: 32px;
    height: 32px;
    font-size: 0.72rem;
}

.notification-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    border-radius: 999px;
    color: var(--roxo-principal);
    background: #f1ecfa;
    padding: 0 12px;
}

.notification-link svg {
    flex: 0 0 17px;
    width: 17px;
    height: 17px;
}

.notification-link strong {
    display: grid;
    min-width: 22px;
    height: 22px;
    place-items: center;
    border-radius: 999px;
    color: var(--branco);
    background: var(--verde-principal);
    font-size: 0.78rem;
}

.notification-link.has-unread {
    color: var(--roxo-escuro);
    box-shadow: 0 0 0 3px rgba(118, 72, 201, 0.12);
}

.icon-button {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    color: var(--roxo-principal);
    background: #f1ecfa;
    cursor: pointer;
}

.theme-toggle {
    display: inline-grid;
    place-items: center;
}

.content {
    width: min(100%, 1240px);
    margin: 0 auto;
    padding: 30px;
}

.content > * {
    animation: pageRise 0.36s ease both;
}

.metric-card,
.table-section,
.form-panel,
.profile-card,
.detail-card,
.notification-item,
.notification-mini,
.finance-chart-card,
.ranking-chart-panel,
.profile-activity-panel {
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.metric-card:hover,
.profile-card:hover,
.detail-card:hover,
.notification-item:hover,
.notification-mini:hover,
.finance-chart-card:hover,
.ranking-chart-panel:hover,
.profile-activity-panel:hover {
    transform: none;
    border-color: rgba(118, 72, 201, 0.22);
    box-shadow: 0 12px 30px rgba(32, 22, 48, 0.09);
}

.page-heading,
.section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

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

.page-heading h1 {
    font-size: 1.8rem;
    font-weight: 600;
}

.section-heading h2 {
    font-size: 1.3rem;
    font-weight: 600;
}

.eyebrow {
    display: inline-flex;
    margin-bottom: 7px;
    color: var(--roxo-principal);
    font-size: 0.76rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(160px, 1fr));
    gap: 16px;
    margin-bottom: 22px;
}

.metric-card {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 122px;
    padding: 18px;
}

.metric-card span {
    color: var(--cinza-medio);
    font-weight: 500;
}

.metric-card strong {
    display: block;
    margin-top: 6px;
    color: var(--cinza-escuro);
    font-family: Verdana, Arial, sans-serif;
    font-size: 2rem;
    font-weight: 600;
    line-height: 1;
}

.metric-icon {
    display: grid;
    flex: 0 0 46px;
    width: 46px;
    height: 46px;
    place-items: center;
    border-radius: 8px;
}

.metric-icon.purple {
    color: var(--roxo-principal);
    background: #efe8fb;
}

.metric-icon.green {
    color: var(--verde-escuro);
    background: #e7f8ee;
}

.metric-icon.blue {
    color: var(--azul);
    background: #eaf3ff;
}

.metric-icon.dark-green {
    color: var(--verde-escuro);
    background: #def5e8;
}

.metric-icon.red {
    color: var(--vermelho);
    background: #fdecec;
}

.table-section {
    padding: 20px;
}

.table-wrap {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
}

.wide-table {
    min-width: 1160px;
}

.admin-table {
    min-width: 1460px;
}

.finance-table {
    min-width: 1220px;
}

.ranking-table {
    min-width: 680px;
}

.users-table {
    min-width: 1120px;
}

.data-table th,
.data-table td {
    padding: 12px;
    border-bottom: 1px solid #ece8f2;
    text-align: left;
    vertical-align: middle;
}

.data-table th {
    color: var(--cinza-medio);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.data-table td {
    color: var(--cinza-escuro);
}

.empty-state {
    color: var(--cinza-medio);
    text-align: center;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0 10px;
    white-space: nowrap;
}

.status-nova {
    color: var(--roxo-escuro);
    background: #efe8fb;
}

.status-atendimento {
    color: #1450a3;
    background: #eaf3ff;
}

.status-negociacao {
    color: #17653b;
    background: #e7f8ee;
}

.status-proposta {
    color: #6b4d12;
    background: #fff3bf;
}

.status-realizada {
    color: var(--verde-escuro);
    background: #d8f4e4;
    animation: wonPulse 2.6s ease-in-out infinite;
}

.status-perdida {
    color: #8f1d1d;
    background: #fde4e4;
}

.status-sem-contato {
    color: var(--cinza-medio);
    background: #ededed;
}

.status-sem-interesse {
    color: #8c4b12;
    background: #fff0df;
}

.status-padrao {
    color: var(--cinza-medio);
    background: #ededed;
}

.filter-bar {
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr)) auto;
    gap: 14px;
    align-items: end;
    margin-bottom: 18px;
    padding: 18px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.86);
}

.filter-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.finance-filter {
    grid-template-columns: repeat(4, minmax(150px, 1fr));
}

.finance-filter .filter-actions {
    grid-column: span 1;
}

.form-panel {
    padding: 24px;
}

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

.full-field {
    grid-column: 1 / -1;
}

.choice-field {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0;
    border: 1px solid #d8d4df;
    border-radius: 8px;
    padding: 14px;
}

.choice-field legend {
    color: var(--cinza-medio);
    font-size: 0.92rem;
    font-weight: 600;
    padding: 0 6px;
}

.choice-field label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    border-radius: 999px;
    background: #f7f4fb;
    color: var(--cinza-escuro);
    cursor: pointer;
    padding: 0 12px;
}

.choice-field input {
    width: auto;
    accent-color: var(--verde-principal);
}

.form-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 22px;
}

.inline-status-form {
    display: grid;
    grid-template-columns: minmax(170px, 1fr) minmax(120px, 0.8fr) auto;
    gap: 8px;
    align-items: center;
    min-width: 430px;
}

.inline-status-form select,
.inline-status-form input {
    min-height: 36px;
    padding: 8px 10px;
}

.inline-status-form input[hidden] {
    display: none;
}

.table-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    min-width: 180px;
}

.tag-table-cell {
    min-width: 260px;
    vertical-align: top;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.lead-tag {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    gap: 4px;
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 4px 9px;
    font-size: 0.74rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
}

.lead-tag form {
    display: inline-flex;
    margin: 0 -5px 0 0;
}

.tag-color-1 {
    border-color: #ded1f5;
    color: #5d3290;
    background: #f1eafb;
}

.tag-color-2 {
    border-color: #c7e9d6;
    color: #17653b;
    background: #e7f8ee;
}

.tag-color-3 {
    border-color: #cddff4;
    color: #18549a;
    background: #e9f2fd;
}

.tag-color-4 {
    border-color: #f0dda3;
    color: #6b4d12;
    background: #fff5cf;
}

.tag-color-5 {
    border-color: #d9dce2;
    color: #4d5360;
    background: #f0f1f3;
}

.tag-remove-button {
    display: grid;
    width: 24px;
    height: 24px;
    place-items: center;
    border: 0;
    border-radius: 50%;
    color: currentColor;
    background: transparent;
    cursor: pointer;
    font: inherit;
    line-height: 1;
    padding: 0;
}

.tag-remove-button:hover,
.tag-remove-button:focus-visible {
    background: rgba(32, 22, 48, 0.1);
}

.no-tags {
    color: var(--cinza-medio);
    font-size: 0.78rem;
    font-weight: 400;
}

.tag-editor {
    margin-top: 8px;
}

.tag-editor summary {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    border: 1px solid #ded6ea;
    border-radius: 6px;
    color: var(--roxo-escuro);
    background: #faf8fd;
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 600;
    list-style: none;
    padding: 6px 10px;
}

.tag-editor summary::-webkit-details-marker {
    display: none;
}

.tag-editor summary::before {
    content: "+";
    margin-right: 6px;
    font-size: 1rem;
    line-height: 1;
}

.tag-editor[open] summary::before {
    content: "−";
}

.tag-editor-panel {
    display: grid;
    gap: 10px;
    width: min(100%, 340px);
    margin-top: 8px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: var(--branco);
    padding: 12px;
}

.tag-form {
    display: grid;
    grid-template-columns: minmax(160px, 1fr) auto;
    gap: 8px;
    align-items: end;
}

.tag-form + .tag-form {
    border-top: 1px solid var(--borda);
    padding-top: 10px;
}

.tag-form label {
    display: grid;
    gap: 5px;
}

.tag-form label > span {
    color: var(--cinza-medio);
    font-size: 0.72rem;
    font-weight: 500;
}

.tag-form input,
.tag-form select {
    min-width: 0;
    min-height: 38px;
    padding: 8px 10px;
}

.tag-form button {
    min-height: 38px;
    white-space: nowrap;
}

.detail-tag-list {
    margin-top: 12px;
}

.detail-tag-editor {
    max-width: 620px;
    margin-top: 14px;
}

.admin-row-actions {
    margin-top: 10px;
}

.admin-metrics .metric-card-wide {
    min-width: 230px;
}

.money-total {
    font-size: 1.55rem;
}

.finance-heading {
    align-items: center;
}

.finance-metrics {
    grid-template-columns: repeat(5, minmax(170px, 1fr));
}

.finance-insight {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
    padding: 16px 18px;
    border: 1px solid rgba(72, 201, 118, 0.22);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 12px 28px rgba(32, 22, 48, 0.08);
}

.finance-insight > span {
    display: grid;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    place-items: center;
    border-radius: 50%;
    color: var(--branco);
    background: linear-gradient(135deg, var(--roxo-principal), var(--verde-principal));
    font-family: Verdana, Arial, sans-serif;
    font-size: 1.7rem;
    font-weight: 800;
}

.finance-insight strong,
.finance-insight small {
    display: block;
}

.finance-insight strong {
    color: var(--cinza-escuro);
    font-family: Verdana, Arial, sans-serif;
}

.finance-insight small {
    margin-top: 3px;
    color: var(--cinza-medio);
    font-weight: 400;
}

.profile-activity-panel {
    display: grid;
    gap: 8px;
    border: 1px solid rgba(72, 201, 118, 0.24);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(240, 255, 246, 0.9));
    box-shadow: 0 14px 32px rgba(32, 22, 48, 0.08);
    padding: 20px;
}

.profile-activity-panel h2 {
    margin: 0;
    color: var(--cinza-escuro);
    font-family: Verdana, Arial, sans-serif;
    font-size: 1.35rem;
}

.profile-activity-panel p {
    margin: 8px 0 0;
    color: var(--cinza-medio);
    font-weight: 500;
}

.filter-summary {
    max-width: 520px;
    color: var(--cinza-medio);
    font-size: 0.88rem;
    font-weight: 500;
    text-align: right;
}

.money-cell {
    color: var(--verde-escuro);
    font-weight: 600;
    white-space: nowrap;
}

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

.ranking-metrics {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
}

.ranking-chart-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 18px;
}

.ranking-chart-panel {
    min-width: 0;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 12px 28px rgba(32, 22, 48, 0.08);
    padding: 20px;
}

.ranking-chart-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 20px;
}

.ranking-chart-heading h2 {
    margin: 4px 0 0;
    font-family: Verdana, Arial, sans-serif;
    font-size: 1.08rem;
}

.ranking-chart-heading p {
    margin: 6px 0 0;
    color: var(--cinza-medio);
    font-size: 0.86rem;
    font-weight: 400;
}

.chart-period {
    flex: 0 0 auto;
    color: var(--roxo-escuro);
    font-size: 0.78rem;
    font-weight: 600;
}

.ranking-column-chart {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
    min-height: 250px;
    align-items: end;
    border-bottom: 1px solid var(--borda);
    padding: 8px 0 10px;
}

.ranking-column-item {
    display: grid;
    grid-template-rows: 22px 174px 42px;
    gap: 6px;
    min-width: 0;
    align-items: end;
    text-align: center;
}

.ranking-column-value {
    color: var(--roxo-escuro);
    font-size: 0.82rem;
    font-weight: 600;
}

.ranking-column-track {
    display: flex;
    width: min(100%, 44px);
    height: 174px;
    align-items: flex-end;
    justify-self: center;
    overflow: hidden;
    border-radius: 6px 6px 0 0;
    background: #f0edf5;
}

.ranking-column-fill {
    display: block;
    width: 100%;
    border-radius: 6px 6px 0 0;
    background: var(--roxo-principal);
    transform-origin: bottom;
    animation: rankingColumnIn 0.7s ease both;
}

.ranking-column-item strong {
    display: -webkit-box;
    overflow: hidden;
    color: var(--cinza-escuro);
    font-size: 0.74rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.ranking-line-chart {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    grid-template-rows: 200px auto;
    column-gap: 8px;
    min-width: 0;
}

.ranking-line-scale,
.ranking-line-plot {
    position: relative;
    min-width: 0;
}

.ranking-line-scale span {
    position: absolute;
    right: 0;
    color: var(--cinza-medio);
    font-size: 0.68rem;
    font-weight: 500;
    transform: translateY(-50%);
}

.ranking-line-guides,
.ranking-line-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.ranking-line-guides span {
    position: absolute;
    right: 0;
    left: 0;
    border-top: 1px dashed #ddd7e6;
}

.ranking-line-stroke {
    fill: none;
    stroke: var(--verde-escuro);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 1;
    vector-effect: non-scaling-stroke;
    animation: rankingLineIn 0.8s ease both;
}

.ranking-line-point {
    position: absolute;
    z-index: 1;
    display: grid;
    width: 14px;
    height: 14px;
    place-items: center;
    transform: translate(-50%, -50%);
}

.ranking-line-point i {
    display: block;
    width: 12px;
    height: 12px;
    border: 3px solid var(--branco);
    border-radius: 50%;
    background: var(--verde-escuro);
    box-shadow: 0 0 0 2px rgba(36, 124, 89, 0.2);
}

.ranking-line-point strong {
    position: absolute;
    bottom: 18px;
    left: 50%;
    min-width: 48px;
    border: 1px solid #dcece5;
    border-radius: 5px;
    color: var(--verde-escuro);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 4px 12px rgba(32, 22, 48, 0.08);
    padding: 3px 5px;
    font-size: 0.68rem;
    line-height: 1.2;
    text-align: center;
    transform: translateX(-50%);
    white-space: nowrap;
}

.ranking-line-labels {
    grid-column: 2;
    display: grid;
    grid-template-columns: repeat(var(--ranking-items), minmax(0, 1fr));
    min-width: 0;
    border-top: 1px solid var(--borda);
    padding-top: 10px;
}

.ranking-line-labels div {
    min-width: 0;
    padding: 0 4px;
    text-align: center;
}

.ranking-line-labels strong,
.ranking-line-labels span {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ranking-line-labels strong {
    color: var(--cinza-escuro);
    font-size: 0.72rem;
}

.ranking-line-labels span {
    margin-top: 3px;
    color: var(--cinza-medio);
    font-size: 0.66rem;
    font-weight: 500;
}

.ranking-chart-empty {
    min-height: 120px;
    margin: 0;
    display: grid;
    place-items: center;
    color: var(--cinza-medio);
    font-weight: 500;
    text-align: center;
}

.rank-badge {
    display: inline-grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 50%;
    color: var(--branco);
    background: linear-gradient(135deg, var(--roxo-principal), var(--verde-principal));
    font-weight: 600;
}

.agenda-metrics {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
}

.agenda-board {
    display: grid;
    grid-template-columns: repeat(4, minmax(230px, 1fr));
    gap: 16px;
    align-items: start;
}

.agenda-column {
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 12px 28px rgba(32, 22, 48, 0.08);
    padding: 16px;
}

.compact-heading {
    align-items: flex-start;
    margin-bottom: 14px;
}

.compact-heading h2 {
    font-size: 1rem;
}

.agenda-list {
    display: grid;
    gap: 10px;
}

.agenda-card {
    display: grid;
    gap: 7px;
    border: 1px solid #ece8f2;
    border-radius: 8px;
    color: var(--cinza-escuro);
    background: #fbfafc;
    padding: 12px;
}

.agenda-card:hover {
    color: var(--cinza-escuro);
    border-color: rgba(72, 201, 118, 0.42);
    background: #f4fff8;
}

.agenda-card strong {
    color: var(--cinza-escuro);
    font-family: Verdana, Arial, sans-serif;
}

.agenda-card span,
.agenda-card small {
    color: var(--cinza-medio);
    font-weight: 500;
}

.agenda-overdue .agenda-card {
    border-color: rgba(217, 72, 72, 0.22);
}

.agenda-today .agenda-card {
    border-color: rgba(72, 201, 118, 0.28);
}

.user-line {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.user-line strong {
    color: var(--cinza-escuro);
}

.user-edit-box {
    margin-bottom: 10px;
}

.user-edit-box summary {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    border-radius: 999px;
    color: var(--branco);
    background: var(--roxo-principal);
    cursor: pointer;
    font-weight: 600;
    padding: 0 14px;
}

.admin-user-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(150px, 1fr));
    gap: 10px;
    min-width: 420px;
    margin: 10px 0;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: #fbfafc;
    padding: 12px;
}

.admin-user-form button {
    align-self: end;
}

.seller-option {
    display: flex;
    min-height: 48px;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: #f7f4fb;
    cursor: pointer;
    padding: 9px 11px;
}

.seller-option input {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    accent-color: var(--roxo-principal);
}

.seller-option span {
    display: grid;
    gap: 2px;
}

.seller-option strong {
    color: var(--cinza-escuro);
}

.seller-option small {
    color: var(--cinza-medio);
    font-weight: 400;
}

.seller-status {
    display: inline-flex;
    min-width: 46px;
    min-height: 30px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--cinza-medio);
    background: #efedf3;
    font-size: 0.82rem;
    font-weight: 600;
}

.seller-status.active {
    color: var(--verde-escuro);
    background: #dcf5e6;
}

.field-message {
    color: #9b5f12;
    font-size: 0.82rem;
    font-weight: 500;
    line-height: 1.4;
}

.table-link {
    color: var(--roxo-escuro);
    font-weight: 600;
}

.table-link:hover {
    color: var(--verde-escuro);
}

.finance-chart-card {
    margin-bottom: 22px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 12px 28px rgba(32, 22, 48, 0.08);
    padding: 20px;
}

.product-chart {
    display: grid;
    gap: 12px;
}

.product-bar-row {
    display: grid;
    gap: 8px;
}

.product-bar-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.product-bar-label span {
    color: var(--cinza-medio);
    font-weight: 600;
}

.progress-track {
    position: relative;
    overflow: hidden;
    height: 11px;
    border-radius: 999px;
    background: #ece8f2;
}

.progress-fill {
    position: absolute;
    inset: 0 auto 0 0;
    min-width: 3px;
    border-radius: inherit;
    background: var(--roxo-principal);
    transition: width 0.7s ease;
}

.progress-fill.status-realizada,
.progress-fill.status-negociacao {
    background: linear-gradient(90deg, var(--verde-escuro), var(--verde-principal));
}

.progress-fill.status-atendimento {
    background: var(--azul);
}

.progress-fill.status-proposta {
    background: var(--amarelo);
}

.progress-fill.status-perdida {
    background: var(--vermelho);
}

.progress-fill.status-sem-contato,
.progress-fill.status-sem-interesse {
    background: var(--cinza-medio);
}

.profile-grid {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 18px;
}

.profile-main-stack {
    display: grid;
    gap: 18px;
}

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

.profile-stat {
    min-height: 126px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 12px 28px rgba(32, 22, 48, 0.08);
    padding: 16px;
}

.profile-stat span,
.profile-stat small {
    display: block;
    color: var(--cinza-medio);
    font-weight: 500;
}

.profile-stat strong {
    display: block;
    margin: 10px 0 6px;
    color: var(--cinza-escuro);
    font-family: Verdana, Arial, sans-serif;
    font-size: 1.5rem;
}

.profile-card,
.detail-card {
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--sombra);
    padding: 22px;
}

.profile-card {
    display: grid;
    align-content: start;
    justify-items: center;
    gap: 14px;
    text-align: center;
}

.profile-avatar {
    display: grid;
    width: 132px;
    height: 132px;
    place-items: center;
    overflow: hidden;
    border: 4px solid rgba(72, 201, 118, 0.32);
    border-radius: 50%;
    color: var(--branco);
    background: linear-gradient(135deg, var(--roxo-principal), var(--verde-principal));
    font-family: Verdana, Arial, sans-serif;
    font-size: 2rem;
    font-weight: 600;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-card h2 {
    margin: 0;
    font-family: Verdana, Arial, sans-serif;
}

.profile-card p {
    margin: 6px 0;
    color: var(--cinza-medio);
}

.profile-role {
    display: inline-flex;
    border-radius: 999px;
    color: var(--roxo-escuro);
    background: #efe8fb;
    font-weight: 600;
    padding: 6px 12px;
    text-transform: capitalize;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 22px;
}

.detail-card h2 {
    margin: 8px 0 16px;
}

.detail-card p {
    color: var(--cinza-medio);
    line-height: 1.5;
}

.detail-card-wide {
    grid-column: 1 / -1;
}

.timeline {
    display: grid;
    gap: 12px;
}

.timeline-step {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--cinza-medio);
    font-weight: 500;
}

.timeline-step.done,
.timeline-step.active {
    color: var(--cinza-escuro);
}

.timeline-dot {
    display: inline-flex;
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--cinza-claro);
    box-shadow: 0 0 0 5px rgba(218, 218, 218, 0.22);
}

.timeline-step.done .timeline-dot,
.timeline-step.active .timeline-dot {
    background: var(--verde-principal);
    box-shadow: 0 0 0 5px rgba(72, 201, 118, 0.2);
}

.timeline-step.active .timeline-dot {
    animation: wonPulse 2.2s ease-in-out infinite;
}

.people-pair,
.detail-list,
.history-list {
    display: grid;
    gap: 12px;
}

.person-line,
.history-item {
    display: flex;
    align-items: center;
    gap: 11px;
}

.person-line strong,
.person-line small,
.history-item strong,
.history-item small {
    display: block;
}

.person-line small,
.history-item small,
.detail-list dt {
    color: var(--cinza-medio);
    font-weight: 500;
}

.detail-list {
    margin: 0;
}

.detail-list div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid #ece8f2;
    padding-bottom: 10px;
}

.detail-list dd {
    margin: 0;
    color: var(--cinza-escuro);
    font-weight: 600;
}

.history-section {
    margin-bottom: 22px;
}

.history-item {
    border: 1px solid #ece8f2;
    border-radius: 8px;
    background: #fbfafc;
    padding: 12px;
}

.notification-list,
.notification-preview {
    margin-bottom: 22px;
}

.notification-list {
    display: grid;
    gap: 12px;
}

.notification-item,
.notification-mini,
.empty-panel {
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 12px 28px rgba(32, 22, 48, 0.08);
}

.notification-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 16px;
}

.notification-item.unread,
.notification-mini.unread {
    border-color: rgba(72, 201, 118, 0.44);
    background: #f0fff6;
}

.notification-item strong,
.notification-mini strong {
    color: var(--cinza-escuro);
    font-family: Verdana, Arial, sans-serif;
}

.notification-item p {
    margin: 6px 0;
    color: var(--cinza-medio);
    line-height: 1.5;
    white-space: pre-line;
}

.notification-item small {
    color: var(--cinza-medio);
    font-weight: 400;
}

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

.notification-mini {
    display: grid;
    gap: 6px;
    color: var(--cinza-escuro);
    padding: 14px;
}

.notification-mini span {
    display: -webkit-box;
    overflow: hidden;
    color: var(--cinza-medio);
    line-height: 1.35;
    white-space: pre-line;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
}

.empty-panel {
    display: grid;
    place-items: center;
    min-height: 132px;
    padding: 18px;
    text-align: center;
}

.empty-panel span {
    color: var(--roxo-claro);
    font-family: Verdana, Arial, sans-serif;
    font-size: 2rem;
    font-weight: 800;
}

.empty-panel p {
    margin: 6px 0 0;
    color: var(--cinza-medio);
    font-weight: 500;
}

.compact-empty {
    min-height: 94px;
}

.celebration-layer {
    position: fixed;
    inset: 0;
    z-index: 1000;
    pointer-events: none;
}

.celebration-layer canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.welcome-layer,
.sent-layer,
.new-indication-layer {
    position: fixed;
    inset: 0;
    z-index: 1100;
    display: grid;
    place-items: center;
}

.welcome-layer,
.sent-layer {
    pointer-events: none;
}

.welcome-card,
.sent-card,
.new-indication-card {
    display: grid;
    gap: 8px;
    width: min(92vw, 480px);
    border: 1px solid rgba(72, 201, 118, 0.28);
    border-radius: 8px;
    color: var(--cinza-escuro);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 26px 70px rgba(32, 22, 48, 0.24);
    padding: 26px;
    text-align: center;
    animation: welcomeIn 0.42s ease both;
}

.welcome-card span,
.sent-card span,
.new-indication-card > span {
    color: var(--verde-principal);
    font-family: Verdana, Arial, sans-serif;
    font-size: 2.4rem;
    font-weight: 800;
}

.welcome-card strong,
.sent-card strong,
.new-indication-card strong {
    font-family: Verdana, Arial, sans-serif;
    font-size: 1.2rem;
}

.welcome-card small,
.sent-card small,
.new-indication-card small {
    color: var(--cinza-medio);
    font-weight: 500;
}

.new-indication-card > small {
    overflow-y: auto;
    max-height: min(52vh, 420px);
    padding: 2px 8px;
    line-height: 1.55;
    text-align: left;
    white-space: pre-line;
}

.new-indication-layer {
    padding: 18px;
    background: rgba(32, 22, 48, 0.28);
}

.new-indication-card {
    border-color: rgba(118, 72, 201, 0.28);
}

.new-indication-card > span {
    color: var(--roxo-principal);
}

.new-indication-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-top: 12px;
}

.new-indication-actions .primary-button,
.new-indication-actions .ghost-button {
    min-height: 42px;
}

html.theme-dark .app-shell {
    background:
        linear-gradient(135deg, #11131a, #16201b 58%, #141624);
}

html.theme-dark .topbar,
html.theme-dark .auth-card,
html.theme-dark .form-panel,
html.theme-dark .metric-card,
html.theme-dark .table-section,
html.theme-dark .profile-card,
html.theme-dark .detail-card,
html.theme-dark .agenda-column,
html.theme-dark .notification-item,
html.theme-dark .notification-mini,
html.theme-dark .empty-panel,
html.theme-dark .finance-chart-card,
html.theme-dark .ranking-chart-panel,
html.theme-dark .finance-insight,
html.theme-dark .profile-stat,
html.theme-dark .user-dropdown {
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(23, 24, 34, 0.94);
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
}

html.theme-dark .profile-activity-panel {
    border-color: rgba(72, 201, 118, 0.25);
    background:
        linear-gradient(135deg, rgba(23, 24, 34, 0.96), rgba(20, 40, 28, 0.92));
}

html.theme-dark .auth-card h1,
html.theme-dark .page-heading h1,
html.theme-dark .section-heading h2,
html.theme-dark .metric-card strong,
html.theme-dark .topbar strong,
html.theme-dark .finance-insight strong,
html.theme-dark .profile-activity-panel h2,
html.theme-dark .profile-card h2,
html.theme-dark .profile-stat strong,
html.theme-dark .notification-item strong,
html.theme-dark .notification-mini strong,
html.theme-dark .data-table td,
html.theme-dark .detail-list dd,
html.theme-dark .agenda-card strong,
html.theme-dark .user-line strong,
html.theme-dark .user-dropdown a {
    color: #f1eef7;
}

html.theme-dark .auth-card p,
html.theme-dark .page-heading p,
html.theme-dark .metric-card span,
html.theme-dark .topbar span,
html.theme-dark .finance-insight small,
html.theme-dark .profile-activity-panel p,
html.theme-dark .profile-card p,
html.theme-dark .profile-stat span,
html.theme-dark .profile-stat small,
html.theme-dark .notification-item p,
html.theme-dark .notification-item small,
html.theme-dark .notification-mini span,
html.theme-dark .agenda-card span,
html.theme-dark .agenda-card small,
html.theme-dark .data-table th,
html.theme-dark label,
html.theme-dark .filter-summary {
    color: #bdb7c9;
}

html.theme-dark input,
html.theme-dark select,
html.theme-dark textarea {
    border-color: rgba(255, 255, 255, 0.12);
    color: #f1eef7;
    background: #11131a;
}

html.theme-dark input.is-filled,
html.theme-dark select.is-filled,
html.theme-dark textarea.is-filled {
    background: #132018;
}

html.theme-dark .filter-bar,
html.theme-dark .choice-field,
html.theme-dark .agenda-card,
html.theme-dark .admin-user-form,
html.theme-dark .history-item {
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(23, 24, 34, 0.86);
}

html.theme-dark .choice-field label,
html.theme-dark .seller-option,
html.theme-dark .ghost-button,
html.theme-dark .ghost-mini-button,
html.theme-dark .notification-link,
html.theme-dark .password-toggle,
html.theme-dark .icon-button,
html.theme-dark .user-pill,
html.theme-dark .auth-highlights span {
    color: #d8ccff;
    background: rgba(118, 72, 201, 0.18);
}

html.theme-dark .tag-editor summary {
    border-color: rgba(118, 72, 201, 0.3);
    color: #d8ccff;
    background: rgba(118, 72, 201, 0.14);
}

html.theme-dark .tag-editor-panel {
    border-color: rgba(255, 255, 255, 0.1);
    background: #171822;
}

html.theme-dark .tag-form + .tag-form {
    border-top-color: rgba(255, 255, 255, 0.1);
}

html.theme-dark .tag-color-1 {
    border-color: rgba(163, 125, 224, 0.35);
    color: #d8ccff;
    background: rgba(118, 72, 201, 0.2);
}

html.theme-dark .tag-color-2 {
    border-color: rgba(72, 201, 118, 0.3);
    color: #a8ebc1;
    background: rgba(72, 201, 118, 0.14);
}

html.theme-dark .tag-color-3 {
    border-color: rgba(74, 145, 226, 0.35);
    color: #b9d8fb;
    background: rgba(74, 145, 226, 0.14);
}

html.theme-dark .tag-color-4 {
    border-color: rgba(230, 190, 75, 0.34);
    color: #f3dc98;
    background: rgba(230, 190, 75, 0.14);
}

html.theme-dark .tag-color-5 {
    border-color: rgba(255, 255, 255, 0.15);
    color: #d4d5da;
    background: rgba(255, 255, 255, 0.08);
}

html.theme-dark .no-tags {
    color: #bdb7c9;
}

html.theme-dark .seller-option strong {
    color: #f1eef7;
}

html.theme-dark .seller-status {
    color: #c8c2d2;
    background: rgba(255, 255, 255, 0.09);
}

html.theme-dark .seller-status.active {
    color: #a8ebc1;
    background: rgba(72, 201, 118, 0.16);
}

html.theme-dark .ranking-column-chart {
    border-bottom-color: rgba(255, 255, 255, 0.12);
}

html.theme-dark .ranking-column-track {
    background: rgba(255, 255, 255, 0.08);
}

html.theme-dark .ranking-column-item strong {
    color: #f1eef7;
}

html.theme-dark .ranking-column-value {
    color: #d8ccff;
}

html.theme-dark .ranking-line-labels strong,
html.theme-dark .ranking-chart-heading h2 {
    color: #f1eef7;
}

html.theme-dark .ranking-chart-heading p,
html.theme-dark .ranking-line-labels span,
html.theme-dark .ranking-line-scale span,
html.theme-dark .ranking-chart-empty {
    color: #bdb7c9;
}

html.theme-dark .ranking-line-guides span {
    border-top-color: rgba(255, 255, 255, 0.12);
}

html.theme-dark .ranking-line-labels {
    border-top-color: rgba(255, 255, 255, 0.12);
}

html.theme-dark .ranking-line-point strong {
    border-color: rgba(72, 201, 118, 0.25);
    color: #a8ebc1;
    background: #292531;
}

html.theme-dark .chart-period {
    color: #d8ccff;
}

@keyframes rankingLineIn {
    from {
        stroke-dashoffset: 1;
    }

    to {
        stroke-dashoffset: 0;
    }
}

@keyframes rankingColumnIn {
    from {
        transform: scaleY(0);
    }

    to {
        transform: scaleY(1);
    }
}

html.theme-dark .data-table th,
html.theme-dark .data-table td,
html.theme-dark .detail-list div {
    border-bottom-color: rgba(255, 255, 255, 0.08);
}

html.theme-dark .user-dropdown a:hover {
    color: #ffffff;
    background: rgba(118, 72, 201, 0.22);
}

html.theme-dark .welcome-card,
html.theme-dark .sent-card,
html.theme-dark .new-indication-card {
    color: #f1eef7;
    background: rgba(23, 24, 34, 0.98);
}

@keyframes pageRise {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes welcomeIn {
    from {
        opacity: 0;
        transform: translateY(18px) scale(0.96);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.mobile-backdrop {
    display: none;
}

@keyframes infinityPulse {
    0%,
    100% {
        opacity: 0.55;
        transform: scale(0.9);
    }

    50% {
        opacity: 1;
        transform: scale(1.08);
    }
}

@keyframes infinityFloat {
    0%,
    100% {
        transform: translate(0, 0) rotate(0deg);
    }

    50% {
        transform: translate(2px, -4px) rotate(10deg);
    }
}

@keyframes infinityDrift {
    0%,
    100% {
        opacity: 0.55;
        transform: translateY(0) rotate(0deg) scale(1);
    }

    50% {
        opacity: 0.9;
        transform: translateY(-10px) rotate(6deg) scale(1.05);
    }
}

@keyframes wonPulse {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(72, 201, 118, 0.24);
    }

    50% {
        box-shadow: 0 0 0 6px rgba(72, 201, 118, 0.08);
    }
}

.sidebar-footer {
    display: grid;
    gap: 8px;
    margin-top: auto;
    padding-top: 18px;
}

.sidebar-settings,
.sidebar-collapse,
.sidebar-footer .sidebar-logout {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
    width: 100%;
    min-height: 44px;
    margin: 0;
    border: 0;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.1);
    cursor: pointer;
    font-weight: 500;
    padding: 0 14px;
}

.sidebar-settings:hover,
.sidebar-settings.active,
.sidebar-collapse:hover,
.sidebar-footer .sidebar-logout:hover {
    color: var(--branco);
    background: rgba(255, 255, 255, 0.18);
}

.sidebar-settings svg,
.sidebar-collapse svg,
.sidebar-footer .sidebar-logout svg {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
}

.sidebar-collapse svg {
    transition: transform 0.2s ease;
}

html.sidebar-collapsed .app-shell {
    grid-template-columns: 88px minmax(0, 1fr);
}

html.sidebar-collapsed .sidebar {
    padding: 22px 16px;
}

html.sidebar-collapsed .sidebar .brand {
    justify-content: center;
}

html.sidebar-collapsed .brand-text,
html.sidebar-collapsed .nav-link span,
html.sidebar-collapsed .sidebar-footer span {
    display: none;
}

html.sidebar-collapsed .nav-link,
html.sidebar-collapsed .sidebar-settings,
html.sidebar-collapsed .sidebar-collapse,
html.sidebar-collapsed .sidebar-footer .sidebar-logout {
    justify-content: center;
    padding-right: 0;
    padding-left: 0;
}

html.sidebar-collapsed .sidebar-collapse svg {
    transform: rotate(180deg);
}

.settings-section {
    padding-top: 4px;
}

.settings-section .section-heading p,
.seller-navigation .section-heading p,
.report-tags-section .section-heading p {
    margin: 6px 0 0;
    color: var(--cinza-medio);
    line-height: 1.5;
}

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

.settings-option {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 20px;
    align-items: center;
    gap: 14px;
    min-height: 94px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    color: var(--cinza-escuro);
    background: var(--branco);
    padding: 16px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.settings-option:hover {
    border-color: rgba(118, 72, 201, 0.35);
    color: var(--cinza-escuro);
    box-shadow: 0 12px 28px rgba(32, 22, 48, 0.09);
    transform: translateY(-1px);
}

.settings-option strong,
.settings-option small {
    display: block;
}

.settings-option strong {
    font-weight: 600;
}

.settings-option small {
    margin-top: 5px;
    color: var(--cinza-medio);
    font-size: 0.88rem;
    line-height: 1.4;
}

.settings-icon {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border-radius: 8px;
}

.settings-icon.purple {
    color: var(--roxo-principal);
    background: #efe8fb;
}

.settings-icon.green {
    color: var(--verde-escuro);
    background: #e7f8ee;
}

.settings-icon.blue {
    color: var(--azul);
    background: #eaf3ff;
}

.settings-icon.red {
    color: var(--vermelho);
    background: #fdecec;
}

.settings-arrow {
    width: 18px;
    height: 18px;
    color: var(--cinza-medio);
}

.report-filter {
    grid-template-columns: 1.1fr repeat(3, minmax(150px, 1fr)) auto;
}

.report-heading {
    position: relative;
    z-index: 30;
}

.report-email-action {
    position: relative;
}

.report-email-action > summary {
    list-style: none;
    cursor: pointer;
}

.report-email-action > summary::-webkit-details-marker {
    display: none;
}

.report-email-action > summary:focus-visible {
    outline: 3px solid rgba(111, 60, 195, 0.28);
    outline-offset: 3px;
}

.report-email-action[open] > summary {
    color: var(--roxo-escuro);
    background: #e6ddf5;
}

.report-email-popover {
    position: absolute;
    z-index: 40;
    top: calc(100% + 10px);
    right: 0;
    width: min(360px, calc(100vw - 48px));
    padding: 18px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: var(--branco);
    box-shadow: 0 14px 35px rgba(39, 29, 50, 0.16);
}

.report-email-form {
    display: grid;
    gap: 14px;
}

.report-email-form > div strong,
.report-email-form > div span,
.report-email-form label > span {
    display: block;
}

.report-email-form > div strong {
    color: var(--cinza-escuro);
    font-size: 0.98rem;
}

.report-email-form > div span {
    margin-top: 4px;
    color: var(--cinza-medio);
    font-size: 0.82rem;
    line-height: 1.45;
}

.report-email-form label > span {
    margin-bottom: 6px;
    color: var(--cinza-escuro);
    font-size: 0.82rem;
    font-weight: 600;
}

.report-email-form input {
    width: 100%;
}

.report-email-form .secondary-button {
    width: 100%;
    justify-content: center;
}

html.theme-dark .report-email-action[open] > summary {
    color: #ded0f5;
    background: #30283f;
}

html.theme-dark .report-email-popover {
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.32);
}

.report-metrics .metric-card {
    min-height: 108px;
}

.seller-navigation,
.seller-detail {
    margin: 30px 0;
    padding: 22px 0;
    border-top: 1px solid var(--borda);
    border-bottom: 1px solid var(--borda);
}

.seller-switcher {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 2px 2px 8px;
    scrollbar-width: thin;
}

.seller-chip {
    display: grid;
    flex: 0 0 184px;
    gap: 5px;
    min-height: 70px;
    align-content: center;
    border: 1px solid var(--borda);
    border-radius: 8px;
    color: var(--cinza-escuro);
    background: var(--branco);
    padding: 12px 14px;
}

.seller-chip span {
    overflow: hidden;
    font-size: 0.9rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.seller-chip strong {
    color: var(--cinza-medio);
    font-size: 0.82rem;
    font-weight: 500;
}

.seller-chip:hover,
.seller-chip.active {
    border-color: rgba(118, 72, 201, 0.4);
    color: var(--roxo-escuro);
    background: #f7f3fc;
}

.seller-chip.active strong {
    color: var(--roxo-principal);
}

.empty-inline {
    align-self: center;
    color: var(--cinza-medio);
    padding: 12px;
}

.seller-detail-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(120px, 1fr));
    gap: 12px;
}

.seller-detail-summary span {
    border-left: 3px solid var(--verde-principal);
    color: var(--cinza-medio);
    background: rgba(255, 255, 255, 0.7);
    padding: 12px 14px;
}

.seller-detail-summary strong {
    color: var(--cinza-escuro);
    font-size: 1.25rem;
    font-weight: 600;
}

.report-seller-table {
    min-width: 1040px;
}

.stale-report-section {
    margin: 22px 0;
}

.stale-report-section .section-heading p {
    max-width: 760px;
    margin: 6px 0 0;
    color: var(--cinza-medio);
    line-height: 1.5;
}

.stale-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    overflow: hidden;
    margin-bottom: 20px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: var(--borda);
}

.stale-summary-link {
    display: flex;
    min-height: 92px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 3px solid transparent;
    color: var(--cinza-escuro);
    background: var(--branco);
    padding: 16px 20px 13px;
}

.stale-summary-link:hover,
.stale-summary-link.active {
    color: var(--roxo-escuro);
    border-bottom-color: var(--roxo-principal);
    background: #f8f5fc;
}

.stale-summary-link.critical:hover,
.stale-summary-link.critical.active {
    color: #8f2d2d;
    border-bottom-color: var(--vermelho);
    background: #fff7f7;
}

.stale-summary-link span,
.stale-summary-link strong,
.stale-summary-link small {
    display: block;
}

.stale-summary-link strong {
    font-weight: 600;
}

.stale-summary-link small {
    margin-top: 5px;
    color: var(--cinza-medio);
}

.stale-summary-link b {
    min-width: 48px;
    color: var(--roxo-principal);
    font-size: 1.8rem;
    font-weight: 600;
    text-align: right;
}

.stale-summary-link.critical b {
    color: var(--vermelho);
}

.stale-table-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 4px 0 12px;
}

.stale-table-heading strong,
.stale-table-heading span {
    display: block;
}

.stale-table-heading strong {
    font-weight: 600;
}

.stale-table-heading span {
    margin-top: 3px;
    color: var(--cinza-medio);
    font-size: 0.86rem;
}

.stale-report-table {
    min-width: 1160px;
}

.stale-days {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    border: 1px solid #eadb9a;
    border-radius: 999px;
    color: #72550c;
    background: #fff8dc;
    padding: 4px 9px;
    font-size: 0.82rem;
    font-weight: 600;
    white-space: nowrap;
}

.stale-days.critical {
    border-color: #f0bcbc;
    color: #982c2c;
    background: #fff0f0;
}

.report-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 16px;
}

.report-pagination > span {
    color: var(--cinza-medio);
    font-size: 0.88rem;
}

.report-pagination > div {
    display: flex;
    gap: 8px;
}

.compact-count {
    display: block;
    margin: 2px 0;
    color: var(--cinza-medio);
    font-size: 0.84rem;
    white-space: nowrap;
}

.compact-count b {
    color: var(--cinza-escuro);
    font-weight: 600;
}

.report-analysis-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin: 22px 0;
}

.report-analysis-panel {
    min-width: 0;
}

.compact-report-table {
    min-width: 500px;
}

.report-percent {
    display: inline-block;
    width: 66px;
    height: 6px;
    margin-right: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #ece8f2;
    vertical-align: middle;
}

.report-percent i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--verde-principal);
}

.tag-report-filter {
    display: grid;
    grid-template-columns: minmax(190px, 1fr) minmax(170px, 0.55fr) auto;
    gap: 12px;
    align-items: end;
    margin-bottom: 16px;
}

.table-footer-action {
    display: flex;
    justify-content: center;
    padding-top: 16px;
}

.presentation-toolbar {
    position: sticky;
    top: 88px;
    z-index: 4;
    padding: 14px;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: rgba(247, 248, 250, 0.95);
    backdrop-filter: blur(10px);
}

.report-presentation {
    display: grid;
    gap: 24px;
}

.presentation-page {
    display: flex;
    min-height: 520px;
    flex-direction: column;
    border: 1px solid var(--borda);
    border-radius: 8px;
    background: var(--branco);
    box-shadow: 0 14px 34px rgba(32, 22, 48, 0.09);
    padding: 42px;
}

.presentation-cover {
    justify-content: space-between;
    color: var(--branco);
    background: linear-gradient(135deg, var(--roxo-escuro), var(--roxo-principal) 66%, var(--verde-escuro));
}

.presentation-brand {
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.08em;
}

.presentation-cover div > span {
    color: rgba(255, 255, 255, 0.74);
}

.presentation-cover h2 {
    max-width: 650px;
    margin: 12px 0;
    font-size: 2.65rem;
    font-weight: 600;
    line-height: 1.1;
}

.presentation-cover p {
    margin: 0;
    color: #dcf5e5;
    font-size: 1.2rem;
}

.presentation-cover > strong {
    font-weight: 500;
}

.presentation-page-heading {
    display: flex;
    align-items: center;
    gap: 18px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--borda);
}

.presentation-page-heading > span {
    color: var(--roxo-principal);
    font-size: 1.8rem;
    font-weight: 600;
}

.presentation-page-heading h2,
.presentation-page-heading p {
    margin: 0;
}

.presentation-page-heading h2 {
    font-size: 1.55rem;
    font-weight: 600;
}

.presentation-page-heading p {
    margin-top: 4px;
    color: var(--cinza-medio);
}

.presentation-kpis {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
    margin: auto 0;
}

.presentation-kpis div {
    min-height: 128px;
    border-top: 3px solid var(--verde-principal);
    background: #f7f8fa;
    padding: 18px;
}

.presentation-kpis span,
.presentation-kpis strong {
    display: block;
}

.presentation-stale-kpis {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 24px 0;
}

.presentation-stale-kpis div {
    border-left: 4px solid var(--roxo-principal);
    background: #f7f8fa;
    padding: 16px 18px;
}

.presentation-stale-kpis div:last-child {
    border-left-color: var(--vermelho);
}

.presentation-stale-kpis span,
.presentation-stale-kpis strong,
.presentation-stale-kpis small {
    display: block;
}

.presentation-stale-kpis span,
.presentation-stale-kpis small {
    color: var(--cinza-medio);
}

.presentation-stale-kpis strong {
    margin: 4px 0;
    color: var(--roxo-escuro);
    font-size: 1.8rem;
    font-weight: 600;
}

.presentation-stale-list {
    display: grid;
    gap: 0;
}

.presentation-stale-list > div:not(.empty-panel) {
    display: grid;
    grid-template-columns: minmax(140px, 1.2fr) minmax(120px, 0.9fr) minmax(100px, 0.75fr) 82px;
    gap: 14px;
    align-items: center;
    min-height: 42px;
    border-bottom: 1px solid var(--borda);
    font-size: 0.88rem;
}

.presentation-stale-list strong {
    font-weight: 600;
}

.presentation-stale-list span,
.presentation-stale-list small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.presentation-stale-list b {
    color: var(--vermelho);
    font-weight: 600;
    text-align: right;
}

.presentation-kpis span {
    color: var(--cinza-medio);
    font-size: 0.86rem;
}

.presentation-kpis strong {
    margin-top: 24px;
    color: var(--roxo-escuro);
    font-size: 2rem;
    font-weight: 600;
}

.presentation-ranking {
    display: grid;
    gap: 14px;
    margin: auto 0;
}

.presentation-ranking > div:not(.empty-panel) {
    display: grid;
    grid-template-columns: minmax(150px, 0.7fr) minmax(180px, 1fr) 52px;
    gap: 16px;
    align-items: center;
}

.presentation-ranking i {
    display: block;
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #ece8f2;
}

.presentation-ranking b {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--verde-principal);
}

.presentation-ranking strong {
    color: var(--roxo-principal);
    font-weight: 600;
    text-align: right;
}

.presentation-seller-total {
    display: inline-grid;
    align-self: flex-start;
    margin: 26px 0 20px;
    border-left: 4px solid var(--verde-principal);
    padding: 6px 18px;
}

.presentation-seller-total span {
    color: var(--cinza-medio);
}

.presentation-seller-total strong {
    color: var(--roxo-escuro);
    font-size: 2rem;
    font-weight: 600;
}

.presentation-columns {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.presentation-columns h3 {
    margin: 0 0 12px;
    font-size: 1rem;
    font-weight: 600;
}

.presentation-columns p {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin: 0;
    padding: 8px 0;
    border-bottom: 1px solid #ece8f2;
    font-size: 0.88rem;
}

.presentation-columns p strong {
    font-weight: 600;
}

html.theme-dark .settings-option,
html.theme-dark .seller-chip,
html.theme-dark .seller-detail-summary span,
html.theme-dark .presentation-page {
    color: #f1eef7;
    background: #191c24;
}

html.theme-dark .seller-chip:hover,
html.theme-dark .seller-chip.active {
    background: #24202e;
}

html.theme-dark .presentation-toolbar {
    background: rgba(17, 19, 26, 0.94);
}

html.theme-dark .presentation-kpis div {
    background: #20232d;
}

html.theme-dark .stale-summary-grid,
html.theme-dark .stale-summary-link,
html.theme-dark .presentation-stale-kpis div {
    background: #20232d;
}

html.theme-dark .stale-summary-link:hover,
html.theme-dark .stale-summary-link.active {
    background: #292431;
}

html.theme-dark .stale-summary-link.critical:hover,
html.theme-dark .stale-summary-link.critical.active {
    background: #302225;
}

.nav-count {
    display: inline-grid;
    min-width: 22px;
    height: 22px;
    margin-left: auto;
    padding: 0 6px;
    place-items: center;
    border-radius: 999px;
    color: #5e2e91;
    background: #eee5f8;
    font-size: 0.72rem;
    font-weight: 600;
}

.delegation-choice {
    background: #fbfafd;
}

.switch-choice {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
}

.switch-choice input {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin-top: 2px;
    accent-color: var(--roxo-principal);
}

.switch-choice strong,
.switch-choice small {
    display: block;
}

.switch-choice strong {
    color: var(--cinza-escuro);
    font-weight: 600;
}

.switch-choice small {
    margin-top: 4px;
    color: var(--cinza-medio);
    font-weight: 400;
}

.delegated-user-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
    padding: 18px;
    border: 1px solid #ded8e7;
    border-left: 3px solid var(--roxo-principal);
    border-radius: 8px;
    background: #fbfafd;
}

.delegated-user-panel[hidden] {
    display: none;
}

.delegation-note {
    grid-column: 1 / -1;
    margin: 0;
    color: #665f6d;
    font-size: 0.88rem;
    line-height: 1.5;
}

.confirmation-dialog {
    width: min(92vw, 510px);
    max-height: 90vh;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
}

.confirmation-dialog::backdrop {
    background: rgba(31, 24, 38, 0.58);
    backdrop-filter: blur(2px);
}

.confirmation-dialog__content {
    display: grid;
    gap: 14px;
    margin: 0;
    padding: 26px;
    border: 1px solid #e1dce7;
    border-radius: 8px;
    background: var(--branco);
    box-shadow: 0 22px 60px rgba(28, 20, 38, 0.22);
}

.confirmation-dialog__content h2,
.confirmation-dialog__content p {
    margin: 0;
}

.confirmation-dialog__content h2 {
    font-size: 1.35rem;
    font-weight: 600;
}

.confirmation-dialog__content p {
    color: var(--cinza-medio);
    line-height: 1.6;
}

.confirmation-dialog__icon {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 50%;
    color: var(--roxo-principal);
    background: #eee7f8;
    font-size: 1.45rem;
    font-weight: 600;
}

.confirmation-dialog__icon.danger {
    color: #a52f3c;
    background: #fbe8eb;
}

.confirmation-dialog__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 4px;
}

.approval-metrics {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
}

.approval-filter {
    grid-template-columns: repeat(4, minmax(150px, 1fr));
}

.approval-filter .filter-actions {
    grid-column: 1 / -1;
    justify-content: flex-end;
}

.approval-table {
    min-width: 1180px;
}

.approval-badge,
.email-delivery {
    display: inline-flex;
    min-height: 26px;
    align-items: center;
    padding: 0 9px;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 600;
    white-space: nowrap;
}

.approval-pending {
    color: #6d5011;
    background: #fff3c9;
}

.approval-approved {
    color: #17653b;
    background: #e2f5ea;
}

.approval-rejected {
    color: #932b38;
    background: #fbe5e8;
}

.email-sent {
    color: #17653b;
    background: #e2f5ea;
}

.email-no_recipient,
.email-not_configured,
.email-error {
    color: #932b38;
    background: #fbe5e8;
}

.email-pending {
    color: var(--cinza-medio);
    background: #efedf1;
}

.table-meta {
    display: block;
    margin-top: 5px;
    color: var(--cinza-medio);
    font-size: 0.74rem;
    font-weight: 400;
    white-space: nowrap;
}

.approval-actions {
    min-width: 210px;
}

.approval-summary {
    border-left: 4px solid #d7a921;
}

.approval-summary.approval-approved {
    border-left-color: var(--verde-principal);
}

.approval-summary.approval-rejected {
    border-left-color: var(--vermelho);
}

.approval-summary__heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}

.approval-summary__heading h2 {
    margin: 0 0 7px;
    font-size: 1.25rem;
    font-weight: 600;
}

.approval-summary__heading p {
    margin: 0;
    color: var(--cinza-medio);
    line-height: 1.55;
}

.approval-summary__heading p strong {
    color: var(--cinza-escuro);
    font-weight: 600;
}

.approval-decision-list {
    margin-top: 18px;
}

.public-approval-page {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 24px;
    background: #f4f5f7;
}

.public-approval-card {
    width: min(100%, 560px);
    padding: 32px;
    border: 1px solid #e0dce5;
    border-top: 5px solid var(--roxo-principal);
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 18px 48px rgba(32, 22, 48, 0.12);
}

.public-approval-card h1 {
    margin: 12px 0 10px;
    font-size: 1.75rem;
    font-weight: 600;
}

.public-approval-card > p {
    margin: 0 0 22px;
    color: var(--cinza-medio);
    line-height: 1.65;
}

.public-approval-brand {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 22px;
    color: var(--roxo-principal);
    font-size: 1.25rem;
    font-weight: 600;
}

.public-approval-brand small {
    color: var(--verde-escuro);
    font-size: 1rem;
}

.public-approval-details {
    display: grid;
    gap: 12px;
    margin: 0 0 22px;
    padding: 18px;
    border: 1px solid #e6e2ea;
    border-radius: 8px;
    background: #faf9fc;
}

.public-approval-details div {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 12px;
}

.public-approval-details dt {
    color: var(--cinza-medio);
    font-size: 0.78rem;
    font-weight: 500;
    text-transform: uppercase;
}

.public-approval-details dd {
    margin: 0;
    color: var(--cinza-escuro);
    font-weight: 500;
}

.public-approval-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.result-card {
    text-align: center;
}

.result-icon {
    display: grid;
    width: 58px;
    height: 58px;
    margin: 0 auto 18px;
    place-items: center;
    border-radius: 50%;
    color: var(--roxo-principal);
    background: #eee7f8;
    font-size: 1.7rem;
    font-weight: 600;
}

.result-icon.success {
    color: #17653b;
    background: #e2f5ea;
}

.result-icon.danger {
    color: #932b38;
    background: #fbe5e8;
}

.public-approval-footer {
    display: block;
    margin-top: 24px;
    color: var(--cinza-medio);
    font-size: 0.75rem;
    font-weight: 500;
}

@media (max-width: 1180px) {
    .metric-grid {
        grid-template-columns: repeat(3, minmax(170px, 1fr));
    }

    .filter-bar {
        grid-template-columns: repeat(2, minmax(150px, 1fr));
    }

    .agenda-board {
        grid-template-columns: repeat(2, minmax(230px, 1fr));
    }

    .finance-filter {
        grid-template-columns: repeat(2, minmax(150px, 1fr));
    }

    .filter-actions {
        grid-column: 1 / -1;
    }

    .presentation-kpis {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .app-shell {
        grid-template-columns: 1fr;
    }

    html.sidebar-collapsed .app-shell {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: fixed;
        z-index: 20;
        width: min(82vw, 300px);
        transform: translateX(-105%);
        transition: transform 0.22s ease;
    }

    html.sidebar-collapsed .sidebar {
        padding: 24px;
    }

    html.sidebar-collapsed .sidebar .brand,
    html.sidebar-collapsed .nav-link,
    html.sidebar-collapsed .sidebar-settings,
    html.sidebar-collapsed .sidebar-footer .sidebar-logout {
        justify-content: flex-start;
    }

    html.sidebar-collapsed .brand-text,
    html.sidebar-collapsed .nav-link span,
    html.sidebar-collapsed .sidebar-footer span {
        display: initial;
    }

    .sidebar-collapse {
        display: none;
    }

    body.nav-open .sidebar {
        transform: translateX(0);
    }

    body.nav-open .mobile-backdrop {
        position: fixed;
        inset: 0;
        z-index: 15;
        display: block;
        background: rgba(25, 19, 35, 0.42);
    }

    .mobile-menu-toggle {
        display: inline-grid;
        place-items: center;
        flex: 0 0 auto;
    }

    .topbar {
        padding: 0 18px;
    }

    .topbar > div:first-of-type span {
        display: none;
    }

    .content {
        padding: 22px 16px;
    }

    .page-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .page-actions {
        justify-content: flex-start;
    }

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

    .profile-grid,
    .detail-grid {
        grid-template-columns: 1fr;
    }

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

    .notification-preview-grid {
        grid-template-columns: 1fr;
    }

    .ranking-grid,
    .ranking-chart-grid,
    .ranking-metrics {
        grid-template-columns: 1fr;
    }

    .report-analysis-grid {
        grid-template-columns: 1fr;
    }

    .presentation-page {
        min-height: 0;
    }

    .presentation-kpis {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        margin-top: 26px;
    }

    .agenda-board,
    .agenda-metrics {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .auth-wrapper {
        padding: 18px;
    }

    .auth-card {
        padding: 24px;
    }

    .auth-card h1,
    .page-heading h1 {
        font-size: 1.55rem;
    }

    .metric-grid,
    .filter-bar {
        grid-template-columns: 1fr;
    }

    .settings-grid,
    .stale-summary-grid,
    .seller-detail-summary,
    .tag-report-filter,
    .presentation-kpis,
    .presentation-columns {
        grid-template-columns: 1fr;
    }

    .report-pagination {
        align-items: stretch;
        flex-direction: column;
    }

    .report-pagination > div {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .profile-stats-grid {
        grid-template-columns: 1fr;
    }

    .finance-filter {
        grid-template-columns: 1fr;
    }

    .metric-card {
        min-height: 104px;
    }

    .topbar-user span {
        display: none;
    }

    .topbar-user .avatar,
    .topbar-user .notification-link strong {
        display: inline-grid;
    }

    .notification-link span {
        display: inline;
    }

    .user-dropdown {
        right: -6px;
        min-width: 176px;
    }

    .filter-actions,
    .form-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .tag-report-filter .secondary-button {
        width: 100%;
    }

    .primary-action,
    .primary-button,
    .secondary-button,
    .ghost-button {
        width: 100%;
    }

    .page-actions {
        width: 100%;
    }

    .report-email-action {
        width: 100%;
    }

    .report-email-popover {
        position: static;
        width: 100%;
        margin-top: 10px;
        box-shadow: none;
    }

    .presentation-toolbar {
        position: static;
    }

    .presentation-page {
        padding: 24px;
    }

    .presentation-cover h2 {
        font-size: 2rem;
    }

    .presentation-ranking > div:not(.empty-panel) {
        grid-template-columns: minmax(100px, 0.8fr) minmax(90px, 1fr) 38px;
        gap: 8px;
        font-size: 0.82rem;
    }

    .presentation-stale-kpis {
        grid-template-columns: 1fr;
    }

    .presentation-stale-list > div:not(.empty-panel) {
        grid-template-columns: minmax(90px, 1fr) minmax(80px, 0.8fr) 64px;
        gap: 8px;
    }

    .presentation-stale-list small {
        display: none;
    }

    .inline-status-form {
        grid-template-columns: 1fr;
        min-width: 260px;
    }

    .tag-table-cell {
        min-width: 240px;
    }

    .tag-form {
        grid-template-columns: 1fr;
    }

    .tag-form button {
        width: 100%;
    }

    .admin-user-form {
        grid-template-columns: 1fr;
        min-width: 260px;
    }

    .ranking-chart-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .ranking-line-chart {
        grid-template-columns: 34px minmax(0, 1fr);
        grid-template-rows: 180px auto;
        column-gap: 6px;
    }

    .ranking-line-labels div {
        padding: 0 2px;
    }

    .ranking-line-labels strong {
        font-size: 0.68rem;
    }

    .ranking-line-labels span {
        font-size: 0.62rem;
    }

    .ranking-column-chart {
        gap: 6px;
    }

    .ranking-column-item {
        grid-template-rows: 22px 150px 42px;
    }

    .ranking-column-track {
        width: min(100%, 34px);
        height: 150px;
    }

    .delegated-user-panel,
    .approval-filter,
    .approval-metrics {
        grid-template-columns: 1fr;
    }

    .confirmation-dialog__content,
    .public-approval-card {
        padding: 22px;
    }

    .confirmation-dialog__actions,
    .public-approval-actions,
    .approval-summary__heading {
        align-items: stretch;
        flex-direction: column;
    }

    .public-approval-details div {
        grid-template-columns: 1fr;
        gap: 4px;
    }
}
