/* MiRELE: shared styles for every page */
:root {
  --cream: #FFFFFF;        /* white, like the product photo backdrops */
  --ivory: #FFFFFF;
  --white: #FFFFFF;
  --ink: #4A3D38;          /* soft warm brown instead of black */
  --ink-soft: #66574F;
  --pink: #F6DCE3;
  --matcha: #E3EACB;
  --lilac: #E8DDF1;
  --orange: #FAD9C1;
  --sky: #DCEAF3;
  --pink-deep: #F5C8D5;

  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;

  --margin: clamp(16px, 2.4vw, 36px);
  --radius: 10px;
  --gap: clamp(96px, 10vw, 168px);
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  margin: 0; background: var(--cream); color: var(--ink);
  font: 400 17px/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; margin: 0; letter-spacing: 0; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--pink-deep); color: var(--ink); }
:focus-visible { outline: 1px solid currentColor; outline-offset: 4px; }
[id] { scroll-margin-top: 84px; }

.skip { position: absolute; inset-inline-start: var(--margin); top: -60px; z-index: 100; background: var(--ivory); color: var(--ink); padding: 10px 16px; }
.skip:focus { top: 10px; }

/* Small spaced capitals: the quiet voice of labels, navigation and buttons */
.label { font: 400 12.5px/1.4 var(--sans); letter-spacing: 0.22em; text-transform: uppercase; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 30px; border: 1px solid currentColor; border-radius: 0; background: transparent;
  font: 400 12.5px/1 var(--sans); letter-spacing: 0.2em; text-transform: uppercase; text-decoration: none; cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 250ms ease, color 250ms ease, border-color 250ms ease;
}
.btn:active { transform: scale(0.97); }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: var(--ink); border-color: var(--ink); color: var(--ivory); }
  .btn-light:hover { background: var(--ivory); border-color: var(--ivory); color: var(--ink); }
}

/* ---------- Header: transparent at the top, white once scrolled ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 40; color: var(--ink);
  background-color: rgba(255, 255, 255, 0);
  transition: background-color 300ms ease;
}
.site-header .inner { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 16px var(--margin); }
.nav { display: flex; gap: clamp(16px, 2.6vw, 40px); }
.nav-r { justify-content: flex-end; }
.nav a { text-decoration: none; padding: 10px 0; }
@media (hover: hover) and (pointer: fine) { .nav a:hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1px; } }
.logo { display: block; line-height: 0; }
.logo img { width: clamp(104px, 9vw, 136px); height: auto; opacity: 0.88; }
.site-header.is-solid { background-color: var(--cream); }
@media (max-width: 420px) { .nav { gap: 14px; } .nav a { letter-spacing: 0.12em; font-size: 11px; } .logo img { width: 92px; } }

/* ---------- Hero: the Marrakesh photograph melting into a field of its own cream backdrop ---------- */
.hero { padding: 76px var(--margin) 0; }
.hero-frame {
  --h: max(520px, calc(100svh - 76px - var(--margin)));
  position: relative; height: var(--h); border-radius: var(--radius); overflow: hidden;
}
.hero-photo { display: block; max-width: none; object-fit: cover; }
.js .hero-photo { animation: settle 1800ms var(--ease-out) both; }
@keyframes settle { from { opacity: 0; transform: scale(1.04); } to { opacity: 1; transform: none; } }
.hero-copy { display: grid; justify-items: center; gap: 18px; text-align: center; }
.hero h1 { font-size: clamp(3.6rem, 6.4vw, 6.8rem); font-style: italic; font-weight: 300; line-height: 1; }
.hero-copy p { font-size: 18px; font-weight: 400; max-width: 32ch; line-height: 1.5; }
.hero-copy .btn { margin-top: 10px; }

/* Hero video: a full-width band. On wide screens the 16:9 video sits in the middle and a blurred,
   live copy of its own frames (the canvas, drawn by site.js) continues the sky out to both edges.
   The title and button sit below the band. */
