/* Identidad premium DOMO + EQUO by NAG. Cargada al final por branding.js. */
:root {
  --brand-primary: #304274;
  --brand-accent: #D3B873;
  --brand-neutral: #DBDBDB;
  --brand-ink: #07111F;
  --brand-navy: #0D1B31;
  --brand-white: #F8FAFF;
  --domo-login-plate: rgba(247, 249, 253, 0.92);
  --nav-text: rgba(255, 255, 255, 0.78);
  --nav-text-hover: #FFFFFF;
  --nav-text-active: #FFFFFF;
  --nav-bg-hover: rgba(255, 255, 255, 0.055);
  --nav-bg-active: rgba(30, 105, 170, 0.30);
  --nav-border-active: rgba(80, 170, 225, 0.32);
}

html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body:has(.auth-layout) { height: auto; min-height: 100vh; overflow: auto; }

/* ── Lockup base ───────────────────────────────────────────────────────── */
.brand-lockup,
.brand-lockup * { box-sizing: border-box; }
.brand-lockup__marks { display: grid; align-items: center; }
.brand-lockup__tenant,
.brand-lockup__product { display: flex; align-items: center; justify-content: center; min-width: 0; }
.brand-lockup__tenant-logo,
.brand-lockup__product-logo {
  display: block;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  filter: none;
  opacity: 1;
}
.brand-lockup__tenant-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brand-lockup__tenant.has-client-logo:not(.is-logo-error) .brand-lockup__tenant-name { display: none; }
.brand-lockup__tenant.is-logo-error .brand-lockup__tenant-logo { display: none; }
.brand-lockup__tenant-monogram {
  display: none;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(211, 184, 115, 0.52);
  border-radius: 9px;
  color: #F6E7BC;
  background: rgba(48, 66, 116, 0.78);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
}
.brand-lockup__tenant:not(.has-client-logo) .brand-lockup__tenant-monogram,
.brand-lockup__tenant.is-logo-error .brand-lockup__tenant-monogram { display: flex; }
.brand-lockup__separator {
  display: block;
  width: 1px;
  height: 32px;
  flex: 0 0 1px;
  background: linear-gradient(180deg, transparent, rgba(211, 184, 115, 0.78), transparent);
}

/* ── Login ─────────────────────────────────────────────────────────────── */
.auth-layout { grid-template-columns: minmax(0, 1fr) minmax(420px, 1fr); min-height: 100vh; }
.auth-brand {
  position: relative;
  display: flex !important;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: clamp(32px, 5vw, 76px);
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 42%, rgba(211, 184, 115, 0.13), transparent 28%),
    radial-gradient(circle at 18% 10%, rgba(47, 104, 190, 0.18), transparent 34%),
    linear-gradient(148deg, #12264A 0%, #0B1930 55%, #07111F 100%) !important;
}
.auth-brand::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.024) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.024) 1px, transparent 1px);
  background-size: 32px 32px;
  -webkit-mask-image: radial-gradient(circle at center, #000 12%, transparent 72%);
  mask-image: radial-gradient(circle at center, #000 12%, transparent 72%);
  pointer-events: none;
}
.auth-brand::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(94%, 728px, calc(100dvh - 80px));
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border: 1px solid rgba(211, 184, 115, 0.06);
  border-radius: 50%;
  box-shadow: 0 0 90px rgba(211, 184, 115, 0.035);
  pointer-events: none;
}
.auth-brand-content { position: relative; z-index: 1; width: 100%; max-width: 660px; text-align: center; }
.brand-lockup--login { width: 100%; max-width: 470px; margin: 0 auto; text-align: center; }
.brand-login__client {
  display: grid;
  min-height: 174px;
  place-items: center;
  padding: clamp(16px, 2.4vw, 28px);
}
.brand-login__client-logo {
  display: block;
  width: min(350px, 82%);
  max-height: 262px;
  object-fit: contain;
  filter: drop-shadow(0 16px 30px rgba(0, 7, 19, 0.28));
}
.brand-login__descriptor {
  margin: clamp(16px, 2vw, 24px) auto 0;
  color: rgba(246, 248, 253, 0.9);
  font-size: clamp(16px, 1.35vw, 20px);
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.35;
  text-wrap: balance;
}
.brand-login__technology {
  display: grid;
  justify-items: center;
  gap: 8px;
  width: min(300px, 62%);
  margin: 30px auto 0;
  padding-top: 17px;
  border-top: 1px solid rgba(211, 184, 115, 0.38);
}
.brand-login__technology-label {
  color: rgba(235, 239, 248, 0.58);
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.12em;
  line-height: 1.2;
  text-transform: uppercase;
}
.brand-login__technology-logo {
  display: block;
  width: min(291px, 100%);
  max-height: 194px;
  object-fit: contain;
  opacity: 0.9;
}

