/* EDS Interface · EDS Core Modern (checkout, Minha conta e Central de acessos).
   O Core já usa as mesmas variáveis nas duas telas (billing.css no :root, admin.css em .eds);
   aqui elas recebem a linguagem Mixroom, com tema Claro ou Escuro escolhido no painel (em vez de seguir o sistema). */

/* ---- tema claro ---- */
html[data-eds-ui="modern"][data-eds-page="billing"][data-eds-theme="claro"],
.eds[data-eds-ui="modern"][data-eds-theme="claro"] {
  --bg: #f4f4f5;
  --fg: #18181b;
  --card: #ffffff;
  --muted: #f1f2f4;
  --muted-fg: #5f6068;
  --border: rgba(9, 9, 11, 0.09);
  --input: #8a8b93;
  --primary: var(--eds-accent);
  --primary-fg: var(--eds-on-accent);
  --ring: rgba(24, 24, 27, 0.22);
  --side: rgba(255, 255, 255, 0.7);
  --accent: #ececef;
  --ok-bg: #ecfdf5;
  --ok-fg: #047857;
  --ok-bd: #a7f3d0;
  --warn-bg: #fffbeb;
  --warn-fg: #92400e;
  --warn-bd: #fcd34d;
  --danger-bg: #fef2f2;
  --danger-fg: #b91c1c;
  --danger-bd: #fecaca;
  --info-bg: #eff6ff;
  --info-fg: #1d4ed8;
  --info-bd: #bfdbfe;
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.12);
  --radius: 14px;
  color-scheme: light;
}
html[data-eds-ui="modern"][data-eds-page="billing"][data-eds-theme="claro"] body,
.eds[data-eds-ui="modern"][data-eds-theme="claro"] {
  background:
    radial-gradient(1100px 620px at 100% -10%, color-mix(in srgb, #93c5fd calc(var(--eds-glow) * 2), transparent), transparent 65%),
    radial-gradient(900px 600px at -10% 110%, color-mix(in srgb, #6ee7c8 var(--eds-glow), transparent), transparent 70%),
    linear-gradient(160deg, #fcfcfd 0%, #f4f4f5 55%, #efeff1 100%);
  background-attachment: fixed;
}

/* ---- tema escuro ---- */
html[data-eds-ui="modern"][data-eds-page="billing"][data-eds-theme="escuro"],
.eds[data-eds-ui="modern"][data-eds-theme="escuro"] {
  --bg: #09090b;
  --fg: #ececf0;
  --card: rgba(18, 18, 21, 0.86);
  --muted: #1a1a1f;
  --muted-fg: #9898a2;
  --border: rgba(255, 255, 255, 0.08);
  --input: #68727e;
  --primary: var(--eds-accent);
  --primary-fg: var(--eds-on-accent);
  --ring: rgba(236, 236, 240, 0.25);
  --side: rgba(13, 13, 15, 0.62);
  --accent: #1a1a1f;
  --ok-bg: #14382b;
  --ok-fg: #6ee7c8;
  --ok-bd: rgba(110, 231, 200, 0.3);
  --warn-bg: #392b13;
  --warn-fg: #f5c26b;
  --warn-bd: rgba(245, 194, 107, 0.35);
  --danger-bg: #3b2024;
  --danger-fg: #ff8a8a;
  --danger-bd: rgba(255, 138, 138, 0.35);
  --info-bg: #172c48;
  --info-fg: #93c5fd;
  --info-bd: rgba(147, 197, 253, 0.3);
  --shadow: none;
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.48);
  --radius: 14px;
  color-scheme: dark;
}
html[data-eds-ui="modern"][data-eds-page="billing"][data-eds-theme="escuro"] body,
.eds[data-eds-ui="modern"][data-eds-theme="escuro"] {
  background:
    radial-gradient(1100px 620px at 100% -10%, color-mix(in srgb, #93c5fd var(--eds-glow), transparent), transparent 65%),
    radial-gradient(900px 600px at -10% 110%, color-mix(in srgb, #6ee7c8 var(--eds-glow-soft), transparent), transparent 70%),
    linear-gradient(160deg, #121218 0%, #09090b 50%, #0c0c10 100%);
  background-attachment: fixed;
}

/* ---- tela de acesso (login) do Core ---- */
html[data-eds-ui="modern"][data-eds-page="auth"] body {
  background:
    radial-gradient(900px 560px at 50% -10%, color-mix(in srgb, var(--accent) calc(var(--eds-glow) * 1.4), transparent), transparent 65%),
    radial-gradient(800px 520px at 100% 110%, color-mix(in srgb, var(--accent) var(--eds-glow-soft), transparent), transparent 70%),
    var(--bg);
  background-attachment: fixed;
}

/* ---- Central de acessos: layout do canvas (menu lateral + conteúdo) ----
   Só reorganiza com CSS o HTML que o painel já tem (cabeçalho, abas e seções). Nenhuma função muda. */
.eds[data-eds-ui="modern"] {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  min-height: 100vh;
}
.eds[data-eds-ui="modern"] h1 {
  font-size: 30px;
  font-weight: 650;
  letter-spacing: -0.03em;
}
.eds[data-eds-ui="modern"] .eds-card {
  border-radius: 14px;
  -webkit-backdrop-filter: saturate(140%) blur(6px);
  backdrop-filter: saturate(140%) blur(6px);
}
.eds[data-eds-ui="modern"] .eds-kpi .value {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
  font-size: 24px;
}
.eds[data-eds-ui="modern"] .eds-btn {
  border-radius: 10px;
}
.eds[data-eds-ui="modern"] .eds-tabs a[aria-current='page'] {
  background: var(--accent);
  color: var(--fg);
  box-shadow: inset 2px 0 0 var(--primary);
}
.eds[data-eds-ui="modern"] .eds-tabs a.eds-ui-link {
  color: var(--muted-fg);
}
@media (min-width: 900px) {
  .eds[data-eds-ui="modern"] .eds-shell {
    max-width: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: 248px minmax(0, 1fr);
    align-items: start;
    min-height: 100vh;
  }
  .eds[data-eds-ui="modern"] .eds-shell > :not(.eds-tabs) {
    grid-column: 2;
    margin-left: 32px;
    margin-right: 32px;
  }
  .eds[data-eds-ui="modern"] .eds-shell > .eds-header {
    margin-top: 28px;
  }
  .eds[data-eds-ui="modern"] .eds-shell > section:last-of-type {
    margin-bottom: 48px;
  }
  .eds[data-eds-ui="modern"] .eds-tabs {
    grid-column: 1;
    grid-row: 1 / span 40;
    align-self: stretch;
    flex-direction: column;
    gap: 2px;
    margin: 0;
    padding: 16px 12px;
    border-radius: 0;
    background: var(--side);
    border-right: 1px solid var(--border);
    overflow: visible;
    -webkit-backdrop-filter: saturate(140%) blur(10px);
    backdrop-filter: saturate(140%) blur(10px);
  }
  .eds[data-eds-ui="modern"] .eds-tabs::before {
    content: "Central de acessos";
    display: block;
    padding: 6px 10px 14px;
    font-size: 15px;
    font-weight: 650;
    color: var(--fg);
  }
  .eds[data-eds-ui="modern"] .eds-tabs a {
    height: 38px;
    padding: 0 12px;
    border-radius: 9px;
  }
  .eds[data-eds-ui="modern"] .eds-tabs a:hover {
    background: var(--accent);
  }
  .eds[data-eds-ui="modern"] .eds-tabs a.eds-ui-link {
    margin-top: 10px;
    border-top: 1px solid var(--border);
    border-radius: 0 0 9px 9px;
    padding-top: 10px;
    height: 48px;
  }
}