.hero--video { padding: 76px 0 0; }
.hero-band {
  position: relative; overflow: hidden; display: grid; place-items: center; background: #A9C3DE;
  height: clamp(340px, min(56.25vw, calc(100svh - 76px - 110px)), 1100px);
}
.hero-fill { position: absolute; inset: -48px; width: calc(100% + 96px); height: calc(100% + 96px); filter: blur(30px); }
.hero-video {
  position: absolute; top: 0; left: 50%; translate: -50% 0;
  height: 100%; width: auto; max-width: none; aspect-ratio: 16 / 9; object-fit: cover;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 9%, #000 91%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0, #000 9%, #000 91%, transparent 100%);
}
.js .hero-video { animation: settle 1800ms var(--ease-out) both; }
.hero--video .hero-copy { color: var(--ink); padding: clamp(40px, 5vw, 72px) var(--margin) 0; }
.hero-pause {
  position: absolute; inset-inline-end: 14px; bottom: 14px; width: 44px; height: 44px; padding: 0;
  display: grid; place-items: center; border: 0; border-radius: 50%;
  background: var(--ivory); color: var(--ink); cursor: pointer;
}
.hero-pause svg { width: 16px; height: 16px; fill: currentColor; }
.hero-pause:focus-visible { outline-offset: 2px; }
/* Phones: the band is taller than the video's shape, so the video fills it and the sides are cropped */
@media (max-width: 699px) {
  .hero-band { height: 62svh; min-height: 380px; }
  .hero-video { -webkit-mask-image: none; mask-image: none; }
  .hero--video .hero-copy { padding: 36px 20px 0; }
}

