/* ===========================
   REVIEWS TAB
   =========================== */
#reviews-tab {
  width: 100%;
  padding: 0;
  margin-bottom: 60px;
  margin-top: 0;
}

.reviews-container {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

/* Tablet */
@media (min-width: 768px) {
  .reviews-container {
    padding: 2rem;
  }
}

/* Desktop */
@media (min-width: 1024px) {
  .reviews-container {
    padding: 2.5rem;
  }
}

/* ===========================
   REVIEW FORM CONTAINER
   =========================== */
.review-form-container {
  background: linear-gradient(135deg, var(--gray-50), var(--white));
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  margin-bottom: 2rem;
  border: 2px solid var(--gray-200);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.review-form-container:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

/* Tablet */
@media (min-width: 768px) {
  .review-form-container {
    padding: 2rem;
  }
}

.review-form-container h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--gray-900);
  margin-bottom: 1.5rem;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

/* Tablet */
@media (min-width: 768px) {
  .review-form-container h3 {
    font-size: 1.5rem;
  }
}

/* ===========================
   RATING INPUT
   =========================== */
.rating-input {
  margin-bottom: 1.5rem;
  text-align: center;
  padding: 1rem;
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200);
}

.rating-input label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 1rem;
  letter-spacing: 0.5px;
}

.stars {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  font-size: 1.75rem;
}

/* Tablet */
@media (min-width: 640px) {
  .stars {
    gap: 1rem;
    font-size: 2.5rem;
  }
}

.stars i {
  color: var(--gray-300);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.stars i:hover,
.stars i.active {
  color: #fbbf24;
  transform: scale(1.2);
}

.stars i.active {
  animation: starPop 0.3s ease;
}

@keyframes starPop {
  0%, 100% {
    transform: scale(1.2);
  }
  50% {
    transform: scale(1.4);
  }
}

/* ===========================
   FORM GROUP IN REVIEWS
   =========================== */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--gray-700);
  margin-bottom: 0.5rem;
}

.form-group textarea {
  width: 100%;
  min-height: 120px;
  padding: 1rem;
  border: 2px solid var(--gray-300);
  border-radius: var(--radius-lg);
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  color: var(--gray-800);
  resize: vertical;
  transition: var(--transition);
}

.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

/* ===========================
   SUBMIT REVIEW BUTTON
   =========================== */
.submit-review-btn {
  width: 100%;
  padding: 1rem 1.5rem;
  background: linear-gradient(135deg, var(--primary), #20c997);
  color: white;
  border: none;
  border-radius: var(--radius-lg);
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.submit-review-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* ===========================
   EDIT REVIEW BUTTON
   =========================== */
#edit-review-btn {
  width: 100%;
  padding: 0.875rem 1.5rem;
  background: linear-gradient(135deg, var(--blue), var(--secondary));
  color: white;
  border: none;
  border-radius: var(--radius-lg);
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

#edit-review-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* ===========================
   REVIEWS LIST
   =========================== */
.reviews-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.reviews-list:empty::before {
  content: 'No reviews yet. Be the first to leave a review!';
  display: block;
  text-align: center;
  padding: 3rem 1.5rem;
  color: var(--gray-500);
  font-size: 1rem;
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  border: 2px dashed var(--gray-300);
}

/* ===========================
   REVIEW ITEM
   =========================== */
.review-item {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  transition: var(--transition);
  animation: fadeInUp 0.4s ease backwards;
}

.review-item:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-light);
  transform: translateY(-2px);
}

/* Tablet */
@media (min-width: 768px) {
  .review-item {
    padding: 2rem;
  }
}

/* ===========================
   REVIEW HEADER
   =========================== */
.review-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--gray-100);
}

.review-avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 2px solid var(--gray-200);
  background: var(--gray-100);
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}

/* Tablet */
@media (min-width: 640px) {
  .review-avatar {
    width: 56px;
    height: 56px;
  }
}

/* ===========================
   REVIEW AUTHOR
   =========================== */
.review-author {
  flex: 1;
  min-width: 0;
}

.review-author h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--gray-900);
  margin: 0 0 0.25rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Tablet */
