/* Select Group — Six Senses Residences Dubai Marina microsite */
/* Tokens, layout, typography, sections. */

/* ─────────────────────────────────────────────────────────────
   1. Tokens
   ───────────────────────────────────────────────────────────── */
:root {
  --bg: #0E1216;
  --surface: #F7F6F2;
  --cream: #EFEBE1;
  --text: #1A1D21;
  --muted: #6B747E;
  --primary: #292F68;
  --secondary: #51A6DC;
  --accent: #8ED0E8;
  --border: #DED9CE;
  --border-dark: rgba(255,255,255,0.14);
  --focus: #51A6DC;
  --hero: #181D22;

  --font-display: 'Cormorant Garamond', 'Cormorant', Georgia, serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --font-ar: 'Noto Naskh Arabic', 'Noto Kufi Arabic', system-ui, sans-serif;

  --section-y: clamp(96px, 12vw, 180px);
  --wrap: min(1320px, calc(100vw - 48px));
  --hairline: 1px solid var(--border);
  --hairline-dark: 1px solid var(--border-dark);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --r-1: 2px;
  --r-2: 4px;
  --r-3: 8px;
}

/* Tweaks: palette weight */
html[data-palette="blue-heavy"] {
  --primary: #1F4A7A;
  --secondary: #51A6DC;
  --accent: #B9DEEE;
}
html[data-palette="editorial"] {
  --bg: #1A1D21;
  --hero: #1A1D21;
  --primary: #1A1D21;
  --secondary: #292F68;
  --accent: #51A6DC;
}

/* Tweaks: type */
html[data-type="grotesque"] {
  --font-display: 'Manrope', 'Inter', system-ui, sans-serif;
}

/* Tweaks: density */
html[data-density="regular"] { --section-y: clamp(72px, 9vw, 130px); }
html[data-density="compact"] { --section-y: clamp(56px, 6vw, 88px); }

/* RTL: Arabic font for body */
html[dir="rtl"] body { font-family: var(--font-ar); }
html[dir="rtl"] .hero-h, html[dir="rtl"] .sect-h { font-family: var(--font-ar); font-weight: 500; }

/* ─────────────────────────────────────────────────────────────
   2. Base reset
   ───────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--surface);
  font-feature-settings: "ss01", "cv01", "cv11";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
p { margin: 0; }
h1, h2, h3, h4, h5, h6 { margin: 0; font-weight: 500; letter-spacing: -0.01em; }
ul, ol, dl { margin: 0; padding: 0; list-style: none; }
dd, dt { margin: 0; }
hr { border: 0; border-top: var(--hairline); }

.wrap { width: var(--wrap); margin-inline: auto; }
.section { padding-block: var(--section-y); }
.section--light { background: var(--surface); color: var(--text); }
.section--cream { background: var(--cream); color: var(--text); }
.section--dark { background: var(--bg); color: var(--surface); }

/* ─────────────────────────────────────────────────────────────
   3. Typographic primitives
   ───────────────────────────────────────────────────────────── */
.sect-eye {
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}
.sect-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--primary);
}
.section--dark .sect-num { color: var(--accent); }
.section--dark .sect-eye, .sect-head--inverse .sect-eye { color: rgba(247,246,242,0.65); }
.hairline {
  flex: 1;
  height: 1px;
  background: var(--border);
}
.section--dark .hairline, .sect-head--inverse .hairline { background: var(--border-dark); }

