/* ============================================
   FlexPRO Photo Upload Styles v1.0
   ============================================ */

/* ── Upload Zone ── */
.photo-upload-zone {
  position: relative;
  border: 2px dashed var(--gray-300, #D1D5DB);
  border-radius: var(--radius-lg, 0.75rem);
  padding: 2rem 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.25s ease;
  background: var(--gray-100, #F3F4F6);
  margin-bottom: 1rem;
}

.photo-upload-zone:hover {
  border-color: var(--primary, #0066FF);
  background: var(--primary-light, #E6F0FF);
}

.photo-upload-zone--dragover {
  border-color: var(--primary, #0066FF);
  background: var(--primary-light, #E6F0FF);
  transform: scale(1.01);
}

.photo-upload-zone__icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 0.75rem;
  color: var(--gray-400, #9CA3AF);
  display: block;
}

.photo-upload-zone:hover .photo-upload-zone__icon {
  color: var(--primary, #0066FF);
}

.photo-upload-zone__text {
  font-size: 1rem;
  font-weight: 600;
  color: var(--gray-700, #4B5563);
  margin-bottom: 0.25rem;
}

.photo-upload-zone__subtext {
  font-size: 0.8rem;
  color: var(--gray-500, #6B7280);
}

/* ── Buttons ── */
.photo-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: var(--radius-md, 0.5rem);
  border: 1px solid var(--gray-300, #D1D5DB);
  background: var(--white, #FFF);
  color: var(--gray-700, #4B5563);
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.photo-btn:hover {
  background: var(--primary-light, #E6F0FF);
  border-color: var(--primary, #0066FF);
  color: var(--primary, #0066FF);
}

.photo-btn--camera {
  background: var(--primary, #0066FF);
  color: var(--white, #FFF);
  border-color: var(--primary, #0066FF);
}

.photo-btn--camera:hover {
  background: var(--primary-dark, #0052CC);
  color: var(--white, #FFF);
}

/* ── Progress Bar ── */
.photo-upload-zone__progress {
  margin-top: 1rem;
}

.photo-progress-bar {
  width: 100%;
  height: 6px;
  background: var(--gray-200, #E5E7EB);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.photo-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary, #0066FF), var(--secondary, #00D4AA));
  border-radius: 3px;
  transition: width 0.3s ease;
}

.photo-progress-text {
  font-size: 0.8rem;
  color: var(--gray-500, #6B7280);
  margin: 0;
}

/* ── Preview Grid ── */
.photo-previews {
  display: none;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.photo-preview-card {
  position: relative;
  border: 1px solid var(--gray-200, #E5E7EB);
  border-radius: var(--radius-md, 0.5rem);
  overflow: hidden;
  background: var(--white, #FFF);
  box-shadow: var(--shadow-sm, 0 1px 2px rgba(0,0,0,0.05));
  transition: box-shadow 0.2s ease;
}

.photo-preview-card:hover {
  box-shadow: var(--shadow-md, 0 4px 6px rgba(0,0,0,0.1));
}

.photo-preview-card__img {
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--gray-100, #F3F4F6);
}

.photo-preview-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-preview-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.photo-preview-card__info {
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.photo-preview-card__name {
  font-size: 0.75rem;
  color: var(--gray-700, #4B5563);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.photo-preview-card__check {
  font-size: 0.7rem;
  color: var(--success, #10B981);
  font-weight: 600;
}

.photo-preview-card__remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  color: #FFF;
  border: none;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
  padding: 0;
}

.photo-preview-card__remove:hover {
  background: var(--error, #EF4444);
}

/* ── Notifications ── */
.photo-notification {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md, 0.5rem);
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
  transition: opacity 0.3s ease;
}

.photo-notification--error {
  background: #FEF2F2;
  color: #DC2626;
  border: 1px solid #FECACA;
}

.photo-notification--success {
  background: #F0FDF4;
  color: #16A34A;
  border: 1px solid #BBF7D0;
}

/* ── Mobile Responsive ── */
@media (max-width: 480px) {
  .photo-upload-zone {
    padding: 1.5rem 1rem;
  }

  .photo-upload-zone__icon {
    width: 36px;
    height: 36px;
  }

  .photo-upload-zone__text {
    font-size: 0.9rem;
  }

  .photo-upload-zone__buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .photo-btn {
    justify-content: center;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
  }

  .photo-previews {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 0.5rem;
  }

  .photo-preview-card__info {
    padding: 0.35rem;
  }

  .photo-preview-card__name {
    font-size: 0.65rem;
  }
}
