/* ===== HVĚZDIČKY V FORMULÁŘI ===== */

/* Schovat původní CF7 checkboxy */
.wpcf7 .wpcf7-form-control-wrap[data-name="rating"] .wpcf7-form-control { 
  position: absolute !important; 
  left: -9999px !important; 
  top: auto !important; 
  width: 1px !important; 
  height: 1px !important; 
  overflow: hidden !important; 
}

/* Wrapper pro hvězdy */
.wpcf7 .nps-stars-ui {
  --size: 28px;
  --off: #c9cdd3;
  --on: #f6b800;
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  margin: 0.25rem 0 1rem 0;
}

.wpcf7 .nps-stars-ui .nps-star {
  appearance: none;
  border: 0;
  background: none;
  cursor: pointer;
  width: var(--size);
  height: var(--size);
  padding: 0;
  line-height: 1;
}

.wpcf7 .nps-stars-ui .nps-star::before {
  content: "";
  display: block;
  width: 100%;
  height: 100%;
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 .9l3.09 6.26 6.91 1-5 4.87 1.18 6.89L12 17.77 5.82 19.92 7 13.13 2 8.16l6.91-1L12 .9z'/></svg>") center/contain no-repeat;
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 .9l3.09 6.26 6.91 1-5 4.87 1.18 6.89L12 17.77 5.82 19.92 7 13.13 2 8.16l6.91-1L12 .9z'/></svg>") center/contain no-repeat;
  background: var(--off);
  transition: background 0.12s ease;
}

.wpcf7 .nps-stars-ui .nps-star.is-on::before {
  background: var(--on);
}

.wpcf7 .nps-stars-ui .nps-star:hover::before {
  filter: brightness(1.1);
}

.wpcf7 .nps-stars-ui .nps-star:focus-visible {
  outline: 2px solid #0ea5e9;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Kompaktnější textarea */
.wpcf7 textarea[name="review_text"] {
  min-height: 140px;
  resize: vertical;
  line-height: 1.45;
}

/* Jméno a email vedle sebe */
.wpcf7 .nps-form-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.wpcf7 .nps-form-row > p {
  flex: 1;
  min-width: 250px;
  margin: 0 0 1rem 0;
}

.wpcf7 .nps-form-row input[type="text"],
.wpcf7 .nps-form-row input[type="email"] {
  width: 100%;
  box-sizing: border-box;
}


/* ===== RECENZE – VÝPIS ===== */

#wpcf7-f3154-p3157-o1 > form {
  margin-top: 2em;
}

#post-56034 > div > div > div.elementor-element.elementor-element-e7f5875.e-grid.eshop-produkt.e-con-boxed.e-con.e-parent > div > div.elementor-element.elementor-element-3088b40.e-flex.e-con-boxed.e-con.e-child > div {
  padding-top: 0;
}

#post-56034 > div > div > div.elementor-element.elementor-element-e7f5875.e-grid.eshop-produkt.e-con-boxed.e-con.e-parent > div > div.elementor-element.elementor-element-3088b40.e-flex.e-con-boxed.e-con.e-child > div > div.elementor-element.elementor-element-178543f.elementor-widget.elementor-widget-text-editor > div > div > header > h3 {
  margin-bottom: 0;
}

/* === LIST & KARTY ======================================================= */
.nps-reviews-list {
  display: grid;
  gap: 18px;
}

.nps-review {
  position: relative;
  background: #fff;
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 50px;
  box-shadow: rgba(0, 0, 0, 0.25) 0px 4px 38px 0px;
  padding: 2.5em 3em;
}

/* Text recenze */
.nps-review-body {
  margin: 8px 0 10px;
  color: #111827;
  line-height: 1.55;
  font-size: 1rem;
  padding-left: 6px;
}

/* Řádek: hvězdy + autor (vedle sebe) */
.nps-review-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
  margin-bottom: 0;
}

