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

:root {
  --yellow: #fad129;
  --black: #050505;
  --muted: #5d5d5d;
  --line: #cacaca;
  --soft: #f6f6f4;
  --danger: #b42318;
  --success: #12715b;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background: #fff;
  color: var(--black);
  font-family: 'Mukta', Arial, sans-serif;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  user-select: none;
}

.login-preloading .login-page {
  opacity: 0;
}

.login-page {
  transition: opacity 180ms ease;
}

input,
button {
  font: inherit;
}

.login-page {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  overflow: auto;
  padding: 32px;
  background: #f1f1f1;
}

.login-label {
  display: none;
}

.login-box {
  position: relative;
  width: min(1000px, 100%);
  min-height: 680px;
  display: grid;
  grid-template-columns: 360px minmax(340px, 1fr);
  gap: 86px;
  align-items: center;
  padding: 28px 72px 28px 28px;
  background: #fff;
}

.language {
  position: absolute;
  top: 36px;
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  line-height: 20px;
}

[dir="rtl"] .language {
  left: 32px;
}

[dir="ltr"] .language {
  right: 32px;
}

.language a {
  color: #000;
  text-decoration: none;
  font-weight: 800;
}

.flag {
  width: 20px;
  height: 20px;
  overflow: hidden;
  border-radius: 999px;
  flex: 0 0 auto;
  position: relative;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
}

.flag-us {
  background:
    linear-gradient(#b22234 0 7.69%, #fff 7.69% 15.38%, #b22234 15.38% 23.07%, #fff 23.07% 30.76%, #b22234 30.76% 38.45%, #fff 38.45% 46.14%, #b22234 46.14% 53.83%, #fff 53.83% 61.52%, #b22234 61.52% 69.21%, #fff 69.21% 76.9%, #b22234 76.9% 84.59%, #fff 84.59% 92.28%, #b22234 92.28%),
    #fff;
}

.flag-us::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 9px;
  height: 11px;
  background: #3c3b6e;
}

.flag-palestine {
  background:
    linear-gradient(180deg, #000 0 33.333%, #fff 33.333% 66.666%, #149954 66.666% 100%);
}

.flag-palestine::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 0;
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-inline-start: 13px solid #e4312b;
}

.login-visual {
  position: relative;
  width: 360px;
  height: 624px;
  overflow: hidden;
  border-radius: 22px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.08) 42%, transparent),
    linear-gradient(135deg, rgba(250, 209, 41, 0.18), transparent 45%),
    linear-gradient(145deg, #ded8cc, #f8f7f5 46%, #c9bca7);
}

.login-visual img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}



.login-visual-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(0, 0, 0, 0.14);
  font-size: 42px;
  font-weight: 700;
  z-index: 0;
}

.login-visual img + .login-visual-fallback {
  display: none;
}

.login-shell {
  width: 380px;
  max-width: 100%;
  justify-self: center;
}

.intro {
  margin-bottom: 24px;
}

.intro h1 {
  width: 100%;
  max-width: 100%;
  margin: 0 0 24px;
  font-size: 29px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0;
}

.intro p {
  width: 100%;
  max-width: 100%;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 24px;
  letter-spacing: 0;
}

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

.field-group {
  display: grid;
  gap: 10px;
}

.field-group label {
  font-size: 14px;
  font-weight: 500;
  line-height: 18px;
}

.input-wrap {
  position: relative;
}

.input-wrap input {
  width: 100%;
  height: 40px;
  padding: 8px 45px 8px 14px;
  color: var(--black);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 7px;
  outline: none;
  font-size: 14px;
  line-height: 22px;
  user-select: text;
}

.input-wrap input::placeholder {
  color: #b8b8b8;
}

.input-wrap input:focus {
  border-color: var(--black);
  box-shadow: 0 0 0 3px rgba(250, 209, 41, 0.24);
}

.field-icon,
.icon-button {
  position: absolute;
  right: 14px;
  top: 50%;
  width: 20px;
  height: 20px;
  transform: translateY(-50%);
  color: #a7a7a7;
}

.icon-button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.primary-button {
  width: 100%;
  height: 39px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #fff;
  border-radius: 7px;
  background: #000;
  color: #fff;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  line-height: 33px;
  letter-spacing: -0.165px;
}

.primary-button:hover {
  background: #1f1f1f;
}

.hint {
  width: 360px;
  max-width: 100%;
  margin: 0 auto;
  color: #777;
  font-size: 18px;
  line-height: 30px;
  text-align: center;
}

.alert {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 16px;
  line-height: 1.45;
}

.alert-error {
  color: var(--danger);
  background: #fff0ee;
  border: 1px solid #ffd6d1;
}

.alert-success {
  color: var(--success);
  background: #ecfdf7;
  border: 1px solid #b8efdf;
}

.alert-warning {
  color: #7a5a00;
  background: #fff8dd;
  border: 1px solid #f4df93;
}

.splash {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: #fff;
  color: #000;
}

.splash-card {
  display: grid;
  justify-items: center;
  gap: 20px;
}

.splash-logo-img {
  width: min(260px, 62vw);
  height: auto;
  display: block;
  animation: flash 1.35s ease-in-out infinite;
}

.splash-line {
  width: 180px;
  height: 4px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  background: #ececec;
}

.splash-line span {
  display: block;
  width: 45%;
  height: 100%;
  border-radius: inherit;
  background: var(--yellow);
  animation: loading 1.1s ease-in-out infinite;
}

.secure-page {
  min-height: 100vh;
  background: #f4f4f2;
  color: var(--black);
}

.secure-header {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  border-bottom: 1px solid #ececea;
}

.logo {
  font-weight: 700;
  font-size: 24px;
}

.logout {
  color: #000;
  text-decoration: none;
  font-weight: 600;
}

.secure-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.secure-main {
  width: min(1040px, calc(100% - 40px));
  margin: 0 auto;
  padding: 72px 0;
}

.decrypt-panel {
  width: min(520px, 100%);
  margin: 0 auto;
}

.eyebrow {
  margin: 0 0 10px;
  color: #797979;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
}

.secure-title {
  margin: 0 0 12px;
  font-size: 36px;
  line-height: 1.15;
}

.secure-copy {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.6;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 32px;
}

.metric {
  min-height: 128px;
  padding: 20px;
  border: 1px solid #e7e7e2;
  border-radius: 8px;
  background: #fff;
}

.metric span {
  display: block;
  color: #777;
  font-size: 15px;
}

.metric strong {
  display: block;
  margin-top: 12px;
  font-size: 34px;
  line-height: 1;
}

.dashboard-band {
  margin-top: 24px;
  padding: 24px;
  border: 1px solid #e7e7e2;
  border-radius: 8px;
  background: #fff;
}

