/* =========================================================
   Reviews — rating input + submission form polish.
   Folosit pe /lasa-recenzie (formular). Stilurile cardului-container
   sunt reluate din /auth.css.
========================================================= */

/* Honeypot field: invisibil, in afara fluxului, dar focusabil de boti. */
.hp-field {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Small helper text (sub textarea). */
.auth-help {
  margin: 0.4rem 0 0;
  font-size: 0.8rem;
  color: var(--text-muted, #6f6557);
}

/* Stilul textarea-ului ca sa nu vina cu inaltime fixa indirect. */
textarea.auth-input {
  min-height: 130px;
  resize: vertical;
  font-family: inherit;
  line-height: 1.55;
}

select.auth-input {
  appearance: none;
  -webkit-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(4, 99, 7, 0.6) 50%),
    linear-gradient(135deg, rgba(4, 99, 7, 0.6) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 12px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 36px;
  cursor: pointer;
}

/* ============= Rating stars input ============= */
.rating-input {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  margin-top: 0.35rem;
  flex-wrap: wrap;
}

.rating-star {
  appearance: none;
  display: grid;
  place-items: center;
  width: 46px;
  height: 48px;
  background: #fff;
  border: 1px solid #cbd5cc;
  border-radius: 8px;
  padding: 0;
  font-size: 1.75rem;
  line-height: 1;
  color: #86968a;
  cursor: pointer;
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
  user-select: none;
}

.rating-star:hover,
.rating-star:focus-visible {
  color: #987124;
  border-color: #ad8a3a;
  background: #f7efd9;
}
.rating-star:focus-visible { outline: 2px solid #12472c; outline-offset: 3px; }

.rating-star.is-active {
  color: #987124;
  border-color: #c5aa68;
  background: #f7efd9;
}

.rating-star.is-active:hover,
.rating-star.is-active:focus-visible {
  color: #B8941F;
}

.rating-value {
  margin-left: 0.6rem;
  font-size: 0.92rem;
  color: var(--text-secondary, #5a4f3a);
  font-weight: 600;
}

/* ============= Submit state ============= */
.review-form-card [data-submit][disabled] {
  opacity: 0.65;
  cursor: progress;
}

/* ============= Success state — ascundem formularul + aratam mesaj mare ============= */
.review-success-block {
  text-align: center;
  padding: 1.5rem 0.5rem;
}

.review-success-block .check-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 1rem;
  border-radius: 999px;
  background: rgba(4, 99, 7, 0.1);
  color: #046307;
  display: grid;
  place-items: center;
  font-size: 2rem;
  font-weight: 700;
}

.review-success-block h2 {
  margin: 0 0 0.5rem;
  font-family: var(--font-heading, Georgia, serif);
  color: var(--text-primary, #0d2614);
}

.review-success-block p {
  margin: 0;
  color: var(--text-secondary, #5a4f3a);
  line-height: 1.6;
}

.review-success-block .actions {
  margin-top: 1.25rem;
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* Editorial invitation shared with the review form. */
.home-reviews, .review-page {
  --review-green: #0d2614;
  --review-ivory: #faf3dd;
  --review-copy: #d2dcd0;
  background: var(--review-green);
  color: var(--review-ivory);
}
.reviews-eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 22px;
  color: #d9c58b;
  font-size: .75rem;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.reviews-eyebrow::before { content: ''; width: 28px; height: 1px; flex: 0 0 auto; background: #b7a16a; }
.home-reviews { padding-block: clamp(64px, 7vw, 96px); scroll-margin-top: 72px; }
.home-reviews-invitation {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(36px, 6vw, 88px);
}
.home-reviews h2, .review-intro h1 {
  margin: 0;
  color: var(--review-ivory);
  font-size: clamp(2.3rem, 3.7vw, 3.4rem);
  font-weight: 500;
  line-height: 1.18;
  letter-spacing: -.035em;
}
.home-reviews h2 em, .review-intro h1 em { color: #dfcc94; font-weight: inherit; }
.home-reviews-copy p, .review-intro > p:not(.reviews-eyebrow) {
  margin: 0 0 18px;
  font-size: 1rem;
  color: var(--review-copy);
  line-height: 1.8;
}
.home-reviews-copy p:first-child { color: var(--review-ivory); font-size: 1.125rem; }
.home-reviews-copy .btn { margin-top: 7px; white-space: normal; text-align: center; }
.home-reviews-note { display: block; margin-top: 14px; color: #b7c8b7; font-size: .8125rem; line-height: 1.6; }
.home-reviews .reviews-approved { margin-top: 44px; }
.home-reviews .testimonial-card {
  max-width: none;
  padding: 26px;
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(223, 204, 148, .25);
  border-radius: 4px;
  box-shadow: none;
  text-align: left;
}
.home-reviews .testimonial-text { color: var(--review-ivory); font-size: 1rem; }
.home-reviews .testimonial-author { color: #dfcc94; }
.home-reviews .testimonial-card > p:last-child { color: var(--review-copy); }

.review-page { padding: 128px 0 80px; min-height: 85vh; }
.review-layout {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: clamp(36px, 6vw, 88px);
  align-items: start;
  max-width: 1160px;
}
.review-intro { position: sticky; top: 112px; padding-top: 20px; }
.review-intro h1 { margin-bottom: 26px; }
.review-writing-guide { margin: 30px 0; padding-top: 24px; border-top: 1px solid rgba(250,243,221,.18); }
.review-writing-guide h2 { color: var(--review-ivory); font-size: 1.25rem; margin: 0 0 16px; }
.review-writing-guide ul { margin: 0; padding-left: 18px; color: var(--review-copy); font-size: .9375rem; line-height: 1.8; }
.review-writing-guide li { margin: 0 0 10px; padding-left: 4px; }
.review-writing-guide li::marker { color: #c7b174; }
.review-intro > .review-intro-note { font-size: .8125rem; color: #b7c8b7; }
.review-back-link { display: inline-block; padding-block: 8px; color: var(--review-ivory); font-size: .875rem; text-decoration: underline; text-underline-offset: 5px; }
.review-back-link:hover { color: #dfcc94; }
.review-form-card.auth-card {
  max-width: none;
  padding: clamp(24px, 3.2vw, 40px);
  background: #fcfaf3;
  border: 1px solid rgba(223,204,148,.7);
  border-radius: 8px;
  box-shadow: 0 18px 48px rgba(0,0,0,.12);
}
.review-form-card .auth-card-title { text-align: left; font-size: 1.875rem; color: #0d2614; }
.review-form-card .auth-card-sub { text-align: left; line-height: 1.7; color: #526156; margin-bottom: 26px; }
.review-form-card .auth-form { gap: 22px; }
.review-form-card .auth-label { font-size: .875rem; line-height: 1.6; color: #263e2e; }
.review-optional { font-weight: 400; font-size: .8125rem; color: #65736a; }
.review-form-card .auth-input { min-height: 48px; border: 1px solid #cbd5cc; border-radius: 5px; font-size: 1rem; }
.review-form-card .auth-input:focus { border-color: #12472c; box-shadow: 0 0 0 3px rgba(18,71,44,.12); }
.review-form-card textarea.auth-input { min-height: 160px; }
.review-form-card .auth-help { color: #65736a; line-height: 1.6; }
.review-submit { width: 100%; white-space: normal; }
.review-success-block .btn { white-space: normal; }
.review-success-block { color: #263e2e; }
.home-reviews a:focus-visible, .review-back-link:focus-visible { outline: 2px solid #dfcc94; outline-offset: 5px; }

@media (max-width: 767px) {
  .home-reviews-invitation, .review-layout { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .home-reviews h2, .review-intro h1 { font-size: clamp(2.1rem, 8.8vw, 3rem); }
  .home-reviews-copy .btn { width: 100%; }
  .home-reviews-note { text-align: center; }
  .review-page { padding-top: 108px; padding-bottom: 56px; }
  .review-intro { position: static; padding: 0; }
  .review-writing-guide { display: none; }
  .review-intro > .review-intro-note { margin-bottom: 8px; }
  .review-form-card.auth-card { padding: 24px 20px; }
  .rating-input { gap: 4px; }
  .rating-star { width: calc((100% - 16px) / 5); max-width: 42px; height: 46px; flex-shrink: 0; }
  .rating-value { margin-left: 4px; font-size: .8125rem; }
}
@media (prefers-reduced-motion: reduce) {
  .rating-star { transition: none; }
}
