/* ======= COLOR THEME FOR EMI CALCULATOR ======= */

/* Root palette */
:root {
  --bg: #f4f9f6;          /* soft off-white background */
  --card: #ffffff;        /* white cards */
  --border: #d1d5db;      /* subtle gray border */
  --text: #1f2937;        /* gray-900 text */
  --muted: #6b7280;       /* muted gray for labels */
  --primary: #2563eb;     /* blue-600 for buttons/links */
  --primary-hover: #1e40af; /* blue-800 hover */
  --accent: #16a34a;      /* green-600 highlights */
  --accent-light: #dcfce7;/* green-100 (row stripe) */
  --danger: #dc2626;      /* red-600 (for border/error) */
  --shadow: 0 6px 20px rgba(0,0,0,.1);
}

/* Base */
body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
}

.wrap {
  max-width: 1100px;
  margin: 32px auto;
  padding: 0 16px;
}

/* Header */
header {
  text-align: center;
  margin-bottom: 24px;
}
h1 {
  margin: 0;
  font-size: 1.8rem;
  color: var(--primary);
}
.sub {
  color: var(--muted);
}

/* Card */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin: 16px 0;
  box-shadow: var(--shadow);
}

/* Form fields */
.field span {
  font-size: 0.9rem;
  color: var(--muted);
}
.field input, .field select {
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f9fafb;
  color: var(--text);
}
.field input:focus, .field select:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(37,99,235,0.2);
}

/* Buttons */
.btn {
  padding: 10px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-weight: 600;
  color: #fff;
  background: var(--primary);
  transition: background 0.2s ease;
}
.btn:hover {
  background: var(--primary-hover);
}
.btn.ghost {
  background: #e5e7eb;
  color: var(--text);
}
.btn.ghost:hover {
  background: #d1d5db;
}

/* Summary */
.summary-grid .k {
  font-size: 0.8rem;
  color: var(--muted);
}
.summary-grid .v {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--accent);
}

/* Table */
.table-wrap {
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 10px;
}

#scheduleTable {
  width: 100%;
  border-collapse: collapse;
}

#scheduleTable thead th {
  background: var(--primary);
  color: #fff;
  text-align: right;
  padding: 10px;
  font-weight: 600;
}
#scheduleTable thead th:first-child {
  text-align: center;
}

#scheduleTable tbody td {
  padding: 10px;
  text-align: right;
  border-bottom: 1px solid var(--border);
}
#scheduleTable tbody tr:nth-child(odd) {
  background: #fff;
}
#scheduleTable tbody tr:nth-child(even) {
  background: var(--accent-light);
}
#scheduleTable tbody td:first-child {
  text-align: center;
}

/* Footer */
footer {
  text-align: center;
  margin-top: 20px;
  color: var(--muted);
}
