
:root{
  --sd-primary:#F84300;
  --sd-primary-2:#ff6a3d;
  --sd-dark:#0f172a;
  --sd-gray:#334155;
  --sd-bg:#f6f7fb;
  --sd-card:#ffffff;
}

.sd-guide-fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1060;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--sd-primary);
  color: #fff;
  font-size: 20px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.2);
}

.sd-guide-fab:hover {
  background: var(--sd-primary-2);
}

.sd-guide-hint {
  position: fixed;
  right: 84px;
  bottom: 33px;
  z-index: 1059;
  padding: 4px 10px;
  border-radius: 999px;
  background: #0b1220;
  color: #fff;
  font-size: 11px;
  line-height: 1;
  border: 1px solid rgba(248, 67, 0, 0.35);
}
body{
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
  background: var(--sd-bg);
  color:#0b1220;
}
a{ color: var(--sd-primary); }
a:hover{ color: var(--sd-primary-2); }

.sd-topbar{
  background: linear-gradient(90deg, var(--sd-dark), #111827);
  color: #fff;
  border-bottom: 3px solid var(--sd-primary);
}
.sd-brand-badge{
  display:inline-flex; align-items:center; gap:.5rem;
  font-weight:800; letter-spacing:.3px;
}
.sd-dot{ width:10px; height:10px; border-radius:50%; background:var(--sd-primary); display:inline-block; }

.sd-card{
  background: var(--sd-card);
  border: 1px solid rgba(15,23,42,.08);
  box-shadow: 0 10px 30px rgba(15,23,42,.06);
  border-radius: 18px;
}

.btn-sd{
  --bs-btn-bg: var(--sd-primary);
  --bs-btn-border-color: var(--sd-primary);
  --bs-btn-hover-bg: var(--sd-primary-2);
  --bs-btn-hover-border-color: var(--sd-primary-2);
  --bs-btn-color:#fff;
  --bs-btn-hover-color:#fff;
  font-weight:700;
}
.btn-sd-outline{
  --bs-btn-color: var(--sd-primary);
  --bs-btn-border-color: var(--sd-primary);
  --bs-btn-hover-bg: var(--sd-primary);
  --bs-btn-hover-border-color: var(--sd-primary);
  --bs-btn-hover-color:#fff;
  font-weight:700;
}

.badge-sd{
  background: rgba(248,67,0,.12);
  color: var(--sd-primary);
  border: 1px solid rgba(248,67,0,.25);
}

.sd-muted{ color: #475569; }
.sd-kpi{
  border-left: 4px solid var(--sd-primary);
  padding-left: .9rem;
}

.sd-sidebar{
  background: #0b1220;
  color:#cbd5e1;
  border-radius:18px;
}
.sd-sidebar a{
  color:#cbd5e1; text-decoration:none;
}
.sd-sidebar a:hover{
  color:#fff;
}
.sd-nav-item{
  padding:.7rem .8rem;
  border-radius: 12px;
}
.sd-nav-item.active{
  background: rgba(248,67,0,.14);
  border:1px solid rgba(248,67,0,.28);
  color:#fff;
}
.sd-section-title{
  font-weight:800;
  letter-spacing:.2px;
}
.sd-divider{
  height:1px;
  background: rgba(15,23,42,.08);
}
.sd-help{
  background: #0b1220;
  color:#e2e8f0;
  border-radius: 16px;
  border:1px solid rgba(248,67,0,.25);
}
.sd-table thead th{
  background: #0b1220;
  color:#e2e8f0;
  border-color: rgba(255,255,255,.08);
}
.small-caps{ font-variant: all-small-caps; letter-spacing:.8px; }

.modal .sd-card #crudForm .form-label {
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.modal .sd-card #crudForm .form-control,
.modal .sd-card #crudForm .form-select {
  border-radius: 10px;
}

.modal .sd-card #crudForm .form-text {
  font-size: 0.78rem;
  color: #64748b;
}

.modal .sd-card #crudForm select[multiple] {
  min-height: 170px;
}


/* ===========================
   ShowDeal Home Layout (Header + Sidebar)
   =========================== */

:root{
  --sd-bg: #ffffff;
  --sd-dark: #0b1220;
  --sd-dark-2: #0f1a2d;
  --sd-border: rgba(15, 23, 42, 0.10);
  --sd-muted: rgba(255,255,255,0.72);
  --sd-muted-2: rgba(255,255,255,0.50);
  --sd-orange: #ff4d00;
}

