/**
 * Auvira Theme - Base Styles
 * 
 * Reset, typography, and foundational styles
 */

/* ==========================================================================
   RESET / NORMALIZE
   ========================================================================== */

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

* {
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: var(--font-normal);
  line-height: var(--leading-normal);
  color: var(--color-text-primary);
  background-color: var(--color-background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: none;
}

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* Remove default focus styles - we'll add custom ones */
:focus {
  outline: none;
}

/* Custom focus visible styles */
:focus-visible {
  outline: none;
}

/* ==========================================================================
   TYPOGRAPHY - HEADINGS
   ========================================================================== */

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--font-heading);
  font-weight: var(--font-bold);
  line-height: var(--leading-tight);
  color: var(--color-text-primary);
  letter-spacing: var(--tracking-tight);
}

h1, .h1 {
  font-size: var(--text-5xl);
  letter-spacing: var(--tracking-tighter);
}

h2, .h2 {
  font-size: var(--text-4xl);
}

h3, .h3 {
  font-size: var(--text-3xl);
}

h4, .h4 {
  font-size: var(--text-2xl);
  font-weight: var(--font-semibold);
}

h5, .h5 {
  font-size: var(--text-xl);
  font-weight: var(--font-semibold);
}

h6, .h6 {
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
}

/* Responsive heading sizes */
@media (max-width: 768px) {
  h1, .h1 {
    font-size: var(--text-4xl);
  }
  
  h2, .h2 {
    font-size: var(--text-3xl);
  }
  
  h3, .h3 {
    font-size: var(--text-2xl);
  }
}

/* ==========================================================================
   TYPOGRAPHY - BODY
   ========================================================================== */

p {
  margin-bottom: var(--space-4);
  line-height: var(--leading-relaxed);
}

p:last-child {
  margin-bottom: 0;
}

.lead {
  font-size: var(--text-xl);
  line-height: var(--leading-relaxed);
  color: var(--color-text-secondary);
}

small,
.small {
  font-size: var(--text-sm);
}

.text-muted {
  color: var(--color-text-muted);
}

.text-secondary {
  color: var(--color-text-secondary);
}

/* ==========================================================================
   TYPOGRAPHY - LINKS
   ========================================================================== */

a:not([class]) {
  color: var(--color-primary);
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 2px;
  transition: var(--transition-colors);
}

a:not([class]):hover {
  color: var(--color-primary-dark);
  text-decoration-color: currentColor;
}

/* ==========================================================================
   TYPOGRAPHY - LISTS
   ========================================================================== */

.content ul,
.content ol {
  margin-bottom: var(--space-4);
  padding-left: var(--space-6);
}

.content ul {
  list-style-type: disc;
}

.content ol {
  list-style-type: decimal;
}

.content li {
  margin-bottom: var(--space-2);
  line-height: var(--leading-relaxed);
}

.content li:last-child {
  margin-bottom: 0;
}

/* ==========================================================================
   TYPOGRAPHY - MISC
   ========================================================================== */

strong, b {
  font-weight: var(--font-semibold);
}

em, i {
  font-style: italic;
}

blockquote {
  border-left: 4px solid var(--color-primary);
  padding-left: var(--space-6);
  margin: var(--space-6) 0;
  font-style: italic;
  color: var(--color-text-secondary);
}

code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  background-color: var(--color-surface);
  padding: 0.2em 0.4em;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
}

pre {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  background-color: var(--color-charcoal);
  color: var(--color-off-white);
  padding: var(--space-4);
  border-radius: var(--radius-lg);
  overflow-x: auto;
  margin: var(--space-4) 0;
}

pre code {
  background: none;
  padding: 0;
  border: none;
  font-size: inherit;
}

hr {
  border: none;
  border-top: 1px solid var(--color-border);
  margin: var(--space-8) 0;
}

mark {
  background-color: var(--color-accent-light);
  padding: 0.1em 0.3em;
  border-radius: var(--radius-sm);
}

/* ==========================================================================
   SELECTION
   ========================================================================== */

::selection {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* ==========================================================================
   SCROLLBAR (Webkit) - Auvira Parent Site Only
   Each brand defines its own scrollbar styles via brand CSS
   ========================================================================== */

html.brand-auvira::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

html.brand-auvira::-webkit-scrollbar-track {
  background: var(--color-off-white);
}

html.brand-auvira::-webkit-scrollbar-thumb {
  background: var(--color-light-grey);
  border-radius: var(--radius-full);
}

html.brand-auvira::-webkit-scrollbar-thumb:hover {
  background: var(--color-medium-grey);
}

/* ==========================================================================
   UTILITY CLASSES
   ========================================================================== */

.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;
}

.not-sr-only {
  position: static;
  width: auto;
  height: auto;
  padding: 0;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

/* ==========================================================================
   WOOCOMMERCE OVERRIDES
   ========================================================================== */

/* Hide "View cart" link that appears after AJAX add-to-cart
   We use FunnelKit side cart instead */
.added_to_cart.wc-forward {
  display: none !important;
}
