/* Shared UI polish for the standalone HTML pages (login/register/admin dashboards).
   Intentionally light-touch: uses existing per-page CSS variables when present. */

:root {
  --yalla-radius-sm: 10px;
  --yalla-radius-md: 14px;
  --yalla-radius-lg: 18px;
  --yalla-ring: 0 0 0 3px rgba(37, 99, 235, 0.22);
  --yalla-ring-strong: 0 0 0 4px rgba(37, 99, 235, 0.28);
  --yalla-shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06), 0 6px 16px rgba(16, 24, 40, 0.08);
  --yalla-shadow-md: 0 1px 2px rgba(16, 24, 40, 0.06), 0 12px 28px rgba(16, 24, 40, 0.12);
  --yalla-transition: 160ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

:where(a) {
  color: inherit;
  text-decoration-color: color-mix(in srgb, currentColor 35%, transparent);
  text-underline-offset: 3px;
}

@supports not (color: color-mix(in srgb, white, black)) {
  :where(a) {
    text-decoration-color: rgba(15, 23, 42, 0.25);
  }
}

:where(button, [role='button'], input, select, textarea, a) {
  outline: none;
}

:where(button, [role='button'], input, select, textarea, a):focus-visible {
  box-shadow: var(--ring, var(--yalla-ring));
}

:where(input, select, textarea) {
  accent-color: var(--primary, #2563eb);
}

.btn {
  transition:
    transform var(--yalla-transition),
    box-shadow var(--yalla-transition),
    background var(--yalla-transition),
    border-color var(--yalla-transition),
    color var(--yalla-transition);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn[disabled],
.btn.disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.card {
  border-radius: var(--yalla-radius-md);
  box-shadow: var(--shadow, var(--yalla-shadow-sm));
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
    scroll-behavior: auto !important;
  }
}
