:root {
  --azuni-navy: #012342;
  --azuni-teal: #48b9bc;
  --azuni-teal-2: #51c7b8;
  --azuni-ink: #0b1320;
  --azuni-bg: #ffffff;
  --azuni-muted: #5c6678;
  --azuni-surface: #f6f8fb;
  --azuni-border: rgba(1, 35, 66, 0.14);

  --primary-color: var(--azuni-teal);
  --primary-dark: var(--azuni-navy);
  --secondary-color: var(--azuni-surface);
  --secondary-dark: rgba(1, 35, 66, 0.06);
  --third-color: var(--azuni-teal-2);
  --third-dark: var(--azuni-navy);
  --light-blue: var(--azuni-surface);
  --blue: var(--azuni-navy);
  --dark-blue: var(--azuni-navy);
  --white: var(--azuni-bg);
  --light-gray: var(--azuni-surface);
  --gray: var(--azuni-border);
  --dark-gray: var(--azuni-muted);
  --text-primary: var(--azuni-ink);
  --text-secondary: var(--azuni-muted);
  --success: var(--azuni-teal);
  --warning: var(--azuni-teal-2);
  --error: var(--azuni-navy);
  --radius: 4px;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.15);
  --gradient-brand: linear-gradient(135deg, var(--azuni-teal), var(--azuni-teal-2));
}

:where(*):not(:where(button, .btn, [role="button"])) {
  border-radius: var(--radius);
}

:where(button, .btn, [role="button"]):not(:focus-visible) {
  box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto',
    'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans',
    'Helvetica Neue', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: var(--white);
  color: var(--text-primary);
  line-height: 1.6;
}

.login-container {
  min-height: 100vh;
  display: flex;
  background: var(--white);
}

.left-panel {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  min-height: 100vh;
}

.right-panel {
  flex: 1;
  background-image: url('/logo_azuni.svg');
  background-repeat: no-repeat;
  background-position: left center;
  background-size: 70%;
  background-color: var(--white);
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-left: 20px;
}

.login-card {
  background: var(--white);
  border-radius: 4px;
  border: 1px solid var(--azuni-border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  padding: 40px;
  width: 100%;
  max-width: 400px;
  text-align: center;
}

.login-logo {
  margin-bottom: 32px;
}

.login-logo h1 {
  color: var(--azuni-navy);
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
  margin-top: 0;
}

.login-logo h1 .brand-word {
  color: var(--azuni-teal);
}

.login-logo h1 .brand-suffix {
  color: var(--azuni-navy);
}

.login-logo p {
  color: var(--text-secondary);
  font-size: 16px;
  margin: 0;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.input-group {
  position: relative;
}

#registerExtraFields .input-group + .input-group,
#doctorFields .input-group + .input-group {
  margin-top: 20px;
}

.input-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  z-index: 1;
  width: 16px;
  height: 16px;
}

.input-field {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--azuni-border);
  border-radius: 4px;
  font-size: 16px;
  color: var(--text-primary);
  background-color: var(--white) !important;
  transition: all 0.3s ease;
  font-family: inherit;
}

.input-group .input-field {
  padding-left: 48px;
}

.input-field:focus {
  outline: none;
  border-color: rgba(72, 185, 188, 0.7);
  box-shadow: 0 0 0 4px rgba(72, 185, 188, 0.22);
}

.input-field::placeholder {
  color: var(--text-secondary);
}

.password-toggle {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  cursor: pointer;
  z-index: 1;
  background: none;
  border: none;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

body[data-login-context] .password-toggle {
  box-shadow: none;
}

.password-toggle:hover {
  color: var(--primary-color);
}

.user-type-selector {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.user-type-btn {
  flex: 1;
  padding: 12px;
  border: 1px solid var(--azuni-border);
  background-color: transparent;
  color: var(--text-primary);
  border-radius: 34px;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s ease;
  cursor: pointer;
  font-family: inherit;
}

.user-type-btn:hover {
  border-color: rgba(72, 185, 188, 0.7);
  background-color: rgba(72, 185, 188, 0.14);
}

.user-type-btn.active {
  border-color: rgba(1, 35, 66, 0.06);
  background: var(--gradient-brand);
  color: #072130;
}

.user-type-btn.active:hover {
  background: var(--gradient-brand);
}

.error-message {
  color: var(--error);
  font-size: 14px;
  margin-top: 8px;
  text-align: left;
  display: none;
}

.success-message {
  color: var(--success);
  font-size: 14px;
  margin-top: 8px;
  text-align: center;
  display: none;
  padding: 12px;
  background: rgba(72, 185, 188, 0.08);
  border-radius: 4px;
  border: 1px solid rgba(72, 185, 188, 0.36);
}

.forgot-password {
  color: var(--azuni-navy);
  font-size: 14px;
  text-decoration: none;
  margin-top: 8px;
  display: inline-block;
  cursor: pointer;
}

.forgot-password:hover {
  text-decoration: underline;
}

.btn-primary {
  width: 100%;
  background: var(--gradient-brand);
  color: #072130;
  padding: 12px 24px;
  border-radius: 34px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary:hover {
  background: var(--gradient-brand);
  transform: translateY(-1px);
  box-shadow: var(--shadow-hover);
}

.btn-primary:disabled {
  background-color: var(--gray);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.toggle-mode {
  margin-top: 20px;
  text-align: center;
}

.toggle-mode p {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 8px;
  margin: 0;
}

.toggle-mode button {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: var(--azuni-navy);
  cursor: pointer;
  font-weight: 600;
  text-decoration: underline;
  box-shadow: none;
}

.toggle-mode button:hover {
  color: var(--primary-color);
}

@media (max-width: 768px) {
  .left-panel {
    flex: none;
    width: 100%;
  }

  .right-panel {
    display: none;
  }

  .btn-primary {
    padding: 14px 20px;
    font-size: 16px;
    min-height: 52px;
  }

  .input-field {
    padding: 14px 16px;
    font-size: 16px;
  }

  .login-card {
    padding: 20px;
    border-radius: 4px;
  }
}