.sect-head {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-bottom: 56px;
}
.sect-meta {
  display: flex;
  align-items: center;
  gap: 16px;
}
.sect-h {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(34px, 4.8vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  max-width: 22ch;
  text-wrap: balance;
}
html[data-type="grotesque"] .sect-h {
  font-weight: 400;
  letter-spacing: -0.025em;
}
.section--dark .sect-h, .sect-head--inverse .sect-h { color: var(--surface); }
.sect-lede {
  font-family: var(--font-display);
  font-size: clamp(20px, 2.2vw, 26px);
  line-height: 1.4;
  color: var(--text);
  max-width: 56ch;
  margin-bottom: 56px;
  font-weight: 400;
  font-style: italic;
}
html[data-type="grotesque"] .sect-lede { font-style: normal; font-family: var(--font-body); font-weight: 300; }

.section--dark .sect-lede { color: rgba(247,246,242,0.85); }

/* ─────────────────────────────────────────────────────────────
   4. Buttons
   ───────────────────────────────────────────────────────────── */
.btn {
  appearance: none;
  border: 0;
  background: transparent;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  font-family: var(--font-body);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
  border-radius: var(--r-1);
  transition: all .25s var(--ease);
  white-space: nowrap;
}
.btn--lg { padding: 16px 28px; font-size: 13px; letter-spacing: 0.08em; }
.btn--primary {
  background: var(--primary);
  color: var(--surface);
  position: relative;
  overflow: hidden;
}
.btn--primary::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(120deg, var(--primary) 0%, var(--secondary) 50%, var(--primary) 100%);
  background-size: 200% 100%;
  background-position: 100% 0;
  opacity: 0;
  transition: opacity .35s var(--ease), background-position .8s var(--ease);
  z-index: 0;
}
.btn--primary:hover::before { opacity: 1; background-position: 0 0; }
.btn--primary > * { position: relative; z-index: 1; }
.btn--ghost {
  background: transparent;
  color: currentColor;
  border: 1px solid currentColor;
}
.btn--ghost:hover { background: currentColor; color: var(--bg); }
.section--dark .btn--ghost:hover { color: var(--surface); background: rgba(247,246,242,0.1); border-color: var(--surface); }

/* ─────────────────────────────────────────────────────────────
   5. Nav
   ───────────────────────────────────────────────────────────── */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding: 18px clamp(20px, 3vw, 36px);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
  color: var(--surface);
  transition: background .35s var(--ease), color .35s var(--ease), padding .35s var(--ease), border-color .35s var(--ease);
  border-bottom: 1px solid transparent;
}
.nav--solid {
  background: rgba(247,246,242,0.95);
  color: var(--text);
  padding-block: 14px;
  border-bottom-color: var(--border);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.nav-brand { display: flex; align-items: center; }
.nav-logo { height: 32px; width: auto; }
.nav-logo--light { display: none; }
.nav--solid .nav-logo--dark { display: none; }
.nav--solid .nav-logo--light { display: block; }
.nav-items {
  display: flex;
  gap: 28px;
  justify-content: center;
  font-size: 13px;
  font-weight: 400;
}
.nav-items a { color: inherit; opacity: 0.85; transition: opacity .2s; }
.nav-items a:hover { opacity: 1; }
.nav-right { display: flex; align-items: center; gap: 16px; }
.nav-cta { padding: 11px 18px; font-size: 11.5px; }
.nav-burger { display: none; background: none; border: 0; width: 36px; height: 36px; flex-direction: column; gap: 5px; justify-content: center; align-items: center; }
.nav-burger span { width: 18px; height: 1px; background: currentColor; display: block; }

.lang { position: relative; }
.lang-btn {
  appearance: none;
  background: transparent;
  border: 1px solid currentColor;
  color: inherit;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  letter-spacing: 0.1em;
  border-radius: var(--r-1);
  opacity: 0.85;
  transition: opacity .2s;
}
.lang-btn:hover { opacity: 1; }
.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--surface);
  color: var(--text);
  border: var(--hairline);
  min-width: 180px;
  padding: 6px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.12);
  z-index: 10;
}
html[dir="rtl"] .lang-menu { right: auto; left: 0; }
.lang-menu button {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  text-align: start;
  background: transparent;
  border: 0;
  padding: 10px 12px;
  font-size: 13px;
  border-radius: var(--r-1);
}
.lang-menu button:hover { background: var(--cream); }
.lang-menu button.is-on { color: var(--primary); font-weight: 500; }
.lang-menu em { font-style: normal; font-size: 9.5px; color: var(--muted); letter-spacing: 0.1em; text-transform: uppercase; }

