/* public/auth-v2.css — Preview: Auth / Login page styles */

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  direction: rtl;
}

.auth-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: var(--space-10) var(--space-8);
  width: 100%;
  max-width: 380px;
  box-shadow: var(--shadow-lg);
}

.auth-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
  direction: ltr;
}

.auth-logo img {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.35));
}

.auth-logo-title {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  color: var(--text-primary);
}

.auth-tagline {
  text-align: center;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  margin-bottom: var(--space-8);
  line-height: var(--leading-loose);
}

.auth-card .form-input {
  margin-bottom: var(--space-3);
  direction: rtl;
}

.auth-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-top: var(--space-4);
}

#auth-status {
  margin-top: var(--space-4);
  font-size: var(--text-sm);
  color: var(--text-secondary);
  text-align: center;
  min-height: 1.2em;
}

/* Loading overlay — JS sets display:block, spinner centered via position */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-overlay);
  display: none;
  z-index: var(--z-overlay);
}
.loading-overlay .spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

/* ─── TOS Modal Extensions ──────────────────────────────────── */

.tos-modal-dialog {
  max-width: 520px;
}

/* TOS statement (Hebrew) */
.tos-statement {
  margin: 0 0 var(--space-4);
  padding: var(--space-3) var(--space-4);
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: var(--text-base);
  text-align: right;
  direction: rtl;
}

/* Toggle button (looks like a link) */
.tos-toggle-link {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-2) var(--space-4);
  margin-bottom: var(--space-4);
  background: none;
  border: none;
  color: var(--color-primary);
  font-size: var(--text-sm);
  cursor: pointer;
  text-align: right;
  direction: rtl;
  transition: color 0.2s ease;
}

.tos-toggle-link:hover {
  color: var(--color-primary-hover);
  text-decoration: underline;
}

.tos-toggle-link:active {
  transform: scale(0.98);
}

/* Arrow icon */
.tos-toggle-arrow {
  display: inline-block;
  transition: transform 0.3s ease;
  font-size: var(--text-lg);
  margin-left: var(--space-1);
}

.tos-toggle-link.expanded .tos-toggle-arrow {
  transform: rotate(90deg);
}

/* TOS content (expandable, initially hidden) */
.tos-content {
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  max-height: 300px;
  overflow-y: auto;
  margin-bottom: var(--space-4);
  direction: ltr;
  text-align: left;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.6;
  white-space: pre-wrap;
  font-family: monospace;
  transition: max-height 0.3s ease, opacity 0.3s ease;
}

.tos-content[style*="display: none"] {
  opacity: 0;
}

.tos-content[style*="display: block"] {
  opacity: 1;
}

.tos-checkbox-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
  direction: rtl;
  cursor: pointer;
  user-select: none;
}

.tos-checkbox-label input[type="checkbox"] {
  cursor: pointer;
  flex-shrink: 0;
}

.tos-checkbox-label span {
  font-size: var(--text-sm);
  color: var(--text-primary);
}

.modal-actions .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
