/* Reviews van kopers: blok op de homepage (js/reviews.js), schrijfpagina (review.html)
   en plaatspagina voor Lucia (review-keuren.html). */

/* Sterrenmeter: grijze sterren met daaroverheen de wijnrode, zo breed als --vulling */
.sterren-meter {
  position: relative; display: inline-block;
  color: rgba(74, 22, 34, .18);
  letter-spacing: 2px; line-height: 1;
}
.sterren-meter::before {
  content: "★★★★★";
  position: absolute; left: 0; top: 0;
  width: var(--vulling, 100%); overflow: hidden; white-space: nowrap;
  color: var(--wijn);
}

/* Bij de prijs in het productblok */
.product-reviews {
  display: inline-flex; align-items: center; gap: 8px;
  margin: -6px 0 14px;
  font-size: 14px; color: var(--zacht); text-decoration: none;
}
.product-reviews:hover { color: var(--wijn); }
.product-reviews .sterren-meter { font-size: 15px; }

/* Blok op de homepage */
.reviews { padding: 90px 28px 80px; }
.reviews .sectie-kop { margin-bottom: 36px; }
.reviews-score { display: inline-flex; align-items: center; gap: 10px; margin: 6px 0 0; color: var(--zacht); }
.reviews-score .sterren-meter { font-size: 20px; }
.reviews-score strong { font-family: var(--serif); font-size: 1.6rem; font-weight: 500; color: var(--wijn); }

.reviews-raster {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: start;
  gap: 16px;
  max-width: 1120px; margin: 0 auto;
}
.review-kaart {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  padding: 0 0 18px;
}
.review-kaart > p { margin-left: 20px; margin-right: 20px; }
.review-kaart > p:first-child { margin-top: 20px; }
.review-foto { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; margin-bottom: 16px; background: var(--naakt); }
.review-sterren { margin: 0 0 8px; color: var(--wijn); font-size: 16px; letter-spacing: 2px; }
.review-sterren-leeg { color: rgba(74, 22, 34, .18); }
.review-tekst { margin: 0 0 12px; font-size: 15.5px; line-height: 1.6; color: var(--inkt); white-space: pre-line; }
.review-wie { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin: 0 0 2px; font-size: 14px; }
.review-wie strong { font-weight: 600; color: var(--wijn); }
.review-echt {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11.5px; letter-spacing: .06em; color: #2F6B4F;
}
.review-echt::before {
  content: ""; width: 13px; height: 13px; border-radius: 50%;
  background: #2F6B4F url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M3 6.2l2 2 4-4.4' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat;
}
.review-meta { margin: 0; font-size: 13px; color: var(--zacht); }
.reviews-meer-plek { text-align: center; margin: 28px 0 0; }
.reviews-meer-plek:has(> [hidden]) { display: none; }
.reviews-uitleg { max-width: 640px; margin: 28px auto 0; text-align: center; font-size: 13px; line-height: 1.6; color: var(--zacht); }

/* Schrijfpagina */
.review-form .veld { margin-bottom: 20px; }
.veld textarea {
  width: 100%;
  font: inherit; font-size: 16px; line-height: 1.5;
  padding: 13px 14px 11px;
  border-radius: 12px;
  border: 1px solid rgba(74, 22, 34, .25);
  background: #fff; color: var(--inkt);
  resize: vertical;
}
.veld textarea:focus { outline: 2px solid var(--roze); outline-offset: 1px; border-color: var(--wijn); }
.veld-label { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--wijn); }
.veld-label span { font-weight: 300; letter-spacing: .04em; text-transform: none; color: var(--zacht); }
.tekens { font-size: 12.5px; color: var(--zacht); }
.tekens:empty { display: none; }

.sterren-kiezen { margin-bottom: 22px !important; }
.sterren-kiezen legend { font-size: 1.5rem !important; }
.sterren-rij { position: relative; display: flex; gap: 6px; }
.sterren-rij label {
  width: 44px; height: 44px; cursor: pointer;
  background: rgba(74, 22, 34, .16);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.5l2.9 6.1 6.6.8-4.9 4.6 1.3 6.6L12 17.3l-5.9 3.3 1.3-6.6-4.9-4.6 6.6-.8z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.5l2.9 6.1 6.6.8-4.9 4.6 1.3 6.6L12 17.3l-5.9 3.3 1.3-6.6-4.9-4.6 6.6-.8z'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: background .15s;
}
.sterren-rij input:focus-visible + label { outline: 2px solid var(--wijn); outline-offset: 2px; }
.sterren-rij[data-gekozen="1"] label:nth-of-type(-n+1),
.sterren-rij[data-gekozen="2"] label:nth-of-type(-n+2),
.sterren-rij[data-gekozen="3"] label:nth-of-type(-n+3),
.sterren-rij[data-gekozen="4"] label:nth-of-type(-n+4),
.sterren-rij[data-gekozen="5"] label:nth-of-type(-n+5) { background: var(--wijn); }

/* Wel bereikbaar met toetsenbord en schermlezer, niet zichtbaar en zonder breedte */
.verborgen-invoer, .sterren-rij input {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; opacity: 0;
}
.foto-kiezen { position: relative; display: flex; flex-wrap: wrap; align-items: flex-start; gap: 14px; }
.foto-knop { cursor: pointer; }
.foto-kiezen:has(.verborgen-invoer:focus-visible) .foto-knop { outline: 2px solid var(--wijn); outline-offset: 2px; }
.foto-voorbeeld { margin: 0; display: flex; flex-direction: column; gap: 6px; }
.foto-voorbeeld img { width: 120px; height: 150px; object-fit: cover; border-radius: 10px; }
.foto-weg { border: 0; background: none; padding: 0; font: inherit; font-size: 13px; color: var(--zacht); text-decoration: underline; cursor: pointer; text-align: left; }

/* Plaatspagina voor Lucia */
.keur-status { font-size: 14px; color: var(--zacht); }
.bestelkaart .review-sterren { font-size: 22px; }
.keur-tekst { font-family: var(--serif); font-size: 1.35rem; line-height: 1.4; color: var(--inkt); white-space: pre-line; }
.keur-foto { display: block; width: 100%; max-width: 360px; border-radius: 12px; margin: 12px 0 4px; }
.keur-uitleg { font-size: 13.5px; color: var(--zacht); margin: 22px 0 14px !important; }
.keur-weigeren { margin-top: 22px; }
.keur-weigeren .veld { margin-bottom: 10px; }
.veld select {
  width: 100%; font: inherit; font-size: 16px;
  padding: 12px 14px 10px;
  border-radius: 12px; border: 1px solid rgba(74, 22, 34, .25);
  background: #fff; color: var(--inkt);
}

@media (max-width: 960px) {
  .reviews-raster { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .reviews { padding: 64px var(--rand) 60px; }
  .reviews-raster { grid-template-columns: 1fr; }
  .sterren-rij label { width: 40px; height: 40px; }
}
