:root {
  --bg: #0b0f17;
  --panel: #111827;
  --panel-2: #151f32;
  --line: #243145;
  --text: #f3f4f6;
  --muted: #9ca3af;
  --gold: #d97706;
  --gold-2: #f59e0b;
  --emerald: #10b981;
  --red: #ef4444;
  --radius: 14px;
}
* { box-sizing: border-box; }
html {
  overflow-x: hidden;
  max-width: 100%;
}
body {
  margin: 0;
  background: radial-gradient(1200px 600px at 20% -10%, rgba(217,119,6,.18), transparent 60%),
    radial-gradient(1000px 500px at 90% 0%, rgba(16,185,129,.12), transparent 60%), var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  overflow-x: clip;
  max-width: 100%;
  width: 100%;
}
a { color: var(--gold-2); }

/* ==========================================================================
   Hotchows Global Sticky Top Navigation Bar
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 100;
  background: #101211f5;
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.header-inner {
  min-height: 82px;
  display: flex;
  gap: 20px;
  align-items: center;
  padding: 12px 32px;
  max-width: 1660px;
  margin: auto;
}
.site-header .brand {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}
.site-header .brand img {
  height: 40px;
  width: auto;
  object-fit: contain;
}
.global-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 17px;
  flex: 1;
}
.global-nav a {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  min-height: 44px;
  display: flex;
  align-items: center;
  color: #f6efdf;
  transition: color 0.15s ease;
}
.global-nav a:hover,
.global-nav a:focus-visible {
  color: var(--gold-2);
}
.header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}
.site-header select.language {
  max-width: 90px;
  background: #202522;
  color: #f6efdf;
  border: 1px solid #626960;
  border-radius: 6px;
  min-height: 40px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.site-header a.site-btn-cta {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid #f5ae59;
  border-radius: 5px;
  background: #f5ae59;
  color: #17180f;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s ease;
}
.site-header a.site-btn-cta:hover {
  background: #fbc88a;
  border-color: #fbc88a;
  color: #17180f;
}
.menu-toggle {
  display: none;
  background: transparent;
  border: 1px solid #666f65;
  color: #f6efdf;
  border-radius: 5px;
  min-height: 40px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.menu-toggle:hover {
  border-color: #f5ae59;
}

@media (min-width: 1600px) {
  .global-nav { gap: 25px; }
  .global-nav a { font-size: 13px; }
}

@media (max-width: 1240px) {
  .header-inner { flex-wrap: wrap; padding: 12px 20px; min-height: 72px; }
  .menu-toggle { display: block; }
  .global-nav {
    display: none;
    order: 3;
    width: 100%;
    flex-basis: 100%;
    align-items: stretch;
    justify-content: flex-start;
    flex-wrap: wrap;
    padding: 12px 0 6px;
    gap: 8px 20px;
    border-top: 1px solid var(--line);
    margin-top: 8px;
  }
  .site-header.menu-open .global-nav { display: flex; }
  .header-actions { margin-left: auto; }
  .global-nav a { font-size: 13px; min-width: 120px; }
}

@media (max-width: 540px) {
  .header-inner { padding: 10px 14px; gap: 8px; min-height: 64px; }
  .site-header .brand img { height: 32px; }
  .header-actions { gap: 6px; }
  .site-header select.language { width: 62px; font-size: 11px; padding: 6px 4px; min-height: 36px; }
  .site-header a.site-btn-cta { padding: 6px 10px; font-size: 11px; min-height: 36px; }
  .menu-toggle { font-size: 11px; padding: 6px 8px; min-height: 36px; }
}

/* ==========================================================================
   Tips Pool App Sub-Header / Topbar
   ========================================================================== */
