/* ============================================
   RentTech Design System — shared CSS
   ============================================ */
:root {
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  --shadow-sm: 0 2px 10px rgba(0,0,0,0.15);
  --shadow-md: 0 4px 24px rgba(0,0,0,0.2);
  --shadow-lg: 0 10px 40px rgba(0,0,0,0.5);
  --shadow-glow: 0 4px 20px rgba(255,255,255,0.1);
}
/* ---------- focus-visible (M6) ---------- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
/* ---------- prefers-reduced-motion (M7) ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
/* ---------- responsive breakpoints (M13) ---------- */
@media (max-width: 768px) {
  .hide-tablet { display: none !important; }
}
@media (max-width: 480px) {
  .hide-mobile { display: none !important; }
  .btn-sm { font-size: 0.9rem; min-height: 44px; padding: 0.6rem 1.1rem; }
}
@media (max-width: 400px) {
  .card { padding: 1rem; }
}
/* ---------- btn base ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius-md);
  font-weight: 500;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  text-decoration: none;
  line-height: 1.2;
  white-space: normal;
  word-break: keep-all;
}
.btn:hover { opacity: 0.85; }
.btn:active { transform: scale(0.97); }
/* ---------- btn variants ---------- */
.btn-primary {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
  font-weight: 600;
}
.btn-primary:hover { opacity: 0.9; }

.btn-secondary {
  border-color: var(--border);
  background: var(--surface);
  color: var(--text);
}
.btn-secondary:hover { background: var(--surface2); border-color: rgba(255,255,255,0.15); }

.btn.btn-happ,
.btn-secondary.btn-happ {
  background: #fff !important;
  color: #0b0b0c !important;
  border-color: #fff !important;
  font-weight: 600;
}
.btn.btn-happ:hover,
.btn-secondary.btn-happ:hover { opacity: 0.9; border-color: #fff !important; }

.btn-danger {
  border-color: var(--red);
  color: var(--red);
  background: transparent;
}
.btn-danger:hover { background: rgba(255,71,87,0.08); }

.btn-ghost {
  border-color: transparent;
  color: var(--muted);
}
.btn-ghost:hover { color: var(--accent); }

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}
.btn-xs {
  padding: 0.4rem 0.85rem;
  font-size: 0.75rem;
  border-radius: var(--radius-xs);
}
/* full-width modifier */
.btn-block { width: 100%; }

/* ---------- card ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.25rem;
}
.card-glass {
  background: rgba(255,255,255,0.03);
  backdrop-filter: blur(8px);
}

/* ---------- input ---------- */
.input {
  display: block;
  width: 100%;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 0.9rem;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s;
}
.input:focus { border-color: var(--accent); }

/* ---------- modal ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  max-width: 400px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

/* ---------- badge ---------- */
.badge {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 500;
}

/* ---------- touch target helper (M8) ---------- */
.touch-target {
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
}

/* ---------- link hover utility ---------- */
.link-accent { color: var(--muted); text-decoration: none; transition: color 0.2s; }
.link-accent:hover { color: var(--accent); }

.link-hover-opacity { transition: opacity 0.2s; }
.link-hover-opacity:hover { opacity: 0.85; }

/* ---------- text utilities ---------- */
.text-muted { color: var(--muted); }
.text-accent { color: var(--accent); }
.text-green { color: var(--green); }
.text-red { color: var(--red); }
.text-center { text-align: center; }
.font-unbounded { font-family: 'Unbounded', sans-serif; }
.font-small { font-size: 0.8rem; }
.font-xs { font-size: 0.7rem; }

/* ---------- flex/grid utilities ---------- */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-sm { gap: 0.5rem; }
.gap-md { gap: 0.75rem; }
.gap-lg { gap: 1rem; }

/* ---------- spacing ---------- */
.mt-sm { margin-top: 0.5rem; }
.mt-md { margin-top: 1rem; }
.mt-lg { margin-top: 1.5rem; }
.mb-sm { margin-bottom: 0.5rem; }
.mb-md { margin-bottom: 1rem; }
.mb-lg { margin-bottom: 1.5rem; }

/* ---------- scrollbar (S9) ---------- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--muted); }


.interactive-card {
  cursor: pointer;
  transition: background 0.15s, border-color 0.2s;
}
.interactive-card:hover {
  background: var(--surface2);
  border-color: rgba(255,255,255,0.12);
}
