* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f7f7f8;
  color: #1f2937;
  padding: 20px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 8px;
}

h1 {
  margin: 0 0 8px;
  font-size: 30px;
}

.subtitle {
  margin: 0 0 10px;
  color: #6b7280;
}

.menu-wrap {
  position: relative;
}

.menu-btn {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #ffffff;
  color: #111827;
  border: 1px solid #d1d5db;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.menu-dropdown {
  position: absolute;
  top: 50px;
  right: 0;
  min-width: 220px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  z-index: 20;
}

.menu-dropdown a {
  display: block;
  padding: 12px 14px;
  color: #111827;
  text-decoration: none;
  border-bottom: 1px solid #f1f5f9;
}

.menu-dropdown a:last-child {
  border-bottom: none;
}

.menu-dropdown a:hover {
  background: #f9fafb;
}

.card {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 16px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  color: #4b5563;
}

input,
select,
button {
  width: 100%;
  padding: 11px 12px;
  border-radius: 10px;
  border: 1px solid #d1d5db;
  font-size: 14px;
}

input,
select {
  background: #ffffff;
  color: #111827;
}

button {
  background: #111827;
  color: white;
  border: none;
  cursor: pointer;
  font-weight: 600;
}

button:hover {
  opacity: 0.92;
}

.button-wrap {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.quick-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.quick-btn {
  width: auto;
  padding: 9px 14px;
  background: #f3f4f6;
  color: #111827;
  border: 1px solid #d1d5db;
}

.status {
  margin-top: 14px;
  min-height: 20px;
  color: #2563eb;
}

.summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.stat {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 14px;
}

.stat-key {
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 8px;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
}

.good {
  color: #16a34a;
  font-weight: 700;
}

.moderate {
  color: #d97706;
  font-weight: 700;
}

.poor {
  color: #dc2626;
  font-weight: 700;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 1000px;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 12px 10px;
  border-bottom: 1px solid #e5e7eb;
  font-size: 14px;
}

th {
  background: #f9fafb;
  color: #374151;
}

.hidden {
  display: none;
}

@media (max-width: 700px) {
  body {
    padding: 12px;
  }

  h1 {
    font-size: 24px;
  }

  .topbar {
    align-items: center;
  }
}
.dam-map {
  width: 100%;
  height: 520px;
  border-radius: 14px;
  overflow: hidden;
}

.section-title {
  margin: 0 0 14px;
  font-size: 20px;
}

.selected-dam-card {
  min-height: 120px;
}

.selected-dam-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.empty-card {
  color: #6b7280;
}

.back-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}