/* Alongside account / auth — site-wide */
:root {
  --al-blue: #1B4FD8;
  --al-cream: #FDF8EE;
  --al-blue-dark: #1340b0;
  --al-text: #1a1a1a;
  --al-font: 'Instrument Serif', Georgia, 'Times New Roman', serif;
}

.al-account {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.al-account-btn {
  width: auto;
  height: auto;
  min-width: 28px;
  min-height: 28px;
  border-radius: 0;
  border: none;
  background: transparent;
  color: var(--al-text);
  opacity: 0.55;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.2s, opacity 0.2s;
  padding: 4px;
}

.al-account-btn:hover,
.al-account-btn[aria-expanded="true"] {
  background: transparent;
  border: none;
  color: var(--al-blue);
  opacity: 1;
}

.al-account-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 220px;
  max-width: 280px;
  background: var(--al-cream);
  border: 1.5px solid rgba(27, 79, 216, 0.18);
  border-radius: 14px;
  padding: 6px;
  box-shadow: 0 12px 32px rgba(26, 26, 26, 0.1);
  z-index: 950;
}

.al-account-menu[hidden] {
  display: none !important;
}

.al-account-menu-note {
  padding: 8px 12px 2px;
  font-family: var(--al-font);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--al-blue);
  cursor: default;
}

.al-account-menu-hint {
  margin: 0 0 4px;
  padding: 0 12px 8px;
  font-family: var(--al-font);
  font-size: 12px;
  line-height: 1.35;
  color: rgba(26, 26, 26, 0.55);
  cursor: default;
  border-bottom: 1px solid rgba(27, 79, 216, 0.1);
}

.al-account-menu-item {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  border-radius: 10px;
  padding: 10px 12px;
  font-family: var(--al-font);
  font-size: 16px;
  color: var(--al-text);
  cursor: pointer;
}

.al-account-menu-item:hover {
  background: rgba(27, 79, 216, 0.08);
  color: var(--al-blue);
}

.al-account-menu-item.al-danger:hover {
  background: rgba(180, 40, 40, 0.08);
  color: #a32020;
}

#al-auth-overlay {
  position: fixed;
  inset: 0;
  background: rgba(27, 79, 216, 0.38);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 1100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

#al-auth-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.al-auth-modal {
  background: var(--al-cream);
  width: 100%;
  max-width: 400px;
  border-radius: 16px;
  padding: 40px 32px 28px;
  position: relative;
  transform: translateY(12px);
  transition: transform 0.25s ease;
}

#al-auth-overlay.visible .al-auth-modal {
  transform: translateY(0);
}

.al-auth-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  font-family: var(--al-font);
  font-size: 22px;
  color: var(--al-text);
  opacity: 0.35;
  cursor: pointer;
  line-height: 1;
}

.al-auth-close:hover {
  opacity: 0.75;
}

.al-auth-modal h2 {
  font-family: var(--al-font);
  font-size: 28px;
  font-weight: 400;
  color: var(--al-text);
  margin: 0 0 8px;
}

.al-auth-modal .al-auth-sub {
  font-family: var(--al-font);
  font-size: 15px;
  font-style: italic;
  opacity: 0.55;
  margin: 0 0 24px;
  line-height: 1.45;
}

.al-auth-gate,
.al-auth-traveler {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 4px;
}

.al-auth-gate[hidden],
.al-auth-traveler[hidden],
#al-auth-credentials[hidden] {
  display: none !important;
}

.al-auth-choice {
  width: 100%;
  padding: 13px 16px;
  border-radius: 999px;
  border: 1.5px solid rgba(27, 79, 216, 0.28);
  background: white;
  font-family: var(--al-font);
  font-size: 16px;
  color: var(--al-text);
  cursor: pointer;
}

.al-auth-choice:hover {
  border-color: var(--al-blue);
  color: var(--al-blue);
}

.al-auth-choice-primary {
  border: none;
  background: var(--al-blue);
  color: var(--al-cream);
}

.al-auth-choice-primary:hover {
  background: var(--al-blue-dark);
  color: var(--al-cream);
  border: none;
}

.al-auth-company-fields {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.al-auth-company-fields[hidden] {
  display: none !important;
}

.al-auth-company-fields input {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid rgba(27, 79, 216, 0.28);
  border-radius: 999px;
  font-family: var(--al-font);
  font-size: 16px;
  background: white;
  color: var(--al-text);
  outline: none;
}

.al-auth-company-fields input:focus {
  border-color: var(--al-blue);
}

.al-auth-company-hint {
  margin: 0 0 4px;
  font-family: var(--al-font);
  font-size: 13px;
  line-height: 1.4;
  opacity: 0.6;
}

.al-auth-google {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 999px;
  border: 1.5px solid rgba(27, 79, 216, 0.28);
  background: white;
  font-family: var(--al-font);
  font-size: 16px;
  color: var(--al-text);
  cursor: pointer;
  margin-bottom: 18px;
}

.al-auth-google:hover:not(:disabled) {
  border-color: var(--al-blue);
}

.al-auth-google:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.al-auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  font-family: var(--al-font);
  font-size: 13px;
  font-style: italic;
  opacity: 0.45;
}

.al-auth-divider::before,
.al-auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(26, 26, 26, 0.15);
}

.al-auth-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.al-auth-name-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.al-auth-name-row[hidden] {
  display: none !important;
}

@media (max-width: 420px) {
  .al-auth-name-row {
    grid-template-columns: 1fr;
  }
}

.al-auth-form input {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid rgba(27, 79, 216, 0.28);
  border-radius: 999px;
  font-family: var(--al-font);
  font-size: 16px;
  background: white;
  color: var(--al-text);
  outline: none;
}

.al-auth-form input:focus {
  border-color: var(--al-blue);
}

.al-auth-form button[type="submit"] {
  width: 100%;
  padding: 13px 16px;
  border: none;
  border-radius: 999px;
  background: var(--al-blue);
  color: var(--al-cream);
  font-family: var(--al-font);
  font-size: 16px;
  cursor: pointer;
  margin-top: 4px;
}

.al-auth-form button[type="submit"]:hover {
  background: var(--al-blue-dark);
}

.al-auth-form button[type="submit"]:disabled {
  opacity: 0.55;
  cursor: wait;
}

.al-auth-error {
  display: none;
  margin-top: 12px;
  font-family: var(--al-font);
  font-size: 14px;
  color: #a32020;
}

.al-auth-error.visible {
  display: block;
}

.al-auth-switch {
  margin-top: 18px;
  text-align: center;
  font-family: var(--al-font);
  font-size: 14px;
  opacity: 0.65;
}

.al-auth-switch button {
  background: none;
  border: none;
  color: var(--al-blue);
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
}
