/*
 * dd-theme — auth-modal.css
 * Guest login / register modal (template-parts/auth-modal.php + auth-modal.js).
 * Backdrop + centred dialog + ARIA tabs, using the locked theme tokens.
 */

.dd-auth {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
}
.dd-auth.is-open {
  display: block;
}

.dd-auth__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 22, 34, 0.55);
  backdrop-filter: blur(2px);
}

.dd-auth__dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(440px, calc(100vw - 32px));
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  background: var(--paper);
  border: 1px solid var(--hair);
  border-radius: var(--radius);
  box-shadow: 0 24px 60px rgba(20, 22, 34, 0.28);
  padding: 32px 30px 30px;
}

.dd-auth__close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  border-radius: var(--radius-xs);
}
.dd-auth__close:hover {
  color: var(--ink-1);
  background: var(--cream);
}

.dd-auth__title {
  margin: 0 0 18px;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 26px;
  color: var(--ink-1);
}

.dd-auth__tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--hair);
}
.dd-auth__tab {
  flex: 1;
  padding: 12px 8px;
  border: 0;
  background: transparent;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 14px;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.dd-auth__tab:hover {
  color: var(--ink-1);
}
.dd-auth__tab.is-active {
  color: var(--terracotta);
  border-bottom-color: var(--terracotta);
}
.dd-auth__tab:focus-visible {
  outline: 2px solid var(--terracotta);
  outline-offset: 2px;
}

.dd-auth__panel .form-row,
.dd-auth__panel .woocommerce-form-row {
  margin: 0 0 14px;
}
.dd-auth__panel label {
  display: block;
  margin-bottom: 6px;
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
}
.dd-auth__panel input[type="text"],
.dd-auth__panel input[type="email"],
.dd-auth__panel input[type="password"] {
  width: 100%;
  padding: 11px 13px;
  font-family: var(--sans);
  font-size: 15px;
  color: var(--ink-1);
  background: var(--off-white);
  border: 1px solid var(--hair);
  border-radius: var(--radius-s);
}
.dd-auth__panel input:focus {
  outline: none;
  border-color: var(--terracotta);
}

.dd-auth__panel .woocommerce-form-login__rememberme,
.dd-auth__panel label.woocommerce-form__label-for-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  color: var(--muted);
}
.dd-auth__panel input[type="checkbox"] {
  width: auto;
}

.dd-auth__panel .button,
.dd-auth__panel button[type="submit"] {
  width: 100%;
  margin-top: 6px;
  padding: 12px 16px;
  justify-content: center;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 15px;
  color: var(--cream);
  background: var(--terracotta);
  border: 0;
  border-radius: var(--radius-s);
  cursor: pointer;
}
.dd-auth__panel .button:hover,
.dd-auth__panel button[type="submit"]:hover {
  background: var(--terracotta-deep);
}

.dd-auth__panel .lost_password,
.dd-auth__panel .woocommerce-LostPassword {
  margin: 14px 0 0;
  font-size: 13px;
}
.dd-auth__panel .lost_password a,
.dd-auth__panel .woocommerce-LostPassword a {
  color: var(--muted);
}
.dd-auth__panel .lost_password a:hover,
.dd-auth__panel .woocommerce-LostPassword a:hover {
  color: var(--terracotta);
}
