/* RicambiPro customer workspace — light editorial direction.
   Shared business rules, data, visibility states and handlers are unchanged. */
#page-app {
  --client-ink: #202226; --client-muted: #656a73; --client-line: #e7e9ed;
  font-family: 'Segoe UI', Arial, sans-serif; --client-accent: var(--gold); background: #f6f7f9; color: var(--client-ink); min-height: 100vh;
}
#page-app .header { background: #fff; border: 0; border-bottom: 1px solid var(--client-line); border-image: none; padding: 12px 0; box-shadow: none; backdrop-filter: none; }
#page-app .header-inner { gap: 14px; min-width: 0; }
#page-app .brand { gap: 9px; padding: 0; background: transparent; color: var(--client-ink); text-align: left; }
#page-app .header .brand-logo { width: 36px; height: 36px; }
#page-app .brand-name { color: var(--client-ink); font-size: 20px; font-weight: 700; letter-spacing: -.65px; }
#page-app .brand-name .pro { color: var(--gold-deep); }
#page-app .brand-tag { color: var(--client-muted); font-size: 8px; letter-spacing: 1px; }
#page-app .header-nav { gap: 5px; min-width: 0; }
#page-app .client-nav-section { display: none; }
#page-app .nav-btn { min-height: 44px; padding: 10px; font-size: 13px; font-weight: 500; gap: 8px; color: #5e646e; border: 1px solid transparent; border-radius: 9px; white-space: nowrap; box-shadow: none; transform: none; }
#page-app .nav-btn .ico { width: 17px; height: 17px; flex-shrink: 0; }
#page-app .nav-btn:hover { background: #f7f8fa; color: var(--client-ink); }
#page-app .nav-btn.active { color: #684500; background: #fff4d8; border-color: #ffde8a; box-shadow: none; font-weight: 650; }
#page-app #nav-promotions::before, #page-app #nav-promotions::after { display: none; }
#page-app #nav-promotions { animation: none; background: transparent; border-image: none; border-color: transparent; box-shadow: none; color: #5e646e; }
#page-app #nav-promotions:hover { background: #f7f8fa; color: var(--client-ink); }
#page-app #nav-promotions.active { color: #684500; background: #fff4d8; border-color: #ffde8a; }
#page-app .nav-btn .badge { background: var(--gold); color: #202226; font-family: inherit; min-width: 21px; padding: 1px 5px; font-size: 11px; box-shadow: none; }
#page-app .user-chip { min-width: 0; gap: 8px; padding: 6px 0 6px 12px; border: 0; border-left: 1px solid var(--client-line); border-radius: 0; background: transparent; box-shadow: none; font-size: 12px; flex-shrink: 1; }
#page-app #header-customer-name { max-width: 112px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#page-app .user-chip .points { padding: 4px 8px; background: #fff1cc; color: #795100; font-size: 11px; white-space: nowrap; box-shadow: none; flex-shrink: 0; }
#page-app .user-logout-btn { min-height: 36px; padding: 6px 8px; font-size: 12px; white-space: nowrap; border-color: #d6dae1; background: #fff; color: #626873; flex-shrink: 0; }
#page-app #header-points-pending { max-width: 90px; white-space: normal !important; }
#page-app .client-menu-toggle { display: none; }
#page-app .client-menu-toggle[hidden] { display: none !important; }
#page-app .brand:focus-visible, #page-app .nav-btn:focus-visible, #page-app .client-menu-toggle:focus-visible,
#page-app .vetrina-cta:focus-visible, #page-app .home-search-shortcuts button:focus-visible { outline: 3px solid #996b00; outline-offset: 3px; }

