/* ===========================
   CSS CUSTOM PROPERTIES
   =========================== */
:root {
  /* Color Palette - Neutrals with High-Contrast CTAs */
  --color-primary: #2563eb;
  --color-primary-dark: #1e40af;
  --color-primary-light: #3b82f6;
  --color-accent: #f59e0b;
  --color-accent-dark: #d97706;

  --color-text-primary: #1f2937;
  --color-text-secondary: #4b5563;
  --color-text-light: #6b7280;

  --color-bg-primary: #ffffff;
  --color-bg-secondary: #f9fafb;
  --color-bg-tertiary: #f3f4f6;
  --color-bg-dark: #111827;

  --color-border: #e5e7eb;
  --color-border-light: #f3f4f6;

  /* Typography */
  --font-primary: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --spacing-xl: 3rem;
  --spacing-2xl: 4rem;
  --spacing-3xl: 6rem;

  /* Layout */
  --container-width: 1000px;
  --border-radius: 8px;
  --border-radius-lg: 12px;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-medium: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* ===========================
   CSS RESET & BASE STYLES
   =========================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-primary);
  color: var(--color-text-primary);
  background-color: var(--color-bg-primary);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ===========================
   SCROLL PROGRESS BAR
   =========================== */
.scroll-progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  width: 0%;
  z-index: 9999;
  transition: width 0.1s ease;
  box-shadow: 0 0 10px rgba(37, 99, 235, 0.5);
}

/* ===========================
   HERO SECTION
   =========================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.3) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.3) 0%, transparent 50%),
    linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  will-change: transform;
}

.hero-decoration {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100px;
  background: var(--color-bg-primary);
  clip-path: polygon(0 50%, 100% 0, 100% 100%, 0 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: var(--spacing-xl) var(--spacing-lg);
}

.hero-text {
  max-width: 800px;
  margin: 0 auto;
}

.fade-in {
  animation: fadeInUp 1s ease forwards;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  color: white;
  margin-bottom: var(--spacing-md);
  line-height: 1.2;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
  letter-spacing: -0.02em;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: var(--spacing-xl);
  line-height: 1.6;
  font-weight: 400;
}

.hero-cta {
  margin-top: var(--spacing-xl);
}

.btn-scroll {
  display: inline-block;
  padding: 1rem 2.5rem;
  background: white;
  color: var(--color-primary);
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1rem;
  box-shadow: var(--shadow-xl);
  transition: all var(--transition-medium);
  position: relative;
  overflow: hidden;
}

.btn-scroll::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s ease;
}

.btn-scroll:hover::before {
  left: 100%;
}

.btn-scroll:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.btn-scroll:active {
  transform: translateY(-1px) scale(1.02);
}

/* ===========================
   CONTAINER & LAYOUT
   =========================== */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

.content-wrapper {
  background-color: var(--color-bg-primary);
}

/* ===========================
   ARTICLE CONTENT
   =========================== */
.article-content {
  padding: var(--spacing-3xl) 0;
}

.content-section {
  margin-bottom: var(--spacing-3xl);
}

.intro-section {
  margin-bottom: var(--spacing-3xl);
}

/* ===========================
   TYPOGRAPHY
   =========================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.3;
  color: var(--color-text-primary);
  margin-bottom: var(--spacing-md);
  letter-spacing: -0.01em;
}

h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  margin-top: var(--spacing-xl);
  position: relative;
  padding-bottom: var(--spacing-sm);
}

h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  border-radius: 2px;
}

h3 {
  font-size: clamp(1.3rem, 3vw, 1.75rem);
  margin-top: var(--spacing-lg);
  color: var(--color-text-primary);
}

p {
  margin-bottom: var(--spacing-md);
  color: var(--color-text-secondary);
  font-size: 1.1rem;
}

.lead-paragraph {
  font-size: clamp(1.2rem, 2.5vw, 1.4rem);
  line-height: 1.8;
  color: var(--color-text-primary);
  font-weight: 400;
  margin-bottom: var(--spacing-lg);
}

/* ===========================
   LISTS
   =========================== */
ol, ul {
  margin-bottom: var(--spacing-md);
  padding-left: var(--spacing-lg);
}

li {
  margin-bottom: var(--spacing-sm);
  color: var(--color-text-secondary);
  font-size: 1.1rem;
  line-height: 1.7;
}

.styled-list {
  list-style: none;
  counter-reset: list-counter;
  padding-left: 0;
}

.styled-list li {
  counter-increment: list-counter;
  position: relative;
  padding-left: var(--spacing-xl);
  margin-bottom: var(--spacing-md);
}

.styled-list li::before {
  content: counter(list-counter);
  position: absolute;
  left: 0;
  top: 0;
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-light));
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  box-shadow: var(--shadow-md);
}

/* ===========================
   HIGHLIGHT BOX
   =========================== */
.highlight-box {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
  border-left: 4px solid var(--color-primary);
  padding: var(--spacing-lg);
  margin: var(--spacing-xl) 0;
  border-radius: var(--border-radius);
  position: relative;
  overflow: hidden;
  transition: all var(--transition-medium);
}

.highlight-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.03) 0%, rgba(139, 92, 246, 0.03) 100%);
  opacity: 0;
  transition: opacity var(--transition-medium);
}

.highlight-box:hover::before {
  opacity: 1;
}

.highlight-box:hover {
  transform: translateX(5px);
  box-shadow: var(--shadow-lg);
}

