/* Migdalim Design Tokens — based on design document v1.0 */
:root {
  /* === COLORS === */
  --c-deep-blue: #0A2540;       /* Hadera Deep Blue — primary, headers, footers */
  --c-gold: #C9A961;            /* Migdalim Gold — accent (one place per screen) */
  --c-ivory: #F5F2EC;           /* Coast Ivory — default light background */
  --c-charcoal: #1A1A1A;        /* Charcoal — body text */
  --c-sand: #E8E1D1;            /* Warm Sand — secondary surfaces */
  --c-vein: #525968;            /* Vein Gray — meta text (WCAG AA on ivory) */
  --c-green: #2E7D5B;            /* Approval green */
  --c-red:   #C24E4E;            /* Soft red */
  --c-deeper: #061a30;           /* Even deeper blue for stage darks */
  --c-bone: #fbf9f4;

  /* status badge colors */
  --status-completed-bg: #2E7D5B;
  --status-completed-fg: #ffffff;
  --status-marketing-bg: #C9A961;
  --status-marketing-fg: #0A2540;
  --status-building-bg: #0A2540;
  --status-building-fg: #ffffff;
  --status-planning-bg: #6B7280;
  --status-planning-fg: #ffffff;

  /* === TYPOGRAPHY === */
  --font-display: "Frank Ruhl Libre", "Times New Roman", Georgia, serif;
  --font-body: "Heebo", "Assistant", -apple-system, system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;

  /* type scale */
  --t-display-xl: clamp(72px, 12vw, 200px);
  --t-display-l:  clamp(48px, 7.5vw, 120px);
  --t-display-m:  clamp(40px, 5vw, 80px);
  --t-h1: clamp(32px, 3.6vw, 56px);
  --t-h2: clamp(26px, 2.6vw, 40px);
  --t-h3: clamp(20px, 1.8vw, 28px);
  --t-body-l: 20px;
  --t-body-m: 16px;
  --t-body-s: 14px;
  --t-numeral-xl: clamp(120px, 22vw, 280px);

  /* spacing */
  --s-1: 4px;  --s-2: 8px;  --s-3: 12px;  --s-4: 16px;
  --s-5: 24px; --s-6: 32px; --s-7: 48px;  --s-8: 64px;
  --s-9: 96px; --s-10: 128px; --s-11: 192px;

  --max-w: 1440px;
  --gutter-mobile: 24px;
  --gutter-desktop: 56px;

  /* motion */
  --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-sharp: cubic-bezier(0.83, 0, 0.17, 1);
  --ease-anticipate: cubic-bezier(0.6, -0.28, 0.74, 0.05);
  --dur-fast: 200ms;
  --dur-base: 400ms;
  --dur-slow: 700ms;
  --dur-glacial: 1400ms;
}

/* === RESET & BASE === */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  font-size: var(--t-body-m);
  line-height: 1.6;
  color: var(--c-charcoal);
  background: var(--c-ivory);
  direction: rtl;
  overflow-x: hidden;
  font-feature-settings: "kern", "liga", "calt", "ss01";
}
img, video, svg { display: block; max-width: 100%; }
button { font-family: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }

/* === TYPOGRAPHY HELPERS === */
.t-display-xl { font-family: var(--font-display); font-size: var(--t-display-xl); line-height: 0.95; font-weight: 700; letter-spacing: -0.01em; }
.t-display-l  { font-family: var(--font-display); font-size: var(--t-display-l);  line-height: 1.02; font-weight: 700; letter-spacing: -0.005em; }
.t-display-m  { font-family: var(--font-display); font-size: var(--t-display-m);  line-height: 1.08; font-weight: 700; }
.t-h1 { font-family: var(--font-display); font-size: var(--t-h1); line-height: 1.15; font-weight: 700; }
.t-h2 { font-family: var(--font-display); font-size: var(--t-h2); line-height: 1.2; font-weight: 700; }
.t-h3 { font-family: var(--font-display); font-size: var(--t-h3); line-height: 1.3; font-weight: 600; }
.t-body-l { font-size: var(--t-body-l); line-height: 1.55; }
.t-body-m { font-size: var(--t-body-m); line-height: 1.6; }
.t-body-s { font-size: var(--t-body-s); line-height: 1.55; }
.t-meta {
  font-family: var(--font-mono); font-size: 14px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--c-vein); font-weight: 500;
}
.t-numeral { font-family: var(--font-display); font-variant-numeric: tabular-nums; font-weight: 700; letter-spacing: -0.02em; }

.gold { color: var(--c-gold); }
.deep { color: var(--c-deep-blue); }

/* === LAYOUT === */
.wrap {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding-inline: var(--gutter-mobile);
}
@media (min-width: 1024px) {
  .wrap { padding-inline: var(--gutter-desktop); }
}

