/*
 * Emna Hussein — base styles.
 * Reset + typography + layout primitives shared by every component.
 * Namespace: `eh-*` only, to avoid any collision with legacy
 * `pxl-*` / `elementor-*` vendor classes still loaded on untouched pages.
 */

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

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

body.eh-body {
  margin: 0;
  background: var(--color-cream);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: var(--text-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--color-ink);
  letter-spacing: -0.005em;
}
h1 { font-size: var(--text-h1); line-height: 1.08; letter-spacing: -0.01em; }
h2 { font-size: var(--text-h2); line-height: 1.12; }
h3 { font-size: var(--text-h3); font-weight: 500; line-height: 1.2; letter-spacing: normal; }
h4 { font-size: var(--text-h4); font-weight: 500; line-height: 1.3; letter-spacing: normal; }

p { margin: 0 0 var(--space-4); max-width: 42rem; }
p:last-child { margin-bottom: 0; }

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

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
}

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

ul, ol { margin: 0; padding: 0; list-style: none; }

/* ---- Layout primitives ---- */

.eh-container {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-gutter);
}

.eh-section {
  padding-block: var(--space-8);
}
@media (min-width: 768px) {
  .eh-section { padding-block: var(--space-9); }
}
@media (min-width: 1280px) {
  .eh-section { padding-block: var(--section-pad); }
}
.eh-section--tight { padding-block: var(--space-6); }
.eh-section--dark { background: var(--color-ink); color: var(--color-cream); }
.eh-section--dark h1, .eh-section--dark h2, .eh-section--dark h3, .eh-section--dark h4 { color: var(--color-cream); }
.eh-section--sand { background: var(--color-sand); }

.eh-grid {
  display: grid;
  gap: var(--space-5);
}
@media (min-width: 992px) {
  .eh-grid { gap: var(--space-6); }
}
.eh-grid--2 { grid-template-columns: repeat(1, 1fr); }
.eh-grid--3 { grid-template-columns: repeat(1, 1fr); }
.eh-grid--4 { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 768px) {
  .eh-grid--2 { grid-template-columns: repeat(2, 1fr); }
  .eh-grid--3 { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1200px) {
  .eh-grid--4 { grid-template-columns: repeat(4, 1fr); }
}

/* ---- Type utilities ---- */

.eh-display {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: var(--text-display);
  line-height: 1.02;
  letter-spacing: -0.01em;
  margin: 0;
}

.eh-eyebrow {
  display: inline-block;
  font-family: var(--font-label);
  font-weight: 500;
  font-size: var(--text-eyebrow);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-gold-deep);
}

.eh-quote {
  font-family: var(--font-accent);
  font-style: italic;
  font-weight: 400;
  font-size: var(--text-quote);
  line-height: 1.4;
  max-width: 48rem;
  margin-inline: auto;
}

.eh-lede {
  font-size: var(--text-body-lg);
  color: var(--color-text-muted);
  max-width: 34rem;
}

.eh-caption { font-size: var(--text-caption); color: var(--color-text-muted); }

.eh-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;
}

/* ---- Links ---- */

.eh-link {
  position: relative;
  display: inline-block;
  font-family: var(--font-label);
  font-size: var(--text-button);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.eh-link::after {
  content: '';
  position: absolute;
  left: 0; bottom: -2px;
  width: 100%; height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--duration-base) ease-out;
}
.eh-link:hover::after { transform: scaleX(1); }

/* ---- Buttons ---- */

.eh-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-family: var(--font-label);
  font-size: var(--text-button);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: 1px solid currentColor;
  background: transparent;
  color: var(--color-ink);
  transition: background var(--duration-base) ease, color var(--duration-base) ease, border-color var(--duration-base) ease;
}
.eh-btn:hover { background: var(--color-ink); color: var(--color-cream); }

.eh-btn--on-dark { color: var(--color-cream); }
.eh-btn--on-dark:hover { background: var(--color-cream); color: var(--color-ink); }

.eh-btn--solid { background: var(--color-ink); color: var(--color-cream); border-color: var(--color-ink); }
.eh-btn--solid:hover { background: transparent; color: var(--color-ink); }

.eh-btn--gold { border-color: var(--color-gold); color: var(--color-gold-deep); }
.eh-btn--gold:hover { background: var(--color-gold); color: var(--color-ink); border-color: var(--color-gold); }

.eh-btn--full { width: 100%; }

/* ---- Forms ---- */

.eh-field { display: flex; flex-direction: column; gap: var(--space-2); margin-bottom: var(--space-5); }
.eh-field label {
  font-family: var(--font-label);
  font-size: var(--text-eyebrow);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.eh-field input,
.eh-field select,
.eh-field textarea {
  font-family: var(--font-body);
  font-size: var(--text-body);
  color: var(--color-ink);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--color-stone);
  padding: var(--space-2) 0;
  transition: border-color var(--duration-base) ease;
}
.eh-field input:focus,
.eh-field select:focus,
.eh-field textarea:focus { border-color: var(--color-gold); outline: none; }
.eh-field textarea { resize: vertical; min-height: 7rem; }

/* ---- Image frames (cropping discipline) ---- */

.eh-frame { position: relative; overflow: hidden; background: var(--color-sand); }
.eh-frame img, .eh-frame video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.eh-frame--4-5 { aspect-ratio: 4 / 5; }
.eh-frame--3-4 { aspect-ratio: 3 / 4; }
.eh-frame--1-1 { aspect-ratio: 1 / 1; }
.eh-frame--16-9 { aspect-ratio: 16 / 9; }

/* ---- Scroll reveal ---- */

.eh-reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity var(--duration-slower) var(--ease-out-soft), transform var(--duration-slower) var(--ease-out-soft);
}
.eh-reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .eh-reveal { opacity: 1; transform: none; transition: none; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ---- Divider ---- */

.eh-rule { border: none; border-top: 1px solid var(--color-stone); opacity: 0.4; margin: 0; }
.eh-rule--gold { width: 40px; height: 2px; border: none; background: var(--color-gold); margin-inline: auto; }
