*,
*::before,
*::after {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

:root {
  --bg: #1a1a2e;
  --surface: #16213e;
  --surface-hover: #1f2f52;
  --accent: #e94560;
  --accent-soft: rgba(233, 69, 96, 0.15);
  --text: #eaeaea;
  --text-muted: #a0a0b8;
  --border: rgba(255, 255, 255, 0.08);
  --paid-opacity: 0.42;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --header-h: 5.5rem;
  --footer-h: 7.25rem;
  --fab-size: 3.5rem;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  min-height: 100dvh;
  font-family: system-ui, -apple-system, "Segoe UI", "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  overscroll-behavior: none;
}

button,
input {
  font: inherit;
  color: inherit;
}

#app {
  min-height: 100dvh;
}

.page {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  padding-top: var(--safe-top);
  padding-bottom: calc(var(--safe-bottom) + var(--footer-h) + 1rem);
}

.page--form {
  padding-bottom: calc(var(--safe-bottom) + 1rem);
}

.page--auth {
  padding-bottom: calc(var(--safe-bottom) + 1rem);
}

.page--center {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-bottom: var(--safe-bottom);
}

.loading {
  margin: 0;
  color: var(--text-muted);
}

.header__row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.header__user {
  margin: 0.35rem 0 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
  word-break: break-all;
}

.btn-logout {
  flex-shrink: 0;
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 0.625rem;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.75rem;
  cursor: pointer;
}

.btn-logout:active:not(:disabled) {
  background: var(--surface);
}

.form__error {
  margin: 0;
  padding: 0.75rem 1rem;
  border-radius: 0.875rem;
  background: rgba(255, 107, 107, 0.12);
  border: 1px solid rgba(255, 107, 107, 0.35);
  color: #ffb4b4;
  font-size: 0.875rem;
}

.fab:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.card:disabled {
  cursor: not-allowed;
}

.card__edit:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.header {
  position: sticky;
  top: 0;
  z-index: 10;
  padding: 1.25rem 1.25rem 0.75rem;
  background: linear-gradient(to bottom, var(--bg) 70%, transparent);
}

.header--form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header__title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.header--form .header__title {
  font-size: 1.125rem;
}

.header__subtitle {
  margin: 0.25rem 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.header__progress {
  margin: 0.5rem 0 0;
  font-size: 0.8125rem;
  color: var(--accent);
  font-weight: 600;
}

.btn-back {
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 0.75rem;
  background: var(--surface);
  color: var(--text);
  font-size: 1.25rem;
  cursor: pointer;
}

.btn-back:active {
  background: var(--surface-hover);
}

.main {
  flex: 1;
  padding: 0 1rem 1rem;
}

.list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.list__item {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
}

.card {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 4.25rem;
  padding: 0.875rem 1rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: opacity 0.25s ease, background 0.15s ease, transform 0.1s ease;
}

.card:active:not(.card--paid) {
  transform: scale(0.98);
  background: var(--surface-hover);
}

.card--paid {
  opacity: var(--paid-opacity);
  background: var(--accent-soft);
  border-color: rgba(233, 69, 96, 0.25);
}

.card__body {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.card__name {
  font-size: 1.0625rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card__meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.card__amount {
  font-variant-numeric: tabular-nums;
  font-weight: 500;
}

.card__day {
  font-variant-numeric: tabular-nums;
}

.card__badge {
  flex-shrink: 0;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.card__edit {
  flex-shrink: 0;
  align-self: center;
  padding: 0.625rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8125rem;
  cursor: pointer;
}

.card__edit:active {
  background: var(--surface);
}

.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 40dvh;
  text-align: center;
  padding: 2rem 1rem;
}

.empty__text {
  margin: 0;
  font-size: 1.0625rem;
  color: var(--text-muted);
}

.empty__hint {
  margin: 0.5rem 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  opacity: 0.7;
}

.footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  padding: 0.75rem 1rem calc(0.75rem + var(--safe-bottom));
  background: linear-gradient(to top, var(--bg) 75%, transparent);
}

.footer__total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0.625rem 1rem;
  border: 1px solid var(--border);
  border-radius: 0.875rem;
  background: var(--surface);
}

.footer__total-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
}

