/* Capservi Clean Corporate Web Styles - Login Page Override */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* Apply custom grayscale industrial background only to login page */
body[data-path="login"] {
  background: #0f172a !important; /* fallback slate-900 background */
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
}

body[data-path="login"]::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(15, 23, 42, 0.45), rgba(30, 41, 59, 0.55)), 
    url("/assets/mdx_capservi2/images/portada.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: grayscale(100%); /* Elegant grayscale filter */
  z-index: -1;
  pointer-events: none;
}

/* Minimalist Clean Login Card */
body[data-path="login"] .page-card {
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  border-radius: 8px !important;
  background-color: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.45) !important;
  padding: 30px !important;
}

body[data-path="login"] .page-card-head {
  margin-bottom: 24px !important;
}

body[data-path="login"] .page-card-head img {
  max-height: 48px !important;
}

/* Custom header text to say Iniciar sesión en CAPSERVI and make it highly readable */
body[data-path="login"] .page-card-head h4 {
  color: #ffffff !important;
  font-weight: 500 !important;
  margin-top: 16px !important;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5) !important;
}

body[data-path="login"] section.for-login .page-card-head h4,
body[data-path="login"] section.for-email-login .page-card-head h4 {
  font-size: 0 !important;
}

body[data-path="login"] section.for-login .page-card-head h4::after,
body[data-path="login"] section.for-email-login .page-card-head h4::after {
  content: "Iniciar sesión en CAPSERVI" !important;
  font-size: 18px !important;
  color: #ffffff !important;
}

body[data-path="login"] section.for-forgot .page-card-head h4 {
  font-size: 0 !important;
}

body[data-path="login"] section.for-forgot .page-card-head h4::after {
  content: "Restablecer contraseña" !important;
  font-size: 18px !important;
  color: #ffffff !important;
}

body[data-path="login"] section.for-signup .page-card-head h4 {
  font-size: 0 !important;
}

body[data-path="login"] section.for-signup .page-card-head h4::after {
  content: "Crear una cuenta" !important;
  font-size: 18px !important;
  color: #ffffff !important;
}

/* Align and prevent icons overlapping text inside inputs */
body[data-path="login"] .form-control {
  border-radius: 4px !important;
  border: 1px solid #cbd5e1 !important;
  padding: 10px 14px !important;
  font-size: 14px !important;
}

body[data-path="login"] .form-control:focus {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15) !important;
}

body[data-path="login"] .email-field .form-control {
  padding-left: 38px !important;
}

body[data-path="login"] .password-field .form-control {
  padding-left: 38px !important;
  padding-right: 64px !important;
}

body[data-path="login"] .field-icon {
  top: 50% !important;
  transform: translateY(-50%) !important;
  left: 12px !important;
}

body[data-path="login"] .toggle-password {
  top: 50% !important;
  transform: translateY(-50%) !important;
  right: 12px !important;
}

/* Submit button */
body[data-path="login"] .btn-login {
  background-color: #1e3a8a !important;
  border-color: #1e3a8a !important;
  font-weight: 600 !important;
  border-radius: 4px !important;
  padding: 10px !important;
  font-size: 14px !important;
  transition: background-color 0.2s ease !important;
}

body[data-path="login"] .btn-login:hover {
  background-color: #1d4ed8 !important;
  border-color: #1d4ed8 !important;
}

/* Custom Icons for Workspace Card Links (Desk UI) */
.workspace-page .link-item::before,
.links-widget-box .link-item::before {
  display: inline-block !important;
  margin-right: 6px !important;
  font-size: 14px !important;
}

/* Accesos Rápidos */
.workspace-page .link-item[title="Dashboard Capservi"]::before,
.workspace-page .link-item[href*="capservi-dashboard"]::before,
.links-widget-box .link-item[title="Dashboard Capservi"]::before,
.links-widget-box .link-item[href*="capservi-dashboard"]::before { content: "📊" !important; }

.workspace-page .link-item[title="Egresos"]::before,
.workspace-page .link-item[href*="Egreso"]::before,
.links-widget-box .link-item[title="Egresos"]::before,
.links-widget-box .link-item[href*="Egreso"]::before { content: "💵" !important; }

.workspace-page .link-item[title="Facturas de Compra"]::before,
.workspace-page .link-item[href*="Purchase%20Invoice"]::before,
.workspace-page .link-item[href*="Purchase_Invoice"]::before,
.workspace-page .link-item[href*="Purchase Invoice"]::before,
.links-widget-box .link-item[title="Facturas de Compra"]::before,
.links-widget-box .link-item[href*="Purchase%20Invoice"]::before,
.links-widget-box .link-item[href*="Purchase_Invoice"]::before,
.links-widget-box .link-item[href*="Purchase Invoice"]::before { content: "🧾" !important; }

.workspace-page .link-item[title="Proyectos"]::before,
.workspace-page .link-item[href*="Project"]::before,
.links-widget-box .link-item[title="Proyectos"]::before,
.links-widget-box .link-item[href*="Project"]::before { content: "🏗️" !important; }

