@import "tailwindcss";
@import "tw-animate-css";

@theme {
  --color-bg: #0c0d0b;
  --color-surface: #161814;
  --color-elevated: #1e211c;
  --color-well: #12140f;
  --color-fg: #e8e6df;
  --color-muted: #8a8e82;
  --color-subtle: #5e6358;
  --color-accent: #8fbf9a;
  --color-accent-fg: #0c0d0b;
  --color-border: color-mix(in oklab, var(--color-fg) 12%, transparent);
  --color-border-strong: color-mix(in oklab, var(--color-fg) 22%, transparent);
  --color-danger: #b4534e;
  --color-check-a: #1a1c16;
  --color-check-b: #141611;
  --color-grid-line: color-mix(in oklab, var(--color-fg) 18%, transparent);

  --font-sans: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;
  --font-display: "Pixelify Sans", "IBM Plex Sans", system-ui, sans-serif;

  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  --shadow-border: 0 0 0 1px rgba(232, 230, 223, 0.08);
  --shadow-border-hover: 0 0 0 1px rgba(232, 230, 223, 0.14);
  --shadow-well:
    inset 0 0 0 1px rgba(232, 230, 223, 0.06),
    inset 0 1px 0 rgba(232, 230, 223, 0.04);

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-smooth-out: cubic-bezier(0.22, 1, 0.36, 1);
  --motion-micro: 80ms;
  --motion-quick: 150ms;
  --motion-fast: 250ms;
  --motion-medium: 350ms;
}

@layer base {
  html {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }

  html,
  body,
  #app {
    min-height: 100dvh;
    background: var(--color-bg);
    color: var(--color-fg);
  }

  body {
    font-family: var(--font-sans);
    letter-spacing: -0.01em;
  }

  button:not(:disabled),
  [role="button"]:not(:disabled) {
    cursor: pointer;
  }

  ::selection {
    background: color-mix(in oklab, var(--color-accent) 40%, transparent);
    color: var(--color-fg);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.pixelated {
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.checkerboard {
  background-color: var(--color-check-a);
  background-image:
    linear-gradient(45deg, var(--color-check-b) 25%, transparent 25%),
    linear-gradient(-45deg, var(--color-check-b) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--color-check-b) 75%),
    linear-gradient(-45deg, transparent 75%, var(--color-check-b) 75%);
  background-size: 16px 16px;
  background-position:
    0 0,
    0 8px,
    8px -8px,
    -8px 0;
}
