@import url("/paleta.css?v=20260423b");

:root {
  --page-bg: #f7f8f9;
  --sidebar-bg: var(--askora-primary);
  --sidebar-pad-x: 14px;
  --sidebar-collapsed-width: 82px;
  --sidebar-expanded-width: 258px;
  --sidebar-icon-size: 22px;
  --sidebar-logo-size: 34px;
  --sidebar-inner-width: calc(var(--sidebar-collapsed-width) - (var(--sidebar-pad-x) * 2));
  --sidebar-icon-anchor-padding: calc((var(--sidebar-inner-width) - var(--sidebar-icon-size)) / 2);
  --sidebar-logo-anchor-padding: calc((var(--sidebar-inner-width) - var(--sidebar-logo-size)) / 2);
  --card-bg: var(--askora-card-light-surface);
  --card-bg-soft: #f8fafc;
  --card-light-bg: var(--askora-card-light-bg);
  --card-light-border: var(--askora-card-light-border);
  --card-light-shadow: var(--askora-card-light-shadow);
  --card-dark-bg: var(--askora-card-dark-bg);
  --card-dark-border: var(--askora-card-dark-border);
  --card-dark-shadow: var(--askora-card-dark-shadow);
  --card-color-bg: var(--askora-card-color-bg);
  --card-color-border: var(--askora-card-color-border);
  --card-color-shadow: var(--askora-card-color-shadow);
  --text-900: var(--askora-text-900);
  --text-700: var(--askora-text-700);
  --text-600: var(--askora-text-600);
  --text-500: var(--askora-text-500);
  --accent: var(--askora-primary);
  --accent-orange: var(--askora-secondary-orange);
  --askora-cyan-1: var(--askora-tertiary-light);
  --askora-cyan-2: var(--askora-tertiary);
  --askora-cyan-3: var(--askora-tertiary-dark);
  --askora-green-1: var(--askora-secondary-green-light);
  --askora-green-2: var(--askora-secondary-green);
  --askora-green-3: var(--askora-secondary-green-dark);
  --askora-orange-1: var(--askora-secondary-orange-light);
  --askora-orange-2: var(--askora-secondary-orange);
  --askora-orange-3: var(--askora-secondary-orange-dark);
  --askora-gradient-brand: var(--askora-secondary-gradient);
  --askora-gradient-cyan: var(--askora-tertiary-gradient);
  --askora-gradient-green: linear-gradient(132deg, var(--askora-green-1) 0%, var(--askora-green-2) 52%, var(--askora-green-3) 100%);
  --glass-black-bg: var(--askora-card-dark-bg);
  --glass-black-border: var(--askora-card-dark-border);
  --glass-black-shadow: var(--askora-card-dark-shadow);
  --glass-inner-bg: var(--askora-card-light-bg);
  --glass-inner-border: var(--askora-card-light-border);
  --radius-lg: 20px;
  --radius-md: 14px;
  --shadow-card: var(--askora-card-light-shadow);
  --shadow-soft: 0 6px 18px rgba(17, 24, 39, 0.05);
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--page-bg);
  color: var(--text-900);
  -webkit-font-smoothing: antialiased;
}

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

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

p {
  margin: 0;
}

.section-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.section-toggle--compact {
  gap: 8px;
}

.switch-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 46px;
  height: 26px;
  border: 1px solid rgba(var(--askora-slate-400-rgb), 0.55);
  border-radius: 999px;
  padding: 0;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background: linear-gradient(140deg, rgba(var(--askora-slate-200-rgb), 0.95), rgba(var(--askora-slate-300-rgb), 0.88));
  transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.switch-toggle input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  margin: 0;
}

.switch-toggle__track {
  position: absolute;
  inset: 2px;
  border-radius: 999px;
  background: linear-gradient(140deg, rgba(var(--askora-slate-200-rgb), 0.95), rgba(var(--askora-slate-300-rgb), 0.88));
  transition: background 0.2s ease, box-shadow 0.2s ease;
  pointer-events: none;
}

.switch-toggle__thumb {
  position: absolute;
  top: -0.5px;
  left: 2px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--askora-white);
  box-shadow: 0 2px 6px rgba(var(--askora-slate-900-rgb), 0.25);
  transition: transform 0.2s ease;
}