.footer__total-amount {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  font-variant-numeric: tabular-nums;
}

.footer__total-remaining {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent);
}

.footer__total-sep {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-muted);
}

.footer__total-all {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-muted);
}

.fab {
  position: fixed;
  right: 1.25rem;
  bottom: calc(var(--footer-h) + var(--safe-bottom) + 0.75rem);
  z-index: 11;
  width: var(--fab-size);
  height: var(--fab-size);
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(233, 69, 96, 0.45);
}

.fab:active {
  transform: scale(0.94);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.75rem 1.25rem;
  border: none;
  border-radius: 0.875rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.1s ease;
}

.btn:active:not(:disabled) {
  transform: scale(0.98);
}

.btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.btn--block {
  width: 100%;
}

.btn--primary {
  background: var(--accent);
  color: #fff;
}

.btn--secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn--danger {
  background: transparent;
  color: #ff6b6b;
  border: 1px solid rgba(255, 107, 107, 0.35);
}

.form {
  padding: 0.5rem 1.25rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.field__label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
}

.field__input {
  width: 100%;
  min-height: 3rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: 0.875rem;
  background: var(--surface);
  color: var(--text);
  outline: none;
}

.field__input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.field__input::placeholder {
  color: var(--text-muted);
  opacity: 0.5;
}

.form__actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

@media (min-width: 480px) {
  .page {
    max-width: 28rem;
    margin: 0 auto;
  }

  .footer,
  .fab {
    max-width: 28rem;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
  }

  .fab {
    left: auto;
    right: calc(50% - 14rem + 1.25rem);
    transform: none;
  }
}

/* Tabs */
.tabs {
  display: flex;
  gap: 0.5rem;
  padding: 0 1rem 0.75rem;
}

.tabs__btn {
  flex: 1;
  min-height: 2.5rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
}

.tabs__btn--active {
  background: var(--accent-soft);
  border-color: rgba(233, 69, 96, 0.35);
  color: var(--accent);
}

/* Tax / expenses */
.page--tax {
  padding-bottom: calc(var(--safe-bottom) + 5.5rem);
}

.page--tax-form {
  padding-bottom: calc(var(--safe-bottom) + 1rem);
}

.footer--tax {
  background: linear-gradient(to top, var(--bg) 85%, transparent);
}

.year-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.year-bar__label {
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-weight: 600;
}

.field__input--compact {
  min-height: 2.5rem;
  padding: 0.5rem 0.75rem;
  flex: 1;
}

.expense-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.expense-list__item {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
}