@media (max-width: 900px) {
  .nav-items { display: none; }
  .nav-burger { display: flex; }
}

/* ─────────────────────────────────────────────────────────────
   6. Hero
   ───────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  color: var(--surface);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  padding: 0 clamp(20px, 3vw, 36px) clamp(72px, 9vw, 128px);
}
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center; animation: heroZoom 14s var(--ease) forwards; }
@keyframes heroZoom { from { transform: scale(1.06); } to { transform: scale(1); } }
.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(14,18,22,0.55) 0%, rgba(14,18,22,0.15) 30%, rgba(14,18,22,0.85) 100%),
    linear-gradient(90deg, rgba(14,18,22,0.55), rgba(14,18,22,0.05) 60%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
}
.hero-eye {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  margin-bottom: 28px;
  color: var(--accent);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.hero-eye::before {
  content: "";
  width: 36px;
  height: 1px;
  background: var(--accent);
  display: inline-block;
}
.hero-h {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(56px, 9vw, 132px);
  line-height: 0.94;
  letter-spacing: -0.025em;
  margin-bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.hero-h-1 { display: block; }
.hero-h-2 { display: block; font-style: italic; }
html[data-type="grotesque"] .hero-h-2 { font-style: normal; opacity: 0.78; }
.hero-h-3 {
  display: block;
  font-family: var(--font-body);
  font-size: clamp(14px, 1.5vw, 18px);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-weight: 400;
  margin-top: 24px;
  color: var(--accent);
}
.hero-sub {
  font-size: clamp(15px, 1.4vw, 17px);
  line-height: 1.55;
  color: rgba(247,246,242,0.85);
  max-width: 52ch;
  margin-bottom: 40px;
}
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-meta {
  position: absolute;
  bottom: clamp(20px, 3vw, 36px);
  inset-inline-end: clamp(20px, 3vw, 36px);
  z-index: 2;
  display: flex;
  gap: 28px;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(247,246,242,0.7);
}
.hero-meta-item { display: flex; align-items: center; gap: 8px; }
.hero-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(142,208,232,0.25);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(142,208,232,0.45); }
  50% { box-shadow: 0 0 0 6px rgba(142,208,232,0); }
}

/* Hero side rail */
.hero-side {
  position: absolute;
  top: clamp(96px, 12vw, 130px);
  inset-inline-end: clamp(20px, 3vw, 36px);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  color: rgba(247,246,242,0.7);
}
.hero-side-mark {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
}
.hero-side-rule {
  width: 1px; height: 72px;
  background: linear-gradient(180deg, transparent, var(--accent), transparent);
}
.hero-side-text {
  writing-mode: vertical-rl;
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}
html[dir="rtl"] .hero-side-text { writing-mode: vertical-lr; }