.app-dashboard {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
  direction: rtl;
}

.app-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 24px 18px;
  background: #050505;
  color: #fff;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 6px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.sidebar-logo {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: var(--yellow);
  color: #000;
  font-weight: 700;
  font-size: 24px;
}

.sidebar-brand strong,
.sidebar-brand small {
  display: block;
}

.sidebar-brand strong {
  font-size: 18px;
  line-height: 1.2;
}

.sidebar-brand small {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 13px;
}

.side-nav {
  display: grid;
  gap: 8px;
  padding: 22px 0;
}

.side-nav a {
  min-height: 44px;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  border-radius: 8px;
}

.side-nav a:hover,
.side-nav a:focus {
  background: rgba(255, 255, 255, 0.09);
  color: #fff;
  outline: none;
}

.nav-mark {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  background: rgba(250, 209, 41, 0.14);
  color: var(--yellow);
  font-weight: 700;
}

.side-nav strong {
  min-width: 28px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  text-align: center;
  font-size: 13px;
}

.sidebar-logout {
  margin-top: auto;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #000;
  background: #fff;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 700;
}

.app-content {
  min-width: 0;
  padding: 32px;
}

.dashboard-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 30px;
  border: 1px solid #e8e8e3;
  border-radius: 8px;
  background: #fff;
}

.dashboard-hero h1 {
  margin: 0 0 10px;
  font-size: 34px;
  line-height: 1.2;
}

.dashboard-hero p {
  max-width: 700px;
  margin: 0;
  color: #666;
  font-size: 17px;
  line-height: 1.7;
}

.hero-status {
  min-width: 172px;
  padding: 14px 16px;
  border: 1px solid #e9e2bd;
  border-radius: 8px;
  background: #fff9dc;
}

.hero-status span,
.hero-status strong {
  display: block;
}

.hero-status span {
  color: #6a5b16;
  font-size: 13px;
}

.hero-status strong {
  margin-top: 6px;
  color: #000;
  font-size: 17px;
}

.summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.summary-strip div {
  min-height: 104px;
  padding: 18px;
  border: 1px solid #e8e8e3;
  border-radius: 8px;
  background: #fff;
}

.summary-strip span {
  display: block;
  color: #747474;
  font-size: 14px;
}

.summary-strip strong {
  display: block;
  margin-top: 12px;
  font-size: 32px;
  line-height: 1;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.module-card {
  min-height: 168px;
  display: flex;
  flex-direction: column;
  padding: 20px;
  border: 1px solid #e8e8e3;
  border-radius: 8px;
  background: #fff;
  color: #000;
  text-decoration: none;
}

.module-card:hover,
.module-card:focus {
  border-color: #d8bb23;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
  outline: none;
}

.module-card span {
  color: #111;
  font-size: 17px;
  font-weight: 700;
}

.module-card strong {
  margin-top: 18px;
  font-size: 34px;
  line-height: 1;
}

.module-card p {
  margin: auto 0 0;
  color: #6a6a6a;
  font-size: 14px;
  line-height: 1.55;
}

.dashboard-workbench {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 18px;
  padding: 24px;
  border: 1px solid #e8e8e3;
  border-radius: 8px;
  background: #fff;
}

.dashboard-workbench h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.dashboard-workbench p {
  max-width: 660px;
  margin: 0;
  color: #666;
  line-height: 1.7;
}

.workbench-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.workbench-actions a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  padding: 0 14px;
  border-radius: 8px;
  color: #fff;
  background: #000;
  text-decoration: none;
  font-weight: 700;
}

.lexo-dashboard {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 318px;
  gap: 40px;
  padding: 40px;
  direction: ltr;
  background: #f5f5f3;
  border-radius: 34px;
}

.lexo-workspace,
.lexo-side-menu,
.home-board,
.legal-panel,
.mini-calendar {
  direction: rtl;
}

.lexo-topbar {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  border-radius: 20px;
  background: #fff;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 26px;
}

.bell-icon {
  color: #686b72;
  font-size: 26px;
}

.round-brand {
  width: 50px;
  height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #000;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
}

.search-pill {
  width: min(212px, 32vw);
  height: 51px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  border-radius: 999px;
  background: #f5f4f3;
  direction: rtl;
}

.search-pill input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #686b72;
  user-select: text;
}

.home-board {
  display: grid;
  grid-template-columns: minmax(330px, 1fr) minmax(330px, 1fr) minmax(330px, 0.95fr);
  gap: 38px;
  margin-top: 40px;
  align-items: start;
}

.board-column {
  display: grid;
  gap: 40px;
}

.legal-panel {
  min-height: 436px;
  padding: 24px 16px 16px;
  border-radius: 18px;
}

.legal-panel header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.legal-panel h2 {
  margin: 0;
  color: #050505;
  font-size: 22px;
  line-height: 1.2;
}

.legal-panel h2 span {
  color: rgba(0, 0, 0, 0.28);
  font-size: 17px;
}

.legal-panel button {
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  color: #686b72;
  cursor: pointer;
  font-size: 38px;
  line-height: 1;
}