.workspace-page .link-item[title="Centros de Costo"]::before,
.workspace-page .link-item[href*="Cost%20Center"]::before,
.workspace-page .link-item[href*="Cost_Center"]::before,
.workspace-page .link-item[href*="Cost Center"]::before,
.links-widget-box .link-item[title="Centros de Costo"]::before,
.links-widget-box .link-item[href*="Cost%20Center"]::before,
.links-widget-box .link-item[href*="Cost_Center"]::before,
.links-widget-box .link-item[href*="Cost Center"]::before { content: "🏢" !important; }

.workspace-page .link-item[title="Plan de Cuentas"]::before,
.workspace-page .link-item[href*="Account"]::before,
.links-widget-box .link-item[title="Plan de Cuentas"]::before,
.links-widget-box .link-item[href*="Account"]::before { content: "📋" !important; }

.workspace-page .link-item[title="Proveedores"]::before,
.workspace-page .link-item[href*="Supplier"]::before,
.links-widget-box .link-item[title="Proveedores"]::before,
.links-widget-box .link-item[href*="Supplier"]::before { content: "🤝" !important; }

/* Informes y Reportes */
.workspace-page .link-item[title="Egresos vs Presupuesto"]::before,
.workspace-page .link-item[href*="Egresos%20vs%20Presupuesto"]::before,
.workspace-page .link-item[href*="Egresos vs Presupuesto"]::before,
.links-widget-box .link-item[title="Egresos vs Presupuesto"]::before,
.links-widget-box .link-item[href*="Egresos%20vs%20Presupuesto"]::before,
.links-widget-box .link-item[href*="Egresos vs Presupuesto"]::before { content: "📈" !important; }

.workspace-page .link-item[title="Libro Mayor"]::before,
.workspace-page .link-item[href*="General%20Ledger"]::before,
.workspace-page .link-item[href*="General Ledger"]::before,
.links-widget-box .link-item[title="Libro Mayor"]::before,
.links-widget-box .link-item[href*="General%20Ledger"]::before,
.links-widget-box .link-item[href*="General Ledger"]::before { content: "📖" !important; }

.workspace-page .link-item[title="Balance de Situación"]::before,
.workspace-page .link-item[href*="Balance%20Sheet"]::before,
.workspace-page .link-item[href*="Balance Sheet"]::before,
.links-widget-box .link-item[title="Balance de Situación"]::before,
.links-widget-box .link-item[href*="Balance%20Sheet"]::before,
.links-widget-box .link-item[href*="Balance Sheet"]::before { content: "⚖️" !important; }

.workspace-page .link-item[title="Estado de Resultados"]::before,
.workspace-page .link-item[href*="Profit%20and%20Loss"]::before,
.workspace-page .link-item[href*="Profit and Loss"]::before,
.links-widget-box .link-item[title="Estado de Resultados"]::before,
.links-widget-box .link-item[href*="Profit%20and%20Loss"]::before,
.links-widget-box .link-item[href*="Profit and Loss"]::before { content: "📉" !important; }

.workspace-page .link-item[title="Balance de Comprobación"]::before,
.workspace-page .link-item[href*="Trial%20Balance"]::before,
.workspace-page .link-item[href*="Trial Balance"]::before,
.links-widget-box .link-item[title="Balance de Comprobación"]::before,
.links-widget-box .link-item[href*="Trial%20Balance"]::before,
.links-widget-box .link-item[href*="Trial Balance"]::before { content: "📊" !important; }

/* Control de Inventario */
.workspace-page .link-item[title="Almacenes"]::before,
.workspace-page .link-item[href*="Warehouse"]::before,
.links-widget-box .link-item[title="Almacenes"]::before,
.links-widget-box .link-item[href*="Warehouse"]::before { content: "📦" !important; }

.workspace-page .link-item[title="Catálogo de Ítems"]::before,
.workspace-page .link-item[href*="Item"]::before,
.links-widget-box .link-item[title="Catálogo de Ítems"]::before,
.links-widget-box .link-item[href*="Item"]::before { content: "🛠️" !important; }

.workspace-page .link-item[title="Registro de Stock"]::before,
.workspace-page .link-item[href*="Stock%20Ledger"]::before,
.workspace-page .link-item[href*="Stock Ledger"]::before,
.links-widget-box .link-item[title="Registro de Stock"]::before,
.links-widget-box .link-item[href*="Stock%20Ledger"]::before,
.links-widget-box .link-item[href*="Stock Ledger"]::before { content: "📊" !important; }

.workspace-page .link-item[title="Saldos de Stock"]::before,
.workspace-page .link-item[href*="Stock%20Balance"]::before,
.workspace-page .link-item[href*="Stock Balance"]::before,
.links-widget-box .link-item[title="Saldos de Stock"]::before,
.links-widget-box .link-item[href*="Stock%20Balance"]::before,
.links-widget-box .link-item[href*="Stock Balance"]::before { content: "⚖️" !important; }


