/* GCE Field — desktop login (mockup) */
body.gce-login-active {
  font-family: Inter, "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #1e293b !important;
  background: #f8fafc !important;
}

body.gce-login-active .gce-auth-overlay {
  color: #1e293b !important;
}

.gce-auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  overflow: hidden;
  color: #1e293b;
}

.gce-auth-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background-color: #f8fafc;
}

.gce-auth-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 62% center;
  pointer-events: none;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

/* Monitoare > 4K: nu upscale peste 3840×2160 — tower rămâne la dimensiune naturală */
@media (min-width: 3841px), (min-height: 2161px) {
  .gce-auth-bg-img {
    inset: auto;
    left: 50%;
    top: 50%;
    width: min(100vw, 3840px);
    height: min(100dvh, 2160px);
    transform: translate(-50%, -50%);
    object-fit: cover;
    object-position: 62% center;
  }
}

.gce-auth-bg-shade {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(90deg, rgba(248, 250, 252, 0.94) 0%, rgba(248, 250, 252, 0.78) 26%, rgba(248, 250, 252, 0.34) 46%, rgba(248, 250, 252, 0.08) 58%, transparent 68%),
    linear-gradient(to top, rgba(15, 23, 42, 0.32) 0%, transparent 36%);
}

.gce-auth-layout {
  position: relative;
  z-index: 2;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(360px, 400px) minmax(240px, 1fr);
  align-items: center;
  gap: clamp(16px, 3vw, 48px);
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: 48px clamp(20px, 4vw, 56px) 28px;
}

.gce-auth-hero {
  position: relative;
  grid-column: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 40px;
  width: auto;
  max-width: 560px;
  min-height: min(580px, calc(100dvh - 200px));
  padding: 8px 0;
  z-index: 1;
  pointer-events: none;
}

.gce-auth-hero a,
.gce-auth-hero button {
  pointer-events: auto;
}

.gce-auth-hero-top {
  max-width: 580px;
}

.gce-auth-brand-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 32px;
}

.gce-auth-logo {
  display: grid;
  place-items: center;
  filter: drop-shadow(0 10px 28px rgba(124, 92, 255, 0.45));
}

.gce-auth-logo.gce-logo--custom {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  filter: drop-shadow(0 8px 20px rgba(15, 23, 42, 0.18));
}

.gce-auth-logo.gce-logo--custom img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.gce-auth-tower-svg {
  display: block;
  overflow: visible;
}

.gce-auth-brand-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1;
}

.gce-auth-brand-gce {
  font-size: 36px;
  font-weight: 900;
  letter-spacing: 0.06em;
  color: #1e293b;
}

.gce-auth-brand-field {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.32em;
  color: #8b5cf6;
  text-transform: uppercase;
}

.gce-auth-headline {
  margin: 0 0 14px;
  font-size: clamp(38px, 4.8vw, 54px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.03em;
  color: #1e293b;
}

.gce-auth-headline span {
  color: #8b5cf6;
}

.gce-auth-tagline {
  margin: 0;
  font-size: 17px;
  line-height: 1.55;
  color: #475569;
  max-width: 500px;
  font-weight: 500;
}

.gce-auth-features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin-top: auto;
  padding-top: 32px;
}

.gce-auth-feature {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.gce-auth-feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  flex: 0 0 44px;
  display: grid;
  place-items: center;
}

.gce-auth-feature-icon--secure {
  color: #7c3aed;
  background: #ede9fe;
  border: 1px solid #ddd6fe;
}

.gce-auth-feature-icon--smart {
  color: #2563eb;
  background: #dbeafe;
  border: 1px solid #bfdbfe;
}

.gce-auth-feature-icon--connected {
  color: #16a34a;
  background: #dcfce7;
  border: 1px solid #bbf7d0;
}

.gce-auth-feature b {
  display: block;
  font-size: 14px;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 4px;
}

.gce-auth-feature small {
  display: block;
  font-size: 12px;
  line-height: 1.45;
  color: #64748b;
  font-weight: 500;
}

.gce-auth-card {
  position: relative;
  z-index: 2;
  grid-column: 2;
  justify-self: center;
  width: min(400px, 92vw);
  max-width: 400px;
  margin-left: 0;
  border-radius: 20px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: #ffffff;
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.12), 0 4px 16px rgba(15, 23, 42, 0.06);
}

.gce-auth-form-panel {
  padding: 40px 40px 32px;
}

.gce-auth-form-head {
  margin-bottom: 28px;
}

.gce-auth-form-head h2 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 800;
  color: #1e293b;
  letter-spacing: -0.02em;
}

.gce-auth-form-head p {
  margin: 0;
  font-size: 14px;
  color: #64748b;
  font-weight: 500;
}

.gce-auth-field {
  display: block;
  margin-bottom: 18px;
}

.gce-auth-field > span {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 8px;
}

.gce-auth-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.gce-auth-input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
  display: flex;
}

