/**
 * Atelier — T41 Product Reviews.
 * Source: design/store-theme/01-atelier-fashion/pages/T41 Product Reviews.dc.html
 */

/* Suppress Magento's default product-reviews chrome that renders alongside the
 * themed block on review_product_list: the core page-title, the default rating
 * summary (.product-reviews-summary), the default add-review form (.review-form)
 * and the default review list (.review-list / .review-items / #customer-reviews).
 * The themed markup uses .atl-rv-* classes, so no collision. Scoped to the
 * product-reviews body class; CSS-hide rather than remove the core blocks, to
 * avoid the orphaned-module-reference 500 class. */
body.atl-page-product-reviews .page-title-wrapper,
body.atl-page-product-reviews .product-reviews-summary,
body.atl-page-product-reviews .review-form,
body.atl-page-product-reviews .review-list,
body.atl-page-product-reviews .review-items,
body.atl-page-product-reviews #customer-reviews,
body.atl-page-product-reviews .block.review-add,
body.atl-page-product-reviews .toolbar.review-toolbar,
/* review_product_list inherits the catalog_product_view (PDP) layout, so the
 * full themed PDP (.atl-pdp) + breadcrumbs render below the themed reviews
 * block. The T41 artboard is reviews-only, so hide the PDP + breadcrumbs too. */
body.atl-page-product-reviews [class*="atl-pdp"],
body.atl-page-product-reviews .atl-breadcrumbs:not(.atl-rv-breadcrumbs),
body.atl-page-product-reviews .breadcrumbs { display: none; }

.atl-rv-head { display: flex; gap: 16px; align-items: center; padding: 18px 40px 0; }
.atl-rv-head-thumb { width: 64px; aspect-ratio: 1/1; }
.atl-rv-title { font-family: 'Cormorant Garamond', serif; font-weight: 400; line-height: 1.12; margin: 0; font-size: 26px; text-wrap: balance; }
.atl-rv-back { font-size: 13px; color: var(--atl-accent); text-decoration: none; }

.atl-rv-layout { display: grid; grid-template-columns: 340px 1fr; gap: 32px; padding: 26px 40px 0; align-items: start; }
.atl-rv-side { display: flex; flex-direction: column; gap: 20px; position: sticky; top: 24px; }

.atl-rv-summary { background: var(--atl-surface); border: 1px solid var(--atl-border); padding: 26px; display: flex; flex-direction: column; gap: 12px; align-items: center; text-align: center; }
.atl-rv-summary-score { font-family: 'Cormorant Garamond', serif; font-size: 52px; font-weight: 400; }
.atl-rv-summary-stars { color: var(--atl-accent); font-size: 13px; letter-spacing: 2px; }
.atl-rv-summary-count { font-size: 13px; color: var(--atl-text-muted); }
.atl-rv-bars { width: 100%; display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.atl-rv-bar-row { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--atl-text-muted); }
.atl-rv-bar-star { width: 12px; }
.atl-rv-bar-track { flex: 1; height: 7px; border-radius: 99px; background: var(--atl-border); }
.atl-rv-bar-fill { height: 100%; border-radius: 99px; background: var(--atl-accent); }
.atl-rv-bar-pct { width: 30px; text-align: right; }
.atl-rv-summary .atl-btn { width: 100%; box-sizing: border-box; margin-top: 8px; }

.atl-rv-form { background: var(--atl-surface); border: 1px solid var(--atl-border); padding: 22px; display: flex; flex-direction: column; gap: 12px; }
.atl-rv-form-label { font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--atl-text-muted); }
.atl-rv-form-stars { display: flex; direction: rtl; justify-content: flex-end; gap: 5px; font-size: 20px; color: var(--atl-border-strong); }
.atl-rv-star-input { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); border: 0; opacity: 0; }
.atl-rv-star { display: inline-flex; align-items: center; justify-content: center; min-width: 32px; min-height: 32px; cursor: pointer; line-height: 1; }
.atl-rv-star-text { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); }
.atl-rv-star-input:checked ~ .atl-rv-star,
.atl-rv-star:hover,
.atl-rv-star:hover ~ .atl-rv-star { color: var(--atl-accent); }
.atl-rv-star-input:focus-visible + .atl-rv-star { outline: 2px solid var(--atl-focus-ring); outline-offset: 2px; }
.atl-rv-form .atl-btn { width: fit-content; padding: 10px 20px; font-size: 13px; }

.atl-rv-list { display: flex; flex-direction: column; gap: 16px; }
.atl-rv-card { background: var(--atl-surface); border: 1px solid var(--atl-border); padding: 24px; display: flex; flex-direction: column; gap: 8px; }
/* Verified-buyer pill sits to the right of the title row. */
.atl-rv-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.atl-rv-card-head-left { display: flex; gap: 10px; align-items: center; }
.atl-rv-card-stars { color: var(--atl-accent); font-size: 13px; letter-spacing: 2px; }
.atl-rv-card-title { font-size: 14px; font-weight: 600; }
.atl-rv-card-verified { font-size: 12px; color: var(--atl-accent); border: 1px solid var(--atl-accent); padding: 2px 8px; white-space: nowrap; }
/* Helpful votes: two buttons per card; the chosen one is aria-pressed. */
.atl-rv-vote { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0; }
.atl-rv-vote-label { font-size: 12.5px; color: var(--atl-text-subtle); }
.atl-rv-vote-btn { font: inherit; font-size: 12.5px; min-height: 44px; padding: 0 14px; background: transparent; color: var(--atl-text); border: 1px solid var(--atl-border); cursor: pointer; }
.atl-rv-vote-btn:hover { border-color: var(--atl-accent); }
.atl-rv-vote-btn[aria-pressed="true"] { border-color: var(--atl-accent); color: var(--atl-accent); font-weight: 600; }
.atl-rv-card-body { font-size: 14px; line-height: 1.7; color: var(--atl-text-muted); margin: 0; }
.atl-rv-card-meta { font-size: 12.5px; color: var(--atl-text-subtle); }
/* Honest empty state — shown when the product has no approved reviews. */
.atl-rv-empty { text-align: center; color: var(--atl-text-subtle); }

/* T41 pagination — base .atl-pagination comes from components/_toolbar.css
 * (loaded globally via default.xml); these are the reviews-page specifics. */
.atl-rv-pagination { padding: 8px 0; }
.atl-rv-pagination .atl-rv-pagination-ellipsis { border: 0; padding: 10px 4px; color: var(--atl-text-subtle); }

@media (max-width: 900px) {
  .atl-rv-layout { grid-template-columns: 1fr; }
  .atl-rv-side { position: static; display: contents; }
  .atl-rv-summary { order: 1; }
  .atl-rv-list { order: 2; }
  .atl-rv-form { order: 3; }
}
@media (max-width: 767px) {
  .atl-rv-head, .atl-rv-layout { padding-left: 20px; padding-right: 20px; }
  .atl-rv-title { font-size: 22px; }
}