.topbar {
  border-bottom: 1px solid var(--line);
  position: relative;
  background: rgba(11,15,23,.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 10;
  width: 100%;
}
.topbar-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  box-sizing: border-box;
}
.brand, .topbar .brand { display: flex; gap: 12px; align-items: center; }
.logo, .topbar .logo {
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, var(--gold), #92400e);
  display: grid; place-items: center; font-size: 22px;
  box-shadow: 0 6px 24px rgba(217,119,6,.35);
}
.topbar .brand h1, .brand h1 { font-size: 18px; margin: 0; letter-spacing: .04em; }
.topbar .brand p, .brand p { margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.top-actions { display: flex; gap: 10px; align-items: center; }
.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px 20px 60px;
  width: 100%;
  box-sizing: border-box;
}
.grid { display: grid; gap: 16px; min-width: 0; width: 100%; }
.grid.two { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
@media (max-width: 900px) { .grid.two { grid-template-columns: minmax(0, 1fr); } }
.card {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.card h2 { margin: 0 0 4px; font-size: 16px; }
.card .sub { color: var(--muted); font-size: 13px; margin: 0 0 14px; }
.card-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.card-header-titles {
  flex: 1;
  min-width: 240px;
}
.card-header-titles h2 {
  margin: 0 0 4px;
}
.card-header-titles .sub {
  margin: 0;
}
.card-header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 140px; flex: 1; }
label { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
input, select, textarea {
  background: #0b1220; border: 1px solid var(--line); color: var(--text);
  border-radius: 10px; padding: 10px 12px; font-size: 15px; outline: none;
}
input:focus, select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(217,119,6,.2); }
.btn {
  border: 1px solid var(--line); background: #0b1220; color: var(--text);
  padding: 10px 16px; border-radius: 10px; cursor: pointer; font-weight: 600;
}
.btn:hover { border-color: var(--gold); }
.btn.primary { background: linear-gradient(135deg, var(--gold-2), var(--gold)); border: none; color: #1a1000; }
.btn.ghost { background: transparent; }
.btn.small { padding: 6px 10px; font-size: 13px; }
.modes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
@media (max-width: 700px) { .modes { grid-template-columns: 1fr; } }
.mode {
  border: 1px solid var(--line); border-radius: 12px; padding: 14px; cursor: pointer;
  background: #0b1220; display: flex; flex-direction: column; gap: 6px;
  transition: all 0.2s ease;
}
.mode:hover { border-color: rgba(217,119,6,.6); }
.mode:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 2px; border-color: var(--gold); }
.mode.active { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(217,119,6,.22); background: #0e172a; }
.mode b { display: block; font-size: 14px; color: var(--text); }
.mode-badge {
  display: inline-block; font-size: 10px; font-weight: 700; padding: 3px 8px;
  border-radius: 6px; letter-spacing: 0.05em; width: fit-content; text-transform: uppercase;
}
.badge-flsa { background: rgba(16,185,129,0.2); color: #34d399; border: 1px solid rgba(16,185,129,0.4); }
.badge-custom { background: rgba(217,119,6,0.2); color: #fbbf24; border: 1px solid rgba(217,119,6,0.4); }
.badge-equal { background: rgba(59,130,246,0.2); color: #60a5fa; border: 1px solid rgba(59,130,246,0.4); }
.mode-formula { font-family: ui-monospace, SFMono-Regular, monospace; font-size: 11px; color: var(--gold-2); background: rgba(217,119,6,0.1); padding: 2px 6px; border-radius: 4px; width: fit-content; }
.mode-desc { color: var(--muted); font-size: 12px; line-height: 1.4; margin-top: 2px; }

.mode-status-bar {
  background: rgba(11,18,32,0.8); border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 14px; font-size: 13px; display: flex; align-items: center; gap: 10px;
}
.mode-status-bar .status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.status-dot.green { background: #10b981; box-shadow: 0 0 8px #10b981; }
.status-dot.amber { background: #f59e0b; box-shadow: 0 0 8px #f59e0b; }
.status-dot.blue { background: #3b82f6; box-shadow: 0 0 8px #3b82f6; }

.legal-box {
  background: rgba(15, 23, 42, 0.7); border: 1px solid rgba(217,119,6,0.3);
  border-radius: 12px; padding: 14px; font-size: 12px; line-height: 1.5; color: #cbd5e1;
}
.legal-header { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; color: var(--gold-2); font-size: 13px; }
.legal-icon { font-size: 16px; }
.legal-body p { margin: 0 0 8px; }
.legal-body p:last-child { margin-bottom: 0; }
.disclaimer-text { color: #94a3b8; font-size: 12px; border-top: 1px dashed var(--line); padding-top: 8px; line-height: 1.5; }
.total-strip {
  display: flex; gap: 18px; align-items: center; margin-top: 14px;
  background: rgba(217,119,6,.1); border: 1px dashed rgba(217,119,6,.5);
  padding: 12px 14px; border-radius: 12px;
}
.total-strip .big { font-size: 26px; font-weight: 800; color: var(--gold-2); }

/* Responsive scroll container for data tables */
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(11, 18, 32, 0.4);
  margin-top: 14px;
  position: relative;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}
.mobile-table-hint {
  display: none;
  font-size: 12px;
  color: var(--gold-2);
  background: rgba(217, 119, 6, 0.12);
  border: 1px solid rgba(217, 119, 6, 0.25);
  padding: 6px 12px;
  border-radius: 8px;
  margin-bottom: 8px;
}
@media (max-width: 768px) {
  .mobile-table-hint { display: block; }
}

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: #cbd5e1; font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; padding: 12px 10px; border-bottom: 1px solid var(--line); }
td { padding: 10px; border-bottom: 1px solid rgba(36,49,69,.6); }
td.num, th.num { text-align: right; }
.payout { color: var(--emerald); font-weight: 700; }
.pill { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; background: #0b1220; border: 1px solid var(--line); }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.mt { margin-top: 14px; }
.muted { color: var(--muted); }
#toast {
  position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
  background: #0b1220; border: 1px solid var(--gold); padding: 10px 16px;
  border-radius: 999px; display: none; z-index: 1000;
  width: max-content; max-width: min(92vw, 560px); box-sizing: border-box;
}
#toast.toast-warn {
  background: #3a1d06; border-color: #f59e0b; color: #fde68a; font-weight: 600;
  border-radius: 12px; text-align: center;
}
.unsynced-badge {
  display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px;
  background: #3a1d06; border: 1px solid #f59e0b; color: #fde68a; font-size: 11px; font-weight: 700;
}
.retry-sync-btn { border-color: #f59e0b !important; color: #fde68a !important; }

/* Staff Table & Column Widths: prevent squished/overlapping fields on mobile */
#staffTable {
  min-width: 740px; /* guarantees columns never collapse into illegibility */
}
#staffTable th:nth-child(1), #staffTable td:nth-child(1) { width: 48px; text-align: center; }
#staffTable th:nth-child(2), #staffTable td:nth-child(2) { min-width: 180px; width: 220px; }
#staffTable th:nth-child(3), #staffTable td:nth-child(3) { min-width: 120px; width: 130px; }
#staffTable th:nth-child(4), #staffTable td:nth-child(4) { min-width: 85px; width: 95px; }
#staffTable th:nth-child(5), #staffTable td:nth-child(5) { min-width: 85px; width: 95px; }
#staffTable th:nth-child(6), #staffTable td:nth-child(6) { min-width: 100px; width: 110px; }
#staffTable th:nth-child(7), #staffTable td:nth-child(7) { min-width: 80px; width: 85px; }
#staffTable th:nth-child(8), #staffTable td:nth-child(8) { width: 50px; text-align: center; }

#reportTable {
  min-width: 600px;
}
#shiftTable {
  min-width: 500px;
}

.staff-input {
  width: 100%;
  min-height: 42px;
  font-size: 15px;
  padding: 8px 10px;
  box-sizing: border-box;
  background: #0b1220;
  border: 1px solid #374151;
  color: #f3f4f6;
  border-radius: 8px;
}
.staff-input:focus {
  border-color: var(--gold-2);
  outline: 2px solid var(--gold-2);
  outline-offset: 1px;
}

/* Checkbox touch target compliance (min 44px hit area, min 24px checkbox) */
.chk-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  cursor: pointer;
}
.chk-wrap input[type="checkbox"] {
  width: 24px;
  height: 24px;
  min-width: 24px;
  min-height: 24px;
  margin: 0;
  cursor: pointer;
  accent-color: var(--gold-2);
}

/* Mobile viewport adjustments */
@media (max-width: 768px) {
  .header-inner {
    padding: 12px 16px;
  }
  .topbar-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 12px 16px;
  }
  .top-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    width: 100%;
  }
  .top-actions #authChip {
    grid-column: 1 / -1;
  }
  .top-actions .lang-wrap {
    grid-column: 1 / -1;
    width: 100%;
    justify-content: flex-end;
  }
  .top-actions .btn {
    width: 100%;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    padding: 8px 12px;
  }
  .wrap {
    padding: 16px 16px 50px;
  }
  .lang-wrap select {
    flex: 1;
    max-width: none;
    min-height: 44px;
    font-size: 16px;
  }
  .staff-input {
    font-size: 16px; /* Prevents auto-zoom on iOS */
    min-height: 44px;
  }
  input, select, textarea {
    font-size: 16px; /* Prevents auto-zoom on iOS */
    min-height: 44px;
  }
  .btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}

@media (max-width: 540px) {
  .header-inner {
    padding: 10px 14px;
    gap: 8px;
    min-height: 64px;
  }
  .topbar-inner {
    padding: 12px 14px;
    gap: 10px;
  }
  .wrap {
    padding: 12px 14px 40px;
  }
  .card {
    padding: 14px;
  }
  .row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .field {
    min-width: 0;
    width: 100%;
  }
  .card-header-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .card-header-actions {
    width: 100%;
  }
  .card-header-actions .btn {
    width: 100%;
    min-height: 44px;
    justify-content: center;
  }
}

/* Demo Lock & Multiple Variations Styling */
.demo-lock-banner {
  background: rgba(217, 119, 6, 0.12);
  border: 1px solid rgba(217, 119, 6, 0.4);
  color: #fef3c7;
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.5;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.demo-lock-banner a {
  color: var(--gold-2);
  text-decoration: underline;
  cursor: pointer;
  font-weight: 700;
}
.demo-scenarios-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 12px 14px;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(217, 119, 6, 0.3);
  border-radius: 10px;
  margin-bottom: 14px;
}
.demo-tag {
  font-size: 12px;
  font-weight: 700;
  color: var(--gold-2);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.demo-scenario-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.demo-scen-btn {
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 8px;
  background: #0b1220;
  border: 1px solid var(--line);
  color: #e2e8f0;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s ease;
}
.demo-scen-btn:hover {
  border-color: var(--gold-2);
}
.demo-scen-btn.active {
  background: linear-gradient(135deg, var(--gold-2), var(--gold));
  color: #1a1000;
  border-color: var(--gold);
  font-weight: 700;
  box-shadow: 0 0 10px rgba(217, 119, 6, 0.35);
}
.input-locked {
  cursor: not-allowed !important;
  opacity: 0.85;
  background: #080c14 !important;
  border-color: rgba(55, 65, 81, 0.6) !important;
}
.input-locked:focus {
  outline: none !important;
  box-shadow: none !important;
  border-color: rgba(239, 68, 68, 0.5) !important;
}

.hint { font-size: 12px; color: var(--muted); }

/* ==========================================================================
   Email Modal & Formats
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(5, 8, 15, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 16px;
  box-sizing: border-box;
}
.modal-card {
  background: linear-gradient(180deg, #182235, #0f172a);
  border: 1px solid var(--gold);
  border-radius: 16px;
  max-width: 660px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.7), 0 0 20px rgba(217,119,6,0.25);
  box-sizing: border-box;
}
.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}
.modal-head h3 {
  margin: 0;
  font-size: 18px;
  color: #fff;
}
.modal-close-btn {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 16px;
  border-radius: 8px;
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
}
.modal-close-btn:hover {
  color: #fff;
  border-color: var(--gold-2);
}
.format-options-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: rgba(11, 18, 32, 0.6);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  margin-top: 6px;
}
.fmt-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: #e2e8f0;
  cursor: pointer;
  user-select: none;
}
.fmt-checkbox input[type="checkbox"] {
  width: 24px;
  height: 24px;
  min-width: 24px;
  min-height: 24px;
  accent-color: var(--gold-2);
  cursor: pointer;
  margin: 0;
}
.email-preview-box {
  background: #080c14;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
}
.email-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--gold-2);
  margin-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding-bottom: 6px;
}
.email-body-code {
  margin: 0;
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 11px;
  color: #cbd5e1;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 140px;
  overflow-y: auto;
  line-height: 1.45;
}
.modal-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
}
@media (max-width: 600px) {
  .modal-card { padding: 16px; }
  .modal-actions { flex-direction: column; align-items: stretch; }
  .modal-actions .btn { width: 100%; justify-content: center; }
}

/* ==========================================================================
   Signed Sheet Table Column Badges & Action Buttons
   ========================================================================== */
.signed-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
  white-space: nowrap;
}
.signed-badge.done {
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
}
.signed-badge.pending {
  background: rgba(217, 119, 6, 0.15);
  border: 1px solid rgba(217, 119, 6, 0.35);
  color: #fbbf24;
}
.signed-doc-link {
  color: var(--gold-2);
  text-decoration: underline;
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
}
.signed-actions-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.signed-btn-row {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-wrap: wrap;
}

/* ==========================================================================
   Print-Only Hard-Copy Sign-Off Sheet Styling
   ========================================================================== */
.print-only {
  display: none;
}

/* ==========================================================================
   Direct Signed Record Upload Panel & Past Record Editor Modal
   ========================================================================== */
.signed-upload-panel {
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed var(--line);
  border-radius: 10px;
  padding: 12px 14px;
}
.sup-header strong {
  font-size: 13px;
  color: var(--gold);
}
.sup-controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  align-items: end;
}
.sup-file-row {
  display: flex;
  gap: 8px;
  align-items: center;
}
.modal-card.modal-wide {
  max-width: 780px;
}
.shift-deleted-row {
  opacity: 0.6;
}
.shift-deleted-row td:first-child,
.shift-deleted-row td:nth-child(2) {
  text-decoration: line-through;
}
.deleted-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
  margin-left: 6px;
}

