/* File: market-analysis.css */

.market-analysis-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  font-family: 'Segoe UI', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: #333;
}

.section-title {
  font-size: 32px;
  font-weight: 600;
  margin-bottom: 30px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.kpi-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .kpi-cards {
    flex-direction: column;
  }
}

.kpi-card {
  flex: 1 1 200px;
  background: #ffffff;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  text-align: center;
  border-top: 4px solid #2e86de;
  transition: transform 0.2s ease;
}

.kpi-card:hover {
  transform: translateY(-5px);
}

.kpi-card.total {
  background: #e7f9f0;
  border-top: 4px solid #28a745;
}

.kpi-card p {
  font-size: 14px;
  color: #777;
  margin-bottom: 8px;
}

.kpi-card h2 {
  font-size: 24px;
  margin: 0;
  color: #222;
}

.charts-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .charts-row {
    flex-direction: column;
  }
}

.chart-card {
  flex: 1 1 500px;
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.chart-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 15px;
  color: #333;
}

.location-table {
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  margin-bottom: 40px;
  overflow-x: auto;
}

.location-table h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.location-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 400px;
}

.location-table th,
.location-table td {
  padding: 12px 10px;
  border-bottom: 1px solid #eee;
  text-align: left;
}

.location-table th {
  font-weight: 600;
  background-color: #f7f9fc;
  color: #333;
}

@media (max-width: 600px) {
  .location-table table {
    font-size: 13px;
  }
}


/* FROM HERE IT WOULD BE FOR OFFPLAN */





/* Container */
.market-container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 20px;
}

/* Title */
.market-title {
  text-align: center;
  font-size: 28px;
  margin-bottom: 30px;
  font-weight: 600;
}

/* Summary KPI Cards */
.kpi-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.kpi-card {
  background: #f9f9f9;
  padding: 20px;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.kpi-card h3 {
  margin-bottom: 10px;
  font-size: 16px;
  color: #333;
}

.kpi-card p {
  font-size: 18px;
  font-weight: bold;
  color: #111;
}

/* Charts Grid Layout */
.chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
  gap: 30px;
}

/* Individual Chart Box */
.chart-box {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.chart-box h2 {
  font-size: 18px;
  margin-bottom: 15px;
  text-align: center;
  color: #222;
}

/* Chart Canvas */
.chart-box canvas {
  width: 100% !important;
  max-height: 300px;
}

/* Download PNG Button */
.download-btn {
  margin-top: 15px;
  padding: 8px 16px;
  background: #eef1f6;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: background 0.3s ease;
}

.download-btn:hover {
  background: #dde3eb;
}

/* Full width chart (optional) */
.full-width {
  grid-column: span 2;
}

/* Responsive Behavior */
@media (max-width: 768px) {
  .chart-grid {
    grid-template-columns: 1fr;
  }

  .full-width {
    grid-column: span 1;
  }
}
