@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700;800&family=Space+Grotesk:wght@500;600;700&display=swap');

:root {
  --bg: #081226;
  --bg-soft: #0d1b34;
  --bg-panel: #112447;
  --line: rgba(147, 197, 253, 0.25);
  --line-strong: rgba(129, 140, 248, 0.45);
  --text: #ecf5ff;
  --muted: #c6d4e7;
  --accent: #7dd3fc;
  --accent-dark: #07213d;
  --success: #16a34a;
  --danger: #dc2626;
  --sidebar-bg: linear-gradient(180deg, #0f1f3f 0%, #102f4e 55%, #0b2038 100%);
  --sidebar-text: #f5f5f5;
  --sidebar-link: #cbcbcb;
  --sidebar-link-hover: #ffffff;
  --topbar-bg: linear-gradient(120deg, rgba(30, 64, 175, 0.85), rgba(3, 105, 161, 0.85));
  --topbar-text: #f9f9f9;
  --card-bg: linear-gradient(150deg, rgba(15, 35, 68, 0.86) 0%, rgba(9, 22, 44, 0.9) 100%);
  --card-shadow: 0 16px 40px rgba(9, 14, 33, 0.35);
  --input-bg: rgba(9, 23, 46, 0.85);
  --input-text: #e0ecff;
  --button-secondary-bg: rgba(15, 35, 68, 0.65);
  --button-secondary-text: #e8e8e8;
  --surface-soft: rgba(255, 255, 255, 0.05);
  --surface-border: rgba(255, 255, 255, 0.10);
  --page-glow-1: rgba(59, 130, 246, 0.35);
  --page-glow-2: rgba(16, 185, 129, 0.28);
  --page-glow-3: rgba(244, 114, 182, 0.14);
  --radius-card: 24px;
  --radius-control: 16px;
  --radius-pill: 999px;
  --content-max-width: 1600px;
}

html[data-appearance="claro"] {
  --bg: #f7f9fc;
  --bg-soft: #eef3f8;
  --bg-panel: #ffffff;
  --line: rgba(148, 163, 184, 0.18);
  --line-strong: rgba(148, 163, 184, 0.28);
  --text: #06080d;
  --muted: #4f5f73;
  --accent: #8fb7ef;
  --accent-dark: #eef4fc;
  --sidebar-bg: linear-gradient(180deg, #f4f7fb 0%, #ebf1f8 55%, #e5edf6 100%);
  --sidebar-text: #0a0d12;
  --sidebar-link: #334155;
  --sidebar-link-hover: #000000;
  --topbar-bg: linear-gradient(120deg, #f2f6fb, #e7eef7);
  --topbar-text: #07090d;
  --card-bg: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(247, 250, 253, 0.99));
  --card-shadow: 0 18px 38px rgba(148, 163, 184, 0.18);
  --input-bg: rgba(255, 255, 255, 0.95);
  --input-text: #0b0f15;
  --button-secondary-bg: rgba(236, 241, 246, 0.96);
  --button-secondary-text: #0a0d12;
  --surface-soft: rgba(15, 23, 42, 0.03);
  --surface-border: rgba(148, 163, 184, 0.18);
  --page-glow-1: rgba(255, 255, 255, 0.45);
  --page-glow-2: rgba(203, 213, 225, 0.24);
  --page-glow-3: rgba(226, 232, 240, 0.22);
}

html[data-appearance="system"] {
  --bg: #eef3f8;
  --bg-soft: #dde7f1;
  --bg-panel: #f8fbfe;
  --line: rgba(125, 145, 168, 0.18);
  --line-strong: rgba(125, 145, 168, 0.30);
  --text: #18212b;
  --muted: #5a6a7d;
  --accent: #7aa6d9;
  --accent-dark: #e8f1fa;
  --sidebar-bg: linear-gradient(180deg, #e1e9f2 0%, #d5e0eb 55%, #ccd8e4 100%);
  --sidebar-text: #11161d;
  --sidebar-link: #496175;
  --sidebar-link-hover: #0b0f14;
  --topbar-bg: linear-gradient(120deg, #e8eef5, #d7e2ee);
  --topbar-text: #141920;
  --card-bg: linear-gradient(180deg, rgba(250, 252, 255, 0.98), rgba(236, 243, 249, 0.98));
  --card-shadow: 0 16px 36px rgba(120, 145, 173, 0.18);
  --input-bg: rgba(250, 251, 252, 0.96);
  --input-text: #11161d;
  --button-secondary-bg: rgba(229, 236, 244, 0.94);
  --button-secondary-text: #141920;
  --surface-soft: rgba(15, 23, 42, 0.035);
  --surface-border: rgba(125, 145, 168, 0.16);
  --page-glow-1: rgba(255, 255, 255, 0.36);
  --page-glow-2: rgba(125, 211, 252, 0.18);
  --page-glow-3: rgba(191, 219, 254, 0.16);
}

html[data-appearance="escuro"] {
  --bg: #030712;
  --bg-soft: #0b1220;
  --bg-panel: #121a29;
  --line: rgba(71, 85, 105, 0.35);
  --line-strong: rgba(56, 189, 248, 0.28);
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --accent-dark: #0f172a;
  --sidebar-bg: linear-gradient(180deg, #050814 0%, #09111f 55%, #040914 100%);
  --sidebar-text: #e5edf8;
  --sidebar-link: #94a3b8;
  --sidebar-link-hover: #ffffff;
  --topbar-bg: linear-gradient(120deg, rgba(2, 6, 23, 0.96), rgba(15, 23, 42, 0.96));
  --topbar-text: #f8fafc;
  --card-bg: linear-gradient(180deg, rgba(8, 15, 28, 0.95), rgba(13, 22, 37, 0.98));
  --card-shadow: 0 18px 44px rgba(2, 6, 23, 0.46);
  --input-bg: rgba(2, 6, 23, 0.92);
  --input-text: #e2e8f0;
  --button-secondary-bg: rgba(15, 23, 42, 0.92);
  --button-secondary-text: #e2e8f0;
  --surface-soft: rgba(255, 255, 255, 0.04);
  --surface-border: rgba(148, 163, 184, 0.10);
  --page-glow-1: rgba(14, 165, 233, 0.20);
  --page-glow-2: rgba(34, 197, 94, 0.12);
  --page-glow-3: rgba(99, 102, 241, 0.14);
}

.brand-logo {
  height: 44px;
  width: auto;
  max-width: 170px;
  object-fit: contain;
}

.brand-logo--auth {
  height: 54px;
  width: auto;
  max-width: 190px;
  object-fit: contain;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Barlow', sans-serif;
  color: var(--text);
  line-height: 1.55;
  background:
    radial-gradient(1200px 620px at 85% -10%, var(--page-glow-1) 0%, transparent 58%),
    radial-gradient(900px 520px at -10% 90%, var(--page-glow-2) 0%, transparent 62%),
    radial-gradient(700px 420px at 50% 120%, var(--page-glow-3) 0%, transparent 70%),
    var(--bg);
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Space Grotesk', 'Barlow', sans-serif;
  letter-spacing: -0.03em;
  line-height: 1.06;
  text-wrap: balance;
}

p,
label,
input,
textarea,
select,
button,
a,
td,
th {
  letter-spacing: 0.01em;
}

.auth-body {
  padding: 32px 24px;
}

.main-body {
  min-height: 100vh;
}

a {
  color: inherit;
}

.layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 286px minmax(0, 1fr);
}

.sidebar {
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  border-right: 1px solid rgba(125, 211, 252, 0.3);
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.03), 18px 0 40px rgba(2, 8, 23, 0.18);
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 28px 22px !important;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.sidebar::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.sidebar .nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 15px;
  border-radius: 16px;
  border: 1px solid transparent;
  color: var(--sidebar-link);
  font-size: 0.98rem;
  font-weight: 600;
  transition: transform 0.18s ease, background 0.22s ease, border-color 0.22s ease, color 0.22s ease;
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
  color: var(--sidebar-link-hover);
  border-color: rgba(125, 211, 252, 0.5);
  background: linear-gradient(90deg, rgba(125, 211, 252, 0.18), rgba(34, 197, 94, 0.15));
  transform: translateX(4px);
}

.topbar {
  background: var(--topbar-bg);
  color: var(--topbar-text);
  border-bottom: 1px solid rgba(125, 211, 252, 0.35);
  padding: 18px 28px;
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 34px rgba(3, 7, 18, 0.18);
}

.topbar-language-select {
  width: 72px;
  min-width: 72px;
  min-height: 38px;
  padding: 6px 10px;
  font-weight: 700;
  font-size: 0.92rem;
  border-radius: 14px;
}

.layout main {
  width: 100%;
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 32px !important;
}

.card {
  background: var(--card-bg);
  border-radius: var(--radius-card);
  border: 1px solid rgba(125, 211, 252, 0.18);
  box-shadow: var(--card-shadow);
  backdrop-filter: blur(14px);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease, background 0.35s ease;
  opacity: 1;
  transform: none;
}

.card-visible {
  opacity: 1;
  transform: none;
}

.card:hover {
  transform: translateY(-5px);
  border-color: rgba(56, 189, 248, 0.32);
  box-shadow: 0 28px 54px rgba(14, 116, 144, 0.20);
}

.btn-primary {
  background: linear-gradient(120deg, #67e8f9, #818cf8);
  color: #07111f;
  border-radius: var(--radius-pill);
  padding: 12px 20px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  min-height: 46px;
  box-shadow: 0 12px 26px rgba(56, 189, 248, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn-secondary {
  background: var(--button-secondary-bg);
  color: var(--button-secondary-text);
  border-radius: var(--radius-pill);
  padding: 12px 20px;
  font-weight: 700;
  border: 1px solid var(--line-strong);
  min-height: 46px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.btn-primary:hover,
.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 28px rgba(2, 8, 23, 0.14);
}

.automation-channel-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.automation-channel-nav .btn-secondary {
  flex: 1 1 180px;
}

.automation-channel-nav .btn-secondary.is-active {
  background: linear-gradient(120deg, #67e8f9, #818cf8);
  color: #07111f;
  border-color: transparent;
}

.btn-danger {
  background: linear-gradient(120deg, #ef4444, #dc2626);
  color: #fff;
  border-radius: var(--radius-pill);
  padding: 12px 20px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  min-height: 46px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 28px rgba(185, 28, 28, 0.26);
}

.btn-danger-small {
  padding: 8px 14px;
  font-size: 0.9rem;
}

.quotes-action-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 12px;
}

.quotes-action-form {
  display: inline-flex;
  margin: 0;
}

.quotes-action-btn {
  min-width: 172px;
}

.quotes-action-btn-danger {
  min-width: 118px;
}

.input,
.select,
.textarea {
  width: 100%;
  border-radius: var(--radius-control);
  border: 1px solid var(--line-strong);
  padding: 12px 14px;
  background: var(--input-bg);
  color: var(--input-text);
  min-height: 48px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: rgba(103, 232, 249, 0.78);
  box-shadow: 0 0 0 4px rgba(103, 232, 249, 0.10), 0 12px 24px rgba(8, 23, 46, 0.10);
  transform: translateY(-1px);
}

input[type="file"].input {
  padding: 8px 10px;
  min-height: 56px;
  color: #dbeafe;
  background:
    linear-gradient(120deg, rgba(15, 23, 42, 0.92), rgba(7, 15, 32, 0.98));
}

input[type="file"].input::file-selector-button {
  margin-right: 12px;
  border: 1px solid rgba(125, 211, 252, 0.52);
  border-radius: 12px;
  background: linear-gradient(135deg, #67e8f9, #8ea6ff);
  color: #0b1220;
  padding: 10px 16px;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
  box-shadow: 0 10px 20px rgba(56, 189, 248, 0.18);
}

input[type="file"].input::file-selector-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 24px rgba(56, 189, 248, 0.24);
  filter: brightness(1.03);
}

input[type="file"].input::file-selector-button:active {
  transform: translateY(0);
  box-shadow: 0 8px 14px rgba(56, 189, 248, 0.16);
}

.label {
  font-size: 12px;
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

body {
  top: 0 !important;
}

.badge {
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 700;
}

.badge-blue {
  background: rgba(148, 163, 184, 0.2);
  color: #d1d5db;
}

.badge-green {
  background: rgba(22, 163, 74, 0.2);
  color: #86efac;
}

.badge-red {
  background: rgba(220, 38, 38, 0.18);
  color: #fca5a5;
}

.badge-gray {
  background: rgba(120, 120, 120, 0.2);
  color: #d4d4d4;
}

html[data-appearance="escuro"] .text-slate-600,
html[data-appearance="escuro"] .text-slate-500,
html[data-appearance="escuro"] .text-slate-400 {
  color: #94a3b8 !important;
}

html[data-appearance="escuro"] .text-slate-200 {
  color: #cbd5e1 !important;
}

html[data-appearance="claro"] .text-slate-200 {
  color: #2b3440 !important;
}

html[data-appearance="claro"] .text-slate-400,
html[data-appearance="claro"] .text-slate-500,
html[data-appearance="claro"] .text-slate-600 {
  color: #3b4755 !important;
}

html[data-appearance="system"] .text-slate-200 {
  color: #4b5662 !important;
}

html[data-appearance="system"] .text-slate-400,
html[data-appearance="system"] .text-slate-500,
html[data-appearance="system"] .text-slate-600 {
  color: #5e6975 !important;
}

.kanban-board-shell {
  position: relative;
  display: grid;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
}

.kanban-scroll-wrap {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto !important;
  overflow-y: hidden;
  padding: 0 0 12px;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: rgba(125, 211, 252, 0.55) rgba(9, 20, 41, 0.65);
  touch-action: pan-x pan-y;
}

.kanban-scroll-wrap::-webkit-scrollbar {
  height: 12px;
}

.kanban-scroll-wrap::-webkit-scrollbar-track {
  background: rgba(9, 20, 41, 0.65);
  border-radius: 999px;
}

.kanban-scroll-wrap::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, rgba(103, 232, 249, 0.85), rgba(129, 140, 248, 0.85));
  border-radius: 999px;
}

.kanban {
  display: flex;
  align-items: stretch;
  gap: 18px;
  width: max-content;
  min-width: max-content;
  max-width: none;
  padding-right: 12px;
}

.kanban-column {
  flex: 0 0 340px;
  width: 340px;
  max-width: 340px;
  display: flex;
  flex-direction: column;
  background: rgba(11, 27, 53, 0.86);
  border-radius: 18px;
  border: 1px dashed rgba(125, 211, 252, 0.35);
  padding: 14px;
  height: min(70vh, 760px);
  min-height: 520px;
}

.kanban-column-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.kanban-toolbar {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.kanban-toolbar-block {
  display: grid;
  gap: 10px;
}

.kanban-filter-block {
  flex: 1 1 560px;
}

.kanban-filter-employee-form {
  display: grid;
  gap: 8px;
  max-width: 360px;
}

.kanban-toolbar-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
  font-weight: 700;
}

.kanban-view-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.25);
  background: rgba(10, 27, 54, 0.7);
  flex-wrap: wrap;
}

.kanban-view-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  min-width: 138px;
  padding: 0 18px;
  border-radius: 999px;
  color: #dbeafe;
  font-weight: 700;
  text-decoration: none;
  transition: 0.2s ease;
}

.dashboard-shell {
  position: relative;
}

.dashboard-hero {
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.24), transparent 30%),
    radial-gradient(circle at bottom left, rgba(16, 185, 129, 0.18), transparent 36%),
    linear-gradient(135deg, rgba(8, 20, 42, 0.96), rgba(14, 36, 68, 0.92));
}

.dashboard-hero::after {
  content: '';
  position: absolute;
  inset: auto -60px -60px auto;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.22), transparent 68%);
  pointer-events: none;
}

.dashboard-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.9fr);
  gap: 24px;
  align-items: center;
}

.dashboard-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid rgba(125, 211, 252, 0.28);
  border-radius: 999px;
  background: rgba(9, 23, 46, 0.45);
  color: #cde8ff;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 700;
}

.dashboard-title {
  font-size: clamp(1.8rem, 2.6vw, 3rem);
  line-height: 1.08;
  font-weight: 800;
  margin-top: 16px;
}

.dashboard-subtitle {
  color: #c4d3e6;
  margin-top: 14px;
  max-width: 680px;
}

.dashboard-hero-badges {
  display: grid;
  gap: 12px;
}

.hero-badge {
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(8, 17, 35, 0.55);
  border: 1px solid rgba(125, 211, 252, 0.2);
}

.hero-badge strong {
  display: block;
  font-size: 1.1rem;
  margin-top: 6px;
}

.hero-badge-label {
  color: #92aac7;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.dashboard-filter-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: end;
}

.dashboard-filter-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.dashboard-metric-card {
  position: relative;
  overflow: hidden;
}

.dashboard-metric-card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  border-radius: 999px;
}

.dashboard-metric-card.accent-cyan::before {
  background: linear-gradient(180deg, #22d3ee, #38bdf8);
}

.dashboard-metric-card.accent-emerald::before {
  background: linear-gradient(180deg, #4ade80, #10b981);
}

.dashboard-metric-card.accent-amber::before {
  background: linear-gradient(180deg, #fbbf24, #f97316);
}

.dashboard-metric-card.accent-rose::before {
  background: linear-gradient(180deg, #fb7185, #e11d48);
}

.metric-kicker {
  color: #9db1c9;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
}

.metric-value {
  margin-top: 14px;
  font-size: clamp(1.7rem, 2vw, 2.6rem);
  line-height: 1.05;
  font-weight: 800;
}

.metric-value-sm {
  font-size: clamp(1.2rem, 1.8vw, 1.7rem);
}

.metric-meta {
  margin-top: 12px;
  color: #bed0e5;
  font-size: 0.95rem;
}

.dashboard-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.dashboard-card-title {
  font-size: 1.05rem;
  font-weight: 700;
}

.dashboard-card-subtitle {
  color: #90a7c2;
  margin-top: 4px;
  font-size: 0.95rem;
}

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

.trend-chart {
  width: 100%;
  height: auto;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
  padding: 4px;
}

.chart-grid-line {
  stroke: rgba(148, 163, 184, 0.14);
  stroke-width: 1;
}

.chart-legend {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  color: #aabed5;
  font-size: 0.92rem;
}

.chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.chart-legend-note {
  margin-left: auto;
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  display: inline-block;
}

.dot-green {
  background: #22c55e;
}

.dot-cyan {
  background: #38bdf8;
}

.dot-rose {
  background: #fb7185;
}

.chart-axis-labels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(28px, 1fr));
  gap: 8px;
  color: #7f95af;
  font-size: 0.78rem;
}

.performance-bars {
  display: grid;
  gap: 14px;
}

.performance-row {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.6fr) 84px;
  gap: 14px;
  align-items: center;
}

.performance-copy {
  display: grid;
  gap: 4px;
}

.performance-copy span {
  color: #8da4bf;
  font-size: 0.9rem;
}

.performance-track {
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.performance-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #22d3ee, #4f46e5);
}

.performance-score {
  text-align: right;
  font-weight: 700;
  color: #e9f4ff;
}

.bar-chart {
  min-height: 260px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(20px, 1fr));
  gap: 10px;
  align-items: end;
}

