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

:root {
  --ink: #16243e;
  --ink-soft: #4d5e84;
  --blue-1: #0f5bff;
  --blue-2: #1549d4;
  --blue-3: #0b39a8;
  --head-blue-1: #1a46cd;
  --head-blue-2: #1539ad;
  --head-pink-1: #ff1499;
  --head-pink-2: #ff4bb8;
  --pink: #ff0fa2;
  --line: #c8d4ec;
  --line-soft: #d5e0f4;
  --surface: #f6f9ff;
  --surface-2: #edf4ff;
  --ok: #0b753d;
  --error: #af2a3f;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 5% 0%, #dce8ff 0%, transparent 40%),
    radial-gradient(circle at 95% 100%, #ffeeda 0%, transparent 38%),
    #ecf2ff;
}

.page {
  width: min(1360px, calc(100% - 28px));
  margin: 14px auto 24px;
  display: grid;
  gap: 16px;
}

.hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(340px, 1fr) minmax(280px, 0.9fr);
  align-items: center;
  gap: 24px;
  border-radius: 28px;
  padding: 36px 38px;
  background: linear-gradient(130deg, var(--blue-1) 0%, var(--blue-2) 46%, var(--blue-3) 100%);
  box-shadow: 0 24px 46px rgba(16, 47, 131, 0.33);
}

.hero::before {
  content: "";
  position: absolute;
  inset: auto auto -120px -60px;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0) 70%);
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.hero-kicker {
  margin: 0 0 10px;
  color: rgba(233, 242, 255, 0.9);
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hero h1 {
  margin: 0;
  max-width: 12.5ch;
  color: #f5f9ff;
  font-size: clamp(2rem, 4.4vw, 4.3rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.hero-subtitle {
  margin: 16px 0 0;
  max-width: 620px;
  color: #dce7ff;
  font-size: 1.08rem;
  line-height: 1.45;
}

.hero-actions {
  margin-top: 24px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 208px;
  padding: 13px 20px;
  border-radius: 16px;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 800;
  transition: transform 0.16s ease, filter 0.16s ease, background-color 0.16s ease;
}

.hero-btn-primary {
  background: linear-gradient(120deg, #ff0fa2, #de007f);
  color: #ffffff;
}

.hero-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.04);
}

.hero-art {
  position: relative;
  min-height: 280px;
}

.hero-shape {
  position: absolute;
  display: block;
  border-radius: 999px;
  transform: rotate(-22deg);
}

.hero-shape.shape-a {
  width: 280px;
  height: 74px;
  top: 16px;
  left: 36px;
  background: rgba(255, 255, 255, 0.9);
}

.hero-shape.shape-b {
  width: 380px;
  height: 92px;
  top: 118px;
  right: -22px;
  background: rgba(255, 255, 255, 0.88);
}

.hero-shape.shape-c {
  width: 350px;
  height: 108px;
  top: 186px;
  right: 36px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.74) 0%, rgba(255, 255, 255, 0) 100%);
}

.hero-dot {
  position: absolute;
  width: 76px;
  height: 76px;
  right: 34px;
  bottom: 26px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #9ff7ff 0%, #5ac8ff 45%, #1f74ff 100%);
  box-shadow: 0 12px 28px rgba(17, 46, 122, 0.45);
}

