/* Layout: a gallery wall. Full-height hero, then single images placed at different sizes and sides with large empty intervals. Interface is type only. */
:root {
  --bg: #FFFFFF;      /* white */
  --ink: #1F1C19;     /* warm charcoal */
  --mute: #7A746B;    /* aged plaster shadow */
  --line: #BDB8AF;    /* hairline under links */
  --hero-ink: #231F1B;/* sits on the photograph, so it does not change with theme */
  --font: "Heebo", system-ui, "Arial Hebrew", Arial, sans-serif;
  --gutter: clamp(1.25rem, 4vw, 4rem);
  --space: clamp(7rem, 15vw, 15rem);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --bg: #171615; --ink: #E9E5DE; --mute: #8F897F; --line: #55514C; color-scheme: dark; }
}
:root[data-theme="dark"] { --bg: #171615; --ink: #E9E5DE; --mute: #8F897F; --line: #55514C; color-scheme: dark; }

*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.6;
  direction: rtl;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, p, figure, ul { margin: 0; padding: 0; }
ul { list-style: none; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 1px solid currentColor; outline-offset: 6px; }

/* HERO */
.hero { position: relative; height: 100svh; min-height: 32rem; overflow: hidden; background: #cfc8bd; }
.hero img { width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: 50% 48%; }
.hero-nav {
  position: absolute; z-index: 2;
  top: max(1.5rem, 3svh); left: var(--gutter); right: var(--gutter);
  display: flex; justify-content: flex-end; gap: 0.5rem 1.25rem; flex-wrap: wrap;
  font-size: 0.8125rem; letter-spacing: 0.04em; color: var(--hero-ink);
  animation: fade 2.4s ease both;
}
.hero-nav a + a::before { content: "·"; margin-inline-end: 1.25rem; opacity: 0.6; }
.hero-nav a { transition: opacity 0.6s ease; }
.hero-nav a:hover { opacity: 0.55; }
.hero-copy {
  position: absolute; z-index: 2;
  left: var(--gutter); top: 21svh;
  direction: ltr; text-align: left; color: var(--hero-ink);
  animation: fade 2.8s ease 0.3s both;
}
.hero-copy h1 {
  font-size: clamp(2.1rem, 4.2vw, 4.5rem);
  font-weight: 200; letter-spacing: 0.2em; line-height: 1;
  margin-right: -0.2em; white-space: nowrap;
}
.hero-copy p {
  direction: ltr; text-align: center;
  margin-top: 0.35rem; font-size: clamp(0.8rem, 1.05vw, 1rem);
  font-weight: 200; letter-spacing: 0.18em; padding-left: 0.18em; position: relative; left: -5px;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* INTRO */
.intro { padding: var(--space) var(--gutter); display: grid; gap: clamp(1.25rem, 2vw, 2rem); }
.intro p {
  max-width: 26em;
  margin-inline-start: clamp(0rem, 14vw, 16rem);
  font-size: clamp(1.5rem, 2.9vw, 2.75rem);
  font-weight: 200; line-height: 1.5; text-wrap: balance;
}

/* THREE WORLDS */
.world {
  padding: 0 var(--gutter) var(--space);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(0.75rem, 2vw, 2rem);
  row-gap: 1.75rem;
}
.world figure img { width: 100%; }
.world h2 { font-size: clamp(1.75rem, 2.6vw, 2.5rem); font-weight: 200; line-height: 1.2; }
.world .more {
  display: inline-block;
  margin-top: 1.5rem; padding-bottom: 0.3rem;
  font-size: 0.6875rem; font-weight: 300; letter-spacing: 0.03em; line-height: 1.4;
  white-space: nowrap; color: var(--mute); border-bottom: 1px solid var(--line);
  transition: color 0.6s ease, border-color 0.6s ease;
}
.world .more:hover { color: var(--ink); border-bottom-color: var(--ink); }
.world .text { min-width: 0; }
.world .more-stack { margin-top: 1.5rem; display: grid; justify-items: start; gap: 0.875rem; }
.world .more-stack .more { margin-top: 0; }

/* All three categories share the proportions of עתיקים: image on the left (8 of 12 columns), name and link high on the right. */
.w-sela figure, .w-atikim figure, .w-migorad figure { grid-column: 5 / span 8; grid-row: 1; }
.w-sela .text, .w-atikim .text, .w-migorad .text { grid-column: 1 / span 3; grid-row: 1; align-self: start; padding-top: 2rem; }
.w-sela img, .w-atikim img, .w-migorad img { aspect-ratio: 1900 / 1985; object-fit: cover; }
.w-sela img { object-position: 50% 50%; }
.w-migorad img { object-position: 62% 50%; }

/* WOW */
.wow { padding: 0 clamp(1rem, 2vw, 2.5rem) var(--space); }
.wow img { width: 100%; max-height: 120svh; object-fit: cover; }

/* ABOUT */
.about {
  padding: 0 var(--gutter) var(--space);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(0.75rem, 2vw, 2rem); row-gap: 2.5rem;
}
.about h2 {
  grid-column: 1 / span 3;
  font-size: 1.05rem; font-weight: 400; letter-spacing: 0.2em; direction: ltr; text-align: right;
}
.about .body { grid-column: 5 / span 6; display: grid; gap: 1.6em; max-width: 34em; min-width: 0; }
.about .body p { font-size: clamp(1.0625rem, 1.35vw, 1.25rem); line-height: 1.9; text-wrap: pretty; }

/* CONTACT */
.contact { padding: 0 var(--gutter) calc(var(--space) * 0.9); }
.contact p.big {
  font-size: clamp(2.1rem, 5.4vw, 5rem); font-weight: 200; line-height: 1.25; text-wrap: balance;
}
.contact p.big span { display: block; color: var(--mute); }
.contact ul {
  display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; margin-top: clamp(2.5rem, 5vw, 4.5rem);
  font-size: 0.9375rem; letter-spacing: 0.02em;
}
.contact li + li::before { content: "·"; margin-inline-end: 1.25rem; color: var(--mute); }

@media (max-width: 760px) {
  .hero-copy { top: 19svh; }
  .hero-copy h1 { font-size: clamp(1.7rem, 8.4vw, 2.1rem); letter-spacing: 0.18em; margin-right: -0.18em; }
  .hero-nav { justify-content: space-between; gap: 0.25rem 0.5rem; font-size: 0.75rem; flex-wrap: nowrap; letter-spacing: 0.02em; }
  .hero-nav a + a::before { display: none; }
  .intro p { margin-inline-start: 0; }
  .world { row-gap: 1.5rem; }
  .w-sela .text, .w-atikim .text, .w-migorad .text { grid-column: 1 / span 4; }
  .world h2 { font-size: 1.25rem; text-wrap: balance; }
  .world .more { margin-top: 1rem; font-size: 0.625rem; }
  .world .more-stack { margin-top: 1rem; gap: 0.75rem; }
  .about h2 { grid-column: 1 / -1; text-align: right; }
  .about .body { grid-column: 1 / -1; }
}
.gallery img { cursor: zoom-in; }
.lb { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; background: var(--bg, #fff); cursor: zoom-out; }
.lb[hidden] { display: none; }
.lb img { max-width: 100vw; max-height: 100vh; max-height: 100dvh; width: auto; height: auto; object-fit: contain; }
.lb button { position: absolute; background: none; border: 0; padding: 0.5rem 1rem; font: inherit; font-size: 2rem; line-height: 1; color: var(--ink, #1F1C19); opacity: 0.55; cursor: pointer; }
.lb button:hover { opacity: 1; }
.lb-x { top: 0.5rem; left: 0.5rem; } .lb-p { top: 50%; right: 0.25rem; transform: translateY(-50%); } .lb-n { top: 50%; left: 0.25rem; transform: translateY(-50%); }
.lb-open { overflow: hidden; }
.founder { padding: 0 var(--gutter) clamp(6rem, 12vw, 12rem); display: grid; grid-template-columns: minmax(0, 1fr) minmax(18rem, 30vw); gap: clamp(2rem, 5vw, 6rem); align-items: stretch; }
.founder .text { grid-column: 1; grid-row: 1; display: grid; align-content: start; gap: 1.6em; min-width: 0; border-bottom: 1px solid var(--ink); padding-bottom: 1.4rem; }
.founder h2 { font-size: clamp(1.75rem, 2.6vw, 2.5rem); font-weight: 200; line-height: 1.2; }
.founder p { max-width: 34em; font-size: clamp(1.0625rem, 1.35vw, 1.25rem); line-height: 1.9; text-wrap: pretty; }
.founder figure { grid-column: 2; grid-row: 1; }
.founder img { width: 100%; height: auto; }
@media (max-width: 760px) { .founder { grid-template-columns: 1fr; } .founder .text { grid-column: 1; grid-row: 2; } .founder figure { grid-column: 1; grid-row: 1; } }
.hero-copy h1 img { display: block; width: clamp(11.5rem, 18vw, 19rem); height: auto; margin: 0 auto; max-width: none; }
.about h2 img { display: block; width: clamp(7.5rem, 11vw, 12rem); height: auto; max-width: none; margin-inline-start: auto; }
.hero-nav a[aria-current="page"] { border-bottom: 1px solid currentColor; }
.hero.hero-half { width: 100%; height: auto; aspect-ratio: 6 / 1; min-height: 0; }
@media (max-width: 760px) { .hero.hero-half { aspect-ratio: auto; height: 8rem; min-height: 0; } }
.hero.hero-half img { object-position: 50% 0; }
.brand { grid-column: 2; grid-row: 1 / span 3; align-self: start; margin: 0; }
.brand img { display: block; width: clamp(9rem, 17vw, 18rem); height: auto; max-width: none; }
.intro, .home-intro { grid-template-columns: minmax(0, 1fr) auto; column-gap: clamp(2rem, 5vw, 6rem); }
.intro p, .home-intro p { grid-column: 1; }
@media (max-width: 760px) { .intro, .home-intro { grid-template-columns: 1fr; } .brand { grid-column: 1; grid-row: auto; } .brand img { width: 11rem; } }
.intro p:first-of-type, .home-intro p:first-of-type { text-align: center; }
.intro, .home-intro { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(0.75rem, 2vw, 2rem); row-gap: 1.6em; }
.intro p, .home-intro p { grid-column: 5 / span 6; max-width: 34em; margin: 0; text-align: start; font-size: clamp(1.0625rem, 1.35vw, 1.25rem); line-height: 1.9; text-wrap: pretty; }
.intro .brand, .home-intro .brand { grid-column: 10 / span 3; grid-row: 1 / span 3; }
@media (max-width: 760px) { .intro, .home-intro { grid-template-columns: 1fr; } .intro p, .home-intro p, .intro .brand, .home-intro .brand { grid-column: 1; grid-row: auto; max-width: none; } }
.intro p:first-of-type, .home-intro p:first-of-type { text-align: start; }
.intro p, .home-intro p { max-width: 34rem; }
.intro p:nth-of-type(1), .home-intro p:nth-of-type(1) { grid-row: 1; }
.intro p:nth-of-type(2), .home-intro p:nth-of-type(2) { grid-row: 2; }
.intro p:nth-of-type(3), .home-intro p:nth-of-type(3) { grid-row: 3; }
.intro .brand, .home-intro .brand { grid-row: 1; align-self: start; }
@media (max-width: 760px) { main .intro p, main .home-intro p, .intro .brand, .home-intro .brand { grid-row: auto !important; max-width: none; } }
main .home-intro p { max-width: 34rem; }
.intro .brand, .home-intro .brand { grid-row: 1 / span 3; }
.intro .brand, .home-intro .brand { grid-column: 1 / span 3; }
.intro .brand img, .home-intro .brand img { width: clamp(7.5rem, 11vw, 12rem); margin-inline-start: auto; }
@media (max-width: 760px) { .intro .brand, .home-intro .brand { grid-column: 1; } .intro .brand img, .home-intro .brand img { width: 7.5rem; } }
.intro .brand img, .home-intro .brand img { margin-inline: auto 0; margin-left: 0; margin-right: 0; }
.intro .brand, .home-intro .brand { direction: rtl; }
.hero-copy .t { font-size: clamp(2.1rem, 4.2vw, 4.5rem); font-weight: 200; letter-spacing: 0.2em; line-height: 1; margin-right: -0.2em; white-space: nowrap; }
@media (max-width: 760px) { .hero-copy .t { font-size: clamp(1.7rem, 8.4vw, 2.1rem); letter-spacing: 0.18em; margin-right: -0.18em; } }
.contact { position: relative; }
.contact .c-logo { position: absolute; left: var(--gutter); top: 0; width: clamp(7.5rem, 11vw, 12rem); height: auto; }
@media (max-width: 760px) { .contact .c-logo { position: static; display: block; width: 5.5rem; margin: 0 auto 1.5rem 0; } }
.contact .c-logo { position: static; display: block; width: clamp(7.5rem, 11vw, 12rem); margin: clamp(2rem, 4vw, 3.5rem) 0 0; }
@media (max-width: 760px) { .contact .c-logo { width: 5.5rem; margin: 1.75rem 0 0; } }
.hero-copy p { text-align: left; left: 8px; padding-left: 0; }
/* INNER PAGE: קירות סלע */
.p-top { padding: max(1.5rem, 3svh) var(--gutter) 0; }
.p-nav { display: flex; justify-content: flex-end; gap: 0.5rem 1.25rem; flex-wrap: wrap; font-size: 0.8125rem; letter-spacing: 0.04em; }
.p-nav a + a::before { content: "·"; margin-inline-end: 1.25rem; opacity: 0.6; }
.p-nav a { transition: opacity 0.6s ease; }
.p-nav a:hover { opacity: 0.55; }
.p-nav a[aria-current="page"] { border-bottom: 1px solid currentColor; }
@media (max-width: 760px) { .p-nav { justify-content: space-between; gap: 0.25rem 0.5rem; font-size: 0.75rem; flex-wrap: nowrap; letter-spacing: 0.02em; } .p-nav a + a::before { display: none; } }
.p-intro {
  padding: clamp(8rem, 18vw, 17rem) var(--gutter) 0;
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(0.75rem, 2vw, 2rem); row-gap: clamp(1.5rem, 2.4vw, 2.25rem);
}
.p-intro h1 { grid-column: 1 / -1; font-size: clamp(2.75rem, 6.4vw, 6.25rem); font-weight: 200; line-height: 1.1; }
.p-intro p { grid-column: 1 / -1; font-size: clamp(1.0625rem, 1.3vw, 1.25rem); line-height: 1.8; text-wrap: pretty; }
.gallery { padding: clamp(9rem, 18vw, 18rem) var(--gutter) 0; }
/* Gallery system (all category pages). Inside a project the images are one tight unit; between projects, large white space.
   single: alone, sized from its own proportions. pair / row3: side by side, equal height, widths from each image's own proportions (no crop). On mobile a row3 that contains a wide image wraps to: wide image, then the other two side by side. quad (4): 2x2. */
.proj { margin-bottom: clamp(9rem, 19vw, 19rem); --g: clamp(0.5rem, 1vw, 0.875rem); }
.unit { width: min(100%, calc(var(--s) * var(--h))); margin-inline-start: 0; margin-inline-end: auto; }
.rows { width: min(100%, var(--w)); margin-inline-start: 0; margin-inline-end: auto; }
.rows .grp + .grp { margin-top: var(--g); }
.single { --h: 38vw; }
.pair { --h: 32vw; }
.stack, .rows { --h: 38vw; }
.stack .grp { flex-wrap: wrap; }
.stack figure:first-child { flex: 0 0 100%; }
.rows .grp + .grp { margin-top: var(--g); }
.row3 { --h: 38vw; }
.single.feature { --h: 52vw; }
@media (min-width: 761px) { .unit:not(.single) { width: 100%; } }
.quad { --h: 34vw; }
.grp { display: flex; gap: var(--g); }
.single .grp { display: block; }
.grp figure { flex: var(--a, 1) 1 0; min-width: 0; min-height: 0; }
.proj img { display: block; width: 100%; height: auto; }
.quad .grp { display: grid; grid-template-columns: 1fr 1fr; aspect-ratio: 1 / 1; }
.quad img { height: 100%; object-fit: cover; }
.meta { direction: rtl; text-align: right; min-width: 0; margin-top: 1.1rem; font-size: 0.75rem; font-weight: 300; line-height: 1.8; letter-spacing: 0.04em; color: var(--mute); }
.meta .n { display: block; color: var(--ink); }
.meta .n.lat { letter-spacing: 0.2em; margin-inline-start: -0.2em; }

@media (prefers-reduced-motion: reduce) {
  .hero-nav, .hero-copy { animation: none; }
  a { transition: none !important; }
}

@media (max-width: 760px) {
  .single { --h: 80vw; }
  .pair { --h: 52vw; }
  .rows { --w: 100%; }
  .grp.stackm { flex-direction: column; }
  .grp.stackm figure { flex: none; width: 100%; }
  .stack .grp, .rows .grp { flex-direction: column; align-items: flex-start; }
  .stack figure, .stack figure:first-child, .rows figure { flex: none; width: min(100%, calc(var(--a) * 80vw)); }
  .row3 { --h: 80vw; }
  .single.feature { --h: 110vw; }
  .row3.wrapm .grp { flex-wrap: wrap; }
  .row3.wrapm .lead { flex: 0 0 100%; order: -1; }
}

/* ---- multi-page shell (index direction) ---- */
:root { --bg: #F4F2EE; }
.site-top { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: flex-end; gap: 0.75rem 2rem; padding: max(1.5rem, 3svh) var(--gutter) 0; }
.site-top .logo { font-size: 0.8125rem; letter-spacing: 0.3em; font-weight: 400; direction: ltr; }
.site-top nav { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 0.5rem 1.25rem; font-size: 0.8125rem; letter-spacing: 0.04em; }
.site-top nav a + a::before { content: "·"; margin-inline-end: 1.25rem; opacity: 0.6; }
@media (max-width: 760px) { .site-top nav { width: 100%; justify-content: space-between; gap: 0.25rem 0.5rem; font-size: 0.75rem; flex-wrap: nowrap; letter-spacing: 0.02em; } .site-top nav a + a::before { display: none; } }
.site-top nav a { transition: opacity .5s ease; }
.site-top nav a:hover { opacity: .55; }
.site-top nav a[aria-current="page"] { border-bottom: 1px solid currentColor; }
.home-intro { padding: clamp(5rem, 11vw, 11rem) var(--gutter) clamp(4rem, 8vw, 8rem); display: grid; gap: 1.25rem; font-size: clamp(1.0625rem, 1.3vw, 1.25rem); line-height: 1.8; }
.home-intro p { max-width: 56rem; }
.home-intro h1 { font-size: 0.8125rem; font-weight: 400; letter-spacing: 0.3em; direction: ltr; text-align: right; color: var(--mute); }
.idx { display: grid; grid-template-columns: minmax(0, 1fr) minmax(18rem, 30vw); gap: clamp(2rem, 5vw, 6rem); padding: 0 var(--gutter) clamp(6rem, 12vw, 12rem); align-items: stretch; }
.idx-list { border-bottom: 1px solid var(--ink); display: flex; flex-direction: column; }
.idx-row { display: block; padding: 1.4rem 0; border-top: 1px solid var(--ink); }
@media (min-width: 761px) { .idx-row { flex: 1 1 0; } }
.idx-row .no { display: inline-block; width: 2.2rem; font-size: 0.8125rem; color: var(--mute); }
.idx-row .nm { font-size: clamp(2.1rem, 4.6vw, 4.25rem); font-weight: 200; line-height: 1.1; }
.idx-row img { display: none; margin-top: 1rem; width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.idx-prev { position: sticky; top: 2rem; aspect-ratio: 4/5; overflow: hidden; background: #e4dfd6; }
.idx-prev img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; opacity: 0; transition: opacity .6s ease; }
.idx-prev img.on { opacity: 1; }
.site-foot { padding: clamp(4rem, 8vw, 8rem) var(--gutter) 3rem; display: flex; flex-wrap: wrap; gap: 0.75rem 1.75rem; font-size: 0.875rem; color: var(--mute); }
.site-foot a:hover { color: var(--ink); }
@media (max-width: 760px) {
  .idx { grid-template-columns: 1fr; }
  .idx-prev { display: none; }
  .idx-row img { display: block; }
}
