@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&display=swap');

:root {
  --ink: #0f1f3d;
  --ink-soft: #54627a;
  --accent: #2a7bff;
  --accent-dark: #1c5edb;
  --surface: #ffffff;
  --surface-strong: #f5f8ff;
  --outline: rgba(15, 31, 61, 0.12);
  --shadow: 0 12px 30px rgba(26, 65, 143, 0.12);
  --radius-lg: 20px;
  --radius-md: 16px;
  --mono: "SFMono-Regular", "JetBrains Mono", "Courier New", monospace;
  --display: "Manrope", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --body: "Manrope", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

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

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--body);
  color: var(--ink);
  background: radial-gradient(circle at 18% 24%, rgba(42, 123, 255, 0.12), transparent 34%),
    radial-gradient(circle at 78% 14%, rgba(253, 187, 45, 0.08), transparent 30%),
    #f5f8ff;
}

.atmosphere {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, rgba(42, 123, 255, 0.18), transparent 32%),
    radial-gradient(circle at 80% 20%, rgba(253, 187, 45, 0.14), transparent 30%),
    linear-gradient(135deg, rgba(42, 123, 255, 0.06), rgba(255, 255, 255, 0));
  filter: blur(8px);
  z-index: 0;
  pointer-events: none;
}

header {
  padding: 24px 0;
}

.shell {
  width: min(1200px, 92vw);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--outline);
  border-radius: 16px;
  padding: 12px 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.brand {
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: 18px;
  color: var(--ink);
}

.nav-links {
  display: flex;
  gap: 14px;
  align-items: center;
}

.nav a {
  color: var(--ink-soft);
  padding: 10px 12px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav a:hover {
  color: var(--ink);
  background: rgba(42, 123, 255, 0.08);
  text-decoration: none;
}

.page {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px 0 80px;
}

.hero {
  margin-bottom: 28px;
  animation: rise 0.8s ease-out both;
}

.eyebrow {
  letter-spacing: 0.12em;
  font-size: 12px;
  color: var(--ink-soft);
  margin: 0 0 12px;
}

h1 {
  margin: 0 0 12px;
  font-family: var(--display);
  font-size: clamp(32px, 4vw, 52px);
}

.lead {
  margin: 0;
  color: var(--ink-soft);
  max-width: 720px;
  font-size: 18px;
}

.panel {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow);
  border: 1px solid var(--outline);
  backdrop-filter: blur(10px);
  animation: rise 0.7s ease-out both;
}

.form-panel {
  animation-delay: 0.1s;
}

.summary-panel {
  margin-top: 24px;
  padding: 20px 28px;
  animation-delay: 0.15s;
}

.table-panel {
  margin-top: 28px;
  animation-delay: 0.2s;
}

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

label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
  color: var(--ink-soft);
}

.hint {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--ink-soft);
}

input,
select {
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--outline);
  font-size: 15px;
  font-family: var(--mono);
  background: var(--surface-strong);
}

input:focus,
select:focus {
  outline: 2px solid rgba(42, 123, 255, 0.28);
  border-color: rgba(42, 123, 255, 0.6);
}

.actions {
  display: flex;
  gap: 16px;
  margin-top: 20px;
  align-items: center;
  flex-wrap: wrap;
}

button {
  background: var(--accent);
  border: none;
  color: #fff;
  padding: 12px 22px;
  border-radius: 999px;
  font-size: 15px;
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 12px 24px rgba(30, 94, 219, 0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(30, 94, 219, 0.3);
}

button:disabled {
  cursor: progress;
  opacity: 0.7;
  transform: none;
  box-shadow: none;
}

.ghost {
  padding: 10px 20px;
  border-radius: 999px;
  border: 1px solid var(--accent);
  color: var(--accent-dark);
  text-decoration: none;
  font-weight: 600;
}

.status {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--ink-soft);
}

.alert {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 14px;
}

.error {
  background: #ffe4df;
  color: #7a1f12;
}

.summary {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.summary-label {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}

.summary-value {
  margin: 6px 0 0;
  font-family: var(--display);
  font-size: 26px;
}

.table-header h2 {
  margin: 0 0 6px;
  font-family: var(--display);
}

.table-header p {
  margin: 0;
  color: var(--ink-soft);
}

.table-wrap {
  margin-top: 18px;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th,
td {
  text-align: left;
  padding: 12px 10px;
  border-bottom: 1px solid var(--outline);
}

th {
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}

td.value {
  font-family: var(--mono);
  color: var(--accent-dark);
}

td.error-cell {
  color: #8c4b3c;
  font-size: 12px;
}

a {
  color: var(--accent-dark);
  text-decoration: none;
  font-weight: 600;
}

a:hover {
  text-decoration: underline;
}

.is-hidden {
  display: none;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(14px);
  }
}

@media (max-width: 720px) {
  .page {
    padding: 32px 18px 60px;
  }

  .panel {
    padding: 20px;
  }

  .actions {
    flex-direction: column;
    align-items: stretch;
  }

  button,
  .ghost {
    width: 100%;
    text-align: center;
  }
}
