/* ═══════════════════════════════════════════════════════════════
   EASYTRIP HUB — BASE
   Reset, typography, layout primitives, motion primitives.
   ═══════════════════════════════════════════════════════════════ */

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

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

body {
  font-family: var(--font-body);
  font-size: var(--text-body);
  font-weight: 400;
  line-height: 1.7;
  color: var(--ink-soft);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { color: inherit; text-decoration: none; }
button { font: inherit; border: none; background: none; cursor: pointer; color: inherit; }
ul, ol { list-style: none; }
summary { cursor: pointer; }

::selection { background: var(--accent); color: #fff; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── Typography ─────────────────────────────────────────────── */

h1, h2, h3, .display {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.08;
  color: var(--ink);
  letter-spacing: -0.01em;
}

h1 { font-size: var(--text-h1); }
h2 { font-size: var(--text-h2); }
h3 { font-size: var(--text-h3); line-height: 1.2; }

h4 {
  font-family: var(--font-body);
  font-size: var(--text-h4);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
}

.display-hero { font-size: var(--text-hero); line-height: 1.02; }

.display i, h1 i, h2 i, h3 i {
  font-style: italic;
  font-weight: 500;
  line-height: 1.12;            /* descender clearance for italics */
  padding-bottom: 0.06em;
  color: var(--accent);
}

.lead {
  font-size: var(--text-lead);
  line-height: 1.65;
  max-width: 58ch;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow::before {
  content: '';
  width: 26px;
  height: 1.5px;
  background: var(--accent);
}

.small  { font-size: var(--text-small); }
.faint  { color: var(--ink-faint); }
.strong { font-weight: 700; color: var(--ink); }

/* ── Layout primitives ──────────────────────────────────────── */

.container {
  width: 100%;
  max-width: calc(var(--content-width) + var(--content-padding) * 2);
  margin-inline: auto;
  padding-inline: var(--content-padding);
}

.container-narrow {
  width: 100%;
  max-width: calc(var(--content-narrow) + var(--content-padding) * 2);
  margin-inline: auto;
  padding-inline: var(--content-padding);
}

.section { padding-block: var(--space-section); }
.section-wash { background: var(--wash); }

.section-head { max-width: 640px; margin-bottom: var(--space-block); }
.section-head h2 { margin-top: 0.75rem; }
.section-head .lead { margin-top: 1.1rem; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head.center .lead { margin-inline: auto; }

.grid { display: grid; gap: var(--space-element); }

/* ── Icon sizing ────────────────────────────────────────────── */

.icon { width: 22px; height: 22px; flex: none; }
.icon svg { width: 100%; height: 100%; }
.icon-lg { width: 30px; height: 30px; }
.icon-sm { width: 17px; height: 17px; }

/* ── Motion: scroll reveal (IntersectionObserver adds .visible) ─ */

.reveal {
  opacity: 0;
  transform: translateY(34px);
  transition:
    opacity 0.85s var(--ease-signature),
    transform 0.85s var(--ease-signature);
}
.reveal.visible { opacity: 1; transform: none; }

.reveal-scale {
  opacity: 0;
  transform: scale(0.96) translateY(20px);
  transition:
    opacity 0.9s var(--ease-signature),
    transform 0.9s var(--ease-signature);
}
.reveal-scale.visible { opacity: 1; transform: none; }

.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.16s; }
.reveal-d3 { transition-delay: 0.24s; }
.reveal-d4 { transition-delay: 0.32s; }

/* ── Keyframes ──────────────────────────────────────────────── */

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(36px); }
  to   { opacity: 1; transform: none; }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes marqueeLeft {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@keyframes marqueeRight {
  from { transform: translateX(-50%); }
  to   { transform: translateX(0); }
}
@keyframes dashFlow {
  to { stroke-dashoffset: -240; }
}
@keyframes floatSoft {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

/* Hero load-in cascade */
.hero-in {
  opacity: 0;
  animation: fadeInUp 1s var(--ease-signature) forwards;
}
.hero-in-1 { animation-delay: 0.05s; }
.hero-in-2 { animation-delay: 0.18s; }
.hero-in-3 { animation-delay: 0.31s; }
.hero-in-4 { animation-delay: 0.44s; }

/* ── Reduced motion: collapse everything ────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal, .reveal-scale, .hero-in { opacity: 1 !important; transform: none !important; }
  .marquee-track { animation: none !important; }
}