.hero--marrakesh .hero-frame { display: grid; grid-template-columns: 1fr auto; grid-template-rows: minmax(0, 1fr); background: #E9E0CE; }
.hero--marrakesh .hero-photo {
  height: var(--h); width: auto; max-width: 56vw; object-position: 72% 50%;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 22%);
  mask-image: linear-gradient(to right, transparent 0, #000 22%);
}
.hero--marrakesh .hero-copy { align-self: center; justify-self: center; width: min(88%, 520px); color: var(--ink); }
@media (max-width: 899px) {
  .hero--marrakesh .hero-frame { grid-template-columns: 1fr; grid-template-rows: auto; height: auto; }
  .hero--marrakesh .hero-photo { order: -1; width: 100%; max-width: none; height: 62svh; min-height: 380px; object-position: 60% 30%; -webkit-mask-image: none; mask-image: none; }
  .hero--marrakesh .hero-copy { width: 100%; padding: 36px 20px 44px; }
}


/* ---------- Section headings: soft, centered ---------- */
.head { display: grid; justify-items: center; gap: 14px; text-align: center; padding: 0 var(--margin) clamp(36px, 4vw, 56px); }
.head h1, .head h2 { font-size: clamp(2.4rem, 4.2vw, 3.8rem); font-weight: 300; line-height: 1.05; }

/* ---------- Collection ---------- */
.collection { padding-top: var(--gap); }
.grid {
  list-style: none; margin: 0; padding: 0 var(--margin);
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 3vw, 48px) clamp(12px, 1.6vw, 24px);
}
@media (min-width: 1000px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* The home page shows four pieces: two rows of two on phones, one row of four on wide screens */
@media (min-width: 1000px) { .grid[data-pieces="home"] { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tile {
  display: grid; gap: 14px; width: 100%; padding: 0; border: 0; background: none; text-align: center; cursor: pointer;
  transition: transform 160ms var(--ease-out);
}
.tile:active { transform: scale(0.99); }
.tile-media { position: relative; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); background: var(--field); }
.tile-media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transition: opacity 500ms ease, transform 1000ms var(--ease-out);
}
.tile-media img + img { opacity: 0; }
@media (hover: hover) and (pointer: fine) {
  .tile:hover .tile-media img + img { opacity: 1; }
  .tile:hover .tile-media img:first-child { transform: scale(1.04); }
  .tile:hover .tile-more { text-decoration: underline; text-underline-offset: 5px; }
}
.tile-info { display: grid; justify-items: center; gap: 4px; }
.tile-info h3 { font-size: clamp(1.7rem, 2.2vw, 2.2rem); font-weight: 400; line-height: 1.1; }
.tile-more { color: var(--ink-soft); }
@media (max-width: 599px) { .tile-info h3 { font-size: 1.6rem; } }

.f-pink { --field: var(--pink); }
.f-matcha { --field: var(--matcha); }
.f-lilac { --field: var(--lilac); }
.f-orange { --field: var(--orange); }
.f-sky { --field: var(--sky); }

.collection-more { display: flex; justify-content: center; padding: clamp(44px, 4.5vw, 72px) var(--margin) 0; }

/* The collection page: no hero, so the heading clears the fixed header itself */
.collection--page { padding-top: calc(76px + clamp(40px, 6vw, 96px)); }
.collection--page .head p:not(.label) { max-width: 44ch; color: var(--ink-soft); }

/* ---------- Piece banners: like the hero, each photograph melts into a field of its own backdrop ---------- */
.banners { margin: var(--gap) var(--margin) 0; display: grid; gap: clamp(12px, 1.6vw, 24px); }
.banner {
  --h: clamp(520px, 84svh, 900px);
  height: var(--h); border-radius: var(--radius); overflow: hidden;
  display: grid; grid-template-columns: 1fr auto; grid-template-rows: minmax(0, 1fr);
  background: var(--bg); color: var(--fg, var(--ink));
}
.banner img {
  display: block; height: var(--h); width: auto; max-width: 56vw; object-fit: cover;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 22%);
  mask-image: linear-gradient(to right, transparent 0, #000 22%);
}
.banner--left { grid-template-columns: auto 1fr; }
.banner--left img {
  -webkit-mask-image: linear-gradient(to left, transparent 0, #000 22%);
  mask-image: linear-gradient(to left, transparent 0, #000 22%);
}
.banner-copy { align-self: center; justify-self: center; width: min(88%, 480px); display: grid; justify-items: center; gap: 14px; text-align: center; }
.banner h2 { font-size: clamp(3rem, 5.6vw, 5.6rem); font-style: italic; font-weight: 300; line-height: 1; }
.banner .btn { margin-top: 8px; }
.banner--como { --bg: #0F3533; --fg: var(--ivory); }
.banner--valencia { --bg: #CBDAE1; }
.banner--kyoto { --bg: #C4CDB2; background: linear-gradient(to bottom, #C4CDB2 0%, #D3D9BF 35%, #E9E7D2 66%, #EFEAD7 100%); } /* taste-skill-ignore: continues the photo's backdrop */
.banner--marrakesh { --bg: #7E62A6; --fg: var(--ivory); }
@media (max-width: 899px) {
  .banner { grid-template-columns: 1fr; grid-template-rows: auto; height: auto; }
  .banner img { order: -1; width: 100%; height: 62svh; min-height: 380px; max-width: none; -webkit-mask-image: none; mask-image: none; }
  .banner-copy { width: 100%; padding: 36px 20px 44px; }
}

/* ---------- About ---------- */
.about {
  margin: var(--gap) var(--margin) 0; display: grid; grid-template-columns: 1fr; gap: clamp(32px, 5vw, 96px);
  align-items: center;
}
.about img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); }
/* Studio slideshow: the photos sit on top of each other and cross-fade */
.about-slides { position: relative; width: 100%; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); }
.about-slides img { position: absolute; inset: 0; height: 100%; border-radius: 0; opacity: 0; transition: opacity 900ms ease; }
.about-slides img.is-on { opacity: 1; }
html:not(.js) .about-slides img:first-child { opacity: 1; }
.about-text { display: grid; justify-items: start; gap: 22px; max-width: 560px; }
.about h2, .about h1 { font-size: clamp(2.6rem, 4.6vw, 4.2rem); font-weight: 300; line-height: 1.05; }
/* The Brand as its own page: clear the fixed header */
.about--page { margin-top: 0; padding-top: calc(76px + clamp(40px, 6vw, 96px)); }
@media (min-width: 760px) { .about { grid-template-columns: 1fr 1fr; } }

/* ---------- Contact ---------- */
.contact {
  margin: var(--gap) var(--margin) 0; border-radius: var(--radius); overflow: hidden;
  background: var(--lilac); display: grid; grid-template-columns: 1fr;
}
.contact-text { display: grid; align-content: center; justify-items: center; gap: 20px; text-align: center; padding: clamp(64px, 8vw, 120px) var(--margin); }
.contact h2 { font-size: clamp(2.6rem, 4.6vw, 4.2rem); font-weight: 300; line-height: 1.05; }
.contact p:not(.label) { max-width: 32ch; }
.contact .label { color: var(--ink-soft); }
.contact-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.contact-links a { font-family: var(--serif); font-style: italic; font-size: clamp(24px, 2.4vw, 32px); text-underline-offset: 6px; text-decoration-thickness: 1px; }
.contact img { width: 100%; height: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
@media (min-width: 760px) { .contact { grid-template-columns: 1fr 1fr; } }

/* ---------- Footer ---------- */
.site-footer { display: grid; justify-items: center; gap: 28px; padding: clamp(80px, 9vw, 140px) var(--margin) 32px; text-align: center; }
.footer-mark { width: clamp(180px, 22vw, 300px); height: auto; opacity: 0.85; }
.footer-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 32px; }
.footer-nav a { text-decoration: none; padding: 6px 0; }
@media (hover: hover) and (pointer: fine) { .footer-nav a:hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1px; } }
.footer-ig { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; padding: 8px 0; font-size: 16px; }
.footer-ig svg { width: 22px; height: 22px; flex: none; }
@media (hover: hover) and (pointer: fine) { .footer-ig:hover span { text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; } }
.footer-note { font-size: 14px; color: var(--ink-soft); margin-top: 16px; }
/* Phones: room under the last line so the round accessibility button never covers it */
@media (max-width: 699px) { .site-footer { padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px)); } }
.footer-legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 24px; font-size: 14px; }
.footer-legal a { padding: 6px 0; text-underline-offset: 4px; text-decoration-thickness: 1px; }

