/* ── Account button (inside .top-nav) ─────────────────────────────────────── */

.account-btn {
  margin-left: auto; /* push to the right end of the nav row */
}

/* ── Dropdown (logged-in state) ────────────────────────────────────────────── */

.account-dropdown {
  position: absolute;
  z-index: 200;
  background: var(--card-bg, #fff);
  border: 1px solid var(--border, #e6e0dd);
  border-radius: var(--radius, 12px);
  box-shadow: var(--shadow-lg, 0 8px 24px rgba(0,0,0,.08));
  min-width: 160px;
  max-width: calc(100vw - 16px);
  overflow: hidden;
}

.dropdown-item {
  display: block;
  width: 100%;
  padding: 10px 16px;
  font: inherit;
  font-size: 13px;
  color: var(--text, #1a1a1a);
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.1s;
}

.dropdown-item:hover {
  background: var(--accent-light, #fde6e9);
  color: var(--accent, #c8102e);
}

/* ── Modal overlay ──────────────────────────────────────────────────────────── */

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fade-in 0.15s ease-out;
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-box {
  background: var(--card-bg, #fff);
  border-radius: var(--radius-lg, 18px);
  box-shadow: var(--shadow-lg, 0 8px 24px rgba(0,0,0,.12));
  padding: 24px;
  width: 100%;
  max-width: 380px;
  position: relative;
  animation: slide-up 0.18s ease-out;
}

@keyframes slide-up {
  from { transform: translateY(12px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: transparent;
  border: none;
  font-size: 22px;
  color: var(--text-soft, #6b6b6b);
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: color 0.1s;
}

.modal-close:hover { color: var(--text, #1a1a1a); }

.modal-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text, #1a1a1a);
  margin: 0 0 16px;
}

/* ── Tabs ──────────────────────────────────────────────────────────────────── */

.modal-tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--border, #e6e0dd);
  margin-bottom: 20px;
}

.modal-tab {
  flex: 1;
  padding: 8px 4px;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-soft, #6b6b6b);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  transition: color 0.12s, border-color 0.12s;
}

.modal-tab:hover {
  color: var(--accent, #c8102e);
}

.modal-tab.is-active {
  color: var(--accent, #c8102e);
  border-bottom-color: var(--accent, #c8102e);
  font-weight: 600;
}

/* ── Form elements ─────────────────────────────────────────────────────────── */

.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text, #1a1a1a);
  margin-bottom: 5px;
}

.form-group input {
  display: block;
  width: 100%;
  padding: 8px 12px;
  font: inherit;
  font-size: 14px;
  border: 1.5px solid var(--border, #e6e0dd);
  border-radius: var(--radius, 12px);
  background: var(--bg, #faf7f5);
  color: var(--text, #1a1a1a);
  outline: none;
  transition: border-color 0.12s;
  box-sizing: border-box;
}

.form-group input:focus {
  border-color: var(--accent, #c8102e);
}

.form-group input::placeholder {
  color: var(--text-soft, #6b6b6b);
  font-size: 13px;
}

.form-error {
  font-size: 13px;
  color: var(--error, #c8102e);
  background: var(--error-bg, #fde6e9);
  border-radius: 8px;
  padding: 7px 12px;
  margin-bottom: 12px;
}

.btn-primary {
  display: block;
  width: 100%;
  padding: 10px;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: var(--accent, #c8102e);
  border: none;
  border-radius: var(--radius, 12px);
  cursor: pointer;
  transition: opacity 0.12s, background 0.12s;
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent-dark, #8b0a1e);
}

.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
