:root {
  --bg: #f5f7fb;
  --panel: #ffffff;
  --ink: #172033;
  --muted: #647084;
  --brand: #2454d6;
  --brand-dark: #183a9f;
  --line: #dce2ee;
  --soft: #edf2ff;
  --shadow: 0 20px 50px rgba(23, 32, 51, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

a {
  color: var(--brand);
  font-weight: 700;
  text-decoration: none;
}

a:hover {
  color: var(--brand-dark);
  text-decoration: underline;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0;
}

.brand {
  color: var(--ink);
  font-size: 1.12rem;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.nav-links a {
  border-radius: 999px;
  color: var(--muted);
  padding: 8px 14px;
}

.nav-links a:hover {
  background: var(--soft);
  color: var(--brand);
  text-decoration: none;
}

main {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.section {
  scroll-margin-top: 92px;
  padding: 72px 0;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 36px;
  align-items: center;
  min-height: 620px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--brand);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

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

h1 {
  max-width: 720px;
  margin-bottom: 18px;
  font-size: clamp(3rem, 8vw, 5.75rem);
  letter-spacing: -0.07em;
  line-height: 0.95;
}

h2 {
  margin-bottom: 10px;
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.04em;
}

h3 {
  margin-bottom: 12px;
  font-size: 1.15rem;
}

.intro,
.section-heading p {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.05rem;
}

.question-card,
.info-card,
.table-wrap {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.question-card {
  display: grid;
  gap: 14px;
  padding: 28px;
}

label {
  font-weight: 800;
}

textarea,
input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--ink);
  font: inherit;
  padding: 14px 16px;
}

textarea {
  min-height: 180px;
  resize: vertical;
}

textarea:focus,
input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(36, 84, 214, 0.14);
  outline: none;
}

button {
  border: 0;
  border-radius: 999px;
  background: var(--brand);
  color: #ffffff;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  padding: 14px 20px;
}

button:hover {
  background: var(--brand-dark);
}

.section-heading {
  margin-bottom: 24px;
}

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

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

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 18px;
  text-align: left;
  vertical-align: top;
}

th {
  background: #f8faff;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

tr:last-child td {
  border-bottom: 0;
}

.empty-state {
  color: var(--muted);
  text-align: center;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.info-card {
  padding: 24px;
}

.info-card p:last-child {
  margin-bottom: 0;
}

.variable-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.variable-list p {
  margin-bottom: 0;
}

.variable-field {
  display: grid;
  gap: 8px;
  color: var(--muted);
}

.formula-result {
  border-radius: 16px;
  background: var(--soft);
  color: var(--brand-dark);
  padding: 14px 16px;
}

@media (max-width: 780px) {
  .navbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .nav-links {
    justify-content: flex-start;
  }

  .section {
    padding: 48px 0;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .question-card,
  .info-card {
    border-radius: 22px;
    padding: 22px;
  }
}
