/* ============================================================
   PRESU — Premium Skin (presu-skin.css)
   Brand world: vibrant royal blue + golden yellow.
   Homepage gets the full treatment; tool pages keep their
   ORIGINAL design (only brand accent follows the palette).
   ============================================================ */


:root {
  --presu-blue: #2563eb;
  --presu-blue-deep: #1d4ed8;
  --presu-navy: #132c5c;
  --presu-navy-deep: #0f2450;
  --presu-gold: #fbbf24;
  --presu-gold-hi: #ffd23f;
  --presu-gold-deep: #f59e0b;
}

/* ────────────────────────────────────────────────────────────
   1 · HOMEPAGE GROUNDS
   Light (default): airy blue-grey ground, white cards, navy ink.
   Dark: deep navy world.
   (index.css tokens are only consumed on the homepage.)
   ──────────────────────────────────────────────────────────── */
:root {
  --dark: #eef4fc;
  --dark-2: #e2ecf9;
  --dark-3: #ffffff;
  --dark-4: #f4f8fe;
  --ink: #12294f;
  --ink-2: #29416d;
  --ink-3: #53658c;
  --ink-4: #8494b4;
  --ink-5: #b4c2d9;
  --border: #d5e1f1;
  --border-2: #c1d2ea;
  --accent-bg: rgba(37, 99, 235, 0.08);
  --accent-bd: rgba(37, 99, 235, 0.22);
}
/* ── Tool pages: same brand world (user request: uniform colors) ──
   Light: cool blue-grey ground, white cards, navy ink.
   Dark: deep navy — matches the homepage dark theme. */
:root {
  --vl-bg: #eef4fc;
  --vl-bg-2: #e6eefa;
  --vl-surface: #ffffff;
  --vl-surface-2: #f4f8fe;
  --vl-surface-3: #e9f0fa;
  --vl-border: #d5e1f1;
  --vl-border-2: #c1d2ea;
  --vl-border-3: #a9bfe0;
  --vl-t1: #12294f;
  --vl-t2: #29416d;
  --vl-t3: #53658c;
  --vl-t4: #8494b4;
  --vl-t5: #b4c2d9;
}

/* ────────────────────────────────────────────────────────────
   2 · HEADER — navy bar on the homepage (both themes)
   ──────────────────────────────────────────────────────────── */
