/* ============================================
   PRANA IQ Base Styles
   ============================================ */

/* ============ RESET ============ */

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: var(--leading-relaxed);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

/* ============ ACCESSIBILITY ============ */

.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--color-blue);
  color: white;
  padding: var(--space-3) var(--space-4);
  z-index: var(--z-tooltip);
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============ TYPOGRAPHY ============ */

h1, h2, h3, h4, h5, h6 {
  font-weight: var(--font-normal);
  line-height: var(--leading-tight);
}

.display-xl {
  font-family: var(--font-serif);
  font-size: clamp(var(--text-5xl), 7vw, var(--text-7xl));
  line-height: 1.02;
  letter-spacing: var(--tracking-tighter);
  color: var(--color-navy);
}

.display-lg {
  font-family: var(--font-serif);
  font-size: clamp(var(--text-4xl), 5vw, var(--text-5xl));
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--color-navy);
}

.heading-1 {
  font-family: var(--font-serif);
  font-size: clamp(26px, 3.5vw, 38px);
  letter-spacing: var(--tracking-tight);
  color: var(--color-navy);
}

.heading-2 {
  font-family: var(--font-sans);
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  color: var(--color-navy);
}

.heading-3 {
  font-family: var(--font-sans);
  font-size: 17px;
  font-weight: var(--font-bold);
  color: var(--color-navy);
}

.body-lg {
  font-size: clamp(var(--text-md), 1.8vw, 19px);
  line-height: var(--leading-relaxed);
  color: var(--color-text-secondary);
}

.body {
  font-size: var(--text-md);
  line-height: var(--leading-loose);
  color: var(--color-text-secondary);
}

.body-sm {
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: var(--color-text-muted);
}

.caption {
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.mono {
  font-family: var(--font-mono);
  font-size: var(--text-base);
}

.text-blue { color: var(--color-blue); }
.text-orange { color: var(--color-orange); }
.text-teal { color: var(--color-teal); }
.text-muted { color: var(--color-text-muted); }

.italic { font-style: italic; }
.bold { font-weight: var(--font-bold); }

/* ============ LAYOUT ============ */

.page-section {
  padding: 0 var(--page-padding);
  max-width: var(--max-width);
  margin: 0 auto;
}

.section-narrow {
  max-width: var(--max-width-narrow);
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--page-padding);
}

/* ============ FOCUS STATES ============ */

:focus-visible {
  outline: 2px solid var(--color-blue);
  outline-offset: 2px;
}

button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--color-blue);
  outline-offset: 2px;
}

/* ============ SELECTION ============ */

::selection {
  background: var(--color-blue-pale);
  color: var(--color-navy);
}

/* ============ ANIMATIONS ============ */

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.6;
    transform: scale(0.85);
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-10px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.5s ease-out;
}

.animate-fade-in-up {
  animation: fadeInUp 0.7s ease-out both;
}

.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }
.animate-delay-5 { animation-delay: 0.5s; }

/* ============ UTILITIES ============ */

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }

.grid { display: grid; }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mx-auto { margin-left: auto; margin-right: auto; }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

.w-full { width: 100%; }
.max-w-prose { max-width: 65ch; }

.relative { position: relative; }
.absolute { position: absolute; }
.sticky { position: sticky; }

.hidden { display: none; }

@media (max-width: 768px) {
  .md\:hidden { display: none; }
  .md\:block { display: block; }
  .md\:flex { display: flex; }
}

@media (min-width: 769px) {
  .lg\:hidden { display: none; }
  .lg\:block { display: block; }
  .lg\:flex { display: flex; }
}
