/* אלבומים מהגלריה · סגנון "מחברת קולאז'" */
:root {
  --paper: #F7EFE2;
  --paper-2: #EFE3D0;
  --card: #FFFDF9;
  --ink: #2B2320;
  --muted: #7A6E66;
  --line: #E4D6C2;
  --accent: #E2574C;
  --on-accent: #fff;
  --yellow: #F4B63F;
  --mint: #9FD8C6;
  --pink: #F5B5C4;
  --sky: #A9CBEA;
  --tape: rgba(255, 226, 130, .78);
  --shadow: 0 10px 24px -12px rgba(70, 40, 20, .45);
  --radius: 20px;
  --hand: 'Amatic SC', 'Heebo', cursive;
  --head: 'Rubik', 'Heebo', sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: 'Heebo', system-ui, sans-serif; font-size: 17px; line-height: 1.55; color: var(--ink);
  background: var(--paper);
  background-image: radial-gradient(rgba(120, 90, 60, .08) 1px, transparent 1px);
  background-size: 16px 16px;
  min-height: 100vh;
}
h1, h2, h3 { font-family: var(--head); font-weight: 900; line-height: 1.15; margin: 0; text-wrap: balance; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
img { max-width: 100%; }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }
.muted { color: var(--muted); }
.hand { font-family: var(--hand); font-weight: 700; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 8px; }

.app { max-width: 720px; margin: 0 auto; padding: 0 16px 120px; }

/* ---------- ראש ---------- */
.top { display: flex; align-items: center; gap: 12px; padding: 18px 0 10px; }
.top__title { flex: 1; min-width: 0; }
.top h1 { font-size: 26px; }
.top small { display: block; color: var(--muted); font-size: 15px; }
.icon-btn { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: var(--card); border: 1.5px solid var(--line); text-decoration: none; flex: none; }
.i { width: 22px; height: 22px; flex: none; }

.hello { padding: 22px 0 6px; }
.hello h1 { font-size: 34px; }
.hello h1 .hand { font-size: 46px; color: var(--accent); display: inline-block; rotate: -3deg; }
.hello p { margin: 4px 0 0; color: var(--muted); }