.surface {
  border: 1px solid #c9d6ee;
  border-radius: 24px;
  padding: 24px;
  background: linear-gradient(180deg, #fbfdff 0%, var(--surface) 100%);
  box-shadow:
    0 14px 34px rgba(23, 40, 78, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.headline h2 {
  margin: 0 0 8px;
  font-size: 2rem;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.headline p {
  margin: 0;
  max-width: 860px;
  color: var(--ink-soft);
  font-size: 1.05rem;
  line-height: 1.45;
}

.controls {
  margin-top: 20px;
}

.controls label {
  display: block;
  margin-bottom: 10px;
  font-size: 1rem;
  font-weight: 700;
}

.controls-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.controls input {
  width: min(440px, 100%);
  padding: 12px 14px;
  border: 1px solid #a8b8da;
  border-radius: 14px;
  background: #fcfeff;
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  font-weight: 800;
}

.controls input::placeholder {
  color: #8a98b6;
}

.controls input:focus {
  outline: 2px solid color-mix(in srgb, #3d6ec8 45%, white);
  outline-offset: 2px;
}

.controls button {
  min-width: 170px;
  padding: 12px 20px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(120deg, #ff0fa2, #de007f);
  color: #f5fbff;
  font: inherit;
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s ease, filter 0.15s ease;
}

.controls button:hover {
  transform: translateY(-1px);
  filter: saturate(1.08);
}

.status {
  margin: 10px 0 0;
  min-height: 26px;
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink-soft);
}

.status.error {
  color: var(--error);
}

.status.success {
  color: var(--ok);
}

.status.info {
  color: #2e5874;
}

.table-shell {
  margin-top: 12px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #ffffff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    0 10px 22px rgba(22, 41, 74, 0.08);
}

.acts-table,
.tax-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

.acts-col {
  width: 25%;
}

.tax-col {
  width: 25%;
}

.acts-table th,
.acts-table td,
.tax-table th,
.tax-table td {
  padding: 13px 14px;
  border-right: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  font-size: 1rem;
  line-height: 1.32;
  overflow-wrap: break-word;
  word-break: break-word;
  hyphens: auto;
  vertical-align: top;
}

.acts-table th:last-child,
.acts-table td:last-child,
.tax-table th:last-child,
.tax-table td:last-child {
  border-right: none;
}

.acts-table th,
.tax-table th {
  color: #eef4ff;
  font-weight: 800;
  text-align: center;
  font-size: 0.93rem;
  line-height: 1.25;
  background: #1f4ed3;
}

.tax-table th {
  background: #1f4ed3;
}

.acts-table thead th:first-child,
.tax-table thead th:first-child {
  border-top-left-radius: 16px;
}

.acts-table thead th:last-child,
.tax-table thead th:last-child {
  border-top-right-radius: 16px;
}

.acts-table td,
.tax-table td {
  background: #fefeff;
  color: #23304e;
  font-weight: 600;
}

.acts-table tbody tr:nth-child(even) td {
  background: var(--surface-2);
}

.tax-table tbody tr:nth-child(even) td {
  background: #f3f7ff;
}

.acts-table tbody tr:hover td {
  background: #eaf0ff;
}

.tax-table tbody tr:hover td {
  background: #e8efff;
}

.acts-table tfoot td,
.tax-table tfoot td {
  background: linear-gradient(180deg, #d8e4fb 0%, #cfddf5 100%);
  font-weight: 800;
}

.tax-table tfoot td {
  background: linear-gradient(180deg, #dce8fc 0%, #d0ddf5 100%);
}

.acts-table tfoot td:first-child,
.tax-table tfoot td:first-child {
  border-bottom-left-radius: 16px;
}

.acts-table tfoot td:last-child,
.tax-table tfoot td:last-child {
  border-bottom-right-radius: 16px;
}

.num-col {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.acts-table tbody .num-col,
.acts-table tfoot .num-col,
.tax-table tbody .num-col,
.tax-table tfoot .num-col {
  white-space: nowrap;
}

.acts-table thead .num-col,
.tax-table thead .num-col {
  white-space: normal;
}

.input-cell {
  background: #edf3ff;
}

.tax-return-input {
  width: 100%;
  min-width: 0;
  padding: 9px 11px;
  border: 1px solid #9fb6e5;
  border-radius: 10px;
  background: #fcfffe;
  color: var(--ink);
  font: inherit;
  font-size: 0.98rem;
  font-weight: 700;
  text-align: right;
}

.tax-return-input::placeholder {
  color: #728cb8;
}

.tax-return-input:focus {
  outline: 2px solid color-mix(in srgb, #2b58ff 45%, white);
  outline-offset: 2px;
}

@media (max-width: 980px) {
  .page {
    width: calc(100% - 16px);
    margin: 8px auto 14px;
    gap: 10px;
  }

  .hero {
    grid-template-columns: 1fr;
    padding: 24px 18px;
    border-radius: 20px;
    gap: 18px;
  }

  .hero h1 {
    max-width: none;
    font-size: clamp(1.85rem, 10vw, 2.65rem);
  }

  .hero-subtitle {
    font-size: 0.98rem;
  }

  .hero-art {
    min-height: 180px;
  }

  .hero-shape.shape-a {
    width: 170px;
    height: 56px;
    left: 10px;
    top: 12px;
  }

  .hero-shape.shape-b {
    width: 220px;
    height: 66px;
    top: 78px;
    right: -16px;
  }

  .hero-shape.shape-c {
    width: 220px;
    height: 76px;
    top: 124px;
    right: 20px;
  }

  .hero-dot {
    width: 56px;
    height: 56px;
    right: 14px;
    bottom: 10px;
  }

  .hero-btn {
    min-width: 0;
    width: 100%;
  }

  .surface {
    padding: 16px;
    border-radius: 18px;
  }

  .headline h2 {
    font-size: 1.42rem;
  }

  .headline p {
    font-size: 0.96rem;
  }

  .controls-row {
    display: grid;
    width: 100%;
    gap: 8px;
  }

  .controls input,
  .controls button {
    width: 100%;
  }
}

@media (max-width: 860px) {
  .table-shell {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 16px;
  }

  .acts-table {
    min-width: 700px;
  }

  .tax-table {
    min-width: 620px;
  }

  .acts-col,
  .tax-col {
    width: auto;
  }

  .acts-table th,
  .acts-table td,
  .tax-table th,
  .tax-table td {
    padding: 10px 12px;
    font-size: 0.92rem;
    line-height: 1.28;
  }

  .headline h2 {
    font-size: 1.28rem;
  }

  .headline p {
    font-size: 0.92rem;
  }
}

@media (max-width: 640px) {
  .hero {
    padding: 20px 14px 16px;
    border-radius: 18px;
    gap: 12px;
  }

  .hero-kicker {
    font-size: 0.78rem;
    letter-spacing: 0.07em;
  }

  .hero h1 {
    font-size: clamp(1.62rem, 11.2vw, 2.2rem);
    line-height: 1;
  }

  .hero-subtitle {
    margin-top: 12px;
    font-size: 0.9rem;
    line-height: 1.35;
  }

  .hero-actions {
    margin-top: 16px;
  }

  .hero-btn {
    padding: 11px 16px;
    border-radius: 14px;
    font-size: 0.95rem;
  }

  .hero-art {
    min-height: 126px;
  }

  .hero-shape.shape-a {
    width: 120px;
    height: 40px;
    left: 6px;
    top: 8px;
  }

  .hero-shape.shape-b {
    width: 158px;
    height: 46px;
    top: 52px;
    right: -12px;
  }

  .hero-shape.shape-c {
    width: 158px;
    height: 54px;
    top: 86px;
    right: 10px;
  }

  .hero-dot {
    width: 44px;
    height: 44px;
    right: 8px;
    bottom: 6px;
  }

  .table-shell {
    overflow: visible;
    border: none;
    background: transparent;
    box-shadow: none;
  }

  .acts-table,
  .tax-table {
    min-width: 0;
    width: 100%;
    table-layout: auto;
  }

  .acts-table thead,
  .tax-table thead {
    display: none;
  }

  .acts-table tbody,
  .acts-table tfoot,
  .tax-table tbody,
  .tax-table tfoot {
    display: block;
  }

  .acts-table tr,
  .tax-table tr {
    display: block;
    margin-bottom: 10px;
    border: 1px solid var(--line);
    border-radius: 14px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 8px 18px rgba(27, 46, 86, 0.1);
  }

  .acts-table tfoot tr,
  .tax-table tfoot tr {
    margin-bottom: 0;
  }

  .acts-table td,
  .tax-table td {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--line-soft);
    padding: 10px 12px;
    background: #ffffff;
    text-align: right;
    white-space: normal;
  }

  .acts-table td::before,
  .tax-table td::before {
    content: attr(data-label);
    flex: 0 0 46%;
    max-width: 46%;
    text-align: left;
    color: var(--ink-soft);
    font-size: 0.74rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    line-height: 1.3;
  }

  .acts-table td:last-child,
  .tax-table td:last-child {
    border-bottom: none;
  }

  .acts-table tfoot td,
  .tax-table tfoot td {
    background: #e5eefc;
  }

  .tax-return-input {
    min-height: 40px;
    font-size: 0.94rem;
  }
}