.bar-column {
  display: grid;
  gap: 8px;
  align-items: end;
}

.bar-track {
  height: 190px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.bar-fill {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 16px 16px 10px 10px;
}

.bar-fill-cyan {
  background: linear-gradient(180deg, #67e8f9, #2563eb);
}

.bar-value,
.bar-label {
  text-align: center;
  font-size: 0.76rem;
}

.bar-value {
  color: #dcecff;
}

.bar-label {
  color: #7890aa;
}

.dashboard-table-wrap {
  overflow-x: auto;
}

.dashboard-table {
  width: 100%;
  border-collapse: collapse;
}

.dashboard-table th,
.dashboard-table td {
  padding: 14px 12px;
  text-align: left;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  white-space: nowrap;
}

.dashboard-table th {
  color: #8ea5c1;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.table-user-cell {
  display: grid;
  gap: 4px;
}

.table-user-cell span {
  color: #7f95af;
  font-size: 0.84rem;
}

.summary-stack {
  display: grid;
  gap: 12px;
}

.summary-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(148, 163, 184, 0.08);
}

.summary-item span {
  color: #8ea5c1;
}

.summary-item strong {
  text-align: right;
}

.empty-state,
.empty-state-cell {
  color: #7f95af;
  text-align: center;
}

.empty-state-cell {
  padding: 24px 12px;
}

@media (max-width: 1280px) {
  .dashboard-hero-grid,
  .dashboard-filter-grid {
    grid-template-columns: 1fr;
  }

  .settings-theme-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .performance-row {
    grid-template-columns: 1fr;
  }

  .chart-legend-note {
    margin-left: 0;
  }

  .summary-item {
    align-items: flex-start;
    flex-direction: column;
  }
}

.kanban-view-pill.is-active {
  background: linear-gradient(135deg, #67e8f9, #818cf8);
  color: #08111f;
}

.btn-compact {
  padding: 8px 12px;
  font-size: 13px;
}

.kanban-stage-manage {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.kanban-stage-rename-form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.kanban-stage-rename-form .input {
  flex: 1 1 180px;
}

.kanban-stage-editor {
  width: 100%;
}

.kanban-stage-editor summary {
  list-style: none;
}

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

.kanban-stage-editor[open] {
  display: grid;
  gap: 12px;
  width: 100%;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.22);
  background: rgba(9, 22, 44, 0.72);
}

.kanban-column-add {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 18px;
  border-style: solid;
  background: rgba(9, 22, 46, 0.72);
}

.kanban-add-column-card {
  width: 100%;
}

.kanban-add-column-card[open] {
  display: grid;
  gap: 14px;
  width: 100%;
}

.kanban-add-trigger {
  width: 100%;
  min-height: 140px;
  border-radius: 18px;
  border: 1px dashed rgba(125, 211, 252, 0.4);
  background: rgba(14, 35, 68, 0.75);
  color: #dbeafe;
  display: grid;
  place-items: center;
  gap: 10px;
  cursor: pointer;
  transition: 0.2s ease;
  text-align: center;
  list-style: none;
}

.kanban-add-trigger::-webkit-details-marker {
  display: none;
}

.kanban-add-trigger span {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  background: linear-gradient(135deg, rgba(103, 232, 249, 0.16), rgba(129, 140, 248, 0.2));
  color: #67e8f9;
}

.kanban-add-trigger small {
  color: #b8d0ea;
  font-size: 0.78rem;
}

.kanban-add-trigger:hover {
  transform: translateY(-2px);
  border-color: rgba(125, 211, 252, 0.65);
}

.kanban-add-form {
  width: 100%;
  display: grid;
  gap: 12px;
}

.kanban-card {
  background: rgba(16, 37, 72, 0.9);
  border-radius: 14px;
  border: 1px solid rgba(125, 211, 252, 0.2);
  padding: 12px;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.35);
  margin-bottom: 12px;
  cursor: grab;
}

.kanban-column-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding-right: 6px;
  scrollbar-width: thin;
  scrollbar-color: rgba(125, 211, 252, 0.45) rgba(9, 20, 41, 0.28);
}

.kanban-column-list::-webkit-scrollbar {
  width: 10px;
}

.kanban-column-list::-webkit-scrollbar-track {
  background: rgba(9, 20, 41, 0.28);
  border-radius: 999px;
}

.kanban-column-list::-webkit-scrollbar-thumb {
  background: rgba(125, 211, 252, 0.45);
  border-radius: 999px;
}

.kanban-carousel-nav {
  position: static;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 14px 18px;
  width: fit-content;
  max-width: 100%;
  margin: 0 auto;
  border-radius: 20px;
  border: 1px solid rgba(125, 211, 252, 0.22);
  background: rgba(6, 18, 38, 0.88);
  backdrop-filter: blur(12px);
  box-shadow: 0 18px 34px rgba(2, 8, 23, 0.35);
}

.kanban-carousel-arrow {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.3);
  background: rgba(9, 22, 44, 0.92);
  color: #e5f1ff;
  font-size: 1.2rem;
  cursor: pointer;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}

.kanban-carousel-arrow:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 211, 252, 0.55);
  background: rgba(12, 30, 58, 0.96);
}

.kanban-card:active {
  cursor: grabbing;
}

body.kanban-dragging {
  overflow: hidden;
}

.alert {
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 700;
  border: 1px solid transparent;
}

.alert-success {
  background: rgba(22, 163, 74, 0.12);
  color: #86efac;
  border-color: rgba(22, 163, 74, 0.3);
}

.alert-error {
  background: rgba(220, 38, 38, 0.12);
  color: #fca5a5;
  border-color: rgba(220, 38, 38, 0.3);
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th {
  text-align: left;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  padding: 10px 8px;
}

.table td {
  padding: 10px 8px;
  border-top: 1px solid rgba(125, 211, 252, 0.2);
}

.table tbody tr {
  transition: background .2s ease;
}

.table tbody tr:hover {
  background: rgba(59, 130, 246, 0.08);
}

main .text-slate-600,
main .text-slate-500 {
  color: #b6b6b6 !important;
}

.auth-body .text-slate-600,
.auth-body .text-slate-500 {
  color: #b6b6b6 !important;
}

main .text-green-600 {
  color: #86efac !important;
}

main .text-red-600 {
  color: #fca5a5 !important;
}

#globalSearchResults {
  background: #0d1f3e !important;
  border-color: rgba(125, 211, 252, 0.35) !important;
  color: #f1f1f1;
}

#globalSearch {
  padding-right: 42px;
}

.search-icon-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  color: #9fb1c8;
  border: 0;
  background: transparent;
  cursor: pointer;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: color .2s ease, transform .2s ease;
}

.search-icon-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.search-icon-btn:hover {
  color: #dbeafe;
  transform: translateY(-50%) scale(1.07);
}

.settings-hero-card {
  overflow: hidden;
  position: relative;
}

.settings-hero-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top right, rgba(103, 232, 249, 0.14), transparent 38%),
    radial-gradient(circle at bottom left, rgba(129, 140, 248, 0.14), transparent 42%);
  pointer-events: none;
}

.settings-hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 18px;
}

.settings-suggestion-card {
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.24);
  background: linear-gradient(165deg, rgba(18, 44, 82, 0.84), rgba(8, 21, 40, 0.95));
  padding: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.settings-suggestion-eyebrow {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #9fc4ef;
  font-weight: 700;
  margin-bottom: 10px;
}

.settings-suggestion-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #f5fbff;
}

.settings-suggestion-description {
  margin-top: 10px;
  color: #c6d7ee;
  line-height: 1.55;
}

.settings-preset-appearance {
  margin-top: 14px;
  color: #b9cde5;
  font-size: 0.92rem;
}

.settings-preset-appearance strong {
  color: #ffffff;
}

.settings-suggestion-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.settings-suggestion-item {
  border-radius: 14px;
  border: 1px solid rgba(125, 211, 252, 0.15);
  background: rgba(255, 255, 255, 0.04);
  padding: 11px 13px;
  color: #e7f2ff;
  line-height: 1.45;
}

.settings-toggle-card {
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(255, 255, 255, 0.03);
  padding: 14px;
  transition: border-color .2s ease, transform .2s ease, background .2s ease;
}

.settings-toggle-card:hover {
  transform: translateY(-2px);
  border-color: rgba(125, 211, 252, 0.36);
  background: rgba(59, 130, 246, 0.08);
}

.notif-bell-btn {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 !important;
  min-width: 48px;
  min-height: 48px !important;
  aspect-ratio: 1 / 1;
  gap: 0;
  cursor: pointer;
  background: radial-gradient(circle at top, rgba(56, 189, 248, 0.2), transparent 60%),
              linear-gradient(135deg, rgba(15, 23, 42, 0.8), rgba(30, 41, 59, 0.85));
  border: 1px solid rgba(148, 163, 184, 0.3);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.25);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.topbar .notif-bell-btn {
  border-radius: 999px !important;
}

.notif-bell-icon {
  display: none;
  width: 20px;
  height: 20px;
  color: #e2e8f0;
}

.notif-bell-icon svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.notif-bell-icon svg path[stroke] {
  fill: none;
}

.notif-bell-btn.is-default .notif-bell-default,
.notif-bell-btn.is-enabled .notif-bell-active,
.notif-bell-btn.is-blocked .notif-bell-blocked,
.notif-bell-btn.is-muted .notif-bell-blocked {
  display: inline-flex;
}

.notif-bell-btn:not(.is-enabled):not(.is-blocked):not(.is-muted) .notif-bell-default {
  display: inline-flex;
}

.notif-bell-btn.is-enabled {
  border-color: rgba(74, 222, 128, 0.55);
  color: #22c55e;
}

.notif-bell-btn.is-blocked,
.notif-bell-btn.is-muted {
  border-color: rgba(248, 113, 113, 0.6);
  color: #fca5a5;
}

.notif-bell-btn.is-blocked {
  cursor: not-allowed;
}

.notif-bell-btn:hover {
  transform: translateY(-1px) scale(1.02);
  border-color: rgba(125, 211, 252, 0.6);
  box-shadow: 0 14px 26px rgba(15, 23, 42, 0.32);
}

.notif-bell-btn.is-loading::after {
  content: '';
  position: absolute;
  width: 54px;
  height: 54px;
  border-radius: 999px;
  border: 2px solid rgba(56, 189, 248, 0.4);
  border-top-color: transparent;
  animation: bellSpin 0.8s linear infinite;
}

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

.notification-choice-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 14px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  background: rgba(15, 23, 42, 0.35);
}

.notification-choice-buttons {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.choice-pill {
  border-radius: 999px;
  padding: 8px 14px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(15, 23, 42, 0.65);
  color: #e2e8f0;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}

.choice-pill.is-active {
  border-color: rgba(34, 197, 94, 0.7);
  background: rgba(34, 197, 94, 0.18);
  color: #bbf7d0;
}

.choice-pill:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 211, 252, 0.6);
}

html[data-appearance="claro"] .notif-bell-btn {
  background: radial-gradient(circle at top, rgba(59, 130, 246, 0.2), transparent 60%),
              linear-gradient(135deg, rgba(226, 232, 240, 0.9), rgba(241, 245, 249, 0.95));
  border-color: rgba(148, 163, 184, 0.6);
  box-shadow: 0 10px 24px rgba(148, 163, 184, 0.25);
}

html[data-appearance="claro"] .notif-bell-icon {
  color: #0f172a;
}

html[data-appearance="claro"] .notif-bell-btn.is-enabled .notif-bell-active {
  color: #16a34a;
}

@media (prefers-color-scheme: light) {
  html[data-appearance="system"] .notif-bell-btn.is-enabled .notif-bell-active {
    color: #16a34a;
  }
}


html[data-appearance="claro"] .notification-choice-group {
  background: rgba(248, 250, 252, 0.95);
  border-color: rgba(148, 163, 184, 0.35);
}

html[data-appearance="claro"] .choice-pill {
  background: rgba(255, 255, 255, 0.9);
  color: #0f172a;
}

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

.settings-theme-card {
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(255, 255, 255, 0.03);
  padding: 12px;
  display: grid;
  gap: 10px;
  text-align: left;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}

.settings-theme-card:hover {
  transform: translateY(-2px);
  border-color: rgba(125, 211, 252, 0.35);
}

.settings-theme-card.is-selected {
  border-color: rgba(103, 232, 249, 0.65);
  background: rgba(103, 232, 249, 0.08);
  box-shadow: 0 12px 24px rgba(8, 23, 46, 0.18);
}

.settings-theme-card-title {
  font-size: 0.92rem;
  font-weight: 700;
}

.settings-theme-card-preview {
  height: 72px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: block;
  position: relative;
  overflow: hidden;
}

.settings-theme-card-preview::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 10px;
  width: 22%;
  height: 52px;
  border-radius: 10px;
}

.settings-theme-card-preview::after {
  content: '';
  position: absolute;
  right: 10px;
  top: 10px;
  width: 58%;
  height: 12px;
  border-radius: 999px;
  box-shadow: 0 18px 0 0 currentColor, 0 36px 0 0 currentColor;
  opacity: .85;
}

.preview-light {
  background: linear-gradient(180deg, #f8fbff, #e7eef8);
  color: #93a4ba;
}

.preview-light::before {
  background: linear-gradient(180deg, #d9e8fb, #f8fbff);
}

.preview-dark {
  background: linear-gradient(180deg, #09111f, #111c2f);
  color: #5f7390;
}

.preview-dark::before {
  background: linear-gradient(180deg, #162641, #0d1728);
}

.preview-system {
  background: linear-gradient(180deg, #102340, #0a1730);
  color: #88a9cf;
}

.preview-system::before {
  background: linear-gradient(180deg, #153055, #102340);
}

.settings-toggle-card input {
  accent-color: #7dd3fc;
}

.logout-btn,
.btn-primary,
.btn-secondary,
.btn-danger {
  box-shadow: 0 10px 24px rgba(2, 8, 23, 0.14);
}

.ranking-shell {
  position: relative;
}

.ranking-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at top left, rgba(250, 204, 21, 0.16), transparent 26%),
    radial-gradient(circle at top right, rgba(226, 232, 240, 0.16), transparent 28%),
    linear-gradient(135deg, rgba(10, 24, 48, 0.96), rgba(18, 39, 70, 0.92));
}

.ranking-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) 320px;
  gap: 24px;
  align-items: start;
}

.ranking-kicker {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
  color: #93c5fd;
}

.ranking-title {
  margin-top: 12px;
  font-size: clamp(1.8rem, 2.8vw, 3rem);
  line-height: 1.04;
  font-weight: 800;
}

.ranking-subtitle {
  margin-top: 12px;
  color: #d7e5f5;
}

.ranking-message-stack {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  max-width: 640px;
}

.ranking-message-card {
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  color: #eef6ff;
  font-weight: 700;
}

.ranking-message-card--gold {
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.30), rgba(120, 53, 15, 0.14));
  border-color: rgba(250, 204, 21, 0.34);
  color: #fff7db;
}

.ranking-message-card--silver {
  background: linear-gradient(135deg, rgba(226, 232, 240, 0.20), rgba(71, 85, 105, 0.14));
  border-color: rgba(203, 213, 225, 0.28);
}

.ranking-message-card--bronze {
  background: linear-gradient(135deg, rgba(251, 146, 60, 0.22), rgba(120, 53, 15, 0.14));
  border-color: rgba(249, 115, 22, 0.26);
  color: #ffedd5;
}

.ranking-message-card--champion {
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.34), rgba(255, 236, 179, 0.18));
  border-color: rgba(250, 204, 21, 0.38);
  color: #fff9e7;
}

.ranking-filter-form {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.ranking-section-head {
  margin-bottom: 18px;
}

.ranking-podium-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: end;
}

.ranking-podium-card {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  padding: 20px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 18px 32px rgba(15, 23, 42, 0.24);
  animation: podiumRise .6s ease both;
}

.ranking-podium-1 {
  min-height: 300px;
  background:
    linear-gradient(180deg, rgba(255, 248, 214, 0.28), rgba(244, 190, 32, 0.32)),
    linear-gradient(155deg, rgba(126, 77, 15, 0.94), rgba(246, 194, 59, 0.84));
}

.ranking-podium-2 {
  min-height: 255px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.22), rgba(203, 213, 225, 0.24)),
    linear-gradient(155deg, rgba(71, 85, 105, 0.94), rgba(192, 200, 212, 0.84));
}

.ranking-podium-3 {
  min-height: 235px;
  background:
    linear-gradient(180deg, rgba(255, 233, 216, 0.18), rgba(194, 120, 54, 0.26)),
    linear-gradient(155deg, rgba(120, 53, 15, 0.96), rgba(197, 111, 39, 0.84));
}

.ranking-medal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(8, 15, 28, 0.24);
  color: #fff8ea;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ranking-place {
  margin-top: 18px;
  font-size: 3rem;
  font-weight: 900;
  color: rgba(255, 255, 255, 0.96);
  text-shadow: 0 10px 20px rgba(15, 23, 42, 0.24);
}

