*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: system-ui, sans-serif;
  background: #0f0f1a;
  color: #e0e0e8;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header */
header {
  background: #1a1a2e;
  border-bottom: 2px solid #c9a227;
  padding: 0 1.5rem;
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}
header h1 { font-size: 1.4rem; color: #c9a227; }
nav a {
  color: #b0b0c0;
  text-decoration: none;
  margin-left: 1.5rem;
  font-size: 0.95rem;
}
nav a:hover { color: #c9a227; }

/* Layout */
.layout {
  display: flex;
  flex: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem;
  gap: 2rem;
}

/* Sidebar */
.sidebar {
  width: 200px;
  flex-shrink: 0;
}
.sidebar h2 { font-size: 0.85rem; text-transform: uppercase; color: #888; margin-bottom: 0.75rem; }
.sidebar ul { list-style: none; }
.sidebar li { margin-bottom: 0.4rem; }
.sidebar ul ul { margin-left: 1rem; margin-top: 0.3rem; }
.sidebar a { color: #a0a0c0; text-decoration: none; font-size: 0.9rem; }
.sidebar a:hover { color: #c9a227; }

/* Main content */
main { flex: 1; }
section { margin-bottom: 3rem; }
section h2 {
  font-size: 1.5rem;
  color: #c9a227;
  border-bottom: 1px solid #333;
  padding-bottom: 0.4rem;
  margin-bottom: 1rem;
}
section p { line-height: 1.7; color: #b0b0c0; }

/* Calculator */
.calc-box {
  background: #1a1a2e;
  border: 1px solid #333;
  border-radius: 8px;
  padding: 1.25rem;
  max-width: 420px;
}
.calc-box h3 { font-size: 1rem; color: #ddd; margin-bottom: 1rem; }
.calc-fields { display: flex; flex-direction: column; gap: 0.6rem; margin-bottom: 1rem; }
.calc-fields label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  color: #b0b0c0;
}
.calc-fields input[type="number"] {
  background: #0f0f1a;
  border: 1px solid #444;
  border-radius: 4px;
  color: #e0e0e8;
  padding: 0.3rem 0.5rem;
  width: 100px;
  font-size: 0.9rem;
}
button {
  background: #c9a227;
  color: #0f0f1a;
  border: none;
  border-radius: 4px;
  padding: 0.5rem 1.2rem;
  font-weight: 700;
  cursor: pointer;
  font-size: 0.9rem;
}
button:hover { background: #e0b840; }
.calc-result {
  margin-top: 0.8rem;
  font-size: 1rem;
  color: #c9a227;
  min-height: 1.5rem;
}

/* Footer */
footer {
  text-align: center;
  padding: 1rem;
  background: #1a1a2e;
  color: #555;
  font-size: 0.8rem;
  border-top: 1px solid #222;
}

@media (max-width: 700px) {
  .layout { flex-direction: column; }
  .sidebar { width: 100%; }
  nav a { margin-left: 0.75rem; }
}