@media (min-width: 640px) {
  .review-author h4 {
    font-size: 1.0625rem;
  }
}

.review-date {
  font-size: 0.8125rem;
  color: var(--gray-500);
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

/* ===========================
   REVIEW RATING
   =========================== */
.review-rating {
  display: flex;
  gap: 0.25rem;
  color: #fbbf24;
  font-size: 1.125rem;
}

/* Tablet */
@media (min-width: 640px) {
  .review-rating {
    gap: 0.375rem;
    font-size: 1.25rem;
  }
}

/* ===========================
   REVIEW TEXT
   =========================== */
.review-text {
  color: var(--gray-700);
  font-size: 0.9375rem;
  line-height: 1.7;
  margin: 0;
  position: relative;
  padding-left: 1rem;
  border-left: 3px solid var(--primary-light);
}

/* Tablet */
@media (min-width: 768px) {
  .review-text {
    font-size: 1rem;
    padding-left: 1.25rem;
  }
}

/* ===========================
   EMPTY STATE FOR REVIEWS
   =========================== */
.reviews-empty {
  text-align: center;
  padding: 3rem 1.5rem;
  background: var(--gray-50);
  border-radius: var(--radius-xl);
  border: 2px dashed var(--gray-300);
}

.reviews-empty i {
  font-size: 3rem;
  color: var(--gray-400);
  margin-bottom: 1.5rem;
  display: block;
}

.reviews-empty h3 {
  font-size: 1.25rem;
  color: var(--gray-700);
  margin-bottom: 0.5rem;
}

.reviews-empty p {
  color: var(--gray-500);
  font-size: 0.9375rem;
  margin-bottom: 0;
}

/* Tablet */
@media (min-width: 768px) {
  .reviews-empty {
    padding: 4rem 2rem;
  }
  
  .reviews-empty i {
    font-size: 4rem;
  }
  
  .reviews-empty h3 {
    font-size: 1.5rem;
  }
}

/* ===========================
   DARK MODE SUPPORT
   =========================== */
@media (prefers-color-scheme: dark) {
  .reviews-container {
    background: #1a1a1a;
    border-color: #2d2d2d;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  }

  .review-form-container {
    background: linear-gradient(135deg, #252525 0%, #1a1a1a 100%);
    border-color: #2d2d2d;
  }

  .review-form-container:hover {
    border-color: #28a745;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.2);
  }

  .review-form-container::before {
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.1) 0%, rgba(40, 167, 69, 0.02) 100%);
  }

  .form-group label {
    color: #d4d4d4;
  }

  .form-group input,
  .form-group textarea,
  .form-group select {
    background: #252525;
    color: #d4d4d4;
    border-color: #2d2d2d;
  }

  .form-group input:focus,
  .form-group textarea:focus,
  .form-group select:focus {
    background: #2d2d2d;
    border-color: #28a745;
  }

  .form-group input::placeholder,
  .form-group textarea::placeholder {
    color: #999999;
  }

  .star-rating {
    color: #b3b3b3;
  }

  .star-rating .star.active {
    color: #f59e0b;
  }

  .star-rating .star:hover {
    color: #f59e0b;
  }

  .review-item {
    background: #252525;
    border-color: #2d2d2d;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  }

  .review-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  }

  .reviewer-info {
    color: #d4d4d4;
  }

  .reviewer-name {
    color: #d4d4d4;
  }

  .review-date {
    color: #999999;
  }

  .review-text {
    color: #b3b3b3;
  }

  .review-actions {
    border-top-color: #2d2d2d;
  }

  .review-action-btn {
    color: #b3b3b3;
  }

  .review-action-btn:hover {
    color: #28a745;
  }

  .reviews-header h2 {
    color: #d4d4d4;
  }

  .reviews-header-stats {
    background: #252525;
    border-color: #2d2d2d;
  }

  .reviews-header-stats span {
    color: #b3b3b3;
  }

  .reviews-header-stats strong {
    color: #d4d4d4;
  }

  .reviews-empty {
    background: transparent;
  }

  .reviews-empty i {
    color: #b3b3b3;
  }

  .reviews-empty h3 {
    color: #d4d4d4;
  }

  .reviews-empty p {
    color: #999999;
  }
}