/* A restrained type scale and a clear working surface. */
#page-app .main { min-width: 0; padding-top: 28px; }
#page-app .home-hero { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 6px 20px; margin: 0 0 22px; padding: 0; }
#page-app .home-hero h1 { font-size: 20px; line-height: 1.25; font-weight: 500; letter-spacing: -.3px; color: var(--client-ink); }
#page-app .home-hero p { font-size: 12px; margin: 0; color: var(--client-muted); }
#page-app .home-workspace { margin-bottom: 34px !important; }
#page-app .home-search-card { position: relative; isolation: isolate; padding: 28px 32px 22px; border: 1px solid #e5e6e9; border-radius: 16px; background: linear-gradient(115deg, #fff 52%, #faf8f2 100%); box-shadow: 0 8px 28px rgba(29,35,50,.035); overflow: hidden; }
#page-app .home-search-card::after { display: none; }
#page-app .home-search-card .hsc-head { position: relative; z-index: 1; display: block; width: 63%; margin: 0 0 22px; }
#page-app .home-search-card .hsc-ico { display: none; }
#page-app .home-search-card h2 { font-size: 28px; font-weight: 600; line-height: 1.25; letter-spacing: -.4px; color: var(--client-ink); margin: 0 0 14px; }
#page-app .home-search-card h2 .gold { color: var(--client-ink); background: none; }
#page-app .home-search-card .hsc-sub { color: var(--client-muted); font-size: 13px; line-height: 1.6; max-width: 410px; }
#page-app .home-workshop-visual { position: relative; display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: contain; border-radius: 0; mix-blend-mode: multiply; }
#page-app .home-search-row { position: relative; z-index: 1; width: 64%; gap: 6px; padding: 5px; background: #fff; border: 1px solid #d7dce3; border-radius: 12px; box-shadow: 0 5px 16px rgba(35,41,53,.04); }
#page-app .home-search-row input { min-width: 0; height: 48px; padding: 0 8px 0 40px; font-family: inherit; font-size: 14px; border: 0; border-radius: 8px; background: transparent; color: var(--client-ink); box-shadow: none; }
#page-app .home-search-row button, #page-app .search-btn { min-height: 50px; height: 50px; padding: 0 24px; border-radius: 8px; background: var(--gold); color: #262117; font-size: 14px; font-weight: 650; letter-spacing: 0; box-shadow: none; transform: none; }
#page-app .home-search-row button:hover, #page-app .search-btn:hover { background: #ffc13c; box-shadow: none; transform: none; }
#page-app .home-search-row button::after, #page-app .search-btn::after { display: none; }
#page-app .home-search-row input:focus, #page-app .search-input:focus { outline: 2px solid #b67b00; outline-offset: 1px; border-color: #b67b00; }
#page-app .home-search-shortcuts { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 12px; width: 64%; }
#page-app .home-search-shortcuts button { display: inline-flex; align-items: center; gap: 7px; min-height: 40px; padding: 4px 0; background: transparent; color: #575e69; font-size: 11px; font-weight: 500; }
#page-app .home-search-shortcuts button:hover { color: #865900; }
#page-app .home-search-shortcuts button > span { color: #9a6c00; }
#page-app .home-search-shortcuts button .ico { color: #8c939d; }


#page-app .home-visual-stage { position: absolute; z-index: 0; inset: 8px 24px 12px auto; width: 30%; display: flex; align-items: center; pointer-events: none; mix-blend-mode: multiply; }
#page-app .home-search-symbol { position: absolute; top: 21px; left: 18px; width: 18px; height: 18px; color: #7c838c; pointer-events: none; }
#page-app .home-search-row:focus-within { border-color: #b88927; outline: 2px solid #b67b00; outline-offset: 2px; box-shadow: none; }
#page-app .home-search-row input:focus { outline: none; }
#page-app .home-search-row button { height: 48px; min-height: 48px; padding: 0 18px; font-size: 12px; border-radius: 9px; }

