/* ===========================================
   BORIDESK BASE STYLES & TYPOGRAPHY
   Core layout, fonts, selection, scrollbar
   =========================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.4s ease, color 0.4s ease;
}

/* === Typography === */
h1, h2, h3, h4, h5, h6 {
  line-height: 1.1;
}

h1, h2, h3, .logo span, .pricing-price .amount, .math-price, .step-number {
  font-family: 'Bricolage Grotesque', 'Inter', sans-serif;
  letter-spacing: -0.025em;
  font-weight: 800;
}

p {
  color: var(--text-secondary);
  line-height: 1.7;
}

/* === Selection === */
::selection {
  background: var(--accent);
  color: var(--bg-primary);
}

/* === Scrollbar === */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: 4px;
  transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-dark);
}

/* === Noise Overlay === */
.noise-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* === Focus Styles (Accessibility) === */
a:focus-visible,
button:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* === Links === */
a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--accent);
}

/* === Button Base === */
button,
.btn {
  font-family: inherit;
  cursor: pointer;
  border: none;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  text-decoration: none;
}

button:active,
.btn:active {
  transform: scale(0.98);
}

/* === Code === */
code,
.code {
  font-family: 'JetBrains Mono', 'Courier New', monospace;
  font-size: 0.9em;
  background: var(--frost-2);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--accent);
}

/* === Utility Classes === */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
