/* ============================================================
   WONA CHAT — global.css
   Clean, professional. No glows. No AI aesthetics.
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600&display=swap');

:root {
  /* Colours */
  --white:       #ffffff;
  --off-white:   #f8f9fb;
  --gray-50:     #f3f4f6;
  --gray-100:    #e9eaec;
  --gray-200:    #d1d5db;
  --gray-300:    #9ca3af;
  --gray-400:    #6b7280;
  --gray-500:    #4b5563;
  --gray-600:    #374151;
  --gray-700:    #1f2937;
  --gray-800:    #111827;
  --gray-900:    #0d1117;

  --blue:        #2563eb;
  --blue-dark:   #1d4ed8;
  --blue-light:  #eff6ff;
  --blue-mid:    #dbeafe;
  --red:         #dc2626;
  --red-light:   #fef2f2;
  --green:       #16a34a;
  --green-light: #f0fdf4;
  --amber:       #d97706;
  --amber-light: #fffbeb;

  /* Typography */
  --font:      'Inter', 'DM Sans', system-ui, sans-serif;
  --font-num:  'Inter', system-ui, sans-serif;

  /* Spacing */
  --nav-h:   58px;
  --max-w:   1060px;

  /* Radius */
  --r-sm:    4px;
  --r-md:    8px;
  --r-lg:    12px;
  --r-xl:    16px;
  --r-2xl:   24px;

  /* Borders */
  --border:  1px solid #e5e7eb;
  --border-2:1px solid #d1d5db;

  /* Shadows — subtle, real */
  --shadow-sm:  0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md:  0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.06);
  --shadow-lg:  0 10px 15px rgba(0,0,0,0.07), 0 4px 6px rgba(0,0,0,0.05);

  /* Transition */
  --t: 150ms ease;
}

/* ── Reset ───────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font);
  background: var(--white);
  color: var(--gray-800);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; display: block; }
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--gray-50); }
::-webkit-scrollbar-thumb { background: var(--gray-200); border-radius: 3px; }

/* ── Typography ──────────────────────────────────────────────── */
h1,h2,h3,h4,h5,h6 {
  font-family: var(--font);
  font-weight: 700;
  line-height: 1.2;
  color: var(--gray-900);
  letter-spacing: -0.02em;
}
h1 { font-size: clamp(1.9rem, 4vw, 3rem); font-weight: 800; }
h2 { font-size: clamp(1.45rem, 3vw, 2.1rem); }
h3 { font-size: 1.1rem; }
h4 { font-size: .95rem; }
p  { color: var(--gray-500); line-height: 1.7; font-size: .93rem; }
a  { color: var(--blue); text-decoration: none; transition: color var(--t); }
a:hover { color: var(--blue-dark); }
strong { font-weight: 600; color: var(--gray-700); }