/* Promotional content uses the existing list and its existing order. */
#page-app #home-promos-vetrina h2 { color: var(--client-ink) !important; font-size: 22px !important; font-weight: 600 !important; letter-spacing: -.3px !important; }
#page-app #home-promos-vetrina .pill-gold { color: #687064; background: #fff; border-color: #e2e6de; font-size: 10px !important; font-weight: 500; box-shadow: none; }
#page-app .online-dot { animation: none; box-shadow: none; }
#page-app .vetrina-cta { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 8px 0; color: #795300; background: transparent; border: 0; box-shadow: none; font-size: 12px; font-weight: 600; }
#page-app .promo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(270px, 100%), 1fr)); gap: 20px; }
#page-app .promo-card { border: 1px solid var(--client-line) !important; border-radius: 18px !important; background: #fff !important; box-shadow: 0 3px 10px rgba(23,33,46,.025) !important; transform: none; }
#page-app .promo-card:hover { border-color: #d0d5de !important; box-shadow: 0 7px 18px rgba(23,33,46,.06) !important; transform: none; }
#page-app .promo-card .promo-card-media { min-width: 0; width: 100%; min-height: 0 !important; aspect-ratio: 4 / 3; background: #fff !important; }
#page-app .promo-card .promo-img { object-fit: contain; background: #fff !important; transform: none; }
#page-app .promo-card:hover .promo-img { transform: none; }
#page-app .promo-card .promo-card-body { min-width: 0; display: flex; padding: 20px 22px !important; gap: 8px !important; border-top: 1px solid #edf0f3 !important; }
#page-app .promo-card .pc-title { font-size: 16px; font-weight: 650; line-height: 1.4; letter-spacing: -.2px; color: var(--client-ink); min-height: 44px; }
#page-app .promo-card .pc-desc { font-size: 12px; line-height: 1.5; color: var(--client-muted); min-height: 36px; }
#page-app .promo-total-label { color: #757b85; font-size: 10px; font-weight: 500; line-height: 1.4; margin-top: 8px; }
#page-app .promo-price-zone { margin: 0; min-height: 34px; }
#page-app .promo-price-zone > span { color: var(--client-ink) !important; font: 600 27px/1.2 'Segoe UI',Arial,sans-serif !important; letter-spacing: -.5px !important; font-variant-numeric: tabular-nums !important; }
#page-app .promo-unit-line { color: #656b75; font-size: 12px; line-height: 1.4; }
#page-app .promo-meta { min-height: 36px; gap: 6px; align-content: start; }
#page-app .promo-meta > span { font-size: 11px !important; font-weight: 500 !important; }
#page-app .promo-card .promo-cta { min-height: 42px; padding: 10px 13px !important; border: 1px solid #e0e3e9 !important; border-radius: 8px !important; background: #fff !important; color: #3e4652 !important; font: 600 12px/1.4 'Segoe UI',Arial,sans-serif !important; box-shadow: none !important; transform: none; }
#page-app .promo-card .promo-cta:hover { color: #684500 !important; background: #fff5dc !important; border-color: #edcc7e !important; }
#page-app .promo-card .promo-cta::after { display: none; }
#page-app .promo-card .promo-media-badge { padding: 4px 8px !important; box-shadow: none !important; font-family: inherit !important; font-size: 10px !important; font-weight: 650 !important; }
#page-app .promo-card .promo-media-featured { color: #694900 !important; background: #fff0c4 !important; }
#page-app .promo-cat-grid { gap: 20px; }
#page-app .promo-cat-card { border: 1px solid var(--client-line); border-radius: 14px; box-shadow: none; transform: none; }
#page-app .home-benefits { display: grid; gap: 20px; margin: 32px 0 10px; padding: 26px 0; border-top: 1px solid var(--client-line); border-bottom: 1px solid var(--client-line); }
#page-app .home-benefits .hb { background: transparent; border: 0; box-shadow: none; padding: 0; }
#page-app .home-benefits .hb-ico { color: #8f6200; background: #fff2d0; border-radius: 12px; width: 42px; height: 42px; }
#page-app .home-benefits .hb strong { font-size: 12px; font-weight: 600; }
#page-app .home-benefits .hb span { font-size: 11px; }
#page-app .footer { margin-top: 24px; padding: 24px 32px; background: #fff; border-top: 1px solid var(--client-line); }