.panel-followup { background: #bfeef4; }
.panel-execution { background: #facdca; }
.panel-ended { background: #ffd4a8; }
.panel-tasks { background: #cdb9ee; }
.panel-today { background: #edfbea; }
.panel-tomorrow { background: #eef1ff; }

.legal-list,
.task-list {
  display: grid;
  gap: 5px;
}

.legal-mini-card {
  min-height: 70px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 10px;
  align-items: center;
  padding: 6px 14px 6px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.95);
  color: #000;
}

.legal-mini-card strong,
.legal-mini-card small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.legal-mini-card strong {
  font-size: 14px;
  line-height: 1.15;
}

.legal-mini-card small {
  font-size: 11px;
  line-height: 1.2;
}

.legal-card-icon {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #66708a;
  font-size: 24px;
}

.empty-panel {
  min-height: 70px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.55);
  color: #686b72;
  font-weight: 600;
}

.task-row {
  min-height: 58px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 38px;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.52);
  color: #676a72;
}

.task-row strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 16px;
  font-weight: 500;
}

.task-row em {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #676a72;
  border-radius: 50%;
  font-style: normal;
  font-weight: 700;
}

.task-row.is-done strong {
  color: #9b9b9b;
  text-decoration: line-through;
}

.task-row.is-done em {
  border-color: #32bd7f;
  background: #32bd7f;
  color: #fff;
}

.mini-calendar {
  min-height: 420px;
  padding: 38px 30px;
  border-radius: 18px;
  background: #fff;
}

.mini-calendar header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
}

.mini-calendar h2 {
  margin: 0;
  font-size: 28px;
}

.mini-calendar button {
  width: 28px;
  height: 28px;
  margin-right: 8px;
  border: 0;
  border-radius: 50%;
  background: #ff7438;
  color: #fff;
  font-size: 20px;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 18px 16px;
  text-align: center;
  direction: ltr;
}

.calendar-grid strong {
  color: #111;
  font-size: 13px;
}

.calendar-grid span {
  color: #747880;
  font-size: 14px;
}

.calendar-grid .is-today {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  justify-self: center;
  margin-top: -8px;
  border-radius: 50%;
  background: #ff7438;
  color: #fff;
}

.lexo-side-menu {
  min-height: calc(100vh - 80px);
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
}

.elite-logo {
  height: 178px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  color: #0b315e;
}

.elite-logo strong {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 42px;
  line-height: 1;
}

.elite-logo span {
  font-size: 8px;
  letter-spacing: 0.06em;
}

.lexo-side-menu nav {
  display: grid;
}

.lexo-side-menu a {
  min-height: 76px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
  align-items: center;
  gap: 16px;
  padding: 0 26px;
  color: #70727a;
  text-decoration: none;
  font-size: 18px;
  font-weight: 600;
}

.lexo-side-menu a.active {
  color: #ff7438;
  background: #fff1e9;
}

.lexo-side-menu a strong {
  color: inherit;
  font-size: 25px;
  text-align: center;
}

.compact-dashboard {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 208px minmax(0, 1fr);
  gap: 18px;
  padding: 16px;
  background: #f4f4f2;
  direction: inherit;
}

.compact-sidebar {
  height: calc(100vh - 32px);
  position: sticky;
  top: 16px;
  display: flex;
  flex-direction: column;
  padding: 14px;
  border: 1px solid #e8e8e3;
  border-radius: 10px;
  background: #fff;
}

.compact-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 14px;
  border-bottom: 1px solid #ededed;
}

.compact-brand span {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: #000;
  color: var(--yellow);
  font-weight: 800;
}

.compact-brand strong {
  font-size: 15px;
  line-height: 1;
}

.compact-sidebar nav {
  display: grid;
  gap: 4px;
  margin-top: 14px;
}

.compact-sidebar nav a {
  min-height: 36px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  border-radius: 7px;
  color: #4f5258;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}

.compact-sidebar nav a:hover {
  color: #000;
  background: #f6f1de;
}

.compact-sidebar small {
  min-width: 28px;
  padding: 2px 7px;
  border-radius: 999px;
  background: #f0f0ee;
  color: #6b6b6b;
  text-align: center;
  font-size: 11px;
}

.compact-logout {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: auto;
  border-radius: 7px;
  background: #000;
  color: #fff;
  text-decoration: none;
  font-size: 13px;
  font-weight: 800;
}

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

.compact-topbar {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border: 1px solid #e8e8e3;
  border-radius: 10px;
  background: #fff;
}

.compact-topbar p,
.compact-topbar h1 {
  margin: 0;
}

.compact-topbar p {
  color: #777;
  font-size: 12px;
  font-weight: 700;
}

.compact-topbar h1 {
  margin-top: 2px;
  font-size: 20px;
  line-height: 1.2;
}

.compact-search {
  width: min(340px, 42vw);
  height: 38px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border-radius: 8px;
  background: #f5f5f4;
}

.compact-search span {
  color: #777;
  font-size: 12px;
  font-weight: 800;
}

.compact-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #111;
  user-select: text;
}

.compact-search button {
  display: none;
}

.compact-flash {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
}

.compact-flash.ok {
  color: #0b624b;
  background: #e9fbf4;
  border: 1px solid #c6f2e2;
}

.compact-flash.error {
  color: #9c1f14;
  background: #fff0ee;
  border: 1px solid #ffd4cf;
}

.compact-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.compact-stats div {
  min-height: 70px;
  padding: 12px;
  border: 1px solid #e8e8e3;
  border-radius: 10px;
  background: #fff;
}

.compact-stats span {
  display: block;
  color: #777;
  font-size: 12px;
  font-weight: 700;
}

.compact-stats strong {
  display: block;
  margin-top: 6px;
  font-size: 26px;
  line-height: 1;
}

