/* Rainwolf Sports Buyer Portal — light theme design system.
   Premium via spacing/typography/hierarchy, not effects. */

:root {
  color-scheme: light;
  --bg: #F7F7F5;
  --surface: #FFFFFF;
  --surface-2: #F4F4F2;
  --border: #E6E6E2;
  --border-strong: #D8D8D3;
  --text: #17171A;
  --text-2: #5B5B57;
  --muted: #8F8F89;
  --accent: #E4FF00;
  --accent-ink: #14140F;

  --status-green: #1FA14B;
  --status-green-bg: #EAF7EE;
  --status-amber: #B8860B;
  --status-amber-bg: #FBF3DD;
  --status-red: #D7263D;
  --status-red-bg: #FCEBED;
  --status-blue: #1E5BD6;
  --status-blue-bg: #EAF0FD;
  --status-gray-bg: #F0F0EE;

  --r: 12px;
  --r-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(23,23,26,.04);
  --shadow-md: 0 4px 16px rgba(23,23,26,.06);
  --ease: cubic-bezier(.22,.61,.36,1);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #101112;
  --surface: #181a1c;
  --surface-2: #222528;
  --border: #303438;
  --border-strong: #464b50;
  --text: #f4f5f2;
  --text-2: #c1c5c8;
  --muted: #8e959a;
  --status-green-bg: #163522;
  --status-amber-bg: #3a2f12;
  --status-red-bg: #3b1d24;
  --status-blue-bg: #182c4e;
  --status-gray-bg: #2b2e30;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.2);
  --shadow-md: 0 8px 28px rgba(0,0,0,.28);
}

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.display {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Inter", system-ui, sans-serif;
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.1;
}

.mono { font-family: "IBM Plex Mono", monospace; }

a { color: inherit; }

/* ---------- Status pills (shared across RFQs/Quotes/Orders/Invoices/Samples) ---------- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: .3em .7em;
  border-radius: 100px;
  white-space: nowrap;
}
.pill--green { color: var(--status-green); background: var(--status-green-bg); }
.pill--amber { color: var(--status-amber); background: var(--status-amber-bg); }
.pill--red   { color: var(--status-red); background: var(--status-red-bg); }
.pill--blue  { color: var(--status-blue); background: var(--status-blue-bg); }
.pill--gray  { color: var(--text-2); background: var(--status-gray-bg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  font-weight: 600;
  font-size: .88rem;
  padding: .78rem 1.3rem;
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: filter .15s, border-color .15s, background .15s, color .15s;
  background: var(--accent);
  color: var(--accent-ink);
  font-family: inherit;
  text-decoration: none;
}
.btn:hover { filter: brightness(1.04); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn--secondary { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn--secondary:hover { background: var(--surface-2); filter: none; }
.btn--ghost { background: transparent; color: var(--text-2); border-color: transparent; }
.btn--ghost:hover { background: var(--surface-2); color: var(--text); }
.btn--danger { background: var(--status-red-bg); color: var(--status-red); border-color: transparent; }
.btn--danger:hover { filter: brightness(.97); }
.btn--sm { padding: .5rem .9rem; font-size: .8rem; }
.btn--block { width: 100%; }
.btn--inline { width: auto; }

/* ---------- Auth pages (login/signup/reset) ---------- */
.auth-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(600px 300px at 15% 0%, rgba(228,255,0,.08), transparent 60%),
    var(--bg);
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 12px 34px rgba(23,23,26,.08);
  padding: clamp(1.8rem, 4vw, 2.6rem);
}

.auth-brand { display: flex; align-items: center; gap: .6rem; margin-bottom: 1.8rem; }
.auth-brand img { height: 26px; width: auto; filter: none; }
.auth-brand { justify-content: space-between; }

.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  min-width: 38px; height: 34px; padding: 0 .65rem;
  border: 1px solid var(--border-strong); border-radius: 999px;
  background: var(--surface); color: var(--text-2); cursor: pointer;
  font: inherit; font-size: .78rem; transition: background .15s, color .15s, border-color .15s;
}
.theme-toggle:hover { background: var(--surface-2); color: var(--text); }
.theme-toggle__icon { font-size: 1rem; line-height: 1; }
.auth-divider { display:flex; align-items:center; gap:.7rem; margin:1.25rem 0; color:var(--muted); font-size:.72rem; text-transform:uppercase; letter-spacing:.08em; }
.auth-divider::before,.auth-divider::after { content:""; height:1px; flex:1; background:var(--border); }
.oauth-btn { display:flex; align-items:center; justify-content:center; gap:.65rem; width:100%; padding:.72rem 1rem; border:1px solid var(--border-strong); border-radius:var(--r-sm); color:var(--text); background:var(--surface); text-decoration:none; font-weight:600; font-size:.88rem; transition:background .15s,border-color .15s; }
.oauth-btn:hover { background:var(--surface-2); border-color:var(--text-2); }
.oauth-btn--linkedin span { display:inline-flex; align-items:center; justify-content:center; width:22px; height:22px; border-radius:3px; background:#0a66c2; color:#fff; font-weight:700; font-size:.9rem; }
.oauth-provider-grid { display:grid; grid-template-columns:1fr 1fr; gap:.7rem; }
.oauth-provider-grid .oauth-btn { min-width:0; padding-left:.65rem; padding-right:.65rem; }
.oauth-btn__logo { width:22px; height:22px; object-fit:contain; flex:none; }
.oauth-btn--disabled { cursor:not-allowed; opacity:.55; }
.oauth-btn--disabled small { font-size:.65rem; font-weight:500; color:var(--muted); }
.auth-title { font-size: clamp(1.65rem, 4vw, 2rem); text-transform:none; }
.auth-sub { line-height:1.45; }
.input { border-radius:12px; }
.btn { border-radius:12px; }
@media (max-width:460px) { .oauth-provider-grid { grid-template-columns:1fr; } }

.auth-title { font-size: clamp(1.5rem, 4vw, 1.9rem); margin-bottom: .35rem; color: var(--text); }
.auth-sub { color: var(--text-2); font-size: .9rem; margin-bottom: 1.9rem; }

.field { margin-bottom: 1.1rem; display: flex; flex-direction: column; gap: .4rem; }
.field label { font-size: .78rem; font-weight: 600; color: var(--text-2); }

.input {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  padding: .78rem .9rem;
  color: var(--text);
  font: inherit;
  font-size: .9rem;
  transition: border-color .15s, box-shadow .15s;
}
.input:focus { outline: 0; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(228,255,0,.25); }
.input::placeholder { color: var(--muted); }

.field-row-inline {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1.5rem; font-size: .85rem;
}
.field-row-inline label { display: flex; align-items: center; gap: .5rem; color: var(--text-2); cursor: pointer; }
.field-row-inline a { color: var(--text); text-decoration: underline; text-underline-offset: 2px; }

.auth-error, .auth-success {
  border-radius: 9px; padding: .8rem 1rem; font-size: .85rem; margin-bottom: 1.2rem; display: none;
}
.auth-error { background: var(--status-red-bg); color: var(--status-red); }
.auth-success { background: var(--status-green-bg); color: var(--status-green); }
.auth-error.show, .auth-success.show { display: block; }

.auth-foot { margin-top: 1.7rem; text-align: center; font-size: .85rem; color: var(--text-2); }
.auth-foot a { color: var(--text); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
