:root {
  --navy: #12233f; --navy-2: #1d3560; --gold: #e8a33d; --gold-2: #f6c96f;
  --paper: #faf6ee; --ink: #1f2430; --muted: #6b7180; --line: #e5dccb;
  --ok: #2e7d4f; --warn: #b26a00; --bad: #b3261e;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink);
  font-family: "Noto Sans Devanagari", system-ui, sans-serif; font-size: 16px; line-height: 1.55; }
a { color: var(--navy-2); }
.top { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px;
  padding: 12px 24px; background: var(--navy); color: #fff; }
.brand { color: var(--gold-2); font-family: "Tiro Devanagari Marathi", serif; font-size: 28px; text-decoration: none; }
.brand small { display: block; font-family: "Noto Sans Devanagari"; font-size: 12px; color: #c9d3e6; }
.top nav { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.top nav a { color: #fff; text-decoration: none; }
.wallet-pill { background: var(--navy-2); padding: 4px 12px; border-radius: 999px; }
.devbar { background: var(--gold-2); text-align: center; font-size: 14px; padding: 4px; }
main { max-width: 1100px; margin: 24px auto; padding: 0 16px; }
footer { text-align: center; color: var(--muted); font-size: 13px; padding: 24px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 20px 22px; margin-bottom: 18px; }
.panel.narrow { max-width: 440px; margin: 24px auto; }
.panel.warn { background: #fff7e6; border-color: var(--gold); }
.grid2 { display: grid; grid-template-columns: 2fr 1fr; gap: 18px; }
@media (max-width: 760px) { .grid2 { grid-template-columns: 1fr; } }
h1, h2, h3 { color: var(--navy); margin: 0 0 10px; }
label { display: block; margin: 10px 0; font-size: 15px; }
input, select { display: block; width: 100%; padding: 9px 10px; margin-top: 4px; font: inherit;
  border: 1px solid #cfc5b0; border-radius: 8px; background: #fff; }
input[type=radio], input[type=checkbox] { display: inline; width: auto; margin: 0 6px 0 0; }
.row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.row label { flex: 0 0 auto; }
.row input { width: 110px; }
.row label.check { display: flex; align-items: center; gap: 6px; min-height: 42px; margin-bottom: 10px; }
.row label.check input { margin: 0; }
.btn { display: inline-block; background: var(--gold); color: var(--navy); border: 0; padding: 10px 20px;
  border-radius: 8px; font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; margin: 6px 6px 6px 0; }
.btn:hover { background: var(--gold-2); }
.btn.ghost { background: transparent; border: 2px solid var(--gold); }
.btn.small { padding: 6px 14px; font-size: 14px; }
button.link { background: none; border: 0; color: inherit; text-decoration: underline; cursor: pointer; font: inherit; }
.top button.link { color: #fff; }
form.inline { display: inline; }
.muted { color: var(--muted); font-size: 14px; }
.flash { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; background: #e8f3ec; color: var(--ok); }
.flash.error { background: #fbe9e7; color: var(--bad); }
.note { background: #eef3fb; padding: 10px 14px; border-radius: 8px; }
.big { font-size: 32px; font-weight: 700; color: var(--navy); margin: 6px 0 12px; }
.big.small { font-size: 18px; }
.hero { text-align: center; padding: 40px 10px 20px; }
.hero h1 { font-family: "Tiro Devanagari Marathi", serif; font-size: 40px; }
.hero p { max-width: 640px; margin: 0 auto 20px; }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 20px 0; }
.steps div { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 14px; text-align: center; }
.steps b { display: block; font-size: 26px; color: var(--gold); }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr 1fr; } }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 14px 0; }
@media (max-width: 760px) { .cards { grid-template-columns: 1fr; } }
.card { display: block; background: #fff; border: 2px solid var(--line); border-radius: 12px; padding: 16px; margin: 0; }
.cards.pick .card { cursor: pointer; }
.card.chosen { border-color: var(--gold); box-shadow: 0 0 0 3px #f6c96f55; }
.card p { font-size: 14px; min-height: 44px; }
.price { font-size: 20px; font-weight: 700; color: var(--navy); }
.price small { font-size: 12px; font-weight: 400; color: var(--muted); }
.tag { background: var(--gold-2); color: var(--navy); font-size: 12px; padding: 1px 8px; border-radius: 999px; }
.estimate { background: var(--paper); border: 1px dashed var(--gold); border-radius: 10px; padding: 14px; margin: 14px 0; }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-weight: 600; font-size: 13px; }
td input, td select { margin: 0; }
.num { text-align: right; white-space: nowrap; }
.minus { color: var(--bad); }
.status { font-size: 13px; padding: 2px 10px; border-radius: 999px; background: #eee; white-space: nowrap; }
.status.done { background: #e2f2e8; color: var(--ok); }
.status.running, .status.queued { background: #fff1d6; color: var(--warn); }
.status.failed { background: #fbe9e7; color: var(--bad); }
.progress { height: 14px; background: #eee; border-radius: 999px; overflow: hidden; margin: 14px 0 6px; }
.progress div { height: 100%; background: var(--gold); transition: width .5s; }

td input { max-width: 120px; }
td select { min-width: 160px; }

/* languages: English in Latin type, मराठी / हिन्दी in Devanagari */
.hidden { display: none; }
.brand .latin { font-family: "Noto Serif", serif; font-size: 18px; margin-left: 6px; color: #e9d9a8; }
.langs { display: inline-flex; gap: 8px; margin-left: 14px; padding-left: 14px;
  border-left: 1px solid rgba(255,255,255,.25); font-size: 14px; }
.langs a { opacity: .8; }
.langs b { color: var(--gold-2); }
body.lang-en { font-family: "Noto Sans", system-ui, sans-serif; line-height: 1.5; }
body.lang-en .hero h1, body.lang-en h2 { font-family: "Noto Serif", Georgia, serif; }
body.lang-mr, body.lang-hi { line-height: 1.7; }
body.lang-mr .hero h1, body.lang-hi .hero h1 { font-family: "Tiro Devanagari Marathi", serif; }
@media (max-width: 640px) {
  .langs { margin-left: 0; padding-left: 0; border-left: 0; }
}

/* v14.5.1: delivery modes, Word layout, what to check, proofreading */
.modes { border: 1px solid #e3d9c3; border-radius: 10px; padding: 8px 14px; margin: 14px 0; }
.modes legend { font-weight: 700; padding: 0 6px; }
label.mode { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: baseline; padding: 8px; border-radius: 8px; }
label.mode input { width: auto; display: inline; margin: 0; }
label.mode.chosen { background: #fff7e4; }
.price.small { font-size: 16px; }
details.word summary { cursor: pointer; font-weight: 600; }
.summary h3 { margin-top: 0; }
.proof-bar { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; margin-bottom: 8px; }
.proof-nav { display: inline-flex; gap: 6px; align-items: center; }
.proof-nav select { width: auto; display: inline-block; margin: 0; }
.proof { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.proof .scan { position: sticky; top: 8px; max-height: calc(100vh - 16px); overflow: auto;
  background: #fff; border: 1px solid #e3d9c3; border-radius: 10px; }
.proof .scan img { width: 100%; display: block; }
.proof .text { background: #fff; border: 1px solid #e3d9c3; border-radius: 10px; padding: 12px 16px; }
.proof .block small { color: var(--muted); }
.proof textarea { width: 100%; font: inherit; font-family: "Noto Sans Devanagari", "Tiro Devanagari Marathi", serif;
  font-size: 18px; line-height: 1.7; padding: 8px 10px; border: 1px solid #d8cdb4; border-radius: 6px; resize: vertical; }
.proof .block.footnote textarea { font-size: 16px; background: #fbf8f1; }
a.here { font-weight: 700; }
table.prices input, table.prices select { min-width: 70px; }
@media (max-width: 800px) {
  .proof { grid-template-columns: 1fr; }
  .proof .scan { position: static; max-height: none; }
}

/* accounts */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; margin: 12px 0; }
.tile { background: #fff; border: 1px solid #e3d9c3; border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; }
.tile b { font-size: 24px; color: var(--navy); }
.tile.profit { border-color: var(--gold); background: #fff9ea; }
.tile small { color: var(--muted); }
form.period select, form.period input { width: auto; display: inline-block; }
.subnav { display: flex; flex-wrap: wrap; gap: 4px 18px; padding: 8px 24px; background: #1d2b4f; }
.subnav a { color: #dfe6f3; text-decoration: none; font-size: 14px; }
.subnav a.here, .subnav a:hover { color: var(--gold-2); }
details.section summary { cursor: pointer; font-weight: 700; font-size: 17px; }
table.settings td { vertical-align: middle; }
table.settings input:not([type=checkbox]), table.settings select { max-width: 320px; }
table.settings input[type=checkbox] { width: auto; }
ul.samples { font-size: 15px; } ul.samples del { color: #a33; } ul.samples ins { color: #176a3a; text-decoration: none; font-weight: 600; }
details.find summary { cursor: pointer; font-weight: 600; }
.row.tools form { margin: 0; }
label.check { display: inline-flex; align-items: center; gap: 6px; width: auto; }
label.check input { width: auto; display: inline; margin: 0; }
fieldset.bs { border: 1px solid #e3d9c3; border-radius: 10px; padding: 6px 14px 10px; margin: 10px 0; }
fieldset.bs legend { font-weight: 700; padding: 0 6px; }
.bs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 2px 16px; }
.bs-grid label.changed { border-left: 3px solid var(--gold); padding-left: 8px; }
.bs-grid label.check { min-height: 42px; }
.thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.thumbs figure { margin: 0; text-align: center; font-size: 12px; color: var(--muted); }
.thumbs img { width: 110px; border: 1px solid #e3d9c3; border-radius: 4px; background: #fff; }
pre.report { white-space: pre-wrap; font-size: 13px; max-height: 300px; overflow: auto; background: #fbf8f1; padding: 8px; }
details.prep summary { cursor: pointer; font-weight: 700; }
input.short { width: 120px; display: inline-block; }
.status.requested { background: #fde9c4; } .status.working { background: #dbe7fb; }

/* ============================================================
   The desktop program's look (gui.py colours, its banner and its
   Home picture): navy and gold on warm paper.
   ============================================================ */
:root {
  --navy: #122654; --navy-2: #22456E; --gold: #EE710F; --gold-2: #E3A63F;
  --paper: #FEFAF6; --ink: #12243A; --muted: #4E6A85; --line: #B9D2E6;
  --surface: #E3EDF5; --rule-gold: #9A7433; --deep: #001B38;
}
body { background: var(--paper); color: var(--ink); }
.top { display: block; padding: 0; background: var(--deep); }
.top .banner { display: block; position: relative; line-height: 0; }
.top .banner img { width: 100%; height: auto; display: block; }
.top .plate { position: absolute; left: 34.6%; width: 15.8%; top: 34%; height: 33%;
  display: flex; align-items: center; justify-content: center; text-align: center; line-height: 1.15;
  color: var(--navy); font-weight: 700; font-size: clamp(9px, 1.05vw, 17px); overflow: hidden; padding: 0 1%; }
nav.strip { display: flex; align-items: center; gap: 6px 4px; flex-wrap: wrap; padding: 6px 18px;
  background: linear-gradient(#fffaf0, #f6e7c6); border-top: 2px solid var(--gold-2);
  border-bottom: 2px solid var(--rule-gold); }
nav.strip a, nav.strip button.link { color: var(--navy); text-decoration: none; font-weight: 600;
  padding: 6px 14px; border-radius: 8px; border-right: 1px solid #e3cf9f; }
nav.strip a:hover, nav.strip button.link:hover { background: #fff3da; }
nav.strip a.here { background: var(--navy); color: #fff; }
nav.strip .wallet-pill { background: var(--surface); }
nav.strip .wallet-pill.here { background: var(--navy); }
nav.strip .langs { margin-left: auto; border-left: 0; padding-left: 0; }
nav.strip .langs a { border-right: 0; padding: 6px 8px; font-weight: 400; opacity: 1; }
nav.strip .langs b { color: var(--gold); padding: 6px 8px; }
nav.strip .btn.small { color: var(--navy); }
.top button.link { color: var(--navy); }
.subnav { background: var(--navy); }
.devbar { background: #fde3c3; color: var(--navy); border-bottom: 1px solid var(--gold-2); }
.panel { border-color: var(--line); box-shadow: 0 1px 0 rgba(18, 38, 84, .04); }
h1, h2, h3 { color: var(--navy); }
.btn { background: var(--gold); color: #fff; }
.btn:hover { background: #d9650c; }
.btn.ghost { color: var(--navy); border-color: var(--gold-2); background: #fff; }
.btn.ghost:hover { background: #fff3da; }
input, select, textarea { border-color: var(--line); background: #fff; }
input:focus, select:focus, textarea:focus { outline: 2px solid #3FB6E8; outline-offset: 0; }
table th { color: var(--navy-2); }
.status { background: var(--surface); }
.hero { padding: 0 0 20px; }
.hero-art { width: 100%; height: auto; border-radius: 14px; display: block; margin: 0 0 18px;
  border: 2px solid var(--gold-2); }
.card { border-color: var(--line); }
.card.chosen, label.mode.chosen { border-color: var(--gold); background: #fff8ef; }
.tile { border-color: var(--line); }
.tile.profit { border-color: var(--gold-2); }
footer { color: var(--muted); }
@media (max-width: 640px) {
  .top .plate { display: none; }
  nav.strip { padding: 4px 6px; }
  nav.strip .langs { margin-left: 0; }
}
.service textarea, .panel label textarea { display: block; width: 100%; margin-top: 4px; font: inherit;
  border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; }
.table-wrap { overflow-x: auto; }
table.styles-table td, table.styles-table th { padding: 4px 4px; font-size: 14px; white-space: nowrap; }
table.styles-table select, table.styles-table input { margin: 0; padding: 5px 6px; width: auto; display: inline-block; }
input.tiny { width: 58px !important; }
details.styles summary { cursor: pointer; font-weight: 700; }

/* ---------------------------------------------------------------- the book's menu strip (booknav.py) */
nav.booknav { display: flex; align-items: center; flex-wrap: wrap; gap: 2px 2px; padding: 4px 18px;
  background: var(--surface, #fffaf0); border-bottom: 1px solid #e6d7b8; position: relative; z-index: 20; }
.booknav-title { font-weight: 700; color: var(--navy); margin-right: 12px; max-width: 260px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
nav.booknav details.menu { position: relative; }
nav.booknav details.menu > summary { list-style: none; cursor: pointer; padding: 6px 12px; border-radius: 6px;
  color: var(--navy); font-weight: 600; font-size: 15px; user-select: none; }
nav.booknav details.menu > summary::-webkit-details-marker { display: none; }
nav.booknav details.menu > summary::after { content: " ▾"; font-size: 11px; opacity: .7; }
nav.booknav details.menu > summary:hover, nav.booknav details.menu[open] > summary { background: #fff3da; }
nav.booknav details.menu.here > summary { background: var(--navy); color: #fff; }
nav.booknav .menu-list { position: absolute; left: 0; top: 100%; min-width: 250px; margin-top: 2px;
  background: #fff; border: 1px solid #d9c9a5; border-radius: 8px; box-shadow: 0 8px 24px rgba(20, 30, 60, .18);
  padding: 4px 0; }
nav.booknav .menu-list a, nav.booknav .menu-list span.off { display: block; padding: 7px 16px;
  text-decoration: none; color: var(--navy); white-space: nowrap; }
nav.booknav .menu-list a:hover { background: #fff3da; }
nav.booknav .menu-list a.here { font-weight: 700; border-left: 3px solid var(--gold); padding-left: 13px; }
nav.booknav .menu-list span.off { color: #9a9a9a; cursor: not-allowed; }
.panel.section > h3:first-child { margin-top: 0; }
p.tip { margin-top: 14px; }
@media (max-width: 640px) {
  nav.booknav { padding: 4px 6px; }
  .booknav-title { width: 100%; max-width: none; }
  nav.booknav .menu-list { min-width: 200px; }
  nav.booknav details.menu:last-child .menu-list { left: auto; right: 0; }
}

/* ---------------------------------------------------------------- suggested corrections (proof editor) */
.unsure-bar { display: flex; align-items: center; gap: 12px; margin: 4px 0 10px; }
.sugg { margin: -4px 0 12px; padding: 6px 10px; background: #fffbea; border: 1px solid #f0e2b0; border-radius: 6px;
  font-size: 14px; line-height: 2; }
.sugg-word { display: inline-block; margin-right: 14px; }
.sugg-word mark { background: #ffe680; padding: 0 3px; border-radius: 3px; }
.sugg-word.here mark { outline: 2px solid var(--gold, #c8962c); }
.sugg-word.done { opacity: .45; text-decoration: line-through; }
.sugg .chip { border: 1px solid #d9c9a5; background: #fff; border-radius: 12px; padding: 0 9px; cursor: pointer;
  font: inherit; color: var(--navy, #1d2b4f); }
.sugg .chip:hover { background: #fff3da; }

/* ---------------------------------------------------------------- footer menu and policy pages */
footer .footer-menu { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; margin-bottom: 8px; }
footer .footer-menu a { text-decoration: none; }
footer .footer-menu a.here { font-weight: 700; }
.panel.legal { max-width: 860px; margin-left: auto; margin-right: auto; line-height: 1.65; }
.panel.legal h3 { margin-top: 22px; }
.panel.legal li { margin-bottom: 6px; }
.panel.legal .updated { margin-top: 26px; }
.gap { background: #ffe1d6; color: #9a2b00; padding: 0 4px; border-radius: 3px; font-size: .9em; }
table.facts th { text-align: left; width: 32%; vertical-align: top; }
table.prices.public td, table.prices.public th { vertical-align: top; }

/* ---------------------------------------------------------------- payments by UPI / bank (until the gateway) */
.pay-where { display: flex; gap: 22px; align-items: flex-start; flex-wrap: wrap; margin: 10px 0 16px; }
.pay-where .qr { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.pay-where .qr svg { width: 180px; height: 180px; background: #fff; border: 1px solid #e6d7b8; border-radius: 8px; }
.status.pay-pending { background: #fff3da; color: #8a5a00; }
.status.pay-approved { background: #e3f4e6; color: #1d6b2c; }
.status.pay-rejected { background: #fbe3e0; color: #9a2b00; }
.subnav .count { background: var(--gold, #c8962c); color: #1d2b4f; border-radius: 10px; padding: 0 7px; font-weight: 700; }
tr.pending td { background: #fffbea; }
input.small-input { width: 150px; }
.wallet-grid { align-items: start; }
.wallet-grid .col > .panel + .panel { margin-top: 18px; }
input.tiny[name="amount"] { width: 90px; }

/* v14.17 -- the testing launch: report a problem from any page; codes */
.feedback-tab { position: fixed; right: 0; bottom: 120px; z-index: 50;
  writing-mode: vertical-rl; transform: rotate(180deg);
  background: var(--gold, #c8962c); color: #1d2b4f; font-weight: 700;
  padding: 12px 7px; border-radius: 0 8px 8px 0; text-decoration: none;
  box-shadow: 0 2px 6px rgba(0,0,0,.2); font-size: 14px; }
.feedback-tab:hover { filter: brightness(1.08); }
.strip .count { background: var(--gold, #c8962c); color: #1d2b4f; border-radius: 10px; padding: 0 7px; font-weight: 700; }
.code { font-family: ui-monospace, Consolas, monospace; letter-spacing: .05em; }
@media (max-width: 640px) { .feedback-tab { bottom: 70px; font-size: 12px; padding: 9px 5px; } }
.bad { color: var(--bad, #b3261e); }
