/* Scoped styles. Gallery placement is produced by the PHP shortcode. */
.rgp {
  --rgp-ink: #171717;
  --rgp-muted: #73736f;
  --rgp-line: #e5e5e1;
  width: 100%;
  max-width: var(--restoo-container, 1448px);
  min-width: 0;
  margin: 32px auto;
  color: var(--rgp-ink);
  font-family: var(--restoo-font, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif);
  line-height: 1.45;
  text-align: left;
}
.rgp *, .rgp *::before, .rgp *::after { box-sizing: border-box; }
.rgp [hidden] { display: none !important; }
.rgp button, .rgp a { -webkit-tap-highlight-color: transparent; }
.rgp a { text-decoration: none; }
.rgp button { font: inherit; cursor: pointer; }
.rgp svg { display: block; flex-shrink: 0; width: 20px; height: 20px; }
.rgp :focus-visible { outline: 2px solid var(--rgp-ink); outline-offset: 4px; }
.rgp__header, .rgp__heading { display: flex; align-items: center; gap: 12px; }
.rgp__header { justify-content: space-between; margin: 0 0 20px; padding: 0; }
.rgp__heading { min-width: 0; }
.rgp__heading h2 { margin: 0; padding: 0; color: var(--rgp-ink); font-size: clamp(25px, 2.5vw, 34px); font-weight: 500; line-height: 1.15; letter-spacing: -.045em; overflow-wrap: anywhere; }
.rgp__total { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; min-width: 32px; height: 32px; padding: 0 8px; border-radius: 999px; background: #f1f1ee; color: var(--rgp-muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.rgp__all { display: inline-flex; flex-shrink: 0; align-items: center; justify-content: center; gap: 9px; min-height: 44px; padding: 11px 17px; border: 1px solid var(--rgp-line); border-radius: 999px; background: #fff; color: var(--rgp-ink); font-size: 13px; line-height: 1.4; transition: border-color .2s, background .2s; }
.rgp__all:hover { border-color: #b5b5ae; background: #f7f7f4; }
.rgp__rail {
  position: relative;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 28px) / 2.12);
  gap: 14px;
  min-width: 0;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  border-radius: 24px;
  direction: ltr;
  user-select: none;
  -webkit-user-select: none;
}
.rgp__rail::-webkit-scrollbar { display: none; }
.rgp__rail.is-dragging { cursor: grabbing; scroll-snap-type: none; scroll-behavior: auto; }
.rgp__rail.is-dragging a { cursor: grabbing; }
.rgp__slide { min-width: 0; width: auto; height: clamp(320px, 32vw, 440px); margin: 0 !important; padding: 0; border: 0; scroll-snap-align: start; }
.rgp__photo { position: relative; display: block; width: 100%; height: 100%; overflow: hidden; border-radius: 24px; background: #eae9e4; color: #fff; cursor: zoom-in; }
.rgp__photo > img { display: block; width: 100% !important; height: 100% !important; max-width: none; margin: 0; border-radius: 0; object-fit: cover; transition: transform .5s cubic-bezier(.2, .7, .2, 1); -webkit-user-drag: none; }
.rgp__photo:focus-visible { outline-color: #fff; outline-offset: -7px; }
.rgp__zoom { position: absolute; right: 18px; bottom: 18px; z-index: 1; display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid #ffffff6b; border-radius: 50%; background: #ffffffeb; color: #171717; box-shadow: 0 3px 20px #0000000f; pointer-events: none; }
.rgp__photo-caption { position: absolute; inset: auto 0 0; display: block; max-height: 50%; overflow: hidden; margin: 0; padding: 55px 82px 23px 24px; background: linear-gradient(transparent, #000000a6); color: #fff; font-size: 14px; line-height: 1.45; overflow-wrap: anywhere; pointer-events: none; }
.rgp__bottom { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 16px; }
.rgp__thumbs { display: flex; flex: 0 1 auto; gap: 8px; min-width: 0; padding: 3px; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: thin; scrollbar-color: #ddd transparent; }
.rgp__thumb { display: block; flex: 0 0 76px; width: 76px; height: 58px; padding: 3px; border: 1px solid transparent; border-radius: 12px; opacity: .52; transition: opacity .2s, border-color .2s; }
.rgp__thumb > img { display: block; width: 100%; height: 100%; margin: 0; border-radius: 8px; object-fit: cover; }
.rgp__thumb:hover, .rgp__thumb.is-visible { opacity: 1; }
.rgp__thumb[aria-current="true"] { border-color: #292929; opacity: 1; }
.rgp__controls { display: flex; flex-shrink: 0; align-items: center; gap: 8px; }
.rgp__position { min-width: 84px; margin-right: 8px; color: #73736f; font-size: 13px; letter-spacing: .02em; font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; }
.rgp__position > span { color: #92928b; }
.rgp__arrow { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; padding: 0; border: 1px solid var(--rgp-line); border-radius: 50%; background: #fff; color: #171717; transition: background .2s, color .2s; }
.rgp__arrow--prev svg { transform: rotate(180deg); }
.rgp__arrow:hover:not(:disabled) { border-color: #171717; background: #171717; color: #fff; }
.rgp__arrow:disabled { opacity: .35; cursor: default; }
.rgp--single .rgp__rail { grid-auto-columns: 100%; }
.rgp--single .rgp__slide { height: clamp(320px, 36vw, 500px); }

html.rgp-viewer-open, body.rgp-viewer-open { overflow: hidden; overscroll-behavior: none; }
.rgp dialog.rgp-viewer { position: fixed; inset: 0; z-index: 2147483000; width: 100%; max-width: none; height: 100vh; height: 100dvh; max-height: none; margin: 0; padding: 0; overflow: hidden; border: 0; border-radius: 0; background: #141414; color: #fff; font: inherit; box-shadow: none; }
.rgp dialog.rgp-viewer:not([open]) { display: none; }
.rgp dialog.rgp-viewer[open] { display: flex; flex-direction: column; }
.rgp-viewer::backdrop { background: #141414; }
.rgp-viewer :focus-visible { outline-color: #fff; }
.rgp-viewer__header { display: flex; flex: 0 0 auto; align-items: center; gap: 20px; margin: 0; padding: max(16px, env(safe-area-inset-top)) max(28px, env(safe-area-inset-right)) 16px max(28px, env(safe-area-inset-left)); }
.rgp-viewer__title { flex: 1; min-width: 0; }
.rgp-viewer__title > span { display: block; margin-bottom: 3px; color: #aaa; font-size: 12px; line-height: 1.3; }
.rgp-viewer__title h2 { margin: 0; padding: 0; overflow: hidden; color: #fff; font-size: 22px; font-weight: 500; letter-spacing: -.03em; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.rgp-viewer__count { flex: 0 0 auto; color: #d2d2d2; font-size: 14px; font-variant-numeric: tabular-nums; }
.rgp-viewer__button { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; width: 48px; height: 48px; margin: 0; padding: 0; border: 1px solid #ffffff30; border-radius: 50%; background: #232323cc; color: #fff; transition: background .2s; }
.rgp-viewer__button:hover { background: #444; }
.rgp-viewer__button svg { width: 24px; height: 24px; }
.rgp-viewer__stage { position: relative; flex: 1 1 auto; min-height: 0; margin: 0 max(28px, env(safe-area-inset-right)) 12px max(28px, env(safe-area-inset-left)); touch-action: pan-y pinch-zoom; }
.rgp-viewer__frame { width: 100%; height: 100%; }
.rgp-viewer__frame img { display: block; width: 100%; height: 100%; max-width: 100%; max-height: 100%; margin: 0; border-radius: 0; object-fit: contain; user-select: none; -webkit-user-select: none; }
.rgp-viewer__message { position: absolute; top: 50%; left: 50%; width: min(400px, calc(100% - 110px)); margin: 0; transform: translate(-50%, -50%); color: #ccc; font-size: 14px; line-height: 1.6; text-align: center; }
.rgp-viewer__message a { display: block; margin-top: 8px; color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.rgp-viewer__prev, .rgp-viewer__next { position: absolute; top: 50%; transform: translateY(-50%); }
.rgp-viewer__prev { left: 16px; }
.rgp-viewer__prev svg { transform: rotate(180deg); }
.rgp-viewer__next { right: 16px; }
.rgp-viewer__caption { flex: 0 0 auto; max-height: 4.2em; overflow-y: auto; margin: 0 28px 12px; color: #d2d2d2; font-size: 14px; line-height: 1.4; text-align: center; overflow-wrap: anywhere; }
.rgp-viewer__thumbs { display: flex; position: relative; flex: 0 0 auto; gap: 8px; width: max-content; max-width: calc(100% - 56px); margin-inline: auto; padding: 5px 5px max(18px, env(safe-area-inset-bottom)); overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: thin; scrollbar-color: #555 transparent; }
.rgp-viewer__thumb { flex: 0 0 80px; width: 80px; height: 58px; margin: 0; padding: 3px; overflow: hidden; border: 1px solid transparent; border-radius: 10px; background: transparent; opacity: .55; transition: opacity .2s, border-color .2s; }
.rgp-viewer__thumb img { width: 100%; height: 100%; margin: 0; border-radius: 6px; object-fit: cover; }
.rgp-viewer__thumb:hover, .rgp-viewer__thumb[aria-current="true"] { opacity: 1; }
.rgp-viewer__thumb[aria-current="true"] { border-color: #fff; }

/* Hide the supplied theme's old galleries only on a page containing this
   shortcode. Pure CSS; no DOM insertion, relocation or theme-file changes. */
body.single-restoo_restaurant:has([data-restoo-gallery-plugin]) .restaurant-gallery,
body.single-restoo_restaurant:has([data-restoo-gallery-plugin]) .restoo-photo-gallery { display: none !important; }

@media (hover: hover) {
  .rgp__photo:hover > img { transform: scale(1.025); }
  .rgp__rail.is-dragging .rgp__photo > img { transform: none; }
}
@media (max-width: 1050px) {
  .rgp__rail { grid-auto-columns: 80%; }
  .rgp__slide { height: clamp(320px, 45vw, 440px); }
  .rgp--single .rgp__rail { grid-auto-columns: 100%; }
}
@media (max-width: 760px) {
  .rgp { margin-block: 24px; }
  .rgp__header { margin-bottom: 16px; gap: 12px; }
  .rgp__heading { gap: 9px; }
  .rgp__heading h2 { font-size: 26px; }
  .rgp__total { min-width: 28px; height: 28px; font-size: 12px; }
  .rgp__all { padding: 10px 13px; font-size: 12px; }
  .rgp__rail { grid-auto-columns: 88%; gap: 10px; border-radius: 20px; }
  .rgp__slide { height: clamp(270px, 78vw, 420px); }
  .rgp__photo { border-radius: 20px; }
  .rgp__zoom { right: 13px; bottom: 13px; }
  .rgp__photo-caption { padding: 45px 70px 18px 18px; font-size: 13px; }
  .rgp__bottom { flex-wrap: wrap; gap: 12px; margin-top: 12px; }
  .rgp__thumbs { flex-basis: 100%; gap: 6px; }
  .rgp__thumb { flex-basis: 54px; width: 54px; height: 44px; border-radius: 10px; }
  .rgp__thumb > img { border-radius: 6px; }
  .rgp__controls { justify-content: flex-end; width: 100%; }
  .rgp__arrow { width: 44px; height: 44px; }
  .rgp__position { margin-right: auto; min-width: 0; text-align: left; }
  .rgp-viewer__header { gap: 12px; padding: max(12px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) 12px max(14px, env(safe-area-inset-left)); }
  .rgp-viewer__title h2 { font-size: 18px; }
  .rgp-viewer__count { font-size: 13px; }
  .rgp-viewer__button { width: 44px; height: 44px; }
  .rgp-viewer__stage { margin-inline: max(10px, env(safe-area-inset-left)) max(10px, env(safe-area-inset-right)); }
  .rgp-viewer__prev { left: 5px; }
  .rgp-viewer__next { right: 5px; }
  .rgp-viewer__caption { margin-inline: 18px; font-size: 13px; }
  .rgp-viewer__thumbs { max-width: calc(100% - 20px); gap: 5px; }
  .rgp-viewer__thumb { flex-basis: 64px; width: 64px; height: 48px; }
}
@media (max-width: 420px) {
  .rgp__all { width: 44px; padding: 0; }
  .rgp__all > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) {
  .rgp__rail { scroll-behavior: auto; }
  .rgp__all, .rgp__photo > img, .rgp__thumb, .rgp__arrow, .rgp-viewer__button, .rgp-viewer__thumb { transition: none; }
  .rgp__photo:hover > img { transform: none; }
}
@media print {
  .rgp dialog.rgp-viewer, .rgp__all, .rgp__bottom, .rgp__zoom { display: none !important; }
  .rgp__rail { display: grid; grid-template-columns: 1fr 1fr; grid-auto-flow: row; overflow: visible; }
  .rgp__slide { height: 180px; }
}
