/* =========================================================================
   Amrad Investments — design tokens, base, layout, components
   ========================================================================= */

:root {
  --bg: #ffffff;
  --surface: #f7f8fa;
  --surface-2: #eef1f6;
  --ink: #0f1a2b;
  --ink-soft: #3b4759;
  --ink-mute: #6a7484;
  --accent: #c1272d;
  --accent-strong: #971c21;
  --accent-soft: rgba(193, 39, 45, 0.10);
  --accent-gold: #b08a47;
  --border: #e6e9ef;
  --shadow-sm: 0 1px 2px rgba(15, 26, 43, 0.04), 0 1px 1px rgba(15, 26, 43, 0.03);
  --shadow-md: 0 6px 24px rgba(15, 26, 43, 0.06), 0 2px 6px rgba(15, 26, 43, 0.04);

  --container: 1200px;
  --gutter: clamp(20px, 4vw, 64px);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;

  --font-en: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --font-he: "Heebo", "Assistant", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;

  --line-en: 1.6;
  --line-he: 1.75;
}

/* Reset / base ---------------------------------------------------------- */

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

html { scroll-behavior: smooth; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--accent);
  text-decoration: none;
  transition: color .15s ease;
}
a:hover { color: var(--accent-strong); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

h1, h2, h3, h4 {
  color: var(--ink);
  margin: 0 0 .4em;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

p { margin: 0 0 1em; color: var(--ink-soft); }

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

button { font: inherit; cursor: pointer; }

/* Skip link ------------------------------------------------------------- */

.skip-link {
  position: absolute;
  inset-inline-start: 8px;
  inset-block-start: -40px;
  background: var(--ink);
  color: #fff;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  z-index: 100;
  transition: top .15s ease;
}
.skip-link:focus { inset-block-start: 8px; color: #fff; }

/* Layout helpers -------------------------------------------------------- */

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

.placeholder {
  color: var(--ink-mute);
  font-style: italic;
  background: linear-gradient(transparent 0 60%, rgba(176, 138, 71, 0.18) 60% 95%, transparent 95%);
  padding-inline: 2px;
}

/* Header ---------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(160%) blur(8px);
  border-bottom: 1px solid var(--border);
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 2px 12px rgba(15, 26, 43, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 88px;
}

.brand { display: inline-flex; align-items: center; }
.brand-logo {
  height: 56px;
  width: auto;
  max-width: 260px;
  object-fit: contain;
}

/* Logo fallback box (visible if logo file is missing) */
.brand-logo:not([src]),
.brand-logo[src=""] {
  height: 56px;
  width: 160px;
  background: var(--surface-2);
  border: 1px dashed var(--border);
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-list {
  display: flex;
  gap: 28px;
  align-items: center;
}
.nav-list a {
  color: var(--ink-soft);
  font-weight: 500;
  font-size: 15px;
  padding: 8px 0;
  position: relative;
}
.nav-list a:hover { color: var(--ink); }
.nav-list a::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: inline-start;
  transition: transform .2s ease;
}
.nav-list a:hover::after { transform: scaleX(1); }

.lang-toggle {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--ink);
  padding: 6px 12px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.04em;
  transition: border-color .15s, color .15s, background .15s;
}
.lang-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  padding: 8px;
  width: 40px;
  height: 40px;
  position: relative;
}
.nav-toggle-bar {
  display: block;
  height: 2px;
  width: 22px;
  background: var(--ink);
  margin: 4px auto;
  transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Hero ------------------------------------------------------------------ */

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(1200px 480px at 50% -10%, rgba(193, 39, 45, 0.08), transparent 70%),
    linear-gradient(180deg, #fdfbfb 0%, #ffffff 100%);
  border-bottom: 1px solid var(--border);
}
.hero-skyline-svg {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 130%;
  opacity: 0.22;
  pointer-events: none;
  user-select: none;
}
.hero-skyline-svg svg {
  display: block;
  width: 100%;
  height: auto;
}
.hero-inner {
  position: relative;
  z-index: 1;
  padding-block: clamp(64px, 10vw, 140px);
  text-align: center;
  max-width: 900px;
}
.hero-logo {
  height: clamp(120px, 18vw, 200px);
  width: auto;
  margin: 0 auto 40px;
  max-width: 480px;
  object-fit: contain;
}
.hero-title {
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  color: var(--ink);
}
.hero-sub {
  font-size: clamp(17px, 2vw, 20px);
  color: var(--ink-soft);
  max-width: 640px;
  margin: 0 auto 36px;
}
.hero-cta {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 14px 28px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
  box-shadow: 0 4px 12px rgba(193, 39, 45, 0.22);
  transition: background .2s ease, transform .15s ease, box-shadow .2s ease;
}
.hero-cta:hover {
  background: var(--accent-strong);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(193, 39, 45, 0.30);
}

/* Sections -------------------------------------------------------------- */

.section { padding-block: clamp(64px, 9vw, 120px); }
.section--about { background: var(--bg); }
.section--holdings { background: var(--surface); border-block: 1px solid var(--border); }
.section--leadership { background: var(--bg); position: relative; z-index: 1; }
.section--contact { background: var(--surface); border-top: 1px solid var(--border); }

.section-title {
  font-size: clamp(26px, 3.5vw, 40px);
  font-weight: 700;
  letter-spacing: -0.015em;
  position: relative;
  padding-bottom: 14px;
  margin-bottom: 16px;
}
.section-title::after {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  bottom: 0;
  width: 56px;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
}

.section-lede {
  font-size: clamp(17px, 2vw, 20px);
  color: var(--ink-soft);
  max-width: 760px;
  margin: 8px 0 0;
}

.section-sub {
  color: var(--ink-soft);
  font-size: 17px;
  margin: 8px 0 40px;
  max-width: 720px;
}

/* Holdings -------------------------------------------------------------- */

.holdings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 16px;
}

.holding-card {
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.holding-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: #d6dde7;
}

.holding-icon {
  color: var(--accent);
  width: 56px;
  height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  border-radius: var(--radius-md);
  padding: 10px;
  margin-bottom: 20px;
}
.holding-icon svg { width: 100%; height: 100%; }

.holding-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--ink);
}
.holding-body {
  color: var(--ink-soft);
  margin-bottom: 18px;
}
.holding-link {
  font-weight: 600;
  font-size: 15px;
  color: var(--accent);
}
.holding-link:hover { color: var(--accent-strong); }