.switch-toggle input:checked + .switch-toggle__track,
.switch-toggle.switch-toggle--on .switch-toggle__track {
  background: linear-gradient(140deg, var(--askora-secondary-green), var(--askora-secondary-green-dark));
  box-shadow: 0 8px 18px rgba(var(--askora-status-success-teal-rgb), 0.2);
}

.switch-toggle input:checked + .switch-toggle__track .switch-toggle__thumb,
.switch-toggle.switch-toggle--on .switch-toggle__thumb {
  transform: translateX(18px);
}

.status-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 78px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border: 1px solid transparent;
}

.status-chip--open {
  background: rgba(var(--askora-status-success-teal-rgb), 0.14);
  color: var(--askora-status-success-strong);
  border-color: rgba(var(--askora-status-success-teal-rgb), 0.32);
}

.status-chip--closed {
  background: rgba(var(--askora-slate-200-rgb), 0.9);
  color: var(--askora-slate-600);
  border-color: rgba(var(--askora-slate-400-rgb), 0.42);
}

.shell {
  display: flex;
  min-height: 100vh;
  align-items: flex-start;
}

.sidebar-slot {
  position: relative;
  align-self: flex-start;
  flex: 0 0 var(--sidebar-collapsed-width);
  width: var(--sidebar-collapsed-width);
  height: 100vh;
  overflow: visible;
  z-index: 20;
}

.sidebar {
  /* Keep the sidebar fixed to the viewport and use .sidebar-slot only to reserve layout width. */
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-collapsed-width);
  background: var(--sidebar-bg);
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  border-top-right-radius: 16px;
  border-bottom-right-radius: 16px;
  box-shadow: 8px 0 18px rgba(2, 6, 23, 0.2);
  padding: 16px var(--sidebar-pad-x) 14px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  height: 100vh;
  overflow: hidden;
  transition: width 0.18s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.18s ease;
  z-index: 10;
  color: #ffffff;
}

.sidebar:hover,
.sidebar:focus-within,
.sidebar.is-expanded {
  width: var(--sidebar-expanded-width);
  box-shadow: 10px 0 22px rgba(2, 6, 23, 0.24);
}

.shell.is-nav-leaving .sidebar {
  width: var(--sidebar-collapsed-width);
}

.sidebar__header {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  padding-left: var(--sidebar-logo-anchor-padding);
  margin: 0;
  width: 100%;
  min-height: 38px;
}

.brand__mark {
  width: var(--sidebar-logo-size);
  min-width: var(--sidebar-logo-size);
  height: auto;
  filter: none;
}

.brand__logo {
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.16s ease, transform 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}

.sidebar__handle {
  position: fixed;
  left: calc(var(--sidebar-collapsed-width) - 4px);
  top: 39px;
  transform: translate3d(0, 0, 0);
  width: 18px;
  height: 38px;
  border-radius: 0 12px 12px 0;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-left: none;
  background: linear-gradient(180deg, #2a3240 0%, #1b2432 100%);
  box-shadow: 0 2px 6px rgba(2, 6, 23, 0.2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(226, 232, 240, 0.88);
  pointer-events: none;
  z-index: 9;
  transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);
}

.sidebar__handle svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.24s ease;
}

.sidebar:hover + .sidebar__handle,
.sidebar:focus-within + .sidebar__handle,
.sidebar.is-expanded + .sidebar__handle {
  transform: translate3d(calc(var(--sidebar-expanded-width) - var(--sidebar-collapsed-width)), 0, 0);
}

.shell.is-nav-leaving .sidebar + .sidebar__handle {
  transform: translate3d(0, 0, 0);
}

.sidebar:hover + .sidebar__handle svg,
.sidebar:focus-within + .sidebar__handle svg,
.sidebar.is-expanded + .sidebar__handle svg {
  transform: rotate(180deg);
}

.shell.is-nav-leaving .sidebar + .sidebar__handle svg {
  transform: rotate(0deg);
}

.menu {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  margin-top: 4px;
}

.menu__item {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  min-height: 44px;
  border-radius: 12px;
  padding: 10px 0 10px var(--sidebar-icon-anchor-padding);
  color: rgba(255, 255, 255, 0.84);
  transition: color 0.18s ease;
}