/* ==========================================================================
   Bottom Scan & Share QR Code Card
   ========================================================================== */
.share-card {
  margin-top: 20px;
}
.share-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  align-items: center;
}
.qr-box-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.qr-frame {
  background: #ffffff;
  padding: 10px;
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45), 0 0 0 2px rgba(217, 119, 6, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
#appQrCanvas {
  width: 190px;
  height: 190px;
  display: block;
  border-radius: 6px;
}
.qr-caption {
  margin: 8px 0 0;
  font-size: 11px;
}
.share-details h2 {
  margin: 0 0 6px;
}
.share-link-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.share-link-row input {
  flex: 1;
  min-width: 220px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
}
.share-social-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
@media (max-width: 720px) {
  .share-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .share-link-row {
    justify-content: center;
  }
  .share-social-row {
    justify-content: center;
  }
}

@media print {
  /* Hide standard web UI */
  .site-header, .topbar, .wrap, .modal-backdrop, #toast, .no-print {
    display: none !important;
  }
  html, body {
    background: #fff !important;
    color: #000 !important;
    font-size: 12pt;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
  }
  .print-only {
    display: block !important;
  }
  .print-sheet {
    max-width: 100% !important;
    margin: 0 !important;
    padding: 12mm 15mm !important;
    font-family: Arial, "Helvetica Neue", Helvetica, sans-serif !important;
    color: #111 !important;
    background: #fff !important;
  }
  .ps-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 2pt solid #000;
    padding-bottom: 8pt;
    margin-bottom: 12pt;
  }
  .ps-brand h1 {
    margin: 0 0 4pt;
    font-size: 18pt;
    font-weight: bold;
    color: #000;
  }
  .ps-brand p {
    margin: 1pt 0;
    font-size: 10pt;
    color: #333;
  }
  .ps-title-block {
    text-align: right;
  }
  .ps-title-block h2 {
    margin: 0 0 3pt;
    font-size: 14pt;
    font-weight: bold;
    letter-spacing: 0.04em;
    color: #000;
  }
  .ps-title-block p {
    margin: 0;
    font-size: 9pt;
    color: #555;
  }
  .ps-meta-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6pt 12pt;
    background: #f8f8f8;
    border: 1pt solid #ccc;
    padding: 8pt 10pt;
    border-radius: 4pt;
    font-size: 10pt;
    margin-bottom: 14pt;
  }
  .ps-table {
    width: 100% !important;
    border-collapse: collapse !important;
    font-size: 10pt !important;
    margin-bottom: 14pt !important;
  }
  .ps-table th, .ps-table td {
    border: 1pt solid #444 !important;
    padding: 6pt 8pt !important;
    text-align: left;
    color: #000 !important;
  }
  .ps-table th {
    background: #eee !important;
    font-weight: bold !important;
  }
  .ps-table td.num, .ps-table th.num {
    text-align: right !important;
  }
  .ps-sig-cell {
    min-height: 28pt;
    border-bottom: 1pt dashed #666;
  }
  .ps-total-row td {
    font-weight: bold !important;
    background: #f5f5f5 !important;
    border-top: 2pt solid #000 !important;
  }
  .ps-ack-box {
    border: 1pt solid #999;
    padding: 10pt;
    border-radius: 4pt;
    font-size: 8.5pt;
    line-height: 1.45;
    background: #fafafa;
    page-break-inside: avoid;
  }
  .ps-ack-box p {
    margin: 0 0 10pt;
    color: #222;
  }
  .ps-sign-row {
    display: flex;
    justify-content: space-between;
    gap: 40pt;
    margin-top: 18pt;
  }
  .ps-sign-col {
    flex: 1;
  }
  .ps-sign-col.ps-date-col {
    max-width: 180pt;
  }
  .ps-line {
    border-bottom: 1pt solid #000;
    height: 20pt;
    margin-bottom: 4pt;
  }
  .ps-sign-col p {
    font-size: 9pt;
    margin: 0;
    color: #333;
    font-weight: bold;
  }
}
