/* ============================================================
   LEGASIST · CAPA VISUAL MINIMALISTA
   Inspiración: interfaces clínicas/profesionales de lectura clara.
   Mantiene la paleta LEGASIST y el logotipo original.
   ============================================================ */
:root{
  --ls-radius-xs:10px;
  --ls-radius-sm:12px;
  --ls-radius-md:16px;
  --ls-radius-lg:20px;
  --ls-border:var(--dash-line,var(--border,#d8e4f2));
  --ls-surface:var(--dash-surface,var(--surface,#fff));
  --ls-surface-2:var(--dash-surface-2,var(--soft,#f7faff));
  --ls-text:var(--dash-text,var(--navy,#10233e));
  --ls-muted:var(--dash-muted,var(--muted,#667892));
  --ls-primary:var(--dash-primary,var(--blue,#0f4ea8));
  --ls-shadow:0 5px 18px rgba(12,45,98,.055);
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{font-feature-settings:"kern" 1,"liga" 1;text-rendering:optimizeLegibility}
img.brand-logo-img,.law-brand__logo{filter:none!important;transform:none!important;object-fit:contain!important}
.ui-icon{width:20px;height:20px;display:inline-block;vertical-align:-.2em;flex:0 0 auto}
.ui-icon.avatar-icon{width:30px;height:30px}.ui-icon.specialty-svg{width:22px;height:22px}.ui-icon.trust-svg{width:30px;height:30px}

/* Menos ostentación: superficies claras, bordes finos y sombras discretas. */
.panel,.law-card,.plan-mini,.guard-card,.step-card,.lawyer-card,.review-card,.favorite-card,.result-card,.search-panel,.search-summary-card,.registration-intro,.register-card,.login-card,.login-image-panel,.lawyer-login-card,.payment-panel,.order-panel,.create-card,.table-panel,.kpi,.note-store-card,.quick-compose,.scan-card,.sheet-card,.support-card,.legal-card,.calendar-card,.rating-summary,.rating-shell,.profile-card,.hero-card,.hero__panel{
  box-shadow:var(--ls-shadow)!important;
  border-radius:var(--ls-radius-md)!important;
}
.law-card,.plan-mini,.guard-card,.step-card,.lawyer-card,.review-card,.favorite-card,.result-card,.payment-panel,.order-panel,.create-card,.table-panel,.kpi,.note-store-card,.quick-compose,.scan-card,.legal-card{
  border-color:var(--ls-border)!important;
}
.law-card:hover,.lawyer-card:hover,.result-card:hover,.favorite-card:hover,.plan-mini:hover{transform:none!important;box-shadow:0 7px 22px rgba(12,45,98,.075)!important}

/* Elimina fotografías y fondos raster decorativos de la interfaz. */
.search-hero::before,
body.login-role-page.login-role-abogado,
body.login-role-page.login-role-abogado .lawyer-login-stage,
body.lawyer-register-premium .funnel-main,
body.lawyer-register-premium .register-banner,
.lawyer-login-copy.lawyer-login-image-only,
.login-image-panel,
.hero-media,
.side-preview,
.image-card,
.support-control-hero,
.favorites-hero,
.scan-hero,
.sheet-library-intro{
  background-image:none!important;
}
.search-hero::before{background:linear-gradient(135deg,var(--ls-primary),#1d67c8)!important}
body.login-role-page.login-role-abogado{background:linear-gradient(180deg,#f7faff,#eef4fb)!important}
html[data-theme="royal-dark"] body.login-role-page.login-role-abogado{background:linear-gradient(180deg,#071426,#0b1d35)!important}
.lawyer-login-copy.lawyer-login-image-only,.login-vector-panel,.login-image-panel{
  background:linear-gradient(145deg,rgba(15,78,168,.08),rgba(15,78,168,.02))!important;
  color:var(--ls-primary)!important;
}
html[data-theme="royal-dark"] .lawyer-login-copy.lawyer-login-image-only,
html[data-theme="royal-dark"] .login-vector-panel,
html[data-theme="royal-dark"] .login-image-panel{background:rgba(255,255,255,.035)!important;color:#8bbaff!important}
.login-vector-illustration{display:grid;place-items:center;width:100%;min-height:250px;padding:24px;color:inherit}
.login-vector-illustration svg{display:block;width:min(100%,520px);height:auto}
.register-vector{display:block;width:100%;max-width:420px;height:auto;margin:0 auto;color:var(--ls-primary)}

/* Avatares: siempre vectoriales/initials, sin fotografía de persona. */
.avatar--vector,.lawyer-avatar,.result-photo,.favorite-photo,.lawyer-photo,.profile-photo-preview,.vector-profile-avatar{
  position:relative;display:inline-grid!important;place-items:center!important;overflow:hidden!important;
  background:var(--dash-soft,#edf5ff)!important;color:var(--ls-primary)!important;border:1px solid var(--ls-border)!important;
  font-weight:900!important;text-transform:uppercase;
}
.avatar--vector img,.lawyer-avatar img,.result-photo img,.favorite-photo img,.lawyer-photo img,.profile-photo-preview img{display:none!important}
.avatar-initials{position:absolute;right:7px;bottom:5px;display:grid;place-items:center;min-width:21px;height:21px;padding:0 4px;border-radius:999px;background:var(--ls-surface);border:1px solid var(--ls-border);font-size:.62rem;font-weight:950}
.lawyer-photo--vector{gap:4px}.lawyer-photo--vector span{font-size:.72rem}.lawyer-profile-icon{width:34px;height:34px}
.vector-profile-note{display:flex!important;align-items:center;gap:14px;padding:14px;border:1px solid var(--ls-border);border-radius:var(--ls-radius-sm);background:var(--ls-surface-2)}
.vector-profile-avatar{width:52px;height:52px;border-radius:14px;flex:0 0 52px}.vector-profile-avatar .ui-icon{width:23px;height:23px}.vector-profile-avatar span{font-size:.68rem}.vector-profile-note small{display:block;margin-top:3px;color:var(--ls-muted);line-height:1.45}

/* Header y navegación: compactos, respirables y responsivos. */
.topbar,.law-topbar{box-shadow:none!important;border-bottom:1px solid var(--ls-border)!important}
.topbar__inner,.law-topbar__inner{gap:18px!important}
.nav-links,.law-nav{gap:6px!important}
.nav-links>a:not(.button),.law-nav>a:not(.law-btn){padding:9px 10px!important;border-radius:10px!important}
.nav-links>a:hover,.law-nav>a:hover{background:var(--ls-surface-2)!important}
.professional-access-link{display:inline-flex!important;align-items:center!important;justify-content:center!important;align-self:center!important;gap:6px!important;min-height:34px!important;padding:8px 14px!important;border:1px solid #0f4ea8!important;border-radius:999px!important;background:#0f4ea8!important;color:#fff!important;font-weight:850!important;font-size:.82rem!important;line-height:1!important;text-decoration:none!important;white-space:nowrap!important;vertical-align:middle!important}
.professional-access-link span{display:inline-flex!important;align-items:center!important;line-height:1!important;color:#fff!important}
.professional-access-link .ui-icon{width:16px;height:16px;color:#fff!important}
.professional-access-link:hover,.professional-access-link:focus-visible{background:#0a3f91!important;border-color:#0a3f91!important;color:#fff!important}
.footer-links{align-items:center!important}

/* Botones y campos coherentes. */
.button,.dash-btn,.law-btn,.mini-button,.sidebar-action,.filter-pill,.text-link,.change-plan-link{
  border-radius:11px!important;box-shadow:none!important;transition:background-color .16s ease,border-color .16s ease,color .16s ease!important;
}
.button.primary,.dash-btn.primary,.law-btn--primary,.login-button{box-shadow:none!important}
input,select,textarea,button{max-width:100%}
input,select,textarea{border-radius:11px!important;box-shadow:none!important}
input:focus,select:focus,textarea:focus{outline:3px solid rgba(15,78,168,.11)!important;outline-offset:0!important}

/* Dashboard y menú con iconografía SVG. */
.dash-sidebar{box-shadow:none!important;border-right:1px solid var(--ls-border)!important}
.dash-menu a{border-radius:11px!important;gap:10px!important}
.dash-menu a>.ui-icon,.sidebar-action>.ui-icon{width:18px;height:18px;flex:0 0 18px}
.dash-profile{border-radius:14px!important}
.dash-topbar{box-shadow:none!important;border:1px solid var(--ls-border)!important;border-radius:14px!important}

/* Landing / directorio. */
.directory-hero,.law-hero,.law-section,.directory-section{overflow:hidden}
.directory-hero__grid,.law-hero__grid{align-items:center!important}
.law-preview{box-shadow:var(--ls-shadow)!important;border-radius:18px!important}
.law-card__icon{width:42px!important;height:42px!important;display:grid!important;place-items:center!important;border-radius:12px!important}
.law-card__icon .ui-icon,.guard-card .ui-icon{width:22px;height:22px}
.specialty-grid a>span{display:grid!important;place-items:center!important;width:42px!important;height:42px!important;border-radius:12px!important}
.lawyer-avatar{gap:0!important}.lawyer-avatar .ui-icon{width:26px;height:26px}

/* Flujo de pago: acción principal en el resumen, no duplicada a la izquierda. */
.activation-summary-btn{min-height:48px!important;width:100%!important}
.activation-disclaimer{margin:10px 0 0;color:var(--ls-muted);font-size:.78rem;line-height:1.5}
.change-plan-link{display:inline-flex;margin-top:12px;color:var(--ls-primary);font-weight:800;text-decoration:none;font-size:.86rem}
.payment-tabs{gap:8px!important}.payment-tab{border-radius:10px!important;box-shadow:none!important}

/* Expedientes / honorarios. */
.fee-partial-block{grid-column:1/-1;border:1px solid var(--ls-border);border-radius:14px;padding:15px;background:var(--ls-surface-2)}
.fee-partial-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:12px}.fee-partial-head h3{margin:0;color:var(--ls-text);font-size:1rem}.fee-partial-head p{margin:4px 0 0;color:var(--ls-muted);font-size:.8rem;line-height:1.4}
.fee-partial-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.fee-partial-grid .span2{grid-column:span 2}.fee-partial-grid .full{grid-column:1/-1}
.fee-history{display:grid;gap:7px;margin-top:12px}.fee-history-title{font-size:.78rem;font-weight:900;color:var(--ls-muted);text-transform:uppercase;letter-spacing:.03em}
.fee-history-row{display:grid;grid-template-columns:minmax(86px,.7fr) minmax(90px,.8fr) minmax(100px,1fr) minmax(0,1.5fr);gap:8px;align-items:center;padding:9px 10px;border:1px solid var(--ls-border);border-radius:10px;background:var(--ls-surface);font-size:.78rem}
.fee-history-row strong{color:var(--ls-text)}.fee-history-row span{color:var(--ls-muted);overflow-wrap:anywhere}.fee-history-empty{padding:10px;border:1px dashed var(--ls-border);border-radius:10px;color:var(--ls-muted);font-size:.8rem;text-align:center}
.money-empty{color:var(--ls-muted);font-weight:800}.trash-note{display:inline-flex;align-items:center;gap:6px;color:var(--ls-muted);font-size:.76rem}.trash-note .ui-icon{width:15px;height:15px}
.icon-action{width:36px!important;height:36px!important;min-width:36px!important;padding:0!important;display:inline-grid!important;place-items:center!important;border-radius:10px!important}
.icon-action .ui-icon{width:17px;height:17px}.row-actions form{display:inline-flex;margin:0}.row-actions{align-items:center!important}
.trash-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;padding:14px 16px;border:1px solid var(--ls-border);border-radius:14px;background:var(--ls-surface-2)}

/* Evita decoraciones pseudo excesivas. */
.welcome-card::before,.welcome-card::after,.favorites-hero::before,.favorites-hero::after,.scan-hero::before,.scan-hero::after,.sheet-library-intro::before,.sheet-library-intro::after,.search-hero::after{opacity:.15!important;filter:none!important}

/* Responsive general. */
@media(max-width:1180px){
  .law-hero__grid,.directory-hero__grid,.payment-layout,.login-shell,.lawyer-login-card,.rating-shell{grid-template-columns:1fr!important}
  .law-grid-4,.plans-mini,.law-guard-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .law-grid-3,.steps-grid,.lawyer-grid,.reviews-grid,.specialty-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .fee-partial-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:760px){
  body{font-size:15px}
  .container,.law-container{width:min(100% - 24px,1180px)!important}
  .law-grid-4,.plans-mini,.law-guard-grid,.law-grid-3,.steps-grid,.lawyer-grid,.reviews-grid,.specialty-grid,.fee-partial-grid{grid-template-columns:1fr!important}
  .fee-partial-grid .span2{grid-column:auto}
  .fee-history-row{grid-template-columns:1fr 1fr}.fee-history-row span:last-child{grid-column:1/-1}
  .professional-cta__inner,.footer-inner,.law-footer__inner{align-items:flex-start!important;flex-direction:column!important}
  .nav-links,.law-nav{width:100%!important;overflow-x:auto!important;flex-wrap:nowrap!important;padding-bottom:4px!important}
  .topbar__inner,.law-topbar__inner{flex-wrap:wrap!important}
  .login-vector-illustration{min-height:180px;padding:14px}
  .lawyer-login-copy.lawyer-login-image-only{min-height:220px!important}
  .manage-dialog{max-height:calc(100dvh - 20px)!important;overflow:auto!important}
  .row-actions{gap:5px!important}
  .kpi-grid{grid-template-columns:1fr 1fr!important}
}
@media(max-width:520px){
  .kpi-grid{grid-template-columns:1fr!important}
  .fee-history-row{grid-template-columns:1fr}
  .fee-history-row span:last-child{grid-column:auto}
  .vector-profile-note{align-items:flex-start}
  .professional-access-link{width:auto!important}
}

/* Ajustes finales · entrega minimalista */
.vector-dashboard-card{
  min-height:210px!important;padding:28px!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:18px!important;
  border:1px solid #0a3f91!important;background:linear-gradient(135deg,#0f4ea8 0%,#0a3f91 100%)!important;color:#fff!important;
}
.vector-dashboard-icon{width:68px;height:68px;display:grid;place-items:center;flex:0 0 68px;border-radius:18px;background:rgba(255,255,255,.12)!important;border:1px solid rgba(255,255,255,.28)!important;color:#fff!important}
.vector-dashboard-icon .ui-icon{width:30px;height:30px;color:#fff!important}.vector-dashboard-card b{display:block;font-size:1.05rem;color:#fff!important}.vector-dashboard-card span{display:block;margin-top:5px;max-width:340px;color:rgba(255,255,255,.86)!important;line-height:1.5;font-size:.88rem}
.stat-icon,.qicon,.benefit-icon,.ci-row .icon{font-style:normal}
.payment-tab{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important}.payment-tab .ui-icon{width:17px;height:17px}.security-pill{display:inline-flex!important;align-items:center!important;gap:5px!important}.security-pill .ui-icon{width:14px;height:14px}.free-banner-icon{width:34px;height:34px;display:grid;place-items:center;flex:0 0 34px;border-radius:10px;border:1px solid currentColor}.free-banner-icon .ui-icon{width:18px;height:18px}

/* Honorarios conserva su ubicación original; pagos parciales se despliegan debajo, nunca como panel lateral. */
details.fee-partial-block{padding:0!important;overflow:hidden!important;background:var(--ls-surface)!important}
.fee-partial-summary{list-style:none;cursor:pointer;display:flex;align-items:center;gap:11px;padding:12px 14px;min-height:58px;background:var(--ls-surface-2);color:var(--ls-text);user-select:none}
.fee-partial-summary::-webkit-details-marker{display:none}.fee-partial-summary::marker{display:none;content:""}
.fee-partial-summary-icon{display:grid;place-items:center;width:30px;height:30px;flex:0 0 30px;border:1px solid var(--ls-border);border-radius:9px;background:var(--ls-surface);color:var(--ls-primary)}
.fee-partial-summary-icon .ui-icon,.fee-partial-summary-money .ui-icon{width:16px;height:16px}.fee-partial-summary>span:nth-child(2){min-width:0;flex:1}.fee-partial-summary b{display:block;font-size:.9rem}.fee-partial-summary small{display:block;margin-top:2px;color:var(--ls-muted);font-size:.75rem;line-height:1.35;font-weight:500}.fee-partial-summary-money{display:grid;place-items:center;color:var(--ls-primary)}
.fee-partial-block[open] .fee-partial-summary{border-bottom:1px solid var(--ls-border)}.fee-partial-content{padding:14px}
.fee-partial-block:not([open]) .fee-partial-content{display:none}

@media(max-width:760px){
  .vector-dashboard-card{min-height:auto!important;padding:18px!important;justify-content:flex-start!important}.vector-dashboard-icon{width:50px;height:50px;flex-basis:50px;border-radius:14px}.vector-dashboard-icon .ui-icon{width:24px;height:24px}
  .fee-partial-summary{align-items:flex-start}.fee-partial-summary-money{display:none}.fee-partial-content{padding:12px}
}
/* Iconografía vectorial consistente */
.stat-icon,.qicon,.benefit-icon,.ci-row .icon,.contact-action,.hero-pill,.action-card,.badge-soft,.result-meta .ok,.event-chip{display:inline-flex;align-items:center;gap:7px}
.stat-icon .ui-icon{width:21px;height:21px}.qicon .ui-icon{width:23px;height:23px}.benefit-icon .ui-icon{width:21px;height:21px}.ci-row .icon .ui-icon{width:18px;height:18px}.contact-action .ui-icon,.hero-pill .ui-icon,.badge-soft .ui-icon,.result-meta .ui-icon,.event-chip .ui-icon,.inline-icon{width:15px;height:15px}.action-card>.ui-icon{width:24px;height:24px}.record-circle .ui-icon{width:25px;height:25px}.voice-action .ui-icon,.icon-btn .ui-icon{width:16px;height:16px}.list-avatar .ui-icon,.case-icon .ui-icon{width:20px;height:20px}
.support-vector-illustration{width:100%;display:grid;place-items:center}.support-vector-illustration svg{display:block;width:100%;height:auto;max-height:360px}
