/* ============================================================
   Aram Academy for Specialty Coffee Sciences
   Design tokens + base styles
   ============================================================ */

/* --- Thmanyah Serif Text (Arabic headings) --- */
@font-face {
  font-family: "Thmanyah Serif";
  src: url("fonts/thmanyahseriftext-Regular.otf") format("opentype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Serif";
  src: url("fonts/thmanyahseriftext-Medium.otf") format("opentype");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Serif";
  src: url("fonts/thmanyahseriftext-Bold.otf") format("opentype");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Serif";
  src: url("fonts/thmanyahseriftext-Black.otf") format("opentype");
  font-weight: 900; font-style: normal; font-display: swap;
}

/* --- Thmanyah Serif Display (Arabic large headings) --- */
@font-face {
  font-family: "Thmanyah Display";
  src: url("fonts/thmanyahserifdisplay-Regular.otf") format("opentype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Display";
  src: url("fonts/thmanyahserifdisplay-Medium.otf") format("opentype");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Display";
  src: url("fonts/thmanyahserifdisplay-Bold.otf") format("opentype");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Display";
  src: url("fonts/thmanyahserifdisplay-Black.otf") format("opentype");
  font-weight: 900; font-style: normal; font-display: swap;
}

/* --- Thmanyah Sans (Arabic UI / small text) --- */
@font-face {
  font-family: "Thmanyah Sans";
  src: url("fonts/thmanyahsans-Light.otf") format("opentype");
  font-weight: 300; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Sans";
  src: url("fonts/thmanyahsans-Regular.otf") format("opentype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Sans";
  src: url("fonts/thmanyahsans-Medium.otf") format("opentype");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Sans";
  src: url("fonts/thmanyahsans-Bold.otf") format("opentype");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Thmanyah Sans";
  src: url("fonts/thmanyahsans-Black.otf") format("opentype");
  font-weight: 900; font-style: normal; font-display: swap;
}

:root {
  /* --- Course-coding palette (from the 6 module cards) --- */
  --c-intro:   #828f9d;  /* Introduction to Coffee — slate  */
  --c-green:   #00b191;  /* Green Coffee — teal            */
  --c-roast:   #f05a24;  /* Roasting — orange              */
  --c-brew:    #24a7cd;  /* Brewing — cyan                 */
  --c-barista: #913373;  /* Barista Skills — magenta       */
  --c-sensory: #ecc811;  /* Sensory Skills — yellow        */
  --c-cupping: #26211c;  /* Cupping short courses — charcoal (matches Intro-to-Cupping badge) */

  /* --- Neutral, warm paper system --- */
  --paper:     #f4f1ea;
  --paper-2:   #ebe6db;
  --surface:   #ffffff;
  --ink:       #181613;
  --ink-2:     #3b372f;
  --muted:     #837c6f;
  --muted-2:   #a89f8e;
  --line:      #ddd6c8;
  --line-2:    #e8e2d6;

  /* accent that ties to the brand (roast orange) for CTAs by default */
  --accent:    #f05a24;
  --accent-ink:#ffffff;

  /* --- Type --- */
  --font-display: "Archivo", system-ui, sans-serif;
  --font-serif:   "Spectral", Georgia, serif;
  --font-mono:    "IBM Plex Mono", ui-monospace, monospace;

  /* --- Interaction style engine (driven by Tweaks) --- */
  --motion-dur: 0.42s;
  --motion-ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --motion-lift: 10px;     /* hover translateY */
  --motion-rot: 0deg;      /* hover rotate on cards */
  --motion-scale: 1.018;   /* hover scale */
  --motion-pop: 1;         /* multiplier for blob drift etc */

  /* --- Layout --- */
  --radius: 4px;
  --nav-h: 80px;
  --maxw: 1240px;
  --gut: clamp(20px, 4.5vw, 64px);
}

/* color-intensity = muted: soften the saturated palette a touch on large fills */
[data-intensity="muted"] {
  --c-intro:   #8b95a0;
  --c-green:   #3aa991;
  --c-roast:   #e07550;
  --c-brew:    #5aa9c6;
  --c-barista: #94567e;
  --c-sensory: #e3c84e;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-serif);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4, .display { font-family: var(--font-display); margin: 0; }

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }

::selection { background: var(--ink); color: var(--paper); }

/* ---- shared utilities ---- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gut); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 0.7em;
  font-weight: 500;
}
.eyebrow::before {
  content: "";
  width: 28px; height: 1px;
  background: currentColor;
  opacity: 0.5;
}

.tag-label {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 0.96;
}

/* big institutional headline */
.h-display {
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.0;
  font-size: clamp(32px, 4.4vw, 54px);
}
.section-head h2 { font-size: clamp(26px, 3.2vw, 40px); line-height: 1.08; }
.cta-band h2 { font-size: clamp(28px, 3.6vw, 46px); }

/* Arabic companion line under a large heading (Thmanyah Serif Display) */
.h-ar {
  display: block;
  font-family: "Thmanyah Display", var(--font-serif);
  font-weight: 700;
  direction: rtl;
  text-align: left;
  line-height: 1.28;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
  margin-top: 0.42em;
  font-size: clamp(20px, 2.6vw, 34px);
}
/* hero headline is much larger — scale its Arabic line up to match */
.hero h1 .h-ar { font-size: clamp(22px, 3vw, 40px); margin-top: 0.28em; }
/* centered CTA band */
.cta-band .h-ar { text-align: center; font-size: clamp(24px, 3.4vw, 46px); }

/* Arabic companion inside a small eyebrow label (Thmanyah Sans — UI optical size) */
.eyebrow .ar {
  font-family: "Thmanyah Sans", system-ui, sans-serif;
  direction: rtl;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  font-size: 1.25em;
  line-height: 1;
  color: inherit;
}
.eyebrow .ar::before {
  content: "";
  display: inline-block;
  width: 1px; height: 0.9em;
  background: currentColor;
  opacity: 0.4;
  margin-inline-end: 0.7em;
  vertical-align: -0.05em;
}

/* buttons */
.btn {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  padding: 14px 22px;
  border-radius: 100px;
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  transition: transform var(--motion-dur) var(--motion-ease),
              background var(--motion-dur) var(--motion-ease),
              color var(--motion-dur) var(--motion-ease);
}
.btn:hover { transform: translateY(-2px); }
.btn--ghost {
  background: transparent;
  color: var(--ink);
}
.btn--ghost:hover { background: var(--ink); color: var(--paper); }
.btn--accent {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.btn .arrow { transition: transform var(--motion-dur) var(--motion-ease); }
.btn:hover .arrow { transform: translateX(4px); }

/* section rhythm */
.section { padding: clamp(64px, 9vw, 132px) 0; }
.section-head { display: flex; flex-direction: column; gap: 18px; }

/* hairline divider */
.rule { height: 1px; background: var(--line); border: 0; margin: 0; }

/* fade-in on scroll */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s var(--motion-ease), transform 0.7s var(--motion-ease);
  transition-delay: var(--reveal-delay, 0s);
}
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; opacity: 1; transform: none; }
}