/* === BUTTONS === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 28px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: transform var(--dur-fast) var(--ease-smooth),
              background var(--dur-fast) var(--ease-smooth),
              border-color var(--dur-fast) var(--ease-smooth),
              color var(--dur-fast) var(--ease-smooth),
              box-shadow var(--dur-fast) var(--ease-smooth);
  white-space: nowrap;
  background: transparent;
}
.btn-primary {
  background: var(--c-gold);
  color: var(--c-deep-blue);
  border-color: var(--c-gold);
}
.btn-primary:hover {
  background: #b89548;
  border-color: #b89548;
  transform: translateY(-2px);
  box-shadow: 0 18px 40px -16px rgba(201, 169, 97, 0.55);
}
.btn-ghost-light {
  color: #fff;
  border-color: rgba(255,255,255,0.35);
}
.btn-ghost-light:hover {
  border-color: var(--c-gold);
  color: var(--c-gold);
}
.btn-ghost-dark {
  color: var(--c-deep-blue);
  border-color: rgba(10, 37, 64, 0.3);
}
.btn-ghost-dark:hover {
  border-color: var(--c-gold);
  color: var(--c-gold);
}
.btn .arrow {
  display: inline-block;
  transition: transform var(--dur-base) var(--ease-smooth);
}
.btn:hover .arrow { transform: translateX(-6px); }

/* === BADGES === */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  font-family: var(--font-body);
}
.badge::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.85;
}
.badge-completed { background: var(--status-completed-bg); color: var(--status-completed-fg); }
.badge-marketing { background: var(--status-marketing-bg); color: var(--status-marketing-fg); }
.badge-building  { background: var(--status-building-bg);  color: var(--status-building-fg); }
.badge-planning  { background: var(--status-planning-bg);  color: var(--status-planning-fg); }

/* === GLOBAL NAV === */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px var(--gutter-mobile);
  transition: background var(--dur-base) var(--ease-smooth), color var(--dur-base) var(--ease-smooth), backdrop-filter var(--dur-base);
  color: #fff;
  mix-blend-mode: normal;
}
@media (min-width: 1024px) {
  .nav { padding: 26px var(--gutter-desktop); }
}
.nav--scrolled {
  background: rgba(245, 242, 236, 0.92);
  backdrop-filter: blur(20px);
  color: var(--c-deep-blue);
  border-bottom: 1px solid rgba(10,37,64,0.06);
}
.nav--dark {
  background: rgba(10, 37, 64, 0.92);
  backdrop-filter: blur(20px);
  color: #fff;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.nav__brand {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 28px;
  letter-spacing: -0.005em;
}
.nav__brand .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--c-gold); display: inline-block; }
.nav__links {
  display: none;
  gap: 36px;
  align-items: center;
}
@media (min-width: 900px) { .nav__links { display: flex; } }
.nav__link {
  font-size: 16px;
  font-weight: 500;
  position: relative;
  padding: 4px 0;
}
.nav__link::after {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--c-gold);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--dur-base) var(--ease-smooth);
}
.nav__link:hover::after { transform: scaleX(1); }
.nav__link.is-active::after { transform: scaleX(1); }
.nav__cta {
  display: none;
}
@media (min-width: 900px) { .nav__cta { display: inline-flex; padding: 10px 20px; font-size: 13px; } }

/* mobile menu trigger */
.nav__menu {
  display: inline-flex;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  padding: 8px;
}
.nav__menu span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: currentColor;
}
@media (min-width: 900px) { .nav__menu { display: none; } }

/* === FOOTER === */
.footer {
  background: #050d18;
  color: rgba(255,255,255,0.7);
  padding: 96px 0 32px;
  position: relative;
}
.footer__motto {
  font-family: var(--font-display);
  font-size: clamp(56px, 9vw, 140px);
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  line-height: 0.95;
  margin: 0 0 64px;
}
.footer__motto .pause {
  display: inline-block;
  margin-inline-start: 12px;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--c-gold);
  vertical-align: middle;
  transform: translateY(-12px);
}
.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  padding-bottom: 64px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
@media (min-width: 768px) {
  .footer__grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
}
.footer__col h3 {
  font-size: 11px;
  font-family: var(--font-mono);
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--c-gold);
  margin: 0 0 18px;
}
.footer__col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer__col a {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  transition: color var(--dur-fast) var(--ease-smooth);
}
.footer__col a:hover { color: var(--c-gold); }
.footer__brand-block {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 32px;
  color: #fff;
  margin: 0 0 16px;
}
.footer__address {
  font-size: 14px;
  line-height: 1.7;
}
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  padding-top: 28px;
  gap: 16px;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  font-family: var(--font-mono);
  letter-spacing: 0.05em;
}

/* === UTILITY === */
.split-line { width: 32px; height: 1px; background: var(--c-gold); display: inline-block; vertical-align: middle; margin-inline-end: 14px; }
.kicker {
  display: inline-flex; align-items: center;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--c-gold);
  font-weight: 500;
}
.section-head {
  display: flex; flex-direction: column; gap: 14px;
  margin-bottom: 56px;
}
.section-head h2 {
  margin: 0;
  max-width: 18ch;
}
.section-head p {
  max-width: 60ch;
  color: var(--c-vein);
  margin: 0;
  font-size: 18px;
  line-height: 1.55;
}

/* placeholder image utility for missing assets */
.ph {
  background:
    repeating-linear-gradient(45deg, rgba(10,37,64,0.04) 0 1px, transparent 1px 12px),
    var(--c-sand);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--c-vein);
  text-align: center;
}

/* === reduced motion === */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
}