/* ---------- כפתורים ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 22px; border-radius: 16px; border: 0; font-weight: 800; font-size: 17px; text-decoration: none; background: var(--card); border: 1.5px solid var(--ink); }
.btn--primary { background: var(--accent); color: var(--on-accent); border-color: var(--accent); box-shadow: 0 8px 18px -10px var(--accent); }
.btn--dark { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn--ghost { background: transparent; border-color: var(--line); }
.btn--sm { min-height: 44px; padding: 0 14px; font-size: 15px; border-radius: 12px; }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: default; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; margin: 14px 0; }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 10px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; min-height: 44px; padding: 0 16px; border-radius: 99px; border: 1.5px solid var(--ink); background: var(--card); font-weight: 700; font-size: 15px; display: inline-flex; align-items: center; gap: 6px; }
.chip.on { background: var(--ink); color: var(--paper); }
.chip em { font-style: normal; opacity: .65; font-size: 13px; }

/* ---------- כרטיסים ---------- */
.card { background: var(--card); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 20px; margin: 14px 0; }
.card h2 { font-size: 21px; margin-bottom: 6px; }
.card p { margin: 6px 0; }
.note { background: #FFF4D6; border: 1.5px dashed #E6B84E; border-radius: 16px; padding: 14px 16px; font-size: 16px; margin: 12px 0; }
.empty { text-align: center; padding: 34px 18px; }
.empty h2 { font-size: 26px; margin: 10px 0 6px; }
.empty p { color: var(--muted); margin: 0 auto 18px; max-width: 420px; }
.empty .doodle-big { width: 120px; height: 120px; margin: 0 auto; display: block; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 12px 0 4px; }
.stat { background: var(--card); border: 1.5px solid var(--line); border-radius: 18px; padding: 12px; text-align: center; }
.stat b { display: block; font-family: var(--head); font-size: 28px; font-weight: 900; line-height: 1.1; }
.stat span { font-size: 14px; color: var(--muted); }

/* ---------- רשת אלבומים ---------- */
.albums { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px 16px; margin-top: 10px; }
@media (min-width: 620px) { .albums { grid-template-columns: repeat(3, 1fr); } }
.album-card { text-decoration: none; display: block; position: relative; }
.album-card .pol { position: relative; background: #fff; padding: 8px 8px 34px; box-shadow: var(--shadow); rotate: var(--r, -2deg); transition: rotate .2s, translate .2s; }
.album-card:hover .pol { rotate: 0deg; translate: 0 -3px; }
.album-card .pol img, .album-card .pol .ph { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--paper-2); }
.album-card .pol .cap { position: absolute; bottom: 2px; inset-inline: 6px; text-align: center; font-family: var(--hand); font-size: 24px; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.album-card .tape { position: absolute; top: -9px; left: 50%; translate: -50% 0; rotate: -5deg; width: 64px; height: 20px; background: var(--tape); }
.album-card .meta { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; font-size: 14px; color: var(--muted); padding-inline: 4px; }
.badge { display: inline-block; font-size: 13px; font-weight: 800; padding: 2px 10px; border-radius: 99px; background: var(--b, var(--mint)); color: var(--ink); }
.badge--simcha { --b: #FFD2C8; }
.badge--trip { --b: #CDEDE2; }
.badge--holiday { --b: #FFE7A8; }

/* ---------- עמודי האלבום ---------- */
.album-head .title-in { width: 100%; font-family: var(--hand); font-size: 40px; font-weight: 700; border: 0; border-bottom: 2px dashed var(--line); background: transparent; padding: 0 2px; }
.opts { display: grid; gap: 4px; margin: 8px 0; }
.opts > span { font-weight: 800; font-size: 15px; }
.pages { display: grid; gap: 22px; margin: 18px 0; }
.page {
  position: relative; width: 100%; aspect-ratio: var(--ar, 1);
  background: var(--paper); border-radius: 6px; overflow: hidden;
  background-image: radial-gradient(rgba(120, 90, 60, .09) 1px, transparent 1px); background-size: 3.2% 3.2%;
  box-shadow: 0 16px 34px -18px rgba(70, 40, 20, .55), inset 0 0 0 1px rgba(120, 90, 60, .12);
  container-type: inline-size;
}
.page__no { position: absolute; bottom: 1.6%; left: 50%; translate: -50% 0; font-family: var(--hand); font-size: 4.2cqw; color: var(--muted); }
.slot { position: absolute; background: #fff; padding: 2.2cqw 2.2cqw 7.5cqw; box-shadow: 0 2.2cqw 4cqw -1.6cqw rgba(50, 30, 15, .5); border: 0; cursor: pointer; display: block; }
.slot img { display: block; width: 100%; height: 100%; object-fit: cover; background: var(--paper-2); }
.slot .cap { position: absolute; bottom: .6cqw; inset-inline: 1cqw; text-align: center; font-family: var(--hand); font-weight: 700; font-size: 5.2cqw; line-height: 1.15; color: var(--ink); white-space: nowrap; overflow: hidden; }
.slot .tp { position: absolute; top: -2.2cqw; left: 50%; translate: -50% 0; width: 22%; min-width: 9cqw; height: 4.4cqw; background: var(--tape); rotate: var(--tr, -4deg); }
.slot.big-mark::after { content: ''; position: absolute; top: 3cqw; right: 3cqw; width: 6cqw; height: 6cqw; border-radius: 50%; background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.6' stroke-linecap='round'%3E%3Cpath d='M12 4l2.4 5 5.6.8-4 3.9 1 5.5L12 16.6 7 19.2l1-5.5-4-3.9 5.6-.8z'/%3E%3C/svg%3E") center/70% no-repeat; }
.sticker { position: absolute; pointer-events: none; }
.cover-title { position: absolute; inset-inline: 6%; bottom: 7%; text-align: center; }
.cover-title b { display: block; font-family: var(--hand); font-size: 12cqw; line-height: 1; color: var(--ink); }
.cover-title small { display: block; font-family: var(--hand); font-size: 6cqw; color: var(--muted); margin-top: 1cqw; }
.end-page { display: grid; place-items: center; text-align: center; }
.end-page b { font-family: var(--hand); font-size: 14cqw; line-height: 1; }
.end-page small { display: block; font-family: var(--hand); font-size: 6cqw; color: var(--muted); }

/* ---------- רשת תמונות ---------- */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
@media (min-width: 620px) { .grid { grid-template-columns: repeat(4, 1fr); } }
.tile { position: relative; border: 0; padding: 0; background: var(--paper-2); border-radius: 12px; overflow: hidden; aspect-ratio: 1; }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile .why { position: absolute; bottom: 6px; inset-inline: 6px; font-size: 12px; font-weight: 800; background: rgba(43, 35, 32, .82); color: #fff; border-radius: 99px; padding: 2px 8px; text-align: center; }
.group-h { display: flex; justify-content: space-between; align-items: center; margin: 22px 0 10px; }
.group-h h2 { font-size: 20px; }

/* ---------- קיר ---------- */
.wall { display: grid; gap: 24px; }
.wall-item { background: var(--card); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 14px; }
.wall-item .pol { background: #fff; padding: 10px 10px 14px; box-shadow: var(--shadow); rotate: var(--r, -1deg); }
.wall-item img { display: block; width: 100%; max-height: 420px; object-fit: cover; }
.wall-item .info { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: space-between; margin-top: 14px; }
.wall-item .info b { font-size: 18px; }

/* ---------- ייבוא ---------- */
.source { display: flex; gap: 14px; align-items: center; text-align: start; width: 100%; background: var(--card); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 18px; margin: 12px 0; position: relative; cursor: pointer; }
.source:hover { border-color: var(--ink); }
.source .ico { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; background: var(--b, #FFE7A8); flex: none; }
.source .ico .i { width: 28px; height: 28px; }
.source b { display: block; font-size: 19px; font-family: var(--head); }
.source small { color: var(--muted); font-size: 15px; }
.source input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.progress { height: 14px; border-radius: 99px; background: var(--paper-2); overflow: hidden; margin: 14px 0 8px; }
.progress i { display: block; height: 100%; background: var(--accent); border-radius: 99px; transition: width .25s; }
.reasons { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.reasons span { background: var(--paper-2); border-radius: 99px; padding: 4px 12px; font-size: 14px; font-weight: 700; }

/* ---------- ניווט ---------- */
.nav { position: fixed; bottom: 12px; left: 50%; translate: -50% 0; width: min(560px, calc(100% - 24px)); height: 68px; background: var(--ink); color: #CFC3B5; border-radius: 24px; display: flex; justify-content: space-around; align-items: stretch; padding: 0 6px; z-index: 20; box-shadow: 0 14px 30px -12px rgba(43, 35, 32, .6); }
.nav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-decoration: none; font-size: 12px; font-weight: 700; border-radius: 18px; min-width: 48px; }
.nav a.on { color: var(--yellow); }
.nav a.add { color: var(--paper); }
.nav a.add .i { background: var(--accent); border-radius: 14px; width: 40px; height: 32px; padding: 5px 8px; color: #fff; }

.savebar { position: fixed; bottom: 92px; left: 50%; translate: -50% 0; width: min(560px, calc(100% - 32px)); z-index: 15; }

/* ---------- חלונית תחתונה ---------- */
.sheet-bg { position: fixed; inset: 0; background: rgba(30, 20, 15, .45); z-index: 40; display: flex; align-items: flex-end; justify-content: center; }
.sheet { width: min(620px, 100%); max-height: 86vh; overflow: auto; background: var(--paper); border-radius: 26px 26px 0 0; padding: 12px 18px 26px; box-shadow: 0 -10px 30px rgba(0, 0, 0, .2); }
.sheet .grab { width: 46px; height: 5px; border-radius: 99px; background: var(--line); margin: 0 auto 14px; }
.sheet .preview { display: block; width: 100%; max-height: 42vh; object-fit: contain; border-radius: 12px; background: var(--paper-2); }
.sheet h2 { font-size: 21px; margin: 14px 0 4px; }
.sheet .acts { display: grid; gap: 10px; margin-top: 14px; }
.sheet .acts .btn { justify-content: flex-start; }

.f { display: grid; gap: 6px; margin: 12px 0; }
.f label { font-weight: 800; font-size: 15px; }
.f input[type=text] { min-height: 50px; border: 1.5px solid var(--line); border-radius: 14px; padding: 0 14px; background: var(--card); }

/* ---------- הודעה קופצת ---------- */
.toast { position: fixed; bottom: 96px; left: 50%; translate: -50% 20px; background: var(--ink); color: var(--paper); padding: 12px 18px; border-radius: 16px; display: flex; gap: 14px; align-items: center; opacity: 0; pointer-events: none; transition: .2s; z-index: 60; max-width: calc(100% - 32px); font-weight: 600; }
.toast.on { opacity: 1; translate: -50% 0; pointer-events: auto; }
.toast button { background: none; border: 0; color: var(--yellow); font-weight: 800; min-height: 40px; }

/* ---------- מסך הדפסה ---------- */
.print-bar { position: sticky; top: 0; z-index: 10; background: var(--ink); color: var(--paper); padding: 14px 16px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.print-bar p { margin: 0; flex: 1 1 260px; font-size: 16px; }
.print-bar .btn { border-color: var(--paper); }
.print-pages { display: grid; gap: 24px; justify-items: center; padding: 24px 12px 60px; }
.print-pages .page { width: min(100%, 640px); border-radius: 0; }
@media print {
  body { background: #fff; }
  .print-bar, .nav, .toast { display: none !important; }
  .print-pages { display: block; padding: 0; }
  .print-pages .page { width: var(--pw); height: var(--ph); aspect-ratio: auto; box-shadow: none; break-after: page; page-break-after: always; margin: 0; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

@media (min-width: 900px) {
  .app { padding-bottom: 130px; }
}

/* ---------- בחירת סגנון ---------- */
.styles-pick { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 620px) { .styles-pick { grid-template-columns: repeat(4, 1fr); } }
.style-card { text-align: start; background: var(--card); border: 1.5px solid var(--line); border-radius: 16px; padding: 10px 12px; min-height: 64px; display: grid; gap: 4px; }
.style-card.on { border-color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.style-card .sw { display: flex; gap: 4px; }
.style-card .sw i { width: 22px; height: 22px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .15); }
.style-card b { font-size: 15px; }
.style-card small { font-size: 12px; color: var(--accent); font-weight: 700; }

/* ---------- סגנון: יומן מסע (טיולים) ---------- */
.page--journey {
  background-color: #D8BE95;
  background-image: radial-gradient(rgba(90, 60, 30, .16) 1px, transparent 1.2px), radial-gradient(rgba(255, 255, 255, .18) 1px, transparent 1.2px);
  background-size: 2.6% 2.6%, 3.7% 3.7%; background-position: 0 0, 1.3% 1.9%;
  box-shadow: 0 16px 34px -18px rgba(70, 40, 20, .6), inset 0 0 6cqw rgba(90, 55, 25, .25);
}
.page--journey .slot { background: #FFF8EC; padding: 1.8cqw; }
.page--journey .tp { background: rgba(214, 190, 150, .9); box-shadow: 0 .3cqw .6cqw rgba(0, 0, 0, .12); }
.page--journey .cap { font-family: 'Karantina', var(--head); font-weight: 700; font-size: 4.6cqw; color: #4A3526; bottom: -3.4cqw; inset-inline: auto; right: 2cqw; background: #FFF8EC; padding: .2cqw 2cqw; border: .25cqw dashed #4A3526; border-radius: 1cqw; }
.page--journey .route { position: absolute; inset: 0; width: 100%; height: 100%; }
.page--journey .cover-title b { font-family: 'Karantina', var(--head); font-weight: 700; font-size: 13cqw; color: #4A3526; }
.page--journey .cover-title small, .page--journey .end-page small { font-family: 'Karantina', var(--head); font-size: 5.4cqw; color: #6B5442; }
.page--journey.end-page b { font-family: 'Karantina', var(--head); color: #4A3526; }
.page--journey .page__no { font-family: 'Karantina', var(--head); color: #6B5442; }

/* ---------- סגנון: חגיגי ואלגנטי (שמחות) ---------- */
.page--elegant { background: #FBF8F2; box-shadow: 0 16px 34px -18px rgba(70, 50, 20, .45), inset 0 0 0 1px rgba(184, 150, 79, .25); }
.page--elegant .slot { background: #fff; padding: 1.1cqw; border: .3cqw solid #B8964F; box-shadow: 0 1.4cqw 3cqw -2cqw rgba(60, 40, 10, .45); }
.page--elegant .orn { position: absolute; width: 11%; pointer-events: none; }
.page--elegant .orn--tl { top: 2.6%; left: 2.6%; }
.page--elegant .orn--tr { top: 2.6%; right: 2.6%; scale: -1 1; }
.page--elegant .orn--bl { bottom: 2.6%; left: 2.6%; scale: 1 -1; }
.page--elegant .orn--br { bottom: 2.6%; right: 2.6%; scale: -1 -1; }
.page--elegant .cover-title b, .page--elegant.end-page b { font-family: 'Frank Ruhl Libre', serif; font-weight: 700; font-size: 9cqw; color: #2B2320; letter-spacing: .02em; }
.page--elegant .cover-title small, .page--elegant.end-page small { font-family: 'Frank Ruhl Libre', serif; font-weight: 500; font-size: 3.8cqw; color: #8C6E33; letter-spacing: .08em; }
.page--elegant .cover-title { bottom: 9%; }
.page--elegant .page__no { font-family: 'Frank Ruhl Libre', serif; font-size: 3cqw; color: #8C6E33; }

/* ---------- סגנון: חג שמח (מעגל השנה) ---------- */
.page--festive {
  background-color: var(--fbg, #1F3A68);
  background-image:
    radial-gradient(circle, rgba(242, 193, 78, .9) .5cqw, transparent .6cqw),
    radial-gradient(circle, rgba(255, 255, 255, .55) .35cqw, transparent .45cqw),
    radial-gradient(ellipse at 50% 0%, rgba(255, 255, 255, .14), transparent 60%);
  background-size: 23% 21%, 17% 19%, 100% 100%; background-position: 4% 6%, 61% 33%, 0 0;
}
.page--festive .slot { background: #fff; padding: 1.5cqw; border-radius: 3cqw; box-shadow: 0 2cqw 4cqw -1.5cqw rgba(0, 0, 0, .55); }
.page--festive .slot img { border-radius: 2cqw; }
.page--festive .cap { position: absolute; bottom: -4cqw; inset-inline: 10%; background: #F2C14E; color: #2B2320; border-radius: 99px; font-family: var(--head); font-weight: 800; font-size: 3.4cqw; padding: .4cqw 1cqw; }
.page--festive .cover-title b, .page--festive.end-page b { font-family: var(--head); font-weight: 900; font-size: 11cqw; color: #fff; text-shadow: 0 .6cqw 2cqw rgba(0, 0, 0, .3); }
.page--festive .cover-title small, .page--festive.end-page small { font-family: var(--head); font-weight: 700; font-size: 4.4cqw; color: #F2C14E; }
.page--festive .page__no { color: rgba(255, 255, 255, .75); font-family: var(--head); font-size: 3cqw; }

/* ---------- נגישות ---------- */
.skip { position: absolute; top: -60px; right: 12px; z-index: 100; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 12px; font-weight: 800; }
.skip:focus { top: 12px; }
main.app:focus { outline: none; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- דפדוף באלבום ---------- */
.book-view { min-height: 100vh; padding: 12px 16px 28px; background: radial-gradient(ellipse at 50% 40%, #FFF9F0 0%, #E9DCC8 75%); }
.book-top { display: flex; gap: 12px; align-items: center; max-width: 1100px; margin: 0 auto; }
.book-top h1 { font-size: 22px; }
.book-top small { color: var(--muted); font-size: 15px; }
.book-sizes { max-width: 1100px; margin: 8px auto 0; }
.stage { display: flex; align-items: flex-end; justify-content: center; gap: 20px; margin: 10px auto 0; max-width: 1100px; perspective: 2600px; touch-action: pan-y; user-select: none; cursor: pointer; }
.phone-ref { flex: none; order: 2; border: 2px dashed rgba(43, 35, 32, .45); border-radius: 12%/6%; display: grid; place-items: center; text-align: center; font-size: 12px; font-weight: 700; color: var(--muted); line-height: 1.3; }
.book { position: relative; width: calc(var(--w) * 2); height: var(--h); transform-style: preserve-3d; transition: transform .75s cubic-bezier(.3, .7, .3, 1); flex: none; }
.book::after { content: ''; position: absolute; inset: auto 4% -14px; height: 18px; background: radial-gradient(ellipse, rgba(60, 35, 15, .35), transparent 70%); transform: translateZ(-1px); transition: inset .75s; }
.book.closed { transform: translateX(25%); }
.book.closed::after { inset: auto 52% -14px 2%; }
.book.closed-end { transform: translateX(-25%); }
.book.closed-end::after { inset: auto 2% -14px 52%; }
.book.instant, .book.instant .leaf { transition: none !important; }
.leaf { position: absolute; left: 0; top: 0; width: 50%; height: 100%; transform-origin: right center; transform-style: preserve-3d; transition: transform .75s cubic-bezier(.3, .7, .3, 1); }
.leaf.flipped { transform: rotateY(-180deg); }
.face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; overflow: hidden; background: #FFFDF8; }
.face.back { transform: rotateY(180deg); }
.face.front { box-shadow: -1px 0 0 rgba(0, 0, 0, .06), -3px 2px 0 -1px #F3EBDD, -5px 3px 0 -2px #E6DAC7, -7px 6px 12px -6px rgba(60, 35, 15, .35); }
.face.back { box-shadow: 1px 0 0 rgba(0, 0, 0, .06), 3px 2px 0 -1px #F3EBDD, 5px 3px 0 -2px #E6DAC7, 7px 6px 12px -6px rgba(60, 35, 15, .35); }
.face.front::after, .face.back::after { content: ''; position: absolute; inset: 0; pointer-events: none; }
.face.front::after { background: linear-gradient(to left, rgba(40, 25, 10, .28), rgba(40, 25, 10, .06) 7%, transparent 16%); }
.face.back::after { background: linear-gradient(to right, rgba(40, 25, 10, .28), rgba(40, 25, 10, .06) 7%, transparent 16%); }
.leaf.turning .face::after { background: linear-gradient(to left, rgba(40, 25, 10, .35), transparent 40%); }
.face .page { width: 100%; height: 100%; aspect-ratio: auto; border-radius: 0; box-shadow: none; }
.face .page .slot { cursor: inherit; }
.face .page.blank { background-image: none; }
.endpaper { position: absolute; inset: 0; background: #EFE3D0 radial-gradient(rgba(120, 90, 60, .18) 1px, transparent 1.4px) 0 0 / 9% 9%; }
.endpaper--journey { background-color: #C9AE85; }
.endpaper--elegant { background: #F6F0E4 repeating-linear-gradient(45deg, rgba(184, 150, 79, .14) 0 1px, transparent 1px 12px); }
.endpaper--festive { background-color: #F2C14E; }
.hardcover { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6%; padding: 9%; text-align: center; container-type: inline-size; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15), inset -8px 0 14px -6px rgba(0, 0, 0, .35); }
.hardcover img { width: 72%; aspect-ratio: 1; object-fit: cover; background: rgba(255, 255, 255, .3); }
.hardcover b { font-size: 10cqw; line-height: 1.05; }
.hardcover small { font-size: 6cqw; opacity: .8; }
.hardcover--scrapbook { background: #E2574C repeating-linear-gradient(0deg, rgba(255, 255, 255, .05) 0 2px, transparent 2px 5px); color: #fff; }
.hardcover--scrapbook img { padding: 3% 3% 12%; background: #fff; rotate: -3deg; box-shadow: 0 6px 14px -6px rgba(0, 0, 0, .5); }
.hardcover--scrapbook b, .hardcover--scrapbook small { font-family: var(--hand); font-size: 14cqw; }
.hardcover--journey { background: #6E4E35 radial-gradient(rgba(0, 0, 0, .18) 1px, transparent 1.4px) 0 0 / 4% 4%; color: #F3E4C8; }
.hardcover--journey img { border: 4cqw solid #FFF8EC; outline: 1px dashed #F3E4C8; outline-offset: 2cqw; }
.hardcover--journey b, .hardcover--journey small { font-family: 'Karantina', var(--head); font-size: 13cqw; letter-spacing: .03em; }
.hardcover--elegant { background: #F1E9DA; color: #2B2320; box-shadow: inset 0 0 0 4cqw #F1E9DA, inset 0 0 0 calc(4cqw + 1px) #B8964F, inset -8px 0 14px -6px rgba(0, 0, 0, .25); }
.hardcover--elegant img { border: 1.5cqw solid #fff; outline: 1px solid #B8964F; }
.hardcover--elegant b, .hardcover--elegant small { font-family: 'Frank Ruhl Libre', serif; font-size: 8cqw; }
.hardcover--elegant small { color: #8C6E33; }
.hardcover--festive { background: var(--fbg) radial-gradient(circle, rgba(242, 193, 78, .9) 1cqw, transparent 1.2cqw) 0 0 / 22% 20%; color: #fff; }
.hardcover--festive img { border: 2.5cqw solid #fff; border-radius: 5cqw; }
.hardcover--festive b { font-family: var(--head); font-weight: 900; font-size: 11cqw; }
.hardcover--festive small { color: #F2C14E; font-weight: 800; }
.book-ctrl { display: flex; justify-content: center; align-items: center; gap: 14px; margin: 22px auto 6px; }
.book-ctrl span { min-width: 140px; text-align: center; font-weight: 700; }
.book-ctrl .btn { min-width: 110px; }
.i.flip-x { scale: -1 1; }
.book-hint { text-align: center; color: var(--muted); font-size: 15px; max-width: 520px; margin: 6px auto 0; }
@media (max-width: 560px) { .book-ctrl .btn { min-width: 0; padding: 0 16px; } .book-ctrl span { min-width: 100px; font-size: 15px; } }
@media (prefers-reduced-motion: reduce) { .leaf, .book { transition: none !important; } }
.savebar { display: flex; gap: 10px; }
.savebar .btn { flex: 1; padding: 0 12px; }
.book-view { overflow-x: hidden; }

/* ---------- הזזה, כיתובים וג'מיני ---------- */
.move-row { display: grid; grid-template-columns: 1fr auto 1fr; gap: 10px; align-items: center; margin-top: 14px; }
.move-row span { font-weight: 800; font-size: 14px; color: var(--muted); }
.ai-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.ai-row .btn .i { color: var(--accent); }
.page--elegant .cap { bottom: -5.4cqw; inset-inline: 0; font-family: 'Frank Ruhl Libre', serif; font-weight: 500; font-size: 3.4cqw; color: #8C6E33; }
.page--elegant .slot:has(.cap) { margin-bottom: 4cqw; }
