/* ==========================================================================
   Alfa · Rokkantsági kalkulátor
   App-level layer on top of the shared NCSK UI design system.
   Light-mode only.
   ========================================================================== */

@layer app {

  /* ── Page shell ─────────────────────────────────────────── */
  .alfa-wrap {
    max-width: 76rem;
    padding-top: 1.5rem;
    padding-bottom: 2.5rem;
  }

  /* The shared header renders an empty user chip when there is no login. */
  .header-username:empty { display: none !important; }

  /* ── Layout ─────────────────────────────────────────────── */
  .calc-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
    gap: 1.1rem;
    align-items: start;
  }
  .result-col {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
    align-self: start;
  }
  @media (max-width: 980px) {
    .calc-layout { grid-template-columns: 1fr; }
  }

  /* ── Panel chrome ──────────────────────────────────────── */
  .form-panel,
  .steps-panel,
  .table-panel { padding: 1.35rem 1.4rem; }

  /* Windows/Chromium: backdrop-filter rasterises the layer and disables
     subpixel antialiasing, which makes text look slightly blurry. Solid-ish
     glass keeps the look while rendering text crisply. */
  .form-panel,
  .result-panel,
  .steps-panel,
  .table-panel {
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0.25) 100%), rgba(255, 255, 255, 0.88);
  }
  .app-header {
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    background: rgba(255, 255, 255, 0.94);
  }

  /* Header: admin entry */
  .header-admin-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.6rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--ncsk-text-muted);
    border: 1px solid var(--ncsk-border);
    border-radius: var(--ncsk-radius);
    transition: color var(--motion-fast), border-color var(--motion-fast), background var(--motion-fast);
  }
  .header-admin-link i { font-size: 0.9rem; }
  .header-admin-link:hover {
    color: var(--ncsk-primary);
    border-color: var(--ncsk-primary);
    background: rgba(28, 121, 233, 0.06);
  }
  @media (max-width: 800px) {
    .header-admin-link span { display: none; }
    .header-admin-link { padding: 0.4rem; }
  }

  .panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.15rem;
  }
  .panel-kicker {
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--ncsk-text-dim);
    margin-bottom: 0.2rem;
  }
  .panel-head-icon { color: var(--ncsk-text-muted); font-size: 1.05rem; }

  /* ── Form ──────────────────────────────────────────────── */
  .form-block {
    padding: 0 0 1.15rem;
    margin-bottom: 1.15rem;
    border-bottom: 1px solid var(--ncsk-border);
  }
  .form-block-last {
    padding-bottom: 0;
    margin-bottom: 0;
    border-bottom: none;
  }
  .block-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ncsk-text-muted);
    margin-bottom: 0.7rem;
  }
  .block-label i { color: var(--ncsk-primary); font-size: 0.95rem; }

  .fields { display: grid; gap: 0.85rem; }
  .fields-2 { grid-template-columns: 1fr 1fr; }
  @media (max-width: 560px) {
    .fields-2 { grid-template-columns: 1fr; }
  }

  .a-field { display: flex; flex-direction: column; gap: 0.35rem; }
  .a-label {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--ncsk-text-muted);
    letter-spacing: 0.02em;
  }

  .a-control {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    height: 2.85rem;
    padding: 0 0.8rem;
    background: var(--ncsk-input-bg);
    border: 1px solid var(--ncsk-border);
    border-radius: var(--ncsk-radius);
    box-shadow: var(--ncsk-glass-border-top);
    transition: background var(--motion-fast), box-shadow var(--motion-fast), border-color var(--motion-fast);
  }
  .a-control:hover { border-color: var(--ncsk-border-hover); }
  .a-control:focus-within {
    background: var(--ncsk-input-focus);
    border-color: transparent;
    box-shadow: 0 0 0 2px var(--ncsk-primary);
  }
  .a-control input,
  .a-control select {
    flex: 1;
    min-width: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    border: none;
    outline: none;
    color: var(--ncsk-text);
    font-family: var(--ncsk-font);
    font-size: 0.92rem;
    font-weight: 500;
  }
  .a-date input[type="text"] {
    letter-spacing: 0.02em;
    font-variant-numeric: tabular-nums;
  }
  .a-date-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.25rem;
    margin-right: -0.2rem;
    background: none;
    border: none;
    color: var(--ncsk-text-muted);
    cursor: pointer;
    border-radius: var(--ncsk-radius);
    transition: color var(--motion-fast), background var(--motion-fast);
  }
  .a-date-btn:hover { color: var(--ncsk-primary); background: var(--ncsk-btn-neutral-bg); }
  .a-date-btn i { font-size: 1.05rem; }
  .a-date-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
    border: 0;
    padding: 0;
    margin: 0;
  }

  .a-select { position: relative; }
  .a-select select {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 1.4rem;
    cursor: pointer;
  }
  .a-select-icon {
    position: absolute;
    right: 0.8rem;
    pointer-events: none;
    color: var(--ncsk-text-muted);
    font-size: 0.9rem;
  }
  .a-select option {
    background: var(--ncsk-bg-modal);
    color: var(--ncsk-text);
  }

  .a-hint {
    display: flex;
    align-items: flex-start;
    gap: 0.35rem;
    margin-top: 0.5rem;
    font-size: 0.73rem;
    line-height: 1.5;
    color: var(--ncsk-text-muted);
  }
  .a-hint i { font-size: 0.85rem; margin-top: 0.1rem; color: var(--ncsk-text-dim); flex-shrink: 0; }

  /* Percent slider + number */
  .pct-row { display: flex; align-items: center; gap: 0.9rem; }
  .pct-box { width: 7.8rem; flex-shrink: 0; gap: 0.35rem; padding-right: 0.2rem; }
  .pct-box input { text-align: right; font-size: 1rem; font-weight: 600; }
  .pct-box input::-webkit-outer-spin-button,
  .pct-box input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
  .pct-box input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
  .a-suffix { font-size: 0.78rem; font-weight: 600; color: var(--ncsk-text-muted); }
  .pct-stepper {
    display: flex;
    flex-direction: column;
    align-self: stretch;
    justify-content: center;
    gap: 1px;
    border-left: 1px solid var(--ncsk-border);
    padding-left: 0.2rem;
    flex-shrink: 0;
  }
  .pct-step {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    flex: 1;
    max-height: 1.3rem;
    padding: 0;
    border: none;
    border-radius: 2px;
    background: transparent;
    color: var(--ncsk-text-muted);
    cursor: pointer;
    transition: background var(--motion-fast), color var(--motion-fast);
  }
  .pct-step:hover { background: var(--ncsk-btn-neutral-hover); color: var(--ncsk-primary); }
  .pct-step:active { background: var(--ncsk-primary); color: #fff; }
  .pct-step i { font-size: 0.85rem; }

  .a-slider {
    flex: 1;
    min-width: 0;
    height: 0.4rem;
    appearance: none;
    -webkit-appearance: none;
    border-radius: 99px;
    background:
      linear-gradient(90deg, var(--ncsk-primary) 0%, var(--ncsk-primary) var(--pct, 4%), var(--ncsk-btn-neutral-bg) var(--pct, 4%), var(--ncsk-btn-neutral-bg) 100%);
    outline: none;
    cursor: pointer;
  }
  .a-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 1.1rem;
    height: 1.1rem;
    border-radius: 50%;
    background: var(--ncsk-primary);
    border: 2px solid var(--ncsk-white);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    cursor: grab;
    transition: transform var(--motion-fast);
  }
  .a-slider::-webkit-slider-thumb:active { transform: scale(1.12); cursor: grabbing; }
  .a-slider::-moz-range-thumb {
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background: var(--ncsk-primary);
    border: 2px solid var(--ncsk-white);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    cursor: grab;
  }
  .a-slider:focus-visible { outline: 2px solid var(--ncsk-primary); outline-offset: 4px; }

  .pct-scale {
    display: flex;
    justify-content: space-between;
    margin: 0.35rem 8.7rem 0 0;
    font-size: 0.62rem;
    font-weight: 600;
    color: var(--ncsk-text-muted);
  }

  /* Segmented calc-mode control */
  .seg {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }
  .seg-btn {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    padding: 0.65rem 0.75rem;
    background: var(--ncsk-surface-2);
    border: 1px solid var(--ncsk-border);
    border-radius: var(--ncsk-radius);
    color: var(--ncsk-text-muted);
    cursor: pointer;
    text-align: left;
    transition: background var(--motion-fast), border-color var(--motion-fast), color var(--motion-fast), box-shadow var(--motion-fast);
  }
  .seg-btn:hover { background: var(--ncsk-surface-hover); border-color: var(--ncsk-border-hover); color: var(--ncsk-text); }
  .seg-btn.is-active {
    background: var(--ncsk-btn-neutral-hover);
    border-color: var(--ncsk-primary);
    color: var(--ncsk-text);
    box-shadow: 0 0 0 1px var(--ncsk-primary), 0 0 18px -6px var(--ncsk-primary);
  }
  .seg-title {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.85rem;
    font-weight: 600;
  }
  .seg-title i { font-size: 0.95rem; color: var(--ncsk-primary); }
  .seg-desc { font-size: 0.68rem; color: var(--ncsk-text-muted); }

  /* Units stepper */
  .units-row { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
  .stepper {
    display: flex;
    align-items: stretch;
    height: 2.7rem;
    border: 1px solid var(--ncsk-border);
    border-radius: var(--ncsk-radius);
    background: var(--ncsk-input-bg);
    box-shadow: var(--ncsk-glass-border-top);
    overflow: hidden;
    flex-shrink: 0;
  }
  .stepper-btn {
    width: 2.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--ncsk-text-muted);
    cursor: pointer;
    transition: background var(--motion-fast), color var(--motion-fast);
  }
  .stepper-btn:hover { background: var(--ncsk-btn-neutral-bg); color: var(--ncsk-text); }
  .stepper-btn:active { background: var(--ncsk-btn-neutral-hover); }
  .stepper-input {
    width: 3.4rem;
    text-align: center;
    background: transparent;
    border: none;
    border-left: 1px solid var(--ncsk-border);
    border-right: 1px solid var(--ncsk-border);
    outline: none;
    color: var(--ncsk-text);
    font-size: 1rem;
    font-weight: 600;
    -moz-appearance: textfield;
    appearance: textfield;
  }
  .stepper-input::-webkit-outer-spin-button,
  .stepper-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
  .units-hint { flex: 1; min-width: 10rem; margin-top: 0; }

  /* ── Result panel ──────────────────────────────────────── */
  .result-panel {
    position: relative;
    overflow: hidden;
    padding: 1.35rem 1.4rem;
  }
  .result-panel::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 2px;
    background: var(--ncsk-gradient);
  }
  .result-head { margin-bottom: 0.9rem; }

  .amount-label {
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--ncsk-text-muted);
  }
  .amount {
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
    margin-top: 0.3rem;
    font-family: var(--ncsk-font);
    font-size: clamp(2rem, 5.4vw, 2.85rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.035em;
    font-variant-numeric: tabular-nums;
    color: var(--ncsk-text);
    transition: color var(--motion-fast);
  }
  .amount .cur {
    font-size: 0.42em;
    font-weight: 600;
    letter-spacing: 0;
    color: var(--ncsk-text-muted);
  }
  .amount.is-zero { color: var(--ncsk-text-muted); }
  .amount-note {
    margin-top: 0.45rem;
    font-size: 0.72rem;
    line-height: 1.45;
    color: var(--ncsk-text-muted);
  }

  .result-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.55rem;
    margin-top: 1.1rem;
  }
  .stat {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    padding: 0.65rem 0.75rem;
    min-width: 0;
  }
  .stat-k {
    font-size: 0.63rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    line-height: 1.3;
    color: var(--ncsk-text-muted);
  }
  .stat-v {
    font-family: var(--ncsk-font);
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
    color: var(--ncsk-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  @media (max-width: 420px) {
    .result-grid { grid-template-columns: 1fr; }
  }

  .alerts { display: flex; flex-direction: column; gap: 0.45rem; margin-top: 0.9rem; }
  .alerts:empty { display: none; }
  .alert {
    display: flex;
    align-items: flex-start;
    gap: 0.45rem;
    padding: 0.55rem 0.65rem;
    font-size: 0.72rem;
    line-height: 1.45;
    border-radius: var(--ncsk-radius);
    border: 1px solid var(--ncsk-border);
    background: var(--ncsk-surface-2);
    color: var(--ncsk-text-muted);
  }
  .alert i { font-size: 0.9rem; margin-top: 0.05rem; flex-shrink: 0; }
  .alert-warn { border-color: rgba(245, 158, 11, 0.35); background: rgba(245, 158, 11, 0.08); color: var(--ncsk-text); }
  .alert-warn i { color: var(--ncsk-warning); }
  .alert-info i { color: var(--ncsk-primary); }

  /* ── Steps ─────────────────────────────────────────────── */
  .steps-panel { padding-bottom: 1.15rem; }
  .steps { list-style: none; display: flex; flex-direction: column; }
  .steps li {
    display: grid;
    grid-template-columns: 1.45rem minmax(0, 1fr) auto;
    align-items: start;
    gap: 0.6rem;
    padding: 0.55rem 0;
    border-bottom: 1px dashed var(--ncsk-border);
  }
  .steps li:last-child { border-bottom: none; }
  .step-idx {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.45rem;
    height: 1.45rem;
    border-radius: 50%;
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--ncsk-text);
    background: var(--ncsk-btn-neutral-bg);
    border: 1px solid var(--ncsk-border);
  }
  .step-total .step-idx { background: var(--ncsk-gradient); border-color: transparent; color: #fff; }
  .step-main { display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
  .step-k { font-size: 0.78rem; font-weight: 600; color: var(--ncsk-text); line-height: 1.3; }
  .step-sub { font-size: 0.66rem; color: var(--ncsk-text-muted); line-height: 1.35; }
  .step-v {
    font-size: 0.82rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: var(--ncsk-text);
    white-space: nowrap;
    padding-top: 0.05rem;
  }
  .step-total .step-v { color: var(--ncsk-primary); font-size: 0.9rem; }
  @media (max-width: 420px) {
    .steps li { grid-template-columns: 1.35rem minmax(0, 1fr); }
    .step-v { grid-column: 2; padding-top: 0; }
  }

  .fixed-ref {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-top: 0.9rem;
    padding-top: 0.8rem;
    border-top: 1px solid var(--ncsk-border);
  }
  .fixed-ref-k {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.68rem;
    color: var(--ncsk-text-muted);
    line-height: 1.35;
  }
  .fixed-ref-k i { color: var(--ncsk-text-dim); font-size: 0.85rem; flex-shrink: 0; }
  .fixed-ref-v {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--ncsk-text);
    white-space: nowrap;
  }

  /* ── Index table ───────────────────────────────────────── */
  .table-panel { margin-top: 1.1rem; }
  .table-head { align-items: flex-end; }
  .table-sub { font-size: 0.74rem; color: var(--ncsk-text-muted); margin-top: 0.15rem; }
  .table-badges { display: flex; gap: 0.35rem; flex-wrap: wrap; justify-content: flex-end; }

  .table-scroll {
    max-height: 42rem;
    overflow: auto;
    border: 1px solid var(--ncsk-border);
    border-radius: var(--ncsk-radius);
    background: var(--ncsk-surface-2);
  }
  .index-table {
    width: 100%;
    min-width: 58rem;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.78rem;
  }
  .index-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 0.6rem 0.7rem;
    background: var(--ncsk-bg-modal);
    border-bottom: 1px solid var(--ncsk-border);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ncsk-text-muted);
    text-align: right;
    white-space: nowrap;
  }
  .index-table thead th.col-mode {
    left: 0;
    z-index: 3;
    text-align: left;
    border-left: 3px solid transparent;
  }
  .index-table th.col-mode {
    position: sticky;
    left: 0;
    z-index: 1;
    padding: 0.5rem 0.8rem 0.5rem 0.75rem;
    background: var(--ncsk-surface-1);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-right: 1px solid var(--ncsk-border);
    border-left: 3px solid var(--plan-bar, transparent);
    text-align: left;
    white-space: nowrap;
    min-width: 13rem;
  }
  .index-table td {
    padding: 0.5rem 0.7rem;
    text-align: right;
    white-space: nowrap;
    font-size: 0.76rem;
    font-variant-numeric: tabular-nums;
    color: var(--ncsk-text);
    border-bottom: 1px solid var(--ncsk-border);
    transition: background var(--motion-fast);
  }
  .index-table tbody tr:last-child th,
  .index-table tbody tr:last-child td { border-bottom: none; }
  .index-table td.na { color: var(--ncsk-text-muted); opacity: 0.45; }

  /* Plan groups */
  .index-table tbody tr[data-plan="0"] { --plan-bar: #1C79E9; --plan-ink: #1C79E9; }
  .index-table tbody tr[data-plan="1"] { --plan-bar: #32D0F3; --plan-ink: #0E7490; }
  .index-table tbody tr[data-plan="2"] { --plan-bar: #6366F1; --plan-ink: #4F46E5; }
  .index-table tbody tr[data-plan="3"] { --plan-bar: #A855F7; --plan-ink: #7E22CE; }
  .index-table tbody tr[data-plan="4"] { --plan-bar: #10B981; --plan-ink: #047857; }
  .index-table tbody tr[data-plan="5"] { --plan-bar: #94A3B8; --plan-ink: #475569; }

  .index-table tbody tr.plan-start:not(:first-child) th,
  .index-table tbody tr.plan-start:not(:first-child) td {
    border-top: 2px solid var(--ncsk-border-hover);
  }

  .plan-name {
    display: block;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.25;
    color: var(--plan-ink);
  }
  .mode-type {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0.1rem;
    font-size: 0.66rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--ncsk-text-muted);
    line-height: 1.3;
  }
  .mode-type::before {
    content: "";
    width: 0.35rem;
    height: 0.35rem;
    border-radius: 50%;
    background: var(--plan-bar, var(--ncsk-text-muted));
    flex-shrink: 0;
  }

  @media (hover: hover) {
    .index-table tbody tr:hover td { background: var(--ncsk-btn-neutral-bg); }
    .index-table tbody tr:hover th.col-mode { background: var(--ncsk-btn-neutral-bg); }
  }

  /* Selected mode row */
  .index-table tbody tr.is-selected th.col-mode {
    background: var(--ncsk-btn-neutral-hover);
  }
  .index-table tbody tr.is-selected .mode-type { color: var(--ncsk-text); font-weight: 700; }
  .index-table tbody tr.is-selected td { background: rgba(28, 121, 233, 0.06); }

  /* Selected indexation year column */
  .index-table td.is-year {
    background: rgba(50, 210, 243, 0.1);
    color: var(--ncsk-text);
    font-weight: 600;
  }
  .index-table tbody tr.is-selected td.is-year {
    background: rgba(50, 210, 243, 0.18);
    color: var(--ncsk-text);
  }
  .index-table thead th.is-year {
    color: var(--ncsk-primary);
    background: var(--ncsk-btn-neutral-hover);
    box-shadow: inset 0 -2px 0 var(--ncsk-primary);
  }

  .print-head { display: none; }

  /* ── Narrow desktop windows ─────────────────────────────
     ncskui switches to the mobile layout purely on width (<=800px). In a
     side-by-side browser window that yields 20px text and the mobile dock on
     a mouse-driven desktop. Keep the desktop layout for fine pointers. */
  @media (max-width: 800px) {
    html.desktop-pointer { font-size: 16px !important; --ncsk-header-height: 5.25rem !important; }
    html.desktop-pointer,
    html.desktop-pointer body { height: auto !important; overflow: visible !important; }
    html.desktop-pointer .app-container { height: auto !important; overflow: visible !important; }
    html.desktop-pointer .main-content { padding-bottom: 0 !important; }
    html.desktop-pointer .view-body { padding: 1.25rem 1rem 2rem !important; }
    html.desktop-pointer .app-header {
      position: static !important;
      height: var(--ncsk-header-height) !important;
      padding: 0.35rem 1.5rem !important;
    }
    html.desktop-pointer .header-center { display: flex !important; }
    html.desktop-pointer .header-logo,
    html.desktop-pointer .header-brand img { height: 2.5rem !important; max-width: 9rem !important; }
    html.desktop-pointer .ncsk-dock { display: none !important; }
    html.desktop-pointer .header-admin-link span { display: inline !important; }
  }

  /* ── Print ─────────────────────────────────────────────── */
  @media print {
    :root {
      --ncsk-text: #0f172a;
      --ncsk-text-muted: #475569;
      --ncsk-text-dim: #0f172a;
      --ncsk-surface-1: #ffffff;
      --ncsk-surface-2: #f8fafc;
      --ncsk-surface-3: #ffffff;
      --ncsk-border: #cbd5e1;
      --ncsk-bg-modal: #ffffff;
      --ncsk-input-bg: #ffffff;
      --ncsk-btn-neutral-bg: #f1f5f9;
      --ncsk-btn-neutral-hover: #e2e8f0;
      --ncsk-primary: #1c79e9;
    }
    body { background: #fff !important; }
    #ncsk-loader, #webgl-background, .ncsk-canvas-overlay,
    .app-header, .ncsk-dock, .ncsk-fab { display: none !important; }
    .alfa-wrap { max-width: none; padding: 0.2rem 0 0; }
    .view-body { padding: 0; }
    .print-head {
      display: flex;
      justify-content: space-between;
      align-items: baseline;
      padding-bottom: 0.5rem;
      margin-bottom: 0.75rem;
      border-bottom: 2px solid var(--ncsk-primary);
      font-size: 0.9rem;
    }
    .print-head span { font-size: 0.7rem; color: #475569; }
    .calc-layout { grid-template-columns: 1fr 1fr; gap: 0.6rem; }
    .result-col { position: static; }
    .ncsk-panel, .ncsk-well {
      box-shadow: none !important;
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
      background: #fff !important;
    }
    .amount { font-size: 1.7rem; }
    .table-scroll { max-height: none; overflow: visible; }
    .index-table { min-width: 0; font-size: 0.55rem; }
    .index-table thead th { position: static; background: #fff; }
    .index-table th.col-mode { position: static; backdrop-filter: none; min-width: 0; }
    .index-table td { position: static; }
    .table-panel { margin-top: 0.6rem; page-break-inside: avoid; }
    .steps-panel, .table-panel { page-break-inside: avoid; }
    .a-hint { display: none; }
    .form-block { padding-bottom: 0.6rem; margin-bottom: 0.6rem; }
    .seg-btn.is-active { box-shadow: none; border-color: #1c79e9; }
    .alert { background: #fff; }
  }
}
