/* =============================================================================
   100porcentoWP — painel
   -----------------------------------------------------------------------------
   Layout reproduzido dos prints da produção: sidebar CLARA com seções
   agrupadas, barra superior com busca e notificações, conteúdo em cinza muito
   claro. A paleta e a tipografia vêm do site institucional — mesmo azul de
   marca, Space Grotesk nos títulos e Inter no corpo.
   ========================================================================== */

:root {
    /* -------------------------------------------------------------------
       UMA ESCALA SO, TODA NA MESMA MATIZ

       Antes o fundo era #f7f8fa e os cards #ffffff: tres por cento de
       diferenca. Nada se destacava de nada, e a tela lia como uma folha
       branca. Pior, os cinzas eram neutros puros -- sem parentesco nenhum
       com o azul da marca, que ficava solto por cima em vez de pertencer.

       Agora todo neutro nasce da matiz 235, a mesma do azul, com croma
       baixinho. O azul deixa de ser um detalhe aplicado e passa a ser a
       temperatura do painel inteiro.

       Os passos de claridade sao regulares de proposito (oklch mede
       claridade como o olho percebe, ao contrario de hsl): e isso que faz
       a escala parecer harmoniosa em vez de uma colecao de tons.
       ------------------------------------------------------------------- */

    /* Marca */
    --brand:        oklch(62% .13 235);
    --brand-strong: oklch(52% .13 238);
    --brand-soft:   oklch(94.5% .030 235);
    --brand-wash:   oklch(97% .018 235);
    --brand-ink:    #ffffff;

    /* TRES AZUIS, TRES TRABALHOS

       --brand         identidade. Icone, borda, realce. Sobre branco da
                       3,56:1 — o bastante para elemento grafico (min 3), e
                       NAO o bastante para palavra que precisa ser lida.
       --brand-strong  onde ha texto: como cor de letra sobre fundo claro, e
                       como fundo de botao com letra branca. 5,3:1 nos dois
                       sentidos.
       --brand-deep    so o hover do botao, para o clique ter resposta.

       O botao primario sempre foi dificil de ler — usava --brand com letra
       branca. Ninguem tinha medido. A marca continua a mesma; o que mudou foi
       parar de usa-la onde ela nao da conta. */
    --brand-deep:   oklch(43% .12 238);

    /* Superficies, do fundo para a frente.
       Quatro planos distinguiveis onde antes havia dois. */
    --bg:        oklch(96.2% .010 235);   /* o chao do conteudo   */
    --sidebar:   oklch(98%   .008 235);   /* navegacao            */
    --surface:   #ffffff;                 /* cards e paineis      */
    --surface-2: oklch(98.2% .006 235);   /* campos, listras      */
    --surface-3: oklch(94.8% .014 235);   /* hover, pocos         */
    --surface-4: oklch(92%   .019 235);   /* trilhos, vazios      */

    /* Texto — o quase-preto tambem puxa para o azul, senao destoa */
    --text:       oklch(24% .028 250);
    --text-2:     oklch(40% .024 248);
    --text-muted: oklch(52% .020 245);
    --text-faint: oklch(60% .017 243);

    --border:      oklch(90% .015 235);
    --border-soft: oklch(94.5% .009 235);

    /* A borda de CAMPO precisa ser mais escura que a de divisao. --border da
       1,34:1 sobre branco: serve para separar blocos, mas nao para dizer onde
       um campo comeca e termina — quem enxerga pouco simplesmente nao ve o
       contorno. A regra pede 3:1 para o contorno de controle. */
    --field-border: oklch(66% .025 240);

    /* Estado — croma alto o bastante para nao sumir no azul de fundo,
       e cada fundo puxado para a propria matiz, nao para o cinza. */
    --ok:       oklch(56% .14 152);
    --ok-bg:    oklch(95% .045 152);
    --warn:     oklch(52% .13 68);
    --warn-bg:  oklch(95.5% .05 75);
    --alert:    oklch(53% .18 25);
    --alert-bg: oklch(95.5% .04 25);

    --radius:    10px;
    --radius-lg: 14px;

    /* Sombra azulada, nao preta: sombra cinza sobre fundo azulado
       acinzenta o que esta embaixo dela. */
    --shadow-sm: 0 1px 2px oklch(45% .06 240 / .07);
    --shadow:    0 1px 3px oklch(45% .06 240 / .10),
                 0 1px 2px oklch(45% .06 240 / .06);
    --shadow-md: 0 4px 16px -6px oklch(45% .07 240 / .18);

    --sidebar-w: 250px;
    --topbar-h:  62px;

    --font:    "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --display: "Space Grotesk", var(--font);
    --mono:    ui-monospace, "SF Mono", Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 14px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }

.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 8px; top: 8px; z-index: 100; padding: 10px 16px;
    background: var(--text); color: #fff; border-radius: var(--radius); }

/* =============================== ESTRUTURA ================================ */

.app { display: flex; min-height: 100vh; }

.sidebar {
    width: var(--sidebar-w); flex-shrink: 0;
    /* Nao e branca. Branco na sidebar, branco na topbar e branco nos cards
       fazia tres planos virarem um so. */
    background: var(--sidebar); border-right: 1px solid var(--border);
    display: flex; flex-direction: column;
    position: sticky; top: 0; height: 100vh;
}

.content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.main { flex: 1; padding: 26px 30px 60px; max-width: 1500px; width: 100%; }

/* --------------------------------------------------------------- marca --- */

.brand { display: flex; align-items: center; gap: 11px; padding: 18px 16px; }

.brand__logo {
    width: 38px; height: 38px; border-radius: 11px; flex-shrink: 0;
    display: grid; place-items: center; overflow: hidden;
    background: linear-gradient(135deg, var(--brand), var(--brand-strong));
}
.brand__logo img { width: 26px; height: 26px; object-fit: contain; }

.brand__name { font-family: var(--display); font-weight: 700; font-size: 15px;
    letter-spacing: -.01em; line-height: 1.2; }
.brand__org { font-size: 12px; color: var(--text-muted); line-height: 1.3; }

/* ---------------------------------------------------------------- menu --- */

.side-nav { flex: 1; overflow-y: auto; padding: 4px 12px 12px; }

.side-nav__section {
    font-size: 10.5px; font-weight: 700; letter-spacing: .09em;
    /* --text-muted, nao --text-faint: sao 10,5px em caixa alta, e caixa alta
       pequena e o pior caso de leitura que existe numa interface. */
    text-transform: uppercase; color: var(--text-muted); padding: 16px 10px 7px;
}

.side-nav__link {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding: 9px 10px; margin-bottom: 1px; border-radius: 8px;
    color: var(--text-2); font-weight: 500; font-size: 13.5px;
    transition: background .13s ease, color .13s ease;
}
.side-nav__link > span { display: flex; align-items: center; gap: 11px; min-width: 0; }
.side-nav__link:hover { background: var(--surface-3); color: var(--text); }

/* Ativo em azul, nao em cinza. O cinza dizia apenas "algo aqui esta
   diferente"; o azul diz "voce esta aqui" — e traz a marca para dentro da
   navegacao, que e onde o olho passa o tempo todo. */
.side-nav__link--active {
    background: var(--brand-soft); color: var(--brand-strong); font-weight: 600;
}
.side-nav__link--active .side-nav__icon svg { stroke: var(--brand); }