/* Autor */
.nps-author {
  font-weight: 600;
  color: #1f2937;
  line-height: 1.3;
  margin-left: 1em;
}

/* Profese (NOVĚ upraveno) */
.nps-profession {
  display: inline;
  font-size: 0.9em;
  opacity: 0.85;
  font-style: italic;
  font-weight: 400;
}

/* === HVĚZDIČKY ========================================================= */
.nps-rating {
  position: relative;
  display: inline-block;
  line-height: 1;
  font-size: 0;
  margin: 0;
}

/* Šedý podklad + zlaté vyplnění */
.nps-rating::before,
.nps-rating::after {
  content: "★★★★★";
  letter-spacing: 2px;
  font-size: 16px;
}

.nps-rating::before { 
  color: #d7d7d7; 
}

.nps-rating::after {
  position: absolute; 
  inset: 0;
  color: #d39b00 !important;
  overflow: hidden; 
  width: 0%;
}

/* Mapování 1–5 hvězd */
.nps-rating[data-rating="1"]::after { width: 20%; }
.nps-rating[data-rating="2"]::after { width: 40%; }
.nps-rating[data-rating="3"]::after { width: 60%; }
.nps-rating[data-rating="4"]::after { width: 80%; }
.nps-rating[data-rating="5"]::after { width: 100%; }

/* Screen reader only */
.sr-only {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}


/* ===== MODAL OKNO ===== */

.nps-reviews-show-more-wrap {
  text-align: center;
  margin: 2rem 0;
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.nps-reviews-show-more,
.nps-reviews-write-review {  
  background-color: #131A5B;
  color: #fff;
  border: none;
  padding: 0.75rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.nps-reviews-show-more:hover,
.nps-reviews-write-review:hover {
  background: #1f2937;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.nps-reviews-write-review {
  color: #131A5B;
  background-color: #f1f1f1;
  border-color: #131A5B;
}

.nps-reviews-write-review:hover {
  background-color: #131A5B;
  color: #fff;
}

.nps-reviews-show-more .nps-reviews-count {
  opacity: 0.8;
  font-weight: 400;
}

.nps-reviews-modal {
  position: fixed !important;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 999999;
  display: none !important;
}

.nps-reviews-modal * {
  display: none !important;
}

.nps-reviews-modal.is-open {
  display: block !important;
}

.nps-reviews-modal.is-open * {
  display: revert !important;
}

.nps-reviews-modal.is-open {
  animation: npsModalFadeIn 0.2s ease;
}

@keyframes npsModalFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.nps-reviews-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
}

.nps-reviews-modal.is-open .nps-reviews-modal-overlay {
  animation: npsOverlayFadeIn 0.3s ease;
}

@keyframes npsOverlayFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.nps-reviews-modal-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-width: 900px;
  max-height: 85vh;
  min-height: 0;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.nps-reviews-modal.is-open .nps-reviews-modal-content {
  animation: npsModalSlideIn 0.3s ease;
}

@keyframes npsModalSlideIn {
  from {
    transform: translate(-50%, -45%);
    opacity: 0;
  }
  to {
    transform: translate(-50%, -50%);
    opacity: 1;
  }
}

.nps-reviews-modal-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-shrink: 0;
  gap: 1rem;
  position: relative;
}

.nps-reviews-modal-header h2 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
  color: #111827;
  flex: 1;
  padding-right: 2rem;
}

.nps-reviews-modal-close {
  background: none;
  border: none;
  font-size: 2rem;
  line-height: 1;
  color: #6b7280;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  min-width: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s ease;
  flex-shrink: 0;
  position: absolute;
  right: 1.5rem;
  top: 1.5rem;
}

.nps-reviews-modal-close:hover {
  background: rgba(0, 0, 0, 0.05);
  color: #111827;
}

.nps-reviews-modal-body {
  padding: 1.5rem 2rem 2rem;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1 1 auto;
  max-height: calc(85vh - 80px);
}