.ranking-name {
  margin-top: 10px;
  font-size: 1.32rem;
  font-weight: 800;
  color: #ffffff;
}

.ranking-score {
  margin-top: 10px;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 800;
}

.ranking-meta {
  margin-top: 6px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.92rem;
}

.ranking-table .ranking-table-row--podium {
  font-weight: 700;
}

.ranking-table .ranking-table-row--1 {
  background: rgba(250, 204, 21, 0.12);
}

.ranking-table .ranking-table-row--2 {
  background: rgba(226, 232, 240, 0.10);
}

.ranking-table .ranking-table-row--3 {
  background: rgba(249, 115, 22, 0.10);
}

.ranking-confetti {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.ranking-confetti span {
  position: absolute;
  top: -22px;
  left: var(--confetti-left);
  width: 10px;
  height: 24px;
  border-radius: 999px;
  opacity: 0;
  background: linear-gradient(180deg, #fde68a, #f59e0b);
  animation: rankingConfetti 2.4s ease-in-out infinite;
  animation-delay: var(--confetti-delay);
}

.ranking-confetti span:nth-child(3n) {
  background: linear-gradient(180deg, #e2e8f0, #94a3b8);
}

.ranking-confetti span:nth-child(4n) {
  background: linear-gradient(180deg, #fdba74, #c2410c);
}

.ranking-confetti--soft span {
  animation-duration: 3.2s;
  opacity: 0.45;
}

.location-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.location-map-shell {
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.28);
  overflow: hidden;
  background: rgba(9, 23, 46, 0.78);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.location-map {
  width: 100%;
  height: 360px;
  display: block;
  border: 0;
  background:
    linear-gradient(180deg, rgba(11, 29, 55, 0.82), rgba(8, 19, 37, 0.92)),
    radial-gradient(circle at center, rgba(125, 211, 252, 0.18), transparent 58%);
}

.location-picker-note {
  border-radius: 14px;
  border: 1px solid rgba(125, 211, 252, 0.22);
  background: rgba(10, 28, 54, 0.58);
  color: #cfe3fb;
  padding: 12px 14px;
  font-size: 0.9rem;
}

.location-search-results {
  margin-top: 10px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.22);
  background: rgba(7, 22, 43, 0.96);
  overflow: hidden;
  max-height: 260px;
  overflow-y: auto;
  box-shadow: 0 18px 36px rgba(2, 8, 23, 0.28);
}

.location-search-result {
  width: 100%;
  text-align: left;
  padding: 12px 14px;
  border: 0;
  border-top: 1px solid rgba(125, 211, 252, 0.12);
  background: transparent;
  color: #e5f1ff;
  cursor: pointer;
  transition: background 0.2s ease;
}

.location-search-result:first-child {
  border-top: 0;
}

.location-search-result:hover {
  background: rgba(59, 130, 246, 0.14);
}

.location-search-result:focus-visible {
  outline: 2px solid rgba(125, 211, 252, 0.55);
  outline-offset: -2px;
  background: rgba(59, 130, 246, 0.16);
}

.location-search-result strong {
  display: block;
  font-size: 0.96rem;
}

.location-search-result span {
  display: block;
  margin-top: 4px;
  font-size: 0.82rem;
  color: #c4d5eb;
}

.location-selected-card {
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.28);
  background:
    linear-gradient(160deg, rgba(15, 35, 68, 0.82), rgba(8, 24, 48, 0.96)),
    radial-gradient(circle at top right, rgba(103, 232, 249, 0.12), transparent 45%);
  padding: 16px 18px;
  box-shadow: 0 18px 36px rgba(2, 8, 23, 0.24);
}

.location-selected-card strong {
  display: block;
  color: #f4f8ff;
  font-size: 0.98rem;
}

.location-selected-card span {
  display: block;
  margin-top: 6px;
  color: #bfd5f0;
  font-size: 0.86rem;
  line-height: 1.45;
}

@keyframes podiumRise {
  from {
    opacity: 0;
    transform: translateY(18px) scale(.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes rankingConfetti {
  0% {
    opacity: 0;
    transform: translate3d(0, -20px, 0) rotate(0deg);
  }
  15% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate3d(24px, 240px, 0) rotate(340deg);
  }
}

@media (max-width: 1024px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .settings-hero-grid {
    grid-template-columns: 1fr;
  }

  .ranking-hero-grid,
  .ranking-podium-grid {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: 270px;
    transform: translateX(-100%);
    transition: transform 0.2s ease;
    z-index: 50;
  }

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

  .location-search-row {
    grid-template-columns: 1fr;
  }

  .location-map {
    height: 300px;
  }

  .kanban-view-switch {
    width: 100%;
    justify-content: flex-start;
  }

  .kanban-column {
    flex-basis: 300px;
    height: min(66vh, 720px);
  }

  .kanban-scroll-controls {
    justify-items: start;
  }

  .kanban-carousel-nav {
    gap: 10px;
    align-items: flex-start;
    width: calc(100% - 12px);
    max-width: calc(100% - 12px);
    padding: 12px;
  }

  .kanban-carousel-dots {
    gap: 8px;
  }
}

.password-field {
  position: relative;
}

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

.password-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: #b6b6b6;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.password-toggle:hover {
  color: #e2e8f0;
}

.password-toggle span {
  position: absolute;
  inset: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: opacity .2s ease, transform .2s ease;
}

.password-toggle svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.password-toggle .icon-eye-open {
  opacity: 1;
  transform: scale(1);
}

.password-toggle .icon-eye-closed {
  opacity: 0;
  transform: scale(.75);
}

.password-toggle.is-visible .icon-eye-open {
  opacity: 0;
  transform: scale(.75);
}

.password-toggle.is-visible .icon-eye-closed {
  opacity: 1;
  transform: scale(1);
}

.logout-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid rgba(220, 38, 38, 0.62);
  background: linear-gradient(120deg, rgba(153, 27, 27, 0.95), rgba(185, 28, 28, 0.95));
  color: #fee2e2;
  font-size: 0.875rem;
  font-weight: 700;
  box-shadow: 0 6px 14px rgba(127, 29, 29, 0.28);
  transition: transform .22s ease, box-shadow .22s ease, filter .22s ease;
}

.logout-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  transition: transform .22s ease;
}

.logout-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
  box-shadow: 0 9px 18px rgba(185, 28, 28, 0.32);
}

.logout-btn:hover svg {
  animation: doorExit .5s ease;
}

html[data-appearance="claro"] .logout-btn {
  border-color: rgba(248, 113, 113, 0.75);
  background: linear-gradient(120deg, #f43f5e, #ef4444);
  color: #ffffff !important;
  box-shadow: 0 8px 16px rgba(248, 113, 113, 0.22);
}

html[data-appearance="claro"] .logout-btn span,
html[data-appearance="claro"] .logout-btn svg {
  color: #ffffff !important;
  fill: #ffffff !important;
}

@media (prefers-color-scheme: light) {
  html[data-appearance="system"] .logout-btn {
    border-color: rgba(248, 113, 113, 0.75);
    background: linear-gradient(120deg, #f43f5e, #ef4444);
    color: #ffffff !important;
    box-shadow: 0 8px 16px rgba(248, 113, 113, 0.22);
  }

  html[data-appearance="system"] .logout-btn span,
  html[data-appearance="system"] .logout-btn svg {
    color: #ffffff !important;
    fill: #ffffff !important;
  }
}

@keyframes doorExit {
  0% {
    transform: translateX(0);
  }
  35% {
    transform: translateX(-1px);
  }
  70% {
    transform: translateX(2px);
  }
  100% {
    transform: translateX(0);
  }
}

html[data-appearance="claro"] .dashboard-hero,
html[data-appearance="claro"] .dashboard-eyebrow,
html[data-appearance="claro"] .hero-badge,
html[data-appearance="claro"] .kanban-view-switch,
html[data-appearance="claro"] .kanban-column,
html[data-appearance="claro"] .kanban-card,
html[data-appearance="claro"] .kanban-carousel-nav,
html[data-appearance="claro"] .kanban-carousel-arrow,
html[data-appearance="claro"] .settings-suggestion-card,
html[data-appearance="claro"] #globalSearchResults {
  color: #111827 !important;
  border-color: rgba(203, 213, 225, 0.85) !important;
  box-shadow:
    0 18px 34px rgba(148, 163, 184, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

html[data-appearance="claro"] .dashboard-hero,
html[data-appearance="claro"] .kanban-column,
html[data-appearance="claro"] .settings-suggestion-card,
html[data-appearance="claro"] #globalSearchResults {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 250, 252, 0.98)) !important;
}

html[data-appearance="claro"] .dashboard-eyebrow,
html[data-appearance="claro"] .hero-badge,
html[data-appearance="claro"] .kanban-view-switch,
html[data-appearance="claro"] .kanban-card,
html[data-appearance="claro"] .kanban-carousel-nav,
html[data-appearance="claro"] .kanban-carousel-arrow {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(243, 247, 251, 0.98)) !important;
}

html[data-appearance="claro"] .dashboard-title,
html[data-appearance="claro"] .hero-badge strong,
html[data-appearance="claro"] .settings-suggestion-title,
html[data-appearance="claro"] .kanban-column,
html[data-appearance="claro"] .kanban-card,
html[data-appearance="claro"] #globalSearchResults {
  color: #0f172a !important;
}

html[data-appearance="claro"] .dashboard-subtitle,
html[data-appearance="claro"] .hero-badge-label,
html[data-appearance="claro"] .settings-suggestion-description,
html[data-appearance="claro"] .settings-preset-appearance,
html[data-appearance="claro"] .settings-suggestion-eyebrow,
html[data-appearance="claro"] .kanban-view-pill,
html[data-appearance="claro"] .metric-kicker,
html[data-appearance="claro"] .metric-meta,
html[data-appearance="claro"] .dashboard-card-subtitle {
  color: #475569 !important;
}

html[data-appearance="claro"] .settings-suggestion-item,
html[data-appearance="claro"] .location-selected-card,
html[data-appearance="claro"] .location-picker-note,
html[data-appearance="claro"] .location-search-results,
html[data-appearance="claro"] .location-search-result {
  background: #ffffff !important;
  border-color: rgba(203, 213, 225, 0.85) !important;
  box-shadow:
    0 16px 28px rgba(148, 163, 184, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
}

html[data-appearance="claro"] .settings-suggestion-item,
html[data-appearance="claro"] .location-selected-card,
html[data-appearance="claro"] .location-picker-note,
html[data-appearance="claro"] .location-search-result {
  color: #0f172a !important;
}

html[data-appearance="claro"] .settings-suggestion-item,
html[data-appearance="claro"] .location-selected-card span,
html[data-appearance="claro"] .location-search-result span {
  color: #334155 !important;
}

html[data-appearance="claro"] .location-selected-card strong,
html[data-appearance="claro"] .location-search-result strong {
  color: #020617 !important;
}

html[data-appearance="claro"] .location-search-result:hover,
html[data-appearance="claro"] .location-search-result:focus-visible {
  background: linear-gradient(180deg, rgba(241, 245, 249, 0.96), rgba(226, 232, 240, 0.96)) !important;
}

html[data-appearance="system"] .sidebar {
  border-right-color: rgba(255, 255, 255, 0.28);
  box-shadow:
    inset -1px 0 0 rgba(255, 255, 255, 0.42),
    18px 0 40px rgba(70, 95, 126, 0.14);
}

html[data-appearance="system"] .sidebar .nav-link:hover,
html[data-appearance="system"] .sidebar .nav-link.active {
  border-color: rgba(145, 186, 230, 0.42);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0.18)),
    linear-gradient(90deg, rgba(146, 209, 244, 0.30), rgba(188, 218, 255, 0.26));
}

html[data-appearance="system"] .topbar {
  border-bottom-color: rgba(255, 255, 255, 0.28);
  box-shadow: 0 18px 34px rgba(120, 145, 173, 0.14);
}

html[data-appearance="system"] .card {
  border-color: rgba(160, 190, 224, 0.24);
  box-shadow:
    0 18px 36px rgba(120, 145, 173, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.56);
}

html[data-appearance="system"] .dashboard-hero {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.10), rgba(255, 255, 255, 0.03)),
    radial-gradient(circle at top right, rgba(166, 210, 250, 0.20), transparent 34%),
    radial-gradient(circle at bottom left, rgba(218, 235, 252, 0.10), transparent 38%),
    linear-gradient(135deg, rgba(33, 57, 89, 0.96), rgba(70, 104, 145, 0.90));
  border: 1px solid rgba(206, 226, 247, 0.22);
  box-shadow:
    0 22px 46px rgba(91, 120, 155, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

html[data-appearance="system"] .dashboard-hero::after {
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), transparent 70%);
}

html[data-appearance="system"] .dashboard-eyebrow,
html[data-appearance="system"] .hero-badge,
html[data-appearance="system"] .settings-suggestion-card,
html[data-appearance="system"] #globalSearchResults {
  border-color: rgba(210, 228, 248, 0.24) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.10);
}

html[data-appearance="system"] .dashboard-eyebrow,
html[data-appearance="system"] .hero-badge {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.04)),
    linear-gradient(150deg, rgba(36, 67, 104, 0.84), rgba(58, 93, 135, 0.78));
}

html[data-appearance="system"] .dashboard-title,
html[data-appearance="system"] .hero-badge strong,
html[data-appearance="system"] .settings-suggestion-title,
html[data-appearance="system"] #globalSearchResults {
  color: #f5f9ff;
}

html[data-appearance="system"] .dashboard-subtitle,
html[data-appearance="system"] .hero-badge-label,
html[data-appearance="system"] .settings-suggestion-description,
html[data-appearance="system"] .settings-preset-appearance,
html[data-appearance="system"] .settings-suggestion-eyebrow {
  color: #d8e6f7;
}

html[data-appearance="system"] .kanban-view-switch {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(236, 242, 248, 0.92)),
    linear-gradient(150deg, rgba(219, 230, 241, 0.74), rgba(204, 219, 235, 0.68));
  border-color: rgba(180, 199, 221, 0.44) !important;
  box-shadow:
    0 12px 24px rgba(120, 145, 173, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

html[data-appearance="system"] .kanban-view-pill {
  color: #1e293b;
}

html[data-appearance="system"] .kanban-column {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.10), rgba(255, 255, 255, 0.03)),
    linear-gradient(180deg, rgba(49, 74, 107, 0.94), rgba(68, 95, 130, 0.92));
  border-color: rgba(211, 226, 244, 0.26) !important;
  color: #f8fbff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 18px 34px rgba(78, 104, 137, 0.20);
}

html[data-appearance="system"] .kanban-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(240, 245, 251, 0.94)),
    linear-gradient(165deg, rgba(217, 228, 240, 0.46), rgba(197, 214, 232, 0.42));
  border-color: rgba(196, 214, 234, 0.58) !important;
  color: #0f172a;
  box-shadow: 0 10px 18px rgba(67, 92, 126, 0.22);
}

html[data-appearance="system"] .kanban-carousel-nav {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(236, 242, 248, 0.92)),
    linear-gradient(160deg, rgba(217, 228, 240, 0.58), rgba(197, 214, 232, 0.54));
  border-color: rgba(188, 208, 230, 0.54) !important;
}

html[data-appearance="system"] .kanban-carousel-arrow {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(239, 244, 249, 0.96)),
    linear-gradient(165deg, rgba(214, 226, 239, 0.44), rgba(193, 210, 229, 0.40));
  border-color: rgba(188, 208, 230, 0.54) !important;
  color: #1e293b;
}

html[data-appearance="system"] #globalSearchResults,
html[data-appearance="system"] .settings-suggestion-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.05)),
    linear-gradient(160deg, rgba(40, 68, 105, 0.88), rgba(59, 93, 133, 0.82)) !important;
}

html[data-appearance="system"] .kanban-card *,
html[data-appearance="system"] .kanban-view-switch *,
html[data-appearance="system"] .kanban-carousel-nav *,
html[data-appearance="system"] .kanban-carousel-arrow * {
  color: inherit;
}

.task-board-shell {
  position: relative;
}

.task-board-hero {
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(103, 232, 249, 0.12), transparent 30%),
    radial-gradient(circle at bottom left, rgba(250, 204, 21, 0.10), transparent 36%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.88));
}

.task-board-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.9fr);
  gap: 24px;
  align-items: center;
}

.task-board-kicker,
.task-panel-kicker,
.task-column-kicker {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
  color: #9ec7f3;
}

.task-board-title {
  margin-top: 14px;
  font-size: clamp(1.8rem, 2.7vw, 3rem);
  line-height: 1.05;
  font-weight: 800;
}

.task-board-subtitle {
  margin-top: 14px;
  max-width: 680px;
  color: #d5e5f6;
}

.task-board-metrics {
  display: grid;
  gap: 12px;
}

.task-mini-stat {
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
}

.task-mini-stat span {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #bdd7f3;
  font-weight: 700;
}

.task-mini-stat strong {
  display: block;
  margin-top: 8px;
  font-size: 1.65rem;
  line-height: 1;
}

.task-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

.task-board-layout {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 24px;
}

.task-toolbar {
  display: grid;
  gap: 16px;
  margin-bottom: 22px;
}

