/* =========================================================
THE ABC V18.22 — Portal Auth + Global Surface Role Lock
Scop: portal client / portal partener / portal administrator folosesc aceeasi suprafata ca index/flow/dashboard.
Regula: vizitator/client/partener vad UI standard; administratorul vede acelasi UI + tehnic in modulele admin-only.
========================================================= */
:root{
  --abc-surface-max: min(100vw, 100%);
  --abc-shell-pad-x: clamp(10px, 1.4vw, 18px);
  --abc-shell-pad-y: clamp(8px, 1.1vh, 14px);
  --abc-auth-client: rgba(245, 184, 0, .72);
  --abc-auth-partner: rgba(158, 90, 255, .72);
  --abc-auth-admin: rgba(65, 210, 120, .72);
  --abc-panel-bg: rgba(12,16,24,.92);
}
html,body{max-width:100%;overflow-x:hidden!important;}
body:not([data-user-type="admin"]):not([data-user-role="admin"]){min-height:100dvh;}
body[data-page="index"] .page-shell,
body[data-page="auth_login"] .page-shell,
body[data-page="auth_notice"] .page-shell,
body[data-page="client_dashboard"] .page-shell,
body[data-page="partner_dashboard"] .page-shell,
body[data-page="private_client_account"] .page-shell,
body[data-page="private_partner_account"] .page-shell,
body[data-page="business_client_account"] .page-shell,
body[data-page="business_partner_account"] .page-shell,
.page-shell.compact-page{
  width:100%!important;
  max-width:none!important;
  min-height:100dvh;
  margin:0!important;
  padding:var(--abc-shell-pad-y) var(--abc-shell-pad-x)!important;
  box-sizing:border-box!important;
}
body[data-page="auth_login"],
body[data-page="auth_notice"],
body.auth-shell-page{
  background: radial-gradient(circle at top left, rgba(255,255,255,.045), transparent 34%), #070b12!important;
}
body[data-page="auth_login"] .abc-stack,
body[data-page="auth_notice"] .abc-stack,
.abc-auth-stack-v18-22{
  width:100%!important;
  max-width:none!important;
  flex:1 1 auto!important;
  display:flex!important;
  align-items:stretch!important;
  justify-content:center!important;
  margin:0!important;
  padding:0!important;
  box-sizing:border-box!important;
}
body[data-page="auth_login"] .auth-content-panel,
body[data-page="auth_notice"] .auth-content-panel,
.abc-auth-content-panel-v18-22{
  width:100%!important;
  max-width:none!important;
  min-height:0!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:clamp(10px, 1.6vw, 20px)!important;
  margin:0!important;
  overflow:hidden!important;
  border:1px solid rgba(255,255,255,.10)!important;
  background:linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.018))!important;
  box-shadow:none!important;
}
body[data-page="auth_login"] .auth-card,
body[data-page="auth_notice"] .auth-card,
.auth-panel-card{
  width:min(760px, 100%)!important;
  max-width:760px!important;
  margin:0 auto!important;
  padding:clamp(14px, 2vw, 22px)!important;
  box-sizing:border-box!important;
  border-width:1px!important;
  border-style:solid!important;
  border-color:rgba(255,255,255,.16)!important;
  border-radius:18px!important;
  background:var(--abc-panel-bg)!important;
  box-shadow:0 14px 34px rgba(0,0,0,.22)!important;
  transform:none!important;
  left:auto!important;right:auto!important;top:auto!important;
}
body[data-auth-panel-family="client"] .auth-card,
body.auth-panel-family-client .auth-card{border-color:var(--abc-auth-client)!important;}
body[data-auth-panel-family="partner"] .auth-card,
body.auth-panel-family-partner .auth-card{border-color:var(--abc-auth-partner)!important;}
body[data-auth-panel-family="admin"] .auth-card,
body.auth-panel-family-admin .auth-card{border-color:var(--abc-auth-admin)!important;}
body[data-page="auth_login"] .auth-card::before,
body[data-page="auth_login"] .auth-card::after,
body[data-page="auth_notice"] .auth-card::before,
body[data-page="auth_notice"] .auth-card::after,
body[data-page="auth_login"] .auth-content-panel::before,
body[data-page="auth_login"] .auth-content-panel::after,
body[data-page="auth_notice"] .auth-content-panel::before,
body[data-page="auth_notice"] .auth-content-panel::after{
  display:none!important;
  content:none!important;
}
body[data-page="auth_login"] .auth-dashboard-panel__title,
body[data-page="auth_notice"] .auth-dashboard-panel__title{
  font-size:clamp(1.25rem, 2.1vw, 2rem)!important;
  line-height:1.08!important;
  margin:0!important;
  letter-spacing:-.02em!important;
}
body[data-page="auth_login"] .auth-panel-badge,
body[data-page="auth_notice"] .auth-panel-badge{
  display:inline-flex!important;
  width:max-content!important;
  font-size:.78rem!important;
  letter-spacing:.03em!important;
  padding:.38rem .62rem!important;
  border:1px solid rgba(255,255,255,.18)!important;
  border-radius:999px!important;
  background:rgba(255,255,255,.07)!important;
  color:rgba(255,255,255,.88)!important;
}
body[data-page="auth_login"] .auth-form,
body[data-page="auth_notice"] .auth-form{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:clamp(10px, 1.25vw, 14px)!important;
  width:100%!important;
  margin-top:clamp(12px,1.5vw,18px)!important;
}
body[data-page="auth_login"] .auth-actions,
body[data-page="auth_notice"] .auth-actions{
  grid-column:1 / -1!important;
  display:grid!important;
  grid-template-columns:1fr auto 1fr!important;
  align-items:center!important;
  gap:10px!important;
  width:100%!important;
}
body[data-page="auth_login"] .auth-actions-right,
body[data-page="auth_notice"] .auth-actions-right{text-align:right!important;}
body[data-page="auth_login"] .button,
body[data-page="auth_notice"] .button{white-space:nowrap!important;}
/* rosu legacy interzis doar pe portal auth/shell; emergency flow ramane neatins */
body[data-page="auth_login"] .auth-content-panel,
body[data-page="auth_login"] .auth-card,
body[data-page="auth_notice"] .auth-content-panel,
body[data-page="auth_notice"] .auth-card{
  outline:0!important;
}
body[data-page="auth_login"] [style*="red"],
body[data-page="auth_notice"] [style*="red"],
body[data-page="auth_login"] [style*="#f"],
body[data-page="auth_notice"] [style*="#f"]{
  box-shadow:none!important;
}
/* client/partener real: fara bara tehnica peste My Profile */
body[data-page="client_dashboard"]:not([data-admin-debug-ui="true"]) .abc-dashboard-access-module-v10,
body[data-page="partner_dashboard"]:not([data-admin-debug-ui="true"]) .abc-dashboard-access-module-v10{
  display:none!important;
}
body[data-page="client_dashboard"] .client_dashboard-stack,
body[data-page="partner_dashboard"] .partner_dashboard-stack,
body[data-page="client_dashboard"] .content-engine-panel,
body[data-page="partner_dashboard"] .content-engine-panel{
  width:100%!important;
  max-width:none!important;
  margin-left:0!important;
  margin-right:0!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
}
body[data-page="index"] .abc-public-global-box,
body[data-page="index"] .abc-index-flow-module-v10,
body[data-page="index"] .abc-home-six-grid{
  width:100%!important;
  max-width:none!important;
  box-sizing:border-box!important;
}
body[data-page="index"] .abc-home-six-grid{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:clamp(10px,1.2vw,16px)!important;
}
body[data-page="index"] .home-route-card{border-width:1px!important;}
@media (max-width: 780px){
  .page-shell.compact-page{padding:8px!important;}
  body[data-page="auth_login"] .auth-content-panel,
  body[data-page="auth_notice"] .auth-content-panel{align-items:flex-start!important;padding:10px!important;overflow:auto!important;}
  body[data-page="auth_login"] .auth-card,
  body[data-page="auth_notice"] .auth-card{width:100%!important;max-width:100%!important;padding:14px!important;border-radius:16px!important;}
  body[data-page="auth_login"] .auth-form,
  body[data-page="auth_notice"] .auth-form{grid-template-columns:1fr!important;}
  body[data-page="auth_login"] .auth-actions,
  body[data-page="auth_notice"] .auth-actions{grid-template-columns:1fr!important;text-align:stretch!important;}
  body[data-page="auth_login"] .auth-actions-right,
  body[data-page="auth_notice"] .auth-actions-right{text-align:stretch!important;}
  body[data-page="auth_login"] .auth-actions .button,
  body[data-page="auth_notice"] .auth-actions .button{width:100%!important;justify-content:center!important;}
  body[data-page="index"] .abc-home-six-grid{grid-template-columns:1fr!important;}
}
