:root {
  --bg: #fff;
  --text: #222;
  --accent: #017ba3;
  --nav-bg: #f4f4f4;
}

[data-theme="dark"] {
  --bg: #121212;
  --text: #eee;
  --accent: #1e90ff;
  --nav-bg: #1f1f1f;
}

.filter-group {
  margin-bottom: 20px;
  font-family: Arial, sans-serif;
}

.filter-label {
  font-weight: bold;
  margin-bottom: 8px;
  font-size: 16px;
}

body {
  margin: 0;
  font-family: sans-serif;
  background: var(--bg);
  color: var(--text);
  transition: background 0.3s, color 0.3s;
}
ul li{line-height:30px}ul li{padding-bottom:8px;font-size:14px}
header {
  background: var(--nav-bg);
  padding: 1rem;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}

.logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--accent);
  flex: 0 0 auto; 
}

nav {
  display: flex;
  gap: 1rem;
  flex-grow: 1; 
  justify-content: center; 
  order: 2;
}

nav a {
  text-decoration: none;
  color: var(--text);
  padding: 0.5rem 1rem;
}

nav a:hover {
  background: var(--accent);
  color: white;
  border-radius: 5px;
}

.menu-toggle {
  font-size: 1.8rem;
  cursor: pointer;
  background: none;
  border: none;
  color: var(--accent);
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 10;
  order: 3;
}

p {
  line-height: 1.6;
}

@media (max-width: 768px) {
  nav {
    flex-direction: column;
    display: none;
    width: 100%;
    margin-top: 3rem;
    padding: 1rem;
    order: 3;
  }

  nav.show {
    display: flex;
    background: var(--nav-bg);
    border-top: 1px solid #ccc;
  }

  .menu-toggle {
    position: absolute;
    top: 1rem;
    right: 1rem;
  }

  .logo {
    order: 1;
  }
}

main {
  padding: 2rem;
  max-width: 1100px;
  margin: auto;
}

label {
  display: block;
  margin-top: 1rem;
}

input, select {
  width: 100%;
  padding: 5px;
}

button[type="submit"] {
  margin-top: 1.5rem;
  background: var(--accent);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 5px;
  cursor: pointer;
}

.result {
  margin-top: 1rem;
  background: #e9ffe9;
  padding: 1rem;
  border: 1px solid #8cd98c;
}

        form { margin-bottom: 20px; }
        table { border-collapse: collapse; width: 100%; font-size: 0.95em; }
        th, td { border: 1px solid #ccc; padding: 6px; text-align: right; }
        th { background-color: #f9f9f9; }
        input[type="number"] { width: 100px; }
        label { display: inline-block; width: 220px; margin-bottom: 10px; }
        .error { color: red; margin-top: 10px; }
        .summary { margin-top: 20px; font-weight: bold; }
        .note { font-size: 0.9em; color: #555; margin-bottom: 10px; }
        .draw-period-row { background-color: #e0f7fa; } /* Highlight draw period rows */
        .repayment-period-row { background-color: #fff3e0; } /* Highlight repayment period rows */

footer {
  padding: 1.5rem 1rem;
  text-align: center;
}

.footer-content {
  max-width: 800px;
  margin: 0 auto;
}

.footer-links {
  margin-top: 0.5rem;
}

.footer-links a {
  margin: 0 1rem;
  text-decoration: none;
  color: black;
  font-weight: 500;
}

[data-theme="dark"] .footer-links a {
  color: #eee;
}

.footer-links a:hover {
  text-decoration: underline;
}

.side {
  padding-left: 3px;
}

.side ul {
  list-style-type: none;
  padding: 0;
}

.side ul li {
  font-size: 15px;
  line-height: 35px;
}
.tabs {
  display: flex;
  cursor: pointer;
  border-bottom: 2px solid #ddd;
}
.tab {
  padding: 10px 20px;
  margin-right: 10px;
  color: #fff;
  border: 1px solid #ccc;
  border-radius: 5px 5px 0 0;
  transition: background-color 0.3s;
  text-decoration: none;
  background-color: #ff7f00;
}
a.tab:hover,
a.tab:visited {
  text-decoration: none;
  color: #ffffff;
}
@media (max-width: 600px) {
  main {
    padding: 0.1rem;
  }
}
.red{color:#e50303;}
.green{color:#029409;}
.box{background-color:#f9f9f9;border:2px solid #0074d9;border-radius:0px;max-width:700px;text-align:center;}.box p{font-size:16px;color:#333;}.box a{color:#0074d9;text-decoration:underline;font-weight:700}
.trans-button,.trans-button:hover{display:block;background:#4e9caf;padding:12px 0;text-align:center;border-radius:5px;color:#fff;font-weight:700;text-decoration:none;font-size:15px;width:300px}
.long{width:300px;}