/* "החיסכון שלי" as a page (SavingsScreen). The pieces are the dialog's (invest.css, planflow.css); here only their layout. */
.sv-page { display: flex; flex-direction: column; min-height: 100vh; }
.sv-page .foot { position: static; margin-top: auto; }
.sv-page .titlebar h1:focus { outline: none; }
.sv-wrap { width: 100%; box-sizing: border-box; padding-bottom: var(--space-16); }
.sv-cols { display: grid; gap: var(--space-16); }
.sv-cols[hidden], .sv-stack[hidden] { display: none; }
.sv-cols .inv-seg[hidden] { display: none; }
.sv-side { display: flex; flex-direction: column; gap: var(--space-12); }
.sv-cols .bh { flex: none; margin: 0; border-radius: 18px; overflow: hidden; background: var(--bg-app); }
.sv-about { flex: none; padding: 12px 16px; border-radius: 18px; background: var(--surface-1); font-size: 14px; line-height: 1.5; }
.sv-about b { color: var(--date-label); }
.sv-about p { margin: var(--space-4) 0 0; color: var(--color-text-muted); }
.sv-card { flex: none; padding: 10px; border-radius: 18px; background: var(--surface-1); }
.sv-card .inv-led { margin: 0; }
.sv-card .inv-actions { margin-top: 10px; }
.sv-cols .inv-pane { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.sv-cols .inv-sl { flex: none; font-size: 15px; }
.sv-cols .pln-tracks { margin: 0; }
.sv-histbox { padding: 10px 16px; border-radius: 18px; background: var(--surface-1); }
@media (min-width: 1000px) {
  .sv-page { height: 100vh; height: 100dvh; min-height: 0; }
  .sv-wrap { flex: 1; min-height: 0; display: flex; flex-direction: column; padding-top: var(--space-16); }
  .sv-wrap > .titlebar { flex: none; min-height: 77px; box-sizing: border-box; }
  .sv-cols { flex: 1; min-height: 0; grid-template-columns: 360px minmax(0, 1fr) 270px; grid-template-rows: minmax(0, 1fr); }
  .sv-side, .sv-scroll { min-height: 0; overflow-y: auto; scrollbar-width: thin; }
  .sv-scroll { flex: 1; }
}
@media (min-width: 1024px) { .sv-wrap { max-width: 1160px; } }
@media (min-width: 1000px) and (max-height: 860px) {
  .sv-page .foot { padding-block: 6px; font-size: 12px; }
  .sv-wrap { padding-bottom: 8px; }
  /* the side column holds three cards: tighter, so the save button stays on screen */
  .sv-side { gap: 8px; }
  .sv-side .bh-top { min-height: 0; height: 0; }
  .sv-side .bh-panel.iv-pan { margin: 8px; padding: 8px 12px; }
  .sv-side .iv-ring, .sv-side .iv-ring svg { width: 48px; height: 48px; }
  .sv-side .iv-big { font-size: 24px; }
  .sv-side .iv-sub { margin-top: 4px; }
  .sv-side .iv-hl { margin: 6px 0; }
  .sv-about { padding: 8px 14px; font-size: 12.5px; line-height: 1.4; }
  .sv-about p { margin-top: 2px; }
  .sv-card { padding: 8px; }
  .sv-card .inv-led { padding-block: 0; }
  .sv-card .inv-fl { min-height: 46px; }
  .sv-card .inv-actions { margin-top: 8px; }
  .sv-card .inv-actions button { min-height: 40px; }
}
/* the shortest laptops */
@media (min-width: 1000px) and (max-height: 700px) {
  .sv-side .bh { padding: 0; min-height: 0; }
  .sv-side .bh-panel.iv-pan { margin: 6px; padding: 4px 12px; }
  .sv-side .iv-hl { margin: 4px 0; }
  .sv-about { font-size: 12px; line-height: 1.35; padding-block: 6px; }
  .sv-card .inv-fl { min-height: 42px; }
}

/* phones: header, title, value banner, tabs and the disclaimer stay put; the explanation and the picked tab scroll between them */
@media (max-width: 999.98px) {
  .sv-page { height: 100vh; height: 100dvh; min-height: 0; }
  .sv-page .foot { flex: none; margin: 0; }
  .sv-wrap { flex: 1; min-height: 0; display: flex; flex-direction: column; padding-bottom: 0; }
  .sv-wrap > .titlebar { flex: none; position: static; min-height: 77px; box-sizing: border-box; margin-bottom: 0; }
  .sv-stack { flex: 1; min-height: 0; display: flex; flex-direction: column; margin-inline: calc(-1 * var(--space-16)); }
  .sv-stack .bh { flex: none; position: relative; top: 0; margin: 0; padding: 10px 16px 12px; background: var(--bg-app); }
  .sv-stack .bh-top, .sv-stack .bh-scrim { display: none; }
  .sv-stack .bh-panel.iv-pan { margin: 0; padding: 8px 14px; }
  .sv-stack .iv-ring, .sv-stack .iv-ring svg { width: 52px; height: 52px; }
  .sv-stack .iv-big { font-size: 26px; }
  .sv-stack .iv-sub { margin-top: 4px; }
  .sv-stack .iv-hl { margin: 6px 0; }
  .sv-stack .inv-seg { flex: none; margin: 0 16px var(--space-8); }
  .sv-body { flex: 1; min-height: 0; overflow-y: auto; padding: 0 16px var(--space-16); }
  .sv-body .sv-about { margin-bottom: var(--space-12); }
  .sv-body .inv-pane.off { display: none; }
}
/* a phone held sideways has no room for fixed parts: the whole page scrolls */
@media (max-width: 999.98px) and (max-height: 560px) {
  .sv-page { height: auto; min-height: 100dvh; }
  .sv-wrap, .sv-stack { flex: none; }
  .sv-body { overflow: visible; }
}
/* the copies inside the "?" popup keep the page's look without its sheet frame */
.sv-help.sv-help { background: none; padding: 0; margin: 0; max-width: none; max-height: none; box-shadow: none; border: 0; animation: none; overflow: visible; }
.sv-help .bh { margin: 0; border-radius: 18px; overflow: hidden; background: var(--bg-app); }
.sv-help .pln-tracks, .sv-help .inv-led { margin: 0; }
/* the title bar saves, so the page has no button under the deposit */
.sv-cols .inv-actions, .sv-stack .inv-actions { display: none; }
@media (min-width: 1000px) { .sv-topsave .dirty-note:not([hidden]) { display: inline-flex; } }