/* Related customer screens follow the same light surfaces. */
#page-app .page-title { font-size: 28px; font-weight: 650; letter-spacing: -.75px; margin-bottom: 20px; }
#page-app .page-title .accent-bar { width: 4px; border-radius: 2px; background: var(--gold); box-shadow: none; }
#page-app .search-hero { background: #fff; border: 1px solid var(--client-line); border-radius: 18px; padding: 28px 30px; box-shadow: none; }
#page-app .search-hero::before { display: none; }
#page-app .search-hero .hsc-head { gap: 14px; }
#page-app .search-hero .hsc-ico { display: flex; width: 44px; height: 44px; background: #fff4d8; color: #8f6200; border-radius: 12px; box-shadow: none; }
#page-app .search-hero h2, #page-app .search-hero h2 span { color: var(--client-ink) !important; font-size: 26px; font-weight: 650; letter-spacing: -.6px; }
#page-app .search-hero p { color: var(--client-muted); font-size: 13px; }
#page-app .search-box { background: #f7f8fa; border: 1px solid #d9dde4; padding: 6px; border-radius: 11px; box-shadow: none; }
#page-app .search-input { min-width: 0; font-family: inherit; font-size: 16px; height: 50px; background: transparent; border: 0; border-radius: 7px; padding: 0 14px; box-shadow: none; }
#page-app .search-warning { background: #fffbf1; border: 1px solid #efe3c5; }
#page-app .result-card { border: 1px solid var(--client-line); border-radius: 12px; box-shadow: none; }
#page-app .rma-card, #page-app .rma-empty { background: #fff; border: 1px solid var(--client-line); border-radius: 14px; box-shadow: none; }

