/* Shared auth card — used by /login.html, /tee-sheet/login.html, and homepage modal */

.auth-card {
  position: relative;
  background: var(--paper, var(--modal-bg, #fff));
  border: 1px solid var(--border, var(--modal-border, #e5e5e5));
  border-radius: 16px;
  padding: 32px 28px 28px;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 16px 48px rgba(15, 23, 42, 0.08);
  text-align: left;
}

/* Dark: lift off pure black page so the card is readable */
@media (prefers-color-scheme: dark) {
  .auth-card {
    background: var(--modal-bg, #2f2f2f);
    border-color: var(--modal-border, #444444);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
  }
}

.auth-card-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
}

.auth-card-brand img {
  width: 36px;
  height: 36px;
}

.auth-card-brand-text {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.auth-card-header {
  margin-bottom: 24px;
}

.auth-card-title {
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 0.5rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.auth-card-subtitle {
  color: var(--text-muted, var(--text-secondary));
  font-size: 0.925rem;
  line-height: 1.5;
  font-weight: 450;
  margin: 0;
}

/* Hidden GIS mount — needs real dimensions so GIS can render into it */
.auth-gis-mount,
#google-signin-button,
#google-signin-button-modal {
  position: absolute;
  visibility: hidden;
  width: 400px;
  height: 50px;
  overflow: hidden;
  pointer-events: none;
}

.auth-google-btn,
.google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: 100%;
  min-height: 48px;
  padding: 0 1rem;
  border: 1px solid #dadce0;
  border-radius: 10px;
  background: #ffffff;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: #1f1f1f;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  text-decoration: none;
}

.auth-google-btn:hover,
.google-btn:hover {
  background: #f8f9fa;
  border-color: #c6c6c6;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.auth-google-btn:active,
.google-btn:active {
  background: #f1f3f4;
}

.auth-google-btn:focus-visible,
.google-btn:focus-visible {
  outline: 2px solid #4285f4;
  outline-offset: 2px;
}

.auth-google-btn svg,
.google-btn svg {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
}

.auth-card-footer,
.modal-footer {
  margin-top: 18px;
  font-size: 0.8rem;
  color: var(--text-muted, var(--text-secondary));
  line-height: 1.5;
}

.auth-error,
.error-msg,
.login-error-msg {
  margin-top: 1rem;
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: none;
  color: var(--error-inline, var(--ps-error-inline, #c45555));
  font-size: 0.875rem;
  font-weight: 500;
  text-align: left;
  display: none;
  line-height: 1.45;
}

.auth-card-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 8px;
  font-size: 1.35rem;
  font-weight: 300;
  line-height: 1;
  color: var(--text-tertiary);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.auth-card-close:hover {
  background: var(--hover-bg);
  color: var(--text-primary);
}

.auth-card--dialog {
  padding-top: 36px;
}

.auth-card--dialog .auth-card-title {
  padding-right: 1.5rem;
}

@media (max-width: 520px) {
  .auth-card {
    padding: 26px 20px 22px;
    border-radius: 14px;
  }

  .auth-card--dialog {
    padding-top: 32px;
  }

  .auth-card-title {
    font-size: 1.45rem;
  }
}