/* Hero ribbon (marquee at very top of hero, below nav) */
.hero-ribbon {
  position: absolute;
  top: 64px;
  inset-inline: 0;
  z-index: 2;
  overflow: hidden;
  border-block: 1px solid rgba(255,255,255,0.1);
  background: rgba(14,18,22,0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding-block: 8px;
}
html[data-ribbon="off"] .hero-ribbon { display: none; }
.hero-ribbon-track {
  display: flex;
  gap: 0;
  white-space: nowrap;
  animation: ribbon 60s linear infinite;
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(247,246,242,0.7);
}
.hero-ribbon-track span { display: flex; gap: 40px; padding-inline: 20px; }
.hero-ribbon-track em { font-style: normal; }
@keyframes ribbon { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* Hero scroll cue */
.hero-scroll {
  position: absolute;
  bottom: clamp(24px, 4vw, 48px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: rgba(247,246,242,0.7);
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  transition: opacity .4s;
}
.hero-scroll.is-hidden { opacity: 0; pointer-events: none; }
.hero-scroll-line {
  width: 1px; height: 48px;
  background: linear-gradient(180deg, transparent, var(--accent));
  animation: scrollLine 2.4s ease-in-out infinite;
}
@keyframes scrollLine {
  0% { transform: scaleY(0.2); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  50.01% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0.2); transform-origin: bottom; }
}

@media (max-width: 720px) {
  .hero-side, .hero-meta { display: none; }
  .hero-h { font-size: clamp(48px, 13vw, 80px); }
  .hero-eye::before { width: 24px; }
}

/* ─────────────────────────────────────────────────────────────
   7. Facts strip
   ───────────────────────────────────────────────────────────── */
.facts {
  background: var(--hero);
  color: var(--surface);
  padding-block: clamp(56px, 7vw, 96px);
  border-bottom: 1px solid var(--border-dark);
}
.facts-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 48px;
  gap: 24px;
  flex-wrap: wrap;
  color: rgba(247,246,242,0.7);
}
.facts-head .sect-eye { color: var(--accent); font-size: 12px; }
.facts-cite { font-size: 11px; letter-spacing: 0.1em; opacity: 0.6; font-family: var(--font-mono); }
.facts-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--border-dark);
  border-bottom: 1px solid var(--border-dark);
}
.fact {
  padding: 36px 24px 36px 0;
  border-inline-end: 1px solid var(--border-dark);
}
.fact:last-child { border-inline-end: 0; }
.fact-num {
  font-family: var(--font-display);
  font-size: clamp(36px, 4.5vw, 60px);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--surface);
  margin-bottom: 8px;
  font-feature-settings: "lnum";
}
html[data-type="grotesque"] .fact-num { font-family: var(--font-body); font-weight: 300; }
.fact-unit {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}
.fact-note {
  font-size: 13px;
  line-height: 1.45;
  color: rgba(247,246,242,0.65);
  max-width: 28ch;
}
.facts-pull {
  margin-top: 48px;
  display: grid;
  grid-template-columns: 60px 1fr auto;
  gap: 24px;
  align-items: start;
}
.facts-pull-q {
  font-family: var(--font-display);
  font-size: 72px;
  line-height: 0.7;
  color: var(--secondary);
}
.facts-pull p:not(.facts-pull-cite) {
  font-family: var(--font-display);
  font-size: clamp(20px, 2.2vw, 28px);
  line-height: 1.35;
  font-style: italic;
  max-width: 36ch;
  color: rgba(247,246,242,0.95);
}
.facts-pull-cite {
  font-size: 11px;
  letter-spacing: 0.1em;
  font-family: var(--font-mono);
  color: rgba(247,246,242,0.5);
  align-self: end;
}

@media (max-width: 900px) {
  .facts-grid { grid-template-columns: repeat(2, 1fr); }
  .fact:nth-child(2) { border-inline-end: 0; }
  .fact { border-bottom: 1px solid var(--border-dark); }
  .fact:nth-last-child(-n+2) { border-bottom: 0; }
}
@media (max-width: 600px) {
  .facts-grid { grid-template-columns: 1fr; }
  .fact { border-inline-end: 0; border-bottom: 1px solid var(--border-dark); }
  .facts-pull { grid-template-columns: 40px 1fr; }
  .facts-pull-cite { grid-column: 2; }
}

/* ─────────────────────────────────────────────────────────────
   8. Overview
   ───────────────────────────────────────────────────────────── */
.overview-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 80px;
  align-items: start;
}
.overview-body p {
  font-family: var(--font-display);
  font-size: clamp(20px, 2vw, 26px);
  line-height: 1.45;
  margin-bottom: 24px;
  max-width: 38ch;
  color: var(--text);
  font-weight: 400;
}
html[data-type="grotesque"] .overview-body p { font-family: var(--font-body); font-weight: 300; }
.overview-body p:last-child { margin-bottom: 0; }
.overview-pillars {
  display: grid;
  grid-template-columns: 1fr;
  border-top: var(--hairline);
}
.overview-pillars > div {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  padding: 20px 0;
  border-bottom: var(--hairline);
}
.overview-pillars dt {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}
.overview-pillars dd {
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
}

@media (max-width: 800px) {
  .overview-grid { grid-template-columns: 1fr; gap: 40px; }
}
