/* ===========================
   🔹 CLASSIFIER SECTION
=========================== */
.classifier-section h2 {
  text-align: center;
}

.plot-container {
  text-align: center;
  margin: 30px auto;
  max-width: 1000px;
  width: 100%;
}

.charts {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
}

.chart-box {
  flex: 1 1 45%;
  background: rgba(255, 255, 255, 0.1);
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  text-align: center;
}

.chart-box img {
  width: 100%;
  max-height: 250px;
  object-fit: contain;
  border-radius: 6px;
}

/* ===========================
   🔹 UPLOAD FORM
=========================== */
.upload-section {
  display: flex;
  justify-content: center;
  margin-top: 40px;
  width: 100%;
}

.card {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  padding: 25px 0;
  text-align: center;
  max-width: 400px;
  width: 100%;
  transition: transform 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
}

.upload-form {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.upload-form input[type="file"] {
  margin: 10px 0;
  padding: 12px;
  border: 2px dashed var(--cyan);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
  width: 100%;
  max-width: 280px;
  color: var(--text-light);
}

.upload-form button {
  margin-top: 15px;
  padding: 12px 25px;
  border: none;
  border-radius: 25px;
  background: var(--cyan);
  color: black;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
}

.upload-form button:hover {
  background: #00a3cc;
}

.prediction {
  margin-top: 20px;
  font-size: 20px;
  font-weight: bold;
  color: var(--cyan);
}

.preview {
  margin-top: 15px;
  width: fit-content;
  /* container adjusts to image width */
  max-width: 100%;
  /* prevents overflow on small screens */
  border-radius: 10px;
  overflow: hidden;
  /* keeps image corners rounded */
  margin-left: auto;
  /* center it */
  margin-right: auto;
}

.preview img {
  width: auto;
  max-width: 200px;
  /* limit width */
  max-height: 200px;
  /* limit height */
  object-fit: cover;
  /* crop nicely instead of stretching */
  border-radius: 10px;
  display: block;
  margin: 0 auto;
}

.card h3 {
  display: flex;
  /* Enables flexbox */
  justify-content: center;
  /* Forces content to center horizontally */
  align-items: center;
  /* Vertically aligns icon with text */
  gap: 10px;
  /* Adds space between the camera icon and text */
  width: 100%;
  /* Ensures it takes full width */
}

/* ===========================
   🔹 RESPONSIVE DESIGN
=========================== */
@media (max-width: 768px) {
  .charts {
    flex-direction: column;
    align-items: center;
  }

  .chart-box {
    flex: 1 1 100%;
    max-width: 90%;
  }

  header h1 {
    font-size: 1.4rem;
  }

  .projects {
    grid-template-columns: 1fr;
  }

  .card h3 {
    text-align: center !important;
    /* Overrides global 'justify' */
    justify-content: center !important;
    /* Ensures flex centering stays */
  }
}