.px-header, [data-theme] .px-header {
  background: linear-gradient(180deg, #16336a, var(--presu-navy));
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.px-brand-name {
  color: #ffffff;
}
.px-nav-btn,
.px-nav-link {
  color: #cddcf5;
}
.px-nav-btn:hover,
.px-nav-link:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}
body:not(.tool-page) .px-theme-toggle {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #e6eefb;
}
body:not(.tool-page) .px-theme-toggle .px-theme-label,
body:not(.tool-page) .px-theme-toggle svg {
  color: #e6eefb;
  stroke: #e6eefb;
}
.px-mobile-toggle,
[data-theme] .px-mobile-toggle {
  color: #ffffff !important;
}
.px-mobile-toggle .bar1,
.px-mobile-toggle .bar2,
.px-mobile-toggle .bar3 {
  background: #ffffff !important;
}
/* language switcher pill (ES | EN) */
.px-lang-switch {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  margin-right: 10px;
  border-radius: 9999px;
  background: #ffffff;
  border: 1px solid rgba(18, 41, 79, 0.18);
  box-shadow: 0 1px 4px rgba(9, 30, 66, 0.15);
}
.px-lang-switch button {
  font-family: inherit;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  border-radius: 9999px;
  color: #1b2b4b;
  cursor: pointer;
}
.px-lang-switch button.on {
  background: linear-gradient(180deg, var(--presu-gold-hi), var(--presu-gold-deep));
  color: #142a52;
}

/* header CTA — golden on every page, like the reference */
.px-btn-primary {
  background: linear-gradient(180deg, var(--presu-gold-hi), var(--presu-gold-deep));
  color: #142a52;
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.35);
}
.px-btn-primary:hover {
  background: linear-gradient(180deg, #ffe082, var(--presu-gold));
}

/* "No Upload" privacy badge — brand blue (green is reserved for
   money states: paid / success) */
body.tool-page .t-privacy-badge {
  color: var(--presu-blue);
  border-color: rgba(37, 99, 235, 0.25);
  background: rgba(37, 99, 235, 0.06);
}

/* tool action buttons (Print / Download / Generate) — brand blue */
body.tool-page .btn-primary {
  background: linear-gradient(180deg, #3b82f6, var(--presu-blue-deep)) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 10px rgba(29, 78, 216, 0.35) !important;
}
body.tool-page .btn-primary:hover:not(:disabled) {
  background: linear-gradient(180deg, #60a5fa, var(--presu-blue)) !important;
}
/* brand tile — blue jewel, on every page */
.px-brand-icon {
  background: linear-gradient(135deg, #3b82f6, var(--presu-blue-deep));
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.4);
}
.px-brand-icon svg {
  color: #ffffff;
}
.px-brand-name::after {
  content: ".";
  color: var(--presu-gold-deep);
}
.px-brand-name-dot-home-unused {
  color: var(--presu-gold-hi);
}

/* ────────────────────────────────────────────────────────────
   3 · HERO — royal blue gradient, white + gold type
   ──────────────────────────────────────────────────────────── */
body:not(.tool-page) .px-hero {
  position: relative;
  background: linear-gradient(128deg, #123c82 0%, #1c5cb4 48%, #2f7fd9 100%);
  overflow: hidden;
}
/* faint diagonal streaks + top-right glow, like the reference */
body:not(.tool-page) .px-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(115deg,
      rgba(255, 255, 255, 0.035) 0 2px,
      transparent 2px 110px),
    radial-gradient(720px 420px at 85% 0%, rgba(120, 180, 255, 0.25), transparent 70%);
}
.px-hero-layout {
  position: relative;
  z-index: 1;
}
body:not(.tool-page) .px-hero-h1 {
  color: #ffffff;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
body:not(.tool-page) .px-hero-h1 .uw {
  font-family: "Fraunces", Georgia, "Times New Roman", serif;
  font-style: italic;
  font-weight: 600;
  padding-right: 0.06em;
  color: var(--presu-gold-hi);
  background: linear-gradient(115deg, #ffdd66, var(--presu-gold), #f4a915);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
body:not(.tool-page) .px-hero-sub {
  color: #d9e6fa;
}
/* eyebrow pill */
body:not(.tool-page) .px-hero-eyebrow {
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(10, 30, 64, 0.45);
  border-radius: 9999px;
  padding: 6px 14px;
}
body:not(.tool-page) .px-eyebrow-text {
  color: #dfeafc;
}
body:not(.tool-page) .px-eyebrow-text strong {
  color: var(--presu-gold-hi);
}
body:not(.tool-page) .px-eyebrow-dot {
  background: var(--presu-gold-hi);
  box-shadow: 0 0 10px 1px rgba(255, 210, 63, 0.75);
}
/* proof row */
body:not(.tool-page) .px-hero-proof-item {
  color: #e7f0fe;
}
body:not(.tool-page) .px-hero-proof-item svg {
  color: var(--presu-gold-hi);
}
/* floating badges — bright glass chips */
body:not(.tool-page) .px-float-badge {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.6);
  color: #16305e;
  border-radius: 9999px;
  box-shadow: 0 10px 30px -10px rgba(9, 30, 66, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
/* hero mini-cards — frosted glass on blue */
body:not(.tool-page) .px-hero-card {
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.25s, box-shadow 0.25s, background 0.25s;
}
body:not(.tool-page) .px-hero-card .px-hc-name {
  color: #ffffff;
}
body:not(.tool-page) .px-hero-card .px-hc-desc {
  color: #c6daf6;
}
body:not(.tool-page) .px-hero-card:hover {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 210, 63, 0.65);
  box-shadow: 0 16px 38px -14px rgba(9, 30, 66, 0.55);
}
body:not(.tool-page) .px-hero-card .px-hc-icon {
  background: rgba(255, 255, 255, 0.92);
}
/* outline button sits on the gradient */
body:not(.tool-page) .px-btn-outline {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.45);
}
body:not(.tool-page) .px-btn-outline:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #ffffff;
  color: #ffffff;
}

/* golden CTA shine sweep */
.px-btn-accent {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
}
.px-btn-accent::after {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  transform: skewX(-20deg);
  animation: presu-shine 5s ease-in-out infinite;
}
@keyframes presu-shine {
  0%, 65% { transform: translateX(0) skewX(-20deg); }
  90%, 100% { transform: translateX(480%) skewX(-20deg); }
}

/* ────────────────────────────────────────────────────────────
   4 · STATS BAND — navy with golden numerals (both themes)
   ──────────────────────────────────────────────────────────── */
body:not(.tool-page) .px-stats {
  background: linear-gradient(180deg, #16336a, var(--presu-navy-deep));
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}
body:not(.tool-page) .px-stat-num {
  color: #ffffff;
  font-variant-numeric: tabular-nums;
}
body:not(.tool-page) .px-stat-num .acc {
  color: var(--presu-gold-hi);
}
body:not(.tool-page) .px-stat-label {
  color: #9db3d9;
}

/* ────────────────────────────────────────────────────────────
   5 · TOOL CARDS (homepage grid) — lift + blue glow
   ──────────────────────────────────────────────────────────── */
.px-tool-card {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.25s, box-shadow 0.25s, background 0.25s;
}
.px-tool-card:hover {
  transform: translateY(-4px);
  border-color: rgba(37, 99, 235, 0.45);
  box-shadow: 0 18px 44px -16px rgba(29, 78, 216, 0.3);
}
.px-tool-card:hover .px-tc-arrow {
  background: rgba(37, 99, 235, 0.12);
  color: var(--presu-blue);
}

/* ────────────────────────────────────────────────────────────
   6 · FOOTER — navy band, high-contrast text (all pages)
   ──────────────────────────────────────────────────────────── */
.px-footer {
  background: linear-gradient(180deg, #16336a, var(--presu-navy-deep));
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
/* brand tile in the footer — same blue jewel as the header */
.px-footer-brand-icon {
  background: linear-gradient(135deg, #3b82f6, var(--presu-blue-deep)) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}
.px-footer-brand-icon svg {
  color: #ffffff;
}
.px-footer-brand-name {
  color: #ffffff;
}
.px-footer-brand-name::after {
  content: ".";
  color: var(--presu-gold-hi);
}
.px-footer-brand-desc {
  color: #b8c9e8;
}
.px-footer-brand-tag {
  color: #d6e2f7;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.05);
}
.px-footer-col-label {
  color: var(--presu-gold-hi);
}
.px-footer-link {
  color: #c3d2ec;
}
.px-footer-link:hover {
  color: #ffffff;
}
.px-footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.px-footer-copy {
  color: #9db3d9;
}
.px-footer-bottom-link {
  color: #c3d2ec;
}
.px-footer-bottom-link:hover {
  color: #ffffff;
}

/* tool-page compact footer — same navy treatment */
.t-footer {
  background: linear-gradient(180deg, #16336a, var(--presu-navy-deep)) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}
.t-footer-brand {
  color: #ffffff !important;
}
.t-footer-brand svg {
  color: var(--presu-gold-hi);
}
.t-footer-tagline {
  color: #9db3d9 !important;
}
.t-footer-link {
  color: #c3d2ec !important;
}
.t-footer-link:hover {
  color: #ffffff !important;
}

/* ────────────────────────────────────────────────────────────
   6b · TOOL POLISH — pro finish for all 44 tools
   (layout untouched; surfaces, inputs, type and motion refined)
   ──────────────────────────────────────────────────────────── */

/* cards: softer, elevated, roomier */
body.tool-page .card {
  border-radius: 16px !important;
  padding: 24px !important;
  box-shadow: 0 1px 2px rgba(18, 41, 79, 0.04),
    0 12px 32px -16px rgba(18, 41, 79, 0.12) !important;
}

/* section titles: golden kicker bar + spaced caps */
body.tool-page .card-title {
  font-size: 0.7rem !important;
  font-weight: 800 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.1em !important;
  color: #53658c !important;
  display: flex;
  align-items: center;
  gap: 8px;
}
body.tool-page .card-title::before {
  content: "";
  width: 16px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--presu-gold), var(--presu-blue));
  flex: none;
}

/* labels: quiet, consistent */
body.tool-page .control-label {
  font-size: 0.72rem !important;
  font-weight: 600 !important;
  color: #3d5178 !important;
  margin-bottom: 6px !important;
}

/* inputs: white field, crisp border, generous focus ring */
body.tool-page select,
body.tool-page textarea,
body.tool-page input:not([type]),
body.tool-page input[type="text"],
body.tool-page input[type="number"],
body.tool-page input[type="date"],
body.tool-page input[type="month"],
body.tool-page input[type="datetime-local"],
body.tool-page input[type="email"],
body.tool-page input[type="tel"],
body.tool-page input[type="url"] {
  background: #ffffff !important;
  border: 1px solid #c7d5ec !important;
  border-radius: 10px !important;
  padding: 9px 12px !important;
  transition: border-color 0.15s, box-shadow 0.15s !important;
}
body.tool-page select:hover,
body.tool-page textarea:hover,
body.tool-page input:hover {
  border-color: #9db6de !important;
}
body.tool-page select:focus,
body.tool-page textarea:focus,
body.tool-page input:focus {
  border-color: var(--presu-blue) !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14) !important;
}

/* buttons: consistent height, subtle lift on hover */
body.tool-page .btn {
  border-radius: 10px !important;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s !important;
}
body.tool-page .btn:hover:not(:disabled) {
  transform: translateY(-1px);
}
body.tool-page .btn-secondary {
  background: #ffffff !important;
  border: 1px solid #c7d5ec !important;
  color: #29416d !important;
}
body.tool-page .btn-secondary:hover:not(:disabled) {
  border-color: var(--presu-blue) !important;
  color: var(--presu-blue-deep) !important;
}

/* dividers breathe more */
body.tool-page .divider {
  margin: 20px 0 !important;
}

/* radio groups → clean segmented pills */
body.tool-page .u-radio-group,
body.tool-page .u-check-group {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px;
}
body.tool-page .u-radio,
body.tool-page .u-check {
  border: 1px solid #c7d5ec;
  background: #ffffff;
  border-radius: 9999px;
  padding: 7px 14px;
  font-weight: 600;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
body.tool-page .u-radio input,
body.tool-page .u-check input {
  width: auto !important;
  margin: 0;
  accent-color: var(--presu-blue);
}
body.tool-page .u-radio:hover,
body.tool-page .u-check:hover {
  border-color: #9db6de;
}
body.tool-page .u-radio:has(input:checked),
body.tool-page .u-check:has(input:checked) {
  border-color: var(--presu-blue);
  background: rgba(37, 99, 235, 0.07);
  color: var(--presu-blue-deep);
}

/* pen-color swatches: visible ring + clear active state */
body.tool-page .u-color-swatch {
  border: 2px solid rgba(18, 41, 79, 0.15);
  box-shadow: inset 0 0 0 2px #ffffff;
}
body.tool-page .u-color-swatch:hover {
  border-color: #9db6de;
}
body.tool-page .u-color-swatch.active {
  border-color: var(--presu-blue);
  box-shadow: inset 0 0 0 2px #ffffff, 0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* the document preview reads as real paper on a desk */
body.tool-page .invoice-preview-shell {
  background:
    radial-gradient(rgba(18, 41, 79, 0.05) 1px, transparent 1px) 0 0 / 14px 14px,
    #e9f0fa;
  border-radius: 14px;
  padding: 18px;
}
body.tool-page .inv-doc {
  border-radius: 4px;
  box-shadow:
    0 1px 2px rgba(18, 41, 79, 0.1),
    0 12px 30px -10px rgba(18, 41, 79, 0.25),
    0 30px 60px -30px rgba(18, 41, 79, 0.2);
}

/* numbers align in tables */
body.tool-page table,
body.tool-page .inv-doc {
  font-variant-numeric: tabular-nums;
}

@media (prefers-reduced-motion: reduce) {
  body.tool-page .btn:hover:not(:disabled) {
    transform: none;
  }
}

/* ────────────────────────────────────────────────────────────
   7 · AD SLOTS — hidden while empty (placeholders only).
   When real ad code is added in config/ads.js, delete this
   block so the slots become visible again.
   ──────────────────────────────────────────────────────────── */
body:not(.presu-ads-on) .t-banner-ad-slot,
body:not(.presu-ads-on) .px-ad-banner,
body:not(.presu-ads-on) .px-sidebar-ad,
body:not(.presu-ads-on) .px-compact-ad,
body:not(.presu-ads-on) .px-index-ad-wrap,
body:not(.presu-ads-on) #sidebarAdInject,
body:not(.presu-ads-on) #bannerAdInject {
  display: none !important;
}

/* ────────────────────────────────────────────────────────────
   7b · MOBILE MENU — white app sheet (hard-coded colors so no
   theme/cache state can ever turn it dark)
   ──────────────────────────────────────────────────────────── */
.px-mobile-nav,
[data-theme] .px-mobile-nav {
  background: #ffffff !important;
  border-bottom: none !important;
  box-shadow: none !important;
  padding: 14px 16px 60px !important;
  overflow-y: auto;
}
.px-mobile-nav-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.px-mobile-section,
[data-theme] .px-mobile-section {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 2px 2px !important;
  font-size: 0.65rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase;
  color: #53658c !important;
}
.px-mobile-section::before {
  content: "";
  width: 14px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--presu-gold), var(--presu-blue));
  flex: none;
}
.px-mobile-section::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e2ebf7;
}
.px-mobile-link,
[data-theme] .px-mobile-link {
  display: block;
  color: #1b2b4b !important;
  background: #f4f8fe !important;
  border: 1px solid #e2ebf7 !important;
  border-radius: 12px !important;
  padding: 12px 12px !important;
  margin: 0 !important;
  font-size: 0.82rem !important;
  font-weight: 600 !important;
  line-height: 1.3;
}
.px-mobile-link:active,
.px-mobile-link:hover {
  background: #e8f0fc !important;
  border-color: rgba(37, 99, 235, 0.35) !important;
  color: var(--presu-blue-deep) !important;
}

/* ────────────────────────────────────────────────────────────
   8 · MOBILE — preview first + scaled paper (no inner scroll)
   ──────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  /* the preview/results card lives ONLY behind the Preview button:
     hidden while in the normal flow, visible inside the overlay */
  body.tool-page .tool-grid > .presu-preview-card {
    display: none !important;
  }
  /* no inner scrollbox: the scaled paper fits the width */
  body.tool-page .invoice-preview-shell {
    max-height: none !important;
    overflow: hidden !important;
    padding: 8px !important;
  }
  /* line-item rows: description gets its own full line */
  body.tool-page #lineItems > div {
    flex-wrap: wrap;
    row-gap: 6px;
  }
  body.tool-page #lineItems > div > input:first-child,
  body.tool-page #lineItems .li-desc {
    flex: 1 1 100%;
    min-width: 100%;
  }
}

/* ────────────────────────────────────────────────────────────
   9 · MOBILE PREVIEW BUTTON + FULL-SCREEN OVERLAY (all tools)
   ──────────────────────────────────────────────────────────── */
.presu-pv-btn {
  display: none;
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  z-index: 850;
  padding: 15px;
  border: none;
  border-radius: 14px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 800;
  color: #142a52;
  background: linear-gradient(180deg, var(--presu-gold-hi), var(--presu-gold-deep));
  box-shadow: 0 10px 28px rgba(9, 30, 66, 0.4);
  cursor: pointer;
}
.presu-ov {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 900;
  background: #eef4fc;
  flex-direction: column;
}
.presu-ov-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: linear-gradient(180deg, #16336a, var(--presu-navy));
  color: #ffffff;
  font-weight: 800;
  font-size: 0.95rem;
  flex: none;
}
.presu-ov-close {
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 9px 16px;
  border-radius: 9999px;
  cursor: pointer;
}
.presu-ov-body {
  flex: 1;
  overflow-y: auto;
  padding: 10px 8px 24px;
}
.presu-ov-body .card {
  margin: 0 !important;
}
/* document previews: bare sheet, no frames — the paper IS the view */
.presu-ov-body .card:has(.invoice-preview-shell) {
  padding: 0 !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  border-radius: 0 !important;
}
.presu-ov-body .card:has(.invoice-preview-shell) .card-title {
  display: none !important;
}
.presu-ov-body .invoice-preview-shell {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
  max-height: none !important;
}
.presu-ov-body .inv-doc {
  box-shadow: 0 2px 16px rgba(9, 30, 66, 0.2);
}
@media (max-width: 768px) {
  body.presu-has-pvbtn .presu-pv-btn {
    display: block;
  }
  body.presu-ov-open .presu-ov {
    display: flex;
  }
  body.presu-ov-open {
    overflow: hidden;
  }
  body.presu-ov-open .presu-pv-btn {
    display: none;
  }
  /* room so the button never covers the last field or the footer */
  body.presu-has-pvbtn .t-content {
    padding-bottom: 24px !important;
  }
  body.presu-has-pvbtn .t-footer {
    padding-bottom: 96px !important;
  }
  /* tool footer: tidy stacked layout on phones */
  body.tool-page .t-footer-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  body.tool-page .t-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
  }
}

/* ────────────────────────────────────────────────────────────
   10 · MY DOCUMENTS — save/load bar at the top of each tool
   ──────────────────────────────────────────────────────────── */
.presu-docs-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px dashed #c7d5ec;
}
.presu-docs-bar button {
  flex: 1;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 10px 8px;
  border-radius: 10px;
  cursor: pointer;
}
.presu-docs-save {
  border: none;
  background: linear-gradient(180deg, var(--presu-gold-hi), var(--presu-gold-deep));
  color: #142a52;
}
.presu-docs-list-btn {
  border: 1px solid #c7d5ec;
  background: #ffffff;
  color: #29416d;
}
.presu-docs-namerow {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}
.presu-docs-nameinput {
  flex: 1;
}
.presu-docs-nameok {
  border: none;
  background: linear-gradient(180deg, #3b82f6, var(--presu-blue-deep));
  color: #ffffff;
  font-weight: 800;
  padding: 0 18px;
  border-radius: 10px;
  cursor: pointer;
}
.presu-docs-panel {
  margin-bottom: 14px;
  border: 1px solid #d5e1f1;
  border-radius: 12px;
  background: #f8fbff;
  padding: 6px;
  max-height: 240px;
  overflow-y: auto;
}
.presu-docs-empty {
  font-size: 0.8rem;
  color: #8494b4;
  padding: 12px;
  text-align: center;
}
.presu-docs-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 8px;
}
.presu-docs-row:hover {
  background: #eef4fc;
}
.presu-docs-name {
  flex: 1;
  font-size: 0.8rem;
  font-weight: 600;
  color: #1b2b4b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.presu-docs-when {
  font-size: 0.68rem;
  color: #8494b4;
  flex: none;
}
.presu-docs-load {
  border: 1px solid rgba(37, 99, 235, 0.35);
  background: rgba(37, 99, 235, 0.08);
  color: var(--presu-blue-deep);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 8px;
  cursor: pointer;
}
.presu-docs-del {
  border: none;
  background: transparent;
  color: #b91c1c;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 4px 6px;
}

/* respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .px-btn-accent::after {
    animation: none;
  }
  .px-tool-card,
  .px-hero-card {
    transition: none;
  }
}