.task-filter-form {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.task-filter-group {
  display: grid;
  gap: 8px;
  min-width: 180px;
}

.task-filter-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

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

.task-delete-rule {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 0.95rem;
}

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

.task-column {
  min-height: 420px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.task-column.is-drop-target {
  border-color: rgba(56, 189, 248, 0.42);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 0 3px rgba(56, 189, 248, 0.12);
}

.task-column-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.task-column-count {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.92rem;
}

.task-column-list {
  display: grid;
  gap: 14px;
}

.task-empty-note {
  padding: 18px;
  border-radius: 18px;
  border: 1px dashed rgba(148, 163, 184, 0.28);
  color: var(--muted);
  font-size: 0.95rem;
  background: rgba(255, 255, 255, 0.03);
}

.task-note {
  position: relative;
  padding: 18px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.16);
  transform: rotate(-0.6deg);
  cursor: pointer;
  user-select: none;
  transition: transform .18s ease, box-shadow .18s ease;
}

.task-note:nth-child(even) {
  transform: rotate(0.8deg);
}

.task-note:hover {
  transform: translateY(-2px) rotate(-0.35deg);
  box-shadow: 0 18px 30px rgba(15, 23, 42, 0.20);
}

.task-note::after {
  content: '';
  position: absolute;
  top: 12px;
  right: 18px;
  width: 34px;
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  filter: blur(0.2px);
  opacity: 0.72;
}

.task-note-overdue {
  background: linear-gradient(180deg, #ffd8d6, #ffb9b4) !important;
  color: #442323 !important;
}

.task-note-today {
  background: linear-gradient(180deg, #fff1c2, #ffd87d) !important;
  color: #4a3412 !important;
}

.task-note-upcoming {
  background: linear-gradient(180deg, #d9f0ff, #b9ddff) !important;
  color: #18304a !important;
}

.task-note-neutral {
  background: linear-gradient(180deg, #f7f0db, #e9dbb2) !important;
  color: #403623 !important;
}

.task-note-done {
  background: linear-gradient(180deg, #daf9e2, #afecca) !important;
  color: #143222 !important;
}

.task-note-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.task-note-priority,
.task-note-flag {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.46);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.task-note-title {
  margin-top: 14px;
  font-size: 1.06rem;
  line-height: 1.3;
  font-weight: 800;
}

.task-note-description {
  margin-top: 10px;
  font-size: 0.95rem;
  line-height: 1.5;
  color: inherit;
  opacity: 0.88;
}

.task-note-meta {
  margin-top: 16px;
  display: grid;
  gap: 10px;
}

.task-note-meta div {
  display: grid;
  gap: 3px;
}

.task-note-meta dt {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.72;
  font-weight: 800;
}

.task-note-meta dd {
  margin: 0;
  font-size: 0.94rem;
  font-weight: 700;
}

.task-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 24px;
}

.task-modal.hidden {
  display: none;
}

.task-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.62);
  backdrop-filter: blur(8px);
}

.task-modal-dialog {
  position: relative;
  width: min(680px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  z-index: 1;
}

.task-modal-close {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  background: rgba(255, 255, 255, 0.08);
  font-size: 1.5rem;
  line-height: 1;
}

.task-modal-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

body.task-modal-open {
  overflow: hidden;
}

.task-history-delete {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(185, 28, 28, 0.28);
  background: rgba(254, 226, 226, 0.9);
  color: #7f1d1d;
  font-weight: 800;
}

.task-history-lock {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--muted);
}

.finance-shell {
  position: relative;
}

.finance-hero {
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(103, 232, 249, 0.12), transparent 32%),
    radial-gradient(circle at bottom left, rgba(74, 222, 128, 0.10), transparent 34%),
    linear-gradient(135deg, rgba(8, 20, 42, 0.96), rgba(14, 36, 68, 0.92));
}

.finance-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.8fr);
  gap: 24px;
  align-items: center;
}

.finance-kicker {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
  color: #9ec7f3;
}

.finance-title {
  margin-top: 14px;
  font-size: clamp(1.8rem, 2.7vw, 3rem);
  line-height: 1.05;
  font-weight: 800;
}

.finance-subtitle {
  margin-top: 14px;
  color: #d5e5f6;
}

.finance-balance-card {
  padding: 22px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.finance-balance-card span,
.finance-balance-card small {
  display: block;
}

.finance-balance-card span {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #bad5f3;
  font-weight: 800;
}

.finance-balance-card strong {
  display: block;
  margin-top: 10px;
  font-size: 2rem;
  line-height: 1;
}

.finance-balance-card small {
  margin-top: 12px;
  color: #d7e6f5;
}

.finance-toolbar {
  display: grid;
  gap: 16px;
}

.finance-filter-form {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.finance-filter-group {
  display: grid;
  gap: 8px;
  min-width: 180px;
}

.finance-filter-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
  color: var(--muted);
}

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

.finance-toolbar-note {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
}

.finance-chart {
  min-height: 260px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(24px, 1fr));
  gap: 10px;
  align-items: end;
}

.finance-chart-col {
  display: grid;
  gap: 10px;
  align-items: end;
  justify-items: center;
}

.finance-chart-bars {
  width: 100%;
  height: 210px;
  display: flex;
  align-items: end;
  justify-content: center;
  gap: 6px;
}

.finance-chart-bar {
  width: min(18px, 100%);
  border-radius: 12px 12px 4px 4px;
  min-height: 2px;
}

.finance-chart-bar-in {
  background: linear-gradient(180deg, #4ade80, #16a34a);
}

.finance-chart-bar-out {
  background: linear-gradient(180deg, #fb7185, #dc2626);
}

.finance-chart-col small {
  font-size: 0.76rem;
  color: var(--muted);
}

.finance-stat-card {
  position: relative;
  overflow: hidden;
}

.finance-stat-card span,
.finance-stat-card small {
  display: block;
}

.finance-stat-card span {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
  color: #9db1c9;
}

.finance-stat-card strong {
  display: block;
  margin-top: 12px;
  font-size: 1.95rem;
  line-height: 1.05;
}

.finance-stat-card small {
  margin-top: 10px;
  color: var(--muted);
}

.finance-stat-in::before,
.finance-stat-out::before,
.finance-stat-paid::before,
.finance-stat-bank::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  border-radius: 999px;
}

.finance-stat-in::before {
  background: linear-gradient(180deg, #22c55e, #10b981);
}

.finance-stat-out::before {
  background: linear-gradient(180deg, #fb7185, #ef4444);
}

.finance-stat-paid::before {
  background: linear-gradient(180deg, #38bdf8, #22d3ee);
}

.finance-stat-bank::before {
  background: linear-gradient(180deg, #fbbf24, #f97316);
}

.finance-layout {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 24px;
}

.finance-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

.finance-badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 800;
}

.finance-badge-in {
  background: rgba(34, 197, 94, 0.14);
  color: #4ade80;
}

.finance-badge-out {
  background: rgba(244, 63, 94, 0.14);
  color: #fb7185;
}

.finance-badge-paid {
  background: rgba(56, 189, 248, 0.14);
  color: #7dd3fc;
}

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

.finance-ledger-item {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) 140px 160px;
  gap: 14px;
  align-items: center;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.12);
  background: rgba(255, 255, 255, 0.04);
}

.finance-ledger-in {
  box-shadow: inset 4px 0 0 rgba(34, 197, 94, 0.65);
}

.finance-ledger-out {
  box-shadow: inset 4px 0 0 rgba(244, 63, 94, 0.65);
}

.finance-ledger-title {
  font-weight: 800;
}

.finance-ledger-meta {
  margin-top: 5px;
  font-size: 0.86rem;
  color: var(--muted);
}

.finance-ledger-amount {
  font-size: 1.05rem;
  font-weight: 800;
}

.finance-ledger-side {
  display: grid;
  justify-items: end;
  gap: 6px;
}

.finance-status {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.finance-status-pendente {
  background: rgba(250, 204, 21, 0.14);
  color: #facc15;
}

.finance-status-pago {
  background: rgba(34, 197, 94, 0.14);
  color: #4ade80;
}

.finance-status-cancelado {
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}

.finance-status-form {
  display: flex;
  align-items: center;
  gap: 10px;
}

.finance-confirm-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 24px;
}

.finance-confirm-modal.hidden {
  display: none;
}

.finance-confirm-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.66);
  backdrop-filter: blur(10px);
}

.finance-confirm-dialog {
  position: relative;
  z-index: 1;
  width: min(520px, 100%);
  text-align: center;
  border-radius: 28px;
  box-shadow: 0 28px 60px rgba(2, 6, 23, 0.42);
}

.finance-confirm-icon {
  width: 68px;
  height: 68px;
  margin: 0 auto 14px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  font-weight: 900;
  background: linear-gradient(180deg, rgba(251, 191, 36, 0.22), rgba(249, 115, 22, 0.18));
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.24);
}

.finance-confirm-text {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.6;
}

.finance-confirm-actions {
  margin-top: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

body.finance-confirm-open {
  overflow: hidden;
}

.finance-empty {
  padding: 18px;
  border-radius: 18px;
  border: 1px dashed rgba(148, 163, 184, 0.28);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
}

.documents-shell {
  position: relative;
}

.documents-shell .card {
  opacity: 1;
  transform: none;
}

.documents-hero {
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(125, 211, 252, 0.14), transparent 34%),
    radial-gradient(circle at bottom left, rgba(74, 222, 128, 0.10), transparent 36%),
    linear-gradient(135deg, rgba(8, 20, 42, 0.96), rgba(14, 36, 68, 0.92));
}

.documents-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(320px, 0.8fr);
  gap: 24px;
  align-items: center;
}

.documents-kicker {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
  color: #9ec7f3;
}

.documents-title {
  margin-top: 14px;
  font-size: clamp(1.8rem, 2.7vw, 3rem);
  line-height: 1.05;
  font-weight: 800;
}

.documents-subtitle {
  margin-top: 14px;
  color: #d5e5f6;
}

.documents-help-card {
  padding: 22px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.documents-help-title {
  font-weight: 800;
  margin-bottom: 12px;
}

.documents-help-list {
  margin: 0;
  padding-left: 18px;
  color: #d7e6f5;
  display: grid;
  gap: 8px;
}

.documents-layout {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 24px;
}

.documents-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

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

.documents-template-item-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.documents-template-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(255, 255, 255, 0.04);
  text-decoration: none;
  color: inherit;
  transition: transform .18s ease, border-color .18s ease;
}

.documents-template-item:hover,
.documents-template-item.is-active {
  transform: translateY(-2px);
  border-color: rgba(125, 211, 252, 0.35);
}

.documents-template-title {
  font-weight: 800;
}

.documents-template-meta {
  margin-top: 5px;
  font-size: 0.86rem;
  color: var(--muted);
}

.documents-template-arrow {
  font-size: 0.84rem;
  font-weight: 800;
  color: #7dd3fc;
}

.documents-selected-summary {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(255, 255, 255, 0.04);
  margin-bottom: 16px;
}

.documents-field-meta {
  margin-top: 6px;
  font-size: 0.84rem;
  color: var(--muted);
}

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

.documents-detected-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(255, 255, 255, 0.04);
}

.documents-detected-title {
  font-weight: 800;
}

.documents-detected-meta {
  margin-top: 5px;
  font-size: 0.86rem;
  color: var(--muted);
}

.documents-detected-side {
  display: grid;
  justify-items: end;
  gap: 6px;
}

.documents-detected-badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(125, 211, 252, 0.14);
  color: #7dd3fc;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.documents-empty {
  padding: 18px;
  border-radius: 18px;
  border: 1px dashed rgba(148, 163, 184, 0.28);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
}

.documents-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.documents-tab {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(255, 255, 255, 0.04);
  color: #dbeafe;
  text-decoration: none;
  font-weight: 700;
  transition: .2s ease;
}

.documents-tab.is-active {
  background: linear-gradient(135deg, #67e8f9, #818cf8);
  color: #08111f;
}

.documents-subtab-head {
  margin-bottom: 18px;
}

.documents-subtab-head--between {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.documents-format-box {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  background: rgba(255, 255, 255, 0.04);
}

.documents-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: inherit;
  font-weight: 600;
}

.documents-config-list {
  display: grid;
  gap: 14px;
}

.documents-config-item {
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  background: rgba(255, 255, 255, 0.04);
}

.documents-config-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

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

.documents-config-flag {
  display: flex;
  align-items: end;
}

.documents-config-grid-full {
  grid-column: 1 / -1;
}

.documents-manual-actions {
  display: flex;
  justify-content: flex-start;
}

.documents-file-input {
  min-height: 64px;
  padding: 12px 14px;
  border-color: rgba(56, 189, 248, 0.34);
  background:
    linear-gradient(160deg, rgba(5, 14, 30, 0.94), rgba(9, 23, 44, 0.94)),
    radial-gradient(circle at right top, rgba(129, 140, 248, 0.18), transparent 40%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 12px 28px rgba(2, 8, 23, 0.24);
}

.documents-file-input-btn {
  padding: 9px 16px;
  font-size: 0.9rem;
}

.documents-file-input-name {
  font-size: 0.95rem;
  color: rgba(226, 232, 240, 0.96);
}

html[data-appearance="claro"] .documents-hero {
  background:
    radial-gradient(circle at top right, rgba(191, 219, 254, 0.38), transparent 34%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.99), rgba(244, 247, 252, 0.98));
}

html[data-appearance="claro"] .documents-title,
html[data-appearance="claro"] .documents-subtitle,
html[data-appearance="claro"] .documents-help-list {
  color: #0f172a;
}

html[data-appearance="claro"] .documents-help-card,
html[data-appearance="claro"] .documents-template-item,
html[data-appearance="claro"] .documents-selected-summary,
html[data-appearance="claro"] .documents-detected-item,
html[data-appearance="claro"] .documents-config-item,
html[data-appearance="claro"] .documents-format-box,
html[data-appearance="claro"] .documents-empty {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(203, 213, 225, 0.75);
}

html[data-appearance="claro"] .documents-kicker,
html[data-appearance="claro"] .documents-help-title,
html[data-appearance="claro"] .documents-template-title,
html[data-appearance="claro"] .documents-selected-summary strong,
html[data-appearance="claro"] .documents-detected-title,
html[data-appearance="claro"] .documents-detected-side small {
  color: #020617 !important;
}

html[data-appearance="claro"] .documents-template-meta,
html[data-appearance="claro"] .documents-field-meta,
html[data-appearance="claro"] .documents-detected-meta,
html[data-appearance="claro"] .documents-selected-summary span,
html[data-appearance="claro"] .documents-empty,
html[data-appearance="claro"] .documents-template-arrow {
  color: #334155 !important;
}

html[data-appearance="claro"] .documents-tab {
  background: #ffffff;
  color: #0f172a;
  border-color: rgba(203, 213, 225, 0.85);
}

html[data-appearance="claro"] .documents-tab.is-active {
  background: linear-gradient(135deg, #7dd3fc, #a5b4fc);
  color: #020617;
}

html[data-appearance="claro"] .documents-file-input {
  border-color: rgba(37, 99, 235, 0.24);
  background:
    linear-gradient(165deg, rgba(255, 255, 255, 0.98), rgba(238, 246, 255, 0.95)),
    radial-gradient(circle at right top, rgba(99, 102, 241, 0.12), transparent 40%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75), 0 10px 22px rgba(15, 23, 42, 0.08);
}

html[data-appearance="claro"] .documents-file-input-name {
  color: #334155;
}

html[data-appearance="claro"] .ranking-hero {
  background:
    radial-gradient(circle at top left, rgba(250, 204, 21, 0.16), transparent 26%),
    radial-gradient(circle at top right, rgba(226, 232, 240, 0.20), transparent 28%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.99), rgba(244, 247, 252, 0.98));
}

html[data-appearance="claro"] .ranking-title,
html[data-appearance="claro"] .ranking-kicker,
html[data-appearance="claro"] .ranking-name {
  color: #020617;
}

html[data-appearance="claro"] .ranking-subtitle,
html[data-appearance="claro"] .ranking-meta {
  color: #334155;
}

html[data-appearance="claro"] .ranking-filter-form {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(203, 213, 225, 0.85);
}

html[data-appearance="claro"] .ranking-message-card {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(203, 213, 225, 0.85);
  color: #0f172a;
}

html[data-appearance="claro"] .ranking-message-card--gold {
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.30), rgba(251, 191, 36, 0.12));
  border-color: rgba(234, 179, 8, 0.40);
  color: #5b4305;
}

html[data-appearance="claro"] .ranking-message-card--silver {
  background: linear-gradient(135deg, rgba(226, 232, 240, 0.92), rgba(203, 213, 225, 0.72));
  border-color: rgba(148, 163, 184, 0.45);
  color: #334155;
}

html[data-appearance="claro"] .ranking-message-card--champion {
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.34), rgba(255, 236, 179, 0.22));
  border-color: rgba(234, 179, 8, 0.42);
  color: #5b4305;
}

html[data-appearance="claro"] .ranking-message-card--bronze {
  background: linear-gradient(135deg, rgba(251, 146, 60, 0.24), rgba(254, 215, 170, 0.18));
  border-color: rgba(249, 115, 22, 0.34);
  color: #7c2d12;
}

html[data-appearance="claro"] input[type="file"].input {
  color: #0f172a !important;
  background: linear-gradient(180deg, #ffffff, #f8fbff) !important;
}

html[data-appearance="claro"] input[type="file"].input::file-selector-button {
  margin-right: 12px;
  border: 1px solid rgba(56, 189, 248, 0.48);
  border-radius: 12px;
  background: linear-gradient(135deg, #67e8f9, #8ea6ff);
  color: #0b1220;
  padding: 10px 16px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
  box-shadow: 0 10px 18px rgba(56, 189, 248, 0.2);
}

html[data-appearance="claro"] input[type="file"].input::file-selector-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(56, 189, 248, 0.24);
  filter: brightness(1.02);
}

html[data-appearance="system"] .documents-hero {
  background:
    radial-gradient(circle at top right, rgba(186, 216, 245, 0.18), transparent 34%),
    linear-gradient(135deg, rgba(35, 57, 88, 0.96), rgba(82, 112, 150, 0.90));
}

html[data-appearance="claro"] .finance-hero {
  background:
    radial-gradient(circle at top right, rgba(191, 219, 254, 0.38), transparent 34%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.99), rgba(244, 247, 252, 0.98));
}

html[data-appearance="claro"] .finance-title,
html[data-appearance="claro"] .finance-subtitle,
html[data-appearance="claro"] .finance-balance-card strong,
html[data-appearance="claro"] .finance-balance-card small {
  color: #0f172a;
}

html[data-appearance="claro"] .finance-balance-card,
html[data-appearance="claro"] .finance-toolbar-note,
html[data-appearance="claro"] .finance-ledger-item {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(203, 213, 225, 0.75);
}

html[data-appearance="system"] .finance-hero {
  background:
    radial-gradient(circle at top right, rgba(186, 216, 245, 0.18), transparent 34%),
    linear-gradient(135deg, rgba(35, 57, 88, 0.96), rgba(82, 112, 150, 0.90));
}