/* ── Buttons ─────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 20px;
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: .875rem;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--t);
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: -0.01em;
}
.btn-primary {
  background: var(--blue);
  color: var(--white);
  border-color: var(--blue);
}
.btn-primary:hover { background: var(--blue-dark); border-color: var(--blue-dark); color: var(--white); }

.btn-secondary {
  background: var(--white);
  color: var(--gray-700);
  border-color: var(--gray-200);
}
.btn-secondary:hover { background: var(--gray-50); border-color: var(--gray-300); color: var(--gray-800); }

.btn-ghost {
  background: transparent;
  color: var(--gray-500);
  border-color: transparent;
}
.btn-ghost:hover { background: var(--gray-50); color: var(--gray-700); }

.btn-danger {
  background: var(--white);
  color: var(--red);
  border-color: #fecaca;
}
.btn-danger:hover { background: var(--red-light); border-color: #fca5a5; }

.btn-lg { padding: 12px 28px; font-size: .95rem; }
.btn-sm { padding: 6px 14px; font-size: .8rem; }
.btn-full { width: 100%; justify-content: center; }

/* ── Forms ───────────────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: 5px; }
.form-label {
  font-size: .8rem;
  font-weight: 600;
  color: var(--gray-600);
  letter-spacing: -0.01em;
}
.form-input, .form-select, .form-textarea {
  background: var(--white);
  border: var(--border-2);
  border-radius: var(--r-md);
  padding: 10px 12px;
  font-family: var(--font);
  font-size: .875rem;
  color: var(--gray-800);
  outline: none;
  width: 100%;
  transition: border-color var(--t), box-shadow var(--t);
}
.form-input::placeholder,
.form-textarea::placeholder { color: var(--gray-300); }
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}
.form-textarea { resize: vertical; min-height: 96px; }
.form-hint { font-size: .76rem; color: var(--gray-400); margin-top: 3px; }
.form-error { font-size: .76rem; color: var(--red); margin-top: 3px; }

/* ── Navbar ──────────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  height: var(--nav-h);
  background: var(--white);
  border-bottom: var(--border);
  display: flex;
  align-items: center;
  padding: 0 28px;
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--gray-900);
  letter-spacing: -0.03em;
}
.nav-logo-icon {
  width: 30px; height: 30px;
  border-radius: var(--r-md);
  background: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .85rem;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}
.nav-links a {
  padding: 6px 12px;
  border-radius: var(--r-md);
  font-size: .86rem;
  font-weight: 500;
  color: var(--gray-500);
  text-decoration: none;
  transition: all var(--t);
}
.nav-links a:hover { background: var(--gray-50); color: var(--gray-800); }
.nav-links a.active { background: var(--blue-light); color: var(--blue); font-weight: 600; }

.nav-actions { display: flex; align-items: center; gap: 8px; }
.nav-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--blue);
  display: flex; align-items: center; justify-content: center;
  font-size: .75rem; font-weight: 700; color: var(--white);
  text-decoration: none;
  border: 2px solid var(--blue-mid);
}

.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
.nav-hamburger span {
  display: block;
  width: 20px; height: 2px;
  background: var(--gray-500);
  border-radius: 1px;
  transition: all var(--t);
}
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-h); left: 0; right: 0;
  background: var(--white);
  border-bottom: var(--border);
  padding: 12px 20px;
  z-index: 199;
  flex-direction: column;
  gap: 2px;
  box-shadow: var(--shadow-md);
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  font-size: .9rem;
  color: var(--gray-600);
  padding: 10px 8px;
  border-bottom: var(--border);
  font-weight: 500;
}
.nav-mobile a:last-child { border-bottom: none; }

/* ── Footer ──────────────────────────────────────────────────── */
.footer {
  background: var(--gray-900);
  color: var(--gray-400);
  padding: 60px 28px 28px;
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-logo {
  display: flex; align-items: center; gap: 8px;
  text-decoration: none;
  font-size: 1rem; font-weight: 800;
  color: var(--white);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.footer-logo-icon {
  width: 28px; height: 28px;
  border-radius: var(--r-md);
  background: var(--blue);
  display: flex; align-items: center; justify-content: center;
  font-size: .78rem;
}
.footer-brand p { font-size: .82rem; line-height: 1.65; max-width: 240px; }
.footer-col h5 {
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--gray-300);
  margin-bottom: 14px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.footer-col ul a { font-size: .83rem; color: var(--gray-400); transition: color var(--t); }
.footer-col ul a:hover { color: var(--white); }
.footer-bottom {
  max-width: var(--max-w);
  margin: 20px auto 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .78rem;
}
.footer-online {
  display: flex; align-items: center; gap: 5px;
  color: #4ade80; font-size: .75rem;
}
.online-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #22c55e;
  animation: blink 2s ease infinite;
}
@keyframes blink { 0%,100%{opacity:1;} 50%{opacity:.3;} }

/* ── Layout ──────────────────────────────────────────────────── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 28px; }
.page-wrap { padding-top: calc(var(--nav-h) + 40px); padding-bottom: 80px; min-height: 100vh; }
.section { padding: 80px 28px; }
.section-sm { padding: 48px 28px; }
.divider { border: none; border-top: var(--border); margin: 24px 0; }

/* ── Alerts ──────────────────────────────────────────────────── */
.alert {
  padding: 11px 14px;
  border-radius: var(--r-md);
  font-size: .85rem;
  display: flex; align-items: flex-start; gap: 8px;
  margin-bottom: 16px;
  font-weight: 500;
}
.alert-error   { background: var(--red-light);   border: 1px solid #fecaca; color: #b91c1c; }
.alert-success { background: var(--green-light); border: 1px solid #bbf7d0; color: #15803d; }
.alert-info    { background: var(--blue-light);  border: 1px solid var(--blue-mid); color: var(--blue-dark); }

/* ── Badge ───────────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px;
  border-radius: 9999px;
  font-size: .72rem; font-weight: 600;
}
.badge-blue   { background: var(--blue-light);   color: var(--blue);    border: 1px solid var(--blue-mid); }
.badge-green  { background: var(--green-light);  color: var(--green);   border: 1px solid #bbf7d0; }
.badge-amber  { background: var(--amber-light);  color: var(--amber);   border: 1px solid #fde68a; }
.badge-gray   { background: var(--gray-50);      color: var(--gray-600); border: var(--border); }

/* ── Card ────────────────────────────────────────────────────── */
.card {
  background: var(--white);
  border: var(--border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-sm);
}
.card-padded { padding: 24px; }

/* ── Password strength ───────────────────────────────────────── */
.strength-bar { height: 3px; background: var(--gray-100); border-radius: 2px; overflow: hidden; margin-top: 6px; }
.strength-fill { height: 100%; border-radius: 2px; width: 0; transition: width var(--t), background var(--t); }
.strength-fill.weak   { width: 25%; background: var(--red); }
.strength-fill.fair   { width: 50%; background: var(--amber); }
.strength-fill.good   { width: 75%; background: #0891b2; }
.strength-fill.strong { width: 100%; background: var(--green); }
.strength-text { font-size: .72rem; color: var(--gray-400); margin-top: 3px; }

/* ── Section label ───────────────────────────────────────────── */
.section-label {
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--blue);
  margin-bottom: 8px;
}

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 768px) {
  .nav-links, .nav-actions { display: none; }
  .nav-hamburger { display: flex; }
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; gap: 10px; text-align: center; }
  .section { padding: 56px 20px; }
  .container { padding: 0 20px; }
}
@media (max-width: 480px) {
  .footer-inner { grid-template-columns: 1fr; }
}