.compact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(270px, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.compact-panel {
  min-height: 260px;
  max-height: 420px;
  overflow: auto;
  padding: 10px;
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: 10px;
  background: #fff;
}

.compact-panel > header {
  position: sticky;
  top: -10px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: -10px -10px 8px;
  padding: 10px;
  background: inherit;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.compact-panel h2 {
  margin: 0;
  font-size: 15px;
  line-height: 1.25;
}

.compact-panel h2 span {
  color: #898989;
  font-size: 12px;
}

.add-btn,
.tiny-btn {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 9px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 7px;
  background: #000;
  color: #fff;
  text-decoration: none;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}

.add-btn.muted,
.tiny-btn {
  background: #fff;
  color: #111;
}

.tiny-btn.danger {
  color: #a32118;
  background: #fff7f6;
}

.compact-row {
  display: grid;
  grid-template-columns: minmax(116px, 0.8fr) minmax(0, 1.3fr) auto;
  gap: 8px;
  align-items: center;
  min-height: 58px;
  margin-top: 6px;
  padding: 7px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
}

.row-main strong,
.row-main span,
.row-meta span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row-main strong {
  color: #111;
  font-size: 13px;
}

.row-main span {
  margin-top: 2px;
  color: #777;
  font-size: 11px;
}

.row-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2px 8px;
  color: #343434;
  font-size: 11px;
}

.row-meta em {
  display: block;
  color: #858780;
  font-style: normal;
  font-size: 9px;
  font-weight: 900;
}

.compact-actions {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.compact-actions form {
  margin: 0;
}

.compact-empty {
  min-height: 54px;
  display: grid;
  place-items: center;
  margin-top: 6px;
  border-radius: 8px;
  color: #777;
  background: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  font-weight: 700;
}

.tone-cyan { background: #d9f4f6; }
.tone-rose { background: #ffe0dd; }
.tone-amber { background: #ffe3bf; }
.tone-green { background: #ecfae7; }
.tone-blue { background: #e8edff; }
.tone-violet { background: #eadffc; }

.panel-head-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}

.case-page {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 34px;
  direction: rtl;
}

.case-topbar {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border: 1px solid #e8e8e3;
  border-radius: 10px;
  background: #fff;
}

.case-topbar a {
  color: #666;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}

.case-topbar h1 {
  margin: 4px 0 0;
  font-size: 24px;
  line-height: 1.2;
}

.case-topbar-actions,
.form-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.case-btn {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  border: 1px solid #000;
  border-radius: 8px;
  background: #000;
  color: #fff !important;
  text-decoration: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
}

.case-btn.ghost {
  background: #fff;
  color: #111 !important;
  border-color: #d9d9d5;
}

.case-layout,
.case-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 12px;
  margin-top: 12px;
}

.case-card {
  padding: 18px;
  border: 1px solid #e8e8e3;
  border-radius: 10px;
  background: #fff;
}

.case-wide {
  grid-column: 1 / -1;
}

.case-details-card {
  min-height: 360px;
}

.case-card h2 {
  margin: 0 0 14px;
  color: #0e2538;
  font-size: 18px;
}

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

.detail-item {
  min-height: 72px;
  padding: 12px;
  border-radius: 8px;
  background: #f7f7f5;
}

.detail-item span,
.case-form label span {
  display: block;
  color: #777;
  font-size: 12px;
  font-weight: 800;
}

.detail-item strong {
  display: block;
  margin-top: 7px;
  color: #111;
  font-size: 16px;
  line-height: 1.45;
}

.case-muted {
  margin: 0;
  color: #777;
  font-size: 14px;
}

.amount-list {
  display: grid;
  gap: 8px;
}

.amount-list div {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff8dd;
}

.amount-list span {
  color: #7a6411;
  font-size: 13px;
  font-weight: 800;
}

.amount-list strong {
  font-size: 18px;
}

.case-form {
  align-items: start;
}

.case-form label {
  display: grid;
  gap: 6px;
}

.case-form input,
.case-form select,
.case-form textarea {
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  border: 1px solid #d9d9d5;
  border-radius: 8px;
  background: #fff;
  color: #111;
  outline: none;
  user-select: text;
}

.case-form textarea {
  resize: vertical;
}

.case-form input:focus,
.case-form select:focus,
.case-form textarea:focus {
  border-color: #000;
  box-shadow: 0 0 0 3px rgba(250, 209, 41, 0.2);
}

.form-wide {
  grid-column: 1 / -1;
}

.amount-edit-list,
.custom-edit-list {
  display: grid;
  gap: 8px;
}

.amount-edit-row,
.custom-edit-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 8px;
}

.custom-edit-row {
  grid-template-columns: minmax(160px, 0.4fr) minmax(0, 1fr);
}

.import-form {
  grid-template-columns: minmax(0, 1fr);
}

.import-check {
  width: fit-content;
  display: inline-flex !important;
  grid-template-columns: auto auto;
  align-items: center;
  gap: 8px !important;
  margin-top: 14px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f7f7f5;
}

.import-check input {
  width: 18px;
  min-height: 18px;
  margin: 0;
  padding: 0;
}

.import-check span {
  color: #111;
}

.import-results {
  margin-top: 12px;
}

.import-summary-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  margin: 12px 0;
}

.import-summary-grid div {
  min-height: 72px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 10px;
  border-radius: 8px;
  background: #f7f7f5;
}

.import-summary-grid span {
  color: #777;
  font-size: 12px;
  font-weight: 800;
}

.import-summary-grid strong {
  color: #111;
  font-size: 24px;
  line-height: 1;
}

.import-format-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 14px;
}

.import-format-strip span {
  min-height: 44px;
  display: inline-grid;
  align-content: center;
  gap: 2px;
  padding: 7px 10px;
  border-radius: 8px;
  border: 1px solid #e4e4df;
  background: #f7f7f5;
}

.import-format-strip span.ready {
  border-color: #c6f2e2;
  background: #e9fbf4;
}

.import-format-strip span.missing {
  border-color: #ffd4cf;
  background: #fff0ee;
}

.import-format-strip strong {
  color: #111;
  font-size: 12px;
}

.import-format-strip em {
  color: #666;
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
}

.import-result-row {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) repeat(6, minmax(90px, auto));
  gap: 8px;
  align-items: center;
  margin-top: 8px;
  padding: 10px;
  border-radius: 8px;
  background: #f7f7f5;
  font-size: 13px;
}

.import-result-row strong,
.import-result-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.import-result-row small {
  grid-column: 1 / -1;
  color: #9c1f14;
  font-weight: 700;
}

.import-action-form {
  margin-top: 14px;
}

.case-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.form-actions {
  grid-column: 1 / -1;
  justify-content: flex-start;
  padding: 4px 0;
}

.list-page {
  width: min(1280px, calc(100% - 32px));
}

.list-filters {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 170px 170px auto auto;
  gap: 10px;
  align-items: end;
  margin-top: 12px;
  padding: 12px;
  border: 1px solid #e8e8e3;
  border-radius: 10px;
  background: #fff;
}

.list-filters label {
  display: grid;
  gap: 6px;
}

.list-filters span {
  color: #777;
  font-size: 12px;
  font-weight: 800;
}

.list-filters input {
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid #d9d9d5;
  border-radius: 8px;
  outline: none;
  user-select: text;
}

.list-table {
  margin-top: 12px;
  border: 1px solid #e8e8e3;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.list-table > header,
.list-row {
  display: grid;
  grid-template-columns: minmax(170px, 0.7fr) minmax(0, 1.5fr) minmax(190px, auto);
  gap: 12px;
  align-items: center;
}

.list-table > header {
  padding: 11px 14px;
  color: #777;
  background: #f7f7f5;
  font-size: 12px;
  font-weight: 800;
}

.list-row {
  min-height: 72px;
  padding: 10px 14px;
  border-top: 1px solid #ededed;
}

.list-row strong,
.list-row small {
  display: block;
}

.list-row strong {
  font-size: 14px;
}

.list-row small {
  margin-top: 3px;
  color: #777;
  font-size: 12px;
}

.list-field-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.list-field-grid span {
  min-width: 0;
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 6px 8px;
  border-radius: 7px;
  background: #f8f8f6;
  font-size: 12px;
}

.list-field-grid em {
  display: block;
  color: #888;
  font-style: normal;
  font-size: 10px;
}

.list-empty {
  padding: 28px;
  color: #777;
  text-align: center;
  font-weight: 800;
}

.attachment-list {
  display: grid;
  gap: 8px;
}

.attachment-list div {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f7f7f5;
}

.attachment-list span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Polished workspace shell */
.compact-dashboard {
  grid-template-columns: 238px minmax(0, 1fr);
  gap: 20px;
  padding: 20px;
  background:
    linear-gradient(180deg, rgba(250, 209, 41, 0.08), transparent 260px),
    #f6f6f3;
}

.compact-sidebar {
  height: calc(100vh - 40px);
  padding: 16px;
  border: 0;
  border-radius: 8px;
  background: #11130f;
  color: #fff;
  box-shadow: 0 24px 70px rgba(18, 18, 12, 0.18);
}

.compact-brand {
  gap: 12px;
  padding: 4px 2px 18px;
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

.compact-brand span {
  width: 42px;
  height: 42px;
  overflow: hidden;
  border: 1px solid rgba(250, 209, 41, 0.28);
  border-radius: 8px;
  background: #000;
}

.compact-brand span img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 5px;
}

.compact-brand span.has-avatar {
  border-color: rgba(250, 209, 41, 0.58);
  background: #fff;
}

.compact-brand span.has-avatar img {
  object-fit: cover;
  padding: 0;
}

.compact-brand div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.compact-brand strong {
  color: #fff;
  font-size: 16px;
}

.compact-brand small {
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
  font-weight: 700;
}

.compact-sidebar nav {
  gap: 7px;
  margin-top: 18px;
}

.compact-sidebar nav a {
  min-height: 42px;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  padding: 8px 9px;
  color: rgba(255, 255, 255, 0.72);
  border: 1px solid transparent;
  border-radius: 8px;
}

.compact-sidebar nav a i {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--yellow);
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}

.compact-sidebar nav a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(250, 209, 41, 0.18);
}

.compact-sidebar small {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.68);
}

.compact-brand div small {
  min-width: 0;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  text-align: start;
}

.compact-logout {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.08);
}

