/* TAWHOO REVIEW HUB V1.6 — shared three-column visual rhythm */
/* No new data, no duplicated markup, the Foodie review's forms and events remain untouched. */
#trh-hub .trh11-entry-shop .vf-review-card {
  display:grid!important;
  grid-template-columns:minmax(0,1fr) minmax(150px,195px) minmax(0,245px);
  column-gap:17px;
  row-gap:4px;
  align-items:start;
  width:100%;
  min-width:0;
}
/* Normal story fields remain in the left column, in original accessible DOM order. */
#trh-hub .trh11-entry-shop .vf-review-card > * {
  min-width:0;
  grid-column:1;
  margin-top:0;
  margin-bottom:0;
}
#trh-hub .trh11-entry-shop .vf-review-card > .vf-row {margin-bottom:7px}
#trh-hub .trh11-entry-shop .vf-review-card > .vf-stars {margin:5px 0}
#trh-hub .trh11-entry-shop .vf-review-card > p {margin:5px 0;line-height:1.75;overflow-wrap:anywhere}
/* The rating badges are real values from Foodie review data. */
#trh-hub .trh11-entry-shop .vf-review-card > .vf-tags:has(> .vf-badge) {
  grid-column:2;
  grid-row:1 / span 8;
  display:flex!important;
  flex-direction:column;
  align-items:stretch;
  align-self:start;
  gap:7px;
  border-left:1px solid #f1d7e1;
  margin:0;
  padding:2px 0 2px 14px;
}
#trh-hub .trh11-entry-shop .vf-review-card > .vf-tags:has(> .vf-badge)::before {
  content:'★ คะแนนรายด้าน';
  color:#a72e65;
  font-weight:750;
  font-size:12px;
  margin-bottom:5px;
}
#trh-hub .trh11-entry-shop .vf-review-card > .vf-tags:has(> .vf-badge) > .vf-badge {
  display:block;
  align-self:stretch;
  width:100%;
  border-radius:11px;
  white-space:normal;
  font-size:11px;
  padding:6px 9px;
  line-height:1.5;
}
/* The food-photo column is fixed-width and wraps without scattered space. */
#trh-hub .trh11-entry-shop .vf-review-card > .vf-photos {
  grid-column:3;
  grid-row:1 / span 8;
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,76px))!important;
  align-content:start!important;
  justify-content:start!important;
  gap:7px!important;
  margin:0!important;
  width:100%;
}
#trh-hub .trh11-entry-shop .vf-review-card > .vf-photos > * {
  width:76px!important;height:76px!important;max-width:76px!important;
  min-width:0!important;max-height:76px!important;
  flex:none!important;margin:0!important;overflow:hidden;border-radius:11px!important;
}
#trh-hub .trh11-entry-shop .vf-review-card > .vf-photos img {
  width:100%!important;height:100%!important;max-width:none!important;
  object-fit:cover!important;display:block!important;
}
/* Replies, actions and the report control stay in their original flow, full width. */
#trh-hub .trh11-entry-shop .vf-review-card > .vf-reply,
#trh-hub .trh11-entry-shop .vf-review-card > .vf-actions,
#trh-hub .trh11-entry-shop .vf-review-card > details {
  grid-column:1 / -1;
  grid-row:auto;
  margin-top:11px;
}
/* The restaurant photos/rating column should not reserve empty space if missing. */
#trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-tags > .vf-badge)) {
  grid-template-columns:minmax(0,1fr) minmax(0,245px);
}
#trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-tags > .vf-badge)) > .vf-photos {
  grid-column:2;
}
#trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-photos)) {
  grid-template-columns:minmax(0,1fr) minmax(155px,205px);
}
#trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-photos)) > .vf-tags:has(> .vf-badge) {
  grid-column:2;
}
#trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-photos)):not(:has(> .vf-tags > .vf-badge)) {
  grid-template-columns:minmax(0,1fr);
}
/* General comments already use the same shell in V1.5; keep those as text-only cards. */
@media(max-width:940px){
  #trh-hub .trh11-entry-shop .vf-review-card,
  #trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-tags > .vf-badge)),
  #trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-photos)) {
    grid-template-columns:minmax(0,1fr) minmax(150px,195px);
  }
  #trh-hub .trh11-entry-shop .vf-review-card > .vf-tags:has(> .vf-badge) {
    grid-column:2;grid-row:1 / span 8;
  }
  #trh-hub .trh11-entry-shop .vf-review-card > .vf-photos {
    grid-column:1/-1;grid-row:auto;margin:9px 0!important;
  }
}
@media(max-width:650px){
  #trh-hub .trh11-entry-shop .vf-review-card,
  #trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-tags > .vf-badge)),
  #trh-hub .trh11-entry-shop .vf-review-card:not(:has(> .vf-photos)) {
    display:flex!important;flex-direction:column;gap:6px;
  }
  #trh-hub .trh11-entry-shop .vf-review-card > * {width:100%;}
  #trh-hub .trh11-entry-shop .vf-review-card > .vf-tags:has(> .vf-badge) {
    flex-direction:row;flex-wrap:wrap;border-left:0;
    border-top:1px solid #f1d7e1;padding:9px 0 0;margin:7px 0 0;
  }
  #trh-hub .trh11-entry-shop .vf-review-card > .vf-tags:has(> .vf-badge)::before {flex:0 0 100%;}
  #trh-hub .trh11-entry-shop .vf-review-card > .vf-tags:has(> .vf-badge) > .vf-badge {width:auto;max-width:100%;}
  #trh-hub .trh11-entry-shop .vf-review-card > .vf-photos {width:100%;margin:8px 0!important;}
}
@media(prefers-reduced-motion:reduce){#trh-hub .trh11-entry-shop * {scroll-behavior:auto!important}}
