/* PairWise Shared Design System */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=DM+Sans:wght@400;500&display=swap');

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --ink: #0a0f1a;
  --warm: #e8a435;
  --warm-light: #fef3db;
  --warm-glow: rgba(232, 164, 53, 0.12);
  --slate: #3d4663;
  --mist: #f4f5f8;
  --white: #ffffff;
  --blue: #4a6cf7;
  --blue-light: #e3eaff;
  --green: #10b981;
  --green-light: #d1fae5;
  --red: #ef4444;
  --red-light: #fee2e2;
  --border: #e5e7ee;
  --shadow-sm: 0 2px 8px rgba(10, 15, 26, 0.06);
  --shadow-md: 0 8px 24px rgba(10, 15, 26, 0.08);
  --shadow-lg: 0 20px 60px rgba(10, 15, 26, 0.1);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 20px;
}

body {
  font-family: 'DM Sans', -apple-system, sans-serif;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Typography */
h1, h2, h3, h4 {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  letter-spacing: -0.5px;
}
h1 { font-size: 2.8rem; line-height: 1.1; letter-spacing: -2px; }
h2 { font-size: 2rem; line-height: 1.15; letter-spacing: -1px; }
h3 { font-size: 1.3rem; line-height: 1.3; }
p { line-height: 1.7; color: var(--slate); }
a { color: var(--warm); text-decoration: none; transition: opacity 0.2s; }
a:hover { opacity: 0.8; }
em { font-style: normal; color: var(--warm); }

/* NAV */
.nav {
  padding: 20px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
}
.nav .logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--ink);
  letter-spacing: -0.5px;
  text-decoration: none;
}
.nav .logo span { color: var(--warm); }
.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--slate);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--warm); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  white-space: nowrap;
}
.btn-primary {
  background: var(--ink);
  color: var(--white);
}
.btn-primary:hover { background: #1a2438; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-warm {
  background: var(--warm);
  color: var(--white);
}
.btn-warm:hover { background: #d4932e; transform: translateY(-1px); }
.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--border);
}
.btn-outline:hover { border-color: var(--ink); }
.btn-sm { padding: 10px 20px; font-size: 0.85rem; }
.btn-lg { padding: 18px 36px; font-size: 1.05rem; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

/* Cards */
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: all 0.25s ease;
}
.card:hover {
  border-color: var(--warm);
  box-shadow: 0 8px 32px var(--warm-glow);
  transform: translateY(-2px);
}

/* Tags */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--mist);
  color: var(--slate);
  font-size: 0.78rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 8px;
}
.tag-warm {
  background: var(--warm-light);
  color: var(--warm);
}
.tag-blue {
  background: var(--blue-light);
  color: var(--blue);
}

/* Form elements */
.form-group {
  margin-bottom: 24px;
}
.form-group label {
  display: block;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 8px;
  color: var(--ink);
}
.form-group .hint {
  font-size: 0.8rem;
  color: var(--slate);
  margin-top: 4px;
}
input[type="text"],
input[type="email"],
input[type="date"],
input[type="number"],
select,
textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--warm);
  box-shadow: 0 0 0 3px var(--warm-glow);
}
textarea { resize: vertical; min-height: 100px; }
select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%233d4663' d='M6 8L1 3h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; }

/* Avatar */
.avatar {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--white);
  flex-shrink: 0;
}
.avatar-sm { width: 40px; height: 40px; font-size: 1rem; border-radius: 10px; }
.avatar-lg { width: 72px; height: 72px; font-size: 1.8rem; border-radius: 18px; }

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

/* Page header */
.page-header {
  padding: 60px 0 40px;
}
.page-header .breadcrumb {
  font-size: 0.8rem;
  color: var(--slate);
  margin-bottom: 16px;
}
.page-header .breadcrumb a { color: var(--warm); }

/* Section label */
.section-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--warm);
  font-weight: 600;
  margin-bottom: 12px;
}

/* Grid */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }

/* Loading state */
.loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  color: var(--slate);
}
.loading::after {
  content: '';
  width: 24px;
  height: 24px;
  border: 3px solid var(--border);
  border-top-color: var(--warm);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 12px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Match score */
.match-score {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--green);
}
.match-score-bar {
  width: 100%;
  height: 6px;
  background: var(--mist);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 8px;
}
.match-score-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--warm), var(--green));
  border-radius: 3px;
  transition: width 1s ease;
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 32px 48px;
  max-width: 1200px;
  margin: 80px auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer .logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--ink);
  text-decoration: none;
}
.footer .logo span { color: var(--warm); }
.footer p { font-size: 0.8rem; color: var(--slate); margin: 0; }

/* Empty state */
.empty-state {
  text-align: center;
  padding: 80px 20px;
}
.empty-state h3 { margin-bottom: 12px; }

/* Responsive */
@media (max-width: 768px) {
  .nav { padding: 16px 20px; }
  .nav-links { gap: 16px; }
  .nav-links a { font-size: 0.8rem; }
  .container { padding: 0 20px; }
  h1 { font-size: 2rem; letter-spacing: -1px; }
  h2 { font-size: 1.6rem; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .page-header { padding: 32px 0 24px; }
  .footer { padding: 24px 20px; flex-direction: column; gap: 12px; margin-top: 48px; }
  .btn-lg { padding: 14px 24px; font-size: 0.95rem; }
}