.badge {
  position: absolute;
  inset-block-start: 18px;
  inset-inline-end: 18px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
}
.badge--new {
  color: #fff;
  background: var(--accent);
  border: 1px solid var(--accent);
  box-shadow: 0 2px 8px rgba(193, 39, 45, 0.28);
}

/* Leadership ------------------------------------------------------------ */

.leadership-grid {
  margin-top: 16px;
}

.leadership-ceo-row {
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.leadership-ceo-row .person-card {
  width: 280px;
  max-width: 100%;
}

.leadership-directors-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px;
}
.leadership-directors-row .person-card {
  width: 280px;
  max-width: 100%;
}

.person-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  text-align: center;
  transition: transform .2s ease, box-shadow .2s ease;
}
.person-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.person-portrait {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 20px;
  background: linear-gradient(135deg, var(--surface-2), var(--surface));
  color: var(--accent);
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.person-portrait svg { width: 56%; height: 56%; flex-shrink: 0; }
.person-photo { width: 120px; height: 120px; object-fit: cover; object-position: center 15%; display: block; flex-shrink: 0; }

.person-name {
  font-size: 18px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 10px;
}
.person-card .placeholder {
  background: none;
}

.person-roles {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin-bottom: 12px;
}
.role-chip {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--ink-soft);
}
.role-chip--ceo {
  background: var(--accent);
  color: #fff;
}

.person-card-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 16px;
}

