/* 餐廳沿用酒評 C 的評分與資料列，六環節各有相簿及完整原文。 */
:root body#top .restaurant-article .restaurant-overview,
:root[data-score-design] body#top .restaurant-article .restaurant-overview {
  --overview-photo-width: 260px;
  grid-template-columns: minmax(0, 1fr) var(--overview-photo-width);
  column-gap: var(--space-7);
  row-gap: var(--space-4);
}

:root body#top .restaurant-overview .restaurant-title {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  margin: 0;
  font-size: var(--type-page);
  line-height: 1.4;
  overflow-wrap: anywhere;
}

:root body#top .restaurant-article .restaurant-overview > .score-design-target,
:root body#top .restaurant-article .restaurant-overview:has(> .bottle-basics[open]) > .score-design-target,
:root[data-score-design] body#top .restaurant-article .restaurant-overview > .score-design-target,
:root[data-score-design] body#top .restaurant-article .restaurant-overview:has(> .bottle-basics[open]) > .score-design-target {
  grid-column: 1;
  grid-row: 2;
  margin: 0;
}

:root body#top .restaurant-article .restaurant-overview > .bottle-basics,
:root body#top .restaurant-article .restaurant-overview > .bottle-basics[open],
:root[data-score-design] body#top .restaurant-article .restaurant-overview > .bottle-basics,
:root[data-score-design] body#top .restaurant-article .restaurant-overview > .bottle-basics[open] {
  grid-column: 1 / -1;
  grid-row: 3;
  margin: 0;
}

:root[data-score-design] body#top .restaurant-article .restaurant-overview .restaurant-hero-photo {
  position: relative;
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: end;
  width: var(--overview-photo-width);
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: var(--radius-media);
}
:root[data-score-design] body#top .restaurant-article .restaurant-overview .restaurant-hero-photo img {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 450%;
  max-width: none;
  height: auto;
  border-radius: 0;
  transform: translate(-71.7%, -37.6%);
}

@media (max-width: 700px) {
  :root body#top .restaurant-article .restaurant-overview,
  :root[data-score-design] body#top .restaurant-article .restaurant-overview {
    --overview-photo-width: 116px;
    column-gap: var(--space-4);
  }
  :root[data-score-design] body#top .restaurant-article .restaurant-overview .restaurant-hero-photo { grid-row: 1; }
  :root body#top .restaurant-article .restaurant-overview > .score-design-target,
  :root body#top .restaurant-article .restaurant-overview:has(> .bottle-basics[open]) > .score-design-target,
  :root[data-score-design] body#top .restaurant-article .restaurant-overview > .score-design-target,
  :root[data-score-design] body#top .restaurant-article .restaurant-overview:has(> .bottle-basics[open]) > .score-design-target {
    grid-column: 1 / -1;
    margin-top: var(--space-4);
  }
}
@media (max-width: 370px) {
  :root body#top .restaurant-article .restaurant-overview,
  :root[data-score-design] body#top .restaurant-article .restaurant-overview {
    --overview-photo-width: 76px;
    column-gap: var(--space-2);
  }
}

body#top .restaurant-score-note {
  margin: var(--space-3) 0 0;
  color: var(--muted);
}

body#top .restaurant-info > summary > h2 { margin: 0; }
body#top .restaurant-info .info-symbol,
body#top .restaurant-info .details-chevron {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  align-self: center;
  text-decoration: none;
  line-height: 1;
}
body#top .restaurant-info .details-chevron { width: 18px; height: 18px; }
body#top .restaurant-info .bottle-specs th { width: 7.5em; padding-inline-start: 0; }
body#top .restaurant-info .bottle-specs td { overflow-wrap: anywhere; }
body#top .restaurant-info .bottle-specs tr:last-child > * { border-bottom: 0; }

body#top .restaurant-card {
  min-width: 0;
  text-align: center;
}
body#top .restaurant-card .review-body { min-width: 0; }
body#top .restaurant-card .tag-links { justify-content: center; }

/* 完整招牌落在圓形內，沿用門面原圖，不改寫圖片像素。 */
body#top .restaurant-cover { position: relative; }
body#top .restaurant-cover img,
body#top .restaurant-cover:hover img {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 320%;
  max-width: none;
  height: auto;
  transform: translate(-71.7%, -37.6%);
}

/* 桌機與手機均一屏一張，原圖完整呈現，菜名與原文放在照片下方。 */
body#top .restaurant-article .restaurant-stage-gallery {
  width: 100%;
  max-width: 720px;
  margin-inline: auto;
}
body#top .restaurant-article .restaurant-album-viewport {
  position: relative;
  min-width: 0;
}
body#top .restaurant-article .restaurant-photo-track {
  display: flex;
  gap: var(--space-4);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
  border-radius: 0;
}
body#top .restaurant-article .restaurant-photo-slide {
  flex: 0 0 100%;
  min-width: 0;
  margin: 0;
  aspect-ratio: auto;
  overflow: visible;
  border-radius: 0;
  background: transparent;
  scroll-snap-align: start;
}
body#top .restaurant-article .restaurant-album-photo {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--radius-media);
  background: var(--surface);
}
body#top .restaurant-article .restaurant-album-photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
/* 兩張直式來源轉回橫向，原檔不變，旋轉後恰好填滿 4:3。 */
body#top .restaurant-article .restaurant-album-photo img[data-rotate-left] {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 75%;
  height: 133.333333%;
  max-width: none;
  transform: translate(-50%, -50%) rotate(-90deg);
}
body#top .restaurant-article .restaurant-photo-slide figcaption {
  position: static;
  margin: var(--space-3) 0 0;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: var(--muted);
  font-size: var(--type-caption);
  line-height: 1.5;
  text-align: center;
}
/* 控制層只覆蓋 4:3 照片區，左右按鈕都有 44px 觸控目標。 */
body#top .restaurant-article .restaurant-album-controls {
  display: block;
  position: absolute;
  inset: 0 0 auto;
  width: 100%;
  aspect-ratio: 4 / 3;
  margin: 0;
  pointer-events: none;
}
body#top .restaurant-article .restaurant-album-controls button {
  position: absolute;
  top: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 10px;
  transform: translateY(-50%);
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--bg);
  color: var(--ink);
  pointer-events: auto;
}
body#top .restaurant-article .restaurant-album-controls button[data-carousel-prev] { left: var(--space-2); }
body#top .restaurant-article .restaurant-album-controls button[data-carousel-next] { right: var(--space-2); }
body#top .restaurant-article .restaurant-album-controls button svg { width: 22px; height: 22px; }
body#top .restaurant-article .restaurant-album-controls button:disabled { opacity: .35; }
body#top .restaurant-article .restaurant-album-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-top: var(--space-1);
}
body#top .restaurant-article .restaurant-album-dots button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-control);
  color: var(--muted);
}
body#top .restaurant-article .restaurant-album-dots button::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: .35;
}
body#top .restaurant-article .restaurant-album-dots button[aria-current="true"]::before {
  color: var(--ink);
  opacity: 1;
}
body#top .restaurant-article .restaurant-stage-copy { margin-top: var(--space-5); }
body#top .restaurant-article .restaurant-stage-copy > p { margin-bottom: 0; }
body#top .restaurant-article .meal-courses + .meal-courses { margin-top: var(--space-7); }
body#top .restaurant-article .meal-courses > h2 {
  margin: var(--space-6) 0 var(--space-4);
  font-size: var(--type-section);
  font-weight: 500;
  line-height: 1.5;
}