/* Custom scrollbar pro modal */
.nps-reviews-modal-body::-webkit-scrollbar {
  width: 8px;
}

.nps-reviews-modal-body::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

.nps-reviews-modal-body::-webkit-scrollbar-thumb {
  background: #c9cdd3;
  border-radius: 4px;
}

.nps-reviews-modal-body::-webkit-scrollbar-thumb:hover {
  background: #a0a5ac;
}

.nps-reviews-list-modal {
  display: grid;
  gap: 18px !important;
}

.nps-reviews-list-modal .nps-review {
  margin: 0 !important;
}

/* Hvězdičky v modalu musí být žluté */
.nps-reviews-modal .nps-rating::after {
  color: #d39b00 !important;
}

.nps-reviews-modal .nps-rating::before {
  color: #d7d7d7 !important;
}

/* Prevent body scroll when modal is open */
body.nps-modal-open {
  overflow: hidden;
}

/* Skrýt CF7 chybové hlášky a response output v modalu dokud nejsou potřeba */
.nps-write-review-modal .wpcf7-response-output {
  display: none !important;
}

.nps-write-review-modal .wpcf7-form.invalid .wpcf7-response-output,
.nps-write-review-modal .wpcf7-form.sent .wpcf7-response-output,
.nps-write-review-modal .wpcf7-form.failed .wpcf7-response-output,
.nps-write-review-modal .wpcf7-form.spam .wpcf7-response-output {
  display: block !important;
  margin-top: 1rem;
}

.nps-write-review-modal .wpcf7-not-valid-tip {
  font-size: 0.875rem;
  color: #dc2626;
  margin-top: 0.25rem;
}

/* Skrýt screen reader hlášky */
.nps-write-review-modal .wpcf7 .screen-reader-response {
  display: none !important;
}


/* ===== MOBILNÍ DOLADĚNÍ ===== */

@media (max-width: 640px) {
  /* Formulář */
  .wpcf7 .nps-form-row {
    flex-direction: column;
  }
  
  .wpcf7 .nps-form-row > p {
    min-width: 100%;
  }
  
  /* Recenze */
  .nps-review { 
    padding: 12px 14px; 
    border-radius: 12px; 
  }
  
  .nps-review-body { 
    margin: 6px 0 8px; 
    padding-left: 4px; 
  }
  
  .nps-rating::before, 
  .nps-rating::after { 
    font-size: 15px; 
  }
  
  .nps-review-foot { 
    gap: 10px; 
    margin-top: 6px; 
    flex-direction: column;
    align-items: flex-start;
  }
  
  .nps-author {
    margin-left: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
  }
  
  .nps-profession::before {
    content: '';
  }
  
  /* Modal */
  .nps-reviews-modal-content {
    width: 95%;
    max-height: 90vh;
    border-radius: 16px;
  }
  
  .nps-reviews-modal-header {
    padding: 1rem 1.25rem;
  }
  
  .nps-reviews-modal-header h2 {
    font-size: 1.25rem;
  }
  
  .nps-reviews-modal-body {
    padding: 1rem 1.25rem 1.5rem;
  }
  
  .nps-reviews-show-more {
    padding: 0.6rem 1.5rem;
    font-size: 0.95rem;
  }
}

div.nps-reviews-modal.is-open article.nps-review{
  margin-bottom: 1.5rem!important;
}


.wpcf7 .hidden-fields-container {
    display: none!important;
}

div.nps-reviews-modal.is-open .nps-form-row{
     display: flex !important;
    gap: 1rem;
    flex-wrap: wrap; 
}



#kurz-recenze .nps-review {
    margin-left: -1.5rem;
    padding: 0.5em 0.5em;
    border-radius: 21px;
}



#kurz-recenze .nps-review-foot,
#kurz-recenze .nps-rating  {
display: block;
}

#kurz-recenze .nps-author  {
font-size: 15px;
}