.person-linkedin {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  color: var(--ink-mute);
  transition: color .15s, background .15s;
  flex-shrink: 0;
}
.person-linkedin:hover { color: #0a66c2; background: rgba(10, 102, 194, .08); }
.person-linkedin svg { width: 18px; height: 18px; }

.person-bio-wrap { position: relative; }

.person-bio-btn {
  font-size: 13px;
  font-weight: 500;
  color: var(--accent);
  background: var(--accent-soft);
  border: none;
  border-radius: 20px;
  padding: 5px 14px;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.person-bio-btn:hover,
.person-bio-btn[aria-expanded="true"] {
  background: var(--accent);
  color: #fff;
}

.person-bio-popover {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  width: min(300px, 90vw);
  background: var(--bg);
  color: var(--ink-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px;
  font-size: 13px;
  line-height: 1.6;
  text-align: start;
  z-index: 200;
  box-shadow: var(--shadow-md);
}
.person-bio-popover::after {
  content: '';
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-bottom-color: var(--border);
}
.person-bio-popover p { margin: 0; }
.person-bio-wrap:hover .person-bio-popover,
.person-bio-popover.is-open { display: block; }

/* Contact --------------------------------------------------------------- */

.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}

.contact-list {
  margin: 24px 0 0;
}
.contact-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 16px;
  padding-block: 14px;
  border-bottom: 1px solid var(--border);
}
.contact-row:last-child { border-bottom: 0; }
.contact-row dt {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-mute);
}
.contact-row dd {
  margin: 0;
  color: var(--ink);
  font-size: 16px;
}
.map-link {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--border);
  text-underline-offset: 3px;
}
.map-link:hover {
  text-decoration-color: currentColor;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.contact-form {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
}
.contact-form-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
}

.field {
  margin-bottom: 18px;
}
.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.field input,
.field textarea {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus,
.field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(193, 39, 45, 0.18);
  outline: none;
}
.field.field--error input,
.field.field--error textarea {
  border-color: #b3261e;
}
.field.field--error::after {
  content: attr(data-error);
  display: block;
  margin-top: 6px;
  font-size: 13px;
  color: #b3261e;
}

.btn {
  display: inline-block;
  border: 0;
  border-radius: 8px;
  padding: 12px 24px;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background .15s, transform .15s, box-shadow .2s ease;
}
.btn--primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 12px rgba(193, 39, 45, 0.22);
}
.btn--primary:hover {
  background: var(--accent-strong);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(193, 39, 45, 0.30);
}