.compact-main {
  display: grid;
  align-content: start;
}

.compact-topbar {
  min-height: 76px;
  padding: 14px 16px;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 50px rgba(18, 18, 12, 0.07);
  backdrop-filter: blur(14px);
}

.compact-topbar h1 {
  font-size: 24px;
}

.quick-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.quick-actions a {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 7px;
  background: #11130f;
  color: #fff;
  text-decoration: none;
  font-size: 12px;
  font-weight: 900;
}

.quick-actions a:nth-child(2) {
  background: #26384e;
}

.quick-actions a:nth-child(3) {
  background: #7d6b2d;
}

.quick-actions a.ghost-action {
  border: 1px solid #d9d5c8;
  background: #fff;
  color: #11130f;
}

.quick-actions a.lang-action {
  gap: 7px;
}

[dir="ltr"] .compact-dashboard {
  direction: ltr;
}

[dir="rtl"] .compact-dashboard {
  direction: rtl;
}

[dir="ltr"] .compact-sidebar nav a {
  grid-template-columns: 28px minmax(0, 1fr) auto;
}

[dir="rtl"] .compact-sidebar nav a {
  grid-template-columns: 28px minmax(0, 1fr) auto;
}

[dir="ltr"] .compact-sidebar nav a,
[dir="rtl"] .compact-sidebar nav a {
  direction: inherit;
}

[dir="ltr"] .compact-sidebar nav a i,
[dir="rtl"] .compact-sidebar nav a i {
  grid-column: 1;
}

[dir="ltr"] .compact-sidebar nav a span,
[dir="rtl"] .compact-sidebar nav a span {
  grid-column: 2;
  text-align: start;
}

[dir="ltr"] .compact-sidebar nav a small,
[dir="rtl"] .compact-sidebar nav a small {
  grid-column: 3;
}

.compact-search {
  border: 1px solid #ebe8df;
  background: #fff;
}

