:root {
  --ink: #12293a;
  --muted: #607486;
  --paper: #eef4f8;
  --line: #d5e0e8;
  --panel: #ffffff;
  --green: #0b5b86;
  --green-dark: #073b5e;
  --blue: #0b4f7a;
  --red: #9f4a3e;
  --gold: #d8a441;
  --shadow: 0 18px 45px rgba(7, 59, 94, .12);
}

* {
  box-sizing: border-box;
}

html {
  width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: linear-gradient(180deg, #eaf2f7, #f7fafc);
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

.shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 24px;
  color: #fff;
  background: linear-gradient(180deg, rgba(6, 50, 80, .94), rgba(5, 31, 51, .98)), url("/silva-brand-cover.png");
  background-position: center;
  background-size: cover;
  border-right: 1px solid rgba(255, 255, 255, .16);
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 28px;
}

.brand img {
  width: 56px;
  height: 56px;
  border-radius: 0;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .22);
}

.brand strong {
  display: block;
  font-size: 28px;
  letter-spacing: 0;
}

.brand span,
.login p,
.session span {
  color: rgba(255, 255, 255, .72);
}

.login,
.session {
  display: grid;
  gap: 12px;
  margin-bottom: 26px;
  padding: 16px;
  background: rgba(255, 255, 255, .09);
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 8px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.login label {
  color: rgba(255, 255, 255, .78);
}

input,
select,
textarea {
  width: 100%;
  min-height: 40px;
  padding: 9px 10px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(39, 101, 82, .14);
}

.login button,
.session button,
.topbar button,
.filters button,
.formActions button {
  min-height: 40px;
  padding: 0 14px;
  color: #fff;
  background: var(--blue);
  border-radius: 6px;
  font-weight: 800;
}

.session button {
  background: rgba(255, 255, 255, .18);
}

.tabs {
  display: grid;
  gap: 8px;
}

.tabs button {
  min-height: 42px;
  padding: 0 14px;
  color: rgba(255, 255, 255, .78);
  text-align: left;
  background: transparent;
  border-radius: 6px;
  font-weight: 800;
}

.tabs button.active,
.tabs button:hover {
  color: #fff;
  background: rgba(255, 255, 255, .14);
}

main {
  min-width: 0;
  padding: 26px;
}

.topbar,
.panelHead,
.filters,
.headActions,
.formActions {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}

.topbar {
  margin-bottom: 20px;
  padding: 22px;
  color: #fff;
  background: linear-gradient(90deg, rgba(7, 59, 94, .98), rgba(11, 79, 122, .86)), url("/silva-brand-cover.png");
  background-position: center;
  background-size: cover;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.topbar p,
.panelHead p {
  margin: 0 0 4px;
  color: var(--muted);
}

.topbar p {
  color: rgba(255, 255, 255, .76);
}

h1,
h2 {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  font-size: 28px;
}

h2 {
  font-size: 20px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.stats div,
.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.stats div {
  display: grid;
  gap: 7px;
  padding: 16px;
  border-top: 4px solid var(--blue);
}

.stats span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.stats strong {
  font-size: 24px;
}

.panel {
  min-width: 0;
  overflow: hidden;
}

.panelHead {
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.filters {
  flex-wrap: wrap;
  justify-content: flex-end;
  min-width: 0;
}

.filters input {
  width: 280px;
}

.filters select {
  width: 170px;
}

.headActions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.headActions button,
#generateProposalButton {
  min-height: 40px;
  padding: 0 14px;
  color: #fff;
  background: var(--blue);
  border-radius: 6px;
  font-weight: 800;
}

.tableWrap {
  max-width: 100%;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  min-width: 1080px;
  border-collapse: collapse;
}

th,
td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

td {
  font-size: 14px;
}

.rowActions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.rowActions button {
  min-height: 30px;
  padding: 0 9px;
  color: #fff;
  background: var(--blue);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}

.rowActions button[data-action="delete"] {
  background: var(--red);
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  color: #fff;
  background: var(--blue);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.pill.confirmado {
  background: var(--blue);
}

.pill.enviado {
  background: #6d8291;
}

.pill.aprovado {
  background: var(--green);
}

.pill.realizado {
  background: var(--gold);
}

.pill.passado {
  background: #7d7467;
}

.pill.negociacao {
  background: var(--red);
}

.pill.rascunho {
  color: var(--ink);
  background: #ece4d5;
}

.inlineSelect {
  display: block;
  width: 150px;
  min-height: 30px;
  margin-top: 6px;
  padding: 0 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}

.eventForm {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  padding: 18px;
}

.wide {
  grid-column: span 2;
}

.notes {
  grid-column: span 4;
}

.formActions {
  grid-column: span 4;
  justify-content: flex-end;
}

.formMessage {
  grid-column: span 4;
  min-height: 20px;
  margin: 0;
  color: var(--red);
  font-weight: 800;
}

.toggleField {
  align-content: center;
}

.toggleField input {
  width: 18px;
  min-height: 18px;
  margin: 6px 0;
  accent-color: var(--green);
}

.toggleField span {
  color: var(--blue);
  font-size: 13px;
  font-weight: 900;
}

.discountControl {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.discountControl select,
.discountControl input {
  width: 100%;
}

.formActions button {
  color: var(--ink);
  background: #ece4d5;
}

.formActions .primary {
  color: #fff;
  background: var(--blue);
}

.quoteTotal {
  display: grid;
  gap: 6px;
  min-height: 66px;
  padding: 13px;
  background: #eef4f8;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.quoteTotal span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.quoteTotal strong {
  font-size: 20px;
}

.formWarning {
  grid-column: span 4;
  min-height: 20px;
  padding: 12px 14px;
  color: #7a371f;
  background: #fff3eb;
  border: 1px solid #efc8b5;
  border-radius: 8px;
  font-weight: 700;
}

.pill.conflict {
  background: #7a371f;
}

.pill.late {
  background: #b91c1c;
}

.pill.cancelado {
  background: #4b1113;
}

.stats div.statAlert {
  border-top-color: #b91c1c;
}

.pipelineCard.lateCard {
  border-left: 3px solid #b91c1c;
}

.taskAreaBlock {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.taskAreaBlock:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.taskAreaHeader {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.taskAreaHeader small {
  color: var(--muted);
  font-size: 12px;
  margin-right: auto;
}

.taskAreaNotify {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 5px;
}

.extractStats {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  padding: 18px;
  background: #f7fafc;
  border-bottom: 1px solid var(--line);
}

.extractStats div {
  display: grid;
  gap: 6px;
  min-height: 92px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--blue);
  border-radius: 8px;
}

.extractStats span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.extractStats strong {
  color: var(--blue);
  font-size: 20px;
}

.extractStats small {
  color: var(--muted);
  font-size: 11px;
}

.extractTable {
  min-width: 960px;
}

.pipelineSummary,
.billingBoard {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  padding: 18px;
  background: #f7fafc;
  border-bottom: 1px solid var(--line);
}

.pipelineSummary div,
.billingBoard article {
  display: grid;
  gap: 6px;
  min-height: 92px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--green);
  border-radius: 8px;
}

.pipelineSummary span,
.billingBoard span,
.pipelineColumn > div span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.pipelineSummary strong,
.billingBoard strong,
.pipelineColumn > div strong {
  color: var(--blue);
  font-size: 20px;
}

.pipelineSummary small,
.billingBoard small,
.pipelineColumn small {
  color: var(--muted);
  font-size: 11px;
}

.pipelineBoard {
  display: grid;
  grid-template-columns: repeat(5, minmax(210px, 1fr));
  gap: 12px;
  padding: 18px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  background: #fffaf4;
  border-bottom: 1px solid var(--line);
}

.pipelineColumn {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 360px;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.pipelineColumn > div {
  display: grid;
  gap: 5px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.pipelineCard {
  display: grid;
  gap: 5px;
  padding: 10px;
  background: #f7fafc;
  border: 1px solid var(--line);
  border-left: 4px solid var(--blue);
  border-radius: 8px;
}

.pipelineCard span {
  color: var(--ink);
  font-size: 12px;
}

.panelSubhead {
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.panelSubhead h3 {
  margin: 0;
}

.panelSubhead p {
  margin: 4px 0 0;
  color: var(--muted);
}

.eventDetail {
  margin: 18px;
  padding: 18px;
  background: #f7fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.detailHead {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.detailHead span,
.detailGrid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.detailHead h3 {
  margin: 4px 0 0;
  font-size: 22px;
}

.detailHead button {
  min-height: 36px;
  padding: 0 12px;
  color: #fff;
  background: var(--blue);
  border-radius: 6px;
  font-weight: 800;
}

.detailGrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.detailGrid div {
  display: grid;
  gap: 5px;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.detailNotes {
  margin-top: 14px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.detailNotes h4 {
  margin: 0 0 8px;
}

.detailNotes p {
  margin: 0;
  color: var(--muted);
}

.catalogLayout {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 18px;
  padding: 18px;
}

.menuForm,
.responsibleForm {
  display: grid;
  align-self: start;
  gap: 14px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.menuForm .wide {
  grid-column: auto;
}

.custoItensPicker {
  display: flex;
  gap: 8px;
  align-items: center;
}

.custoItensPicker select {
  flex: 1;
}

.custoItensPicker input {
  width: 90px;
}

.custoItensList {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.custoItensList li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 10px;
  background: var(--paper, #f5f7f8);
  border: 1px solid var(--line);
  border-radius: 6px;
  font-size: 13px;
}

.custoItensList li.empty {
  color: var(--muted, #666);
  background: transparent;
  border-style: dashed;
}

.responsibleLayout {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 18px;
  padding: 18px;
}

.responsibleGrid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.responsibleCard {
  display: grid;
  gap: 8px;
  align-content: start;
  min-height: 96px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--blue);
  border-radius: 8px;
}

.responsibleCard span {
  color: var(--muted);
  font-weight: 800;
}

.responsibleCard button {
  width: 100%;
  margin-top: 8px;
}

#accountPinMessage {
  min-height: 18px;
}

.deletedNotice {
  border-left: 5px solid #7d7467;
}

.catalogGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.catalogCard {
  display: grid;
  gap: 12px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.catalogCard h3,
.quoteSection h3 {
  margin: 8px 0 4px;
  font-size: 17px;
}

.catalogCard p,
.quoteSection p,
.quoteFooter p {
  margin: 0;
  color: var(--muted);
}

.catalogCard strong {
  font-size: 20px;
}

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

.catalogCard ul,
.quoteSection ul {
  margin: 0;
  padding-left: 18px;
  color: var(--ink);
}

.quotePaper {
  width: 100%;
  max-width: 1180px;
  margin: 18px auto;
  padding: clamp(12px, 2vw, 22px);
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.proposalTools {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 18px;
  background: #f7fafc;
  border-bottom: 1px solid var(--line);
}

.proposalTools .wide {
  grid-column: span 2;
}

.proposalIntro {
  margin: 30px 0 22px;
  min-height: 220px;
  display: grid;
  align-content: end;
  padding: 30px;
  color: #fff;
  background: linear-gradient(90deg, rgba(7, 59, 94, .96), rgba(11, 79, 122, .48)), url("/vista-mar-silva-real.jpg");
  background-position: center;
  background-size: cover;
  border-radius: 8px;
}

.proposalIntro span {
  color: rgba(255, 255, 255, .75);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.proposalIntro h2 {
  max-width: 680px;
  margin-top: 8px;
  font-size: 34px;
  line-height: 1.05;
}

.proposalIntro p {
  max-width: 680px;
  margin: 10px 0 0;
  color: rgba(255, 255, 255, .82);
}

.letterhead {
  display: grid;
  grid-template-columns: 74px 1fr auto;
  gap: 16px;
  align-items: center;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--blue);
}

.letterhead img {
  width: 74px;
  height: 74px;
  border-radius: 0;
}

.letterhead strong {
  display: block;
  font-size: 32px;
}

.letterhead span,
.letterhead small {
  color: var(--muted);
  font-weight: 800;
}

.quoteTitle {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin: 24px 0 30px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.quoteTitle div {
  display: grid;
  gap: 5px;
  min-height: 78px;
  padding: 13px;
  background: #f7fafc;
  border-radius: 0;
}

.quoteTitle span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.quoteSection {
  margin: 24px 0;
}

.quoteSection h3 {
  padding-bottom: 7px;
  border-bottom: 1px solid var(--line);
  color: var(--blue);
}

.quoteSection.responsibilities {
  padding: 16px;
  background: #eef4f8;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.proposalGallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.proposalGallery figure {
  margin: 0;
  overflow: hidden;
  background: #f7fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.proposalGallery img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: var(--blue);
  border-radius: 0;
}

.proposalGallery figcaption {
  padding: 10px 12px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.proposalDeck {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.proposalPage {
  position: relative;
  display: grid;
  gap: 18px;
  width: 100%;
  max-width: 1120px;
  min-height: 540px;
  min-width: 0;
  margin: 0 auto;
  overflow: hidden;
  padding: clamp(24px, 3.4vw, 38px);
  background: #fffaf4;
  border: 1px solid #eadccb;
  border-radius: 8px;
  box-shadow: 0 12px 34px rgba(23, 36, 44, .08);
}

.coverPage {
  min-height: 570px;
  padding: 0;
  color: #fff;
  background: linear-gradient(135deg, #073b5e, #0b4f7a 58%, #163f3c);
}

.coverPage > img,
.photoStatement > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.coverPage::after,
.photoStatement::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(7, 35, 52, .84), rgba(7, 35, 52, .18));
}

.coverOverlay {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: end;
  max-width: 720px;
  min-height: min(570px, 74vh);
  padding: clamp(30px, 4vw, 46px);
}

.coverOverlay img {
  width: 86px;
  height: 86px;
  margin-bottom: 38px;
  background: rgba(255, 255, 255, .9);
}

.coverOverlay span,
.pageHeader span,
.photoStatement span,
.quoteTitle span,
.budgetCards span,
.signatureGrid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.coverOverlay span {
  color: rgba(255, 255, 255, .76);
}

.coverOverlay h2 {
  margin: 8px 0 0;
  font-size: clamp(48px, 7vw, 72px);
  line-height: .92;
  letter-spacing: 0;
}

.coverOverlay p {
  max-width: 560px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, .86);
  font-size: 20px;
}

.pageHeader {
  display: grid;
  gap: 8px;
  max-width: 820px;
}

.pageHeader h3,
.photoStatement h3 {
  margin: 0;
  color: var(--blue);
  font-size: clamp(28px, 3.8vw, 36px);
  line-height: 1.02;
}

.pageHeader p,
.photoStatement p,
.conditionGrid p,
.budgetCards small {
  margin: 0;
  color: var(--muted);
}

.summaryLayout,
.menuLayout,
.drinksLayout {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, .95fr);
  gap: 26px;
  align-items: stretch;
}

.summaryLayout,
.menuLayout,
.drinksLayout {
  grid-template-columns: 1fr;
}

.summaryLayout .quoteTitle {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
}

.sidePhoto,
.imageMosaic figure {
  margin: 0;
  overflow: hidden;
  border-radius: 8px;
}

.sidePhoto img,
.imageMosaic img,
.stackedPhotos img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photoStatement {
  align-content: end;
  min-height: 540px;
  color: #fff;
  background: var(--blue);
}

.photoStatement > div {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.photoStatement span,
.photoStatement p {
  color: rgba(255, 255, 255, .8);
}

.photoStatement h3 {
  color: #fff;
}

.imageMosaic {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  grid-template-rows: repeat(2, 220px);
  gap: 14px;
}

.imageMosaic.large {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: 520px;
}

.imageMosaic figure:first-child {
  grid-row: span 2;
}

.imageMosaic.large figure:first-child {
  grid-row: auto;
}

.imageMosaic figcaption {
  position: absolute;
  left: 12px;
  bottom: 12px;
  padding: 8px 10px;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  background: rgba(7, 35, 52, .72);
  border-radius: 6px;
}

.imageMosaic figure {
  position: relative;
  background: var(--blue);
}

.photoSpread {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: minmax(310px, 390px);
  gap: 14px;
}

.logoPhotoPage {
  align-content: center;
}

.proposalPhotoLogo {
  position: absolute;
  z-index: 2;
  top: 28px;
  left: 28px;
  width: 74px;
  height: 74px;
  background: rgba(255, 255, 255, .92);
  border-radius: 0;
}

.photoSpread figure {
  position: relative;
  margin: 0;
  overflow: hidden;
  background: var(--blue);
  border-radius: 8px;
}

.photoSpread img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photoSpread figcaption {
  position: absolute;
  left: 12px;
  bottom: 12px;
  padding: 8px 10px;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  background: rgba(7, 35, 52, .72);
  border-radius: 6px;
}

.bookPage {
  align-content: center;
}

.bookPage .pageHeader {
  max-width: 860px;
}

.bookPage .pageHeader p {
  font-size: 18px;
  line-height: 1.5;
}

.menuLayout ul,
.drinksLayout ul,
.responsibilities ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.42;
}

.proposalMenuList {
  display: grid;
  gap: 10px;
}

.proposalMenuList span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.proposalMenuList h4 {
  margin: 0;
  color: var(--blue);
  font-size: 24px;
}

.proposalMenuList ul {
  display: grid;
  gap: 9px;
  margin: 0;
  padding-left: 20px;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.42;
}

.budgetMenuLists {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.budgetMenuLists .proposalMenuList {
  padding: 16px;
  background: #f7efe5;
  border: 1px solid #eadccb;
  border-radius: 8px;
}

.budgetMenuLists .proposalMenuList ul {
  font-size: 13px;
  line-height: 1.32;
}

.budgetMenuLists .proposalMenuList h4 {
  font-size: 18px;
}

.stackedPhotos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  min-height: 330px;
}

.stackedPhotos img {
  border-radius: 8px;
}

.drinksLayout {
  grid-template-columns: minmax(340px, .95fr) minmax(0, 1.05fr);
}

.budgetCards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  min-width: 0;
}

.budgetCards div,
.conditionGrid div {
  display: grid;
  gap: 6px;
  padding: 16px;
  background: #f7efe5;
  border: 1px solid #eadccb;
  border-radius: 8px;
}

.budgetCards strong {
  color: var(--blue);
  font-size: 30px;
}

.budgetCards .total {
  color: #fff;
  background: var(--blue);
}

.budgetCards .total span,
.budgetCards .total small,
.budgetCards .total strong {
  color: #fff;
}

.conditionGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.legalPage {
  align-content: start;
}

.legalPage .pageHeader h3 {
  font-size: 28px;
}

.legalPage .conditionGrid p,
.legalPage .responsibilities ul,
.legalPage .quoteFooter p,
.acceptanceBlock p {
  font-size: 12px;
  line-height: 1.35;
}

.legalPage .conditionGrid strong,
.legalPage .quoteFooter strong {
  font-size: 13px;
}

.legalPage .responsibilities {
  padding: 14px;
  background: #f7efe5;
  border: 1px solid #eadccb;
  border-radius: 8px;
}

.instagramNote {
  display: block;
  margin-top: 8px;
  color: var(--muted);
}

.quoteTable {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
  margin-top: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.quoteTable th,
.quoteTable td {
  word-break: break-word;
}

.quoteTable th {
  background: #eef4f8;
}

.quoteTable tfoot td {
  color: #fff;
  background: var(--blue);
  font-size: 18px;
  font-weight: 900;
}

.quoteFooter {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 28px;
  padding: 18px;
  color: #fff;
  background: var(--blue);
  border-radius: 8px;
}

.quoteFooter p {
  color: rgba(255, 255, 255, .82);
}

.acceptanceBlock {
  margin-top: 28px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.proposalPage.acceptanceBlock {
  margin-top: 0;
  padding: 48px;
  border-color: #eadccb;
}

.acceptanceBlock h3 {
  margin: 0 0 8px;
}

.acceptanceBlock p {
  margin: 0 0 18px;
  color: var(--muted);
}

.signatureGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.signatureGrid div {
  display: grid;
  gap: 6px;
  padding: 12px;
  background: #f7fafc;
  border-radius: 8px;
}

.signatureGrid span,
.signatureLine span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.signatureLine {
  display: grid;
  gap: 32px;
  margin-top: 32px;
  padding-top: 12px;
  border-top: 1px solid var(--ink);
}

.taskGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 18px;
}

.taskCard {
  padding: 15px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.taskCard h3 {
  margin: 0 0 10px;
  font-size: 15px;
}

.taskCard label {
  display: flex;
  grid-template-columns: none;
  gap: 10px;
  align-items: flex-start;
  padding: 9px 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  border-top: 1px solid #eee8dd;
}

.taskCard input {
  width: 18px;
  min-height: 18px;
  margin-top: 1px;
  accent-color: var(--green);
}

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

.noticeList {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.notice {
  display: grid;
  gap: 4px;
  padding: 13px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.notice.unread {
  border-left: 5px solid var(--gold);
}

.notice button {
  justify-self: start;
  min-height: 32px;
  margin-top: 5px;
  padding: 0 10px;
  color: #fff;
  background: var(--green);
  border-radius: 6px;
  font-weight: 800;
}

.empty {
  padding: 18px;
  color: var(--muted);
}

.hidden {
  display: none !important;
}

@media (max-width: 980px) {
  .shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .stats,
  .taskGrid,
  .catalogGrid,
  .extractStats,
  .pipelineSummary,
  .billingBoard {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .catalogLayout {
    grid-template-columns: 1fr;
  }

  .responsibleLayout {
    grid-template-columns: 1fr;
  }

  .eventForm {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .notes,
  .formActions {
    grid-column: span 2;
  }

  .summaryLayout,
  .menuLayout,
  .drinksLayout,
  .conditionGrid,
  .budgetCards,
  .budgetMenuLists,
  .imageMosaic.large,
  .photoSpread {
    grid-template-columns: 1fr;
  }

  .imageMosaic,
  .imageMosaic.large,
  .photoSpread {
    grid-template-rows: none;
  }

  .imageMosaic figure,
  .imageMosaic figure:first-child,
  .imageMosaic.large figure:first-child,
  .photoSpread figure,
  .photoSpread figure:first-child {
    grid-row: auto;
    min-height: 260px;
  }
}

@media (max-width: 640px) {
  main {
    padding: 14px;
  }

  .topbar,
  .panelHead {
    align-items: stretch;
    flex-direction: column;
  }

  .stats,
  .extractStats,
  .pipelineSummary,
  .billingBoard,
  .taskGrid,
  .eventForm,
  .catalogGrid,
  .responsibleGrid,
  .detailGrid,
  .quoteTitle,
  .proposalTools,
  .proposalGallery,
  .signatureGrid {
    grid-template-columns: 1fr;
  }

  .wide,
  .notes,
  .proposalTools .wide,
  .formActions {
    grid-column: span 1;
  }

  .filters input,
  .filters select {
    width: 100%;
  }

  .quotePaper {
    width: 100%;
    margin: 0;
    padding: 12px;
  }

  .proposalPage,
  .proposalPage.acceptanceBlock {
    min-height: auto;
    padding: 24px;
  }

  .coverPage,
  .photoStatement {
    min-height: 520px;
  }

  .coverOverlay {
    min-height: 520px;
    padding: 28px;
  }

  .coverOverlay h2 {
    font-size: 54px;
  }

  .pageHeader h3,
  .photoStatement h3 {
    font-size: 30px;
  }

  .stackedPhotos {
    grid-template-columns: 1fr;
  }

  .budgetCards strong {
    font-size: 24px;
  }

  .letterhead,
  .quoteFooter {
    grid-template-columns: 1fr;
    align-items: start;
    flex-direction: column;
  }
}

/* ─── View toggle ─────────────────────────────────────── */
.viewToggle {
  display: flex;
  border: 1.5px solid var(--line);
  border-radius: 7px;
  overflow: hidden;
}

.viewToggle button {
  flex: 1;
  min-height: 36px;
  padding: 0 14px;
  border: none;
  border-radius: 0;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: background .15s, color .15s;
}

.viewToggle button + button {
  border-left: 1.5px solid var(--line);
}

.viewToggle button.active {
  background: var(--blue);
  color: #fff;
}

/* ─── Kanban board ────────────────────────────────────── */
.kanbanBoard {
  display: flex;
  gap: 14px;
  padding: 18px;
  overflow-x: auto;
  align-items: flex-start;
}

.kanbanColumn {
  flex: 0 0 260px;
  min-width: 0;
  background: var(--bg);
  border: 1.5px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.kanbanColumnHeader {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 12px 14px;
  background: var(--panel);
  border-bottom: 1.5px solid var(--line);
}

.kanbanColumnHeader strong {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.kanbanColumnHeader span {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}

.kanbanColumnBody {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
}

.kanbanCard {
  background: var(--panel);
  border: 1.5px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.kanbanCard[data-status="confirmado"] { border-left: 3px solid var(--blue); }
.kanbanCard[data-status="em negociacao"] { border-left: 3px solid var(--red); }
.kanbanCard[data-status="realizado"] { border-left: 3px solid var(--gold); }
.kanbanCard[data-status="cancelado"] { border-left: 3px solid #4b1113; }
.kanbanCard[data-status="passado"] { border-left: 3px solid #7d7467; opacity: .8; }

.kanbanCardMeta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.kanbanCardTitle {
  font-size: 13px;
  line-height: 1.35;
}

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

.kanbanCardInfo {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
}

.kanbanCardFooter {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  border-top: 1px solid var(--line);
  padding-top: 6px;
  margin-top: 2px;
}

.kanbanCardFooter strong {
  font-size: 13px;
}

.kanbanCard .rowActions {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.kanbanCard .rowActions button {
  font-size: 11px;
  padding: 2px 8px;
  min-height: 26px;
}

@media print {
  body {
    background: #fff;
  }

  .sidebar,
  .topbar,
  .stats,
  .panel:not(#orcamentoPanel),
  #orcamentoPanel > .panelHead,
  .proposalTools {
    display: none !important;
  }

  .shell,
  main {
    display: block;
    padding: 0;
  }

  #orcamentoPanel {
    display: block !important;
    border: 0;
    box-shadow: none;
  }

  .quotePaper {
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    box-shadow: none;
  }

  .proposalDeck {
    gap: 0;
  }

  .proposalPage,
  .proposalPage.acceptanceBlock {
    width: 100%;
    min-height: 100vh;
    margin: 0;
    padding: 14mm;
    break-after: page;
    page-break-after: always;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .coverPage {
    padding: 0;
  }

  .coverOverlay {
    min-height: 100vh;
    padding: 18mm;
  }

  .proposalPage:last-child {
    break-after: auto;
    page-break-after: auto;
  }
}

/* ─── Painel de Custos ──────────────────────────────────────────────── */

.custosSection {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
}

.custosSection h3 {
  font-size: .875rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--muted);
  margin: 0 0 1rem;
}

.custosSection h4 {
  font-size: .85rem;
  color: var(--ink);
  margin: 0;
}

.custosTable {
  width: 100%;
  border-collapse: collapse;
  font-size: .875rem;
}

.custosTable th {
  text-align: left;
  padding: .4rem .5rem;
  border-bottom: 2px solid var(--line);
  color: var(--muted);
  font-weight: 600;
  white-space: nowrap;
}

.custosTable td {
  padding: .35rem .5rem;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.custosTable input[type="text"],
.custosTable input[type="number"] {
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: .25rem .4rem;
  font-size: .875rem;
  color: var(--ink);
  background: var(--paper);
  width: 100%;
}

.custosTable input[type="number"] {
  text-align: right;
}

.custoTotalRow td {
  border-top: 2px solid var(--line);
  padding-top: .5rem;
}

.custoPositivo td { color: #1a6b2e; }
.custoNegativo td { color: var(--red); }

.custosSummary .custosTable td { padding: .45rem .5rem; }

.btnPrimary {
  background: var(--green);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: .45rem 1rem;
  font-size: .875rem;
  cursor: pointer;
  font-weight: 600;
}

.btnPrimary:hover { background: var(--green-dark); }

.btnSecondary {
  background: transparent;
  color: var(--green);
  border: 1px solid var(--green);
  border-radius: 6px;
  padding: .4rem .9rem;
  font-size: .875rem;
  cursor: pointer;
  font-weight: 600;
}

.btnSecondary:hover { background: var(--paper); }

.btnDanger {
  background: transparent;
  color: var(--red);
  border: 1px solid var(--red);
  border-radius: 4px;
  padding: .2rem .5rem;
  font-size: .8rem;
  cursor: pointer;
  line-height: 1;
}

.btnDanger:hover { background: #fdf0ef; }

.btnSm { padding: .2rem .5rem; font-size: .78rem; }

.dimmed { color: var(--muted); font-size: .875rem; }

/* ─── Contrato ──────────────────────────────────────────────────────── */

.contratoTools {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.25rem 0;
  max-width: 720px;
}

.contratoTools label {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  font-size: .85rem;
  font-weight: 600;
  color: var(--muted);
}

.contratoTools input,
.contratoTools textarea {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: .45rem .6rem;
  font-size: .875rem;
  color: var(--ink);
  background: var(--paper);
  font-family: inherit;
}

.contratoTools textarea {
  resize: vertical;
}

.contratoStatusBar {
  padding: .6rem .9rem;
  border-radius: 6px;
  background: var(--paper);
  border: 1px solid var(--line);
  font-size: .85rem;
}

.contratoStatusDetail {
  margin-top: 1rem;
}

.pill-orange {
  background: #fff3e0;
  color: #b26000;
  border: 1px solid #f5c07a;
}

.pill-green {
  background: #e6f4ea;
  color: #1a6b2e;
  border: 1px solid #7fcf96;
}

.pill-grey {
  background: var(--paper);
  color: var(--muted);
  border: 1px solid var(--line);
}

.contratoDoc {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 48px 56px;
  max-width: 800px;
  margin: 1.5rem auto;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 13px;
  line-height: 1.75;
  color: #12293a;
}

.contratoDoc h2 {
  font-size: 13px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: 1.5rem;
}

.contratoDoc h3 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin: 2rem 0 .5rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: .3rem;
}

.contratoDoc p {
  margin: .6rem 0;
}

@media print {
  aside, nav, .topbar, .stats, .panelHead, .contratoTools, #custosPanel,
  #orcamentoPanel .proposalTools, .proposalTools {
    display: none !important;
  }
  .contratoDoc {
    border: none;
    padding: 0;
    margin: 0;
    max-width: 100%;
  }
}

.checkLabel {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-size: .875rem;
  cursor: pointer;
  color: var(--text);
}
.checkLabel input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  accent-color: var(--accent, #0b4f7a);
  cursor: pointer;
}

/* ── Proposta navegável ─────────────────────────────────────────── */
.altDatesGroup {
  border: 1px solid var(--border, #d5e0e8);
  border-radius: 8px;
  padding: 16px;
  margin-top: 12px;
}
.altDatesGroup legend {
  font-size: .75rem;
  font-weight: 600;
  color: var(--accent, #0b4f7a);
  padding: 0 6px;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.altDateRow {
  display: flex;
  gap: 16px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.altDateRow label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: .8rem;
  color: var(--text-muted, #6b8899);
}
.altDateRow input {
  padding: 6px 10px;
  border: 1px solid var(--border, #d5e0e8);
  border-radius: 6px;
  font-size: .9rem;
  width: 160px;
}
.altDateRow input[type="number"] {
  width: 80px;
}
.altDatesFormSection {
  margin-top: 8px;
}
.altDatesFormHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.proposalLinkBox {
  margin-top: 12px;
  background: #e8f4ec;
  border: 1px solid #a8d5b0;
  border-radius: 8px;
  padding: 14px 16px;
}
.proposalLinkBox label {
  font-size: .8rem;
  font-weight: 600;
  color: #1a5c2a;
}
.proposalLinkRow {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  flex-wrap: wrap;
}
.proposalLinkRow input {
  flex: 1;
  min-width: 180px;
  padding: 6px 10px;
  border: 1px solid #a8d5b0;
  border-radius: 6px;
  font-size: .85rem;
  background: #fff;
  color: #1a2e3b;
}

/* ── Checklist por área ─────────────────────────────────────────── */
.taskRow {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 4px 0;
}
.taskRow label {
  flex: 1;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  font-size: .9rem;
}
.btnIconSm {
  background: none;
  border: none;
  cursor: pointer;
  color: #c94b00;
  font-size: .8rem;
  padding: 4px 6px;
  border-radius: 4px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}
.btnIconSm:hover { background: #fce8e0; }
.checklistLink {
  font-size: .78rem;
  color: #1a7a40;
  text-decoration: none;
  background: #e8f4ec;
  border-radius: 4px;
  padding: 2px 8px;
  white-space: nowrap;
}
.checklistLink:hover { background: #d0ecda; }
.checklistPublishDetails {
  margin-top: 10px;
  border: 1px dashed #c0d0dc;
  border-radius: 8px;
  overflow: hidden;
}
.checklistPublishDetails summary {
  padding: 8px 12px;
  font-size: .82rem;
  font-weight: 600;
  color: #0b4f7a;
  cursor: pointer;
  user-select: none;
  background: #f0f6fb;
}
.checklistPublishDetails summary:hover { background: #e4f0f8; }
.checklistPublishForm {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.checklistPublishForm label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: .8rem;
  color: #5a7080;
}
.checklistPublishForm input,
.checklistPublishForm textarea {
  padding: 6px 10px;
  border: 1px solid #d0dde8;
  border-radius: 6px;
  font-size: .88rem;
  font-family: inherit;
  resize: vertical;
}
.altDatesProposalPage {
  padding: 48px 56px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}
.altDatesProposalGrid {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.altDateProposalCard {
  flex: 1;
  min-width: 220px;
  border: 1.5px solid #1a3a52;
  border-radius: 10px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: #f6fafd;
}
.altDateLabel {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #607486;
}
.altDateCardDate {
  font-size: 1.5rem;
  font-weight: 700;
  color: #12293a;
}
.altDateDiscount {
  font-size: .9rem;
  color: #1a5c2a;
  font-weight: 600;
  background: #e8f4ec;
  border-radius: 4px;
  padding: 2px 8px;
  display: inline-block;
  width: fit-content;
}
.altDatePrice {
  font-size: 1.6rem;
  font-weight: 800;
  color: #1a3a52;
  margin-top: 8px;
}
.altDateOriginal {
  font-size: .8rem;
  color: #607486;
  text-decoration: line-through;
}
.altDatesNote {
  font-size: .82rem;
  color: #607486;
  font-style: italic;
}
