/* ============================================================
   eShipz — AskFouzan · Design System v2
   Deep teal-black brand, bright cyan accent, warm neutrals.
   Claude-style calm chat layout. Critically-damped motion only.
   ============================================================ */

:root {
  /* Color */
  --bg: #F7F9F9;
  --bg-sidebar: #05383D;
  --surface: #FFFFFF;
  --border: #E8E8E8;
  --border-strong: #D2D2D2;
  --text: #121212;
  --text-secondary: #606060;
  --text-faint: #8E8E8E;

  --sidebar-text: #FFFFFF;
  --sidebar-text-secondary: rgba(255, 255, 255, 0.62);
  --sidebar-border: rgba(255, 255, 255, 0.12);
  --sidebar-hover: rgba(255, 255, 255, 0.08);

  --accent: #01A6A7;
  --accent-hover: #009D9E;
  --accent-bright: #01C5C6;
  --accent-soft: #E1F8F8;
  --accent-soft-border: #B8ECEC;

  --danger: #FB3748;
  --danger-soft: #FFE8EA;
  --danger-soft-border: #FFC1C6;

  --success: #1FC16B;
  --success-soft: #E3FAEE;

  --warning: #DFB400;
  --warning-soft: #FFF8DE;

  --shadow-sm: 0 1px 2px rgba(18, 18, 18, 0.06);
  --shadow-md: 0 4px 16px rgba(18, 18, 18, 0.10);
  --shadow-lg: 0 12px 32px rgba(18, 18, 18, 0.14);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  color-scheme: light;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  margin: 0;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
}

p { margin: 0; }

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

/* ---------- Brand wordmark ---------- */
.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  user-select: none;
}
.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0;
  flex-shrink: 0;
}
.brand-logo {
  height: 22px;
  width: auto;
  flex-shrink: 0;
}
.brand-name {
  font-weight: 650;
  font-size: 16px;
  letter-spacing: -0.01em;
  color: var(--text);
}
.brand-name .divider {
  color: var(--text-faint);
  font-weight: 400;
  margin: 0 6px;
}
.brand-name .product,
.brand-name.product {
  color: var(--text-secondary);
  font-weight: 500;
}

/* ---------- Buttons ---------- */
button {
  font-family: inherit;
  font-size: 14px;
  cursor: pointer;
  border: none;
  border-radius: var(--radius-pill);
  transition: transform 100ms ease-out, background-color 150ms ease-out, box-shadow 150ms ease-out;
}
button:active { transform: scale(0.97); }

.btn-primary {
  background: var(--accent);
  color: white;
  font-weight: 600;
  padding: 11px 20px;
}
.btn-primary:hover { background: var(--accent-hover); }
.btn-primary:disabled { background: var(--text-faint); cursor: not-allowed; transform: none; }

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
  font-weight: 500;
  padding: 10px 18px;
}
.btn-secondary:hover { background: #F1F1F1; }

.btn-danger {
  background: var(--danger-soft);
  color: var(--danger);
  border: 1px solid var(--danger-soft-border);
  font-weight: 500;
  padding: 8px 16px;
  font-size: 13px;
}
.btn-danger:hover { background: var(--danger-soft-border); }

.btn-text {
  background: none;
  color: var(--accent);
  font-weight: 500;
  padding: 4px 8px;
}
.btn-text:hover { background: var(--accent-soft); text-decoration: none; }

/* ---------- Inputs ---------- */
input[type=text], input[type=email], input[type=password], textarea {
  font-family: inherit;
  font-size: 15px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  color: var(--text);
  width: 100%;
  transition: border-color 150ms ease-out, box-shadow 150ms ease-out;
}
input:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
input::placeholder, textarea::placeholder { color: var(--text-faint); }

/* ---------- Cards ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

/* ---------- Auth page shell (login/signup/forgot/reset) ---------- */
.auth-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--bg-sidebar);
}
.auth-shell > .brand {
  margin-bottom: 28px;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.auth-shell > .brand .brand-name .divider,
.auth-shell > .brand .brand-name .product {
  color: var(--sidebar-text-secondary);
}
.auth-box {
  width: 100%;
  max-width: 380px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  box-shadow: var(--shadow-lg);
  animation: rise 400ms cubic-bezier(0.22, 1, 0.36, 1);
}
.auth-box h1 {
  font-size: 20px;
  text-align: center;
  margin-bottom: 24px;
}
.auth-box form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.auth-box .btn-primary { margin-top: 6px; }
.auth-links {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 20px;
  font-size: 13.5px;
}
.auth-msg {
  min-height: 20px;
  font-size: 13.5px;
  text-align: center;
  margin-top: 10px;
  color: var(--danger);
}
.auth-msg.success { color: var(--success); }
.auth-hint {
  color: var(--text-faint);
  font-size: 12.5px;
  margin-top: -2px;
  margin-bottom: 2px;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .auth-box { animation: none; }
  * { transition-duration: 1ms !important; }
}

/* ---------- Scrollbar (subtle) ---------- */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 8px; }
::-webkit-scrollbar-track { background: transparent; }
