/* ============================================
   IIFIS — Base Styles & Typography
   ============================================ */

/* ── Modern CSS Reset ── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: var(--nav-height);
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: var(--leading-tight);
  color: var(--color-primary);
  letter-spacing: var(--tracking-tight);
}

h1 {
  font-size: var(--text-6xl);
  margin-bottom: var(--space-6);
}

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

h3 {
  font-size: var(--text-3xl);
  font-family: var(--font-body);
  font-weight: 600;
  margin-bottom: var(--space-4);
}

h4 {
  font-size: var(--text-2xl);
  font-family: var(--font-body);
  font-weight: 600;
  margin-bottom: var(--space-3);
}

h5 {
  font-size: var(--text-xl);
  font-family: var(--font-body);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

h6 {
  font-size: var(--text-lg);
  font-family: var(--font-body);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

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

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

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

a:hover {
  color: var(--color-secondary);
}

strong, b {
  font-weight: 600;
}

ul, ol {
  list-style: none;
}

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

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

/* ── Selection ── */
::selection {
  background: rgba(201, 162, 39, 0.2);
  color: var(--color-primary);
}

/* ── Focus Styles ── */
:focus-visible {
  outline: 2px solid var(--color-secondary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ── Scrollbar ── */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--color-accent);
}

::-webkit-scrollbar-thumb {
  background: var(--color-primary-light);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}

/* ── Utility Classes ── */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-primary { color: var(--color-primary); }
.text-secondary { color: var(--color-secondary); }
.text-muted { color: var(--color-text-muted); }
.text-white { color: var(--color-text-light); }

.text-uppercase {
  text-transform: uppercase;
  letter-spacing: var(--tracking-widest);
  font-size: var(--text-sm);
  font-weight: 600;
}

.font-heading { font-family: var(--font-heading); }
.font-body { font-family: var(--font-body); }

.fw-400 { font-weight: 400; }
.fw-500 { font-weight: 500; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }

/* ── Section Title ── */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  text-transform: uppercase;
  letter-spacing: var(--tracking-widest);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-secondary);
  margin-bottom: var(--space-4);
}

.section-label::before {
  content: '';
  width: 32px;
  height: 2px;
  background: var(--color-secondary);
  border-radius: var(--radius-full);
}

.section-title {
  font-size: var(--text-4xl);
  color: var(--color-primary);
  margin-bottom: var(--space-4);
  max-width: 700px;
}

.section-subtitle {
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  max-width: 640px;
  line-height: var(--leading-relaxed);
}

.section-header {
  margin-bottom: var(--space-12);
}

.section-header.centered {
  text-align: center;
}

.section-header.centered .section-title,
.section-header.centered .section-subtitle {
  margin-left: auto;
  margin-right: auto;
}

/* ── Gold Divider ── */
.gold-divider {
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-secondary), var(--color-secondary-light));
  border-radius: var(--radius-full);
  margin: var(--space-4) 0;
}

.centered .gold-divider {
  margin-left: auto;
  margin-right: auto;
}

/* ── Animations ── */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-left {
  opacity: 0;
  transform: translateX(-24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.fade-in-right {
  opacity: 0;
  transform: translateX(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

.scale-in {
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.scale-in.visible {
  opacity: 1;
  transform: scale(1);
}

/* ── Stagger Delays ── */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }
.delay-5 { transition-delay: 0.5s; }
.delay-6 { transition-delay: 0.6s; }
