/* kkp Küsimustiku stiilid v2.27 */

.kkp-poll-container {
  max-width: 500px;
  margin: 20px auto;
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  font-family: sans-serif;
}

.kkp-poll-title {
  margin-top: 0;
  font-size: 22px;
  color: #1c1e21;
  font-weight: bold;
  margin-bottom: 20px;
}

.kkp-poll-label-box {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  cursor: pointer;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  transition: background 0.2s ease-in-out;
}

.kkp-poll-label-box:hover {
  background: #f0f2f5;
}

.kkp-poll-label-box input {
  flex-shrink: 0;
  margin: 0;
  cursor: pointer;
  width: 18px;
  height: 18px;
}

.kkp-label-text {
  flex-grow: 1;
  font-size: 15px;
  line-height: 1.4;
  word-break: break-word;
}

.kkp-status-badge {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: bold;
  padding: 4px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kkp-disabled-box {
  background: #f8f9fa;
  cursor: not-allowed;
  border-color: #eee;
}

.kkp-poll-textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-family: inherit;
  resize: vertical;
}

.kkp-rating-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  justify-content: flex-start;
}

.kkp-rating-item {
  cursor: pointer;
  flex: 1 1 auto;
  min-width: 32px;
  text-align: center;
}

.kkp-rating-item input {
  display: none;
}

.kkp-rating-box {
  display: block;
  padding: 10px 0;
  border: 1px solid #ddd;
  border-radius: 6px;
  background: #fff;
  font-weight: bold;
  transition: 0.2s;
}

.kkp-rating-item:hover .kkp-rating-box {
  background: #f0f2f5;
}

.kkp-rating-item input:checked + .kkp-rating-box {
  background: #1877f2;
  color: #fff;
  border-color: #1877f2;
}

.kkp-poll-submit {
  background: #1877f2;
  color: #fff;
  border: none;
  padding: 15px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  font-size: 14px;
  width: 100%;
  margin-top: 15px;
  transition: background 0.2s ease-in-out;
}

.kkp-poll-submit:hover {
  background: #166fe5;
}

.kkp-poll-submit:disabled {
  background: #9cbff1;
  cursor: not-allowed;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.kkp-question-heading {
  font-weight: bold;
  font-size: 16px;
  margin-bottom: 12px;
  color: #1c1e21;
  line-height: 1.3;
}

.kkp-section-title {
  font-size: 18px;
  font-weight: bold;
  color: #1877f2;
  margin-top: 30px;
  margin-bottom: 15px;
  border-bottom: 2px solid #eef0f2;
  padding-bottom: 8px;
}

.kkp-toggle-form-btn {
  width: 100%;
  background: #1877f2;
  color: #fff;
  border: none;
  padding: 14px 18px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  font-size: 14px;
  margin-bottom: 18px;
  transition: background 0.2s ease-in-out;
}

.kkp-toggle-form-btn:hover {
  background: #166fe5;
}

.kkp-form-hidden {
  display: none;
}

.kkp-form-visible {
  display: block;
}

.kkp-poll-intro {
  margin-bottom: 20px;
  color: #4b5563;
  font-size: 15px;
  line-height: 1.6;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 14px 16px;
}

.kkp-location-select {
  min-width: 260px;
  max-width: 320px;
}

.kkp-maps-link {
  display: inline-block;
  margin-top: 6px;
  font-size: 13px;
  color: #1877f2;
  text-decoration: none;
  font-weight: 600;
}

.kkp-maps-link:hover {
  text-decoration: underline;
}

.kkp-booking-block {
  margin-top: 24px;
}

.kkp-booking-help {
  margin: 0 0 14px;
  color: #666;
  font-size: 14px;
}

/* Kalendri grid süsteem */
.kkp-calendar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.kkp-cal-date-box {
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  text-align: center;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.2s ease;
  background: #fff;
}

.kkp-cal-date-box:hover {
  border-color: #1877f2;
  transform: translateY(-2px);
}

.kkp-cal-date-box.is-active {
  border-color: #1877f2;
  box-shadow: 0 0 0 3px rgba(24, 119, 242, 0.2);
  transform: none;
}

.kkp-cal-date-box.is-full {
  opacity: 0.6;
  cursor: not-allowed;
  background: #f8f9fa;
}

.kkp-cal-date-box.is-full:hover {
  border-color: #e5e7eb;
  transform: none;
}

.kkp-cal-month {
  background: #1877f2;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 4px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.kkp-cal-date-box.is-full .kkp-cal-month {
  background: #6c757d;
}

.kkp-cal-day {
  font-size: 28px;
  font-weight: 800;
  color: #1c1e21;
  padding: 12px 0 2px;
  line-height: 1;
}

.kkp-cal-weekday {
  font-size: 12px;
  color: #666;
  padding-bottom: 8px;
  text-transform: capitalize;
}

.kkp-cal-location-preview {
  font-size: 11px;
  color: #4b5563;
  padding: 0 8px 10px;
  line-height: 1.4;
  word-wrap: break-word;
  white-space: normal;
  display: block;
}

.kkp-cal-status {
  font-size: 10px;
  font-weight: 700;
  padding-bottom: 8px;
  color: #28a745;
  text-transform: uppercase;
}

.kkp-cal-date-box.is-full .kkp-cal-status {
  color: #d63638;
}

.kkp-booking-day-panel {
  display: none;
  padding: 16px;
  border: 2px solid #1877f2;
  border-radius: 10px;
  background: #f0f6ff;
  grid-column: 1 / -1;
  margin: 0;
  animation: fadeIn 0.3s ease-out;
}

.kkp-booking-day-panel.is-open {
  display: block;
}

.kkp-booking-location {
  padding: 0 0 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  border-bottom: 1px solid #cfe0ff;
  margin-bottom: 14px;
}

.kkp-booking-times {
  display: grid;
  gap: 10px;
}

.kkp-booking-slot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 12px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.2s;
}