.auth-form-side {
  min-width: 0;
  padding: clamp(32px, 5vw, 74px);
  color: var(--color-text);
  background:
    radial-gradient(circle at 82% 16%, rgba(48, 66, 116, 0.16), transparent 28%),
    linear-gradient(160deg, #091525 0%, #07101D 100%) !important;
  border-left: 1px solid rgba(211, 184, 115, 0.12);
}
.auth-form-container { width: 100%; max-width: 420px; }
.auth-form-header { margin-bottom: 30px; }
.auth-title { margin-bottom: 8px; font-size: clamp(28px, 2.4vw, 34px); line-height: 1.1; text-wrap: balance; }
.auth-subtitle { color: var(--color-text-muted); font-size: 14px; }
.auth-form { gap: 17px; }
.auth-form .form-label { margin-bottom: 7px; color: rgba(235, 239, 248, 0.76); font-size: 11px; letter-spacing: 0.045em; text-transform: uppercase; }
.auth-form .form-input {
  min-height: 44px;
  border-color: rgba(137, 155, 187, 0.22);
  background: rgba(4, 12, 23, 0.58);
  transition-property: border-color, box-shadow, background-color;
  transition-duration: 150ms;
  transition-timing-function: ease-out;
}
.auth-form .form-input:hover { border-color: rgba(211, 184, 115, 0.32); }
.auth-form .form-input:focus {
  border-color: rgba(211, 184, 115, 0.74);
  background: rgba(7, 17, 31, 0.9);
  box-shadow: 0 0 0 3px rgba(211, 184, 115, 0.1);
  outline: none;
}
.auth-form .btn { min-height: 44px; border-radius: 10px; transition-property: transform, background-color, border-color, box-shadow; transition-duration: 150ms; transition-timing-function: ease-out; }
.auth-form .btn:active:not(:disabled) { transform: scale(0.985); }
.auth-form .btn-primary { box-shadow: 0 10px 26px rgba(25, 52, 101, 0.28); }
.oauth-actions { display: grid; gap: 10px; margin-bottom: 2px; }
.oauth-actions .btn { border-color: rgba(137, 155, 187, 0.24); background: rgba(255, 255, 255, 0.035); }
.oauth-actions .btn:hover { border-color: rgba(211, 184, 115, 0.42); background: rgba(255, 255, 255, 0.065); }
.auth-divider { color: var(--color-text-subtle); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; }
.auth-options a,
.auth-link a { color: #D9C68F; }
.auth-options a:focus-visible,
.auth-link a:focus-visible { border-radius: 4px; outline: 2px solid #D3B873; outline-offset: 3px; }

/* ── Topbar ────────────────────────────────────────────────────────────── */
.topbar { min-width: 0; max-width: 100%; }
.topbar-brand { display: flex; align-items: center; gap: 10px; flex: 0 1 auto; min-width: 0; }
.topbar-nav,
.topbar-search { min-width: 0; }
.topbar-nav { overflow: hidden; }
.topbar-actions { flex: 0 0 auto; }
.brand-lockup--topbar { display: flex; align-items: center; min-width: 0; }
.brand-lockup--topbar .client-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 64px;
  flex: 0 0 76px;
  padding: 8px;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  transition-property: border-color, box-shadow, transform;
  transition-duration: 150ms;
  transition-timing-function: ease-out;
}
.brand-lockup--topbar .client-brand:hover { border-color: transparent; box-shadow: none; }
.brand-lockup--topbar .client-brand:active { transform: scale(0.97); }
.brand-lockup--topbar .client-brand:focus-visible { outline: 2px solid #D3B873; outline-offset: 2px; }
.brand-lockup--topbar .brand-lockup__tenant-logo {
  width: auto;
  height: auto;
  max-width: 60px;
  max-height: 48px;
  border-radius: 0;
  object-fit: contain;
}
.brand-lockup--topbar .brand-lockup__tenant-name { max-width: 110px; font-size: 11px; }
.brand-lockup--topbar .brand-lockup__separator { height: 24px; }
.topbar-logo-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  flex: 0 0 58px;
  min-width: 0 !important;
  height: 42px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(211, 184, 115, 0.17);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045);
  transition-property: border-color, background-color, transform;
  transition-duration: 150ms;
  transition-timing-function: ease-out;
}
.topbar-logo-link::after { content: none !important; }
.topbar-logo-link:hover { border-color: rgba(211, 184, 115, 0.34); background: rgba(255, 255, 255, 0.06); }
.topbar-logo-link:active { transform: scale(0.97); }
.topbar-logo-link:focus-visible { outline: 2px solid #D3B873; outline-offset: 1px; }
.topbar-logo {
  width: 56px !important;
  height: 42px !important;
  object-fit: contain !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  filter: none !important;
  opacity: 1 !important;
}
.topbar-nav-item {
  color: var(--nav-text) !important;
  opacity: 1 !important;
}
.topbar-nav-item svg { color: currentColor; stroke: currentColor; fill: none; opacity: 0.82; }
.topbar-nav-item:hover { background: var(--nav-bg-hover) !important; color: var(--nav-text-hover) !important; }
.topbar-nav-item:hover svg { opacity: 1; }
.topbar-nav-item.active,
.topbar-nav-item.is-active,
.topbar-nav-item[aria-current="page"] {
  background: var(--nav-bg-active) !important;
  border: 1px solid var(--nav-border-active);
  color: var(--nav-text-active) !important;
  font-weight: 600;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
  opacity: 1 !important;
}
.topbar-nav-item.active svg,
.topbar-nav-item.is-active svg,
.topbar-nav-item[aria-current="page"] svg { color: var(--nav-text-active); stroke: currentColor; opacity: 1; }
.topbar-nav-item:focus-visible { outline: 2px solid #D3B873; outline-offset: 2px; color: var(--nav-text-hover) !important; }
.tb-provider-note { padding: 8px 16px 10px; color: var(--color-text-subtle); font-size: 10px; line-height: 1.35; }

/* ── Splash ────────────────────────────────────────────────────────────── */
.brand-splash {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px),
    radial-gradient(circle at center, rgba(211, 184, 115, 0.14), transparent 30%),
    linear-gradient(145deg, #102141, #07111F 68%);
  background-size: 32px 32px, 32px 32px, auto, auto;
  opacity: 0;
  transition-property: opacity;
  transition-duration: 160ms;
  transition-timing-function: ease-out;
}
.brand-splash.is-visible { opacity: 1; }
.brand-splash__content { width: min(620px, 92vw); text-align: center; }
.brand-lockup--splash { position: relative; display: grid; place-items: center; isolation: isolate; }
.brand-lockup--splash::before {
  content: '';
  position: absolute;
  z-index: -1;
  width: min(360px, 86vw);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(211,184,115,0.27), rgba(211,184,115,0.07) 35%, transparent 68%);
  animation: domo-splash-halo 3s ease-in-out both;
}
.brand-lockup--splash::after {
  content: '';
  position: absolute;
  inset: 16% -8%;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(105deg, transparent 34%, rgba(255,255,255,0.42) 49%, transparent 64%);
  mix-blend-mode: screen;
  opacity: 0;
  transform: translateX(-115%);
  animation: domo-splash-sweep 3s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.brand-splash__logo {
  display: block;
  width: min(360px, 78vw);
  height: auto;
  margin: 0 auto;
  object-fit: contain;
  filter: drop-shadow(0 18px 34px rgba(0, 6, 17, 0.34));
  animation: domo-splash-logo 3s cubic-bezier(0.16, 1, 0.3, 1) both;
}
@keyframes domo-splash-logo {
  0% { opacity: 0; transform: translateY(8px) scale(0.9); }
  15% { opacity: 1; transform: translateY(0) scale(1.02); }
  40% { opacity: 1; transform: translateY(0) scale(1); }
  70% { opacity: 1; transform: translateY(0) scale(1.025); }
  88% { opacity: 1; transform: translateY(0) scale(1); }
  100% { opacity: 0; transform: translateY(0) scale(1.03); filter: blur(2px) drop-shadow(0 18px 34px rgba(0, 6, 17, 0.34)); }
}
@keyframes domo-splash-halo {
  0%, 15% { opacity: 0; transform: scale(0.82); }
  40% { opacity: 0.72; transform: scale(1); }
  70% { opacity: 0.88; transform: scale(1.05); }
  88% { opacity: 0.45; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.08); }
}
@keyframes domo-splash-sweep {
  0%, 40% { opacity: 0; transform: translateX(-115%); }
  42% { opacity: 0.5; }
  66% { opacity: 0.5; transform: translateX(115%); }
  68%, 100% { opacity: 0; transform: translateX(115%); }
}

/* ── Footer y superficies institucionales ─────────────────────────────── */
.footer-brandline { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin: 0; color: var(--color-text-subtle); font-size: 10px; line-height: 1.3; }
.footer-brandline strong { color: var(--color-text-muted); font-weight: 700; }
.brand-owner-line { margin: 10px auto 0; max-width: 28rem; color: var(--brand-primary); font-size: 12px; font-weight: 600; line-height: 1.45; letter-spacing: 0.025em; }
.brand-owner-line::before { content: ''; display: block; width: 34px; height: 1px; margin: 0 auto 9px; border-radius: 999px; background: var(--brand-accent); }
.auth-brand .brand-owner-line { color: #F4E7C4; }
.auth-brand-logo { width: min(320px, 76%) !important; height: auto !important; max-height: 220px; margin: 0 auto 8px !important; object-fit: contain !important; filter: none !important; box-shadow: none !important; }
.auth-inline-logo { display: block; width: min(280px, 86%); height: auto; margin: 0 auto 4px; object-fit: contain; }
.auth-public-card .brand-owner-line { margin-bottom: 28px; }
.invite-left-logo { display: block; width: min(320px, 84%); height: auto; margin: 0 auto 8px; object-fit: contain; }

/* ── Acerca de DOMO ───────────────────────────────────────────────────── */
.brand-about { position: fixed; inset: auto; top: 50%; left: 50%; width: min(520px, calc(100% - 32px)); max-height: min(680px, calc(100dvh - 32px)); margin: 0; padding: 0; overflow: auto; transform: translate(-50%, -50%); color: var(--color-text); background: var(--color-surface-raised); border: 1px solid var(--color-border-strong); border-radius: var(--radius-xl); box-shadow: var(--shadow-xl); }
.brand-about::backdrop { background: rgba(3, 8, 18, 0.74); backdrop-filter: blur(5px); }
.brand-about__header { display: flex; align-items: center; justify-content: space-between; min-height: 76px; padding: 10px 18px; border-bottom: 1px solid var(--color-border); background: linear-gradient(120deg, rgba(48, 66, 116, 0.22), rgba(211, 184, 115, 0.08)); }
.brand-about__header img { width: 132px; height: 62px; object-fit: contain; }
.brand-about__close { width: 40px; height: 40px; color: var(--color-text-muted); background: transparent; border: 0; border-radius: var(--radius-md); font-size: 24px; cursor: pointer; }
.brand-about__close:hover,
.brand-about__close:focus-visible { color: var(--color-text); background: var(--color-surface-alt); outline: 2px solid #D3B873; }
.brand-about__body { padding: 24px; }
.brand-about__body h2 { margin: 0 0 8px; font-size: var(--text-2xl); text-wrap: balance; }
.brand-about__body p { color: var(--color-text-muted); line-height: 1.6; text-wrap: pretty; }
.brand-about__lead { color: var(--color-text) !important; font-weight: 600; }
.brand-about__body dl { margin: 20px 0; }
.brand-about__body dl div { display: grid; grid-template-columns: 140px 1fr; gap: 12px; padding: 8px 0; border-top: 1px solid var(--color-border); }
.brand-about__body dt { color: var(--color-text-subtle); font-size: var(--text-xs); }
.brand-about__body dd { margin: 0; color: var(--color-text-muted); font-size: var(--text-sm); overflow-wrap: anywhere; }
.brand-about__body nav { display: flex; flex-wrap: wrap; gap: 16px; }
.brand-about__body a { color: #D3B873; }

/* ── Responsive ───────────────────────────────────────────────────────── */
@media (max-width: 1450px) { .topbar-search { display: none; } }
@media (max-width: 1180px) {
  .topbar { padding-inline: 12px; gap: 8px; }
  .topbar-brand { gap: 8px; }
  .topbar-logo-link { width: 58px; flex-basis: 58px; }
  .topbar-logo { width: 56px !important; }
  .topbar-nav { margin-left: 0; gap: 2px; }
}
@media (max-width: 900px) {
  .auth-layout { grid-template-columns: minmax(0, 1fr); }
  .auth-brand { min-height: 318px; padding: 34px 24px; }
  .auth-form-side { padding: 44px 24px 58px; border-top: 1px solid rgba(211, 184, 115, 0.12); border-left: 0; }
  .brand-login__client { min-height: 142px; padding-block: 12px; }
  .brand-login__client-logo { width: min(294px, 78%); max-height: 221px; }
  .brand-login__technology { margin-top: 22px; }
}
@media (max-width: 767px) {
  .brand-lockup--topbar { gap: 6px; }
  .brand-lockup--topbar .client-brand { width: 52px; height: 44px; flex-basis: 52px; padding: 6px; border-radius: 0; }
  .brand-lockup--topbar .brand-lockup__tenant-logo { width: auto; height: auto; max-width: 40px; max-height: 32px; border-radius: 0; object-fit: contain; }
  .brand-lockup--topbar .brand-lockup__separator { height: 23px; }
  .topbar-logo-link { width: 40px; height: 34px; flex-basis: 40px; padding: 0; }
  .topbar-logo { width: 40px !important; height: 34px !important; }
  .oauth-actions .btn { min-height: 46px; height: auto; white-space: normal; line-height: 1.35; }
}
@media (max-width: 520px) {
  .auth-brand { min-height: 316px; padding: 26px 18px; }
  .auth-form-side { padding: 36px 16px 52px; }
  .brand-login__client { min-height: 110px; padding: 4px 12px; }
  .brand-login__client-logo { width: min(230px, 74vw); max-height: 173px; }
  .brand-login__descriptor { margin-top: 13px; font-size: 15px; }
  .brand-login__technology { width: 140px; gap: 6px; margin-top: 16px; padding-top: 11px; }
  .brand-login__technology-logo { width: 98px; max-height: 34px; }
  .brand-splash__logo { width: min(300px, 82vw); }
  .brand-about__body dl div { grid-template-columns: 1fr; gap: 3px; }
}
@media (max-width: 390px) {
  .topbar-brand { gap: 5px; }
  .brand-lockup--topbar .client-brand { width: 44px; height: 40px; flex-basis: 44px; padding: 5px; }
  .brand-lockup--topbar .brand-lockup__tenant-logo { width: auto; height: auto; max-width: 34px; max-height: 28px; }
  .topbar-logo-link { width: 34px; height: 34px; flex-basis: 34px; }
  .topbar-logo { width: 34px !important; height: 34px !important; }
}
@media (prefers-reduced-motion: reduce) {
  .brand-splash,
  .brand-splash__logo,
  .brand-lockup--splash::before,
  .brand-lockup--splash::after,
  .auth-form .btn,
  .brand-lockup--topbar .client-brand,
  .topbar-logo-link { animation: none; transition: none; }
}
