/* ============================================================
   AALIN — Base CSS
   Design tokens, reset, typography
   ============================================================ */

/* ── Custom Properties ── */
:root {
  /* Colors — meleg "paper / ink / champagne" arculat
     (referencia: magnificent-crisp paletta).
     A legsötétebb "ink" árnyalat csak szövegre/apró elemekre megy;
     a nagy sötét felületek a lágyabb --color-mocha (ink-soft). */
  --color-onyx:          #171411; /* ink – sötét szöveg, fejlécek, apró accent */
  --color-mocha:         #312a25; /* ink-soft – lágy sötét, csak apró elemekhez */
  --color-almond:        #8a715b; /* almond – meleg közepes barna */
  --color-almond-dark:   #5e4b3a; /* sötétebb almond – pl. gomb hover */
  --color-beige:         #b39d85; /* french beige – világos meleg drapp (nagy blokkok) */
  --color-walnut:        #766d62; /* muted – tompított szöveg */
  --color-vanilla:       #d9c6a8; /* meleg világos drapp – sötét háttéren szöveg */
  --color-sand:          #e7dac9; /* paper-warm – meleg világos felület */
  --color-cream:         #f3ecdf; /* paper – alap háttér */
  --color-white:         #fffaf2; /* meleg fehér */
  --color-gold:          #b4935c; /* champagne – fő accent */
  --color-gold-dark:     #7e6439; /* champagne-dark – mélyebb accent */
  --color-sage:          #75806d; /* zsálya – másodlagos accent */
  --color-concrete:      #9f9388; /* meleg szürke-drapp */
  --color-text:          #171411;
  --color-muted:         #766d62;

  /* Typography */
  --font-heading: 'Palatino Linotype', 'Book Antiqua', Palatino, 'Palatino LT STD', Georgia, serif;
  --font-body:    'Inter', 'Helvetica Neue', sans-serif;

  --text-xs:   clamp(0.75rem,  1.5vw, 0.875rem);
  --text-sm:   clamp(0.875rem, 1.8vw, 1rem);
  --text-base: clamp(1rem,     2vw,   1.125rem);
  --text-lg:   clamp(1.125rem, 2.5vw, 1.375rem);
  --text-xl:   clamp(1.375rem, 3vw,   1.75rem);
  --text-2xl:  clamp(1.75rem,  4vw,   2.5rem);
  --text-3xl:  clamp(2.5rem,   6vw,   4rem);
  --text-4xl:  clamp(3.5rem,   8vw,   6rem);
  --text-hero: clamp(4rem,     10vw,  8rem);

  --leading-tight:  1.1;
  --leading-snug:   1.3;
  --leading-normal: 1.6;
  --leading-loose:  1.8;

  --tracking-tight: -0.03em;
  --tracking-normal: 0;
  --tracking-wide:   0.08em;
  --tracking-widest: 0.15em;

  /* Spacing */
  --space-2xs: 0.25rem;
  --space-xs:  0.5rem;
  --space-sm:  0.75rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2rem;
  --space-2xl: 3rem;
  --space-3xl: 4.5rem;
  --space-4xl: 6rem;
  --space-5xl: 9rem;
  --space-6xl: 12rem;

  /* Layout */
  --container-sm:  640px;
  --container-md:  960px;
  --container-lg:  1280px;
  --container-xl:  1600px;
  --container-pad: clamp(1.25rem, 5vw, 4rem);

  /* Borders */
  --radius-sm: 2px;
  --radius-md: 4px;
  --radius-lg: 8px;

  /* Transitions */
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.87, 0, 0.13, 1);
  --ease-butter: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --duration-fast:   200ms;
  --duration-base:   400ms;
  --duration-slow:   700ms;
  --duration-slower: 1200ms;

  /* Z-index layers */
  --z-below:   -1;
  --z-base:     0;
  --z-raised:  10;
  --z-sticky:  50;
  --z-modal:  100;
  --z-cursor: 200;
}

/* ── Magyar ékezetes karakterek elővételezése ──
   A címbetű (Palatino Linotype) helyi rendszerfont, így külön letöltés nem kell;
   ez a rejtett elem ártalmatlanul biztosítja az ékezetes glyphek korai feloldását. */
body::before {
  content: 'ÁÉÍÓÖŐÚÜŰáéíóöőúüű';
  position: absolute;
  left: -9999px;
  font-family: var(--font-heading);
  font-size: 0;
  pointer-events: none;
  aria-hidden: true;
}

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

html {
  font-size: 16px;
  scroll-behavior: auto; /* Lenis handles smooth scroll */
  -webkit-text-size-adjust: 100%;
}

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

/* Lenis class */
html.lenis, html.lenis body {
  height: auto;
}
.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}
.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

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

img {
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

input, textarea, select {
  font-family: inherit;
}

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

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

p {
  max-width: 70ch;
  line-height: var(--leading-loose);
}

.eyebrow {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 400;
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  color: var(--color-walnut);
}

blockquote {
  font-family: var(--font-heading);
  font-size: var(--text-2xl);
  font-style: italic;
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-tight);
  color: var(--color-onyx);
}

/* ── Utility Classes ── */
.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;
}

.container {
  width: 100%;
  max-width: var(--container-lg);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.container--wide {
  max-width: var(--container-xl);
}

.container--narrow {
  max-width: var(--container-md);
}

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