/* Imperium plain-English layer: big type, big targets, one obvious next step, works on phone, tablet and desktop. */
html.sx { font-size: 18px; }
.sx body { line-height: 1.5; }
.sx button, .sx .sx-btn, .sx input, .sx select, .sx textarea, .sx .nav a { min-height: 48px; font-size: 1rem; }
.sx a:focus-visible, .sx button:focus-visible, .sx input:focus-visible, .sx summary:focus-visible { outline: 3px solid #1f6feb; outline-offset: 2px; }
.sx .nav { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 8px 12px; }
.sx .nav a { display: inline-flex; align-items: center; padding: 8px 16px; border-radius: 12px; text-decoration: none; font-weight: 600; }
.sx .nav a[aria-current="page"] { outline: 3px solid #1f6feb; }
.sx-more { position: relative; }
.sx-more summary { min-height: 48px; display: inline-flex; align-items: center; padding: 8px 16px; border-radius: 12px; cursor: pointer; font-weight: 600; list-style: none; }
.sx-more summary::-webkit-details-marker { display: none; }
.sx-more > div { display: flex; flex-direction: column; gap: 6px; padding: 8px; margin-top: 6px; border: 1px solid #c9d1d9; border-radius: 12px; background: #fff; position: absolute; z-index: 5; min-width: 240px; box-shadow: 0 8px 24px rgba(0,0,0,.15); }
.sx-home { max-width: 1040px; margin: 0 auto; padding: 16px; }
.sx-hero h1 { font-size: 2rem; margin: 8px 0; }
.sx-safe { font-size: 1.05rem; padding: 12px 16px; border-radius: 12px; background: #e8f5ec; color: #14532d; border: 2px solid #86c99a; }
.sx-home h2 { font-size: 1.4rem; margin: 28px 0 12px; }
.sx-cmd { margin-top: 20px; padding: 16px; border: 2px solid #1f3a5f; border-radius: 16px; background: #fff; }
.sx-cmd label { display: block; font-size: 1.25rem; font-weight: 700; margin-bottom: 10px; }
.sx-cmd-row { display: flex; gap: 10px; flex-wrap: wrap; }
.sx-cmd-row input { flex: 1 1 260px; padding: 12px 14px; border: 2px solid #8a96a3; border-radius: 12px; }
.sx-btn { display: inline-flex; align-items: center; justify-content: center; padding: 10px 22px; border-radius: 12px; border: 2px solid #1f3a5f; background: #fff; color: #1f3a5f; font-weight: 700; text-decoration: none; cursor: pointer; }
.sx-primary { background: #1f3a5f; color: #fff; }
.sx-say { margin: 12px 0 0; font-size: 1.05rem; min-height: 1.5em; }
.sx-say.good { color: #14532d; } .sx-say.warn { color: #7a4b00; } .sx-say.bad { color: #9b1c1c; font-weight: 700; }
.sx-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .sx-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .sx-grid { grid-template-columns: repeat(3, 1fr); } }
.sx-card { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 18px 18px 18px 22px; min-height: 96px; border: 2px solid #c9d1d9; border-left: 8px solid #1f6feb; border-radius: 14px; background: #fff; color: inherit; text-decoration: none; }
.sx-card:hover, .sx-card:focus-visible { border-color: #1f6feb; background: #f5f9ff; }
.sx-card-t { font-size: 1.2rem; font-weight: 700; } .sx-card-s { color: #4b5563; }
.sx-badge { position: absolute; top: 10px; right: 12px; min-width: 32px; height: 32px; padding: 0 8px; border-radius: 16px; background: #c2410c; color: #fff; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.sx-list { display: flex; flex-direction: column; gap: 12px; }
.sx-row { display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 14px 16px; border: 2px solid #c9d1d9; border-radius: 14px; background: #fff; }
.sx-row-main { flex: 1 1 260px; } .sx-row-main p { margin: 4px 0 0; color: #4b5563; }
.sx-empty { padding: 14px 0; color: #4b5563; font-size: 1.05rem; }
.sx-link { margin-top: 28px; background: none; border: 0; color: #1f6feb; text-decoration: underline; cursor: pointer; }
/* On the home screen the detailed dashboard is hidden until asked for. */
.sx-home .command-bar, .sx-home .global-search, .sx-home .toolbar, .sx-home #message { display: none; }
.sx-home #content { display: none; }
.sx-home.sx-show-tech #content, .sx-home.sx-show-tech .toolbar { display: block; }
@media (prefers-reduced-motion: reduce) { .sx * { transition: none !important; animation: none !important; } }
/* Fix: the count badge must never cover the card title. */
.sx-card:has(.sx-badge) .sx-card-t { padding-right: 48px; }
.sx-card .sx-badge { top: 14px; }
/* Revenue screens: pricing numbers review and the plain-English price card. */
.sx-page .command-bar, .sx-page .global-search, .sx-page .toolbar, .sx-page #message, .sx-page #content { display: none; }
.sx-stamp { display: inline-block; margin: 8px 0; padding: 10px 14px; border-radius: 12px; font-weight: 700; border: 2px solid; }
.sx-stamp.good { background: #e8f5ec; color: #14532d; border-color: #86c99a; }
.sx-stamp.warn { background: #fff4e5; color: #7a4b00; border-color: #f0b35c; }
.sx-quote { margin-top: 16px; padding: 18px; border: 2px solid #1f3a5f; border-radius: 16px; background: #fff; }
.sx-price { display: flex; flex-direction: column; gap: 2px; margin: 8px 0 14px; } .sx-price span { color: #4b5563; } .sx-price strong { font-size: 2.1rem; color: #1f3a5f; }
.sx-qas { display: grid; gap: 10px; } .sx-qa { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; padding: 12px 14px; border-radius: 12px; background: #f5f7fa; }
.sx-q { color: #374151; } .sx-a { text-align: right; }
.sx-quote h3 { margin: 20px 0 6px; font-size: 1.15rem; } .sx-quote ul { margin: 0; padding-left: 22px; } .sx-quote li { margin: 6px 0; }
.sx-needs li { font-weight: 600; }
.sx-form { display: grid; gap: 18px; margin-top: 18px; }
.sx-field { display: flex; flex-direction: column; gap: 6px; } .sx-field label { font-weight: 700; font-size: 1.1rem; } .sx-field small { color: #4b5563; font-size: .95rem; }
.sx-field input { padding: 12px 14px; border: 2px solid #8a96a3; border-radius: 12px; width: 100%; box-sizing: border-box; }
.sx-field-row { display: flex; align-items: center; gap: 10px; max-width: 360px; } .sx-unit { color: #374151; min-width: 56px; }
.sx-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.sx-approve { margin-top: 24px; padding: 16px; border: 2px dashed #1f6feb; border-radius: 16px; }
.sx-big { min-height: 64px; font-size: 1.15rem; width: 100%; }
.sx-confirm { margin-top: 14px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; } .sx-confirm p { flex: 1 1 100%; font-weight: 700; margin: 0; } .sx-confirm[hidden] { display: none; }
@media (min-width: 720px) { .sx-form { grid-template-columns: 1fr 1fr; } .sx-form .sx-say, .sx-form .sx-actions { grid-column: 1 / -1; } }
/* Walkthrough wizard: phone-first, tap-first. */
.wt { max-width: 760px; margin: 0 auto; padding: 8px 0 120px; }
.wt-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; flex-wrap: wrap; }
.wt-bar { height: 10px; border-radius: 6px; background: #e5e7eb; margin-top: 6px; width: 180px; max-width: 60vw; } .wt-bar span { display: block; height: 100%; border-radius: 6px; background: #1f6feb; transition: width .2s; }
.wt-chip { padding: 8px 12px; border-radius: 999px; font-size: .95rem; font-weight: 600; background: #eef2f7; color: #1f3a5f; } .wt-chip.good { background: #e8f5ec; color: #14532d; } .wt-chip.warn { background: #fff4e5; color: #7a4b00; } .wt-chip.bad { background: #fde8e8; color: #9b1c1c; }
.wt-dots { display: flex; gap: 6px; margin: 12px 0; flex-wrap: wrap; } .wt-dot { min-width: 44px; min-height: 44px; border-radius: 50%; border: 2px solid #c9d1d9; background: #fff; font-weight: 700; cursor: pointer; } .wt-dot.on { background: #1f3a5f; color: #fff; border-color: #1f3a5f; }
#wt-body h2 { font-size: 1.5rem; margin: 10px 0 14px; } #wt-body h2:focus { outline: none; }
.wt-label { font-weight: 700; font-size: 1.1rem; display: block; margin-bottom: 6px; } .wt-help { color: #4b5563; margin: 6px 0 12px; }
.wt-picks { display: flex; flex-wrap: wrap; gap: 10px; }
.wt-pick, .wt-add { min-height: 52px; padding: 10px 18px; border-radius: 14px; border: 2px solid #8a96a3; background: #fff; color: #1f2937; font-size: 1rem; font-weight: 600; cursor: pointer; }
.wt-pick.on { background: #1f3a5f; border-color: #1f3a5f; color: #fff; } .wt-pick.on::before { content: '✓ '; }
.wt-results { display: flex; flex-direction: column; gap: 8px; margin: 8px 0; } .wt-result { min-height: 56px; text-align: left; padding: 12px 16px; border-radius: 14px; border: 2px solid #c9d1d9; background: #fff; cursor: pointer; font-size: 1.05rem; }
.wt-area { margin: 16px 0; padding: 14px; border: 2px solid #c9d1d9; border-radius: 16px; background: #fff; } .wt-area h3 { margin: 0 0 8px; }
.wt-area-head { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; } .wt-area-head .sx-field { flex: 1 1 220px; }
.wt-remove { min-height: 48px; padding: 8px 14px; border-radius: 12px; border: 2px solid #b91c1c; background: #fff; color: #b91c1c; font-weight: 700; cursor: pointer; }
.wt-row { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; margin: 10px 0; }
.wt-stepper { display: inline-flex; align-items: center; gap: 8px; } .wt-round { width: 52px; height: 52px; border-radius: 50%; border: 2px solid #1f3a5f; background: #fff; color: #1f3a5f; font-size: 1.6rem; font-weight: 700; cursor: pointer; } .wt-count { min-width: 40px; text-align: center; font-size: 1.3rem; font-weight: 700; }
.wt-more summary { min-height: 48px; display: flex; align-items: center; cursor: pointer; font-weight: 700; color: #1f6feb; }
.wt-task { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 6px 0; border-bottom: 1px solid #eef2f7; }
.wt-tasklabel { display: flex; align-items: center; gap: 12px; min-height: 48px; flex: 1 1 260px; cursor: pointer; } .wt-check { width: 28px; height: 28px; flex: none; }
.wt-task select { min-height: 48px; border-radius: 10px; border: 2px solid #8a96a3; padding: 6px 10px; font-size: 1rem; }
.wt-file { position: absolute; width: 1px; height: 1px; opacity: 0; } .wt-takephoto { min-height: 64px; width: 100%; font-size: 1.15rem; box-sizing: border-box; }
.wt-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin: 12px 0; } .wt-photo { margin: 0; display: flex; flex-direction: column; gap: 6px; } .wt-photo img { width: 100%; height: 120px; object-fit: cover; border-radius: 12px; } .wt-photo input { padding: 10px; border: 2px solid #8a96a3; border-radius: 10px; min-height: 44px; }
.wt-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 8px 0 14px; } .wt-sum { display: flex; flex-direction: column; padding: 12px; border-radius: 12px; background: #f5f7fa; } .wt-sum span { color: #4b5563; font-size: .95rem; } .wt-sum strong { font-size: 1.2rem; }
.wt-tips { margin: 10px 0; color: #374151; }
.wt-nav { position: fixed; left: 0; right: 0; bottom: 0; display: flex; gap: 12px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: #fff; border-top: 2px solid #c9d1d9; z-index: 20; } .wt-nav .sx-btn { flex: 1; min-height: 56px; font-size: 1.1rem; } .wt-nav .sx-btn[disabled] { opacity: .4; } .wt-nav [hidden] { display: none; }
.wt-resume { margin: 12px 0; }
.sx-page .sx-btn[disabled] { opacity: .45; cursor: not-allowed; }
/* Crew Today */
.sx-page.sx-show-tech #content { display: block; }
.cr-card { margin: 14px 0; padding: 18px; border: 3px solid #1f3a5f; border-radius: 18px; background: #fff; }
.cr-label { margin: 0; color: #4b5563; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: .85rem; }
.cr-place { margin: 4px 0; font-size: 1.8rem; } .cr-when { margin: 0 0 8px; font-size: 1.25rem; font-weight: 600; }
.cr-actions { display: grid; gap: 12px; margin: 12px 0; } .cr-actions .sx-btn { width: 100%; box-sizing: border-box; min-height: 60px; font-size: 1.15rem; }
.sx-danger { border-color: #b91c1c; color: #b91c1c; background: #fff; min-height: 56px; }
.cr-facts { display: grid; grid-template-columns: 1fr; gap: 2px; margin: 10px 0; } .cr-facts dt { font-weight: 700; margin-top: 8px; color: #374151; } .cr-facts dd { margin: 0; font-size: 1.1rem; }
.cr-area { margin: 12px 0; padding: 10px 12px; border-radius: 12px; background: #f5f7fa; } .cr-area h4 { margin: 0 0 6px; font-size: 1.15rem; } .cr-watch { margin: 0 0 6px; color: #7a4b00; font-weight: 600; }
.cr-prog { font-weight: 700; color: #14532d; }
.cr-problem { display: grid; gap: 12px; } .cr-problem textarea { padding: 12px; border: 2px solid #8a96a3; border-radius: 12px; font-size: 1rem; width: 100%; box-sizing: border-box; }
@media (min-width: 720px) { .cr-actions { grid-template-columns: repeat(3, 1fr); } .cr-facts { grid-template-columns: 160px 1fr; } .cr-facts dt { margin-top: 0; } }
/* Operations / Management */
.op-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 14px 0; }
.op-stat { display: flex; flex-direction: column; padding: 14px; border-radius: 14px; background: #f5f7fa; border: 2px solid #c9d1d9; } .op-stat strong { font-size: 2rem; } .op-stat span { color: #374151; }
.op-stat.warn { background: #fff4e5; border-color: #f0b35c; } .op-stat.good { background: #e8f5ec; border-color: #86c99a; }
.op-row { align-items: flex-start; } .op-btns { display: flex; gap: 10px; flex-wrap: wrap; } .op-btns .sx-btn { min-height: 52px; }