.kkp-booking-slot:hover:not(.kkp-booking-slot-disabled) {
  border-color: #1877f2;
}

.kkp-booking-slot input {
  margin-right: 10px;
}

.kkp-booking-slot-time {
  flex: 1;
  font-weight: 700;
  font-size: 16px;
}

.kkp-booking-slot-disabled {
  background: #f8f9fa;
  cursor: not-allowed;
  opacity: 0.8;
}

.kkp-booking-selected {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 8px;
  background: #f0f6ff;
  border: 1px solid #cfe0ff;
  color: #1c1e21;
  line-height: 1.5;
}

/* Paketikaardi vastusetüüp */
.kkp-package-card {
  display: block;
  cursor: pointer;
  margin: 0;
}

.kkp-package-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.kkp-package-card-inner {
  display: block;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  background: #fff;
  padding: 16px;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease,
    background 0.2s ease;
}

.kkp-package-card:hover .kkp-package-card-inner {
  border-color: #1877f2;
  transform: translateY(-2px);
}

.kkp-package-card input:checked + .kkp-package-card-inner {
  border-color: #1877f2;
  box-shadow: 0 0 0 3px rgba(24, 119, 242, 0.16);
  background: #f8fbff;
}

.kkp-package-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap; /* Lubab pika märgise puhul hinnal ilusti paigutuda */
}

.kkp-package-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4; /* Parandatud reavahe, et mitu rida teksti oleks loetav */
  color: #1877f2;
  background: #eaf2ff;
  border-radius: 6px; /* Muudetud ümaraks ristkülikuks, sobib pika tekstiga ideaalselt */
  padding: 6px 10px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.kkp-package-price {
  font-size: 22px;
  font-weight: 800;
  color: #1c1e21;
  line-height: 1;
  white-space: nowrap;
  flex-shrink: 0; /* Garanteerib, et hind ei lähe kunagi laiuse puudusel pooleks */
}

.kkp-package-title {
  font-size: 18px;
  font-weight: 700;
  color: #1c1e21;
  line-height: 1.3;
  margin-bottom: 8px;
}

.kkp-package-subtitle {
  font-size: 14px;
  color: #4b5563;
  line-height: 1.5;
  margin-bottom: 12px;
}

.kkp-package-features {
  margin: 0;
  padding-left: 18px;
  color: #374151;
}

.kkp-package-features li {
  margin: 0 0 6px;
  line-height: 1.45;
}

@media (max-width: 640px) {
  .kkp-package-card-inner {
    padding: 14px;
  }
  .kkp-package-price {
    font-size: 20px;
  }
  .kkp-package-title {
    font-size: 17px;
  }
}

/* Kohustusliku välja veateade */
.kkp-error-border {
  border: 1px solid #d63638 !important;
  border-left: 4px solid #d63638 !important;
  background-color: #fff9fa !important;
  padding: 10px;
  border-radius: 8px;
  transition: all 0.3s ease;
}