@media (max-width: 1200px) {
  .documents-layout {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 860px) {
  .documents-hero-grid,
  .finance-hero-grid,
  .finance-ledger-item {
    grid-template-columns: 1fr;
  }

  .finance-filter-form,
  .finance-status-form {
    flex-direction: column;
    align-items: stretch;
  }

  .finance-ledger-side {
    justify-items: start;
  }

  .documents-config-grid {
    grid-template-columns: 1fr;
  }
}

.task-stats-table-wrap {
  overflow-x: auto;
}

.task-progress-cell {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 180px;
}

.task-progress-track {
  width: 120px;
  height: 10px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.18);
  overflow: hidden;
}

.task-progress-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #22d3ee, #4ade80);
}

html[data-appearance="claro"] .task-board-hero {
  background:
    radial-gradient(circle at top right, rgba(191, 219, 254, 0.42), transparent 34%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.99), rgba(244, 247, 252, 0.98));
}

html[data-appearance="claro"] .task-board-title,
html[data-appearance="claro"] .task-board-subtitle,
html[data-appearance="claro"] .task-mini-stat strong {
  color: #0f172a;
}

html[data-appearance="claro"] .task-mini-stat,
html[data-appearance="claro"] .task-column,
html[data-appearance="claro"] .task-delete-rule {
  background: rgba(255, 255, 255, 0.88);
  border-color: rgba(203, 213, 225, 0.8);
}

html[data-appearance="system"] .task-board-hero {
  background:
    radial-gradient(circle at top right, rgba(186, 216, 245, 0.22), transparent 34%),
    linear-gradient(135deg, rgba(35, 57, 88, 0.96), rgba(82, 112, 150, 0.90));
}

html[data-appearance="system"] .task-column {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.10), rgba(255, 255, 255, 0.03)),
    linear-gradient(180deg, rgba(48, 72, 106, 0.92), rgba(62, 87, 121, 0.90));
}

html[data-appearance="system"] .task-delete-rule {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(203, 220, 239, 0.24);
}

@media (max-width: 1200px) {
  .task-board-layout {
    grid-template-columns: 1fr;
  }

  .task-board-columns {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .task-board-hero-grid {
    grid-template-columns: 1fr;
  }

  .task-filter-form {
    flex-direction: column;
    align-items: stretch;
  }

  .task-progress-cell {
    min-width: 150px;
  }
}

html[data-appearance="claro"] body,
html[data-appearance="claro"] main,
html[data-appearance="claro"] .card,
html[data-appearance="claro"] .documents-template-item,
html[data-appearance="claro"] .documents-selected-summary,
html[data-appearance="claro"] .documents-detected-item,
html[data-appearance="claro"] .finance-ledger-item,
html[data-appearance="claro"] .finance-balance-card,
html[data-appearance="claro"] .finance-toolbar-note,
html[data-appearance="claro"] .task-mini-stat,
html[data-appearance="claro"] .task-column,
html[data-appearance="claro"] .task-delete-rule {
  color: #0f172a;
}

html[data-appearance="claro"] p,
html[data-appearance="claro"] span,
html[data-appearance="claro"] small,
html[data-appearance="claro"] label,
html[data-appearance="claro"] td,
html[data-appearance="claro"] th,
html[data-appearance="claro"] li,
html[data-appearance="claro"] dd,
html[data-appearance="claro"] dt,
html[data-appearance="claro"] .text-slate-400,
html[data-appearance="claro"] .text-slate-500,
html[data-appearance="claro"] .text-slate-600,
html[data-appearance="claro"] .text-slate-200 {
  color: #475569 !important;
}

html[data-appearance="claro"] h1,
html[data-appearance="claro"] h2,
html[data-appearance="claro"] h3,
html[data-appearance="claro"] h4,
html[data-appearance="claro"] h5,
html[data-appearance="claro"] h6,
html[data-appearance="claro"] strong,
html[data-appearance="claro"] .font-semibold,
html[data-appearance="claro"] .font-bold,
html[data-appearance="claro"] .font-extrabold,
html[data-appearance="claro"] .metric-value,
html[data-appearance="claro"] .documents-title,
html[data-appearance="claro"] .finance-title,
html[data-appearance="claro"] .task-board-title {
  color: #020617 !important;
}

html[data-appearance="claro"] .input,
html[data-appearance="claro"] .textarea,
html[data-appearance="claro"] .select {
  color: #0f172a !important;
}

html[data-appearance="claro"] ::placeholder {
  color: #64748b !important;
}

.products-shell,
.inventory-shell,
.pos-shell {
  position: relative;
}

.products-hero,
.inventory-hero,
.pos-hero {
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(125, 211, 252, 0.16), transparent 32%),
    radial-gradient(circle at bottom left, rgba(74, 222, 128, 0.12), transparent 36%),
    linear-gradient(135deg, rgba(8, 20, 42, 0.96), rgba(14, 36, 68, 0.92));
}

.products-hero-grid,
.inventory-hero-grid,
.pos-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.8fr);
  gap: 24px;
  align-items: center;
}

.products-kicker,
.inventory-kicker,
.pos-kicker {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
  color: #9ec7f3;
}

.products-title,
.inventory-title,
.pos-title {
  margin-top: 14px;
  font-size: clamp(1.8rem, 2.8vw, 3rem);
  line-height: 1.08;
  font-weight: 800;
}

.products-subtitle,
.inventory-subtitle,
.pos-subtitle {
  margin-top: 14px;
  color: #d5e5f6;
  max-width: 720px;
}

.products-hero-actions,
.inventory-hero-actions,
.pos-period-actions,
.products-filter-actions,
.inventory-filter-actions,
.pos-checkout-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.products-filter-form,
.inventory-filter-form {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 16px;
  align-items: end;
}

.products-layout,
.inventory-layout,
.pos-layout {
  display: grid;
  grid-template-columns: 420px minmax(0, 1fr);
  gap: 24px;
}

.products-section-head,
.inventory-section-head,
.pos-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.products-form-grid,
.inventory-form-grid,
.pos-checkout-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.products-form-grid-full {
  grid-column: 1 / -1;
}

.products-check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}

.products-import-form {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) auto;
  gap: 16px;
  align-items: end;
}

.products-import-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.products-item-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.products-thumb {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid rgba(125, 211, 252, 0.35);
  flex: 0 0 52px;
}

.products-edit-preview {
  width: 100%;
  max-width: 180px;
  max-height: 140px;
  border-radius: 10px;
  border: 1px solid rgba(125, 211, 252, 0.3);
  object-fit: cover;
}

.products-edit-details summary {
  list-style: none;
}

.products-edit-details summary::-webkit-details-marker {
  display: none;
}

.products-edit-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(96, 165, 250, 0.42);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.2), rgba(59, 130, 246, 0.18));
  color: #93c5fd;
  font-weight: 700;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
}

.products-edit-trigger:hover {
  transform: translateY(-1px);
  border-color: rgba(96, 165, 250, 0.56);
  box-shadow: 0 10px 20px rgba(2, 6, 23, 0.2);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.28), rgba(99, 102, 241, 0.24));
}

.products-edit-details[open] .products-edit-trigger {
  color: #08111f;
  border-color: rgba(125, 211, 252, 0.56);
  background: linear-gradient(135deg, #67e8f9, #818cf8);
}

html[data-appearance="claro"] .products-edit-trigger {
  color: #0f172a;
  border-color: rgba(147, 197, 253, 0.64);
  background: linear-gradient(135deg, rgba(224, 242, 254, 0.96), rgba(219, 234, 254, 0.94));
}

html[data-appearance="claro"] .products-edit-details[open] .products-edit-trigger {
  color: #020617;
  background: linear-gradient(135deg, #7dd3fc, #a5b4fc);
}

.products-table-wrap,
.inventory-table-wrap,
.pos-sales-table-wrap {
  overflow-x: auto;
}

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

.inventory-stat-card,
.pos-stat-card {
  position: relative;
  overflow: hidden;
}

.inventory-stat-card strong,
.pos-stat-card strong {
  display: block;
  margin-top: 10px;
  font-size: 2rem;
  line-height: 1.02;
}

.inventory-stat-card small,
.pos-stat-card small {
  display: block;
  margin-top: 10px;
  color: var(--muted);
}

.inventory-stat-label,
.pos-stat-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 700;
}

.inventory-risk {
  color: #f59e0b;
}

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

.inventory-alert-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px;
  gap: 14px;
  align-items: center;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(255, 255, 255, 0.04);
}

.inventory-alert-meta {
  margin-top: 5px;
  font-size: 0.86rem;
  color: var(--muted);
}

.inventory-alert-qty {
  display: grid;
  justify-items: end;
  gap: 4px;
}

.inventory-alert-qty span {
  color: var(--muted);
  font-size: 0.88rem;
}

.inventory-row-actions summary {
  list-style: none;
}

.inventory-row-actions summary::-webkit-details-marker {
  display: none;
}

.inventory-row-actions[open] {
  display: grid;
  gap: 12px;
  min-width: 280px;
}

.inventory-qty-missing {
  color: #ef4444;
}

.user-edit-details summary {
  list-style: none;
}

.user-edit-details summary::-webkit-details-marker {
  display: none;
}

.user-edit-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid rgba(96, 165, 250, 0.34);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.18), rgba(59, 130, 246, 0.16));
  color: #93c5fd;
  font-weight: 700;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.user-edit-trigger:hover {
  transform: translateY(-1px);
  border-color: rgba(96, 165, 250, 0.5);
  box-shadow: 0 14px 24px rgba(2, 6, 23, 0.18);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.24), rgba(99, 102, 241, 0.22));
}

.user-edit-details[open] .user-edit-trigger {
  color: #08111f;
  border-color: rgba(125, 211, 252, 0.54);
  background: linear-gradient(135deg, #67e8f9, #818cf8);
}

html[data-appearance="claro"] .user-edit-trigger {
  color: #0f172a;
  border-color: rgba(147, 197, 253, 0.62);
  background: linear-gradient(135deg, rgba(224, 242, 254, 0.96), rgba(219, 234, 254, 0.94));
}

html[data-appearance="claro"] .user-edit-details[open] .user-edit-trigger {
  color: #020617;
  background: linear-gradient(135deg, #7dd3fc, #a5b4fc);
}

.inventory-empty,
.pos-empty {
  padding: 18px;
  border-radius: 18px;
  border: 1px dashed rgba(148, 163, 184, 0.28);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
}

.pos-period-form {
  display: grid;
  gap: 14px;
}

.pos-cash-grid {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 24px;
}

.pos-cash-period-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

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

.pos-cash-form-full {
  grid-column: 1 / -1;
}

.pos-cash-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
}

.pos-scanner-box {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.pos-scanner-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pos-camera-btn {
  white-space: nowrap;
}

.pos-scanner-qty {
  display: grid;
  gap: 6px;
  max-width: 240px;
}

.pos-scanner-input {
  min-height: 58px;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.pos-scanner-help {
  color: var(--muted);
  font-size: 0.92rem;
}

.pos-usb-help {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(56, 189, 248, 0.18);
  background: rgba(15, 23, 42, 0.45);
  color: #cbd5f5;
  display: grid;
  gap: 6px;
  font-size: 0.92rem;
}

.pos-usb-title {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
  color: #7dd3fc;
}

.pos-usb-steps {
  display: grid;
  gap: 4px;
  color: #e2e8f0;
}

.pos-usb-help small {
  color: #94a3b8;
  font-size: 0.8rem;
}

.pos-scanner-status {
  font-size: 0.9rem;
  color: var(--muted);
}

.pos-scanner-status.is-error {
  color: #f87171;
}

.pos-scanner-status.is-success {
  color: #34d399;
}

.pos-remote-box {
  margin-top: 20px;
  padding: 22px;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background:
    radial-gradient(circle at 10% 0%, rgba(56, 189, 248, 0.12), transparent 45%),
    radial-gradient(circle at 90% 10%, rgba(14, 116, 144, 0.2), transparent 40%),
    rgba(15, 23, 42, 0.4);
  box-shadow: 0 18px 40px rgba(2, 6, 23, 0.35);
  display: grid;
  gap: 16px;
}

.pos-remote-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.pos-remote-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.pos-remote-keep {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  color: #cbd5f5;
  cursor: pointer;
}

.pos-remote-keep input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pos-remote-check {
  width: 18px;
  height: 18px;
  border-radius: 6px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.6);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 0 0 1px rgba(2, 6, 23, 0.5);
  transition: all 0.2s ease;
}

.pos-remote-check::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 3px;
  background: transparent;
  transform: scale(0.2);
  transition: all 0.2s ease;
}

.pos-remote-keep input:checked + .pos-remote-check {
  border-color: rgba(56, 189, 248, 0.9);
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.15);
}

.pos-remote-keep input:checked + .pos-remote-check::after {
  background: linear-gradient(135deg, #38bdf8, #22d3ee);
  transform: scale(1);
}

.pos-remote-keep-text {
  font-weight: 600;
}

.pos-remote-connect {
  border-radius: 999px;
  padding: 10px 18px;
  border: 1px solid rgba(56, 189, 248, 0.5);
  background: rgba(14, 116, 144, 0.2);
  color: #e2f2ff;
  box-shadow: 0 10px 24px rgba(2, 6, 23, 0.25);
  font-size: 0.95rem;
}

.pos-remote-connect:hover {
  border-color: rgba(56, 189, 248, 0.85);
  background: rgba(56, 189, 248, 0.16);
}

.pos-remote-body {
  display: grid;
  gap: 8px;
}

.pos-remote-link {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px dashed rgba(148, 163, 184, 0.45);
  color: #d7e4ff;
  word-break: break-all;
  font-size: 0.98rem;
  background: rgba(15, 23, 42, 0.55);
}

.pos-remote-status {
  font-size: 0.98rem;
  color: #cbd5f5;
}

.pos-remote-status.is-error {
  color: #f87171;
}

.pos-remote-status.is-success {
  color: #34d399;
}

.pos-remote-status-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pos-remote-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: #a5b4fc;
}

.pos-remote-indicator::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #64748b;
}

.pos-remote-indicator.is-online {
  color: #34d399;
}

.pos-remote-indicator.is-online::before {
  background: #34d399;
}

.pos-remote-qr {
  min-height: 160px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.pos-remote-qr canvas,
.pos-remote-qr img {
  width: 180px;
  height: 180px;
  border-radius: 18px;
  padding: 12px;
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.pos-remote-last {
  font-size: 0.92rem;
  color: #94a3b8;
}

.pos-remote-uptime {
  font-size: 0.92rem;
  color: #94a3b8;
}

.pos-remote-shell {
  display: grid;
  place-items: center;
  min-height: 70vh;
}

.pos-remote-card {
  width: min(720px, 92vw);
  display: grid;
  gap: 16px;
}

.pos-remote-manual {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.pos-camera-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.72);
  z-index: 1200;
}

.pos-camera-modal.is-open {
  display: flex;
}

.pos-camera-card {
  width: min(720px, 92vw);
}

.pos-camera-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.pos-camera-view {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: #0f172a;
  aspect-ratio: 16 / 9;
}

.pos-camera-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pos-camera-reader {
  position: absolute;
  inset: 0;
}

.pos-camera-reader > video,
.pos-camera-reader > canvas {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
}

.pos-camera-overlay {
  position: absolute;
  inset: 0;
  margin: 18px;
  border-radius: 14px;
  border: 2px dashed rgba(248, 250, 252, 0.6);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 10px;
  color: #f8fafc;
  font-size: 0.9rem;
  text-align: center;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0), rgba(15, 23, 42, 0.45));
}

.pos-camera-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.9rem;
}

.pos-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.9fr);
  gap: 14px;
  margin-bottom: 18px;
}

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

.pos-product-grid.hidden {
  display: none;
}

.pos-product-card {
  width: 100%;
  padding: 16px;
  text-align: left;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.pos-product-card:hover {
  transform: translateY(-2px);
  border-color: rgba(125, 211, 252, 0.38);
  box-shadow: 0 20px 30px rgba(2, 6, 23, 0.16);
}

.pos-product-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.pos-product-meta,
.pos-product-stock,
.pos-cart-meta,
.pos-sale-items {
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.9rem;
}

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

.pos-cart-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 14px;
  align-items: center;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(255, 255, 255, 0.04);
}