.compact-stats {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.compact-stats a {
  min-height: 88px;
  display: block;
  padding: 14px;
  border: 1px solid #ebe8df;
  border-radius: 8px;
  background: #fff;
  color: #111;
  text-decoration: none;
  box-shadow: 0 12px 34px rgba(18, 18, 12, 0.05);
}

.compact-stats a span,
.compact-stats a small {
  display: block;
  color: #777;
  font-size: 12px;
  font-weight: 800;
}

.compact-stats a strong {
  display: block;
  margin: 7px 0 4px;
  font-size: 28px;
  line-height: 1;
}

.compact-grid {
  grid-template-columns: repeat(3, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.search-panel {
  min-height: auto;
  max-height: 460px;
  margin-top: 14px;
}

.compact-panel {
  min-height: 218px;
  max-height: 340px;
  padding: 12px;
  border: 1px solid #ebe8df;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 16px 48px rgba(18, 18, 12, 0.06);
}

.compact-panel > header {
  top: -12px;
  margin: -12px -12px 10px;
  padding: 12px;
}

.compact-panel h2 {
  font-size: 16px;
}

.tone-cyan { background: linear-gradient(180deg, #eaf8f9, #fff 42%); }
.tone-rose { background: linear-gradient(180deg, #fff0ee, #fff 42%); }
.tone-amber { background: linear-gradient(180deg, #fff2db, #fff 42%); }
.tone-green { background: linear-gradient(180deg, #effbec, #fff 42%); }
.tone-blue { background: linear-gradient(180deg, #eef2ff, #fff 42%); }
.tone-violet { background: linear-gradient(180deg, #f2edff, #fff 42%); }
.tone-gold { background: linear-gradient(180deg, #fff7d8, #fff 42%); }

.compact-row {
  min-height: 58px;
  padding: 7px;
  border: 1px solid #efeee9;
  background: rgba(255, 255, 255, 0.92);
  overflow: hidden;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.row-meta span {
  padding: 2px 0;
  color: #3f403c;
}

.compact-row .row-meta {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px 8px;
}

.compact-row .row-meta span {
  font-size: 10px;
}

@media (hover: hover) and (pointer: fine) {
  .compact-row .compact-actions {
    opacity: 0;
    transform: translateX(-12px);
    transition: opacity 160ms ease, transform 160ms ease;
  }

  .compact-row:hover,
  .compact-row:focus-within {
    border-color: rgba(17, 19, 15, 0.18);
    box-shadow: 0 12px 28px rgba(18, 18, 12, 0.09);
    transform: translateY(-1px);
  }

  .compact-row:hover .compact-actions,
  .compact-row:focus-within .compact-actions {
    opacity: 1;
    transform: translateX(0);
  }
}

.tiny-btn.primary,
.case-btn.archive {
  border-color: #11130f;
  background: #11130f;
  color: #fff;
}

.case-topbar {
  border: 0;
  border-radius: 8px;
  box-shadow: 0 14px 42px rgba(18, 18, 12, 0.06);
}

.workspace-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding: 8px;
  border: 1px solid #ebe8df;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(18, 18, 12, 0.04);
}

.workspace-nav a {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 13px;
  border-radius: 7px;
  color: #555950;
  background: #f8f8f5;
  text-decoration: none;
  font-size: 13px;
  font-weight: 900;
}

.workspace-nav a.active,
.workspace-nav a:hover {
  color: #fff;
  background: #11130f;
}

.session-update-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 12px;
  margin-top: 12px;
}

.session-panel {
  display: grid;
  align-content: start;
  gap: 12px;
}

.session-panel label,
.note-entry {
  display: grid;
  gap: 7px;
}

.session-panel input,
.note-entry textarea {
  width: 100%;
  min-height: 42px;
  padding: 9px 10px;
  border: 1px solid #d9d9d5;
  border-radius: 8px;
  outline: none;
  user-select: text;
}

.session-panel p {
  margin: 0;
  color: #777;
  font-size: 13px;
  line-height: 1.55;
}

.notes-archive {
  max-height: 220px;
  overflow: auto;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid #e7e5dc;
  border-radius: 8px;
  background: #f8f8f5;
  color: #252620;
  font-size: 14px;
  line-height: 1.7;
  user-select: text;
}

.note-entry span,
.session-panel label span {
  color: #777;
  font-size: 12px;
  font-weight: 900;
}

.file-upload-field {
  display: grid;
  gap: 8px;
}

.file-upload-field span {
  color: #777;
  font-size: 12px;
  font-weight: 900;
}

.file-upload-field input[type="file"] {
  width: 100%;
  min-height: 42px;
  padding: 8px;
  border: 1px dashed #c9c6bb;
  border-radius: 8px;
  background: #fafaf7;
  user-select: text;
}

.calendar-page {
  max-width: 1380px;
}

.calendar-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 12px;
  margin-top: 12px;
}

.calendar-board,
.calendar-agenda {
  border: 1px solid #ebe8df;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 16px 44px rgba(18, 18, 12, 0.06);
}

.calendar-board {
  padding: 12px;
}

.calendar-month-head {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.calendar-month-head div {
  display: grid;
  gap: 3px;
  text-align: center;
}

.calendar-month-head strong {
  font-size: 19px;
}

.calendar-month-head span,
.calendar-agenda header span {
  color: #777;
  font-size: 12px;
  font-weight: 900;
}

.calendar-nav-btn {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid #e5e1d5;
  border-radius: 7px;
  color: #11130f;
  background: #faf9f3;
  text-decoration: none;
  font-size: 13px;
  font-weight: 900;
}

.full-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(66px, 1fr));
  gap: 6px;
}

.full-calendar-grid > strong {
  padding: 6px 4px;
  color: #7d7769;
  font-size: 12px;
  text-align: center;
}

.calendar-day {
  min-height: 64px;
  position: relative;
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 8px;
  border: 1px solid #ece9df;
  border-radius: 8px;
  background: #fbfbf8;
  color: #14150f;
  text-decoration: none;
  transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.calendar-day:hover {
  border-color: rgba(17, 19, 15, 0.24);
  box-shadow: 0 10px 28px rgba(18, 18, 12, 0.08);
  transform: translateY(-1px);
}

.calendar-day.is-blank {
  visibility: hidden;
}

.calendar-day b {
  font-size: 14px;
}

.calendar-day em {
  width: max-content;
  padding: 2px 8px;
  border-radius: 999px;
  background: #11130f;
  color: #fff;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.calendar-day i {
  width: 8px;
  height: 8px;
  position: absolute;
  inset-inline-end: 10px;
  bottom: 10px;
  border-radius: 50%;
  background: var(--yellow);
}

.calendar-day.is-today {
  background: #fff9dd;
  border-color: rgba(250, 209, 41, 0.55);
}

.calendar-day.is-selected {
  color: #fff;
  background: #11130f;
  border-color: #11130f;
}

.calendar-day.is-selected em {
  color: #11130f;
  background: var(--yellow);
}

.calendar-agenda {
  max-height: calc(100vh - 150px);
  overflow: auto;
  padding: 10px;
}

.calendar-agenda header {
  position: sticky;
  top: -10px;
  z-index: 1;
  display: grid;
  gap: 4px;
  margin: -10px -10px 10px;
  padding: 12px 10px;
  border-bottom: 1px solid #ebe8df;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
}

.calendar-agenda h2 {
  margin: 0;
  font-size: 17px;
}

.calendar-event {
  display: grid;
  gap: 7px;
  margin-bottom: 8px;
  padding: 10px;
  border: 1px solid #ece9df;
  border-inline-start: 5px solid #c6a15b;
  border-radius: 8px;
  background: #fff;
}

.calendar-event.execution { border-inline-start-color: #11130f; }
.calendar-event.followup { border-inline-start-color: #20a7b5; }
.calendar-event.task { border-inline-start-color: #8a6fdf; }

.calendar-event small {
  color: #777;
  font-size: 11px;
  font-weight: 900;
}

.calendar-event strong {
  font-size: 14px;
}

.calendar-event-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.dash-calendar-card {
  display: grid;
  gap: 10px;
  align-self: start;
  background: #fffdf8;
}

.dash-calendar-top,
.dash-calendar-month,
.dash-calendar-results header,
.dash-calendar-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.lx-mini-panel.dash-calendar-card .dash-calendar-top h3 {
  margin: 0;
  font-size: 16px;
}

.dash-calendar-top a,
.dash-calendar-month a,
.dash-calendar-open {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(44, 35, 24, 0.1);
  border-radius: 9px;
  background: #fbf8f1;
  color: #4e473c;
  text-decoration: none;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.dash-calendar-top a,
.dash-calendar-open {
  padding: 0 9px;
}

.dash-calendar-month {
  min-height: 34px;
  padding: 4px;
  border: 1px solid rgba(44, 35, 24, 0.08);
  border-radius: 13px;
  background: #fbf7ef;
}

.dash-calendar-month strong {
  min-width: 0;
  color: #1f241f;
  font-size: 13px;
  text-align: center;
}

.dash-calendar-month a {
  width: 28px;
  padding: 0;
  font-size: 17px;
  line-height: 1;
}

.dash-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  direction: ltr;
}

.dash-calendar-weekday {
  min-width: 0;
  padding: 3px 0;
  color: #82786a;
  font-size: 10px;
  font-weight: 800;
  text-align: center;
}

.dash-calendar-day {
  aspect-ratio: 1;
  min-width: 0;
  position: relative;
  display: grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 9px;
  background: #fbf8f1;
  color: #1f241f;
  text-decoration: none;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.dash-calendar-day:hover {
  border-color: rgba(185, 149, 91, 0.34);
  background: #fffaf0;
}

.dash-calendar-day b {
  font-size: 11px;
  line-height: 1;
}

.dash-calendar-day i {
  width: 5px;
  height: 5px;
  position: absolute;
  inset-inline-end: 5px;
  bottom: 5px;
  border-radius: 50%;
  background: #b9955b;
}

.dash-calendar-day.is-blank {
  visibility: hidden;
}

.dash-calendar-day.is-today {
  border-color: rgba(185, 149, 91, 0.4);
  background: rgba(185, 149, 91, 0.12);
  color: #7b5f2d;
  font-weight: 900;
}

.dash-calendar-day.is-selected {
  background: #1f241f;
  border-color: #1f241f;
  color: #fff8ec;
}

.dash-calendar-day.is-selected i {
  background: #d8bd84;
}

.dash-calendar-results {
  display: grid;
  gap: 7px;
  padding-top: 2px;
}

.dash-calendar-results header {
  color: #82786a;
  font-size: 11px;
}

.dash-calendar-results header strong {
  min-width: 26px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(185, 149, 91, 0.1);
  color: #b9955b;
  font-size: 11px;
}

.dash-calendar-empty {
  padding: 12px;
  border: 1px dashed rgba(185, 149, 91, 0.34);
  border-radius: 12px;
  background: rgba(185, 149, 91, 0.06);
  color: #82786a;
  text-align: center;
  font-size: 12px;
}

.dash-calendar-item {
  display: grid;
  gap: 6px;
  padding: 8px;
  border: 1px solid rgba(44, 35, 24, 0.08);
  border-inline-start: 4px solid #b9955b;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 5px 14px rgba(43, 35, 24, 0.03);
}

.dash-calendar-item.execution {
  border-inline-start-color: #1f241f;
}

.dash-calendar-item.task {
  border-inline-start-color: #8a6fdf;
}

.dash-calendar-item.followup {
  border-inline-start-color: #20a7b5;
}

.dash-calendar-item-head span {
  height: 20px;
  display: inline-flex;
  align-items: center;
  padding: 0 7px;
  border-radius: 999px;
  background: rgba(185, 149, 91, 0.1);
  color: #9a7840;
  font-size: 10px;
  font-weight: 900;
}

.dash-calendar-item-head time {
  color: #82786a;
  font-size: 10px;
}

.dash-calendar-item > strong {
  min-width: 0;
  color: #1f241f;
  font-size: 12px;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-calendar-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.dash-calendar-fields span {
  min-width: 0;
  padding: 5px 6px;
  border: 1px solid rgba(44, 35, 24, 0.06);
  border-radius: 9px;
  background: #fbf8f1;
}

.dash-calendar-fields em,
.dash-calendar-fields b {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-calendar-fields em {
  margin-bottom: 1px;
  color: #9a907f;
  font-size: 9px;
  font-style: normal;
}

.dash-calendar-fields b {
  color: #1f241f;
  font-size: 10px;
}

.dash-calendar-open {
  width: max-content;
  min-height: 25px;
  justify-self: end;
}

.request-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.request-tabs a {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px solid #e5e1d5;
  border-radius: 7px;
  background: #fff;
  color: #555950;
  text-decoration: none;
  font-size: 13px;
  font-weight: 900;
}

.request-tabs a.active,
.request-tabs a:hover {
  color: #fff;
  background: #11130f;
}

.request-list {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.request-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #ebe8df;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(18, 18, 12, 0.05);
}

.request-card header,
.request-meta,
.request-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.request-card header strong {
  display: block;
  font-size: 17px;
}

.request-card header span,
.request-meta span b {
  color: #777;
  font-size: 12px;
  font-weight: 900;
}

.request-card header em {
  padding: 5px 10px;
  border-radius: 999px;
  background: #f7f6ee;
  color: #11130f;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.request-meta {
  justify-content: flex-start;
}

.request-meta span {
  min-width: 160px;
  display: grid;
  gap: 2px;
}

.request-card p {
  margin: 0;
  padding: 12px;
  border-radius: 8px;
  background: #f8f8f5;
  color: #333;
  line-height: 1.7;
  user-select: text;
}

.request-files {
  display: grid;
  gap: 8px;
}

.request-files > b {
  font-size: 13px;
}

.request-files > div {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.request-files a {
  min-height: 42px;
  display: inline-grid;
  align-content: center;
  gap: 2px;
  padding: 8px 12px;
  border: 1px solid #e8e3d7;
  border-radius: 8px;
  background: #fffaf0;
  color: #11130f;
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(18, 18, 12, 0.05);
}

.request-files a span {
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 900;
}

.request-files a small {
  color: #777;
  font-size: 11px;
  font-weight: 800;
}

.request-actions select,
.request-message textarea {
  min-height: 40px;
  border: 1px solid #d9d9d5;
  border-radius: 8px;
  padding: 8px 10px;
  background: #fff;
  user-select: text;
}

.request-message {
  display: grid;
  gap: 8px;
}

.request-message label {
  display: grid;
  gap: 6px;
}

@media print {
  .case-topbar-actions,
  .case-topbar a,
  .compact-sidebar,
  .compact-actions,
  .tiny-btn {
    display: none !important;
  }

  body,
  .secure-page {
    background: #fff !important;
  }

  .case-page {
    width: 100%;
    padding: 0;
  }

  .case-card,
  .case-topbar {
    border-color: #ddd;
    break-inside: avoid;
  }
}

@keyframes flash {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.48;
  }
}

@keyframes loading {
  0% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(240%);
  }
}

@media (max-width: 980px) {
  .login-page {
    padding: 24px 18px;
  }

  .login-box {
    grid-template-columns: 1fr;
    gap: 28px;
    min-height: auto;
    padding: 64px 24px 30px;
  }

  .login-visual {
    width: 100%;
    height: 360px;
  }

  .login-shell {
    width: min(380px, 100%);
  }

  .app-dashboard {
    grid-template-columns: 1fr;
  }

  .app-sidebar {
    position: static;
    height: auto;
  }

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

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

  .dashboard-hero,
  .dashboard-workbench {
    flex-direction: column;
  }

  .lexo-dashboard {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 22px;
    border-radius: 0;
  }

  .lexo-side-menu {
    order: -1;
    min-height: auto;
  }

  .lexo-side-menu nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-board {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .compact-dashboard {
    grid-template-columns: 1fr;
  }

  .compact-sidebar {
    position: static;
    height: auto;
  }

  .compact-sidebar nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .compact-logout {
    margin-top: 12px;
  }

  .compact-grid {
    grid-template-columns: repeat(2, minmax(270px, 1fr));
  }

  .calendar-shell {
    grid-template-columns: 1fr;
  }

  .calendar-agenda {
    max-height: none;
  }

  .dash-calendar-fields {
    grid-template-columns: 1fr;
  }

  .full-calendar-grid {
    grid-template-columns: repeat(7, minmax(58px, 1fr));
  }

  .case-layout,
  .case-form,
  .session-update-grid {
    grid-template-columns: 1fr;
  }

  .board-column {
    gap: 24px;
  }
}

@media (max-width: 680px) {
  [dir="ltr"] .language {
    right: 20px;
  }

  [dir="rtl"] .language {
    left: 20px;
  }

  .login-box {
    padding: 58px 16px 24px;
  }

  .login-visual {
    height: 300px;
  }

  .intro h1 {
    margin-bottom: 18px;
    font-size: 26px;
  }

  .intro p,
  .hint {
    font-size: 18px;
    line-height: 30px;
  }

  .secure-header {
    padding: 0 20px;
  }

  .secure-main {
    padding: 48px 0;
  }

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

  .app-content {
    padding: 18px;
  }

  .side-nav,
  .summary-strip,
  .module-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-hero {
    padding: 22px;
  }

  .dashboard-hero h1 {
    font-size: 28px;
  }

  .lexo-dashboard {
    padding: 14px;
  }

  .lexo-topbar {
    height: auto;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding: 18px;
  }

  .search-pill {
    width: 100%;
  }

  .lexo-side-menu nav {
    grid-template-columns: 1fr;
  }

  .legal-panel,
  .mini-calendar {
    padding: 18px 12px;
  }

  .calendar-grid {
    gap: 14px 8px;
  }

  .compact-dashboard {
    padding: 10px;
    gap: 10px;
  }

  .compact-sidebar nav,
  .compact-stats,
  .compact-grid {
    grid-template-columns: 1fr;
  }

  .compact-topbar {
    align-items: stretch;
    flex-direction: column;
  }

  .quick-actions {
    width: 100%;
  }

  .quick-actions a {
    flex: 1;
    justify-content: center;
  }

  .compact-search {
    width: 100%;
  }

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

  .calendar-board {
    padding: 10px;
  }

  .calendar-month-head {
    align-items: stretch;
    flex-direction: column;
  }

  .full-calendar-grid {
    gap: 5px;
    grid-template-columns: repeat(7, minmax(34px, 1fr));
  }

  .full-calendar-grid > strong {
    font-size: 10px;
  }

  .calendar-day {
    min-height: 58px;
    padding: 7px;
  }

  .calendar-day b {
    font-size: 13px;
  }

  .dash-calendar-card {
    gap: 9px;
  }

  .dash-calendar-top,
  .dash-calendar-results header {
    align-items: flex-start;
  }

  .dash-calendar-day {
    border-radius: 8px;
  }

  .dash-calendar-day b {
    font-size: 10px;
  }

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

  .case-page {
    width: calc(100% - 20px);
    padding-top: 10px;
  }

  .case-topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .detail-grid,
  .form-grid,
  .amount-edit-row,
  .custom-edit-row,
  .import-summary-grid,
  .import-result-row,
  .list-filters,
  .list-table > header,
  .list-row,
  .list-field-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Lexo Office dashboard agenda redesign ===== */
.lx-agenda-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(310px, 0.85fr);
  gap: 16px;
  align-items: start;
  margin-top: 14px;
}

.lx-agenda-card {
  min-height: auto;
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 16px;
  padding: 22px;
  border: 1px solid rgba(250, 209, 41, 0.12);
  border-radius: 28px;
  background:
    radial-gradient(circle at 12% 100%, rgba(250, 209, 41, 0.13), transparent 28%),
    linear-gradient(135deg, #20271f 0%, #11170f 100%);
  color: #fff;
  box-shadow: 0 22px 60px rgba(18, 18, 12, 0.14);
}

.lx-agenda-card::after {
  content: '';
  position: absolute;
  inset-inline-start: 22px;
  bottom: -22px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 18px solid rgba(250, 209, 41, 0.035);
  pointer-events: none;
}

.lx-agenda-head {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 6px;
  max-width: 760px;
}

.lx-agenda-kicker {
  color: rgba(255, 255, 255, 0.54);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.lx-agenda-head h2,
.lx-agenda-head p {
  margin: 0;
}

.lx-agenda-head h2 {
  color: #fff;
  font-size: clamp(25px, 3vw, 38px);
  line-height: 1.15;
}

.lx-agenda-head p {
  color: rgba(255, 255, 255, 0.68);
  font-size: 15px;
  line-height: 1.65;
}

.lx-agenda-metrics {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
}

.lx-agenda-metric {
  min-height: 86px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.065);
  color: #fff;
  text-decoration: none;
  backdrop-filter: blur(12px);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.lx-agenda-metric:hover,
.lx-agenda-metric:focus {
  transform: translateY(-1px);
  border-color: rgba(250, 209, 41, 0.32);
  background: rgba(255, 255, 255, 0.105);
  outline: none;
}

.lx-agenda-metric span,
.lx-agenda-metric small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lx-agenda-metric span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 900;
}

.lx-agenda-metric strong {
  color: #f6d66d;
  font-size: 27px;
  line-height: 1;
}

.lx-agenda-metric small {
  color: rgba(255, 255, 255, 0.45);
  font-size: 11px;
  font-weight: 800;
}

.lx-agenda-work {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.06);
}

.lx-agenda-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.lx-agenda-title-row div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.lx-agenda-title-row span {
  color: rgba(255, 255, 255, 0.5);
  font-size: 11px;
  font-weight: 900;
}

.lx-agenda-title-row strong {
  color: #fff;
  font-size: 15px;
}

.lx-agenda-title-row a,
.lx-agenda-actions a {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 999px;
  color: #151911;
  background: #f5d978;
  text-decoration: none;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

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

.lx-agenda-work .dash-calendar-item {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: none;
}

.lx-agenda-empty {
  display: grid;
  gap: 6px;
  padding: 18px;
  border: 1px dashed rgba(250, 209, 41, 0.32);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.055);
  text-align: center;
}

.lx-agenda-empty strong {
  color: #fff;
  font-size: 15px;
}

.lx-agenda-empty span {
  color: rgba(255, 255, 255, 0.56);
  font-size: 13px;
}

.lx-agenda-actions {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lx-agenda-actions a {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.lx-agenda-actions a:hover,
.lx-agenda-actions a:focus {
  border-color: rgba(250, 209, 41, 0.38);
  background: rgba(250, 209, 41, 0.14);
  outline: none;
}

.lx-agenda-hero .dash-calendar-card {
  min-height: auto;
  max-height: none;
  padding: 18px;
  border: 1px solid #ebe3d3;
  border-radius: 28px;
  background: #fffdf8;
  box-shadow: 0 18px 50px rgba(18, 18, 12, 0.08);
}

.lx-agenda-hero .dash-calendar-grid {
  gap: 5px;
}

.lx-agenda-hero .dash-calendar-day {
  border-radius: 12px;
}

.lx-agenda-hero .dash-calendar-results {
  max-height: 330px;
  overflow: auto;
  padding-inline-end: 2px;
}

.lx-agenda-hero .dash-calendar-results .dash-calendar-item:nth-of-type(n+4) {
  display: none;
}

@media (max-width: 1180px) {
  .lx-agenda-hero {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 720px) {
  .lx-agenda-card,
  .lx-agenda-hero .dash-calendar-card {
    border-radius: 20px;
    padding: 14px;
  }

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

  .lx-agenda-title-row {
    align-items: stretch;
    flex-direction: column;
  }

  .lx-agenda-title-row a {
    width: 100%;
  }

  .lx-agenda-actions a {
    flex: 1 1 140px;
  }
}