@media (min-width: 1100px) {
  #page-app .header { position: fixed; inset: 0 auto 0 0; width: 224px; height: 100dvh; padding: 28px 0 24px; overflow-y: auto; border: 0; border-right: 1px solid var(--client-line); z-index: 100; }
  #page-app .header-inner { min-height: 100%; max-width: none; margin: 0; padding: 0 18px; display: flex; flex-direction: column; flex-wrap: nowrap; align-items: stretch; justify-content: flex-start; gap: 28px; }
  #page-app .brand { justify-content: flex-start; }
  #page-app .header .brand-logo { width: 34px; height: 34px; }
  #page-app .brand-tag { font-size: 9px; }
  #page-app .header-nav { order: 0; display: flex; flex-direction: column; align-items: stretch; flex-wrap: nowrap; width: 100%; gap: 4px; padding: 0; border: 0; margin: 0; }
  #page-app .client-nav-section { display: block; color: #8a8f98; font-size: 10px; font-weight: 500; letter-spacing: 1px; padding: 7px 12px 8px; }
  #page-app .client-nav-section-services { margin-top: 16px; }
  #page-app .nav-btn { width: 100%; min-height: 44px; justify-content: flex-start; padding: 11px 12px; gap: 12px; font-size: 12px; }
  #page-app .nav-btn .badge { margin-left: auto; }
  #page-app .user-chip { display: grid; grid-template-columns: 1fr auto; gap: 10px 6px; margin: auto 0 0; padding: 16px 10px 10px; border: 0; border-top: 1px solid var(--client-line); border-radius: 0; flex-shrink: 0; }
  #page-app #header-customer-name { grid-column: 1 / -1; max-width: 166px; font-size: 12px; }
  #page-app .user-chip .points { justify-self: start; }
  #page-app #header-points-pending { grid-column: 1 / -1; max-width: 166px; }
  #page-app .main { max-width: none; width: auto; margin: 0 0 0 224px; padding: 28px 32px 32px; }
  #page-app .footer { margin-left: 224px; }
  #page-app .promo-grid-home { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1250px) {
  #page-app .promo-grid-home { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 700px) and (max-width: 1099px) {
  #page-app .header-inner { flex-wrap: wrap; }
  #page-app .brand-text { display: flex; }
  #page-app .header-nav { order: 3; width: 100%; display: flex; flex-wrap: wrap; justify-content: flex-start; border: 0; padding: 0; margin: 0; }
  #page-app .user-chip { margin-left: auto; }
}
@media (max-width: 900px) {
  #page-app .home-workspace { grid-template-columns: 1fr !important; }
  #page-app .home-benefits { grid-template-columns: 1fr; }
}
@media (max-width: 699px) {
  #page-app .header { padding: 10px 0 8px; }
  #page-app .header-inner { padding: 0 16px; flex-wrap: wrap; gap: 8px 10px; }
  #page-app .header .brand-logo { width: 32px; height: 32px; }
  #page-app .brand-text { display: flex; }
  #page-app .brand-name { font-size: 18px; }
  #page-app .brand-tag { font-size: 8px; }
  #page-app .user-chip { display: grid; grid-template-columns: auto auto; gap: 1px 6px; margin-left: auto; max-width: 160px; padding: 0; border: 0; }
  #page-app #header-customer-name { grid-column: 1 / -1; max-width: 155px; font-size: 11px; text-align: right; }
  #page-app .user-chip .points { justify-self: end; font-size: 10px; padding: 2px 5px; }
  #page-app .user-logout-btn { min-height: 29px; padding: 3px 5px; font-size: 11px; }
  #page-app #header-points-pending { grid-column: 1 / -1; max-width: none; font-size: 10px !important; text-align: right; }
  #page-app .header-nav { order: 3; width: 100%; display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-start; border: 0; padding: 0; margin: 0; }
  #page-app .nav-btn { flex: 1 0 auto; min-height: 42px; padding: 8px 4px; gap: 4px; font-size: 11px; justify-content: center; }
  #page-app .nav-btn > span:not(.badge) { overflow: visible; max-width: none; text-overflow: clip; }
  #page-app .header-nav.client-menu-ready { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); }
  #page-app .client-menu-ready .client-menu-toggle { display: flex; align-items: center; justify-content: center; gap: 5px; min-height: 42px; padding: 8px 4px; border: 1px solid #d8dce3; border-radius: 9px; background: #fff; color: var(--client-ink); font: 600 12px 'Archivo',sans-serif; }
  #page-app .client-menu-ready:not(.client-menu-open) .client-nav-secondary { display: none; }
  #page-app .client-menu-ready.client-menu-open .client-nav-secondary { grid-column: span 2; white-space: normal; }
  #page-app .client-menu-toggle[aria-expanded="true"] { background: #fff4d8; border-color: #e4c576; }
  #page-app .main { padding: 22px 16px; }
  #page-app .home-hero { margin-bottom: 20px; }
  #page-app .home-hero h1 { font-size: 21px; }
  #page-app .home-search-card { padding: 24px 20px 18px; border-radius: 18px; background: linear-gradient(135deg, #fff 65%, #fffbf0); }
  #page-app .home-search-card .hsc-head { width: 100%; margin-bottom: 20px; }
  #page-app .home-visual-stage { display: none; }
  #page-app .home-search-card h2 { font-size: 24px; line-height: 1.25; letter-spacing: -.3px; margin-bottom: 10px; }
  #page-app .home-search-card .hsc-sub { font-size: 12px; line-height: 1.5; }
  #page-app .home-workshop-visual { height: 140px; object-fit: contain; }
  #page-app .home-search-row { width: 100%; flex-direction: column; gap: 6px; }
  #page-app .home-search-row input, #page-app .home-search-row button { height: 48px; min-height: 48px; width: 100%; flex: none; }
  #page-app .home-search-shortcuts { width: 100%; gap: 3px 14px; margin-top: 10px; }
  #page-app .home-search-shortcuts button { min-height: 44px; font-size: 11px; }
  #page-app .home-search-row input { font-size: 16px; }
  #page-app #home-promos-vetrina h2 { font-size: 21px !important; }
  #page-app .promo-grid { grid-template-columns: 1fr; gap: 18px; }
  #page-app .promo-card .pc-title, #page-app .promo-card .pc-desc { min-height: 0; }
  #page-app .search-hero { padding: 22px 18px; }
  #page-app .search-hero .hsc-ico { display: none; }
  #page-app .search-hero h2, #page-app .search-hero h2 span { font-size: 25px; }
}
@media (prefers-reduced-motion: reduce) {
  #page-app .nav-btn, #page-app .promo-card, #page-app .promo-img, #page-app .promo-cta, #page-app .home-search-row button { transition: none; }
}