.pos-cart-controls,
.pos-cart-side,
.pos-cart-summary {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pos-cart-side {
  flex-direction: column;
  align-items: flex-end;
}

.pos-remove-link {
  background: transparent;
  border: 0;
  color: #f87171;
  font-weight: 700;
  cursor: pointer;
}

.pos-cart-summary {
  justify-content: space-between;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
}

.pos-cart-summary div {
  display: grid;
  gap: 4px;
}

.pos-cart-summary span {
  color: var(--muted);
  font-size: 0.86rem;
}

.pos-cart-summary strong {
  font-size: 1.5rem;
}

.pos-sale-items {
  display: grid;
  gap: 4px;
}

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

.pos-fiscal-item {
  display: grid;
  gap: 6px;
  padding: 10px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(15, 23, 42, 0.35);
}

.pos-fiscal-type {
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: #7dd3fc;
}

.pos-fiscal-status {
  font-size: 0.82rem;
  color: #cbd5f5;
}

.pos-fiscal-status.is-ok {
  color: #34d399;
}

.pos-fiscal-status.is-error {
  color: #f87171;
}

.pos-fiscal-status.is-warn {
  color: #facc15;
}

.pos-fiscal-status.is-info {
  color: #60a5fa;
}

.pos-fiscal-toggle {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.input.is-disabled {
  opacity: 0.6;
  filter: grayscale(0.1);
}

.pos-fiscal-actions {
  display: grid;
  gap: 6px;
}

.pos-fiscal-email-form {
  display: grid;
  gap: 6px;
}

.input-compact {
  padding: 8px 10px;
  font-size: 0.85rem;
}

html[data-appearance="claro"] .products-hero,
html[data-appearance="claro"] .inventory-hero,
html[data-appearance="claro"] .pos-hero {
  background:
    radial-gradient(circle at top right, rgba(191, 219, 254, 0.38), transparent 34%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.99), rgba(244, 247, 252, 0.98));
}

html[data-appearance="claro"] .products-title,
html[data-appearance="claro"] .products-subtitle,
html[data-appearance="claro"] .inventory-title,
html[data-appearance="claro"] .inventory-subtitle,
html[data-appearance="claro"] .pos-title,
html[data-appearance="claro"] .pos-subtitle,
html[data-appearance="claro"] .inventory-alert-item,
html[data-appearance="claro"] .pos-product-card,
html[data-appearance="claro"] .pos-cart-item,
html[data-appearance="claro"] .inventory-empty,
html[data-appearance="claro"] .pos-empty {
  color: #0f172a;
}

html[data-appearance="claro"] .inventory-alert-item,
html[data-appearance="claro"] .pos-product-card,
html[data-appearance="claro"] .pos-cart-item,
html[data-appearance="claro"] .inventory-empty,
html[data-appearance="claro"] .pos-empty {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(203, 213, 225, 0.78);
}

html[data-appearance="system"] .products-hero,
html[data-appearance="system"] .inventory-hero,
html[data-appearance="system"] .pos-hero {
  background:
    radial-gradient(circle at top right, rgba(186, 216, 245, 0.18), transparent 34%),
    linear-gradient(135deg, rgba(35, 57, 88, 0.96), rgba(82, 112, 150, 0.90));
}

@media (max-width: 1200px) {
  .products-layout,
  .inventory-layout,
  .pos-layout,
  .pos-cash-grid,
  .pos-cash-period-grid,
  .inventory-stats-grid,
  .pos-stats-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .products-hero-grid,
  .inventory-hero-grid,
  .pos-hero-grid,
  .products-filter-form,
  .products-import-form,
  .inventory-filter-form,
  .pos-toolbar,
  .products-form-grid,
  .inventory-form-grid,
  .pos-cash-form,
  .pos-checkout-grid,
  .pos-product-grid,
  .pos-cart-item {
    grid-template-columns: 1fr;
  }

  .inventory-alert-item {
    grid-template-columns: 1fr;
  }

  .inventory-alert-qty,
  .pos-cart-side {
    justify-items: start;
    align-items: flex-start;
  }
}

.meeting-shell {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.meeting-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.meeting-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.meeting-grid {
  display: grid;
  gap: 16px;
}

@media (min-width: 1024px) {
  .meeting-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.meeting-card {
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 18px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.meeting-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
}

.meeting-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.meeting-muted {
  font-size: 0.85rem;
  color: #64748b;
}

.meeting-list {
  list-style: disc;
  padding-left: 20px;
  color: #475569;
  font-size: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.meeting-embed {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.meeting-embed-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.meeting-embed-frame {
  position: relative;
  width: 100%;
  border-radius: 18px;
  overflow: hidden;
  background: #0f172a;
  min-height: 420px;
}

.meeting-embed-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: none;
}

.meeting-embed-frame.is-active iframe {
  display: block;
}

.meeting-embed-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: #e2e8f0;
  text-align: center;
  gap: 8px;
  padding: 24px;
}

html[data-appearance="escuro"] .meeting-card {
  background: rgba(15, 23, 42, 0.6);
  border-color: rgba(148, 163, 184, 0.2);
  color: #e2e8f0;
}

html[data-appearance="escuro"] .meeting-muted,
html[data-appearance="escuro"] .meeting-list {
  color: #cbd5f5;
}

.meeting-recording-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.meeting-file-input {
  min-height: 62px;
  padding: 12px 14px;
  border-color: rgba(56, 189, 248, 0.34);
  background:
    linear-gradient(160deg, rgba(4, 14, 30, 0.92), rgba(8, 21, 42, 0.92)),
    radial-gradient(circle at right top, rgba(129, 140, 248, 0.2), transparent 42%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 10px 28px rgba(2, 8, 23, 0.26);
}

.meeting-file-input-btn {
  padding: 9px 16px;
  font-size: 0.9rem;
}

.meeting-file-input-name {
  font-size: 0.95rem;
  color: rgba(226, 232, 240, 0.94);
}

.meeting-recording-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.meeting-recording-item {
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 16px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.9);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.meeting-recording-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.meeting-recording-item video {
  width: 100%;
  max-height: 360px;
  border-radius: 12px;
  background: #0f172a;
}

html[data-appearance="escuro"] .meeting-recording-item {
  background: rgba(15, 23, 42, 0.55);
  border-color: rgba(148, 163, 184, 0.2);
  color: #e2e8f0;
}

.btn-primary.is-disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

.meeting-item-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.meeting-edit-form {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(148, 163, 184, 0.3);
  display: none;
  gap: 10px;
}

.meeting-edit-form.is-open {
  display: grid;
}

.meeting-check-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.meeting-check {
  width: 100%;
}

.meeting-check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.meeting-check input + span {
  position: relative;
  padding-left: 34px;
  display: inline-flex;
  align-items: center;
  min-height: 22px;
}

.meeting-check input + span::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  width: 20px;
  height: 20px;
  border-radius: 8px;
  border: 1px solid rgba(125, 211, 252, 0.4);
  background: rgba(15, 23, 42, 0.6);
  transform: translateY(-50%);
  box-shadow: inset 0 0 0 2px rgba(15, 23, 42, 0.2);
  transition: all 0.2s ease;
}

.meeting-check input + span::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 50%;
  width: 8px;
  height: 4px;
  border-left: 2px solid #0f172a;
  border-bottom: 2px solid #0f172a;
  transform: translateY(-55%) rotate(-45deg);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.meeting-check input:checked + span::before {
  background: linear-gradient(135deg, #67e8f9, #60a5fa);
  border-color: rgba(96, 165, 250, 0.8);
  box-shadow: 0 6px 14px rgba(56, 189, 248, 0.3);
}

.meeting-check input:checked + span::after {
  opacity: 1;
}

.meeting-pin-toggle {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(15, 23, 42, 0.35);
}

.meeting-pin-toggle input {
  appearance: none;
  width: 44px;
  height: 24px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.35);
  position: relative;
  cursor: pointer;
  outline: none;
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.meeting-pin-toggle input::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #0f172a;
  top: 3px;
  left: 3px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.meeting-pin-toggle input:checked {
  background: linear-gradient(135deg, #67e8f9, #60a5fa);
  box-shadow: 0 6px 14px rgba(56, 189, 248, 0.35);
}

.meeting-pin-toggle input:checked::before {
  transform: translateX(20px);
  background: #0b1220;
}

.custom-select {
  position: relative;
}

.custom-select-native {
  display: none;
}

.custom-select-trigger {
  width: 100%;
  min-height: 46px;
  border-radius: 14px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(15, 23, 42, 0.6);
  color: #e2e8f0;
  padding: 10px 44px 10px 16px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
  cursor: pointer;
}

.custom-select-trigger:hover {
  border-color: rgba(56, 189, 248, 0.6);
}

.custom-select-caret {
  position: absolute;
  right: 16px;
  width: 10px;
  height: 10px;
  border-right: 2px solid #e2e8f0;
  border-bottom: 2px solid #e2e8f0;
  transform: rotate(45deg);
}

.custom-select-panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 14px;
  padding: 8px;
  box-shadow: 0 16px 28px rgba(8, 15, 32, 0.35);
  z-index: 40;
  display: none;
  max-height: 280px;
  overflow: auto;
}

.custom-select.is-open .custom-select-panel {
  display: block;
}

.custom-select-option {
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-radius: 10px;
  border: 0;
  background: transparent;
  color: #e2e8f0;
  cursor: pointer;
}

.custom-select-option:hover,
.custom-select-option.is-selected {
  background: rgba(56, 189, 248, 0.15);
  color: #e0f2fe;
}

.mail-btn {
  position: relative;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  aspect-ratio: 1 / 1;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: #e2e8f0;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.25);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.mail-btn svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.mail-btn:hover {
  transform: translateY(-1px) scale(1.02);
  border-color: rgba(125, 211, 252, 0.6);
  box-shadow: 0 14px 26px rgba(15, 23, 42, 0.32);
}

.mail-btn.is-hollow {
  background: radial-gradient(circle at top, rgba(56, 189, 248, 0.2), transparent 60%),
              linear-gradient(135deg, rgba(15, 23, 42, 0.8), rgba(30, 41, 59, 0.85));
}

.mail-btn.is-filled {
  background: radial-gradient(circle at top, rgba(56, 189, 248, 0.2), transparent 60%),
              linear-gradient(135deg, rgba(56, 189, 248, 0.45), rgba(59, 130, 246, 0.55));
  border-color: rgba(125, 211, 252, 0.8);
  color: #0b1220;
}

.mail-btn.is-filled svg {
  fill: #0b1220;
}

html[data-appearance="claro"] .mail-btn.is-hollow,
html[data-appearance="system"] .mail-btn.is-hollow {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(232, 240, 250, 0.95));
  color: #0f172a;
  border-color: rgba(125, 145, 168, 0.35);
}

html[data-appearance="claro"] .mail-btn.is-filled,
html[data-appearance="system"] .mail-btn.is-filled {
  background: linear-gradient(135deg, rgba(125, 211, 252, 0.85), rgba(96, 165, 250, 0.9));
  color: #0b1220;
}

.notifications-shell {
  position: relative;
}

.notifications-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 12px);
  width: 360px;
  max-height: 420px;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid var(--surface-border);
  background: var(--card-bg);
  color: var(--text);
  box-shadow: var(--card-shadow);
  display: none;
  z-index: 60;
  backdrop-filter: blur(14px);
}

.notifications-panel.is-open {
  display: block;
}

.notifications-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid var(--surface-border);
}

.notifications-panel-head strong {
  color: var(--text);
}

.notifications-panel-list {
  max-height: 360px;
  overflow: auto;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.notifications-item {
  border-radius: 14px;
  border: 1px solid var(--surface-border);
  padding: 10px 12px;
  background: var(--surface-soft);
  display: grid;
  gap: 8px;
}

.notifications-item.is-unread {
  border-color: rgba(56, 189, 248, 0.55);
  background: rgba(56, 189, 248, 0.12);
}

.notifications-item-title {
  font-weight: 600;
  color: var(--text);
}

.notifications-item-meta {
  font-size: 0.75rem;
  color: var(--muted);
}

.notifications-panel .meeting-muted {
  color: var(--muted);
}

html[data-appearance="claro"] .notifications-panel,
html[data-appearance="system"] .notifications-panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 250, 255, 0.98));
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.16);
}

html[data-appearance="claro"] .notifications-panel .btn-secondary,
html[data-appearance="system"] .notifications-panel .btn-secondary {
  background: rgba(226, 236, 248, 0.92);
  color: #0f172a;
  border-color: rgba(125, 145, 168, 0.28);
}

.notifications-item-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.topbar-language-select {
  padding: 6px 30px 6px 12px;
  font-size: 0.78rem;
  border-radius: 999px;
  min-width: 60px;
  height: 36px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.6);
  color: #e2e8f0;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #e2e8f0 50%),
                    linear-gradient(135deg, #e2e8f0 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 12px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.topbar-language-select:focus {
  outline: none;
  border-color: rgba(56, 189, 248, 0.6);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.15);
}

.mail-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #38bdf8;
  color: #0b1220;
  font-size: 0.7rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  box-shadow: 0 4px 12px rgba(56, 189, 248, 0.4);
}

.notification-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.notification-card {
  border-radius: 16px;
  border: 1px solid var(--surface-border);
  padding: 14px;
  background: var(--surface-soft);
  color: var(--text);
  display: grid;
  gap: 10px;
}

.notification-card.is-unread {
  border-color: rgba(125, 211, 252, 0.6);
  background: rgba(56, 189, 248, 0.12);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.18);
}

.notification-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.notification-meta {
  font-size: 0.75rem;
  color: var(--muted);
}

.notification-body {
  color: var(--text);
  line-height: 1.5;
}

.notification-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.topbar-avatar {
  width: 42px;
  height: 42px;
  min-width: 42px;
  min-height: 42px;
  aspect-ratio: 1 / 1;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.3);
  background: rgba(15, 23, 42, 0.6);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e2e8f0;
  font-weight: 700;
  text-transform: uppercase;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.2);
  overflow: hidden;
  padding: 0;
  flex: 0 0 42px;
  line-height: 1;
}

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

.topbar-user-name {
  font-weight: 600;
  color: var(--text);
  font-size: 0.95rem;
  white-space: nowrap;
}

.topbar-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 999px;
  display: block;
}

.topbar-avatar span {
  display: inline-block;
}

.avatar-mini {
  width: 34px;
  height: 34px;
  min-width: 34px;
  min-height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.3);
  background: rgba(15, 23, 42, 0.6);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: #e2e8f0;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.72rem;
  line-height: 1;
}

.avatar-mini img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 999px;
  display: block;
}

.avatar-mini--sm {
  width: 26px;
  height: 26px;
  min-width: 26px;
  min-height: 26px;
  font-size: 0.64rem;
}

.avatar-mini--lg {
  width: 58px;
  height: 58px;
  min-width: 58px;
  min-height: 58px;
  font-size: 0.9rem;
}

.avatar-mini--xs {
  width: 22px;
  height: 22px;
  min-width: 22px;
  min-height: 22px;
  font-size: 0.6rem;
}

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

.user-select .select {
  flex: 1;
}

.user-select-avatar {
  width: 34px;
  height: 34px;
  min-width: 34px;
  min-height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.28);
  background: rgba(15, 23, 42, 0.55);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: #e2e8f0;
  font-weight: 700;
  font-size: 0.7rem;
  text-transform: uppercase;
}

.user-select-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 999px;
  display: block;
}

.user-select-avatar.is-empty {
  opacity: 0;
}

.meeting-user-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

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

.ranking-user--podium {
  flex-direction: column;
  justify-content: center;
  text-align: center;
  gap: 8px;
}

.ranking-user--podium .ranking-name {
  text-align: center;
  text-transform: uppercase;
  font-weight: 800;
  letter-spacing: 0.06em;
  font-size: 1.05rem;
}

.ranking-user-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 1024px) {
  .topbar-user-name {
    display: none;
  }
}

.profile-avatar-row {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.profile-avatar {
  width: 92px;
  height: 92px;
  min-width: 92px;
  min-height: 92px;
  aspect-ratio: 1 / 1;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.35);
  background: rgba(15, 23, 42, 0.6);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e2e8f0;
  font-size: 1.4rem;
  font-weight: 700;
  text-transform: uppercase;
  overflow: hidden;
  line-height: 1;
}

.profile-avatar--sm {
  width: 78px;
  height: 78px;
  min-width: 78px;
  min-height: 78px;
  font-size: 1.15rem;
}

.profile-avatar-wrapper {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}

.profile-avatar-btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(9, 23, 46, 0.55);
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.profile-avatar-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 211, 252, 0.5);
}

.profile-avatar-text {
  display: grid;
  gap: 2px;
  text-align: left;
}

.profile-avatar-title {
  font-weight: 700;
  font-size: 0.95rem;
  color: #e2e8f0;
}

.profile-avatar-subtitle {
  font-size: 0.85rem;
  color: var(--muted);
}

.profile-avatar-menu {
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  min-width: 200px;
  padding: 8px;
  border-radius: 14px;
  border: 1px solid rgba(125, 211, 252, 0.2);
  background: rgba(8, 15, 28, 0.96);
  box-shadow: 0 18px 32px rgba(2, 6, 23, 0.35);
  display: none;
  z-index: 20;
}

.profile-avatar-menu.is-open {
  display: grid;
  gap: 6px;
}

.profile-avatar-menu-item {
  text-align: left;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: rgba(15, 23, 42, 0.55);
  color: #e2e8f0;
  font-weight: 600;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.profile-avatar-menu-item:hover {
  border-color: rgba(125, 211, 252, 0.35);
  background: rgba(15, 23, 42, 0.75);
}

.profile-avatar-menu-item.is-danger {
  color: #fecaca;
  background: rgba(127, 29, 29, 0.25);
}

.profile-avatar-menu-item.is-danger:hover {
  border-color: rgba(248, 113, 113, 0.6);
}

.phone-input--inline {
  position: relative;
  display: block;
  grid-template-columns: none;
  gap: 0;
  align-items: stretch;
  width: 100%;
  margin-top: 6px;
  --phone-select-width: 76px;
}

.phone-country-inline {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: var(--phone-select-width);
}

.phone-country-inline .custom-select-trigger {
  min-height: 32px;
  height: 32px;
  padding: 2px 18px 2px 6px;
  border-radius: 999px;
  background: transparent;
  border: 0;
  box-shadow: none;
  font-size: 0.85rem;
  color: #e2e8f0;
}

.phone-country-inline .custom-select-trigger:hover {
  border-color: transparent;
}

.phone-country-inline .custom-select-caret {
  right: 6px;
  width: 8px;
  height: 8px;
  border-right: 2px solid rgba(226, 232, 240, 0.9);
  border-bottom: 2px solid rgba(226, 232, 240, 0.9);
}

.phone-country-inline .custom-select-panel {
  min-width: 170px;
}

.phone-input-inline {
  width: 100%;
  padding-left: calc(var(--phone-select-width) + 18px);
  padding-right: 14px;
  min-width: 0;
}

@media (max-width: 640px) {
  .phone-input-inline {
    padding-left: 94px;
  }
}

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

.profile-shell {
  display: grid;
  gap: 20px;
}

.profile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.profile-header-note {
  font-size: 0.85rem;
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.2);
  background: rgba(15, 23, 42, 0.35);
}

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

.profile-panel {
  padding: 18px;
  border-radius: 20px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(9, 23, 46, 0.55);
  display: grid;
  gap: 14px;
}

.profile-panel-title {
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #9fb6d1;
}

.profile-muted {
  font-size: 0.85rem;
  color: var(--muted);
}

.profile-panel .profile-muted {
  margin-top: -8px;
}

.profile-panel .input {
  background: rgba(5, 13, 26, 0.7);
}

.profile-panel .input::placeholder {
  color: rgba(148, 163, 184, 0.8);
}

.profile-contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.client-section {
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(9, 23, 46, 0.55);
  display: grid;
  gap: 12px;
}

.client-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.client-section-head h4 {
  font-weight: 700;
}

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