.expense-card {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 4.25rem;
  padding: 0.875rem 1rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.expense-card:active {
  background: var(--surface-hover);
}

.expense-card__main {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.expense-card__vendor {
  font-size: 1rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.expense-card__meta {
  display: flex;
  gap: 0.625rem;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.expense-card__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
  flex-shrink: 0;
}

.expense-card__amount {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.expense-card__receipt {
  font-size: 0.875rem;
}

.receipt-upload__label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.375rem;
}

.receipt-upload__box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 9rem;
  padding: 1.25rem;
  border: 2px dashed var(--border);
  border-radius: 1rem;
  background: var(--surface);
  cursor: pointer;
}

.receipt-upload__icon {
  font-size: 2rem;
}

.receipt-upload__text {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.receipt-upload__input {
  display: none;
}

.receipt-preview {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.receipt-preview__img {
  width: 100%;
  max-height: 16rem;
  object-fit: contain;
  border-radius: 0.875rem;
  border: 1px solid var(--border);
  background: #000;
}

.receipt-preview--detail .receipt-preview__img {
  max-height: 24rem;
}

.expense-detail__list {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.expense-detail__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
}

.expense-detail__row dt {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-weight: 600;
}

.expense-detail__row dd {
  margin: 0;
  text-align: right;
  font-weight: 500;
}

.expense-detail__no-receipt {
  margin: 0;
  padding: 1rem;
  text-align: center;
  color: var(--text-muted);
  background: var(--surface);
  border-radius: 0.875rem;
}

select.field__input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23a0a0b8' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

/* Tax sub-tabs */
.sub-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  padding: 0 1rem 0.75rem;
}

.sub-tabs__btn {
  flex: 1 1 calc(33.333% - 0.375rem);
  min-width: calc(33.333% - 0.375rem);
  min-height: 2.25rem;
  border: 1px solid var(--border);
  border-radius: 0.625rem;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0 0.25rem;
}

.sub-tabs__btn--active {
  background: var(--surface);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.15);
}

.page--summary {
  padding-bottom: calc(var(--safe-bottom) + 1rem);
}

.summary-cards {
  display: grid;
  gap: 0.625rem;
  margin-bottom: 1.25rem;
}

.summary-card {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.875rem 1rem;
  border-radius: 0.875rem;
  border: 1px solid var(--border);
  background: var(--surface);
}

.summary-card__label {
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-weight: 600;
}

.summary-card__value {
  font-size: 1.375rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.summary-card--income .summary-card__value {
  color: #6ee7b7;
}

.summary-card--expense .summary-card__value {
  color: var(--accent);
}

.summary-card--balance.summary-card--plus .summary-card__value {
  color: #6ee7b7;
}

.summary-card--balance.summary-card--minus .summary-card__value {
  color: #ffb4b4;
}

.summary-section {
  margin-bottom: 1.25rem;
}

.summary-section__title {
  margin: 0 0 0.625rem;
  font-size: 0.9375rem;
  font-weight: 700;
}

.summary-empty {
  margin: 0;
  padding: 1.25rem;
  text-align: center;
  color: var(--text-muted);
  background: var(--surface);
  border-radius: 0.875rem;
  font-size: 0.875rem;
}

.summary-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 0.875rem;
  background: var(--surface);
}

.summary-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.summary-table th,
.summary-table td {
  padding: 0.625rem 0.5rem;
  text-align: right;
  border-bottom: 1px solid var(--border);
}

.summary-table th:first-child,
.summary-table td:first-child {
  text-align: left;
  padding-left: 0.875rem;
}

.summary-table th:last-child,
.summary-table td:last-child {
  padding-right: 0.875rem;
}

.summary-table th {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.75rem;
}

.summary-table__row--empty td {
  opacity: 0.35;
}

.col-income {
  color: #6ee7b7;
}

.col-expense {
  color: var(--accent);
}

.col-balance--plus {
  color: #6ee7b7;
}

.col-balance--minus {
  color: #ffb4b4;
}

.client-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 0.875rem;
  background: var(--surface);
  overflow: hidden;
}

.client-list__item {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
}

.client-list__item:last-child {
  border-bottom: none;
}

.client-list__name {
  font-weight: 500;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-list__amount {
  flex-shrink: 0;
  font-weight: 600;
  color: #6ee7b7;
  font-variant-numeric: tabular-nums;
}

.summary-note {
  margin: 0;
  font-size: 0.75rem;
  color: var(--text-muted);
  opacity: 0.8;
  line-height: 1.5;
}

.expense-card__amount--income {
  color: #6ee7b7;
}

.expense-card__desc {
  font-size: 0.8125rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.footer__total-remaining--income {
  color: #6ee7b7;
}

.attachment-hint {
  margin: 0.5rem 0 0;
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.attachment-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.625rem;
}

.attachment-actions__btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  min-height: 5.5rem;
  padding: 0.75rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 0.875rem;
  background: var(--surface);
  cursor: pointer;
  font-size: 0.8125rem;
  color: var(--text-muted);
  text-align: center;
}

.attachment-actions__btn:active {
  background: var(--surface-hover);
}

.attachment-actions__icon {
  font-size: 1.5rem;
}

.attachment-actions__input {
  display: none;
}

.text-income {
  color: #6ee7b7;
}

/* Deduction filters */
.filter-chips {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.filter-chips__btn {
  flex: 1;
  min-height: 2.25rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
}

.filter-chips__btn--active {
  background: var(--surface);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.15);
}

.expense-card--deduction-medical {
  border-left: 3px solid #60a5fa;
}

.expense-card--deduction-furusato {
  border-left: 3px solid #f472b6;
}

.expense-card--salary {
  border-left: 3px solid #a78bfa;
}

.form-section {
  margin: 1.25rem 0;
  padding-top: 0.25rem;
  border-top: 1px solid var(--border);
}

.form-section__title {
  margin: 0 0 0.875rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
}

.deduction-detail__type {
  margin: 0 0 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* Type picker */
.type-picker {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.type-picker__btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.25rem;
  width: 100%;
  padding: 1rem 1.125rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.type-picker__btn:active {
  background: var(--surface-hover);
}

.type-picker__icon {
  font-size: 1.5rem;
  line-height: 1;
}

.type-picker__label {
  font-size: 1rem;
  font-weight: 600;
}

.type-picker__desc {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.form__hint {
  margin: 0 0 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Deduction summary */
.deduction-summary {
  display: grid;
  gap: 1rem;
  margin-bottom: 1rem;
}

.deduction-summary__block {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface);
}

.deduction-summary__heading {
  margin: 0 0 0.75rem;
  font-size: 0.9375rem;
  font-weight: 600;
}

.deduction-summary__list {
  margin: 0;
}

.deduction-summary__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.375rem 0;
  font-size: 0.875rem;
}

.deduction-summary__row dt {
  color: var(--text-muted);
}

.deduction-summary__row dd {
  margin: 0;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.deduction-summary__highlight {
  color: #93c5fd;
}

.summary-settings {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.summary-settings__hint {
  margin: 0.5rem 0 0.75rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.attachment-preview--pdf {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding: 1.25rem 1rem;
  border: 1px dashed var(--border);
  border-radius: 1rem;
  background: var(--surface);
}

.attachment-preview__pdf-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3.5rem;
  min-height: 3.5rem;
  border-radius: 0.75rem;
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  font-size: 0.875rem;
  font-weight: 700;
}

.attachment-preview__pdf-name {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text);
  word-break: break-all;
  text-align: center;
}

.attachment-preview__pdf {
  width: 100%;
  min-height: 16rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: #fff;
}

/* Export */
.page--export {
  padding-bottom: calc(var(--safe-bottom) + 1rem);
}

.export-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.export-actions__hint {
  margin: 0 0 1rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.export-preview__title {
  margin: 0 0 1rem;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-muted);
}

.export-pdf {
  padding: 1.25rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface);
}

.export-pdf__header {
  text-align: center;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--border);
}

.export-pdf__title {
  margin: 0 0 0.375rem;
  font-size: 1.125rem;
  font-weight: 700;
}

.export-pdf__meta {
  margin: 0.25rem 0 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.export-pdf__section {
  margin-bottom: 1.25rem;
}

.export-pdf__section h3 {
  margin: 0 0 0.625rem;
  font-size: 0.875rem;
  font-weight: 600;
}

.export-pdf__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.export-pdf__table th,
.export-pdf__table td {
  padding: 0.5rem 0.625rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  text-align: left;
}

.export-pdf__table thead th {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.export-pdf__row--bold th,
.export-pdf__row--bold td {
  font-weight: 700;
}

.export-pdf__notice {
  margin: 1rem 0 0;
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.5;
}

@media print {
  html,
  body,
  #app {
    min-height: auto !important;
    height: auto !important;
    background: #fff !important;
    color: #000 !important;
  }

  .header--no-print,
  .tabs,
  .sub-tabs,
  .year-bar,
  .btn-logout,
  .fab,
  .export-actions,
  .export-preview__title {
    display: none !important;
  }

  .page,
  .page--export {
    display: block !important;
    min-height: auto !important;
    padding: 0 !important;
  }

  .main {
    padding: 0 !important;
  }

  .export-preview {
    margin: 0;
    padding: 0;
  }

  .export-pdf {
    border: none;
    border-radius: 0;
    background: #fff !important;
    color: #000 !important;
    padding: 0;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .export-pdf__title,
  .export-pdf__section h3,
  .export-pdf__table th,
  .export-pdf__table td {
    color: #000 !important;
  }

  .export-pdf__header {
    border-bottom: 2px solid #000;
  }

  .export-pdf__table th,
  .export-pdf__table td {
    border-bottom: 1px solid #ccc;
  }

  .export-pdf__meta,
  .export-pdf__notice {
    color: #333 !important;
  }
}