/* Manual browsing. Without the enhancement class the full grid remains. */
#page-app button, #page-app input, #page-app select { font-family: inherit; }
#page-app .home-promo-heading { min-height: 44px; }
#page-app .home-promo-heading .vetrina-cta { margin-left: auto; }
#page-app .promo-rail-controls { display: flex; align-items: center; gap: 6px; }
#page-app .promo-rail-controls[hidden] { display: none !important; }
#page-app .promo-rail-controls button { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid #d9dde4; border-radius: 50%; background: #fff; color: #363e49; font: 500 20px/1 'Segoe UI',sans-serif; cursor: pointer; transition: background .16s, border-color .16s, transform .16s; }
#page-app .promo-rail-controls button:hover { background: #fff2cc; border-color: #dab865; }
#page-app .promo-rail-controls button:active { transform: scale(.94); }
#page-app .promo-rail-controls button[aria-disabled="true"] { color: #9299a3; background: #f7f8fa; cursor: default; }
#page-app .promo-rail-controls button:focus-visible, #page-app .client-rail-ready:focus-visible { outline: 2px solid #996b00; outline-offset: 3px; }
#page-app .promo-grid-home.client-rail-ready { display: flex; flex-wrap: nowrap; gap: 20px; overflow-x: auto; scroll-snap-type: x proximity; scroll-padding-inline: 2px; padding: 6px 2px 18px; scrollbar-width: thin; scrollbar-color: #d5c9af transparent; overscroll-behavior-x: contain; }
#page-app .client-rail-ready > .promo-card { flex: 0 0 calc((100% - 40px) / 3); min-width: 0; scroll-snap-align: start; transition: transform .18s, box-shadow .18s, border-color .18s; }
#page-app .client-rail-ready > .promo-card:only-child { flex-basis: min(100%, 420px); }
#page-app .client-rail-ready .promo-card-media { height: 195px; aspect-ratio: auto !important; }
#page-app .client-rail-ready .promo-card-body { padding: 18px !important; }
#page-app .client-rail-ready .pc-title { font-size: 16px; font-weight: 600; }
#page-app .home-search-row button, #page-app .home-search-shortcuts button .cta-arr, #page-app .promo-cta .cta-arr { transition: transform .16s, background .16s; }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  #page-app .client-rail-ready > .promo-card:hover { transform: translateY(-3px); box-shadow: 0 9px 24px rgba(23,33,46,.1) !important; }
  #page-app .promo-cta:hover .cta-arr, #page-app .home-search-row button:hover .cta-arr { display: inline-block; transform: translateX(3px); }
}
@media (min-width: 700px) and (max-width: 1249px) {
  #page-app .client-rail-ready > .promo-card { flex-basis: calc((100% - 20px) / 2); }
}
@media (max-width: 699px) {
  #page-app .client-rail-ready > .promo-card { flex-basis: calc(100% - 28px); }
  #page-app .home-promo-heading .vetrina-cta { order: 3; flex-basis: 100%; margin-left: 0; }
  #page-app .promo-rail-controls { margin-left: auto; }
}
@media (prefers-reduced-motion: reduce) {
  #page-app .client-rail-ready, #page-app .client-rail-ready > .promo-card, #page-app .promo-rail-controls button, #page-app .cta-arr { scroll-behavior: auto !important; transition: none !important; transform: none !important; }
}