.client-basic-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.client-base-field--hidden {
  display: none;
}

.client-custom-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.client-custom-row--edit {
  grid-template-columns: minmax(0, 1fr) auto;
}

.client-custom-render {
  display: grid;
  gap: 8px;
}

.client-custom-empty {
  color: var(--muted);
  font-size: 0.9rem;
}

.client-documents {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(125, 211, 252, 0.14);
  display: grid;
  gap: 12px;
}

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

.client-document-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  background: rgba(5, 13, 26, 0.6);
}

.client-document-link {
  color: #e2e8f0;
  font-weight: 600;
  text-decoration: none;
  max-width: 70%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.client-doc-upload {
  display: grid;
  gap: 12px;
}

.client-doc-row {
  display: grid;
  grid-template-columns: minmax(0, 200px) minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(7, 15, 28, 0.55);
}

.client-doc-type .select {
  min-height: 44px;
}

.client-doc-remove {
  align-self: center;
}

@media (max-width: 720px) {
  .client-custom-row {
    grid-template-columns: 1fr;
  }
  .client-document-item {
    flex-direction: column;
    align-items: flex-start;
  }
  .client-document-link {
    max-width: 100%;
  }
}

.file-input {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 16px;
  border: 1px solid rgba(125, 211, 252, 0.28);
  background: rgba(5, 13, 26, 0.7);
}

.file-input-native {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.file-input-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.4);
  background: linear-gradient(120deg, rgba(125, 211, 252, 0.25), rgba(129, 140, 248, 0.25));
  color: #eaf2ff;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.file-input-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 211, 252, 0.7);
}

.file-input-name {
  color: rgba(226, 232, 240, 0.85);
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 640px) {
  .file-input {
    flex-direction: column;
    align-items: flex-start;
  }
}

.profile-security {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  align-items: start;
}

.profile-security-main {
  display: grid;
  gap: 8px;
}

.profile-security-hint {
  padding-bottom: 0;
  margin-top: 4px;
}

.password-field {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.password-field .input {
  min-height: 54px;
}

.password-field .input {
  padding-right: 44px;
  position: relative;
  z-index: 1;
}

.password-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.2);
  background: rgba(15, 23, 42, 0.55);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e2e8f0;
  cursor: pointer;
  z-index: 2;
  pointer-events: auto;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.password-toggle:hover {
  transform: translateY(-50%) scale(1.04);
  border-color: rgba(125, 211, 252, 0.45);
}

.password-icon {
  width: 18px;
  height: 18px;
  display: block;
  fill: currentColor;
}

.password-icon-hide {
  display: none;
}

.password-toggle.is-on .password-icon-show,
.password-toggle.is-visible .password-icon-show {
  display: none;
}

.password-toggle.is-on .password-icon-hide,
.password-toggle.is-visible .password-icon-hide {
  display: block;
}

@media (max-width: 720px) {
  .profile-security {
    grid-template-columns: 1fr;
  }
}

.phone-input {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.phone-input.phone-input--inline {
  display: block;
  grid-template-columns: none;
  gap: 0;
  align-items: stretch;
}

.phone-country-select {
  padding-left: 12px;
  padding-right: 30px;
  font-weight: 700;
  text-align: left;
}

.phone-input-field {
  width: 100%;
}

@media (max-width: 640px) {
  .phone-input {
    grid-template-columns: 1fr;
  }
}

.nav-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nav-sub {
  display: none;
  flex-direction: column;
  gap: 6px;
  padding-left: 14px;
  border-left: 1px solid rgba(148, 163, 184, 0.3);
  margin-left: 4px;
}

.nav-sublink {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 999px;
  padding: 8px 12px;
  color: rgba(226, 232, 240, 0.8);
  font-weight: 500;
  transition: all 0.2s ease;
}

.nav-sublink:hover,
.nav-sublink.active {
  background: rgba(148, 163, 184, 0.15);
  color: #fff;
}

.nav-group.is-open .nav-sub {
  display: flex;
}

.nav-toggle {
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  cursor: pointer;
}

.input-eye-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-eye-wrap .input {
  padding-right: 46px;
}

.eye-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 0;
  background: rgba(148, 163, 184, 0.15);
  color: #e2e8f0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.eye-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.eye-btn .eye-icon-hide {
  display: none;
}

.eye-btn.is-active .eye-icon-hide {
  display: inline-flex;
}

.eye-btn.is-active .eye-icon-show {
  display: none;
}

.nav-badge {
  margin-left: auto;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.95), rgba(16, 185, 129, 0.95));
  color: #020617;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  box-shadow: 0 10px 18px rgba(14, 116, 144, 0.25);
}

.chat-layout {
  display: flex;
  justify-content: center;
}

.chat-panel {
  width: min(100%, 920px);
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 72vh;
}

.chat-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 6px 4px 2px;
}

.chat-room-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.chat-room-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.2);
  border: 1px solid rgba(148, 163, 184, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-title);
  font-weight: 700;
  overflow: hidden;
  flex-shrink: 0;
}

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

.chat-room-avatar.is-header {
  width: 46px;
  height: 46px;
  box-shadow: 0 8px 16px rgba(2, 6, 23, 0.35);
}

.chat-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-title);
}

.chat-subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.chat-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.4);
  border: 1px solid rgba(125, 211, 252, 0.35);
}

.chat-head-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  position: relative;
}

.chat-head-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(15, 23, 42, 0.55);
  color: var(--text-title);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.chat-head-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.chat-head-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(56, 189, 248, 0.55);
  box-shadow: 0 12px 20px rgba(2, 6, 23, 0.35);
}

.chat-head-menu {
  position: absolute;
  top: 52px;
  right: 0;
  display: grid;
  gap: 6px;
  padding: 10px;
  border-radius: 14px;
  background: rgba(10, 16, 30, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.3);
  box-shadow: 0 18px 30px rgba(2, 6, 23, 0.5);
  min-width: 180px;
  z-index: 20;
}

.chat-head-item {
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: rgba(15, 23, 42, 0.6);
  color: var(--text-title);
  text-align: left;
  font-weight: 600;
}

.chat-head-item:hover {
  border-color: rgba(56, 189, 248, 0.6);
}

.chat-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: var(--text-title);
  font-weight: 600;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 60;
}

.chat-toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.chat-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.7);
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.4), rgba(2, 6, 23, 0.75)),
    radial-gradient(circle at 12% 16%, rgba(56, 189, 248, 0.06), transparent 42%),
    radial-gradient(circle at 86% 28%, rgba(14, 165, 233, 0.06), transparent 40%),
    radial-gradient(circle at 40% 80%, rgba(59, 130, 246, 0.05), transparent 42%);
  border: 1px solid rgba(148, 163, 184, 0.2);
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
}

.chat-messages::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(148, 163, 184, 0.06) 1px, transparent 1px),
    radial-gradient(circle at 80% 60%, rgba(148, 163, 184, 0.05) 1px, transparent 1px);
  background-size: 32px 32px, 36px 36px;
  opacity: 0.45;
  pointer-events: none;
  border-radius: 18px;
}

.chat-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 24px 0;
}

.chat-message {
  display: flex;
  gap: 12px;
  align-items: flex-end;
}

.chat-message.is-me {
  justify-content: flex-end;
}

.chat-message.is-them {
  justify-content: flex-start;
}

.chat-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.2);
  border: 1px solid rgba(148, 163, 184, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--text-title);
  overflow: hidden;
  flex-shrink: 0;
}

.chat-message.is-me .chat-avatar {
  display: none;
}

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

.chat-bubble {
  max-width: min(72%, 620px);
  min-width: 150px;
  padding: 10px 12px 8px;
  border-radius: 12px 12px 12px 6px;
  background: linear-gradient(160deg, rgba(8, 23, 44, 0.94), rgba(7, 17, 34, 0.92));
  border: 1px solid rgba(71, 122, 191, 0.38);
  box-shadow: 0 8px 16px rgba(2, 6, 23, 0.28);
  position: relative;
}

.chat-message.is-me .chat-bubble {
  background: linear-gradient(145deg, rgba(11, 66, 94, 0.94), rgba(20, 89, 126, 0.9));
  border-color: rgba(52, 211, 153, 0.55);
  border-radius: 12px 12px 6px 12px;
}

.chat-message.is-them .chat-bubble {
  background: linear-gradient(145deg, rgba(13, 29, 58, 0.95), rgba(10, 24, 45, 0.94));
  border-color: rgba(56, 189, 248, 0.42);
}

.chat-message.is-me .chat-bubble::after {
  content: '';
  position: absolute;
  right: -5px;
  bottom: 10px;
  width: 10px;
  height: 10px;
  background: rgba(20, 89, 126, 0.9);
  border-right: 1px solid rgba(52, 211, 153, 0.55);
  border-bottom: 1px solid rgba(52, 211, 153, 0.55);
  transform: rotate(45deg);
}

.chat-message.is-them .chat-bubble::after {
  content: '';
  position: absolute;
  left: -5px;
  bottom: 10px;
  width: 10px;
  height: 10px;
  background: rgba(10, 24, 45, 0.94);
  border-left: 1px solid rgba(56, 189, 248, 0.4);
  border-bottom: 1px solid rgba(56, 189, 248, 0.4);
  transform: rotate(45deg);
}

.chat-meta {
  display: flex;
  gap: 8px;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.chat-meta strong {
  font-weight: 700;
  color: var(--text-title);
}

.chat-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chat-text {
  white-space: pre-wrap;
  line-height: 1.45;
  color: var(--text-default);
  font-size: 0.95rem;
}

.chat-deleted {
  font-size: 0.9rem;
  color: rgba(203, 213, 225, 0.86);
  font-style: italic;
}

.chat-footer {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  justify-content: flex-end;
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.chat-time {
  letter-spacing: 0.02em;
}

.chat-edited {
  font-size: 0.7rem;
  color: rgba(203, 213, 225, 0.9);
}

.chat-image,
.chat-video {
  width: 100%;
  max-width: 360px;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.chat-audio {
  width: 100%;
  min-width: 250px;
}

.chat-audio-card {
  display: block;
  width: 100%;
  max-width: 360px;
  padding: 8px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  background: rgba(2, 8, 23, 0.42);
}

.chat-file {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px dashed rgba(148, 163, 184, 0.4);
  color: var(--text-title);
  text-decoration: none;
  background: rgba(15, 23, 42, 0.5);
}

.chat-file:hover {
  border-color: rgba(56, 189, 248, 0.7);
}

.chat-file-name {
  font-weight: 600;
}

.chat-file-size {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.chat-message-actions {
  margin-top: 6px;
  display: inline-flex;
  gap: 6px;
  opacity: 0;
  transition: opacity 0.18s ease;
}

.chat-message:hover .chat-message-actions,
.chat-message:focus-within .chat-message-actions {
  opacity: 1;
}

.chat-message-action {
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(15, 23, 42, 0.46);
  color: var(--text-muted);
  border-radius: 999px;
  padding: 2px 9px;
  font-size: 0.68rem;
  cursor: pointer;
}

.chat-message-action:hover {
  color: #e2e8f0;
  border-color: rgba(56, 189, 248, 0.65);
}

.chat-message-action.is-danger:hover {
  color: #fecaca;
  border-color: rgba(248, 113, 113, 0.7);
}

.chat-compose {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chat-compose-row {
  display: flex;
  gap: 12px;
  align-items: flex-end;
}

.chat-input {
  flex: 1;
  min-height: 56px;
  resize: vertical;
}

.chat-send-btn {
  min-width: 110px;
}

.chat-compose-tools {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.chat-tool-btn {
  padding: 8px 14px;
  border-radius: 14px;
}

.chat-compose-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.chat-edit-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(52, 211, 153, 0.35);
  background: rgba(6, 78, 59, 0.16);
}

.chat-edit-text {
  font-size: 0.8rem;
  color: #a7f3d0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-edit-cancel {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.6);
  color: #e2e8f0;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.75rem;
  cursor: pointer;
}

.chat-edit-cancel:hover {
  border-color: rgba(56, 189, 248, 0.65);
}

.chat-recording {
  font-size: 0.9rem;
  color: #fbbf24;
  font-weight: 600;
}

.chat-preview {
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  padding: 12px;
  background: rgba(15, 23, 42, 0.55);
  display: grid;
  gap: 12px;
}

.chat-preview-label {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.chat-preview-body {
  display: grid;
  gap: 10px;
}

.chat-preview-media {
  width: 100%;
  max-width: 360px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.chat-preview-audio {
  width: 100%;
}

.chat-preview-info {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.86rem;
  color: var(--text-muted);
}

.chat-preview-name {
  color: var(--text-title);
  font-weight: 600;
}

.chat-preview-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.chat-preview-btn {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.6);
  color: var(--text-title);
  font-weight: 600;
}

.chat-preview-btn.is-send {
  background: linear-gradient(135deg, #38bdf8, #22d3ee);
  color: #0f172a;
  border: none;
}

.chat-preview-video {
  width: 100%;
  max-width: 340px;
  border-radius: 12px;
}

.chat-compose {
  position: relative;
}

.chat-compose-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.08), 0 16px 24px rgba(2, 6, 23, 0.35);
}

.chat-input-shell {
  flex: 1;
  background: rgba(2, 6, 23, 0.65);
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  padding: 8px 12px;
}

.chat-input {
  border: none;
  background: transparent;
  resize: none;
  min-height: 34px;
  height: 34px;
  color: var(--text-default);
  font-size: 0.95rem;
}

.chat-input:focus {
  outline: none;
}

.chat-icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.65);
  color: var(--text-title);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.chat-icon-btn svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.chat-icon-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(56, 189, 248, 0.6);
  box-shadow: 0 10px 18px rgba(2, 6, 23, 0.35);
}

.chat-icon-btn.is-send {
  background: linear-gradient(135deg, #38bdf8, #22c55e);
  color: #0f172a;
  border: none;
}

.chat-icon-btn.is-loading {
  opacity: 0.65;
  pointer-events: none;
}

.chat-attach-menu {
  position: absolute;
  left: 12px;
  bottom: calc(100% + 12px);
  display: grid;
  gap: 8px;
  padding: 10px;
  width: 220px;
  border-radius: 18px;
  background: rgba(10, 16, 30, 0.92);
  border: 1px solid rgba(148, 163, 184, 0.3);
  box-shadow: 0 18px 30px rgba(2, 6, 23, 0.5);
  z-index: 10;
}

.chat-attach-menu[hidden] {
  display: none;
}

.chat-attach-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid transparent;
  background: rgba(15, 23, 42, 0.6);
  color: var(--text-title);
  font-weight: 600;
  text-align: left;
}

.chat-attach-item:hover {
  border-color: rgba(56, 189, 248, 0.6);
}

.chat-attach-icon {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0f172a;
}

.chat-attach-icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.chat-attach-icon.is-doc {
  background: linear-gradient(135deg, #fbbf24, #f97316);
}

.chat-attach-icon.is-media {
  background: linear-gradient(135deg, #22d3ee, #38bdf8);
}

.chat-attach-icon.is-camera {
  background: linear-gradient(135deg, #a78bfa, #f472b6);
}

.chat-record-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(148, 163, 184, 0.3);
  box-shadow: inset 0 0 0 1px rgba(244, 63, 94, 0.2);
}

.chat-record-bar[hidden] {
  display: none;
}

.chat-record-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0f172a;
}

.chat-record-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.chat-record-btn.is-danger {
  background: linear-gradient(135deg, #f87171, #ef4444);
}

.chat-record-btn.is-send {
  background: linear-gradient(135deg, #34d399, #22c55e);
}

.chat-record-timer {
  font-weight: 700;
  color: #fca5a5;
  min-width: 52px;
  letter-spacing: 0.04em;
}

.chat-record-wave {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
}

.chat-record-wave span {
  width: 4px;
  height: 16px;
  border-radius: 999px;
  background: rgba(248, 113, 113, 0.9);
  animation: chatWave 1s ease-in-out infinite;
}

.chat-record-wave span:nth-child(2) { animation-delay: 0.1s; }
.chat-record-wave span:nth-child(3) { animation-delay: 0.2s; }
.chat-record-wave span:nth-child(4) { animation-delay: 0.3s; }
.chat-record-wave span:nth-child(5) { animation-delay: 0.4s; }
.chat-record-wave span:nth-child(6) { animation-delay: 0.5s; }
.chat-record-wave span:nth-child(7) { animation-delay: 0.6s; }
.chat-record-wave span:nth-child(8) { animation-delay: 0.7s; }

@keyframes chatWave {
  0%, 100% { transform: scaleY(0.4); opacity: 0.6; }
  50% { transform: scaleY(1.2); opacity: 1; }
}

@media (max-width: 768px) {
  .chat-panel {
    min-height: 70vh;
  }

  .chat-bubble {
    max-width: 100%;
  }

  .chat-compose-row {
    flex-direction: column;
    align-items: stretch;
  }

  .chat-send-btn {
    width: 100%;
  }

  .chat-compose-bar {
    flex-wrap: wrap;
  }

  .chat-icon-btn {
    width: 40px;
    height: 40px;
  }

  .chat-message-actions {
    opacity: 1;
  }
}

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

.chat-sidebar {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.85), rgba(2, 6, 23, 0.92));
  border: 1px solid rgba(148, 163, 184, 0.25);
}

.chat-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.chat-sidebar-title {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-title);
}

.chat-sidebar-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
}

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

.chat-sidebar-search {
  margin-bottom: 12px;
}

.chat-sidebar-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.chat-tab {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: rgba(15, 23, 42, 0.45);
  color: var(--text-default);
  font-size: 0.78rem;
  font-weight: 600;
}

.chat-tab.is-active {
  border-color: rgba(56, 189, 248, 0.7);
  background: rgba(56, 189, 248, 0.2);
  color: #e2e8f0;
}

.chat-sidebar-input {
  border-radius: 999px;
  padding-left: 16px;
  background: rgba(2, 6, 23, 0.55);
}

.chat-room-item {
  text-align: left;
  border-radius: 12px;
  border: 1px solid transparent;
  background: rgba(15, 23, 42, 0.25);
  padding: 10px 12px;
  color: var(--text-default);
  position: relative;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
  width: 100%;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
}

.chat-room-item.is-active,
.chat-room-item:hover {
  border-color: rgba(56, 189, 248, 0.5);
  background: rgba(56, 189, 248, 0.12);
  transform: translateY(-1px);
}

.chat-room-main {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 4px;
}

.chat-room-line {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: baseline;
}

.chat-room-title {
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-room-time {
  font-size: 0.7rem;
  color: var(--text-muted);
  flex-shrink: 0;
}

.chat-room-preview {
  font-size: 0.78rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-room-star {
  margin-left: 6px;
  color: rgba(148, 163, 184, 0.6);
  font-size: 0.9rem;
}

.chat-room-star.is-active {
  color: #fbbf24;
}

.chat-room-mute {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  margin-left: 6px;
  color: rgba(148, 163, 184, 0.6);
}

.chat-room-mute svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.chat-panel {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.75), rgba(2, 6, 23, 0.85));
  border: 1px solid rgba(148, 163, 184, 0.25);
}

.chat-room-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: linear-gradient(135deg, #38bdf8, #22c55e);
  color: #0f172a;
  font-weight: 700;
  border-radius: 999px;
  font-size: 0.72rem;
  padding: 2px 7px;
}

.chat-typing {
  font-size: 0.8rem;
  color: #38bdf8;
  margin-top: 4px;
  min-height: 18px;
}

.chat-receipt {
  margin-left: 6px;
  font-size: 0.8rem;
  line-height: 1;
  letter-spacing: -1px;
}

.chat-receipt--sent {
  color: #64748b;
}

.chat-receipt--delivered {
  color: #94a3b8;
}

.chat-receipt--read {
  color: #22c55e;
  font-weight: 700;
}

.chat-modal {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 50;
  padding: 20px;
}

[hidden] {
  display: none !important;
}

.chat-media-modal,
.chat-call {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
  padding: 20px;
}

.chat-jitsi {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 70;
  padding: 20px;
}

.chat-jitsi-card {
  width: min(100%, 920px);
  height: min(84vh, 720px);
  background: var(--card-bg);
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-jitsi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.chat-jitsi-frame {
  flex: 1;
  border-radius: 14px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.6);
}

.chat-media-card,
.chat-call-card {
  width: min(100%, 520px);
  background: var(--card-bg);
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.chat-media-head,
.chat-call-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.chat-media-list {
  display: grid;
  gap: 12px;
  max-height: 60vh;
  overflow-y: auto;
}

.chat-media-item {
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: rgba(15, 23, 42, 0.6);
  padding: 10px;
}

.chat-media-item img,
.chat-media-item video {
  width: 100%;
  border-radius: 10px;
}

.chat-media-item audio {
  width: 100%;
}

.chat-call-body {
  display: grid;
  gap: 8px;
  justify-items: center;
  text-align: center;
}

.chat-call-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.2);
  border: 1px solid rgba(148, 163, 184, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-title);
  font-weight: 700;
  overflow: hidden;
}

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

.chat-call-name {
  font-size: 1.1rem;
  font-weight: 700;
}

.chat-call-status {
  color: var(--text-muted);
}

.chat-call-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.chat-call-btn {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.6);
  color: var(--text-title);
  font-weight: 600;
}