.form-status {
  margin: 14px 0 0;
  font-size: 14px;
  color: var(--ink-soft);
  min-height: 1.2em;
}
.form-status.is-success { color: #1b6e3a; }
.form-status.is-error { color: #b3261e; }

/* Footer ---------------------------------------------------------------- */

.site-footer {
  background: var(--ink);
  color: rgba(255, 255, 255, 0.78);
  padding-block: 32px;
  border-top: 3px solid var(--accent);
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-name { margin: 0; color: rgba(255, 255, 255, 0.78); font-size: 14px; }
.footer-nav { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-nav a { color: rgba(255, 255, 255, 0.78); font-size: 14px; }
.footer-nav a:hover { color: #fff; }

/* RTL-specific tweaks --------------------------------------------------- */

[dir="rtl"] .nav-list a::after { transform-origin: right; }

/* Hero CTA: arrow-bearing chars in copy are language-specific; nothing to mirror here. */

/* Mobile ---------------------------------------------------------------- */

@media (max-width: 840px) {
  /* backdrop-filter on .site-header creates a containing block for fixed
     descendants, which breaks .primary-nav's full-viewport positioning. */
  .site-header { backdrop-filter: none; }

  .nav-toggle { display: block; }

  .primary-nav {
    position: fixed;
    inset: 88px 0 0 0;
    background: var(--bg);
    flex-direction: column;
    align-items: stretch;
    padding: 24px var(--gutter);
    gap: 8px;
    border-top: 1px solid var(--border);
    transform: translateY(-110%);
    transition: transform .25s ease;
    box-shadow: 0 12px 24px rgba(15, 26, 43, 0.06);
  }
  .primary-nav.is-open { transform: translateY(0); }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    width: 100%;
  }
  .nav-list a {
    display: block;
    padding: 14px 0;
    font-size: 17px;
    border-bottom: 1px solid var(--border);
  }
  .nav-list a::after { display: none; }

  .lang-toggle { align-self: flex-start; margin-top: 12px; }

  body.nav-open { overflow: hidden; }

  .leadership-directors-row .person-card { width: 100%; max-width: 340px; }
  .leadership-ceo-row .person-card { width: 100%; max-width: 340px; }
  .contact-inner { grid-template-columns: 1fr; }
  .contact-row { grid-template-columns: 1fr; gap: 2px; }
  .contact-row dt { font-size: 12px; }
}

@media (max-width: 480px) {
  .leadership-directors-row { grid-template-columns: 1fr; }
  .contact-form { padding: 24px 20px; }
  .hero-cta { padding: 12px 22px; }
}

/* Holdings gallery panel ------------------------------------------------- */

/* Cards with galleries are clickable */
.holding-card[data-gallery] {
  cursor: pointer;
}
/* Subtle expand indicator in bottom-end corner */
.holding-card[data-gallery]::after {
  content: '▾';
  position: absolute;
  inset-block-end: 14px;
  inset-inline-end: 18px;
  font-size: 0.75rem;
  color: var(--accent);
  opacity: 0.6;
  transition: transform 0.35s ease, opacity 0.2s;
}
.holding-card[data-gallery].is-active::after {
  transform: rotate(180deg);
  opacity: 1;
}
.holding-card[data-gallery].is-active {
  border-top-color: var(--accent-strong);
  box-shadow: var(--shadow-md);
}

.holding-gallery-panel {
  grid-column: 1 / -1;
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.45s ease, margin-top 0.45s ease;
  overflow: hidden;
  margin-top: 0;
}
.holding-gallery-panel.is-open {
  grid-template-rows: 1fr;
  margin-top: 28px;
}

.holding-gallery-inner {
  min-height: 0;
  overflow: hidden;
}

.holding-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 16px;
  padding: 24px 0 8px;
  border-top: 2px solid var(--border);
}

.gallery-item {
  margin: 0;
}
.gallery-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: var(--radius-md);
  display: block;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.gallery-item img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-md);
}
.gallery-item figcaption {
  margin-top: 8px;
  font-size: 0.78rem;
  color: var(--ink-mute);
  line-height: 1.45;
  text-align: start;
}

.gallery-note {
  margin: 20px 0 0;
  padding: 8px 14px;
  border-inline-start: 3px solid var(--border);
  font-size: 0.8rem;
  color: var(--ink-mute);
  font-style: italic;
  line-height: 1.5;
}

.holding-gallery-text {
  margin: 24px 0 16px;
  padding-top: 24px;
  border-top: 2px solid var(--border);
  font-size: 1.05rem;
  color: var(--ink-soft);
  line-height: 1.7;
  max-width: 60ch;
}

@media (max-width: 840px) {
  .holding-gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
  }
  .gallery-item img { height: 160px; }
}

/* Desktop: keep Shachak / Real Estate / Parking Solutions on one row,
   with each gallery panel dropping into a shared full-width row below
   the cards instead of pushing the following card down. */
@media (min-width: 900px) {
  .holdings-grid { grid-template-columns: repeat(3, 1fr); }
  .holding-card { grid-row: 1; }
  .holding-gallery-panel { grid-row: 2; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  /* Show skyline instantly when reduced-motion is on */
  .hero-skyline-svg path { stroke-dashoffset: 0 !important; transition: none !important; }
  /* Show gallery instantly when reduced-motion is on */
  .holding-gallery-panel { transition: none !important; }
  .holding-gallery-panel.is-open { margin-top: 28px; }
}
