/* ==========================================================================
   Carve & Curve — Business Suite
   Design tokens
   ========================================================================== */
:root{
  --deep: #3F0D0C;
  --deep-light: #5C1917;
  --gold: #C9A84C;
  --gold-light: #E4CE8A;
  --bg-page: #F5EFE6;
  --bg-card: #FFFEFB;
  --ink: #2A1810;
  --ink-muted: #8A7A6C;
  --border: #E4D9C8;
  --border-strong: #D8C7AE;
  --success: #6B7F5E;
  --success-bg: #EAEFE4;
  --warning: #B9812F;
  --warning-bg: #F5EAD5;
  --danger: #A6473A;
  --danger-bg: #F3E4E0;
  --draft: #8A7F71;
  --draft-bg: #EBE6DC;

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'DM Mono', 'SFMono-Regular', Consolas, monospace;

  --radius: 3px;
  --shadow-sm: 0 1px 2px rgba(63,13,12,0.06);
  --shadow-md: 0 6px 24px rgba(63,13,12,0.14);
  --sidebar-w: 240px;
}

*, *::before, *::after{ box-sizing: border-box; }
html{ -webkit-text-size-adjust: 100%; }
body{
  margin:0;
  background: var(--bg-page);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
h1,h2,h3{ font-family: var(--font-serif); font-weight: 600; color: var(--deep); margin: 0; }
h1{ font-size: 32px; letter-spacing: 0.2px; }
h2{ font-size: 19px; }
p{ margin: 0; }
a{ color: inherit; text-decoration: none; }
button{ font-family: inherit; }
input, select, textarea{ font-family: var(--font-sans); }
:focus-visible{ outline: 2px solid var(--deep); outline-offset: 2px; }

.num{ text-align: right; font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.mono{ font-family: var(--font-mono); }
.eyebrow{
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--gold); margin: 0 0 4px;
}
.optional{ color: var(--ink-muted); font-weight: 400; font-size: 12px; }

/* ==========================================================================
   Shell layout: sidebar + main column
   ========================================================================== */
.app-shell{ display:flex; min-height:100vh; align-items:flex-start; }

.sidebar{
  width: var(--sidebar-w); flex-shrink:0; background: var(--deep);
  display:flex; flex-direction:column; padding: 22px 0; min-height:100vh;
  position: sticky; top:0;
}
.sidebar .brand{ display:flex; flex-direction:column; line-height:1.1; padding: 0 22px 22px; }
.brand-name{ font-family: var(--font-serif); font-weight: 700; font-size: 21px; color: #FBF6EC; letter-spacing: 0.3px; }
.brand-tag{ font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold-light); margin-top:3px; }

.side-nav{ display:flex; flex-direction:column; padding: 0 12px; gap: 2px; }
.side-nav a{
  padding: 9px 12px; border-radius: var(--radius); font-size: 14px; font-weight: 500; color: #E9DFCF;
  transition: background .15s, color .15s;
}
.side-nav a:hover{ background: rgba(255,255,255,0.08); color: #fff; }
.side-nav a.active{ background: var(--gold); color: var(--deep); font-weight: 600; }
.nav-group{
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--gold-light); opacity: .75; padding: 16px 12px 5px;
}

.main-col{ flex:1; min-width:0; }
.topbar{
  display:none; background: var(--deep); padding: 13px 18px; align-items:center; gap: 14px;
  position: sticky; top:0; z-index: 40; box-shadow: var(--shadow-sm);
  padding-top: max(13px, env(safe-area-inset-top));
}
.topbar-title{ color:#fff; font-family: var(--font-serif); font-weight: 700; font-size: 18px; }
.nav-toggle{
  display:none; flex-direction:column; justify-content:center; gap: 4px;
  width: 32px; height: 32px; background: transparent; border: none; cursor: pointer; padding:0;
}
.nav-toggle span{ display:block; height: 2px; background: #fff; border-radius: 2px; }

.sidebar-backdrop{ display:none; position:fixed; inset:0; background: rgba(20,10,6,0.45); z-index: 55; }
.sidebar-backdrop.open{ display:block; }

.sidebar-logout{
  margin: 16px 22px 0; padding: 9px 12px; background: transparent; border: 1px solid rgba(255,255,255,0.18);
  border-radius: var(--radius); color: var(--gold-light); font-size: 13px; font-weight: 500; cursor: pointer;
  text-align: center;
}
.sidebar-logout:hover{ background: rgba(255,255,255,0.08); color: #fff; }

/* ==========================================================================
   Auth screen
   ========================================================================== */
.auth-screen{
  display:flex; align-items:center; justify-content:center; min-height:100vh;
  background: var(--deep); padding: 24px;
}
.auth-card{
  width: 100%; max-width: 340px; background: var(--bg-card); border-radius: 6px;
  padding: 28px 26px 26px; box-shadow: var(--shadow-md); display:flex; flex-direction:column;
}
.auth-brand-name{ color: var(--deep); font-size: 24px; }
.auth-brand-tag{ color: var(--warning); margin-bottom: 14px; }
.auth-tag{ font-size: 13px; color: var(--ink-muted); margin-bottom: 18px; }
.auth-card .field{ margin-bottom: 14px; }
.auth-error{ color: var(--danger); font-size: 12.5px; margin-bottom: 10px; }
.auth-submit{ width:100%; justify-content:center; margin-top: 4px; }

.app-main{ max-width: 1180px; margin: 0 auto; padding: 30px 32px 80px; }
.view{ display:none; animation: fadein .18s ease; }
.view.active{ display:block; }
@keyframes fadein{ from{ opacity:0; transform: translateY(4px);} to{ opacity:1; transform:none; } }

.view-header{ display:flex; align-items:flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.header-actions-inline{ display:flex; gap:10px; flex-wrap: wrap; }

.panel{ background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; margin-bottom: 20px; }
.panel-danger{ border-color: var(--danger); }
.panel-header{ display:flex; align-items:center; justify-content: space-between; margin-bottom: 16px; }
.panel-note{ color: var(--ink-muted); font-size: 13.5px; margin-bottom: 14px; line-height: 1.6; }
.link-more{ font-size: 13px; color: var(--deep); font-weight: 500; }
.link-more:hover{ color: var(--gold); }

/* ==========================================================================
   Stat grid
   ========================================================================== */
.stat-grid{ display:grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.stat-card{ background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; border-top: 3px solid var(--gold); }
.stat-card .stat-label{ font-family: var(--font-mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-muted); }
.stat-card .stat-value{ font-family: var(--font-serif); font-size: 27px; font-weight: 700; color: var(--deep); margin-top: 4px; }
.stat-card .stat-sub{ font-size: 12px; color: var(--ink-muted); margin-top: 2px; }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:6px;
  padding: 10px 18px; border-radius: var(--radius); border: 1px solid transparent;
  font-size: 13.5px; font-weight: 600; cursor:pointer; white-space: nowrap;
  transition: transform .08s ease, background .15s, border-color .15s, color .15s;
}
.btn:active{ transform: translateY(1px); }
.btn-gold{ background: var(--gold); color: var(--deep); }
.btn-gold:hover{ background: var(--gold-light); }
.btn-outline{ background: transparent; color: var(--deep); border-color: var(--border-strong); }
.btn-outline:hover{ border-color: var(--deep); background: rgba(63,13,12,0.04); }
.btn-text{ background: transparent; color: var(--ink-muted); padding: 10px 8px; }
.btn-text:hover{ color: var(--ink); }
.btn-danger{ background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-danger:hover{ background: var(--danger-bg); }
.btn-sm{ padding: 6px 12px; font-size: 12.5px; }
.btn-icon{ background: transparent; border: none; color: var(--ink-muted); cursor: pointer; padding: 5px 8px; border-radius: var(--radius); font-size: 13px; }
.btn-icon:hover{ background: var(--draft-bg); color: var(--ink); }
.btn-icon.danger:hover{ background: var(--danger-bg); color: var(--danger); }

/* ==========================================================================
   Forms
   ========================================================================== */
.form-grid{ display:grid; grid-template-columns: repeat(2, 1fr); gap: 16px 20px; }
.field{ display:flex; flex-direction: column; gap: 6px; }
.field-wide{ grid-column: 1 / -1; }
.field label{ font-size: 12.5px; font-weight: 600; color: var(--deep); }
.field input, .field select, .field textarea{
  padding: 10px 12px; border: 1px solid var(--border-strong); border-radius: var(--radius);
  background: #fff; color: var(--ink); font-size: 14px;
}
.field textarea{ resize: vertical; font-family: var(--font-sans); line-height: 1.5; }
.field input:focus, .field select:focus, .field textarea:focus{ border-color: var(--deep); }
.input-with-action{ display:flex; gap: 8px; }
.input-with-action select{ flex: 1; }

.form-actions{ display:flex; justify-content:flex-end; gap: 10px; margin: 8px 0 30px; flex-wrap: wrap; }
.form-actions-left{ justify-content: flex-start; }
.danger-zone{ margin-top: 4px; }

.filter-row{ display:flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; align-items:center; }
.filter-row select, .filter-row input{ padding: 9px 12px; border: 1px solid var(--border-strong); border-radius: var(--radius); background: #fff; font-size: 13.5px; }
.filter-row input[type="search"]{ flex: 1; min-width: 200px; }
.filter-row input[type="date"]{ min-width: 0; }

/* ==========================================================================
   Tables
   ========================================================================== */
.table-wrap{ overflow-x: auto; }
.data-table{ width: 100%; border-collapse: collapse; min-width: 560px; }
.data-table th{
  text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--ink-muted); font-weight: 600; padding: 0 10px 10px; border-bottom: 1px solid var(--border-strong);
  font-family: var(--font-mono);
}
.data-table th.num{ text-align: right; }
.data-table td{ padding: 12px 10px; border-bottom: 1px solid var(--border); font-size: 14px; vertical-align: middle; }
.data-table tbody tr:hover{ background: rgba(201,168,76,0.06); }
.data-table td.cell-muted{ color: var(--ink-muted); font-size: 13px; }
.row-actions{ display:flex; gap: 4px; justify-content:flex-end; }

.empty-state{ text-align:center; padding: 36px 20px; color: var(--ink-muted); }
.empty-state p{ margin-bottom: 14px; }

/* Status badges */
.badge{ display:inline-block; padding: 4px 10px; border-radius: 20px; font-size: 11.5px; font-weight: 600; font-family: var(--font-mono); letter-spacing: .02em; white-space: nowrap; }
.badge-Draft{ background: var(--draft-bg); color: var(--draft); }
.badge-Sent{ background: var(--warning-bg); color: var(--warning); }
.badge-Accepted{ background: var(--success-bg); color: var(--success); }
.badge-Declined{ background: var(--danger-bg); color: var(--danger); }
.badge-Expired{ background: var(--draft-bg); color: var(--ink-muted); text-decoration: line-through; }
.badge-Paid{ background: var(--success-bg); color: var(--success); }
.badge-PartiallyPaid{ background: var(--warning-bg); color: var(--warning); }
.badge-Overdue{ background: var(--danger-bg); color: var(--danger); }
.badge-Cancelled{ background: var(--draft-bg); color: var(--ink-muted); text-decoration: line-through; }
.badge-Received{ background: var(--success-bg); color: var(--success); }

/* Line items table inputs */
.line-items-table input, .line-items-table select{ width: 100%; padding: 7px 8px; border: 1px solid var(--border); border-radius: var(--radius); font-size: 13.5px; background: #fff; }
.line-items-table td{ padding: 8px 6px; }
.line-items-table .col-qty, .line-items-table .col-unit{ width: 74px; }
.line-items-table .col-rate, .line-items-table .col-disc, .line-items-table .col-tax{ width: 88px; }
.line-items-table .col-amount{ width: 110px; font-family: var(--font-mono); font-weight: 600; color: var(--deep); }
.line-items-table .col-del{ width: 32px; }
.line-items-table select.line-item-select{ min-width: 160px; }

/* Totals card */
.totals-card{ background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 24px; max-width: 360px; margin-left: auto; margin-bottom: 20px; }
.totals-card .t-row{ display:flex; justify-content: space-between; padding: 6px 0; font-size: 14px; }
.totals-card .t-row.grand{ border-top: 2px solid var(--gold); margin-top: 8px; padding-top: 12px; font-family: var(--font-serif); font-size: 22px; font-weight: 700; color: var(--deep); }
.totals-card .t-row .val{ font-family: var(--font-mono); }

/* ==========================================================================
   Modal
   ========================================================================== */
.modal-backdrop{ display:none; position: fixed; inset:0; background: rgba(42,24,16,0.45); align-items:center; justify-content:center; z-index: 100; padding: 20px; }
.modal-backdrop.active{ display:flex; }
.modal{ background: var(--bg-card); border-radius: 6px; padding: 26px; width: 100%; max-width: 480px; box-shadow: var(--shadow-md); max-height: 88vh; overflow-y: auto; }
.modal h2{ margin-bottom: 18px; }
.modal .form-grid{ margin-bottom: 20px; }
.modal .form-actions{ margin-bottom: 0; }

/* ==========================================================================
   Toast
   ========================================================================== */
.toast{
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--deep); color: #FBF6EC; padding: 12px 22px; border-radius: 4px;
  font-size: 13.5px; font-weight: 500; z-index: 200; opacity: 0; pointer-events: none;
  transition: opacity .2s, transform .2s; box-shadow: var(--shadow-md);
}
.toast.show{ opacity: 1; transform: translateX(-50%) translateY(0); }

.status-bar{ display:flex; align-items:center; gap: 12px; margin-bottom: 18px; }
.status-bar select{ padding: 7px 10px; border: 1px solid var(--border-strong); border-radius: var(--radius); font-size: 13px; background:#fff; }

/* ==========================================================================
   Row "more options" menu
   ========================================================================== */
.row-menu{
  position: fixed; background: var(--bg-card); border: 1px solid var(--border-strong); border-radius: var(--radius);
  box-shadow: var(--shadow-md); z-index: 300; min-width: 150px; padding: 4px; display:flex; flex-direction:column;
}
.row-menu-item{
  background: transparent; border: none; text-align: left; padding: 9px 12px; font-size: 13.5px;
  border-radius: var(--radius); cursor: pointer; color: var(--ink); font-family: var(--font-sans);
}
.row-menu-item:hover{ background: var(--draft-bg); }
.row-menu-item.danger{ color: var(--danger); }
.row-menu-item.danger:hover{ background: var(--danger-bg); }
.row-menu-sep{ height:1px; background: var(--border); margin: 4px 2px; }

/* ==========================================================================
   Bar list (Reports)
   ========================================================================== */
.bar-row{ display:flex; align-items:center; gap: 12px; padding: 7px 0; }
.bar-label{ width: 150px; flex-shrink:0; font-size: 13px; color: var(--ink); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.bar-track{ flex:1; height: 10px; background: var(--draft-bg); border-radius: 6px; overflow: hidden; }
.bar-fill{ height:100%; background: var(--gold); }
.bar-value{ width: 110px; flex-shrink:0; text-align:right; font-family: var(--font-mono); font-size: 13px; color: var(--ink); }

/* ==========================================================================
   Printable document — Quotation / Invoice / Purchase Order
   Layout mirrors a standard Indian GST business document.
   ========================================================================== */
.print-doc{
  background: #fff; border: 1px solid var(--border); box-shadow: var(--shadow-sm); max-width: 800px; margin: 0 auto;
  padding: 22px; font-size: 12.5px; min-height: 267mm; display: flex; flex-direction: column;
}
.pd-box{ border: 1px solid var(--deep); }

.pd-header{ display:flex; justify-content: space-between; align-items:flex-start; padding: 6px 12px; border-bottom: 1px solid var(--border-strong); }
.pd-brand-name{ font-family: var(--font-serif); font-weight: 700; font-size: 15px; color: var(--deep); letter-spacing: .2px; line-height: 1.15; }
.pd-brand-name::after{ content:''; display:block; width: 28px; height: 2px; background: var(--gold); margin-top: 2px; }
.pd-brand-meta{ font-size: 9.5px; color: var(--ink-muted); margin-top: 2px; line-height: 1.25; }
.pd-doctype{ font-family: var(--font-serif); font-size: 18px; font-weight: 700; color: var(--gold); letter-spacing: .05em; text-align: right; }

.pd-meta-row{ display:flex; border-bottom: 1px solid var(--border-strong); }
.pd-meta-col{ flex: 1; padding: 4px 12px; font-size: 10.5px; }
.pd-meta-col + .pd-meta-col{ border-left: 1px solid var(--border-strong); }
.pd-meta-col .pd-kv{ display:flex; padding: 0.5px 0; }
.pd-meta-col .pd-kv .k{ width: 100px; flex-shrink:0; color: var(--ink-muted); text-align: right; padding-right: 8px; }
.pd-meta-col .pd-kv .v{ font-weight: 600; color: var(--ink); font-family: var(--font-mono); }

.pd-parties{ display:flex; }
.pd-party{ flex: 1; padding: 5px 12px; }
.pd-party + .pd-party{ border-left: 1px solid var(--border-strong); }
.pd-party .pd-label{ font-family: var(--font-mono); font-size: 9px; text-transform: uppercase; letter-spacing: .1em; color: var(--gold); font-weight: 600; margin-bottom: 2px; }
.pd-party .pd-name{ font-weight: 700; font-size: 12px; color: var(--ink); margin-bottom: 1px; }
.pd-party .pd-line{ font-size: 10.5px; color: var(--ink-muted); line-height: 1.3; }

.pd-subject{ font-style: italic; font-family: var(--font-serif); font-size: 15px; color: var(--deep); margin: 14px 2px 10px; }

.pd-table{ width: 100%; border-collapse: collapse; margin: 14px 0; table-layout: fixed; }
.pd-table thead th{ text-align:left; font-family: var(--font-mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: .04em; color: #fff; background: var(--deep); padding: 7px 6px; border: 1px solid var(--deep); }
.pd-table thead tr.pd-subhead th{ background: var(--deep-light); font-size: 9px; padding: 4px 6px; }
.pd-table thead th.num{ text-align: right; }
/* Column widths are now set via <colgroup> in the generated markup (see
   documentPrintHtml/deliveryChallanPrintHtml) so the Item & Description
   column reliably gets the bulk of the row width and doesn't get squeezed
   by the tax columns. */
.pd-table tbody td{ padding: 7px 6px; border: 1px solid var(--border); font-size: 11px; vertical-align: top; word-wrap: break-word; white-space: nowrap; }
.pd-table tbody td:nth-child(2){ white-space: normal; }
.pd-table tbody td.num{ text-align: right; font-family: var(--font-mono); }
.pd-table tbody .item-desc, .pd-table tbody .item-size{ color: var(--ink-muted); font-size: 10px; margin-top: 2px; }

.pd-bottom{ display:flex; gap: 22px; padding: 4px 2px 0; align-items: flex-start; }
.pd-bottom-left{ flex: 1; min-width: 0; }
.pd-words{ font-weight: 600; font-style: normal; font-family: Georgia, 'Times New Roman', Times, serif; font-size: 12.5px; color: var(--ink); margin-bottom: 10px; }
.pd-notes{ font-size: 11.5px; color: var(--ink); line-height: 1.5; margin-bottom: 10px; }
.pd-terms-title{ font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; letter-spacing: .1em; color: var(--gold); font-weight: 600; margin-bottom: 4px; }
.pd-terms-list{ margin: 0; padding-left: 16px; font-size: 11px; color: var(--ink-muted); line-height: 1.55; }
.pd-thankyou{ margin-top: 8px; font-size: 12px; color: var(--ink); }

.pd-totals-box{ width: 260px; flex-shrink:0; border: 1px solid var(--border-strong); }
.pd-totals-box .pt-row{ display:flex; justify-content: space-between; padding: 7px 12px; font-size: 12px; border-bottom: 1px solid var(--border); }
.pd-totals-box .pt-row .val{ font-family: var(--font-mono); }
.pd-totals-box .pt-row.grand{ background: var(--bg-page); border-bottom: none; font-family: var(--font-serif); font-weight: 700; font-size: 18px; color: var(--deep); }
.pd-totals-box .pt-row.paid .val{ color: var(--success); }
.pd-totals-box .pt-row.balance{ font-weight: 600; }

.pd-signoff{ margin-top: auto; padding-top: 22px; display:flex; justify-content: flex-end; }
.pd-signoff .sign-line{ width: 200px; border-top: 1px solid var(--ink-muted); padding-top: 6px; text-align:center; font-size: 11px; color: var(--ink-muted); }
.pd-dual-signoff{ margin-top: auto; padding-top: 30px; display:flex; justify-content: space-between; gap: 40px; }
.pd-dual-signoff .sign-line{ flex: 1; border-top: 1px solid var(--ink-muted); padding-top: 6px; text-align:center; font-size: 11px; color: var(--ink-muted); }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media screen and (max-width: 900px){
  .sidebar{
    position: fixed; left: -260px; top:0; bottom:0; z-index: 60; transition: left .2s ease;
    box-shadow: var(--shadow-md); min-height: 100vh;
  }
  .sidebar.open{ left: 0; }
  .topbar{ display:flex; }
  .nav-toggle{ display:flex; }
  .app-main{ padding: 22px 16px 60px; }
}
@media screen and (max-width: 860px){
  .stat-grid{ grid-template-columns: repeat(2, 1fr); }
  .form-grid{ grid-template-columns: 1fr; }
  .pd-bill{ flex-direction: column; gap: 16px; }
  .pd-footer{ grid-template-columns: 1fr; }
}
@media screen and (max-width: 640px){
  h1{ font-size: 26px; }
  .print-doc{ padding: 28px 20px; }
  .pd-doc-box{ min-width: 0; }
  .bar-label{ width: 90px; }
}

/* ==========================================================================
   Print
   ========================================================================== */
@media print{
  *{ -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; color-adjust: exact !important; }
  body{ background: #fff; }
  .no-print{ display:none !important; }
  .app-shell{ display:block; }
  .app-main{ padding: 0; max-width: none; margin:0; }
  /* min-height/flex is only useful for the on-screen single-page preview; on
     an actual multi-page print it forces extra blank space and pushes the
     signature block around, so switch to normal block flow when printing. */
  .print-doc{ border: none; box-shadow: none; max-width: none; padding: 0; min-height: 0; display: block; }
  .view{ display:none !important; }
  .view.active{ display:block !important; }
  .pd-box{ page-break-inside: avoid; break-inside: avoid; }
  .pd-table thead{ display: table-header-group; }
  .pd-table tr{ page-break-inside: avoid; break-inside: avoid; }
  .pd-header{ page-break-after: avoid; break-after: avoid; }
  /* Only the small, genuinely atomic pieces avoid breaking — not the whole
     bottom block. Forcing the entire words/notes/terms/totals chunk to stay
     together left large blank gaps on the previous page whenever it didn't
     quite fit; this lets it flow into whatever room remains instead. */
  .pd-words{ page-break-inside: avoid; break-inside: avoid; }
  .pd-terms-list li{ page-break-inside: avoid; break-inside: avoid; }
  .pd-totals-box{ page-break-inside: avoid; break-inside: avoid; }
  .pd-footer, .pd-signoff, .pd-dual-signoff{ page-break-inside: avoid; break-inside: avoid; }
  @page{ size: A4; margin: 12mm; }
}

/* Enquiries */
.nav-badge{display:inline-block;min-width:18px;padding:1px 6px;border-radius:10px;background:var(--gold,#C9A84C);color:#1E0F06;font-size:11px;font-weight:700;text-align:center;margin-left:6px}
.topbar-bell{margin-left:auto;position:relative;text-decoration:none;font-size:18px}
@media(min-width:901px){.topbar-bell{display:none}}
.enq-row{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:14px 4px;border-bottom:1px solid rgba(0,0,0,.08);cursor:pointer}
.enq-row.new{border-left:3px solid var(--gold,#C9A84C);padding-left:12px;background:rgba(201,168,76,.08)}
.enq-row small{display:block;color:var(--ink-muted,#6B4F38)}
.enq-detail dl{display:grid;grid-template-columns:140px 1fr;gap:8px 16px;margin:0 0 18px}
.enq-detail dt{color:var(--ink-muted,#6B4F38);font-size:13px}
.enq-detail dd{margin:0}
.enq-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:20px}
