:root {
  --bg: #0E1325;
  --bg-deep: #080A16;
  --amba: #FFB320;
  --amba-deep: #A35E00;
  --tahini: #F6EEDC;
  --muted: #A9B0C7;
  --soft: #CDD2E2;
  --line: #2A3355;
  --line-2: #3A4566;
  --display: 'Secular One', 'Rubik', system-ui, sans-serif;
  --body: 'Rubik', system-ui, -apple-system, sans-serif;
  --tile: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'%3E%3Cg fill='none' stroke='%2319223F' stroke-width='2'%3E%3Crect x='24' y='24' width='32' height='32'/%3E%3Crect x='24' y='24' width='32' height='32' transform='rotate(45 40 40)'/%3E%3C/g%3E%3Cg fill='%2319223F'%3E%3Ccircle cx='40' cy='40' r='4'/%3E%3Ccircle cx='0' cy='0' r='3'/%3E%3Ccircle cx='80' cy='0' r='3'/%3E%3Ccircle cx='0' cy='80' r='3'/%3E%3Ccircle cx='80' cy='80' r='3'/%3E%3C/g%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg) var(--tile) center / 64px 64px;
  color: var(--tahini);
  font-family: var(--body);
  -webkit-tap-highlight-color: transparent;
}
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { -webkit-user-drag: none; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--amba); outline-offset: 3px; }
[lang="he"] { font-family: var(--display); }

.icon-btn {
  width: 48px; height: 48px; padding: 0;
  display: grid; place-items: center;
  background: rgba(14, 19, 37, .6);
  border: 1.5px solid var(--line);
  color: var(--tahini);
}
.icon-btn:hover { border-color: var(--muted); }
.icon-btn:disabled { opacity: .35; cursor: default; border-color: var(--line); }
.icon-btn svg { width: 22px; height: 22px; }

/* =========================================================
   Reader mode (phones and portrait screens): slides stack
   ========================================================= */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: max(12px, env(safe-area-inset-top)) 16px 12px;
  background: rgba(14, 19, 37, .92);
  border-bottom: 1.5px solid var(--line);
}
.back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-size: 15px; font-weight: 500; text-decoration: none; color: var(--soft); }
.back svg { width: 18px; height: 18px; }
.topbar-title { font-family: var(--display); font-size: 17px; color: var(--amba); }

.deck { padding: 16px 16px max(32px, env(safe-area-inset-bottom)); }
.stage { display: flex; flex-direction: column; gap: 16px; max-width: 640px; margin: 0 auto; }
.slide {
  position: relative;
  scroll-margin-top: 84px;
  padding: 28px 20px 64px;
  background: rgba(14, 19, 37, .9);
  border: 1.5px solid var(--line);
  overflow: hidden;
}
.slide-foot {
  position: absolute; left: 20px; right: 20px; bottom: 20px;
  display: flex; justify-content: space-between;
  font-size: 12px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--muted);
}
.controls { display: none; }

.eyebrow { font-size: 13px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--amba); }
.headline { margin-top: 10px; font-family: var(--display); font-weight: 400; font-size: 28px; line-height: 1.12; color: var(--tahini); text-wrap: balance; }

