:root{
  --shell-nav-w: 238px;
  --shell-page-w: 1120px;
  --shell-hero-w: 1280px;
  --shell-bg: #eef4fa;
  --shell-panel: #ffffff;
  --shell-line: #d8e4f0;
  --shell-line-soft: #e6eef6;
  --shell-text: #16324f;
  --shell-muted: #6d8198;
  --shell-accent: #2155d6;
  --shell-accent-soft: #eef4ff;
  --shell-shadow: 0 16px 34px rgba(23, 50, 79, .08);
}

body.layout-shell-clean{
  background: linear-gradient(180deg, #f4f8fc 0%, #edf3f9 100%);
}

body.layout-shell-clean #proposalShellClean{
  display:grid;
  grid-template-columns: var(--shell-nav-w) minmax(0,1fr);
  min-height:100vh;
}

body.layout-shell-clean .proposalSidebar{
  position:sticky;
  top:0;
  height:100vh;
  width:var(--shell-nav-w);
  min-width:var(--shell-nav-w);
  max-width:var(--shell-nav-w);
  overflow:auto;
  border-right:1px solid var(--shell-line);
  background:#f7fbff;
}

body.layout-shell-clean .proposalSidebarInner{
  padding:18px 14px 22px;
}

body.layout-shell-clean .proposalBrand{
  border:1px solid var(--shell-line);
  background:#fff;
  border-radius:18px;
  padding:14px 14px 12px;
  margin-bottom:16px;
}
.proposalBrandEyebrow{ font-size:11px; letter-spacing:.12em; text-transform:uppercase; color:#7a8da3; font-weight:800; margin-bottom:6px; }
.proposalBrandTitle{ font-size:18px; font-weight:800; color:var(--shell-text); }

.proposalBrandLogo{
  display:block;
  width:100%;
  max-width:168px;
  height:auto;
  margin:0 0 10px;
}

.proposalNavGroup{ margin-bottom:18px; }
.proposalNavLabel{ margin:0 10px 8px; font-size:11px; letter-spacing:.12em; text-transform:uppercase; color:#7588a0; font-weight:800; }
.proposalNavBtn,
.proposalSubBtn,
.proposalActionBtn{
  width:100%;
  text-align:left;
  border:1px solid transparent;
  background:transparent;
  border-radius:16px;
  color:var(--shell-text);
  cursor:pointer;
  transition:background .14s ease, border-color .14s ease, color .14s ease;
}
.proposalNavBtn{ padding:11px 12px; font-size:14px; font-weight:800; }
.proposalSubList{ display:grid; gap:6px; margin-top:6px; }
.proposalSubBtn{ padding:9px 14px; font-size:13px; font-weight:700; color:#425a72; }
.proposalActionBtn{ padding:10px 12px; font-size:13px; font-weight:700; color:#425a72; }
.proposalNavBtn:hover,.proposalSubBtn:hover,.proposalActionBtn:hover{ background:#f8fbff; border-color:#d7e5fb; }
.proposalNavBtn.active,.proposalSubBtn.active,.proposalActionBtn.active{ background:var(--shell-accent-soft); border-color:#cbdcff; color:#124cb8; }
.proposalSidebarFooter{ margin-top:18px; padding-top:16px; border-top:1px solid var(--shell-line-soft); display:grid; gap:8px; }
.proposalAccountGroup{
  margin-top:18px;
  padding-top:16px;
  border-top:1px solid var(--shell-line-soft);
}
.proposalAccountIdentity{
  margin:0 10px 8px;
  overflow:hidden;
  color:#1c3551;
  font-size:13px;
  font-weight:800;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.proposalAccountLink{
  display:flex;
  align-items:center;
  color:#425a72;
  text-decoration:none;
}
.proposalAccountLogout{ color:#8a3441; }
.proposalAccountLink[hidden]{ display:none !important; }

body.layout-shell-clean #proposalMain{
  min-width:0;
  padding:0 28px 36px;
}

body.layout-shell-clean .wrap{
  max-width:none !important;
  margin:0;
  padding:14px 0 34px;
}

body.layout-shell-clean .topControls,
body.layout-shell-clean .startup-hint{
  display:none !important;
}

body.layout-shell-clean .heroHeader,
body.layout-shell-clean .proposalWorkspaceHeader,
body.layout-shell-clean .methodPanel,
body.layout-shell-clean .uxOverview,
body.layout-shell-clean .vinToggleBar,
body.layout-shell-clean #vinWrap,
body.layout-shell-clean #autoWorkspace,
body.layout-shell-clean .layoutFlow,
body.layout-shell-clean #decoderWorkspace,
body.layout-shell-clean #proposalHistoryPage,
body.layout-shell-clean #proposalExportPage{
  max-width:var(--shell-page-w);
  margin-left:auto;
  margin-right:auto;
}
body.layout-shell-clean .heroHeader{ width:min(100%, var(--shell-page-w)); max-width:var(--shell-page-w); margin:0 auto 18px; }
body.layout-shell-clean .heroBanner{ border-radius:24px; box-shadow:var(--shell-shadow); }
body.layout-shell-clean .heroInner{ padding:18px 22px; display:flex; align-items:center; justify-content:center; }
body.layout-shell-clean .heroTitle{ font-size:42px; line-height:1.06; text-align:center; margin:0 auto; }
body.layout-shell-clean .heroSubtitle{ font-size:17px; margin:6px auto 0; text-align:center; width:100%; }

.proposalWorkspaceHeader{ width:min(100%, var(--shell-page-w)); max-width:var(--shell-page-w); margin:0 auto 28px; }
.proposalHeaderCard{
  background:rgba(255,255,255,.92);
  border:1px solid var(--shell-line);
  border-radius:24px;
  box-shadow:var(--shell-shadow);
  padding:18px 26px 18px;
}
.proposalHeaderTop{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:16px;
}
.proposalWorkspaceTitle{
  margin:0;
  text-align:left;
  color:var(--shell-text);
  font-size:24px;
  line-height:1.12;
  font-weight:800;
}
.proposalHeaderSub{
  margin-top:14px;
}
.proposalWorkspaceMeta{
  display:flex;
  justify-content:flex-start;
  flex-wrap:wrap;
  gap:8px;
}
.proposalWorkspacePill{
  display:inline-flex;
  align-items:center;
  padding:7px 12px;
  border:1px solid #dbe7f4;
  border-radius:999px;
  background:#f8fbff;
  color:#35506d;
  font-size:13px;
  font-weight:700;
  cursor:pointer;
}
.proposalWorkspacePill.active{ background:var(--shell-accent-soft); color:#124cb8; border-color:#cbdcff; }
.proposalWorkspaceActions{
  justify-self:end;
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

body.layout-shell-clean .methodPanel,
body.layout-shell-clean .uxSummaryCard,
body.layout-shell-clean .uxMissingCard,
body.layout-shell-clean .workspaceCard,
body.layout-shell-clean .vinField,
body.layout-shell-clean .panelInputs,
body.layout-shell-clean .panelResult,
body.layout-shell-clean .proposalPageCard,
body.layout-shell-clean .workspacePanel{
  box-shadow:var(--shell-shadow) !important;
}
body.layout-shell-clean .methodPanel{ margin-bottom:20px; }
body.layout-shell-clean .uxOverview{ margin-bottom:18px; }
body.layout-shell-clean .vinToggleBar{ margin:16px auto 18px; }
body.layout-shell-clean #autoWorkspace{ margin-bottom:16px; }
body.layout-shell-clean .layoutFlow{ margin-top:0; }
body.layout-shell-clean .layoutFlow > .grid{ width:100%; max-width:var(--shell-page-w); margin:0 auto; }
body.layout-shell-clean .panelResult,
body.layout-shell-clean .panelInputs{ width:100% !important; }
body.layout-shell-clean .panelInputs .cardHeader,
body.layout-shell-clean .panelResult .cardHeader{ padding:18px 22px; }
body.layout-shell-clean .panelInputs .cardBody,
body.layout-shell-clean .panelResult .resultBox{ padding:18px 18px 20px; }

/* page visibility */
body.layout-shell-clean.page-history .methodPanel,
body.layout-shell-clean.page-history .uxOverview,
body.layout-shell-clean.page-history .vinToggleBar,
body.layout-shell-clean.page-history #vinWrap,
body.layout-shell-clean.page-history #autoWorkspace,
body.layout-shell-clean.page-history #decoderWorkspace,
body.layout-shell-clean.page-history .layoutFlow,
body.layout-shell-clean.page-export .methodPanel,
body.layout-shell-clean.page-export .uxOverview,
body.layout-shell-clean.page-export .vinToggleBar,
body.layout-shell-clean.page-export #vinWrap,
body.layout-shell-clean.page-export #autoWorkspace,
body.layout-shell-clean.page-export #decoderWorkspace,
body.layout-shell-clean.page-export .layoutFlow,
body.layout-shell-clean.page-decoder .methodPanel,
body.layout-shell-clean.page-decoder .uxOverview,
body.layout-shell-clean.page-decoder .vinToggleBar,
body.layout-shell-clean.page-decoder #vinWrap,
body.layout-shell-clean.page-decoder #autoWorkspace,
body.layout-shell-clean.page-decoder .layoutFlow,
body.layout-shell-clean.page-calc #proposalHistoryPage,
body.layout-shell-clean.page-calc #proposalExportPage,
body.layout-shell-clean.page-decoder #proposalHistoryPage,
body.layout-shell-clean.page-decoder #proposalExportPage,
body.layout-shell-clean.page-history #proposalExportPage,
body.layout-shell-clean.page-export #proposalHistoryPage{
  display:none !important;
}
body.layout-shell-clean.page-calc .methodPanel,
body.layout-shell-clean.page-calc .uxOverview,
body.layout-shell-clean.page-calc .vinToggleBar,
body.layout-shell-clean.page-calc #vinWrap,
body.layout-shell-clean.page-calc #autoWorkspace,
body.layout-shell-clean.page-calc .layoutFlow,
body.layout-shell-clean.page-decoder #decoderWorkspace,
body.layout-shell-clean.page-history #proposalHistoryPage,
body.layout-shell-clean.page-export #proposalExportPage{
  display:block;
}

/* calc widths */
body.layout-shell-clean.page-calc .proposalWorkspaceHeader,
body.layout-shell-clean.page-calc .methodPanel,
body.layout-shell-clean.page-calc .uxOverview,
body.layout-shell-clean.page-calc .vinToggleBar,
body.layout-shell-clean.page-calc #vinWrap,
body.layout-shell-clean.page-calc #autoWorkspace,
body.layout-shell-clean.page-calc .layoutFlow{
  max-width:var(--shell-page-w);
}
body.layout-shell-clean.page-decoder .proposalWorkspaceHeader,
body.layout-shell-clean.page-decoder #decoderWorkspace{
  max-width:var(--shell-page-w);
}
body.layout-shell-clean.page-history .proposalWorkspaceHeader,
body.layout-shell-clean.page-history #proposalHistoryPage,
body.layout-shell-clean.page-export .proposalWorkspaceHeader,
body.layout-shell-clean.page-export #proposalExportPage{
  width:min(100%, 960px);
  max-width:960px;
}

/* history / export */
.proposalPageCard{ background:#fff; border:1px solid var(--shell-line); border-radius:26px; overflow:hidden; }
.proposalPageHead{ padding:18px 22px; border-bottom:1px solid #edf2f7; }
.proposalPageTitle{ margin:0; font-size:26px; font-weight:800; color:var(--shell-text); }
.proposalPageBody{ padding:20px 22px 22px; }
.proposalPrivacyNote{ border:1px solid #e4ecf4; background:#f8fbff; border-radius:16px; padding:12px 14px; color:#577089; line-height:1.55; margin-bottom:14px; }
.proposalHistoryStats,
.proposalQuickSummary{ display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:14px; margin-bottom:14px; }
.proposalSummaryItem{ border:1px solid #e4ecf4; border-radius:16px; padding:12px 14px; background:#fff; }
.proposalSummaryItem span{ display:block; color:#7a8da0; font-size:12px; margin-bottom:6px; }
.proposalSummaryItem strong{ color:var(--shell-text); font-size:15px; }
.proposalExportGrid{ display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; margin-bottom:14px; }
.proposalMiniCard{ border:1px solid #e4ecf4; border-radius:18px; padding:16px 16px 18px; background:#fff; }
.proposalMiniCard h3{ margin:0 0 14px; color:var(--shell-text); font-size:18px; }
.proposalButtonRow{ display:flex; flex-wrap:wrap; gap:10px; }
.proposalButtonRowCenter{ justify-content:center; }
.proposalExportBody{ text-align:center; }
.proposalExportBody .proposalPageTitle,
.proposalExportBody .proposalMiniCard h3{ text-align:left; }
.proposalEmailBox{ display:grid; grid-template-columns:minmax(0,1fr) auto; gap:10px; margin-top:14px; align-items:center; text-align:left; }
.proposalEmailBox .input{ min-width:0; }
.proposalEmailStatus{ grid-column:1 / -1; display:none; font-size:12px; line-height:1.35; padding:9px 10px; border-radius:10px; border:1px solid #dbe3ee; background:#f8fafc; color:#475569; }
.proposalEmailStatus.busy,.proposalEmailStatus.ok,.proposalEmailStatus.warn{ display:block; }
.proposalEmailStatus.busy{ border-color:#bae6fd; background:#f0f9ff; color:#0369a1; }
.proposalEmailStatus.ok{ border-color:#bbf7d0; background:#f0fdf4; color:#166534; }
.proposalEmailStatus.warn{ border-color:#fed7aa; background:#fff7ed; color:#9a3412; }

/* history card moved from modal */
body.layout-shell-clean #proposalHistoryBody .midCard{
  width:100%;
  max-width:none;
  margin:0;
  background:transparent;
  box-shadow:none;
  border:1px solid #dde8f3;
  border-radius:18px;
  overflow:hidden;
}
body.layout-shell-clean #proposalHistoryBody .midHeader{ padding:14px 16px; background:#f6faff; border-bottom:1px solid #e4edf6; }
body.layout-shell-clean #proposalHistoryBody .midClose,
body.layout-shell-clean #proposalHistoryBody #historyCloseBtn{ display:none !important; }
body.layout-shell-clean #proposalHistoryBody .historyTools{ padding:14px 16px 10px; }
body.layout-shell-clean #proposalHistoryBody .historyList{ padding:0 16px 16px; }
body.layout-shell-clean #proposalHistoryBody .historyList .muted{ padding:10px 0 0; }

/* vin spacing */
body.layout-shell-clean .autoVinHost .vinWrap,
body.layout-shell-clean #vinWrap{ padding:0; }
body.layout-shell-clean .autoVinHost .vinField,
body.layout-shell-clean #vinWrap .vinField{ padding:16px 18px 18px; }
body.layout-shell-clean .autoVinHost .vinField label,
body.layout-shell-clean #vinWrap .vinField label{ display:flex; align-items:center; gap:8px; margin-bottom:10px; padding:0 2px; }
body.layout-shell-clean .autoVinHost .vinInputRow,
body.layout-shell-clean #vinWrap .vinInputRow{ gap:8px; align-items:center; }
body.layout-shell-clean .autoVinHost .vinInfo,
body.layout-shell-clean #vinWrap .vinInfo{ padding:10px 2px 0; line-height:1.45; }
body.layout-shell-clean .autoVinHost label .infoSup,
body.layout-shell-clean #vinWrap label .infoSup{ margin-left:2px; position:static; }

/* decoder page */
body.layout-shell-clean .decoderWorkspace .workspaceCard{ margin-top:0; }

@media (max-width: 1200px){
  :root{ --shell-nav-w: 220px; --shell-page-w: 1000px; }
}

@media (max-width: 1024px){
  body.layout-shell-clean #proposalShellClean{ grid-template-columns: 1fr; }
  body.layout-shell-clean .proposalSidebar{ position:relative; height:auto; width:auto; min-width:0; max-width:none; border-right:none; border-bottom:1px solid var(--shell-line); }
  body.layout-shell-clean #proposalMain{ padding:0 18px 30px; }
  body.layout-shell-clean .heroHeader,
  body.layout-shell-clean .proposalWorkspaceHeader,
  body.layout-shell-clean .methodPanel,
  body.layout-shell-clean .uxOverview,
  body.layout-shell-clean .vinToggleBar,
  body.layout-shell-clean #vinWrap,
  body.layout-shell-clean #autoWorkspace,
  body.layout-shell-clean .layoutFlow,
  body.layout-shell-clean #decoderWorkspace,
  body.layout-shell-clean #proposalHistoryPage,
  body.layout-shell-clean #proposalExportPage{ max-width:none; }
  .proposalHeaderBottom{ grid-template-columns: 1fr; row-gap:12px; }
  .proposalWorkspaceActions{ justify-self:center; }
  .proposalHistoryStats,.proposalQuickSummary,.proposalExportGrid{ grid-template-columns:1fr; }
}


/* v28.1 final polish overrides */
body.layout-shell-clean .heroInner{
  display:flex !important;
  justify-content:center !important;
}
body.layout-shell-clean .heroTitles{
  width:100% !important;
  text-align:center !important;
}
body.layout-shell-clean .heroTitle,
body.layout-shell-clean .heroSubtitle{
  text-align:center !important;
}

/* calc section actions stay right; title centered independently */
.proposalHeaderBottom{
  grid-template-columns: 1fr auto 1fr !important;
}
.proposalWorkspaceActions{
  justify-self:end !important;
  justify-content:flex-end !important;
}

/* auto result width matches sections above */
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow,
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow > .grid,
body.layout-shell-clean.page-calc.workspace-auto .panelResult,
body.layout-shell-clean.page-calc.workspace-auto .panelResult.card{
  width:100% !important;
  max-width:var(--shell-page-w) !important;
  margin-left:auto !important;
  margin-right:auto !important;
}
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow > .grid{
  display:grid !important;
  grid-template-columns:1fr !important;
}

/* decoder page: no middle header card */
body.layout-shell-clean.page-decoder .proposalWorkspaceHeader{
  display:none !important;
}
body.layout-shell-clean.page-decoder #decoderWorkspace{
  margin-top:8px !important;
}
body.layout-shell-clean.page-decoder .workspaceHero{
  align-items:flex-start !important;
}
body.layout-shell-clean.page-decoder .workspaceHero .workspaceActions{
  margin-left:auto !important;
  justify-content:flex-end !important;
}

/* subtle extra room in auto VIN host */
body.layout-shell-clean .autoVinHost .vinField,
body.layout-shell-clean #vinWrap .vinField{
  padding:18px 20px 20px !important;
}
body.layout-shell-clean .autoVinHost .vinField label,
body.layout-shell-clean #vinWrap .vinField label{
  padding:0 4px !important;
}
body.layout-shell-clean .autoVinHost .vinInfo,
body.layout-shell-clean #vinWrap .vinInfo{
  padding:10px 4px 0 !important;
}


/* v28.2 alignment and decoder nav fixes */
body.layout-shell-clean .proposalHeaderCard{
  padding:20px 26px;
}
body.layout-shell-clean .proposalWorkspaceActions{
  justify-self:end !important;
  justify-content:flex-end !important;
}
body.layout-shell-clean .proposalWorkspaceMeta{
  justify-content:flex-start !important;
}
body.layout-shell-clean .heroTitles{
  width:100%;
  text-align:center;
}
body.layout-shell-clean .heroSubtitle{
  text-align:center !important;
}
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow,
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow > .grid,
body.layout-shell-clean.page-calc.workspace-auto .panelResult,
body.layout-shell-clean.page-calc.workspace-auto .panelResult.card{
  width:min(100%, var(--shell-page-w)) !important;
  max-width:var(--shell-page-w) !important;
  margin-left:auto !important;
  margin-right:auto !important;
}
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow{
  padding-left:0 !important;
  padding-right:0 !important;
}
body.layout-shell-clean.page-decoder .workspaceActions{
  justify-content:flex-end !important;
  margin-left:auto !important;
}
body.layout-shell-clean.page-decoder .workspaceCard .workspaceHero{
  align-items:flex-start !important;
}
body.layout-shell-clean.page-decoder .workspaceText{
  margin-bottom:0;
}
@media (max-width:1024px){
  .proposalHeaderTop{ grid-template-columns:1fr; row-gap:12px; }
  body.layout-shell-clean .proposalWorkspaceActions{ justify-self:start !important; }
}


/* v28.3 alignment polish */
body.layout-shell-clean .heroTitles{
  width:100% !important;
  display:flex !important;
  flex-direction:column !important;
  align-items:center !important;
  justify-content:center !important;
  text-align:center !important;
}
body.layout-shell-clean .heroTitle,
body.layout-shell-clean .heroSubtitle{
  width:100% !important;
  text-align:center !important;
  margin-left:auto !important;
  margin-right:auto !important;
}
body.layout-shell-clean.page-calc .proposalWorkspaceHeader,
body.layout-shell-clean.page-calc .methodPanel,
body.layout-shell-clean.page-calc .uxOverview,
body.layout-shell-clean.page-calc .vinToggleBar,
body.layout-shell-clean.page-calc #vinWrap,
body.layout-shell-clean.page-calc #autoWorkspace,
body.layout-shell-clean.page-calc .layoutFlow{
  width:min(100%, var(--shell-page-w)) !important;
  max-width:var(--shell-page-w) !important;
  margin-left:auto !important;
  margin-right:auto !important;
}
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow,
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow > .grid,
body.layout-shell-clean.page-calc.workspace-auto .panelResult,
body.layout-shell-clean.page-calc.workspace-auto .panelResult.card{
  width:100% !important;
  max-width:var(--shell-page-w) !important;
  margin-left:auto !important;
  margin-right:auto !important;
}
body.layout-shell-clean.page-calc.workspace-auto .layoutFlow > .grid{
  width:100% !important;
}
body.layout-shell-clean.page-calc.workspace-auto .panelResult.card{
  display:block !important;
}



/* v28.8 mobile polish */
@media (max-width: 900px){
  :root{
    --shell-page-w: 100%;
  }

  body.layout-shell-clean #proposalMain{
    padding: 0 12px 26px;
  }

  body.layout-shell-clean .wrap{
    padding: 10px 0 24px;
  }

  body.layout-shell-clean .proposalSidebar{
    position: sticky;
    top: 0;
    z-index: 60;
    background: rgba(247, 251, 255, 0.94);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(216, 228, 240, 0.96);
    box-shadow: 0 10px 22px rgba(23, 50, 79, .07);
  }

  body.layout-shell-clean .proposalSidebarInner{
    padding: 10px 12px;
    display: grid;
    gap: 10px;
  }

  body.layout-shell-clean .proposalBrand{
    display: none;
  }

  body.layout-shell-clean .proposalNavGroup{
    margin: 0;
  }

  body.layout-shell-clean .proposalNavLabel{
    display: none;
  }

  body.layout-shell-clean .proposalNavBtn{
    display: none;
  }

  body.layout-shell-clean .proposalSubList{
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  body.layout-shell-clean .proposalSubList::-webkit-scrollbar{
    display: none;
  }

  body.layout-shell-clean .proposalSubBtn,
  body.layout-shell-clean .proposalActionBtn{
    width: auto;
    flex: 0 0 auto;
    white-space: nowrap;
    border-radius: 999px;
    border: 1px solid #d7e5f4;
    background: #ffffff;
    padding: 10px 14px;
    min-height: 42px;
    font-size: 13px;
    box-shadow: 0 6px 14px rgba(23, 50, 79, .04);
  }

  body.layout-shell-clean .proposalSidebarFooter{
    display: none;
  }

  body.layout-shell-clean .proposalAccountGroup{
    margin:0;
    padding:0;
    border-top:0;
  }

  body.layout-shell-clean .proposalAccountIdentity{
    display:none;
  }

  body.layout-shell-clean .heroHeader{
    margin-bottom: 14px;
  }

  body.layout-shell-clean .heroBanner{
    border-radius: 20px;
  }

  body.layout-shell-clean .heroInner{
    padding: 16px 16px;
  }

  body.layout-shell-clean .heroTitle{
    font-size: 30px;
    line-height: 1.08;
  }

  body.layout-shell-clean .heroSubtitle{
    font-size: 14px;
    line-height: 1.35;
    margin-top: 8px;
    max-width: 40ch;
  }

  body.layout-shell-clean .proposalWorkspaceHeader{
    margin-bottom: 18px;
  }

  body.layout-shell-clean .proposalHeaderCard{
    border-radius: 20px;
    padding: 16px 16px;
  }

  body.layout-shell-clean .proposalHeaderTop{
    grid-template-columns: 1fr;
    row-gap: 12px;
    align-items: start;
  }

  body.layout-shell-clean .proposalWorkspaceTitle{
    font-size: 20px;
    line-height: 1.15;
  }

  body.layout-shell-clean .proposalWorkspaceActions{
    width: 100%;
    justify-self: stretch !important;
    justify-content: flex-start !important;
    gap: 8px;
  }

  body.layout-shell-clean .proposalWorkspaceActions .btn{
    min-height: 42px;
    padding: 10px 12px;
  }

  body.layout-shell-clean .proposalHeaderSub{
    margin-top: 12px;
  }

  body.layout-shell-clean .proposalWorkspaceMeta{
    gap: 8px;
  }

  body.layout-shell-clean .proposalWorkspacePill{
    min-height: 36px;
    padding: 7px 12px;
    font-size: 12px;
  }

  body.layout-shell-clean .methodPanel,
  body.layout-shell-clean .uxSummaryCard,
  body.layout-shell-clean .uxMissingCard,
  body.layout-shell-clean .workspaceCard,
  body.layout-shell-clean .vinField,
  body.layout-shell-clean .panelInputs,
  body.layout-shell-clean .panelResult,
  body.layout-shell-clean .proposalPageCard,
  body.layout-shell-clean .workspacePanel{
    border-radius: 18px;
  }

  body.layout-shell-clean .methodPanel,
  body.layout-shell-clean .uxOverview,
  body.layout-shell-clean .vinToggleBar,
  body.layout-shell-clean #vinWrap,
  body.layout-shell-clean #autoWorkspace,
  body.layout-shell-clean .layoutFlow,
  body.layout-shell-clean #decoderWorkspace,
  body.layout-shell-clean #proposalHistoryPage,
  body.layout-shell-clean #proposalExportPage{
    width: 100%;
    max-width: 100%;
  }

  body.layout-shell-clean .uxOverview{
    gap: 12px;
    margin-bottom: 14px;
  }

  body.layout-shell-clean .uxSummaryCard,
  body.layout-shell-clean .uxMissingCard{
    padding: 14px 14px;
  }

  body.layout-shell-clean .panelInputs .cardHeader,
  body.layout-shell-clean .panelResult .cardHeader,
  body.layout-shell-clean .workspaceCard .cardHeader,
  body.layout-shell-clean .proposalPageHead{
    padding: 14px 16px;
  }

  body.layout-shell-clean .panelInputs .cardBody,
  body.layout-shell-clean .panelResult .resultBox,
  body.layout-shell-clean .workspaceCard .cardBody,
  body.layout-shell-clean .proposalPageBody{
    padding: 14px 14px 16px;
  }

  body.layout-shell-clean .proposalHistoryStats,
  body.layout-shell-clean .proposalQuickSummary,
  body.layout-shell-clean .proposalExportGrid{
    gap: 10px;
  }

  body.layout-shell-clean .proposalPrivacyNote{
    padding: 12px 14px;
    border-radius: 16px;
  }
}

@media (max-width: 640px){
  body.layout-shell-clean #proposalMain{
    padding: 0 10px 22px;
  }

  body.layout-shell-clean .proposalSidebarInner{
    padding: 8px 10px;
    gap: 8px;
  }

  body.layout-shell-clean .proposalSubBtn,
  body.layout-shell-clean .proposalActionBtn{
    padding: 9px 12px;
    min-height: 40px;
    font-size: 12px;
  }

  body.layout-shell-clean .heroTitle{
    font-size: 26px;
  }

  body.layout-shell-clean .heroSubtitle{
    font-size: 13px;
    max-width: 34ch;
  }

  body.layout-shell-clean .proposalHeaderCard{
    padding: 14px 14px;
  }

  body.layout-shell-clean .proposalWorkspaceActions .btn{
    flex: 1 1 calc(50% - 6px);
    min-width: 0;
  }

  body.layout-shell-clean .proposalWorkspacePill{
    font-size: 12px;
  }

  body.layout-shell-clean .methodPanel,
  body.layout-shell-clean .uxSummaryCard,
  body.layout-shell-clean .uxMissingCard,
  body.layout-shell-clean .workspaceCard,
  body.layout-shell-clean .vinField,
  body.layout-shell-clean .panelInputs,
  body.layout-shell-clean .panelResult,
  body.layout-shell-clean .proposalPageCard,
  body.layout-shell-clean .workspacePanel{
    border-radius: 16px;
  }

  body.layout-shell-clean .uxSummaryGrid{
    grid-template-columns: 1fr 1fr;
  }

  body.layout-shell-clean .proposalSummaryItem{
    padding: 12px 12px;
  }
}

@media (max-width: 420px){
  body.layout-shell-clean .heroTitle{
    font-size: 24px;
  }

  body.layout-shell-clean .proposalWorkspaceTitle{
    font-size: 18px;
  }

  body.layout-shell-clean .proposalWorkspaceActions .btn{
    flex: 1 1 100%;
  }

  body.layout-shell-clean .proposalWorkspaceMeta{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    overflow: visible;
    padding-bottom: 0;
  }

  body.layout-shell-clean .proposalWorkspacePill{
    width: 100%;
    min-width: 0;
    justify-content: center;
    text-align: center;
    white-space: normal;
    line-height: 1.2;
    min-height: 42px;
    border-radius: 14px;
    padding: 9px 10px;
  }

  body.layout-shell-clean .uxSummaryGrid{
    grid-template-columns: 1fr;
  }
}


/* v28.11 mobile readability */
@media (max-width: 640px){
  body.layout-shell-clean .proposalSubList{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
    overflow:visible;
  }
  body.layout-shell-clean .proposalSubBtn,
  body.layout-shell-clean .proposalActionBtn{
    width:100%;
    justify-content:center;
    text-align:center;
    padding:9px 10px;
    min-height:38px;
  }
  body.layout-shell-clean .proposalWorkspaceActions{
    width:100%;
    justify-content:flex-start !important;
  }
  body.layout-shell-clean .proposalWorkspaceActions .btn{
    flex:0 0 auto;
  }
  body.layout-shell-clean .panelResult .cardHeader{
    display:flex !important;
    flex-direction:column !important;
    align-items:flex-start !important;
    gap:10px;
  }
  body.layout-shell-clean .panelResult .cardHeader .cardHeaderActions{
    width:100% !important;
    justify-content:flex-start !important;
  }
  body.layout-shell-clean .panelResult .resultBox{
    padding:14px 12px 16px !important;
  }
  body.layout-shell-clean .autoVinHost .vinField,
  body.layout-shell-clean #vinWrap .vinField{
    padding:14px 14px 16px !important;
  }
  body.layout-shell-clean .vinInputRow{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:10px !important;
  }
  body.layout-shell-clean .vinInputRow .btn{
    width:100%;
  }
  body.layout-shell-clean .proposalPageHead{
    padding:14px 16px !important;
  }
  body.layout-shell-clean .proposalPageTitle{
    font-size:22px !important;
  }
}
@media (max-width: 420px){
  body.layout-shell-clean .proposalSubList{
    grid-template-columns:1fr 1fr;
  }
  body.layout-shell-clean .heroTitle{font-size:22px;}
  body.layout-shell-clean .heroSubtitle{font-size:12px;}
}


/* v28.11b mobile clarity */
@media (max-width: 640px){
  body.layout-shell-clean .proposalSubList{
    display:flex;
    flex-wrap:nowrap;
    overflow-x:auto;
    gap:10px;
    padding:0 2px 4px;
  }
  body.layout-shell-clean .proposalSubBtn,
  body.layout-shell-clean .proposalActionBtn{
    flex:0 0 auto;
    min-width:max-content;
    padding:10px 14px;
    font-size:13px;
  }
  body.layout-shell-clean .vinSummaryGrid,
  body.layout-shell-clean .vinSummaryGridAuto,
  body.layout-shell-clean .methodGrid,
  body.layout-shell-clean .uxOverview,
  body.layout-shell-clean .proposalExportGrid,
  body.layout-shell-clean .proposalHistoryStats,
  body.layout-shell-clean .proposalQuickSummary{
    grid-template-columns:1fr !important;
  }
  body.layout-shell-clean .vinTag{font-size:13px; line-height:1.35;}
  body.layout-shell-clean .vinSummaryBlock h4{font-size:16px;}
}

/* v30.3 fixed mobile navigation and header pills */
@media (max-width: 900px){
  body.layout-shell-clean .proposalSubList{
    display:grid !important;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:8px;
    overflow:visible !important;
    padding:0 !important;
  }
  body.layout-shell-clean .proposalSubBtn,
  body.layout-shell-clean .proposalActionBtn{
    width:100% !important;
    min-width:0 !important;
    flex:0 0 auto !important;
    white-space:normal !important;
    text-align:center !important;
    justify-content:center;
    line-height:1.2;
    padding:10px 10px;
  }
  body.layout-shell-clean .proposalWorkspaceMeta{
    display:grid !important;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:8px;
    overflow:visible !important;
    padding:0 !important;
  }
  body.layout-shell-clean .proposalWorkspacePill{
    width:100%;
    min-width:0;
    justify-content:center;
    text-align:center;
    white-space:normal;
    line-height:1.2;
    min-height:42px;
    padding:9px 8px;
    border-radius:14px;
  }
}

@media (max-width: 520px){
  body.layout-shell-clean .proposalSubList,
  body.layout-shell-clean .proposalWorkspaceMeta{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
}

/* v30.9 mobile fixed navigation */
@media (max-width: 900px){
  body.layout-shell-clean #proposalShellClean{
    grid-template-columns:1fr !important;
  }
  body.layout-shell-clean .proposalSidebar{
    position:sticky !important;
    top:0 !important;
    z-index:70 !important;
    width:100% !important;
    min-width:0 !important;
    max-width:none !important;
    height:auto !important;
    border-right:0 !important;
    border-bottom:1px solid var(--shell-line) !important;
    background:rgba(247,251,255,.98) !important;
    backdrop-filter:blur(10px);
  }
  body.layout-shell-clean .proposalSidebarInner{
    padding:10px !important;
    display:grid !important;
    gap:10px !important;
  }
  body.layout-shell-clean .proposalBrand{
    display:none !important;
  }
  body.layout-shell-clean .proposalNavGroup,
  body.layout-shell-clean .proposalSubList,
  body.layout-shell-clean .proposalWorkspaceMeta{
    min-width:0 !important;
  }
  body.layout-shell-clean .proposalSubList{
    display:grid !important;
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    gap:8px !important;
    overflow:visible !important;
    padding:0 !important;
  }
  body.layout-shell-clean .proposalSubBtn,
  body.layout-shell-clean .proposalActionBtn{
    width:100% !important;
    min-width:0 !important;
    white-space:normal !important;
    word-break:break-word;
    text-align:center !important;
    justify-content:center !important;
    min-height:44px !important;
    padding:10px 10px !important;
    line-height:1.2 !important;
  }
  body.layout-shell-clean .proposalWorkspaceMeta{
    display:grid !important;
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    gap:8px !important;
    overflow:visible !important;
    padding:0 !important;
  }
  body.layout-shell-clean .proposalWorkspacePill{
    width:100% !important;
    min-width:0 !important;
    white-space:normal !important;
    text-align:center !important;
    justify-content:center !important;
    min-height:44px !important;
    padding:10px 8px !important;
    line-height:1.2 !important;
    border-radius:14px !important;
  }
}

@media (max-width: 420px){
  body.layout-shell-clean .proposalSubList,
  body.layout-shell-clean .proposalWorkspaceMeta{
    grid-template-columns:1fr 1fr !important;
  }
  body.layout-shell-clean #proposalMain{
    padding:0 8px 22px !important;
  }
}


/* v30.10 mobile simplification */
@media (max-width: 900px){
  body.layout-shell-clean .proposalHeaderSub{
    display:none !important;
  }
  body.layout-shell-clean .proposalWorkspaceActions{
    gap:8px !important;
  }
  body.layout-shell-clean .proposalSidebarInner{
    gap:8px !important;
  }
  body.layout-shell-clean .proposalNavLabel{
    font-size:11px;
    margin-bottom:6px;
  }
}
@media (max-width: 520px){
  body.layout-shell-clean .proposalSubList{
    grid-template-columns:repeat(3,minmax(0,1fr)) !important;
  }
  body.layout-shell-clean .proposalSubBtn{
    font-size:12px !important;
    min-height:42px !important;
    padding:8px 8px !important;
  }
  body.layout-shell-clean .proposalNavGroup + .proposalNavGroup .proposalSubList{
    grid-template-columns:repeat(3,minmax(0,1fr)) !important;
  }
}
body.layout-shell-clean #proposalHistoryBody .historyTableWrap{ margin-top: 4px; }
body.layout-shell-clean #proposalHistoryBody .historyNotice{ margin: 0 16px 12px; }


body.layout-shell-clean .proposalWorkspaceActions .btn.subtle{
  border-color:#cfe0ff;
  background:#eef4ff;
  color:#124cb8;
}

/* AI compare page */
body.layout-shell-clean.page-ai-compare .methodPanel,
body.layout-shell-clean.page-ai-compare .uxOverview,
body.layout-shell-clean.page-ai-compare .vinToggleBar,
body.layout-shell-clean.page-ai-compare #vinWrap,
body.layout-shell-clean.page-ai-compare #autoWorkspace,
body.layout-shell-clean.page-ai-compare #decoderWorkspace,
body.layout-shell-clean.page-ai-compare .layoutFlow,
body.layout-shell-clean.page-calc #proposalAiComparePage,
body.layout-shell-clean.page-decoder #proposalAiComparePage,
body.layout-shell-clean.page-history #proposalAiComparePage,
body.layout-shell-clean.page-export #proposalAiComparePage,
body.layout-shell-clean.page-ai-compare #proposalHistoryPage,
body.layout-shell-clean.page-ai-compare #proposalExportPage{
  display:none !important;
}
body.layout-shell-clean.page-ai-compare .proposalWorkspaceHeader,
body.layout-shell-clean.page-ai-compare #proposalAiComparePage{
  width:min(100%, 960px);
  max-width:960px;
  margin-left:auto;
  margin-right:auto;
}
body.layout-shell-clean.page-ai-compare #proposalAiComparePage{
  display:block;
}
.proposalSubBtnLink{ justify-content:flex-start; text-align:left; }
.proposalMiniLead{ margin:0 0 12px; color:#577089; line-height:1.55; }
.proposalAiForm{ display:flex; flex-direction:column; gap:8px; }
.proposalAiLabel{ font-size:13px; font-weight:700; color:#334155; }
#proposalAiNote{ min-height:104px; resize:vertical; }
.proposalAiInlineStats{ display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin-top:4px; }
.proposalAiChartCard{ margin-top:14px; }
.proposalAiAxisLabels{ display:flex; justify-content:space-between; color:#64748b; font-size:12px; margin-bottom:8px; }
.proposalAiTrackWrap{ position:relative; height:74px; }
.proposalAiTrack{ position:absolute; left:0; right:0; top:30px; height:12px; border-radius:999px; background:#e2e8f0; }
.proposalAiMarketBand{ position:absolute; top:30px; height:12px; border-radius:999px; background:linear-gradient(90deg,#93c5fd 0%, #2563eb 100%); opacity:.42; }
.proposalAiMedian{ position:absolute; top:20px; width:3px; height:32px; border-radius:999px; background:#1d4ed8; }
.proposalAiMarker{ position:absolute; top:7px; width:0; height:0; }
.proposalAiMarker::before{ content:""; position:absolute; left:-8px; top:20px; width:16px; height:16px; border-radius:999px; border:2px solid #fff; box-shadow:0 4px 12px rgba(15,23,42,.16); }
.proposalAiMarker span{ position:absolute; top:0; left:50%; transform:translateX(-50%); padding:4px 8px; border-radius:999px; color:#0f172a; background:#fff; border:1px solid #dbe3ee; font-size:11px; font-weight:800; white-space:nowrap; }
.proposalAiMarker.okc::before{ background:#16a34a; }
.proposalAiMarker.ai::before{ background:#f59e0b; }
.proposalAiLegend{ display:flex; flex-wrap:wrap; gap:10px 16px; margin-top:6px; color:#475569; font-size:12px; }
.proposalAiLegend div{ display:flex; align-items:center; gap:7px; }
.proposalAiLegendSwatch{ width:12px; height:12px; border-radius:999px; display:inline-block; }
.proposalAiLegendSwatch.market{ background:#93c5fd; border-radius:4px; }
.proposalAiLegendSwatch.median{ background:#1d4ed8; }
.proposalAiLegendSwatch.okc{ background:#16a34a; }
.proposalAiLegendSwatch.ai{ background:#f59e0b; }
.proposalAiEmpty{ border:1px dashed #cbd5e1; border-radius:14px; padding:16px; color:#64748b; background:#f8fafc; }

@media (max-width: 1024px){
  body.layout-shell-clean #proposalAiComparePage{ max-width:none; }
  .proposalAiInlineStats{ grid-template-columns:1fr; }
}


/* v2.1 manual mode layout fixes */
.formSectionBlock{padding:16px 18px !important;}
.formSectionEyebrow,.formSectionTitle,.formSectionText{padding-left:4px;padding-right:4px;}
.formSectionText{line-height:1.55 !important;}
.uxOverview{align-items:stretch !important;}
.uxSummaryCard,.uxMissingCard{overflow:hidden !important;}
.uxSummaryGrid{display:flex !important;flex-wrap:wrap !important;gap:10px !important;box-sizing:border-box !important;}
.uxMetric{flex:1 1 108px !important;min-width:108px !important;max-width:none !important;box-sizing:border-box !important;}
.uxStatePill{display:inline-flex !important;max-width:100% !important;white-space:normal !important;word-break:break-word !important;}
@media (max-width:900px){.uxSummaryGrid{gap:8px !important;}.uxMetric{flex:1 1 calc(50% - 8px) !important;min-width:0 !important;}}
@media (max-width:620px){.uxMetric{flex:1 1 100% !important;}}


/* OKC: výsledkový stĺpec (VŠH, grafy, trh) — schovať bez hotového výpočtu.
   Musí prepísať vyššie pravidlá typu display:block/grid na .panelResult v tomto súbore. */
body.layout-shell-clean.page-calc:not(.okc-result-ready) aside.panelResult,
body.layout-shell-clean.page-calc:not(.okc-result-ready) aside.panelResult.card,
body.layout-shell-clean.page-calc.workspace-auto:not(.okc-result-ready) aside.panelResult,
body.layout-shell-clean.page-calc.workspace-auto:not(.okc-result-ready) aside.panelResult.card,
body.layout-shell-clean.page-calc.workspace-basic:not(.okc-result-ready) aside.panelResult,
body.layout-shell-clean.page-calc.workspace-basic:not(.okc-result-ready) aside.panelResult.card,
body.layout-shell-clean.page-calc.workspace-expert:not(.okc-result-ready) aside.panelResult,
body.layout-shell-clean.page-calc.workspace-expert:not(.okc-result-ready) aside.panelResult.card{
  display: none !important;
}

/* Auto režim: shell má ešte silnejšie display:block/grid na .panelResult — treba #proposalMain + plný reťazec. */
body.layout-shell-clean.page-calc.workspace-auto:not(.okc-result-ready) #proposalMain aside.card.panelResult,
body.layout-shell-clean.page-calc.workspace-auto:not(.okc-result-ready) #proposalMain aside.card.panelResult.panelScroll,
body.layout-shell-clean.page-calc.workspace-expert:not(.okc-result-ready) #proposalMain aside.card.panelResult,
body.layout-shell-clean.page-calc.workspace-expert:not(.okc-result-ready) #proposalMain aside.card.panelResult.panelScroll{
  display: none !important;
}

/* Auto kalkulačka: schovať riadok „Skryť VIN“ — prepíše page-calc .vinToggleBar { display:block } z tohto súboru */
body.layout-shell-clean.page-calc.workspace-auto #proposalMain .vinToggleBar,
body.layout-shell-clean.page-calc.workspace-auto #proposalMain .wrap .vinToggleBar{
  display: none !important;
}