.gce-auth-input-wrap input {
  width: 100%;
  padding: 13px 44px 13px 42px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #0f172a;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.gce-auth-input-wrap input:focus {
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

.gce-auth-input-wrap input::placeholder {
  color: #94a3b8;
}

.gce-auth-eye {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
}

.gce-auth-eye:hover {
  color: #64748b;
  background: #f8fafc;
}

.gce-auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 2px 0 20px;
  flex-wrap: wrap;
}

.gce-auth-remember {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
}

.gce-auth-remember input {
  width: 16px;
  height: 16px;
  accent-color: #8b5cf6;
  cursor: pointer;
}

.gce-auth-forgot {
  border: none;
  background: none;
  padding: 0;
  font-size: 13px;
  font-weight: 700;
  color: #8b5cf6;
  cursor: pointer;
  font-family: inherit;
}

.gce-auth-forgot:hover {
  color: #7c3aed;
  text-decoration: underline;
}

.gce-auth-error {
  color: #b91c1c;
  font-size: 13px;
  margin: 0 0 12px;
  font-weight: 700;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fef2f2;
  border: 1px solid #fecaca;
}

.gce-auth-submit {
  width: 100%;
  padding: 14px 16px;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  cursor: pointer;
  font-family: inherit;
  background: #8b5cf6;
  box-shadow: 0 10px 28px rgba(139, 92, 246, 0.35);
  transition: transform 0.12s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.gce-auth-submit:hover {
  background: #7c3aed;
  transform: translateY(-1px);
  box-shadow: 0 14px 32px rgba(139, 92, 246, 0.4);
}

.gce-auth-or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0 18px;
  color: #94a3b8;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.gce-auth-or::before,
.gce-auth-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e2e8f0;
}

.gce-auth-sso {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 16px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #334155;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.gce-auth-sso:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.gce-auth-help {
  margin: 20px 0 0;
  font-size: 13px;
  color: #64748b;
  text-align: center;
  font-weight: 500;
}

.gce-auth-help-link {
  border: none;
  background: none;
  padding: 0;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  color: #8b5cf6;
  cursor: pointer;
}

.gce-auth-help-link:hover {
  text-decoration: underline;
  color: #7c3aed;
}

.gce-auth-legal {
  margin: 16px 0 0;
  font-size: 12px;
  color: #64748b;
  text-align: center;
  font-weight: 500;
}

.gce-auth-legal a {
  color: #8b5cf6;
  text-decoration: none;
  font-weight: 600;
}

.gce-auth-legal a:hover {
  text-decoration: underline;
}

.gce-auth-legal-sep {
  opacity: 0.45;
  margin: 0 6px;
}

.gce-auth-footer {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  width: min(1200px, 92vw);
  margin: 0 auto;
  padding: 0 0 24px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.88);
  font-weight: 500;
  text-shadow: 0 1px 8px rgba(15, 23, 42, 0.35);
}

.gce-auth-footer > span:nth-child(2) {
  text-align: center;
}

.gce-auth-footer > span:last-child {
  text-align: right;
}

.gce-auth-footer-secure {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.9);
}

@media (min-width: 1800px) {
  .gce-auth-layout {
    max-width: 1720px;
  }
}

@media (max-width: 1200px) {
  .gce-auth-layout {
    grid-template-columns: minmax(240px, 1fr) minmax(340px, 400px);
    max-width: 100%;
  }
}

@media (max-width: 1024px) {
  .gce-auth-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 28px;
    padding-top: 32px;
    padding-bottom: 96px;
    justify-content: stretch;
    max-width: 100%;
  }

  .gce-auth-hero {
    grid-column: 1;
    width: auto;
    max-width: none;
    min-height: auto;
    gap: 32px;
    pointer-events: auto;
  }

  .gce-auth-card {
    grid-column: 1;
  }

  .gce-auth-bg-img {
    inset: 0;
    left: auto;
    top: auto;
    width: 100%;
    height: 100%;
    transform: none;
    object-position: 65% center;
  }

  .gce-auth-bg-shade {
    background-image:
      linear-gradient(180deg, rgba(248, 250, 252, 0.88) 0%, rgba(248, 250, 252, 0.5) 35%, rgba(248, 250, 252, 0.12) 65%, transparent 100%),
      linear-gradient(to top, rgba(15, 23, 42, 0.35) 0%, transparent 28%);
  }

  .gce-auth-features {
    grid-template-columns: 1fr;
    gap: 14px;
    padding-top: 8px;
  }

  .gce-auth-card {
    max-width: none;
    width: 100%;
    margin-left: 0;
  }

  .gce-auth-footer {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 8px;
  }

  .gce-auth-footer > span:last-child,
  .gce-auth-footer-secure {
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 640px) {
  .gce-auth-form-panel {
    padding: 28px 24px 24px;
  }

  .gce-auth-headline {
    font-size: 32px;
  }

  .gce-auth-brand-gce {
    font-size: 28px;
  }
}