/* title */
.s-title { padding: 56px 20px; text-align: center; }
.decor { position: absolute; height: auto; pointer-events: none; }
.dc-1 { left: -8px; top: 14px; width: 64px; transform: rotate(-16deg); }
.dc-2 { right: 6px; top: 18px; width: 54px; transform: rotate(14deg); }
.dc-3 { left: 10px; bottom: 12px; width: 52px; transform: rotate(14deg); }
.dc-4 { right: 4px; bottom: 10px; width: 64px; transform: rotate(-24deg); }
.dc-5, .dc-6 { display: none; }
.title-wrap { position: relative; display: flex; flex-direction: column; align-items: center; }
.s-title .he { font-size: 17px; letter-spacing: .06em; color: var(--muted); }
.logo { position: relative; margin-top: 6px; display: flex; flex-direction: column; align-items: center; font-weight: 400; }
.logo-line {
  display: block; font-family: var(--display);
  font-size: 64px; line-height: .92; letter-spacing: -.01em;
  color: var(--amba);
  text-shadow: 0 .06em 0 var(--amba-deep), 0 .13em .22em rgba(0, 0, 0, .5);
}
.logo-small { margin-top: 6px; font-size: 34px; color: var(--tahini); text-shadow: 0 .08em 0 #000; }
.blade {
  position: absolute; left: -4%; top: 50%;
  width: 108%; height: 3px; border-radius: 3px;
  background: #fff;
  box-shadow: 0 0 14px 3px rgba(255, 179, 32, .6);
  transform: rotate(-8deg);
}
.tagline { margin-top: 28px; max-width: 30ch; font-size: 17px; line-height: 1.5; color: var(--soft); text-wrap: balance; }
.byline { margin-top: 18px; font-family: var(--display); font-size: 18px; color: var(--tahini); }

/* intro */
.points { margin-top: 18px; display: flex; flex-direction: column; gap: 14px; }
.points li { padding-left: 18px; position: relative; font-size: 16px; line-height: 1.55; color: var(--soft); }
.points li::before { content: ""; position: absolute; left: 0; top: .6em; width: 8px; height: 8px; background: var(--amba); transform: rotate(45deg); }
.stat { margin-top: 22px; padding: 18px; border: 2px dashed var(--amba); }
.stat-num { font-family: var(--display); font-size: 52px; line-height: 1; color: var(--amba); text-shadow: 0 .06em 0 var(--amba-deep); }
.stat-label { margin-top: 10px; font-size: 15px; line-height: 1.5; color: var(--soft); }

/* overview */
.menu { margin-top: 18px; display: grid; grid-template-columns: 1fr; border-top: 1.5px solid var(--line); }
.menu li { display: flex; align-items: center; gap: 14px; padding: 10px 0; border-bottom: 1.5px solid var(--line); }
.menu img { width: 44px; height: 44px; flex: none; }
.menu b { display: block; font-family: var(--display); font-weight: 400; font-size: 19px; line-height: 1.15; color: var(--tahini); }
.menu span { display: block; margin-top: 2px; font-size: 14px; color: var(--muted); }

/* food */
.food-art { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.art-ring {
  position: relative;
  width: 132px; height: 132px; border-radius: 50%;
  display: grid; place-items: center;
  box-shadow: 0 0 0 8px rgba(255, 179, 32, .08);
}
.art-ring::before { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2.5px dashed var(--amba); }
.art-ring img { width: 66%; height: 66%; }
.art-pair { grid-template-columns: 1fr 1fr; }
.art-pair img { width: 100%; height: auto; }
.art-pair img:first-child { justify-self: end; margin-right: -6%; transform: translateY(-14%); }
.art-pair img:last-child { justify-self: start; margin-left: -6%; transform: translateY(16%); }
.route { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 0; font-size: 12px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--soft); }
.route li { white-space: nowrap; }
.route li + li::before { content: "→"; margin: 0 8px; color: var(--amba); letter-spacing: 0; }
.food-body { margin-top: 22px; }
.food-name { margin-top: 6px; font-family: var(--display); font-weight: 400; font-size: 40px; line-height: 1.02; color: var(--amba); text-shadow: 0 .06em 0 var(--amba-deep); }
.food-name .he { display: block; margin-top: 6px; font-size: 18px; color: var(--muted); text-shadow: none; text-align: left; white-space: nowrap; }
.facts { margin-top: 18px; border-top: 1.5px solid var(--line); }
.facts div { padding: 12px 0; border-bottom: 1.5px solid var(--line); }
.facts dt { font-size: 12px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin-top: 6px; font-size: 16px; line-height: 1.55; color: var(--soft); }
.facts i, .points i { color: var(--tahini); }

/* closing */
.headline-amba { color: var(--amba); }
.s-close .headline { color: var(--amba); text-shadow: 0 .06em 0 var(--amba-deep); font-size: 34px; }
.close-text { margin-top: 14px; font-size: 16px; line-height: 1.55; color: var(--soft); }
.thanks { margin-top: 18px; font-family: var(--display); font-size: 22px; color: var(--tahini); }
.thanks [lang="he"] { color: var(--amba); margin-right: 6px; }
.layers { margin-top: 22px; display: flex; flex-direction: column; }
.layers::before, .layers::after { content: ""; height: 14px; background: #E7C38A; border: 1.5px solid #B98846; }
.layers li { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; }
.layers b { font-family: var(--display); font-weight: 400; font-size: 18px; line-height: 1.2; }
.layers span { font-size: 13px; }
.layers li:nth-child(1) { background: #4A2A5E; color: var(--tahini); }
.layers li:nth-child(2) { background: var(--amba); color: var(--bg); }
.layers li:nth-child(3) { background: #3F6B1F; color: var(--tahini); }
.layers li:nth-child(4) { background: #B02F17; color: var(--tahini); }
.layers li:nth-child(5) { background: var(--tahini); color: var(--bg); }

/* references */
.refs-title { font-family: var(--display); font-weight: 400; font-size: 30px; color: var(--amba); text-align: center; }
.refs-title span { font-family: var(--body); font-size: .55em; color: var(--muted); }
.refs { margin-top: 18px; display: flex; flex-direction: column; gap: 14px; }
.refs li { padding-left: 28px; text-indent: -28px; font-size: 14px; line-height: 1.6; color: var(--soft); }
.refs a { color: var(--soft); text-decoration-color: var(--line-2); overflow-wrap: anywhere; }
.refs a:hover { color: var(--amba); text-decoration-color: var(--amba); }
.refs i { color: var(--tahini); }

/* =========================================================
   Stage mode (landscape screens): one 1920×1080 slide at a time
   ========================================================= */
@media (orientation: landscape) and (min-width: 600px) {
  html, body { height: 100%; overflow: hidden; }
  body { position: fixed; inset: 0; background-size: 80px 80px; overscroll-behavior: none; }
  .topbar { display: none; }

  .deck { position: fixed; left: 0; right: 0; top: 0; bottom: 88px; padding: 0; transition: bottom .25s ease; }
  .stage {
    position: absolute; left: 50%; top: 50%;
    width: 1920px; height: 1080px; max-width: none; margin: 0;
    display: block;
    transform: translate(-50%, -50%) scale(var(--s, .5));
    background: var(--bg) var(--tile) center / 80px 80px;
    outline: 3px solid var(--line);
    box-shadow: 0 24px 80px rgba(0, 0, 0, .55);
    overflow: hidden;
  }
  .slide {
    position: absolute; inset: 0;
    padding: 112px 128px 160px;
    background: none; border: 0;
    opacity: 0; visibility: hidden;
    transition: opacity .3s ease, visibility 0s linear .3s;
  }
  .slide.is-active { opacity: 1; visibility: visible; transition: opacity .3s ease; }
  .is-instant .slide { transition: none !important; }
  .slide-foot { left: 128px; right: 128px; bottom: 64px; font-size: 24px; }

  .eyebrow { font-size: 26px; }
  .headline { margin-top: 18px; font-size: 76px; line-height: 1.08; }

  /* title */
  .s-title { padding: 0; display: grid; place-items: center; text-align: center; }
  .dc-1 { left: 150px; top: 130px; width: 200px; }
  .dc-2 { left: auto; right: 190px; top: 150px; width: 170px; }
  .dc-3 { left: 230px; top: auto; bottom: 170px; width: 180px; }
  .dc-4 { left: auto; right: 200px; top: auto; bottom: 200px; width: 230px; }
  .dc-5 { display: block; left: 560px; top: 70px; width: 110px; transform: rotate(20deg); }
  .dc-6 { display: block; left: auto; right: 560px; top: auto; bottom: 80px; width: 190px; transform: rotate(-10deg); }
  .s-title .he { font-size: 34px; }
  .logo { margin-top: 14px; }
  .logo-line { font-size: 250px; }
  .logo-small { margin-top: 18px; font-size: 118px; }
  .blade { height: 7px; }
  .tagline { margin-top: 64px; max-width: none; font-size: 40px; }
  .byline { margin-top: 32px; font-size: 36px; }
  .decor { animation: float 5s ease-in-out infinite; }
  .dc-1 { --r: -16deg; } .dc-2 { --r: 14deg; animation-delay: -1.2s; } .dc-3 { --r: 14deg; animation-delay: -2.1s; }
  .dc-4 { --r: -24deg; animation-delay: -3s; } .dc-5 { --r: 20deg; animation-delay: -.6s; } .dc-6 { --r: -10deg; animation-delay: -1.7s; }

  /* intro */
  .s-intro { display: grid; grid-template-columns: 1fr 600px; gap: 104px; align-items: center; }
  .points { margin-top: 48px; gap: 30px; }
  .points li { padding-left: 40px; font-size: 32px; line-height: 1.45; }
  .points li::before { top: .55em; width: 14px; height: 14px; }
  .stat { margin: 0; padding: 48px 40px; }
  .stat-num { font-size: 124px; white-space: nowrap; }
  .stat-label { margin-top: 22px; font-size: 32px; line-height: 1.4; }

  /* overview */
  .menu { margin-top: 48px; grid-template-columns: repeat(3, 1fr); gap: 24px; border: 0; }
  .menu li { gap: 26px; padding: 24px 28px; border: 1.5px solid var(--line); background: rgba(14, 19, 37, .7); }
  .menu img { width: 96px; height: 96px; }
  .menu b { font-size: 42px; }
  .menu span { margin-top: 6px; font-size: 26px; }

  /* food */
  .s-food { display: grid; grid-template-columns: 520px 1fr; gap: 104px; align-items: center; }
  .food-art { gap: 44px; }
  .art-ring { width: 440px; height: 440px; box-shadow: 0 0 0 18px rgba(255, 179, 32, .08); }
  .art-ring::before { border-width: 5px; }
  .route { font-size: 24px; gap: 10px 0; max-width: 520px; }
  .route li + li::before { margin: 0 14px; }
  .food-body { margin: 0; }
  .food-name { margin-top: 10px; font-size: 104px; }
  .food-name.is-long { font-size: 84px; }
  .food-name .he { display: inline; margin: 0 0 0 20px; font-size: 44px; vertical-align: middle; }
  .facts { margin-top: 28px; }
  .facts div { padding: 16px 0 18px; }
  .facts dt { font-size: 22px; }
  .facts dd { margin-top: 8px; font-size: 29px; line-height: 1.4; }

  /* closing */
  .s-close { display: grid; grid-template-columns: 1fr 600px; gap: 112px; align-items: center; }
  .s-close .headline { font-size: 116px; line-height: 1; }
  .close-text { margin-top: 40px; font-size: 34px; line-height: 1.45; }
  .thanks { margin-top: 48px; font-size: 52px; }
  .thanks [lang="he"] { margin-right: 14px; }
  .layers { margin: 0; }
  .layers::before, .layers::after { height: 40px; border-width: 3px; }
  .layers::before { border-radius: 0; }
  .layers li { padding: 20px 32px 22px; gap: 4px; }
  .layers b { font-size: 40px; }
  .layers span { font-size: 26px; }

  /* references */
  .s-refs { padding-top: 96px; }
  .refs-title { font-size: 76px; }
  .refs { margin-top: 40px; gap: 22px; }
  .refs li { padding-left: 64px; text-indent: -64px; font-size: 27px; line-height: 1.5; }

  /* controls */
  .controls {
    position: fixed; left: 0; right: 0; bottom: 0; height: 88px; z-index: 10;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 max(24px, env(safe-area-inset-right)) 0 max(24px, env(safe-area-inset-left));
    transition: opacity .25s ease, transform .25s ease;
  }
  .ctl-back { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; font-size: 15px; font-weight: 500; text-decoration: none; color: var(--soft); }
  .ctl-back:hover { color: var(--amba); }
  .ctl-back svg { width: 18px; height: 18px; }
  .ctl-mid { position: absolute; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 16px; }
  .count { min-width: 112px; text-align: center; font-family: var(--display); font-size: 26px; color: var(--amba); font-variant-numeric: tabular-nums; }
  .count-of { color: var(--muted); }

  /* full screen: slide fills, controls hide while idle */
  .is-fs .deck { bottom: 0; }
  .is-fs .stage { outline: 0; box-shadow: none; }
  .is-fs .controls { background: rgba(8, 10, 22, .8); }
  .is-fs.is-idle .controls { opacity: 0; transform: translateY(100%); pointer-events: none; }
  .is-fs.is-idle { cursor: none; }
}

@media (orientation: landscape) and (min-width: 600px) and (max-height: 520px) {
  .deck { bottom: 64px; }
  .controls { height: 64px; }
  .ctl-back span { display: none; }
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(var(--r)); }
  50% { transform: translateY(-14px) rotate(calc(var(--r) + 4deg)); }
}
@media (prefers-reduced-motion: reduce) {
  .decor { animation: none !important; }
  .slide, .slide.is-active, .controls, .deck { transition: none !important; }
}
