:root {
  --brand-primary: #1a3a5c;
  --brand-accent: #00bfa6;
}
body { font-family: Arial, Helvetica, sans-serif; font-size: 12pt; }

.body-login {
  background: #fff;
}
.card-login { background: #fff; border-radius: 1rem; box-shadow: 0 4px 20px rgba(0,0,0,0.08); border: 1px solid #e8eef4; }
.login-logo { max-height: 100px; }
.login-servicios { display: flex; flex-wrap: wrap; justify-content: center; gap: .35rem .75rem; }
.login-servicios span { font-size: .72rem; color: rgba(255,255,255,.7); letter-spacing: .3px; white-space: nowrap; }
.login-servicios span i { color: var(--brand-accent); margin-right: .2rem; }
.login-icon { width: 80px; height: 80px; margin: 0 auto; border-radius: 50%; background: linear-gradient(135deg, #e0f7fa, #b2ebf2); display: flex; align-items: center; justify-content: center; }

.body-app { background: linear-gradient(180deg, #e8eef4 0%, #d4dde8 50%, #c5d1e0 100%); background-attachment: fixed; min-height: 100vh; overflow-x: hidden; }

.welcome-banner { background: linear-gradient(90deg, var(--brand-primary), #2c5364); color: #fff; padding: 0.6rem 0; margin: -1rem -0.5rem 1rem; border-radius: 0 0 .5rem .5rem; box-shadow: 0 2px 8px rgba(26,58,92,0.25); }
.welcome-banner .welcome-text { font-size: 1.05rem; font-weight: 500; }
.welcome-banner .welcome-date { font-size: .85rem; opacity: .9; }

.app-layout { min-height: 100vh; }
.sidebar { width: 240px; min-width: 240px; background: linear-gradient(180deg, #0f2027, #203a43); color: #fff; display: flex; flex-direction: column; box-shadow: 2px 0 12px rgba(0,0,0,.15); }
.sidebar-brand { padding: .75rem; border-bottom: 1px solid rgba(255,255,255,.1); display: flex; align-items: center; gap: .5rem; }
.sidebar-logo { max-height: 45px; border-radius: 8px; padding: 4px 8px; background: rgba(255,255,255,.95); box-shadow: 0 1px 4px rgba(0,0,0,.2); }
.sidebar-servicios { padding: .5rem .75rem; border-bottom: 1px solid rgba(255,255,255,.08); display: flex; flex-direction: column; gap: .15rem; }
.sidebar-servicios span { font-size: .65rem; color: rgba(255,255,255,.5); letter-spacing: .3px; }
.sidebar-servicios span i { color: var(--brand-accent); margin-right: .25rem; font-size: .6rem; }
.sidebar-nav { padding: 1rem .75rem; display: flex; flex-direction: column; gap: .35rem; flex: 1; }
.sidebar .btn-menu { text-align: left; color: rgba(255,255,255,.9); background: rgba(255,255,255,.06); border: none; padding: .6rem 1rem; border-radius: .5rem; font-weight: 500; transition: background .2s; }
.sidebar .btn-menu:hover { background: rgba(255,255,255,.12); color: #fff; }
.sidebar .btn-menu.btn-salir { color: #f8a5a5; }
.sidebar .btn-menu.btn-salir:hover { background: rgba(220,53,69,.3); color: #fff; }
.sidebar-footer { padding: 1rem .75rem; border-top: 1px solid rgba(255,255,255,.1); display: flex; flex-direction: column; gap: .5rem; }
.sidebar-user { font-size: .9rem; color: rgba(255,255,255,.75); padding: 0 .5rem; }
.main-content { overflow-x: auto; min-width: 0; }

.sidebar-toggle { position: fixed; top: .75rem; left: .75rem; z-index: 1030; width: 44px; height: 44px; border-radius: .5rem; border: none; background: var(--brand-primary); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; box-shadow: 0 2px 8px rgba(0,0,0,.2); }
.sidebar-close { background: none; border: none; color: rgba(255,255,255,.8); padding: .25rem; font-size: 1.25rem; }
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 1025; }
body.sidebar-open .sidebar-overlay { display: block; }

@media (max-width: 991.98px) {
  .app-layout { flex-direction: column; }
  .sidebar { position: fixed; top: 0; left: 0; bottom: 0; width: 260px; min-width: 260px; z-index: 1030; transform: translateX(-100%); transition: transform .25s ease-out; }
  body.sidebar-open .sidebar { transform: translateX(0); }
  .main-content { width: 100%; padding-top: 3.5rem; padding-left: .75rem; padding-right: .75rem; }
}
@media (min-width: 992px) { .sidebar-toggle, .sidebar-close, .sidebar-overlay { display: none !important; } }

@media (max-width: 767.98px) {
  .welcome-banner { flex-direction: column; padding: .5rem .75rem; }
  .container { padding-left: .5rem; padding-right: .5rem; }
  .card-body { padding: 1rem !important; }
  .btn-lg { width: 100%; margin-bottom: .5rem; }
  .table { font-size: .8rem; }
  .table th, .table td { padding: .35rem; }
}

.card { border-radius: .75rem; overflow: hidden; }
.card-header { border-bottom: none; }
.form-control:focus, .form-select:focus { border-color: var(--brand-accent); box-shadow: 0 0 0 .2rem rgba(0,191,166,.15); }

.cotizacion-print { background: #fff; }

.servicios-barra { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 16px; }
.servicios-header { display: flex; flex-direction: column; gap: 3px; }
.servicio-item {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--brand-primary);
  letter-spacing: 0.4px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 2px 0;
  border-bottom: 1px solid rgba(0,191,166,0.15);
}
.servicios-barra .servicio-item { border-bottom: none; padding: 0; }
.servicio-item:last-child { border-bottom: none; }
.servicio-icono {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 3px;
  background: linear-gradient(135deg, #00bfa6, #00897b);
  color: #fff;
  font-size: 0.55rem;
  flex-shrink: 0;
}
.datos-pago { background: #f8fafc; border-color: #dee2e6 !important; }
.datos-pago h6 { color: var(--brand-primary); }

@page {
  size: 216mm 330mm;
  margin: 12mm 15mm;
}

@media print {
  *, *::before, *::after { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; color-adjust: exact !important; }
  html, body { width: 216mm; min-height: 330mm; margin: 0 !important; padding: 0 !important; background: #fff !important; font-family: Arial, Helvetica, sans-serif !important; font-size: 12pt !important; }
  .sidebar, .navbar, footer, .no-print, .sidebar-toggle, .sidebar-overlay, .welcome-banner { display: none !important; }
  .main-content { margin: 0 !important; padding: 0 !important; width: 100% !important; }
  .app-layout { display: block !important; }
  .container { max-width: 100% !important; padding: 0 !important; margin: 0 !important; }
  .row.justify-content-center { margin: 0 !important; }
  .col-lg-10 { width: 100% !important; max-width: 100% !important; padding: 0 !important; flex: 0 0 100% !important; }
  .card { box-shadow: none !important; border: none !important; border-radius: 0 !important; }
  .cotizacion-print { border: none !important; box-shadow: none !important; }
  .cotizacion-print .card-body { padding: 0 !important; }
  .table { font-size: 11pt !important; }
  .table th, .table td { padding: .3rem .4rem !important; }
  .datos-pago { page-break-inside: avoid; }
  .table-dark th { background-color: #1a3a5c !important; color: #fff !important; }
  .table-primary td { background-color: #cfe2ff !important; }
  .alert-warning { background-color: #fff3cd !important; border-color: #ffecb5 !important; }
  .servicio-icono { background: linear-gradient(135deg, #00bfa6, #00897b) !important; color: #fff !important; }
  .servicio-item { color: #1a3a5c !important; border-bottom-color: rgba(0,191,166,0.15) !important; }
}
