:root {
  --eqs-bg0: #0e0c0a;
  --eqs-bg1: #171310;
  --eqs-surface: rgba(255, 245, 220, 0.05);
  --eqs-border: rgba(200, 157, 84, 0.25);
  --eqs-text: rgba(245, 240, 230, 0.95);
  --eqs-muted: rgba(214, 203, 185, 0.72);
  --eqs-gold: #c89d54;
  --eqs-gold2: #e5c158;
  --eqs-blue: #c89d54;
  --eqs-green: #2e9e6b;
  --eqs-red: #ef4444;
  --eqs-radius: 8px;
  --eqs-shadow: 0 12px 32px rgba(0, 0, 0, 0.55);
  --eqs-textScale: 1;
}

html {
  font-size: calc(16px * var(--eqs-textScale));
}

body.eqs-shell {
  background: radial-gradient(900px 600px at 18% 0%, rgba(200, 157, 84, 0.12), transparent 55%),
    linear-gradient(180deg, var(--eqs-bg0), var(--eqs-bg1));
  color: var(--eqs-text);
}

/* High contrast mode */
html[data-eqs-contrast="high"] body {
  background: #000 !important;
  color: #fff !important;
}

html[data-eqs-contrast="high"] a,
html[data-eqs-contrast="high"] button {
  outline-color: #fff !important;
}

/* Reduced motion */
html[data-eqs-motion="reduce"] *,
html[data-eqs-motion="reduce"] *::before,
html[data-eqs-motion="reduce"] *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
  scroll-behavior: auto !important;
}

/* Top bar */
#eqs-topbar {
  position: sticky;
  top: 0;
  z-index: 9999;
  backdrop-filter: blur(10px);
  background: rgba(20, 16, 13, 0.92);
  border-bottom: 1px solid var(--eqs-border);
}

#eqs-topbar .eqs-wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: space-between;
}

.eqs-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 180px;
}

.eqs-badge {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  background: rgba(200, 157, 84, 0.18);
  border: 1px solid rgba(200, 157, 84, 0.45);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: center;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--eqs-gold2);
}

.eqs-titleblock {
  line-height: 1.1;
}

.eqs-titleblock .eqs-suite {
  font-size: 12px;
  color: var(--eqs-muted);
  font-weight: 600;
}

.eqs-titleblock .eqs-app {
  font-size: 14px;
  color: var(--eqs-text);
  font-weight: 800;
}

.eqs-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

.eqs-pill {
  appearance: none;
  border: 1px solid var(--eqs-border);
  background: rgba(29, 24, 19, 0.9);
  color: var(--eqs-text);
  padding: 7px 11px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.12s ease, border-color 0.12s ease;
}

.eqs-pill:hover {
  transform: translateY(-1px);
  border-color: rgba(200, 157, 84, 0.55);
  background: rgba(40, 33, 26, 0.95);
}

.eqs-pill[aria-current="page"] {
  border-color: rgba(200, 157, 84, 0.65);
  background: rgba(200, 157, 84, 0.18);
}

.eqs-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
  min-width: 180px;
}

.eqs-iconbtn {
  border-radius: 6px;
  padding: 7px 10px;
}

/* Accessible focus */
.eqs-pill:focus-visible,
.eqs-card:focus-visible {
  outline: 2px solid var(--eqs-gold2);
  outline-offset: 2px;
}