/* ---------- Legal pages ---------- */
.legal { width: min(100%, 720px); margin: 0 auto; padding: calc(76px + clamp(40px, 6vw, 96px)) var(--margin) 0; display: grid; gap: 16px; }
.legal h1 { font-size: clamp(2.4rem, 4.2vw, 3.8rem); font-weight: 300; line-height: 1.05; }
.legal h2 { font-size: clamp(1.6rem, 2.4vw, 2rem); line-height: 1.2; margin-top: 28px; }
.legal ul { margin: 0; padding-inline-start: 22px; display: grid; gap: 8px; }
.legal a { text-underline-offset: 3px; overflow-wrap: anywhere; }
.legal h3 { font-size: 1.35rem; line-height: 1.25; margin-top: 16px; }
.legal-note { border: 1px solid var(--ink); padding: 16px 18px; }
.legal-date { font-size: 14px; color: var(--ink-soft); margin-bottom: 12px; }
.fill { background: #FFE27A; color: #2B2320; padding: 1px 5px; }

/* ---------- Piece details ---------- */
dialog.quick {
  width: min(1080px, calc(100vw - 2 * var(--margin))); max-height: calc(100svh - 48px);
  padding: 0; border: 0; border-radius: var(--radius); background: var(--ivory); color: var(--ink); overflow: auto;
  opacity: 0; transform: scale(0.97);
  transition: opacity 220ms ease, transform 220ms var(--ease-out), overlay 220ms allow-discrete, display 220ms allow-discrete;
}
dialog.quick[open] { opacity: 1; transform: none; }
@starting-style { dialog.quick[open] { opacity: 0; transform: scale(0.97); } }
dialog.quick::backdrop { background: rgba(74, 61, 56, 0.35); }
.q-wrap { display: grid; grid-template-columns: 1fr; }
@media (min-width: 820px) { .q-wrap { grid-template-columns: 1.1fr 1fr; } }
.q-media { background: var(--white); }
.q-main { position: relative; aspect-ratio: 4 / 5; overflow: hidden; }
.q-main img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.q-thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; background: var(--ivory); }
.q-thumbs button { padding: 0; border: 0; background: var(--white); cursor: pointer; aspect-ratio: 1; overflow: hidden; opacity: 0.5; transition: opacity 200ms ease; }
.q-thumbs button[aria-pressed="true"] { opacity: 1; }
@media (hover: hover) and (pointer: fine) { .q-thumbs button:hover { opacity: 1; } }
.q-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.q-body { display: grid; align-content: center; justify-items: start; gap: 22px; padding: clamp(28px, 4vw, 56px); }
.q-body .label { color: var(--ink-soft); }
.q-body h2 { font-size: clamp(2.8rem, 4.6vw, 4.2rem); font-style: italic; font-weight: 300; line-height: 1; padding-inline-end: 48px; }
.q-desc { line-height: 1.65; max-width: 46ch; white-space: pre-line; }
.q-specs { margin: 0; display: grid; gap: 16px; }
.q-specs dt { color: var(--ink-soft); }
.q-specs dd { margin: 4px 0 0; }