.sd-body{
  background: var(--sd-bg);
  min-height: 100vh;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Topbar */
.sd-topbar{
  background: radial-gradient(1200px 400px at 30% 0%, #1a2b46 0%, var(--sd-dark) 60%);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 1030;
}

.sd-topbar-inner{
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sd-topbar-accent{
  height: 3px;
  background: var(--sd-orange);
}

.sd-brand{
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.sd-dot{
  width: 10px;
  height: 10px;
  border-radius: 99px;
  background: var(--sd-orange);
  box-shadow: 0 0 0 4px rgba(255,77,0,0.15);
}

.sd-brand-text{
  font-size: 18px;
}

.sd-badge{
  font-size: 11px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255,77,0,0.12);
  border: 1px solid rgba(255,77,0,0.45);
  color: #ffb59a;
}

.sd-topnav{
  display: flex;
  align-items: center;
  gap: 18px;
}

.sd-toplink{
  color: var(--sd-muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}

.judicial-lot-actions-row {
  margin-top: 4px;
}

#lotCreateCompanies {
  min-height: 38px;
}

.lot-module-shell {
  background: linear-gradient(180deg, #fdfefe 0%, #f8fbff 100%);
}

.lot-header-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(180deg, #e8eeff 0%, #f4f7ff 100%);
  color: #3d57d8;
  font-weight: 800;
  font-size: 0.82rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.5px;
}

.lot-module-badge {
  background: linear-gradient(180deg, #5c68d8 0%, #4050d1 100%);
  color: #fff;
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.74rem;
  font-weight: 700;
}

.lot-kpi-card {
  border: 1px solid #e6ebf5;
  border-radius: 14px;
  padding: 16px;
  background: #ffffff;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
}

.lot-kpi-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.72rem;
}

.lot-kpi-icon-lot {
  background: #ecf2ff;
  color: #4663ef;
}

.lot-kpi-icon-vehicle {
  background: #e8f9f0;
  color: #18a558;
}

.lot-kpi-icon-invite {
  background: #ffefe7;
  color: #ef5b21;
}

.lot-kpi-value {
  font-weight: 800;
}

.lot-kpi-value-lot {
  color: #4365f1;
}

.lot-kpi-value-vehicle {
  color: #20aa5f;
}

.lot-kpi-value-invite {
  color: #f26522;
}

.lot-create-card,
.lot-table-card {
  border: 1px solid #e6ebf5;
  background: #ffffff;
}

.lot-create-icon,
.lot-table-icon {
  width: 24px;
  height: 24px;
  border-radius: 8px;
  background: #eef3ff;
  color: #4a5ee9;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.68rem;
}

.lot-file-dropzone {
  border: 2px dashed #b9cbfb;
  border-radius: 12px;
  background: linear-gradient(180deg, #f8fbff 0%, #f4f8ff 100%);
  padding: 16px;
  transition: border-color 120ms ease, background-color 120ms ease, transform 120ms ease;
}

.lot-file-dropzone:hover,
.lot-file-dropzone.is-dragover {
  border-color: #5d7af6;
  background: linear-gradient(180deg, #f3f8ff 0%, #edf4ff 100%);
  transform: translateY(-1px);
}

.lot-file-dropzone button {
  min-width: 140px;
}

.judicial-lot-actions button.lot-btn {
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid transparent;
  background: #1f2937;
  min-height: 42px;
  min-width: 170px;
  border-radius: 10px;
  font-weight: 700;
  color: #fff;
  padding: 0 14px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: transform 120ms ease, filter 120ms ease;
}

.judicial-lot-actions .lot-btn-template {
  margin-right: auto;
}

.judicial-lot-actions .lot-btn-create {
  margin-left: auto;
}

.judicial-lot-actions button.lot-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
}

.judicial-lot-actions button.lot-btn-template {
  background: linear-gradient(180deg, #1d4ed8 0%, #1e40af 100%);
  border-color: #1e40af;
}

.judicial-lot-actions button.lot-btn-template:hover {
  background: linear-gradient(180deg, #2563eb 0%, #1d4ed8 100%);
  border-color: #1d4ed8;
}

.judicial-lot-actions button.lot-btn-create {
  background: linear-gradient(180deg, #ff5b1f 0%, #f84300 100%);
  border-color: #f84300;
  box-shadow: 0 6px 14px rgba(248, 67, 0, 0.25);
}

.judicial-lot-actions button.lot-btn-create:hover {
  background: linear-gradient(180deg, #ff6e3a 0%, #ff4f12 100%);
  border-color: #ff4f12;
}

.judicial-lot-actions button.lot-btn-refresh {
  background: linear-gradient(180deg, #475569 0%, #334155 100%);
  border-color: #334155;
}

.judicial-lot-actions button.lot-btn-refresh:hover {
  background: linear-gradient(180deg, #64748b 0%, #475569 100%);
  border-color: #475569;
}

.lot-icon-btn {
  width: 36px;
  height: 36px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  background: #ffffff;
  color: #334155;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 120ms ease, border-color 120ms ease, color 120ms ease;
}

.lot-icon-btn:hover {
  transform: translateY(-1px);
  border-color: #94a3b8;
  color: #0f172a;
}

.lot-icon-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

@media (max-width: 768px) {
  .lot-kpi-card {
    min-height: 82px;
  }

  .judicial-lot-actions button.lot-btn {
    min-width: 100%;
  }

  .judicial-lot-actions .lot-btn-template,
  .judicial-lot-actions .lot-btn-create {
    margin-left: 0;
    margin-right: 0;
  }

  .lot-module-badge {
    width: 100%;
    text-align: center;
  }
}

.first-login-visual-guide {
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
  border-radius: 14px;
  padding: 12px;
}

.flg-header {
  margin-bottom: 6px;
}

.flg-title {
  font-weight: 800;
  color: #0f172a;
}

.flg-subtitle {
  font-size: 0.86rem;
  color: #475569;
}

.flg-step {
  height: 100%;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #ffffff;
  border-radius: 12px;
  padding: 10px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.flg-step-badge {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #f84300;
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 28px;
  box-shadow: 0 4px 10px rgba(248, 67, 0, 0.25);
}

.flg-step-title {
  font-weight: 700;
  color: #0f172a;
  font-size: 0.93rem;
  line-height: 1.2;
}

.flg-step-text {
  margin-top: 2px;
  color: #475569;
  font-size: 0.84rem;
  line-height: 1.35;
}

.sd-toplink:hover{
  color: #fff;
}

/* Shell */
.sd-shell{
  padding: 18px;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.sd-shell > .row{
  height: 100%;
}

/* Sidebar */
.sd-sidebar-wrap{
  padding-right: 14px;
  height: 100%;
  min-height: 0;
}

.sd-sidebar{
  background: linear-gradient(180deg, var(--sd-dark) 0%, #0a1222 100%);
  border-radius: 18px;
  padding: 18px;
  height: 100%;
  min-height: 0;
  box-shadow: 0 10px 30px rgba(2,6,23,0.15);
  border: 1px solid rgba(255,255,255,0.06);
  overflow: hidden;
}

.sd-session{
  padding: 14px;
  border-radius: 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 14px;
}

.sd-session-label{
  font-size: 11px;
  letter-spacing: 1.1px;
  color: var(--sd-muted-2);
  font-weight: 800;
  margin-bottom: 8px;
}

.sd-session-user-title{
  font-size: 13px;
  color: var(--sd-muted);
  font-weight: 700;
}

.sd-session-user-name{
  font-size: 14px;
  color: #fff;
  font-weight: 800;
  margin-bottom: 10px;
}

.sd-pill{
  display: inline-block;
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255,77,0,0.10);
  border: 1px solid rgba(255,77,0,0.45);
  color: #ffb59a;
  font-weight: 700;
}

.sd-menu{
  padding: 8px 0 16px;
}

.sd-menu-item{
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--sd-muted);
  text-decoration: none;
  font-weight: 650;
  font-size: 14px;
  transition: 150ms ease-in-out;
}

.sd-bullet{
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: rgba(255,255,255,0.35);
  box-shadow: 0 0 0 6px rgba(255,255,255,0.03);
}

.sd-menu-item:hover{
  background: rgba(255,255,255,0.06);
  color: #fff;
}

.sd-menu-item.active{
  background: rgba(255,77,0,0.10);
  border: 1px solid rgba(255,77,0,0.25);
  color: #fff;
}

.sd-menu-item.active .sd-bullet{
  background: var(--sd-orange);
  box-shadow: 0 0 0 6px rgba(255,77,0,0.10);
}

/* Side card */
.sd-sidecard{
  margin-top: 14px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
}

.sd-sidecard-title{
  font-weight: 800;
  color: #fff;
  font-size: 12px;
  margin-bottom: 6px;
}

.sd-sidecard-text{
  color: var(--sd-muted);
  font-size: 12px;
  line-height: 1.35;
}

/* Logout */
.sd-logout{
  width: 100%;
  margin-top: 14px;
  border-radius: 12px;
}

/* Content placeholder */
.sd-content-wrap{
  padding-left: 14px;
  height: 100%;
  min-height: 0;
}

.sd-content{
  background: #fff;
  border-radius: 18px;
  height: 100%;
  min-height: 0;
  border: 1px solid var(--sd-border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

#appContent {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}