/* === Reset & Global === */
body {
    margin: 0;
    font-family: 'Segoe UI', sans-serif;
    background-color: #f7f9fc;
    color: #333;
}

h1, h2, h3 {
    margin-top: 0;
}

/* === Sidebar === */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 230px;
    height: 100vh;
    background-color: #1e293b;
    color: white;
    padding: 20px;
    box-sizing: border-box;
}

.sidebar h2 {
    margin-bottom: 40px;
    font-size: 22px;
}

.sidebar span {
    color: #38bdf8;
}

.sidebar a {
    display: block;
    margin-bottom: 15px;
    text-decoration: none;
    color: #cbd5e1;
    font-size: 16px;
    padding: 8px 12px;
    border-radius: 8px;
    transition: background 0.3s, color 0.3s;
}

.sidebar a:hover,
.sidebar a.active {
    background-color: #334155;
    color: hsl(0, 0%, 100%);
}

/* === Main Content === */
.main {
    margin-left: 250px;
    padding: 30px;
}

/* === Form Input === */
form textarea {
    width: 100%;
    max-width: 700px;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 15px;
    resize: vertical;
    margin-bottom: 10px;
}

form button {
    padding: 10px 20px;
    background-color: #0ea5e9;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.3s;
}

form button:hover {
    background-color: #0284c7;
}

/* === Cards & Info Boxes === */
.card {
    background-color: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.summary-cards {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.summary-cards .card {
    flex: 1;
    min-width: 200px;
    background-color: white;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.summary-cards .card h2 {
    margin: 0;
    font-size: 32px;
    font-weight: bold;
    color: #1f2937;
}

.summary-cards .card p {
    margin: 8px 0 0;
    color: #6b7280;
    font-size: 15px;
}

/* === Table === */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table thead {
    background-color: #e2e8f0;
}

table th, table td {
    padding: 12px;
    border: 1px solid #cbd5e1;
    text-align: left;
}

table tbody tr:hover {
    background-color: #f1f5f9;
}

.text-center {
    text-align: center;
    color: #888;
}

/* === Dropdown button === */
.dropdown {
  position: relative;
  display: inline-block;
}

.download-btn {
  padding: 6px 14px;
  background: #33ccff;
  color: white;
  font-size: 14px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.download-btn:hover {
  background: #1aa3cc;
}

.dropdown-content {
  display: none;
  position: absolute;
  background: #fff;
  min-width: 120px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  border-radius: 6px;
  margin-top: 6px;
  z-index: 1;
}

.dropdown-content a {
  display: block;
  padding: 8px 12px;
  font-size: 14px;
  color: #333;
  text-decoration: none;
  transition: background 0.2s ease;
}

.dropdown-content a:hover {
  background: #f1f1f1;
}

.dropdown.show .dropdown-content {
  display: block;
}

/* === Chart Container === */
canvas {
    margin-top: 30px;
    max-width: 100%;
    display: block;
}

.chart-container {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    margin: 20px 0;
    min-height: 300px;
}

/* === Responsive Layout === */
@media (max-width: 768px) {
    .sidebar {
        position: static;
        width: 100%;
        height: auto;
    }

    .main {
        margin-left: 0;
        padding: 20px;
    }

    .summary-cards {
        flex-direction: column;
    }
}

/* === Animasi Blink Saat Submit === */
@keyframes blinkHighlight {
    0%   { background-color: #fff8c4; } /* Kuning pucat */
    50%  { background-color: #fff; }
    100% { background-color: #fff8c4; }
}

.blink-highlight {
    animation: blinkHighlight 1s ease-in-out;
}

#notif {
  position: fixed;
  top: 20px;
  right: 20px;
  background: red;
  color: white;
  padding: 12px 18px;
  border-radius: 6px;
  font-weight: bold;
  display: none;
  z-index: 9999;
}
