/* Momentum design tokens + shared chrome for Webhook Tester */

:root {
  /* Color */
  --wt-color-primary-action: #000000f2;
  --wt-color-text-primary: rgba(0, 0, 0, 0.95);
  --wt-color-text-secondary: rgba(0, 0, 0, 0.70);
  --wt-color-text-disabled: rgba(0, 0, 0, 0.40);
  --wt-color-text-success: #1d805f;
  --wt-color-bg-success: rgba(29, 128, 95, 0.14);
  --wt-color-cobalt: #1170cf;
  --wt-color-bg-cobalt: rgba(17, 112, 207, 0.12);
  --wt-color-put: #8a5600;
  --wt-color-bg-put: rgba(196, 120, 0, 0.16);
  --wt-color-destructive: #db1f2e;
  --wt-color-bg-destructive: rgba(219, 31, 46, 0.12);

  /* Surfaces */
  --wt-surface-page: #ffffff;
  --wt-surface-solid: #ffffff;
  --wt-surface-secondary: #f2f2f2;

  /* Borders / overlays */
  --wt-outline-secondary: rgba(0, 0, 0, 0.08);
  --wt-outline-input: rgba(0, 0, 0, 0.16);
  --wt-hover-overlay: rgba(0, 0, 0, 0.07);

  /* Radius */
  --wt-radius-xs: 6px;
  --wt-radius-sm: 8px;
  --wt-radius-md: 10px;
  --wt-radius-lg: 12px;
  --wt-radius-xl: 16px;
  --wt-radius-pill: 999px;

  /* Elevation */
  --wt-elevation-1: 0 2px 8px rgba(0, 0, 0, 0.12);

  /* Motion */
  --wt-ease: cubic-bezier(0.44, 0, 0, 1);
  --wt-duration-fast: 100ms;
  --wt-duration-base: 200ms;
  --wt-duration-slow: 300ms;

  /* Typography */
  --wt-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --wt-mono: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;
}

@font-face {
  font-family: 'Inter';
  src: url('/static/fonts/inter-latin.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--wt-surface-page);
  color: var(--wt-color-text-primary);
  font-family: var(--wt-font);
}

*, *::before, *::after {
  box-sizing: border-box;
}

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

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb {
  background: var(--wt-outline-secondary);
  border-radius: 8px;
  border: 3px solid var(--wt-surface-page);
}

@keyframes wt-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}

@keyframes wt-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: none; }
}

/* ---- Shared chrome ---- */

.wt-icon { display: inline-flex; align-items: center; justify-content: center; }
.wt-icon svg { width: 100%; height: 100%; display: block; }

.wt-appbar {
  flex: 0 0 auto;
  height: 56px;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 24px;
  background: var(--wt-surface-solid);
  border-bottom: 1px solid var(--wt-outline-secondary);
}

.wt-appbar__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
}

.wt-appbar__tile {
  width: 30px;
  height: 30px;
  border-radius: var(--wt-radius-sm);
  background: var(--wt-color-primary-action);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
}

.wt-appbar__brand {
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.01em;
  color: var(--wt-color-text-primary);
}

.wt-appbar__version {
  margin-left: auto;
  font-family: var(--wt-mono);
  font-size: 12px;
  color: var(--wt-color-text-secondary);
}

.wt-overline {
  font-size: 12px;
  font-weight: 600;
  color: var(--wt-color-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.wt-card {
  background: var(--wt-surface-solid);
  border: 1px solid var(--wt-outline-secondary);
  border-radius: var(--wt-radius-xl);
  padding: 24px;
  box-shadow: var(--wt-elevation-1);
}

.wt-tag {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 22px;
  padding: 0 9px;
  border-radius: var(--wt-radius-pill);
  font-size: 11px;
  font-weight: 700;
}
.wt-tag--neutral {
  background: var(--wt-surface-secondary);
  color: var(--wt-color-text-secondary);
}
.wt-tag--success {
  background: var(--wt-color-bg-success);
  color: var(--wt-color-text-success);
}

.wt-btn-pill {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 20px;
  border: none;
  border-radius: var(--wt-radius-pill);
  background: var(--wt-color-primary-action);
  color: #fff;
  font-family: inherit;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: background var(--wt-duration-base) var(--wt-ease);
}
.wt-btn-pill:hover {
  background: #000000;
}

.wt-btn-ghost {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 26px;
  padding: 0 10px;
  border: none;
  border-radius: var(--wt-radius-xs);
  background: transparent;
  cursor: pointer;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--wt-color-cobalt);
  transition: background var(--wt-duration-base) var(--wt-ease);
}
.wt-btn-ghost:hover {
  background: var(--wt-hover-overlay);
}

.wt-badge {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  height: 22px;
  padding: 0 8px;
  border-radius: var(--wt-radius-xs);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.wt-badge--lg {
  min-width: 60px;
  height: 28px;
  font-size: 13px;
  border-radius: var(--wt-radius-sm);
}
.wt-badge--get { background: rgba(29, 128, 95, 0.14); color: #1d805f; }
.wt-badge--post { background: rgba(17, 112, 207, 0.12); color: #1170cf; }
.wt-badge--put { background: rgba(196, 120, 0, 0.16); color: #8a5600; }
.wt-badge--delete { background: rgba(219, 31, 46, 0.12); color: #db1f2e; }

.wt-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--wt-color-text-success);
  animation: wt-blink 1.4s ease-in-out infinite;
}
.wt-dot--sm { width: 6px; height: 6px; }
.wt-dot.is-disconnected { background: var(--wt-color-destructive); }

.wt-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 10px;
  border-radius: var(--wt-radius-pill);
  background: var(--wt-color-bg-success);
  color: var(--wt-color-text-success);
  font-size: 12px;
  font-weight: 600;
}
.wt-status-pill.is-disconnected {
  background: var(--wt-color-bg-destructive);
  color: var(--wt-color-destructive);
}