.side-nav__icon svg { width: 17px; height: 17px; flex-shrink: 0; fill: none;
    stroke: var(--text-muted); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.side-nav__badge {
    min-width: 21px; padding: 1px 7px; border-radius: 999px;
    background: var(--surface-3); color: var(--text-2);
    font-size: 11px; font-weight: 700; text-align: center;
}
.side-nav__link--active .side-nav__badge { background: var(--brand-strong); color: #fff; }

/* --------------------------------------------------------- rodapé user --- */

.sidebar__user { display: flex; align-items: center; gap: 10px;
    padding: 12px 16px; border-top: 1px solid var(--border); }
.avatar { width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
    display: grid; place-items: center;
    background: var(--brand-strong); color: #fff; font-weight: 700; font-size: 13px; }
.sidebar__user-name { font-size: 13px; font-weight: 600; line-height: 1.2; }
.sidebar__user-state { font-size: 11.5px; color: var(--text-muted); }

/* -------------------------------------------------------------- topbar --- */

.topbar { height: var(--topbar-h); flex-shrink: 0;
    /* Branca de proposito: entre a sidebar tingida e o chao tingido, ela e
       o que separa os dois. */
    background: var(--surface); border-bottom: 1px solid var(--border);
    display: flex; align-items: center; gap: 14px; padding: 0 24px;
    position: sticky; top: 0; z-index: 30; }

.topbar__toggle { width: 32px; height: 32px; border: 0; background: transparent;
    cursor: pointer; border-radius: 7px; display: grid; place-items: center;
    color: var(--text-muted); }
.topbar__toggle:hover { background: var(--surface-3); color: var(--text); }
.topbar__toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor;
    stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.search { position: relative; flex: 1; max-width: 460px; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
    width: 16px; height: 16px; fill: none; stroke: var(--text-faint);
    stroke-width: 1.8; stroke-linecap: round; }
.search input { width: 100%; padding: 9px 12px 9px 36px;
    border: 1px solid var(--field-border); border-radius: 9px;
    background: var(--surface-2); color: var(--text); font: inherit; font-size: 13.5px; }
.search input::placeholder { color: var(--text-faint); }
.search input:focus { outline: none; background: var(--surface);
    border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }

.topbar__spacer { flex: 1; }

.bell { position: relative; width: 38px; height: 38px; border-radius: 9px;
    border: 1px solid transparent; background: transparent; cursor: pointer;
    display: grid; place-items: center; color: var(--text-muted); }
.bell:hover { background: var(--surface-3); color: var(--text); }
.bell svg { width: 19px; height: 19px; fill: none; stroke: currentColor;
    stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.bell__count { position: absolute; top: 4px; right: 4px; min-width: 17px; height: 17px;
    padding: 0 4px; border-radius: 999px; background: var(--alert); color: #fff;
    font-size: 10.5px; font-weight: 700; display: grid; place-items: center; }

/* --------------------------------------------------------- notificações -- */

.notifs { position: absolute; right: 0; top: calc(100% + 8px); width: 340px;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius-lg); box-shadow: 0 16px 40px -12px rgba(16,24,40,.22);
    z-index: 40; overflow: hidden; }
.notifs[hidden] { display: none; }
.notifs__head { display: flex; align-items: center; justify-content: space-between;
    padding: 13px 16px; border-bottom: 1px solid var(--border); font-weight: 600; }
.notifs__list { max-height: 380px; overflow-y: auto; }
.notif { display: flex; gap: 11px; padding: 13px 16px; border-bottom: 1px solid var(--border-soft); }
.notif:last-child { border-bottom: 0; }
.notif__icon { flex-shrink: 0; margin-top: 1px; }
.notif__icon svg { width: 19px; height: 19px; fill: none; stroke: currentColor;
    stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.notif--error .notif__icon { color: var(--alert); }
.notif--warn  .notif__icon { color: var(--warn); }
.notif--info  .notif__icon { color: var(--brand-strong); }
.notif__title { font-weight: 600; font-size: 13px; }
.notif__text { font-size: 12px; color: var(--text-muted); line-height: 1.45; }
.notif__when { font-size: 11px; color: var(--text-faint); margin-top: 3px; }

/* ============================== CABEÇALHO ================================= */

.page-head { display: flex; align-items: flex-start; justify-content: space-between;
    gap: 20px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head h1 { margin: 0; font-family: var(--display); font-size: 25px;
    font-weight: 700; letter-spacing: -.025em; display: flex; align-items: center; gap: 10px; }
.page-head__sub { margin: 3px 0 0; color: var(--text-muted); font-size: 13.5px; }
.page-head__back { display: inline-flex; align-items: center; gap: 8px;
    color: var(--text-muted); font-size: 13px; }

/* ================================ CARDS ================================== */

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 16px; margin-bottom: 22px; }

.card { background: var(--surface); border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    border-radius: var(--radius-lg); padding: 18px 20px; box-shadow: var(--shadow-sm); }
.card__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.card__label { font-size: 11px; font-weight: 600; text-transform: uppercase;
    letter-spacing: .07em; color: var(--text-muted); }
.card__value { font-family: var(--display); font-size: 30px; font-weight: 700;
    line-height: 1.1; letter-spacing: -.03em; margin-top: 8px; }
.card__foot { margin-top: 8px; font-size: 12.5px; color: var(--text-muted);
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* Ícone em quadrado de cor suave, como nos prints. */
.card__icon { width: 38px; height: 38px; border-radius: 10px; flex-shrink: 0;
    display: grid; place-items: center; }
.card__icon svg { width: 19px; height: 19px; fill: none; stroke: currentColor;
    stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.card__icon--brand { background: var(--brand-soft); color: var(--brand); }

/* Card que leva a algum lugar.
   O que faz um bloco parecer clicavel nao e o cursor — ninguem passa o mouse
   em tudo para descobrir. E o comportamento: sobe um pouco, a borda ganha a
   cor da marca, e a seta aparece. */
.card--link { display: block; color: inherit; position: relative;
    transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease; }
.card--link:hover {
    transform: translateY(-2px);
    border-color: color-mix(in oklab, var(--brand) 40%, var(--border));
    box-shadow: var(--shadow-md);
}
.card--link::after {
    content: ""; position: absolute; right: 16px; bottom: 15px;
    width: 7px; height: 7px; border-right: 1.6px solid var(--text-faint);
    border-top: 1.6px solid var(--text-faint); transform: rotate(45deg);
    opacity: 0; transition: opacity .14s ease, right .14s ease;
}
.card--link:hover::after { opacity: 1; right: 12px; }
.card--link:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

/* Quem prefere menos movimento nao leva salto nenhum. */
@media (prefers-reduced-motion: reduce) {
    .card--link, .card--link::after { transition: none; }
    .card--link:hover { transform: none; }
}
.card__icon--warn  { background: var(--warn-bg);    color: var(--warn); }
.card__icon--alert { background: var(--alert-bg);   color: var(--alert); }
.card__icon--ok    { background: var(--ok-bg);      color: var(--ok); }

.panel { background: var(--surface); border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    border-radius: var(--radius-lg); padding: 20px 22px; margin-bottom: 20px;
    box-shadow: var(--shadow-sm); }
.panel--alert { border-color: #fecaca; background: #fffafa; }
.panel--brand { border-color: color-mix(in oklab, var(--brand) 28%, white);
    background: var(--brand-soft); }
.panel__head { display: flex; align-items: center; justify-content: space-between;
    gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.panel__head h2 { margin: 0; font-family: var(--display); font-size: 16px;
    font-weight: 700; display: flex; align-items: center; gap: 9px; }
.panel__hint { font-size: 12.5px; color: var(--text-muted); }
.panel__note { margin: 12px 0 0; font-size: 12.5px; color: var(--text-muted); }

.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; }

/* =============================== TABELAS ================================= */

.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table th, .table td { padding: 13px 12px; text-align: left;
    border-bottom: 1px solid var(--border-soft); }
.table thead th { font-size: 10.5px; text-transform: uppercase; letter-spacing: .07em;
    color: var(--text-muted); font-weight: 600; border-bottom: 1px solid var(--border); }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: var(--surface-2); }
.table .num { text-align: right; }
.table__site { font-weight: 600; }
.table__url { font-size: 12px; color: var(--text-muted); }
.mono { font-family: var(--mono); font-size: 12px; color: var(--text-muted); }

/* ================================ PILLS ================================== */

.pill { display: inline-flex; align-items: center; gap: 5px;
    padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600;
    border: 1px solid var(--border); background: var(--surface-2);
    color: var(--text-muted); white-space: nowrap; }
.pill svg { width: 13px; height: 13px; fill: none; stroke: currentColor;
    stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.pill--ok    { border-color: #bbf7d0; color: var(--ok);    background: var(--ok-bg); }
.pill--warn  { border-color: oklch(85% .10 75); color: var(--warn);  background: var(--warn-bg); }
.pill--alert { border-color: #fecaca; color: var(--alert); background: var(--alert-bg); }
.pill--brand { border-color: color-mix(in oklab, var(--brand) 35%, white);
    color: var(--brand-strong); background: var(--brand-soft); }

.badge-count { display: inline-grid; place-items: center; min-width: 22px; height: 22px;
    padding: 0 6px; border-radius: 999px; background: var(--warn-bg);
    color: var(--warn); border: 1px solid #fde68a; font-size: 11.5px; font-weight: 700; }

.icon-ok, .icon-alert { display: inline-flex; }
.icon-ok { color: var(--ok); }
.icon-alert { color: var(--alert); }
.icon-ok svg, .icon-alert svg { width: 17px; height: 17px; fill: none;
    stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ================================= ABAS ================================== */

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border);
    margin-bottom: 20px; overflow-x: auto; }
.tab { display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px;
    border-radius: 8px 8px 0 0; white-space: nowrap; color: var(--text-muted);
    font-size: 13.5px; font-weight: 500; border-bottom: 2px solid transparent; }
.tab:hover { color: var(--text); background: var(--surface-2); }
.tab--active { color: var(--brand-strong); border-bottom-color: var(--brand); font-weight: 600; }
.tab svg { width: 15px; height: 15px; fill: none; stroke: currentColor;
    stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tab__count { font-size: 11px; font-weight: 700; padding: 1px 6px;
    border-radius: 999px; background: var(--surface-3); color: var(--text-muted); }
.tab--active .tab__count { background: var(--brand-soft); color: var(--brand-strong); }

/* ============================== FORMULÁRIOS ============================== */

.form { display: flex; flex-direction: column; gap: 15px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span, .field label { font-size: 12.5px; font-weight: 600; color: var(--text-2); }

.field input, .field select, .field textarea, .input {
    width: 100%; padding: 10px 12px; border: 1px solid var(--field-border);
    border-radius: 9px; background: var(--surface); color: var(--text);
    font: inherit; font-size: 13.5px;
}
.field input:focus, .field select:focus, .field textarea:focus, .input:focus {
    outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft);
}
.field__hint { font-size: 11.5px; color: var(--text-muted); font-weight: 400; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 10px 17px; border: 1px solid transparent; border-radius: 9px;
    font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer;
    transition: background .14s ease, border-color .14s ease, color .14s ease; }
.btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor;
    stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.btn--primary { background: var(--brand-strong); color: var(--brand-ink); }
.btn--primary:hover { background: var(--brand-deep); }
.btn--ghost { background: var(--surface); border-color: var(--border); color: var(--text-2); }
.btn--ghost:hover { border-color: var(--text-faint); color: var(--text); }
.btn--danger { background: var(--alert); color: #fff; }
.btn--soft-danger { background: var(--alert-bg); color: var(--alert); border-color: #fecaca; }
.btn--block { width: 100%; }
.btn--sm { padding: 6px 12px; font-size: 12.5px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btn[data-ocupado][aria-busy="true"] { opacity: .6; cursor: progress; }

.link { color: var(--brand-strong); font-weight: 600; }
.link:hover { text-decoration: underline; }

/* ------------------------------------------------------------ interruptor */

.switch { position: relative; display: inline-block; width: 42px; height: 24px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch__slider { position: absolute; inset: 0; cursor: pointer;
    background: #d1d5db; border-radius: 999px; transition: background .18s ease; }
.switch__slider::before { content: ""; position: absolute; height: 18px; width: 18px;
    left: 3px; bottom: 3px; background: #fff; border-radius: 50%;
    transition: transform .18s ease; box-shadow: var(--shadow-sm); }
.switch input:checked + .switch__slider { background: var(--brand); }
.switch input:checked + .switch__slider::before { transform: translateX(18px); }

/* Linha com título, descrição e controle à direita. */
.setting-row { display: flex; align-items: center; justify-content: space-between;
    gap: 16px; padding: 15px 17px; border: 1px solid var(--border);
    border-radius: var(--radius); margin-bottom: 12px; }
.setting-row__title { font-weight: 600; font-size: 13.5px; }
.setting-row__desc { font-size: 12.5px; color: var(--text-muted); }

/* =============================== AVISOS ================================== */

.flash { padding: 12px 15px; border-radius: var(--radius); margin-bottom: 16px;
    font-size: 13.5px; border: 1px solid; }
.flash--error   { background: var(--alert-bg); border-color: #fecaca; color: #991b1b; }
.flash--success { background: var(--ok-bg);    border-color: #bbf7d0; color: #166534; }
.flash--info    { background: var(--brand-soft);
    border-color: color-mix(in oklab, var(--brand) 30%, white); color: var(--brand-strong); }

.empty { color: var(--text-muted); font-size: 13.5px; }

/* =============================== UPTIME ================================== */

.uptime-bars { display: flex; gap: 3px; align-items: stretch; height: 46px; }
.uptime-bars__day { flex: 1; min-width: 4px; border-radius: 3px; background: var(--ok); }
.uptime-bars__day--down    { background: var(--alert); }
.uptime-bars__day--partial { background: var(--warn); }
.uptime-bars__day--none    { background: var(--surface-3); }
.uptime-legend { display: flex; justify-content: space-between;
    font-size: 11.5px; color: var(--text-faint); margin-top: 7px; }

/* ============================ BARRA DE USO =============================== */

.usage { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 22px; }
.usage__head { display: flex; justify-content: space-between; align-items: baseline;
    font-size: 12.5px; margin-bottom: 7px; }
.usage__label { color: var(--text-muted); }
.usage__value { font-weight: 600; }
.usage__track { height: 7px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.usage__fill { height: 100%; border-radius: 999px; background: var(--brand); }
.usage__fill--warn  { background: var(--warn); }
.usage__fill--alert { background: var(--alert); }

/* ============================== LINHA DO TEMPO =========================== */

.steps { display: flex; align-items: flex-start; gap: 0; margin: 20px 0 4px; }
.step { flex: 1; display: flex; flex-direction: column; align-items: center;
    position: relative; text-align: center; }
.step__dot { width: 30px; height: 30px; border-radius: 50%; display: grid;
    place-items: center; font-size: 12px; font-weight: 700; z-index: 1;
    background: var(--surface-3); color: var(--text-faint);
    border: 2px solid var(--surface-3); }
.step--done .step__dot { background: var(--brand); color: #fff; border-color: var(--brand); }
.step--done .step__dot svg { width: 15px; height: 15px; fill: none; stroke: currentColor;
    stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.step__label { margin-top: 8px; font-size: 12px; color: var(--text-muted); }
.step--done .step__label { color: var(--text); font-weight: 600; }
/* A linha liga um passo ao seguinte. */
.step:not(:last-child)::after { content: ""; position: absolute; top: 14px;
    left: 50%; width: 100%; height: 2px; background: var(--surface-3); }
.step--done:not(:last-child)::after { background: var(--brand); }

/* ================================ MODAL ================================== */

.modal { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center;
    background: rgba(17, 24, 39, .5); padding: 20px; }
.modal[hidden] { display: none; }
.modal__card { background: var(--surface); border-radius: var(--radius-lg);
    width: 100%; max-width: 470px; padding: 24px;
    box-shadow: 0 24px 60px -18px rgba(16,24,40,.4); }
.modal__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.modal__title { font-family: var(--display); font-size: 17px; font-weight: 700; margin: 0; }
.modal__sub { font-size: 13px; color: var(--text-muted); margin: 4px 0 18px; }
.modal__close { border: 0; background: transparent; cursor: pointer; font-size: 20px;
    line-height: 1; color: var(--text-faint); padding: 0 2px; }
.modal__close:hover { color: var(--text); }
.modal__acoes { display: flex; gap: 8px; justify-content: flex-end; margin-top: 18px; }

/* ------------------------------------------------------- barra de progresso */

/* O cartao do progresso e mais largo que um modal comum: ele lista sites, e
   nome de site nao cabe em 380px sem quebrar em duas linhas cada um. */
.modal__card--progresso { max-width: 520px; }
.modal__card--confirmar { max-width: 420px; }

.prog__topo { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.prog__texto { min-width: 0; }
.prog__texto .modal__sub { margin: 4px 0 0; }

/* O anel e o numero dizem a mesma coisa de dois jeitos: um para o olho de
   longe, outro para quem quer o valor exato. */
.prog__anel { position: relative; width: 56px; height: 56px; flex-shrink: 0;
    display: grid; place-items: center; }

.prog__anel svg { position: absolute; inset: 0; width: 100%; height: 100%;
    transform: rotate(-90deg); }

.prog__anel circle { fill: none; stroke-width: 4; stroke-linecap: round; }
.prog__anel-trilho { stroke: var(--surface-3); }

.prog__anel-fill {
    stroke: var(--brand);
    /* 2 * pi * 19 = 119.38. O contorno inteiro vira um traco so, e o
       deslocamento controla quanto dele aparece. */
    stroke-dasharray: 119.38;
    stroke-dashoffset: 119.38;
    transition: stroke-dashoffset .45s ease;
}

.prog__anel b { position: relative; font-family: var(--display); font-size: 13px;
    font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }

.prog--pronto .prog__anel-fill { stroke: var(--ok); }
.prog--falhou .prog__anel-fill { stroke: var(--warn); }

.barra { position: relative; height: 8px; border-radius: 999px;
    background: var(--surface-3); overflow: hidden; }

/*
   O preenchimento cresce por `transform: scaleX`, e nao por `width`.

   Duas razoes, e a primeira e um bug de verdade: largura em PORCENTAGEM nao
   resolve enquanto o elemento esta dentro de um `display:none`. O modal nasce
   escondido, entao a transicao partia de um valor que o navegador nao sabia
   calcular e ficava presa em zero — a barra marcava 50% no numero e continuava
   vazia na tela.

   A segunda: `transform` nao provoca recalculo de layout a cada quadro, e
   `width` provoca.
*/
.barra__fill {
    height: 100%; width: 100%; border-radius: 999px;
    background: var(--brand);
    transform: scaleX(0); transform-origin: left center;
    transition: transform .45s ease, background-color .3s ease;
}

.prog--pronto .barra__fill { background: var(--ok); }
.prog--falhou .barra__fill { background: var(--warn); }

/*
   Enquanto ha trabalho, um brilho atravessa a barra da esquerda para a direita.

   Fica sobre o TRILHO, e nao sobre o preenchimento: o preenchimento e escalado
   horizontalmente, e qualquer textura nele sairia esticada na mesma proporcao.

   E nao e enfeite. Barra parada em 40% e barra travada em 40% sao visualmente
   identicas — o brilho e o que diz que o sistema ainda esta vivo.
*/
.barra--andando::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(90deg,
        transparent 0%, rgb(255 255 255 / .55) 50%, transparent 100%);
    width: 45%;
    animation: barra-brilho 1.4s ease-in-out infinite;
}

@keyframes barra-brilho {
    from { transform: translateX(-100%); }
    to   { transform: translateX(320%); }
}

/* ---------------------------------------------------- a lista de sites ---- */

/* 236px bastava quando cada site era uma linha. Com o motivo de cada plugin
   embaixo, um site sozinho pode ocupar dez linhas — e o que interessa ler são
   justamente as de baixo, as que falharam. Daí o teto maior, ainda preso ao
   tamanho da janela para o cartão nunca passar da tela. */
.prog__itens { list-style: none; margin: 18px 0 0; padding: 0;
    max-height: min(46vh, 400px); overflow-y: auto;
    display: flex; flex-direction: column; gap: 5px; }

.prog__itens li {
    display: flex; flex-direction: column; align-items: flex-start; gap: 0;
    font-size: 13px; padding: 9px 11px; border-radius: 8px;
    background: var(--surface-2); border: 1px solid transparent;
    transition: background .2s ease, border-color .2s ease;
}

.prog__itens li[data-estado="processing"] {
    background: var(--brand-soft);
    border-color: color-mix(in srgb, var(--brand) 28%, transparent);
}
.prog__itens li[data-estado="completed"] { background: var(--ok-bg); }
.prog__itens li[data-estado="failed"]    { background: var(--alert-bg); }

.prog__linha { display: flex; align-items: center; gap: 10px; width: 100%; }

.prog__site { font-weight: 600; color: var(--text); flex-shrink: 0;
    max-width: 42%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* O detalhe: um plugin ou tema por linha, com o motivo de quem falhou.
   Recuado sob o site a que pertence, porque um lote mexe em varios sites e a
   lista precisa dizer de qual e cada item. */
.prog__sub { list-style: none; margin: 8px 0 0; padding: 0 0 0 26px;
    display: flex; flex-direction: column; gap: 3px; }

.prog__sub:empty { display: none; }

.prog__sub li { display: flex; gap: 8px; font-size: 12px; line-height: 1.45;
    padding: 3px 0; }

.prog__sub b { flex-shrink: 0; font-weight: 600; color: var(--text-2);
    max-width: 40%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.prog__sub span { color: var(--text-muted); min-width: 0; }

/* A marca de cada item vem antes do nome, pelo ::before: uma tag a menos por
   linha, e sao dezenas de linhas. */
.prog__sub li::before { content: "\2713"; flex-shrink: 0; width: 12px;
    color: var(--ok); font-weight: 700; }
.prog__sub li[data-ok="0"]::before { content: "\00d7"; color: var(--alert); }
.prog__sub li[data-ok="0"] span { color: var(--alert); }
.prog__msg { color: var(--text-muted); min-width: 0; overflow: hidden;
    text-overflow: ellipsis; white-space: nowrap; }

/* O marcador de estado: um circulo que gira enquanto trabalha, vira certo
   quando termina, vira x quando falha. Cor sozinha nao basta — quem nao
   distingue verde de vermelho precisa da FORMA. */
.prog__marca { width: 16px; height: 16px; flex-shrink: 0; border-radius: 50%;
    display: grid; place-items: center; font-size: 10px; font-weight: 700;
    border: 1.6px solid var(--text-faint); color: transparent; }

li[data-estado="processing"] .prog__marca {
    border-color: var(--brand); border-top-color: transparent;
    animation: girando .7s linear infinite;
}
li[data-estado="completed"] .prog__marca {
    border-color: var(--ok); background: var(--ok); color: #fff;
}
li[data-estado="completed"] .prog__marca::before { content: "\2713"; }
li[data-estado="failed"] .prog__marca {
    border-color: var(--alert); background: var(--alert); color: #fff;
}
li[data-estado="failed"] .prog__marca::before { content: "\00d7"; font-size: 12px; }

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

@media (prefers-reduced-motion: reduce) {
    .barra--andando::after { animation: none; opacity: 0; }
    .barra__fill, .prog__anel-fill { transition: none; }
    li[data-estado="processing"] .prog__marca { animation: none; border-top-color: var(--brand); }
}

/* -------------------------------------------------------- site conectando --

   Um site recém-adicionado leva de dez a trinta segundos para responder pela
   primeira vez: o painel entra no wp-admin, instala o plugin e o ativa. Sem
   sinal nenhum na tela, esse intervalo parece travamento — e o cliente clica
   em adicionar de novo. */

.pill--conectando { color: var(--brand-strong); background: var(--brand-soft);
    border-color: color-mix(in srgb, var(--brand) 30%, transparent); }

.pulso { width: 8px; height: 8px; border-radius: 50%; background: var(--brand);
    flex-shrink: 0; position: relative; }

.pulso::after {
    content: ""; position: absolute; inset: 0; border-radius: 50%;
    background: var(--brand); animation: pulsa 1.4s ease-out infinite;
}

@keyframes pulsa {
    0%   { transform: scale(1);   opacity: .7; }
    100% { transform: scale(3.2); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .pulso::after { animation: none; }
    .barra--andando::after { animation: none; opacity: 0; }
    .barra__fill { transition: none; }
}
.modal__foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }

/* ============================== MENU ⋯ =================================== */

.rowmenu { position: relative; }

/* Botao de acoes da linha.
   Era transparente e cinza-claro: parecia decoracao, e ninguem clicava. Um
   controle so e clicavel quando parece clicavel ANTES do mouse chegar perto —
   por isso ele agora tem fundo, borda e a cor do texto normal. */
.rowmenu__toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 34px; height: 32px; cursor: pointer;
    /* --field-border, e nao --border: um controle precisa de 3:1 contra o que
       esta atras dele, e a borda de divisao da 1,34. Era esse o motivo de o
       botao "sumir" na linha. */
    border: 1px solid var(--field-border); border-radius: 8px;
    background: var(--surface-3); color: var(--text);
    font-size: 17px; line-height: 1; letter-spacing: .06em;
    transition: background .12s ease, border-color .12s ease, color .12s ease;
}
.rowmenu__toggle:hover,
.rowmenu__toggle[aria-expanded="true"] {
    background: var(--brand-soft); color: var(--brand-strong);
    border-color: color-mix(in srgb, var(--brand) 40%, var(--border));
}
.rowmenu__toggle:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.rowmenu__panel { position: absolute; right: 0; top: calc(100% + 4px); min-width: 168px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
    box-shadow: 0 12px 30px -10px rgba(16,24,40,.25); z-index: 25; padding: 5px; }
.rowmenu__panel[hidden] { display: none; }
.rowmenu__item { display: block; width: 100%; text-align: left; padding: 8px 11px;
    border: 0; background: transparent; border-radius: 7px; cursor: pointer;
    font: inherit; font-size: 13px; color: var(--text-2); }
.rowmenu__item:hover { background: var(--surface-3); }
.rowmenu__item--danger { color: var(--alert); }

/* =============================== AUTH ==================================== */

/* ======================= ENTRADA: LOGIN E CADASTRO ======================= */
/*
   Duas colunas. A da esquerda diz o que é isto para quem chegou de um anúncio;
   a da direita pede o e-mail. Nenhuma das duas custa um clique da outra.

   No celular a vitrine some: numa tela estreita, argumento em cima do
   formulário empurra o campo para fora da vista, e quem abriu para entrar
   teria que rolar até o que já sabia que queria fazer.
*/

.entrada { margin: 0; background: var(--bg); }

.entrada__grade { min-height: 100vh; min-height: 100dvh;
    display: grid; grid-template-columns: 1.05fr 1fr; }

.entrada__grade--so-forma { grid-template-columns: 1fr; }

/* ------------------------------------------------------------ vitrine --- */

.vitrine { position: relative; display: flex; flex-direction: column;
    justify-content: center; gap: 22px; padding: 56px clamp(32px, 5vw, 80px);
    color: #fff;
    /* O ponto mais claro do gradiente e o que decide a legibilidade: e ali que
       o texto claro tem menos contraste. Em 52% de claridade, o paragrafo dava
       3,94:1 e a linha do WhatsApp, 2,84 — abaixo dos 4,5 que texto precisa.
       Em 46% nada fica abaixo disso. */
    background:
        radial-gradient(120% 90% at 15% 10%, oklch(46% .14 238) 0%, transparent 55%),
        linear-gradient(155deg, oklch(36% .10 245) 0%, oklch(25% .07 250) 100%); }

.vitrine__voltar { position: absolute; top: 28px; left: clamp(32px, 5vw, 80px);
    font-size: 13px; font-weight: 500; color: oklch(88% .03 240);
    transition: color .13s ease; }
.vitrine__voltar:hover { color: #fff; }

.vitrine__titulo { margin: 0; font-family: var(--display);
    font-size: clamp(30px, 3.4vw, 46px); font-weight: 700; line-height: 1.1;
    letter-spacing: -.025em; }

.vitrine__texto { margin: 0; max-width: 44ch; font-size: 15.5px; line-height: 1.6;
    color: oklch(90% .025 240); }

.vitrine__lista { margin: 4px 0 0; padding: 0; list-style: none;
    display: flex; flex-direction: column; gap: 11px; }

.vitrine__lista li { position: relative; padding-left: 28px; font-size: 14.5px;
    color: oklch(93% .02 240); }

/* O tique é desenhado pelo ::before para a lista não precisar de um <span> por
   item — e para o texto quebrar alinhado, e não por baixo da marca. */
.vitrine__lista li::before { content: "✓"; position: absolute; left: 0; top: -1px;
    display: grid; place-items: center; width: 19px; height: 19px;
    border-radius: 50%; background: oklch(52% .13 235); color: #fff;
    font-size: 11px; font-weight: 700; }

/* 80% dava 3,63:1 sobre o ponto mais claro do fundo. Este da 4,72. */
.vitrine__rodape { margin: 18px 0 0; font-size: 13px; color: oklch(88% .03 240); }

/* -------------------------------------------------------- o formulário -- */

.entrada__forma { display: grid; place-items: center;
    padding: 48px clamp(20px, 4vw, 56px); background: var(--surface); }

.entrada__caixa { width: 100%; max-width: 400px; }

.entrada__marca { display: flex; align-items: center; gap: 10px; margin-bottom: 34px;
    font-family: var(--display); font-size: 17px; font-weight: 500;
    color: var(--text-2); letter-spacing: -.01em; }
.entrada__marca b { font-weight: 700; color: var(--text); }
.entrada__marca img { border-radius: 8px; }

.entrada__titulo { margin: 0; font-family: var(--display);
    font-size: 27px; font-weight: 700; letter-spacing: -.025em; line-height: 1.15; }

.entrada__sub { margin: 7px 0 0; font-size: 14.5px; color: var(--text-muted); }

.entrada__caixa .flash { margin-top: 20px; }

.entrada__rodape { margin-top: 26px; padding-top: 20px;
    border-top: 1px solid var(--border-soft);
    font-size: 14px; color: var(--text-muted); text-align: center; }

/* --------------------------------------------------------- os campos ---- */

.forma { display: flex; flex-direction: column; gap: 18px; margin-top: 26px; }

.campo { display: flex; flex-direction: column; gap: 7px; }

.campo__rotulo { display: flex; align-items: baseline; justify-content: space-between;
    gap: 12px; font-size: 13.5px; font-weight: 600; color: var(--text-2); }

.campo__ajuda { font-size: 13px; font-weight: 500; color: var(--brand-strong); }
.campo__ajuda:hover { text-decoration: underline; }

/* 48px de altura, e não os 38 do resto do painel.
   Estes são os únicos campos que alguém preenche antes de decidir se fica —
   e num celular, alvo pequeno é tentativa errada e desistência. */
.campo__entrada { width: 100%; height: 48px; padding: 0 15px;
    font: inherit; font-size: 15px; color: var(--text);
    background: var(--surface); border: 1px solid var(--field-border);
    border-radius: 10px; outline: none;
    transition: border-color .13s ease, box-shadow .13s ease; }

.campo__entrada::placeholder { color: var(--text-faint); }

.campo__entrada:focus { border-color: var(--brand);
    box-shadow: 0 0 0 3px color-mix(in oklab, var(--brand) 22%, transparent); }

/* O olho fica DENTRO do campo, e por isso a caixa existe: sem ela, o botão
   ficaria ao lado e o campo encolheria. */
.campo__caixa { position: relative; display: block; }
.campo__caixa .campo__entrada { padding-right: 46px; }

.campo__olho { position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
    display: grid; place-items: center; width: 36px; height: 36px;
    border: 0; background: transparent; border-radius: 8px; cursor: pointer;
    color: var(--text-muted); transition: color .13s ease, background .13s ease; }
.campo__olho:hover { color: var(--text); background: var(--surface-3); }
.campo__olho svg { width: 19px; height: 19px; fill: none; stroke: currentColor;
    stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* Riscado quando a senha está à mostra: a barra diz "clique para esconder"
   sem precisar de um segundo ícone. */
.campo__olho--aberto::after { content: ""; position: absolute; left: 8px; right: 8px;
    height: 1.8px; background: currentColor; transform: rotate(-45deg);
    border-radius: 2px; }

.forma__nota { margin: -4px 0 0; font-size: 13px; line-height: 1.5;
    color: var(--text-muted); text-align: center; }
.forma__nota--topo { margin: 0 0 -2px; text-align: left; }

.forma__conta { margin: 0; padding: 11px 14px; border-radius: 10px;
    background: var(--surface-2); border: 1px solid var(--border);
    font-size: 14px; color: var(--text-2); text-align: center; }

.forma__regra { margin: -8px 0 0; font-size: 12.5px; color: var(--text-muted); }
.forma__regra--ok { color: var(--ok); }
.forma__regra--erro { color: var(--alert); }

.btn--grande { height: 48px; padding: 0 22px; font-size: 15px; }

/* ---------------------------------------------------- aviso de meio ----- */

.aviso-grande { display: flex; flex-direction: column; align-items: center;
    gap: 14px; margin: 28px 0 22px; text-align: center; }

.aviso-grande__marca { display: grid; place-items: center; width: 58px; height: 58px;
    border-radius: 50%; background: var(--brand-soft); color: var(--brand-strong);
    font-size: 26px; }

.aviso-grande__texto { margin: 0; font-size: 15px; line-height: 1.6; color: var(--text-2); }
.aviso-grande__texto strong { color: var(--text); word-break: break-all; }

.aviso-grande__nota { margin: 0; font-size: 13px; line-height: 1.55;
    color: var(--text-muted); }

/* ------------------------------------------------------------- estreito - */

@media (max-width: 860px) {
    .entrada__grade { grid-template-columns: 1fr; }
    .vitrine { display: none; }
    .entrada__forma { padding: 32px 20px; align-items: start; }
    .entrada__caixa { padding-top: 8px; }
    .entrada__marca { margin-bottom: 26px; }
}

/* =========================== O ASSISTENTE ================================ */
/*
   Os três passos, na horizontal, com a linha ligando um ao outro.

   Estes estilos existiram, e sumiram numa substituição de bloco vizinha: sem
   eles o `<ol>` volta a ser o que um `<ol>` é, uma lista de cima para baixo.
   Ficaram fora de qualquer bloco que alguém vá substituir de novo.
*/

.onboard { max-width: 720px; margin: 0 auto; padding: 28px 20px 56px; }

.onboard__topo { display: flex; align-items: center; justify-content: space-between;
    gap: 16px; margin-bottom: 34px; }

.onboard__marca { font-family: var(--display); font-size: 16px; font-weight: 700;
    letter-spacing: -.02em; color: var(--text); }

/* ------------------------------------------------------- os três passos -- */

.passos { display: flex; align-items: flex-start; list-style: none;
    margin: 0 0 30px; padding: 0; }

/* Cada passo ocupa a mesma fração, e o texto fica sob a bolinha: é o que
   mantém as marcas alinhadas mesmo com "Adicionar site" sendo o dobro de
   "Pronto". */
.passo { position: relative; flex: 1; display: flex; flex-direction: column;
    align-items: center; gap: 8px; text-align: center; }

/* A linha que liga um passo ao seguinte sai do ::before do passo, e não de um
   elemento à parte: um `<li>` decorativo entre os passos apareceria na leitura
   de tela como um item de lista vazio. */
.passo::before { content: ""; position: absolute; top: 15px; left: calc(-50% + 17px);
    right: calc(50% + 17px); height: 2px; background: var(--border);
    transition: background .2s ease; }

.passo:first-child::before { display: none; }

/* A linha até um passo já feito fica verde: a cor conta o progresso junto com
   as bolinhas, e não depois delas. */
.passo--feito::before,
.passo--atual::before { background: var(--ok); }

.passo__bola { position: relative; z-index: 1; display: grid; place-items: center;
    width: 32px; height: 32px; border-radius: 50%;
    background: var(--surface); border: 2px solid var(--border);
    font-size: 13.5px; font-weight: 700; color: var(--text-muted);
    transition: background .2s ease, border-color .2s ease, color .2s ease; }

.passo__bola svg { width: 16px; height: 16px; fill: none; stroke: currentColor;
    stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }

.passo--feito .passo__bola { background: var(--ok); border-color: var(--ok); color: #fff; }

.passo--atual .passo__bola { background: var(--brand-strong); border-color: var(--brand-strong);
    color: #fff; }

.passo__nome { font-size: 13px; font-weight: 600; color: var(--text-muted);
    line-height: 1.3; max-width: 12ch; }

.passo--feito .passo__nome { color: var(--ok); }
.passo--atual .passo__nome { color: var(--text); }

/* --------------------------------------------------------- o conteúdo --- */

.onboard__cartao { padding: 30px 28px; }

.onboard__titulo { display: flex; align-items: center; gap: 10px; margin: 0;
    font-family: var(--display); font-size: 23px; font-weight: 700;
    letter-spacing: -.025em; line-height: 1.2; }

.onboard__titulo svg { width: 24px; height: 24px; flex-shrink: 0; fill: none;
    stroke: var(--ok); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.onboard__sub { margin: 9px 0 0; font-size: 14.5px; line-height: 1.6;
    color: var(--text-muted); }

/* ------------------------------------------------ o site que conectou --- */

.onboard__retrato { display: flex; flex-wrap: wrap; gap: 22px; margin-top: 24px;
    padding-top: 22px; border-top: 1px solid var(--border-soft); }

.onboard__thumb { width: 190px; height: 130px; flex-shrink: 0; border-radius: 10px; }

.onboard__dados { flex: 1; min-width: 240px; display: grid; gap: 2px 20px;
    grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 0; }

.onboard__dados > div { padding: 7px 0; border-bottom: 1px solid var(--border-soft); }
.onboard__dados dt { font-size: 11.5px; font-weight: 600; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: .04em; }
.onboard__dados dd { margin: 2px 0 0; font-size: 14px; font-weight: 600; color: var(--text); }

@media (max-width: 560px) {
    .onboard { padding: 20px 16px 40px; }
    .passo__nome { font-size: 11.5px; max-width: 9ch; }
    .onboard__cartao { padding: 22px 18px; }
    .onboard__dados { grid-template-columns: 1fr; }
}

/* Os formulários do assistente usam os campos grandes da entrada: é a mesma
   jornada, e trocar o tamanho do campo no meio dela faria a pessoa sentir que
   mudou de produto. */
.onboard__forma { display: flex; flex-direction: column; gap: 18px; margin-top: 22px; }
.onboard__acoes { display: flex; flex-wrap: wrap; gap: 10px; }
.onboard__forma .forma__regra { margin-top: -8px; }

/* ============================= ETAPAS ==================================== */

.etapas { list-style: none; margin: 0; padding: 0; }
.etapa { display: flex; align-items: center; gap: 10px; padding: 10px 0;
    font-size: 13px; border-bottom: 1px solid var(--border-soft); }
.etapa:last-child { border-bottom: 0; }
.etapa__marca { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0;
    background: var(--border); }
.etapa--ok   .etapa__marca { background: var(--ok); }
.etapa--fail .etapa__marca { background: var(--alert); }
.etapa--fail { color: var(--alert); }
.etapa__detalhe { margin-left: auto; font-size: 12px; color: var(--text-muted); text-align: right; }
.etapa--fail .etapa__detalhe { color: var(--alert); }

/* ============================ UTILITÁRIOS ================================ */

.muted { color: var(--text-muted); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }
.stack { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.dot--ok { background: var(--ok); } .dot--alert { background: var(--alert); }

/* ============================= RESPONSIVO ================================ */

@media (max-width: 980px) {
    .sidebar { position: fixed; left: 0; top: 0; z-index: 50;
        transform: translateX(-100%); transition: transform .2s ease; box-shadow: var(--shadow); }
    .app.is-open .sidebar { transform: translateX(0); }
    .main { padding: 20px 16px 40px; }
    .topbar { padding: 0 14px; }
    .search { max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition-duration: .001ms !important; }
}

/* ========================= ADMINISTRAÇÃO ================================= */
/* Barra escura de propósito: aqui se enxerga TODAS as agências, e a tela
   precisa deixar isso óbvio antes de alguém clicar em "Remover". */

.adminbar {
    display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
    padding: 11px 24px; background: #0b1020; color: #e5e7eb;
    position: sticky; top: 0; z-index: 40;
}
.adminbar__brand { display: flex; align-items: center; gap: 10px;
    font-family: var(--display); font-weight: 700; font-size: 14.5px; }
.adminbar__brand .brand__logo { width: 30px; height: 30px; border-radius: 8px; }
.adminbar__tag { font-family: var(--font); font-size: 11px; font-weight: 600;
    text-transform: uppercase; letter-spacing: .08em; padding: 3px 9px;
    border-radius: 999px; background: rgba(255,255,255,.12); color: #cbd5e1; }
.adminbar__user { font-size: 12.5px; color: #94a3b8; }
.adminbar .btn--ghost { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.16);
    color: #e5e7eb; }
.adminbar .btn--ghost:hover { background: rgba(255,255,255,.16); color: #fff; }

/* A faixa acompanha o rodapé da página inteira, não só o topo. */
body.admin { background: var(--bg); }

/* ============================ CARTÕES DE PLANO =========================== */

.planos { display: grid; gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); }

.plano { position: relative; display: flex; flex-direction: column;
    padding: 22px 20px; border: 1px solid var(--border);
    border-radius: var(--radius-lg); background: var(--surface); }
.plano--atual    { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.plano--destaque { border-color: color-mix(in oklab, var(--brand) 45%, white); }

.plano__fita { position: absolute; top: -10px; left: 20px; padding: 3px 10px;
    border-radius: 999px; background: var(--brand-strong); color: #fff;
    font-size: 10.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }

.plano__nome { font-family: var(--display); font-size: 17px; font-weight: 700; }
.plano__tagline { margin: 2px 0 14px; font-size: 12.5px; color: var(--text-muted); min-height: 32px; }
.plano__preco { font-family: var(--display); font-size: 30px; font-weight: 700;
    letter-spacing: -.03em; line-height: 1; }
.plano__preco span { font-family: var(--font); font-size: 13px; font-weight: 500;
    color: var(--text-muted); letter-spacing: 0; }

/* "Sob consulta" e uma frase, e nao um numero: no corpo de 30px do preco ela
   fica maior que os R$ ao lado e desequilibra a fileira de cartoes. O `span`
   embaixo continua no mesmo tamanho dos outros — o que muda e so a linha de
   cima, que aqui e palavra. */
.plano__preco--consulta { font-size: 22px; letter-spacing: -.01em; }
.plano__preco--consulta span { display: block; margin-top: 4px; }
.plano__limite { margin-top: 10px; font-size: 12.5px; color: var(--text-2); }
.plano__extra { display: flex; align-items: center; gap: 7px; margin-top: 10px;
    padding: 8px 10px; border-radius: 8px; background: var(--brand-soft);
    color: var(--brand-strong); font-size: 12px; font-weight: 600; }
.plano__extra svg { width: 15px; height: 15px; flex-shrink: 0; fill: none;
    stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
/* O botão desce para o rodapé do cartão: sem isto, cartões de alturas
   diferentes deixam os botões desalinhados. */
.plano__btn { margin-top: auto; align-self: stretch; text-align: center; }
.plano form { margin-top: auto; }

/* ========================= TABELA COMPARATIVA ============================ */

.tabela-comparativa th.num, .tabela-comparativa td.num { text-align: center; }
.tabela-comparativa thead th { vertical-align: bottom; }
.tabela-comparativa .linha-grupo th { padding-top: 20px; font-size: 11px;
    text-transform: uppercase; letter-spacing: .07em; color: var(--text-2);
    background: var(--surface-2); border-bottom: 1px solid var(--border); }
/* A coluna do plano assinado fica realçada de cima a baixo, para a leitura
   horizontal não se perder em uma tabela de 35 linhas. */
.tabela-comparativa .col-atual { background: var(--brand-soft); }
.tabela-comparativa .table__url { display: block; }
.marca-nao { color: var(--text-muted); font-size: 15px; }

/* ============================ GRÁFICO DE BARRAS ========================== */
/* Barras em CSS puro: a série é de 12 pontos e cabe em markup. Uma biblioteca
   de gráficos aqui custaria mais bytes do que o painel inteiro. */

.grafico { display: flex; align-items: flex-end; gap: 10px; height: 190px; padding-top: 8px; }
.grafico__col { flex: 1; display: flex; flex-direction: column; align-items: center;
    height: 100%; min-width: 0; }
.grafico__barras { flex: 1; width: 100%; display: flex; align-items: flex-end;
    justify-content: center; gap: 3px; }
.grafico__barra { width: 44%; max-width: 20px; border-radius: 4px 4px 0 0;
    min-height: 0; transition: opacity .15s ease; }
.grafico__barra--paga     { background: var(--brand); }
.grafico__barra--pendente { background: color-mix(in oklab, var(--warn) 55%, white); }
.grafico__col:hover .grafico__barra { opacity: .78; }
.grafico__rotulo { margin-top: 8px; font-size: 10.5px; color: var(--text-muted);
    white-space: nowrap; }

.legenda { display: inline-block; width: 9px; height: 9px; border-radius: 2px;
    margin: 0 4px 0 10px; vertical-align: middle; }
.legenda--paga     { background: var(--brand); }
.legenda--pendente { background: color-mix(in oklab, var(--warn) 55%, white); }

/* ======================= CAMPOS SEGUROS DO CARTÃO ======================== */
/* Cada um é um iframe servido pelo Mercado Pago. O conteúdo não é nosso, então
   o estilo interno vai por JS; aqui só a moldura, para casar com os demais
   campos do formulário. */

.campo-seguro { height: 40px; padding: 0 12px; display: flex; align-items: center;
    border: 1px solid var(--border); border-radius: 9px; background: var(--surface); }
.campo-seguro iframe { width: 100%; height: 100%; border: 0; display: block; }
.campo-seguro:focus-within { border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-soft); }

#erro-pagamento[hidden] { display: none; }
#pagar svg, .field__hint svg { width: 14px; height: 14px; fill: none;
    stroke: currentColor; stroke-width: 1.9; vertical-align: -2px; }

/* ======================== MEIO DE PAGAMENTO ============================== */

.meios { display: grid; gap: 10px; margin-bottom: 18px; }
.meio { display: flex; align-items: flex-start; gap: 11px; padding: 13px 15px;
    border: 1px solid var(--border); border-radius: var(--radius);
    cursor: pointer; transition: border-color .13s ease, background .13s ease; }
.meio:hover { border-color: var(--text-faint); }
.meio:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.meio--off { opacity: .55; cursor: not-allowed; }
.meio--off:hover { border-color: var(--border); }
.meio input { margin-top: 3px; flex-shrink: 0; }
.meio__nome { display: flex; align-items: center; gap: 8px;
    font-weight: 600; font-size: 13.5px; }
.meio__nome svg { width: 16px; height: 16px; fill: none; stroke: currentColor;
    stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.meio__nota { font-size: 12px; color: var(--text-muted); }

#bloco-cartao[hidden], #bloco-boleto[hidden] { display: none; }

/* ================== TEMAS E PLUGINS DE UM SITE ============================ */
/*
   A grade é o que o wp-admin usa, e não é por estilo: com sessenta plugins
   instalados, ninguém acha o de formulário lendo uma coluna de nomes. Acha
   pelo ícone. A tabela continua certa para a carteira, onde a pergunta é
   numérica; aqui a pergunta é "qual é aquele?", e a resposta é visual.
*/

.itens__barra { display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
    padding-bottom: 16px; border-bottom: 1px solid var(--border-soft); }

.itens__busca { position: relative; display: flex; align-items: center; gap: 8px; }
.itens__busca .input { padding-left: 34px; width: 250px; }

.itens__lupa { position: absolute; left: 11px; top: 50%; transform: translateY(-50%);
    display: flex; color: var(--text-faint); pointer-events: none; }
.itens__lupa svg { width: 15px; height: 15px; fill: none; stroke: currentColor;
    stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

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

/* O recorte ativo precisa se distinguir de um botão comum: é estado, não ação.
   Fundo da marca e letra forte fazem isso sem inventar mais um componente. */
.chip { display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 11px; border-radius: 999px; font-size: 12.5px; font-weight: 600;
    color: var(--text-2); background: var(--surface-2);
    border: 1px solid var(--border); transition: background .13s ease, color .13s ease; }
.chip:hover { background: var(--surface-3); color: var(--text); }
.chip--on { background: var(--brand-soft); color: var(--brand-strong);
    border-color: color-mix(in oklab, var(--brand) 32%, white); }

.chip__n { min-width: 17px; padding: 0 5px; border-radius: 999px;
    background: var(--warn-bg); color: var(--warn); border: 1px solid oklch(85% .10 75);
    font-size: 11px; font-weight: 700; text-align: center; }

.itens__acoes { display: flex; gap: 8px; margin-left: auto; }

/* A barra de ação em massa só faz sentido com algo selecionado. Fica visível
   sempre, mas apagada: escondê-la faria a tela pular de altura a cada clique. */
.itens__massa { display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
    padding: 12px 0; border-bottom: 1px solid var(--border-soft); }
.itens__massa:has([data-precisa-selecao]:disabled) { opacity: .72; }

.itens__conta { font-size: 12.5px; color: var(--text-muted); }

.check { display: inline-flex; align-items: center; gap: 7px;
    font-size: 13px; color: var(--text-2); cursor: pointer; user-select: none; }

.input--sm { padding: 6px 10px; font-size: 12.5px; width: auto; }

.itens__vazio { padding: 44px 20px; text-align: center; color: var(--text-muted);
    display: flex; flex-direction: column; align-items: center; gap: 12px; }
.itens__vazio p { margin: 0; font-size: 13.5px; }

/* ------------------------------------------------------------- o cartão -- */

.itens { display: grid; gap: 12px; margin-top: 16px;
    grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); }

.item { position: relative; display: grid; gap: 13px;
    grid-template-columns: auto 1fr; grid-template-areas:
        "arte  corpo"
        "botoes botoes";
    padding: 15px; background: var(--surface);
    border: 1px solid var(--border); border-radius: var(--radius);
    transition: border-color .13s ease, box-shadow .13s ease; }
.item:hover { border-color: var(--text-faint); box-shadow: var(--shadow-sm); }

/* Ativo ganha uma faixa na lateral, e não fundo colorido: com vinte cartões
   ativos e três inativos, colorir os vinte pinta a tela inteira. */
.item--ativo::before { content: ""; position: absolute; left: 0; top: 12px; bottom: 12px;
    width: 3px; border-radius: 0 3px 3px 0; background: var(--ok); }
.item--velho { border-color: oklch(85% .10 75); }

.item__marca { position: absolute; top: 12px; right: 12px; z-index: 1; }
.item__marca input { width: 16px; height: 16px; cursor: pointer; }

.item__arte { grid-area: arte; position: relative; overflow: hidden;
    width: 58px; height: 58px; border-radius: 9px; flex-shrink: 0;
    display: grid; place-items: center;
    background: oklch(93% .055 var(--matiz, 235));
    border: 1px solid var(--border-soft); }

/* Miniatura de tema é retangular e larga — o wp-admin também a mostra assim. */
.item__arte--tema { width: 92px; height: 62px; border-radius: 8px; }

/* Nasce transparente. Quem a mostra e o app.js, ao confirmar que carregou.
   Fundo transparente de proposito: com fundo branco, um icone que ainda nao
   chegou — ou que nunca vai chegar — vira um quadrado branco por cima da
   inicial, e a tela inteira parece meio carregada. */
.item__arte img { position: absolute; inset: 0; width: 100%; height: 100%;
    object-fit: cover; opacity: 0; transition: opacity .18s ease; }
.item__arte img.pronta { opacity: 1; background: var(--surface); }

/* Fica ATRÁS da imagem, sempre desenhada. Quando o plugin não está no
   repositório o `onerror` remove o `<img>` e a inicial aparece sozinha — sem
   pisca, sem segunda requisição, sem cada cartão precisar saber se tem ícone. */
.item__inicial { font-family: var(--display); font-size: 22px; font-weight: 700;
    color: oklch(38% .10 var(--matiz, 235)); }

.item__corpo { grid-area: corpo; min-width: 0; padding-right: 22px; }

.item__nome { margin: 0 0 3px; font-size: 14.5px; font-weight: 650;
    font-family: var(--display); color: var(--text);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.item__meta { display: flex; flex-wrap: wrap; gap: 4px 10px; margin: 0;
    font-size: 12px; color: var(--text-muted); }

.item__desc { margin: 7px 0 0; font-size: 12.5px; line-height: 1.5;
    color: var(--text-muted);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    overflow: hidden; }

.item__pills { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }

.pill--mudo { color: var(--text-muted); background: var(--surface-2);
    border-color: var(--border); }

.item__botoes { grid-area: botoes; display: flex; flex-wrap: wrap; gap: 7px;
    padding-top: 12px; border-top: 1px solid var(--border-soft); }
.item__botoes:empty { display: none; }
.item__form { display: contents; }

.btn--perigo { color: var(--alert); }
.btn--perigo:hover { background: var(--alert-bg); border-color: #fecaca; }

/* ------------------------------------------- a biblioteca do WordPress --- */

.modal__card--largo { max-width: 860px; }

.itens--biblio { max-height: min(52vh, 460px); overflow-y: auto; margin-top: 14px;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }

.itens--biblio .item { grid-template-areas: "arte corpo" "botoes botoes"; }

/* As duas abas do wp-admin: procurar, ou enviar arquivo. Sublinhado e nao
   cartao — sao dois modos da mesma tela, nao dois lugares. */
.biblio__abas { display: flex; gap: 4px; margin: 2px 0 16px;
    border-bottom: 1px solid var(--border); }

.biblio__aba { display: inline-flex; align-items: center; gap: 7px;
    padding: 9px 14px; border: 0; background: transparent; cursor: pointer;
    font: inherit; font-size: 13px; font-weight: 600; color: var(--text-muted);
    border-bottom: 2px solid transparent; margin-bottom: -1px;
    transition: color .13s ease, border-color .13s ease; }
.biblio__aba:hover { color: var(--text); }
.biblio__aba--on { color: var(--brand-strong); border-bottom-color: var(--brand); }
.biblio__aba svg { width: 15px; height: 15px; fill: none; stroke: currentColor;
    stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

.itens__busca--modal .input { width: 100%; }
.itens__busca--modal { width: 100%; }

/* "Procurando…" dentro do campo, a direita: fora dele empurraria a grade para
   baixo a cada tecla digitada. */
.biblio__estado { position: absolute; right: 12px; top: 50%;
    transform: translateY(-50%); font-size: 12px; color: var(--text-muted);
    pointer-events: none; }

/* --------------------------------------------- avaliacao e instalacoes --- */

.item__numeros { display: flex; flex-wrap: wrap; align-items: center;
    gap: 4px 12px; margin: 8px 0 0; font-size: 12px; color: var(--text-muted); }

.estrelas { display: inline-flex; align-items: center; gap: 5px; }

/* Duas fileiras sobrepostas, a de cima cortada na porcentagem da nota. E o
   que permite mostrar 4,5 como quatro estrelas e meia — arredondar para cinco
   daria a um plugin de 90% a mesma marca de um de 100%.

   Amarelo mais escuro que o do WordPress: o deles da 1,9:1 sobre branco. Este
   e a mesma familia da marca de aviso do painel, ja medida em 4,9:1. */
/* A fileira de baixo nao e enfeite: e ela que diz "de cinco". Em --surface-4
   dava 1,26:1 e sumia — a nota passava a ler como "tres estrelas" em vez de
   "tres de cinco", que e outra informacao. Este da exatamente 3,1:1 sobre branco, o minimo para
   elemento grafico que carrega significado. */
.estrelas__fundo { position: relative; display: inline-block;
    color: oklch(66% .022 240); letter-spacing: 1px; font-size: 12.5px;
    white-space: nowrap; }

.estrelas__frente { position: absolute; left: 0; top: 0; overflow: hidden;
    width: calc(var(--nota, 0) * 1%); color: var(--warn); white-space: nowrap; }

/* --text-faint da 3,92:1, abaixo dos 4,5 que texto precisa. E numero, e numero
   e para ser lido. */
.estrelas__n { color: var(--text-muted); }

.item__instala { white-space: nowrap; }

/* ------------------------------------------------- envio de arquivo ------ */

/* O `hidden` do HTML vale `display: none` pela folha do navegador — e QUALQUER
   `display` numa folha de autor ganha dele. Este `display: flex` fazia os dois
   painéis do modal aparecerem ao mesmo tempo: a busca em cima, o envio de
   arquivo logo abaixo, com as duas abas dizendo que só uma estava aberta.
   Esconder por JavaScript não adiantava, porque a regra nunca perdia. */
.biblio__envio { display: flex; flex-direction: column; gap: 14px; }
.biblio__envio[hidden] { display: none; }
.biblio__envio .modal__sub { margin: 0; }

/* O bloco de soltar arquivo. O input fica invisivel POR CIMA de tudo, e nao
   escondido com display:none: assim o clique em qualquer ponto abre o
   seletor, e arrastar o zip para cima do bloco tambem funciona. */
.solta { position: relative; display: flex; flex-direction: column;
    align-items: center; gap: 8px; padding: 30px 20px; text-align: center;
    border: 2px dashed var(--field-border); border-radius: var(--radius);
    background: var(--surface-2); cursor: pointer;
    transition: border-color .13s ease, background .13s ease; }
.solta:hover { border-color: var(--brand); background: var(--brand-wash); }
.solta--sobre { border-color: var(--brand); background: var(--brand-soft); }
.solta--cheia { border-style: solid; border-color: var(--ok); background: var(--ok-bg); }

.solta input[type="file"] { position: absolute; inset: 0; width: 100%; height: 100%;
    opacity: 0; cursor: pointer; }

.solta__icone { display: flex; color: var(--brand-strong); }
.solta__icone svg { width: 26px; height: 26px; fill: none; stroke: currentColor;
    stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.solta__texto { font-size: 13.5px; font-weight: 600; color: var(--text-2);
    max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.solta__limite { font-size: 12px; color: var(--text-muted); }