.chat-call-btn.is-accept {
  background: linear-gradient(135deg, #22c55e, #86efac);
  color: #0f172a;
  border: none;
}

.chat-call-btn.is-decline,
.chat-call-btn.is-hangup {
  background: linear-gradient(135deg, #f87171, #ef4444);
  color: #0f172a;
  border: none;
}

.chat-modal-card {
  width: min(100%, 460px);
  background: var(--card-bg);
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.chat-modal-card--compact {
  width: min(92vw, 340px);
  padding: 14px;
  border-radius: 16px;
  background: linear-gradient(175deg, rgba(7, 19, 42, 0.96), rgba(8, 14, 30, 0.95));
  border: 1px solid rgba(56, 189, 248, 0.35);
  box-shadow: 0 26px 60px rgba(2, 6, 23, 0.6);
}

.chat-action-list {
  display: grid;
  gap: 9px;
}

.chat-action-head {
  display: grid;
  gap: 4px;
  margin-bottom: 2px;
}

.chat-action-kicker {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(148, 163, 184, 0.95);
  font-weight: 700;
}

.chat-action-title {
  font-size: 0.96rem;
  font-weight: 700;
  color: #e2e8f0;
}

.chat-action-item {
  width: 100% !important;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left !important;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  background: rgba(15, 23, 42, 0.75);
  color: #e2e8f0;
  padding: 11px 12px;
  font-size: 0.91rem;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.35);
}

.chat-action-item:hover {
  border-color: rgba(56, 189, 248, 0.8);
  background: rgba(18, 42, 78, 0.75);
}

.chat-action-item.is-danger {
  color: #fecdd3;
  border-color: rgba(251, 113, 133, 0.45);
  background: rgba(71, 20, 40, 0.5);
}

.chat-action-item.is-danger:hover {
  border-color: rgba(251, 113, 133, 0.8);
  background: rgba(88, 24, 49, 0.6);
}

.chat-action-icon {
  width: 24px;
  height: 24px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(56, 189, 248, 0.16);
  color: #bae6fd;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.chat-action-item.is-danger .chat-action-icon {
  background: rgba(251, 113, 133, 0.2);
  color: #fecdd3;
}

.chat-action-label {
  font-weight: 600;
}

.chat-action-footer {
  margin-top: 2px;
}

.chat-action-cancel {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.6);
  color: #cbd5e1;
  font-size: 0.88rem;
  font-weight: 700;
  padding: 10px 12px;
  cursor: pointer;
}

.chat-action-cancel:hover {
  border-color: rgba(56, 189, 248, 0.7);
  color: #e2e8f0;
}

.chat-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.chat-modal-users {
  display: grid;
  gap: 8px;
  max-height: 220px;
  overflow-y: auto;
  padding: 8px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.chat-user-option {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 0.9rem;
}

.chat-modal-search {
  margin-bottom: 10px;
  border-radius: 999px;
  padding-left: 16px;
}

.chat-user-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid transparent;
  background: rgba(15, 23, 42, 0.5);
  color: var(--text-title);
  text-align: left;
  cursor: pointer;
  width: 100%;
}

.chat-user-item:hover {
  border-color: rgba(56, 189, 248, 0.5);
}

.chat-user-item.is-selected {
  border-color: rgba(56, 189, 248, 0.7);
  background: rgba(56, 189, 248, 0.12);
}

.chat-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.18);
  border: 1px solid rgba(148, 163, 184, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-title);
  font-weight: 700;
  overflow: hidden;
}

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

.chat-user-name {
  font-weight: 600;
}

.chat-user-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid rgba(148, 163, 184, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0f172a;
  background: rgba(148, 163, 184, 0.15);
  font-size: 0.8rem;
}

.chat-user-item.is-selected .chat-user-check {
  background: linear-gradient(135deg, #38bdf8, #22c55e);
  border-color: transparent;
}

.chat-modal-actions {
  display: flex;
  justify-content: flex-end;
}

html[data-appearance="claro"] .chat-sidebar,
html[data-appearance="system"] .chat-sidebar {
  background: linear-gradient(180deg, #ffffff, #f5f8fc);
  border-color: rgba(148, 163, 184, 0.28);
}

html[data-appearance="claro"] .chat-panel,
html[data-appearance="system"] .chat-panel {
  background: linear-gradient(180deg, #ffffff, #f7faff);
  border-color: rgba(148, 163, 184, 0.28);
}

html[data-appearance="claro"] .chat-sidebar-head,
html[data-appearance="system"] .chat-sidebar-head {
  border-bottom-color: rgba(148, 163, 184, 0.24);
}

html[data-appearance="claro"] .chat-sidebar-title,
html[data-appearance="system"] .chat-sidebar-title,
html[data-appearance="claro"] .chat-title,
html[data-appearance="system"] .chat-title {
  color: #0f172a;
}

html[data-appearance="claro"] .chat-sidebar-subtitle,
html[data-appearance="system"] .chat-sidebar-subtitle,
html[data-appearance="claro"] .chat-subtitle,
html[data-appearance="system"] .chat-subtitle,
html[data-appearance="claro"] .chat-room-preview,
html[data-appearance="system"] .chat-room-preview,
html[data-appearance="claro"] .chat-room-time,
html[data-appearance="system"] .chat-room-time {
  color: #64748b;
}

html[data-appearance="claro"] .chat-tab,
html[data-appearance="system"] .chat-tab {
  background: rgba(241, 245, 249, 0.95);
  border-color: rgba(148, 163, 184, 0.3);
  color: #334155;
}

html[data-appearance="claro"] .chat-tab.is-active,
html[data-appearance="system"] .chat-tab.is-active {
  background: rgba(59, 130, 246, 0.13);
  border-color: rgba(59, 130, 246, 0.45);
  color: #1e3a8a;
}

html[data-appearance="claro"] .chat-sidebar-input,
html[data-appearance="system"] .chat-sidebar-input {
  background: rgba(255, 255, 255, 0.96);
  color: #0f172a;
  border-color: rgba(148, 163, 184, 0.34);
}

html[data-appearance="claro"] .chat-room-item,
html[data-appearance="system"] .chat-room-item {
  background: rgba(248, 250, 252, 0.95);
  border-color: rgba(148, 163, 184, 0.2);
  color: #0f172a;
}

html[data-appearance="claro"] .chat-room-item.is-active,
html[data-appearance="claro"] .chat-room-item:hover,
html[data-appearance="system"] .chat-room-item.is-active,
html[data-appearance="system"] .chat-room-item:hover {
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.4);
}

html[data-appearance="claro"] .chat-status,
html[data-appearance="system"] .chat-status {
  background: rgba(239, 246, 255, 0.92);
  border-color: rgba(96, 165, 250, 0.35);
  color: #1e293b;
}

html[data-appearance="claro"] .chat-head-btn,
html[data-appearance="system"] .chat-head-btn {
  background: rgba(241, 245, 249, 0.95);
  border-color: rgba(148, 163, 184, 0.32);
  color: #0f172a;
}

html[data-appearance="claro"] .chat-head-menu,
html[data-appearance="system"] .chat-head-menu {
  background: #ffffff;
  border-color: rgba(148, 163, 184, 0.3);
  box-shadow: 0 16px 28px rgba(15, 23, 42, 0.18);
}

html[data-appearance="claro"] .chat-head-item,
html[data-appearance="system"] .chat-head-item {
  background: rgba(248, 250, 252, 0.95);
  color: #0f172a;
}

html[data-appearance="claro"] .chat-messages,
html[data-appearance="system"] .chat-messages {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 251, 255, 0.98)),
    radial-gradient(circle at 12% 16%, rgba(59, 130, 246, 0.06), transparent 42%),
    radial-gradient(circle at 86% 28%, rgba(14, 165, 233, 0.06), transparent 40%);
  border-color: rgba(148, 163, 184, 0.28);
}

html[data-appearance="claro"] .chat-messages::after,
html[data-appearance="system"] .chat-messages::after {
  opacity: 0.18;
}

html[data-appearance="claro"] .chat-bubble,
html[data-appearance="system"] .chat-bubble {
  background: linear-gradient(160deg, #ffffff, #f8fbff);
  border-color: rgba(148, 163, 184, 0.35);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
}

html[data-appearance="claro"] .chat-message.is-them .chat-bubble,
html[data-appearance="system"] .chat-message.is-them .chat-bubble {
  background: linear-gradient(160deg, #ffffff, #f7faff);
  border-color: rgba(148, 163, 184, 0.35);
}

html[data-appearance="claro"] .chat-message.is-me .chat-bubble,
html[data-appearance="system"] .chat-message.is-me .chat-bubble {
  background: linear-gradient(145deg, #dcfce7, #bbf7d0);
  border-color: rgba(34, 197, 94, 0.45);
}

html[data-appearance="claro"] .chat-message.is-me .chat-bubble::after,
html[data-appearance="system"] .chat-message.is-me .chat-bubble::after {
  background: #bbf7d0;
  border-right-color: rgba(34, 197, 94, 0.45);
  border-bottom-color: rgba(34, 197, 94, 0.45);
}

html[data-appearance="claro"] .chat-message.is-them .chat-bubble::after,
html[data-appearance="system"] .chat-message.is-them .chat-bubble::after {
  background: #f8fbff;
  border-left-color: rgba(148, 163, 184, 0.35);
  border-bottom-color: rgba(148, 163, 184, 0.35);
}

html[data-appearance="claro"] .chat-meta,
html[data-appearance="system"] .chat-meta,
html[data-appearance="claro"] .chat-footer,
html[data-appearance="system"] .chat-footer {
  color: #64748b;
}

html[data-appearance="claro"] .chat-meta strong,
html[data-appearance="system"] .chat-meta strong,
html[data-appearance="claro"] .chat-text,
html[data-appearance="system"] .chat-text,
html[data-appearance="claro"] .chat-file,
html[data-appearance="system"] .chat-file {
  color: #0f172a;
}

html[data-appearance="claro"] .chat-compose-bar,
html[data-appearance="system"] .chat-compose-bar {
  background: #f8fbff;
  border-color: rgba(148, 163, 184, 0.3);
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.08), 0 10px 18px rgba(15, 23, 42, 0.08);
}

html[data-appearance="claro"] .chat-input-shell,
html[data-appearance="system"] .chat-input-shell {
  background: #ffffff;
  border-color: rgba(148, 163, 184, 0.3);
}

html[data-appearance="claro"] .chat-input,
html[data-appearance="system"] .chat-input {
  color: #0f172a;
}

html[data-appearance="claro"] .chat-input::placeholder,
html[data-appearance="system"] .chat-input::placeholder {
  color: #94a3b8;
}

html[data-appearance="claro"] .chat-icon-btn,
html[data-appearance="system"] .chat-icon-btn {
  background: #ffffff;
  border-color: rgba(148, 163, 184, 0.35);
  color: #0f172a;
}

html[data-appearance="claro"] .chat-attach-menu,
html[data-appearance="system"] .chat-attach-menu,
html[data-appearance="claro"] .chat-modal-card,
html[data-appearance="system"] .chat-modal-card,
html[data-appearance="claro"] .chat-media-card,
html[data-appearance="system"] .chat-media-card,
html[data-appearance="claro"] .chat-call-card,
html[data-appearance="system"] .chat-call-card {
  background: #ffffff;
  border-color: rgba(148, 163, 184, 0.32);
  box-shadow: 0 18px 30px rgba(15, 23, 42, 0.16);
}

html[data-appearance="claro"] .chat-attach-item,
html[data-appearance="system"] .chat-attach-item,
html[data-appearance="claro"] .chat-user-item,
html[data-appearance="system"] .chat-user-item {
  background: rgba(248, 250, 252, 0.96);
  color: #0f172a;
}

html[data-appearance="claro"] .chat-preview,
html[data-appearance="system"] .chat-preview {
  background: #f8fbff;
  border-color: rgba(148, 163, 184, 0.35);
}

html[data-appearance="claro"] .chat-preview-label,
html[data-appearance="system"] .chat-preview-label,
html[data-appearance="claro"] .chat-preview-info,
html[data-appearance="system"] .chat-preview-info {
  color: #64748b;
}

html[data-appearance="claro"] .chat-preview-name,
html[data-appearance="system"] .chat-preview-name {
  color: #0f172a;
}

html[data-appearance="claro"] .chat-preview-btn,
html[data-appearance="system"] .chat-preview-btn {
  background: #eef2f7;
  border-color: rgba(148, 163, 184, 0.4);
  color: #0f172a;
}

html[data-appearance="claro"] .chat-record-bar,
html[data-appearance="system"] .chat-record-bar {
  background: #f8fafc;
  border-color: rgba(148, 163, 184, 0.35);
  box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.08);
}

html[data-appearance="claro"] .chat-modal-card--compact,
html[data-appearance="system"] .chat-modal-card--compact {
  background: #ffffff;
  border-color: rgba(148, 163, 184, 0.35);
  box-shadow: 0 18px 30px rgba(15, 23, 42, 0.18);
}

html[data-appearance="claro"] .chat-action-kicker,
html[data-appearance="system"] .chat-action-kicker {
  color: #64748b;
}

html[data-appearance="claro"] .chat-action-title,
html[data-appearance="system"] .chat-action-title {
  color: #0f172a;
}

html[data-appearance="claro"] .chat-action-item,
html[data-appearance="system"] .chat-action-item {
  background: #f8fafc;
  border-color: rgba(148, 163, 184, 0.35);
  color: #0f172a;
  box-shadow: none;
}

html[data-appearance="claro"] .chat-action-item:hover,
html[data-appearance="system"] .chat-action-item:hover {
  background: #eff6ff;
  border-color: rgba(59, 130, 246, 0.5);
}

html[data-appearance="claro"] .chat-action-icon,
html[data-appearance="system"] .chat-action-icon {
  background: rgba(59, 130, 246, 0.14);
  color: #1d4ed8;
}

html[data-appearance="claro"] .chat-action-item.is-danger,
html[data-appearance="system"] .chat-action-item.is-danger {
  background: #fff1f2;
  border-color: rgba(239, 68, 68, 0.45);
  color: #b91c1c;
}

html[data-appearance="claro"] .chat-action-item.is-danger:hover,
html[data-appearance="system"] .chat-action-item.is-danger:hover {
  background: #ffe4e6;
  border-color: rgba(239, 68, 68, 0.65);
}

html[data-appearance="claro"] .chat-action-item.is-danger .chat-action-icon,
html[data-appearance="system"] .chat-action-item.is-danger .chat-action-icon {
  background: rgba(239, 68, 68, 0.16);
  color: #dc2626;
}

html[data-appearance="claro"] .chat-action-cancel,
html[data-appearance="system"] .chat-action-cancel {
  background: #f1f5f9;
  border-color: rgba(148, 163, 184, 0.35);
  color: #334155;
}

html[data-appearance="claro"] .chat-action-cancel:hover,
html[data-appearance="system"] .chat-action-cancel:hover {
  background: #e2e8f0;
  border-color: rgba(100, 116, 139, 0.45);
  color: #0f172a;
}

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