/*
 * Base Styles
 * Typography, global styles, and noise texture overlay
 */

/* ===================================
   FONT IMPORTS - Google Fonts
   ================================= */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Dancing+Script:wght@400;700&display=swap');

/* ===================================
   BODY & GLOBAL STYLES
   ================================= */
body {
  font-family: var(--font-primary);
  font-size: var(--text-base);
  font-weight: var(--font-normal);
  line-height: var(--leading-relaxed);
  color: var(--color-gray-800);
  background-color: var(--color-white);
  position: relative;
  overflow-x: hidden;
}

/* ===================================
   NOISE TEXTURE OVERLAY
   Award-winning design technique
   ================================= */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' /%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' /%3E%3C/svg%3E");
  pointer-events: none;
  z-index: var(--z-50);
  mix-blend-mode: overlay;
}

/* ===================================
   TYPOGRAPHY - Headings
   ================================= */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-accent);
  font-weight: var(--font-bold);
  line-height: var(--leading-tight);
  color: var(--color-gray-900);
  margin-bottom: var(--space-4);
}

h1 {
  font-size: var(--text-5xl);
  letter-spacing: var(--tracking-normal);
  margin-bottom: var(--space-6);
}

h2 {
  font-size: var(--text-4xl);
  letter-spacing: var(--tracking-normal);
  margin-bottom: var(--space-5);
}

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

h4 {
  font-size: var(--text-2xl);
}

h5 {
  font-size: var(--text-xl);
}

h6 {
  font-size: var(--text-lg);
}

/* ===================================
   TYPOGRAPHY - Body Text
   ================================= */
p {
  margin-bottom: var(--space-4);
  color: var(--color-gray-700);
}

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

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

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

.tiny {
  font-size: var(--text-xs);
}

/* ===================================
   ACCENT TYPOGRAPHY
   Inter for section labels and accents
   ================================= */
.accent-text,
.section-label {
  font-family: var(--font-primary);
  color: var(--color-gold-600);
  font-weight: var(--font-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
}

.section-label {
  font-size: var(--text-sm);
  display: inline-block;
  margin-bottom: var(--space-3);
}

/* ===================================
   LINKS
   ================================= */
a {
  color: var(--color-teal-600);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-teal-700);
  text-decoration: underline;
}

a:focus-visible {
  outline: 2px solid var(--color-teal-500);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ===================================
   LISTS
   ================================= */
ul:not([class]),
ol:not([class]) {
  padding-left: var(--space-6);
  margin-bottom: var(--space-4);
}

ul:not([class]) {
  list-style-type: disc;
}

ol:not([class]) {
  list-style-type: decimal;
}

li:not([class]) {
  margin-bottom: var(--space-2);
  color: var(--color-gray-700);
}

/* ===================================
   BLOCKQUOTE
   ================================= */
blockquote {
  border-left: 4px solid var(--color-teal-500);
  padding-left: var(--space-6);
  padding-top: var(--space-3);
  padding-bottom: var(--space-3);
  margin: var(--space-6) 0;
  font-size: var(--text-lg);
  font-style: italic;
  color: var(--color-gray-600);
  background: var(--gradient-ocean);
  border-radius: var(--radius-md);
}

blockquote p {
  margin-bottom: var(--space-2);
}

blockquote cite {
  display: block;
  margin-top: var(--space-3);
  font-size: var(--text-sm);
  font-style: normal;
  font-weight: var(--font-medium);
  color: var(--color-gray-500);
}

blockquote cite::before {
  content: '— ';
}

/* ===================================
   CODE & PRE
   ================================= */
code {
  font-family: 'Monaco', 'Courier New', monospace;
  font-size: 0.9em;
  padding: var(--space-1) var(--space-2);
  background-color: var(--color-gray-100);
  border-radius: var(--radius-sm);
  color: var(--color-teal-700);
}

pre {
  background-color: var(--color-gray-900);
  color: var(--color-gray-100);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  overflow-x: auto;
  margin-bottom: var(--space-4);
}

pre code {
  background: transparent;
  padding: 0;
  color: inherit;
}

/* ===================================
   HORIZONTAL RULE
   ================================= */
hr {
  border: none;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    var(--color-teal-200),
    transparent
  );
  margin: var(--space-12) 0;
}

/* ===================================
   EMPHASIS & STRONG
   ================================= */
em {
  font-style: italic;
}

strong {
  font-weight: var(--font-bold);
  color: var(--color-gray-900);
}

/* ===================================
   SKIP TO CONTENT (Accessibility)
   ================================= */
.skip-to-content {
  position: absolute;
  top: var(--space-4);
  left: var(--space-4);
  background-color: var(--color-teal-600);
  color: var(--color-white);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-md);
  font-weight: var(--font-semibold);
  text-decoration: none;
  z-index: var(--z-tooltip);
  transform: translateY(-200%);
  transition: transform var(--transition-base);
}

.skip-to-content:focus {
  transform: translateY(0);
  outline: 2px solid var(--color-gold-500);
  outline-offset: 2px;
}

/* ===================================
   MAIN CONTENT AREA
   ================================= */
main {
  position: relative;
  z-index: var(--z-10);
}

/* ===================================
   SECTION SPACING
   ================================= */
section {
  padding-top: var(--section-padding-y);
  padding-bottom: var(--section-padding-y);
  position: relative;
}

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

/* Screen Reader Only */
.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;
}

/* Text Alignment */
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }

/* Text Colors */
.text-teal { color: var(--color-teal-600); }
.text-gold { color: var(--color-gold-600); }
.text-gray { color: var(--color-gray-600); }
.text-white { color: var(--color-white); }

/* Background Colors */
.bg-white { background-color: var(--color-white); }
.bg-gray-50 { background-color: var(--color-gray-50); }
.bg-teal-50 { background-color: var(--color-teal-50); }
.bg-gradient-ocean { background: var(--gradient-ocean); }

/* Font Weights */
.font-light { font-weight: var(--font-light); }
.font-normal { font-weight: var(--font-normal); }
.font-medium { font-weight: var(--font-medium); }
.font-semibold { font-weight: var(--font-semibold); }
.font-bold { font-weight: var(--font-bold); }

/* ===================================
   RESPONSIVE IMAGES
   ================================= */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity var(--transition-base);
}

img[loading="lazy"].loaded {
  opacity: 1;
}

/* ===================================
   SELECTION HIGHLIGHT
   ================================= */
::selection {
  background-color: var(--color-teal-200);
  color: var(--color-teal-900);
}

::-moz-selection {
  background-color: var(--color-teal-200);
  color: var(--color-teal-900);
}