.metals { border: 0; margin: 0; padding: 0; display: grid; gap: 10px; }
.metals legend { padding: 0; margin-bottom: 10px; color: var(--ink-soft); }
.metal-options { display: flex; flex-wrap: wrap; gap: 8px; }
.metal-options label { position: relative; }
.metal-options input { position: absolute; opacity: 0; pointer-events: none; }
.metal-options span {
  display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px;
  border: 1px solid rgba(74, 61, 56, 0.35); font-size: 14px; cursor: pointer;
  transition: background-color 200ms ease, color 200ms ease, border-color 200ms ease;
}
.metal-options input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--ivory); }
.metal-options input:focus-visible + span { outline: 1px solid var(--ink); outline-offset: 3px; }
@media (hover: hover) and (pointer: fine) { .metal-options span:hover { border-color: var(--ink); } }
.q-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 26px; }
.q-price span { font-family: var(--serif); font-size: 30px; line-height: 1.1; }
.q-price small { font: 400 12.5px/1 var(--sans); letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-soft); margin-inline-start: 8px; }
.q-terms { font-size: 14px; line-height: 1.5; color: var(--ink-soft); }
.q-terms a { text-underline-offset: 3px; }
.q-alt { margin-top: -4px; font-size: 14px; line-height: 1.5; color: var(--ink-soft); }
.q-alt a, .q-alt button { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.q-alt button { font: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
.q-note { margin-top: -6px; font-size: 14px; line-height: 1.5; color: var(--ink-soft); }

.q-close {
  position: absolute; top: 14px; inset-inline-end: 14px; z-index: 2;
  width: 44px; height: 44px; border: 0; border-radius: 999px; background: var(--ivory); color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
  transition: transform 160ms var(--ease-out);
}
.q-close:active { transform: scale(0.94); }
@media (max-width: 819px) {
  dialog.quick { width: 100vw; max-width: 100vw; height: 100svh; max-height: 100svh; margin: 0; border-radius: 0; }
  .q-main { aspect-ratio: 1 / 1; }
  .q-thumbs button { aspect-ratio: 4 / 3; }
}

/* ---------- Newsletter popup ---------- */
dialog.news {
  width: min(480px, calc(100vw - 32px)); max-height: calc(100svh - 32px);
  padding: 0; border: 0; border-radius: var(--radius); background: var(--ivory); color: var(--ink); overflow: auto;
  opacity: 0; transform: translateY(8px);
  transition: opacity 320ms ease, transform 320ms var(--ease-out), overlay 320ms allow-discrete, display 320ms allow-discrete;
}
dialog.news[open] { opacity: 1; transform: none; }
@starting-style { dialog.news[open] { opacity: 0; transform: translateY(8px); } }
dialog.news::backdrop { background: rgba(38, 30, 27, 0.55); transition: background-color 320ms ease, overlay 320ms allow-discrete, display 320ms allow-discrete; }
@starting-style { dialog.news[open]::backdrop { background: rgba(38, 30, 27, 0); } }
.news-body { display: grid; justify-items: center; gap: 18px; text-align: center; padding: clamp(44px, 6vw, 60px) clamp(22px, 5vw, 48px) clamp(32px, 5vw, 44px); }
.news-body h2 { font-size: clamp(1.5rem, 4vw, 1.9rem); font-style: italic; font-weight: 300; line-height: 1.2; }
.news-offer { font-family: var(--serif); font-variant-numeric: lining-nums; font-size: clamp(2.6rem, 6vw, 3.4rem); font-weight: 300; line-height: 1; margin-bottom: -4px; }
.news-sub { max-width: 34ch; line-height: 1.6; }
.news-form { display: grid; gap: 12px; width: 100%; margin-top: 6px; text-align: start; }
.news-form[hidden], .news-sub[hidden], .news-offer[hidden] { display: none; }
.news-form > .label { color: var(--ink-soft); }
.news-form input[type=email] {
  width: 100%; min-height: 50px; padding: 0 16px; border: 1px solid rgba(74, 61, 56, 0.35); border-radius: 0;
  background: var(--white); color: var(--ink); font: 400 16px/1 var(--sans);
}
.news-form input[type=email]:focus-visible { outline: 1px solid var(--ink); outline-offset: 2px; border-color: var(--ink); }
.news-form input[aria-invalid=true] { border-color: #A3473B; }
.news-consent { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: start; font-size: 14px; line-height: 1.5; color: var(--ink-soft); cursor: pointer; margin-top: 4px; }
.news-consent a { text-underline-offset: 3px; }
.news-consent input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--ink); cursor: pointer; }
.news-consent input[aria-invalid=true] { outline: 1px solid #A3473B; outline-offset: 2px; }
.news-error { font-size: 14px; color: #A3473B; min-height: 0; }
.news-error:empty { display: none; }
.news-form .btn { width: 100%; margin-top: 6px; }
.news-form .btn:disabled { opacity: 0.6; cursor: wait; }
.news-skip { justify-self: center; padding: 8px 4px; border: 0; background: none; font-size: 14px; color: var(--ink-soft); text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
.news-trap { position: absolute; inset-inline-start: -9999px; width: 1px; height: 1px; opacity: 0; }
.news-done { display: grid; justify-items: center; gap: 14px; width: 100%; outline: none; }
.news-done[hidden] { display: none; }
.news-code { font-family: var(--serif); font-variant-numeric: lining-nums; font-size: clamp(2rem, 6vw, 2.6rem); letter-spacing: 0.12em; padding: 10px 24px; border: 1px dashed rgba(74, 61, 56, 0.5); user-select: all; }
.news-note, .news-copied { font-size: 14px; color: var(--ink-soft); }
.news-copied:empty { display: none; }

/* ---------- Entrances (content stays visible without script) ---------- */
.js .rise { opacity: 0; transform: translateY(20px); }
.js .rise.in { opacity: 1; transform: none; transition: opacity 800ms ease, transform 1000ms var(--ease-out); transition-delay: var(--d, 0ms); }

@media (prefers-reduced-motion: reduce) {
  .js .rise, .js .rise.in { transition: opacity 400ms ease; transform: none; }
  .js .hero-photo { animation: none; }
  .tile-media img, .feature img, dialog.quick, dialog.news, .tile { transform: none !important; }
}

/* ---------- Language switch: EN / IL, fixed at the bottom right, opposite the accessibility button ---------- */
.lang {
  position: fixed; right: max(16px, env(safe-area-inset-right, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 45;
  display: flex; direction: ltr; height: 48px; padding: 4px; gap: 2px;
  border: 1px solid var(--ink); border-radius: 999px; background: var(--white); color: var(--ink);
  box-shadow: 0 2px 10px rgba(38, 30, 27, 0.14);
}
.lang a, .lang-current { display: grid; place-items: center; min-width: 40px; padding: 0 8px; border-radius: 999px; text-decoration: none; letter-spacing: 0.12em; }
.lang-current { background: var(--ink); color: var(--white); }
@media (hover: hover) and (pointer: fine) { .lang a:hover { text-decoration: underline; text-underline-offset: 4px; } }

/* ---------- Hebrew pages (he/): right to left, Hebrew typefaces ---------- */
/* Latin letters keep Cormorant and Jost; Hebrew letters fall through to Frank Ruhl Libre and Heebo */
html[lang=he] { --serif: "Cormorant Garamond", "Frank Ruhl Libre", "Times New Roman", serif; --sans: "Jost", "Heebo", Arial, sans-serif; }
html[lang=he] .lang { flex-direction: row-reverse; } /* EN stays on the left, IL on the right, as on the English pages */
html[lang=he] .label, html[lang=he] .btn, html[lang=he] .q-price small { letter-spacing: 0.04em; }
html[lang=he] .news-body h2, html[lang=he] .legal h1 { font-style: normal; }
html[lang=he] .banner img { -webkit-mask-image: linear-gradient(to left, transparent 0, #000 22%); mask-image: linear-gradient(to left, transparent 0, #000 22%); }
html[lang=he] .banner--left img { -webkit-mask-image: linear-gradient(to right, transparent 0, #000 22%); mask-image: linear-gradient(to right, transparent 0, #000 22%); }
@media (max-width: 899px) { html[lang=he] .banner img, html[lang=he] .banner--left img { -webkit-mask-image: none; mask-image: none; } }
html[lang=he] .a11y-options button::after { content: "כבוי"; content: "כבוי" / ""; }
html[lang=he] .a11y-options button[aria-pressed=true]::after { content: "פעיל"; content: "פעיל" / ""; }

/* ---------- Accessibility menu (a11y.js) ---------- */
.a11y-toggle {
  position: fixed; left: max(16px, env(safe-area-inset-left, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 45;
  width: 48px; height: 48px; display: grid; place-items: center; padding: 0;
  border: 1px solid var(--ink); border-radius: 50%; background: var(--white); color: var(--ink);
  box-shadow: 0 2px 10px rgba(38, 30, 27, 0.14); cursor: pointer;
}
.a11y-toggle svg { width: 24px; height: 24px; }
.a11y-toggle[aria-expanded=true] { background: var(--ink); color: var(--white); }
.a11y-panel {
  position: fixed; left: max(16px, env(safe-area-inset-left, 0px)); bottom: calc(76px + env(safe-area-inset-bottom, 0px)); z-index: 45;
  width: min(300px, calc(100vw - 32px)); max-height: calc(100vh - 110px); overflow-y: auto;
  display: grid; gap: 12px; padding: 16px 18px 18px;
  background: var(--white); color: var(--ink); border: 1px solid var(--ink); box-shadow: 0 12px 32px rgba(38, 30, 27, 0.18);
}
.a11y-panel[hidden] { display: none; }
.a11y-head { display: flex; align-items: center; justify-content: space-between; }
.a11y-close { width: 40px; height: 40px; margin-inline-end: -10px; display: grid; place-items: center; border: 0; background: none; cursor: pointer; }
.a11y-options { display: grid; gap: 8px; }
.a11y-options button {
  min-height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 14px;
  border: 1px solid rgba(74, 61, 56, 0.4); background: none; font-size: 15px; text-align: start; cursor: pointer;
}
.a11y-options button::after { content: "Off"; content: "Off" / ""; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-soft); }
.a11y-options button[aria-pressed=true] { border-color: var(--ink); background: var(--ink); color: var(--white); }
.a11y-options button[aria-pressed=true]::after { content: "On"; content: "On" / ""; color: inherit; }
.a11y-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; font-size: 14px; }
.a11y-reset { padding: 6px 0; border: 0; background: none; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.a11y-foot a { text-underline-offset: 3px; }

/* Larger text: scales the whole page, so text set in px grows too */
html.a11y-text body { zoom: 1.2; }

/* High contrast: darker text everywhere and stronger outlines */
html.a11y-contrast { --ink: #000000; --ink-soft: #1F1A18; }
html.a11y-contrast .a11y-options button,
html.a11y-contrast input[type=email] { border-color: #000000; }

/* Highlight links */
html.a11y-links a:not(.btn):not(.logo) { background: #FFF0A3; color: #000000; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
html.a11y-links a.btn { outline: 2px solid #000000; outline-offset: 2px; }

/* Readable font: one plain sans serif, no italics, normal spacing */
html.a11y-font { --serif: Arial, "Helvetica Neue", sans-serif; --sans: Arial, "Helvetica Neue", sans-serif; }
html.a11y-font * { font-style: normal !important; }
html.a11y-font h1, html.a11y-font h2, html.a11y-font h3, html.a11y-font .news-offer { font-weight: 400 !important; }
html.a11y-font .label, html.a11y-font .btn { letter-spacing: 0.06em; }

/* Stop animations */
html.a11y-still *, html.a11y-still *::before, html.a11y-still *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
html.a11y-still.js .rise { opacity: 1 !important; transform: none !important; }
