/* ==========================================================================
   Base Styles, Reset & Modern Cooperative Typography
   ========================================================================== */

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
  max-width: 100%;
  width: 100%;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.8;
  font-weight: 400;
  overflow-x: clip;
  max-width: 100%;
  width: 100%;
  position: relative;
}

/* Devanagari numerals and script optimization */
[lang="ne"], .lang-ne {
  font-feature-settings: "kern" 1, "liga" 1;
}

/* Headings with balanced breathing space */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--navy-900);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2rem, 3.8vw + 0.8rem, 3.25rem); font-weight: 800; margin-bottom: var(--space-4); }
h2 { font-size: clamp(1.65rem, 2.4vw + 0.4rem, 2.35rem); font-weight: 800; margin-bottom: var(--space-3); }
h3 { font-size: clamp(1.25rem, 1.5vw + 0.4rem, 1.65rem); margin-bottom: var(--space-2); }
h4 { font-size: 1.2rem; margin-bottom: var(--space-2); }
h5 { font-size: 1.05rem; }
h6 { font-size: 0.95rem; }

p {
  margin-bottom: 1.25rem;
  color: var(--text-secondary);
  line-height: 1.8;
}

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

a {
  color: var(--primary-600);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--primary-700);
}

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

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: 1rem;
  color: inherit;
  border: none;
  outline: none;
  background: none;
}

button {
  cursor: pointer;
}

/* Layout Containers */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding);
  padding-right: var(--container-padding);
  box-sizing: border-box;
  min-width: 0;
}

.container-narrow {
  max-width: var(--container-narrow);
  box-sizing: border-box;
  min-width: 0;
}

/* Section Header Structure */
.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto var(--space-12) auto;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.9rem;
  background-color: var(--primary-50);
  color: var(--primary-700);
  border: 1px solid var(--primary-200);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: var(--space-3);
}

.section-tag.tag-gold {
  background-color: var(--accent-50);
  color: var(--accent-700);
  border-color: var(--accent-200);
}

.section-tag.tag-navy {
  background-color: var(--navy-50);
  color: var(--navy-800);
  border-color: var(--navy-200);
}

.section-title {
  color: var(--navy-900);
  margin-bottom: var(--space-3);
  position: relative;
}

.section-title span.highlight {
  color: var(--primary-600);
  position: relative;
}

.section-title span.highlight::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 0;
  width: 100%;
  height: 6px;
  background: var(--accent-300);
  opacity: 0.45;
  z-index: -1;
  border-radius: 4px;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Section Spacing */
.section-py {
  padding-top: clamp(3.5rem, 6vw, 6.5rem);
  padding-bottom: clamp(3.5rem, 6vw, 6.5rem);
}

.section-py-sm {
  padding-top: clamp(2rem, 4vw, 3.5rem);
  padding-bottom: clamp(2rem, 4vw, 3.5rem);
}

.bg-white {
  background-color: var(--bg-surface);
}

.bg-subtle {
  background-color: var(--bg-subtle);
}

.bg-navy {
  background-color: var(--navy-900);
  color: var(--text-light);
}

.bg-emerald {
  background-color: var(--primary-700);
  color: var(--text-light);
}

/* Accessibility & Utility */
.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;
}

:focus-visible {
  outline: 2.5px solid var(--accent-500);
  outline-offset: 3px;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 9px;
  height: 9px;
}
::-webkit-scrollbar-track {
  background: #f1f5f3;
}
::-webkit-scrollbar-thumb {
  background: #a7b8b0;
  border-radius: 6px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary-600);
}

/* ==========================================================================
   Inner Pages - Standardized Page Hero Banner & Breadcrumbs
   ========================================================================== */
.page-hero-banner {
  background: linear-gradient(135deg, #031233 0%, #08399f 100%);
  color: #ffffff;
  padding: clamp(2.5rem, 5vw, 4rem) 0 clamp(2rem, 4vw, 3.25rem) 0;
  position: relative;
  overflow: hidden;
  border-bottom: 4px solid var(--secondary-500, #01a755);
}

.page-hero-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(8, 57, 159, 0.35) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.page-hero-title {
  color: #ffffff;
  font-size: clamp(1.85rem, 3.5vw, 2.75rem);
  font-weight: 800;
  margin-bottom: 0.75rem;
  letter-spacing: -0.01em;
}

.page-hero-subtitle {
  color: #cbd5e1;
  font-size: clamp(0.95rem, 1.4vw, 1.15rem);
  max-width: 780px;
  line-height: 1.75;
  margin-bottom: 1.25rem;
}

.breadcrumb-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 0.9rem;
  color: #94a3b8;
}

.breadcrumb-nav a {
  color: #e2e8f0;
  text-decoration: none;
  transition: color 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.breadcrumb-nav a:hover {
  color: var(--brand-cyan);
}

.breadcrumb-separator {
  color: #64748b;
  font-size: 0.8rem;
}

.breadcrumb-current {
  color: #a7f3d0;
  font-weight: 600;
}