.menu__icon {
  width: var(--sidebar-icon-size);
  height: var(--sidebar-icon-size);
  min-width: var(--sidebar-icon-size);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

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

.menu__label {
  font-size: 14px;
  font-weight: 600;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.16s ease, transform 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}

.sidebar:hover .brand__logo,
.sidebar:focus-within .brand__logo,
.sidebar.is-expanded .brand__logo,
.sidebar:hover .menu__label,
.sidebar:focus-within .menu__label,
.sidebar.is-expanded .menu__label {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 0.04s;
}

.shell.is-nav-leaving .sidebar .brand__logo,
.shell.is-nav-leaving .sidebar .menu__label {
  opacity: 0;
  transform: translateX(-8px);
}

.menu__item.is-active {
  color: #ffffff;
}

.menu__item:hover {
  color: #ffffff;
}

.menu__item--logout {
  color: rgba(255, 255, 255, 0.8);
}

.sidebar__footer {
  margin-top: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  padding-top: 6px;
}

.menu__item--logout:hover {
  color: #ffffff;
}

.content {
  flex: 1;
  min-width: 0;
  padding: 48px 64px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.toast-container {
  position: fixed;
  right: 20px;
  bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 9999;
}

.toast {
  min-width: 240px;
  max-width: 360px;
  padding: 12px 14px;
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.18);
  background: #0f172a;
  color: #ffffff;
  font-size: 14px;
}

.toast--success {
  background: var(--askora-status-success-strong, #0f766e);
}

.toast--error {
  background: var(--askora-danger-700, #b91c1c);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-md);
  padding: 11px 18px;
  font-weight: 600;
  font-size: 14px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-900);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}

.btn--primary {
  background: var(--askora-primary-gradient);
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(var(--askora-primary-rgb), 0.28);
}

.btn--primary:hover {
  background: var(--askora-primary-gradient-hover);
}

.btn--ghost {
  border-color: rgba(15, 23, 42, 0.12);
}

.btn:hover {
  transform: translateY(-1px);
}

input[data-askora-input="money"],
input[data-askora-input="percent"],
input[data-askora-input="factor"],
input[data-askora-input="qtd"],
input[data-askora-input="number"] {
  font-variant-numeric: tabular-nums;
}

.askora-password-field {
  position: relative;
  display: flex;
  align-items: center;
}

.askora-password-field > input {
  width: 100%;
  padding-right: 40px;
}

.askora-password-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  border: none;
  background: transparent;
  color: var(--text-600);
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.askora-password-eye {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.askora-password-eye--off {
  display: none;
}

.askora-password-toggle.is-visible .askora-password-eye--open {
  display: none;
}

.askora-password-toggle.is-visible .askora-password-eye--off {
  display: inline-flex;
}

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

button[data-global-loading="1"].is-loading {
  position: relative;
  pointer-events: none;
  cursor: wait;
  opacity: 0.86;
}

button[data-global-loading="1"].is-loading::after {
  content: "";
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-top-color: currentColor;
  animation: askoraButtonSpin 0.85s linear infinite;
}

button[data-global-loading="1"].is-loading.btn--ghost::after {
  border-color: rgba(15, 23, 42, 0.25);
  border-top-color: currentColor;
}

@media (max-width: 960px) {
  .shell {
    flex-direction: column;
  }

  .sidebar-slot {
    position: relative;
    top: auto;
    width: 100%;
    flex: 0 0 auto;
    height: auto;
  }

  .sidebar,
  .sidebar:hover,
  .sidebar:focus-within,
  .sidebar.is-expanded {
    position: relative;
    height: auto;
    flex: 0 0 auto;
    width: 100%;
    padding: 16px 18px 14px;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
  }

  .brand__logo,
  .menu__label {
    opacity: 1;
    transform: translateX(0);
  }

  .brand {
    justify-content: flex-start;
    gap: 12px;
    padding-left: 0;
  }

  .menu__item {
    justify-content: flex-start;
    gap: 12px;
    padding: 10px 10px;
  }

  .menu {
    flex: 0 0 auto;
  }

  .sidebar__handle {
    display: none;
  }

  .sidebar__footer {
    margin-top: 14px;
  }

  .content {
    padding: 36px 26px;
  }
}
