/* ============================================================
   SIGHT — base: tokens, reset, typography, primitives
   ============================================================ */

:root {
  --ink: #1c1713;
  --ink-soft: #40362e;
  --espresso: #221a14;
  --paper: #fbf8f2;
  --cream: #f5efe4;
  --sand: #e9decd;
  --sand-deep: #ddcdb6;
  --terracotta: #b96d50;
  --clay: #9c5139;
  --gold: #b99a62;
  --gold-light: #d8bd8a;
  --white: #fffdf9;
  --line: rgba(28, 23, 19, 0.13);
  --line-light: rgba(251, 248, 242, 0.18);
  --muted: #796d62;

  --font-en: "Inter", "Segoe UI", sans-serif;
  --font-serif: "Cormorant Garamond", Georgia, serif;
  --font-ar: "Tajawal", "Segoe UI", sans-serif;
  --font-script: "Aref Ruqaa", serif;

  --container: 1480px;
  --gutter: clamp(18px, 4vw, 64px);
  --section-y: clamp(84px, 10vw, 150px);
  --header-h: 76px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
  --shadow-soft: 0 24px 70px rgba(37, 25, 16, 0.12);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 26px);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

html[lang="ar"] {
  --font-body: var(--font-ar);
}

html[lang="en"] {
  --font-body: var(--font-en);
}

body {
  margin: 0;
  min-width: 300px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

body.overlay-open {
  overflow: hidden;
}

html[lang="ar"] body {
  letter-spacing: 0;
}

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

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: var(--cream);
}
::-webkit-scrollbar-thumb {
  background: #bbaa95;
  border: 3px solid var(--cream);
  border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--clay);
}

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

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

button,
input {
  font: inherit;
  color: inherit;
}

button {
  border: 0;
  background: none;
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.4;
}

h1, h2, h3, h4, p, figure, blockquote {
  margin: 0;
}

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

svg {
  display: block;
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  inset-inline-start: 16px;
  top: -100px;
  z-index: 1000;
  padding: 12px 20px;
  color: var(--paper);
  background: var(--ink);
  border-radius: 2px;
  transition: top 0.25s var(--ease);
}
.skip-link:focus {
  top: 16px;
}

/* ---------- layout ---------- */
.container {
  width: min(100% - (var(--gutter) * 2), var(--container));
  margin-inline: auto;
}

.section {
  position: relative;
  padding-block: var(--section-y);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: clamp(28px, 5vw, 90px);
  margin-bottom: clamp(36px, 5vw, 62px);
}

.section-title {
  color: var(--ink);
  font-family: var(--font-body);
  font-size: clamp(2.5rem, 5.2vw, 5.1rem);
  font-weight: 300;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

html[lang="en"] .section-title {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.025em;
}

.section-title em {
  color: var(--clay);
  font-style: normal;
}

html[lang="en"] .section-title em {
  font-family: var(--font-serif);
  font-style: italic;
}

.section-sub {
  max-width: 390px;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.9;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  color: var(--clay);
  font-family: var(--font-en);
  font-size: 0.68rem;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

html[lang="ar"] .eyebrow {
  font-family: var(--font-ar);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0;
}

.eyebrow-mark {
  width: 22px;
  height: 1px;
  flex: none;
  background: currentColor;
}

.eyebrow-light {
  color: var(--gold-light);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 500;
  border-bottom: 1px solid var(--line);
  padding-bottom: 3px;
  transition: color 0.25s ease, border-color 0.25s ease;
}
.text-link svg {
  width: 17px;
  height: 17px;
  transition: transform 0.3s var(--ease);
}
.text-link:hover {
  color: var(--clay);
  border-color: var(--clay);
}
.text-link:hover svg {
  transform: translateX(4px);
}
html[dir="rtl"] .text-link:hover svg {
  transform: translateX(-4px);
}

.dot {
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
  vertical-align: middle;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 52px;
  padding: 0 27px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 0.84rem;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  transition: background 0.35s var(--ease), color 0.35s var(--ease),
    border-color 0.35s var(--ease), transform 0.35s var(--ease);
}
.btn svg {
  width: 18px;
  height: 18px;
  transition: transform 0.35s var(--ease);
}
.btn:hover svg {
  transform: translateX(4px);
}
html[dir="rtl"] .btn:hover svg {
  transform: translateX(-4px);
}
.btn:active {
  transform: scale(0.985);
}

.btn-primary {
  color: var(--paper);
  background: var(--ink);
  border-color: var(--ink);
}
.btn-primary:hover {
  background: var(--clay);
  border-color: var(--clay);
}

.btn-ghost {
  color: var(--paper);
  border-color: rgba(251, 248, 242, 0.42);
  background: rgba(251, 248, 242, 0.04);
  backdrop-filter: blur(10px);
}
.btn-ghost:hover {
  color: var(--ink);
  background: var(--paper);
  border-color: var(--paper);
}

.btn-light {
  color: var(--ink);
  background: var(--paper);
  border-color: var(--paper);
}
.btn-light:hover {
  color: var(--paper);
  background: transparent;
  border-color: var(--paper);
}

.btn-wide {
  width: 100%;
}

.icon-btn {
  position: relative;
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 50%;
  color: var(--ink);
  transition: background 0.25s ease, color 0.25s ease;
}
.icon-btn svg {
  width: 20px;
  height: 20px;
}
.icon-btn:hover {
  background: rgba(28, 23, 19, 0.07);
}

.circle-btn {
  display: inline-grid;
  width: 48px;
  height: 48px;
  place-items: center;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 50%;
  transition: background 0.3s var(--ease), color 0.3s var(--ease),
    border-color 0.3s var(--ease);
}
.circle-btn svg {
  width: 19px;
  height: 19px;
}
.circle-btn:hover {
  color: var(--paper);
  background: var(--ink);
  border-color: var(--ink);
}
html[dir="rtl"] .circle-btn svg {
  transform: scaleX(-1);
}

.carousel-controls {
  display: flex;
  gap: 8px;
  flex: none;
}

/* ---------- motion ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
}
.js [data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

.scroll-progress {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 300;
  height: 2px;
  pointer-events: none;
}
.scroll-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--terracotta));
  transform: scaleX(0);
  transform-origin: left;
}
html[dir="rtl"] .scroll-progress span {
  transform-origin: right;
}

.grain::after,
.hero-grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.06;
  content: "";
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.35'/%3E%3C/svg%3E");
  background-size: 160px;
}

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

@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;
    scroll-behavior: auto !important;
  }
  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
