body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto',
    sans-serif;
  margin: 0;
  padding: 20px;
  background-color: #f5f5f5;
}
.group-container {
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
  justify-content: start;
  position: relative;
  box-sizing: border-box;
}
@media (min-width: 768px) {
  .group-container {
    width: 380px;
  }
}
h1 {
  margin-top: 0;
  color: #333;
}
.description {
  color: #666;
  margin-bottom: 30px;
  line-height: 1.6;
}
.flagsmith-status {
  padding: 12px 16px;
  border-radius: 6px;
  margin-bottom: 20px;
  font-size: 14px;
  display: none;
}
.flagsmith-status.show {
  display: block;
}
.flagsmith-status.loading {
  background-color: #e7f3ff;
  border: 1px solid #b3d9ff;
  color: #0066cc;
}
#flagsmith-status,
.flagsmith-status.loading {
  position: absolute !important; /* not fixed */
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  box-sizing: border-box !important;
}
.flagsmith-status.enabled {
  background-color: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}
.flagsmith-status.disabled {
  background-color: #fff3cd;
  border: 1px solid #ffeaa7;
  color: #856404;
}
.flagsmith-status.error {
  background-color: #f8d7da;
  border: 1px solid #f5c6cb;
  color: #721c24;
}
.flagsmith-status.timeout {
  background-color: #ffeaa7;
  border: 1px solid #fdcb6e;
  color: #856404;
}
#keycloak-create-account-wrapper {
  border: none;
  border-radius: 0;
  overflow: visible;
  min-height: 150px;
  position: relative;
}
#keycloak-create-account-wrapper iframe {
  border: none;
  border-radius: 0;
  overflow: hidden;
}
/* Email verification success message styles */
.email-verified-message {
  display: none;
  padding: 30px;
  text-align: center;
}

.email-verified-message.show {
  display: block;
}

.email-verified-message p {
  margin-bottom: 20px;
  font-size: 16px;
  color: #333;
}

.email-verified-message .login-button {
  display: inline-block;
  padding: 12px 24px;
  background-color: #007bff;
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-size: 16px;
  font-weight: 500;
  transition: background-color 0.2s;
}

.email-verified-message .login-button:hover {
  background-color: #0056b3;
}

/* Fallback message styles (when Flagsmith flag is disabled) */
.fallback-message {
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 30px;
  text-align: center;
  align-items: center;
  justify-content: center;
}

.fallback-message.show {
  display: flex;
}

.fallback-message p {
  margin: 0;
  font-size: 16px;
  color: #666;
  line-height: 1.6;
}

/* Loading state styles */
#keycloak-create-account-wrapper[data-loading='true']::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

#keycloak-create-account-wrapper[data-loading='true']::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 11;
  width: 40px;
  height: 40px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #007bff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}