.highlight-box p {
  margin-bottom: 0;
  font-style: italic;
  color: var(--color-text-primary);
  font-size: 1.15rem;
  position: relative;
  z-index: 1;
}

/* ===========================
   ANIMATION ON SCROLL
   =========================== */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===========================
   CTA SECTION
   =========================== */
.cta-section {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: var(--spacing-3xl) 0;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(circle at 80% 20%, rgba(99, 102, 241, 0.3) 0%, transparent 50%),
    radial-gradient(circle at 20% 80%, rgba(139, 92, 246, 0.3) 0%, transparent 50%);
  pointer-events: none;
}

.cta-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-2xl);
  align-items: center;
  position: relative;
  z-index: 1;
}

.cta-text {
  color: white;
}

.cta-title {
  font-size: clamp(2rem, 4vw, 3rem);
  color: white;
  margin-bottom: var(--spacing-md);
  font-weight: 800;
}

.cta-title::after {
  background: linear-gradient(90deg, white, rgba(255, 255, 255, 0.5));
}

.cta-description {
  font-size: 1.2rem;
  line-height: 1.8;
  margin-bottom: var(--spacing-lg);
  color: rgba(255, 255, 255, 0.95);
}

.cta-highlights {
  list-style: none;
  padding: 0;
  margin: var(--spacing-lg) 0;
}

.cta-highlights li {
  padding-left: var(--spacing-lg);
  margin-bottom: var(--spacing-sm);
  position: relative;
  color: rgba(255, 255, 255, 0.95);
  font-size: 1.1rem;
}

.cta-highlights li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-weight: 700;
  font-size: 1.3rem;
}

.cta-profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-lg);
}

.profile-image-wrapper {
  position: relative;
  width: 250px;
  height: 250px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 0 0 10px rgba(255, 255, 255, 0.1), var(--shadow-xl);
  transition: all var(--transition-medium);
}

.profile-image-wrapper:hover {
  transform: scale(1.05) rotate(2deg);
  box-shadow: 0 0 0 15px rgba(255, 255, 255, 0.15), 0 30px 60px -15px rgba(0, 0, 0, 0.3);
}

.profile-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-medium);
}

.profile-image-wrapper:hover .profile-image {
  transform: scale(1.1);
}

.cta-button {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: 1.2rem 2.5rem;
  background: white;
  color: var(--color-primary);
  text-decoration: none;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1.2rem;
  box-shadow: var(--shadow-xl);
  transition: all var(--transition-medium);
  position: relative;
  overflow: hidden;
}

.cta-button::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(37, 99, 235, 0.1);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s ease, height 0.6s ease;
}

.cta-button:hover::before {
  width: 400px;
  height: 400px;
}

.cta-button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.3);
}

.cta-button:active {
  transform: translateY(0) scale(1);
}

.arrow-icon {
  transition: transform var(--transition-fast);
  position: relative;
  z-index: 1;
}

.cta-button:hover .arrow-icon {
  transform: translateX(5px);
  animation: arrowBounce 0.6s ease infinite;
}

@keyframes arrowBounce {
  0%, 100% {
    transform: translateX(5px);
  }
  50% {
    transform: translateX(10px);
  }
}

/* ===========================
   FOOTER
   =========================== */
.site-footer {
  background-color: var(--color-bg-dark);
  color: rgba(255, 255, 255, 0.7);
  padding: var(--spacing-lg) 0;
  text-align: center;
}

.site-footer p {
  margin: 0;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

/* ===========================
   RESPONSIVE DESIGN
   =========================== */
@media (max-width: 1024px) {
  :root {
    --spacing-xl: 2.5rem;
    --spacing-2xl: 3.5rem;
    --spacing-3xl: 5rem;
  }
}

@media (max-width: 768px) {
  .cta-content {
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
    text-align: center;
  }

  .cta-text {
    order: 2;
  }

  .cta-profile {
    order: 1;
  }

  .profile-image-wrapper {
    width: 200px;
    height: 200px;
  }

  h2::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .cta-title::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .highlight-box:hover {
    transform: translateX(0);
  }
}

@media (max-width: 480px) {
  :root {
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 2.5rem;
    --spacing-3xl: 3rem;
  }

  .hero-content {
    padding: var(--spacing-lg);
  }

  .btn-scroll {
    padding: 0.9rem 2rem;
    font-size: 1rem;
  }

  .cta-button {
    padding: 1rem 2rem;
    font-size: 1.1rem;
  }

  .profile-image-wrapper {
    width: 180px;
    height: 180px;
  }

  p {
    font-size: 1.05rem;
  }

  .lead-paragraph {
    font-size: 1.15rem;
  }
}

/* ===========================
   PRINT STYLES
   =========================== */
@media print {
  .scroll-progress-bar,
  .hero,
  .cta-section,
  .site-footer,
  .btn-scroll {
    display: none;
  }

  body {
    font-size: 12pt;
    line-height: 1.5;
    color: black;
  }

  .article-content {
    padding: 0;
  }

  h2, h3 {
    page-break-after: avoid;
  }

  p {
    orphans: 3;
    widows: 3;
  }

  .highlight-box {
    border: 1pt solid black;
    page-break-inside: avoid;
  }
}

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

/* Focus styles for keyboard navigation */
a:focus,
button:focus {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  :root {
    --color-text-primary: #000000;
    --color-text-secondary: #000000;
    --color-border: #000000;
  }
}
