* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Aptos, Segoe UI, Arial, sans-serif;
  color: #1F2933;
  background: #F5F7F8;
}

.hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: center;
  margin: 14px 22px 12px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid #DDE5E7;
  box-shadow: 0 18px 42px rgba(15, 92, 83, .12);
}

.hero-copy {
  padding: clamp(18px, 3vw, 30px);
}

.hero h1 {
  margin: 0;
  max-width: 680px;
  color: #0F5C53;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.04;
  letter-spacing: 0;
}

.hero-title-row {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
}

.hero-title-row h1 {
  margin-bottom: 0;
  flex: 0 1 auto;
}

.product-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  width: clamp(390px, 30vw, 540px);
  max-width: 100%;
  flex: 0 1 clamp(390px, 30vw, 540px);
}

.product-gallery img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  max-height: 126px;
  object-fit: contain;
  background: #f7fbfa;
  border: 1px solid #DDE5E7;
}

@media (max-width: 980px) {
  .product-gallery {
    width: min(100%, 480px);
    flex-basis: min(100%, 480px);
  }
}

@media (max-width: 780px) {
  .hero-title-row {
    gap: 12px;
  }

  .product-gallery {
    width: min(100%, 420px);
    flex-basis: min(100%, 420px);
  }
}

.hero-text {
  max-width: 620px;
  margin: 12px 0 0;
  color: #425955;
  font-size: 16px;
  line-height: 1.6;
}

.hero-media {
  align-self: stretch;
  min-height: 340px;
}

.hero-gallery {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(120px, .56fr);
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 8px;
  background: #ffffff;
}

.hero-gallery img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
}

.hero-gallery-main {
  grid-row: 1 / span 2;
}

.whatsapp-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin-top: 24px;
  padding: 0 18px;
  color: #ffffff;
  background: #1f8f5f;
  font-weight: 700;
  text-decoration: none;
}

.whatsapp-link:hover {
  color: #ffffff;
  background: #176d49;
}

.app-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 28px;
  color: white;
  background: #0F5C53;
}

.eyebrow {
  margin: 0 0 6px;
  color: #D5E9E5;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: 30px;
  line-height: 1.1;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: 30px;
  line-height: 1.1;
  letter-spacing: 0;
}

.totals {
  display: flex;
  gap: 12px;
}

.totals div {
  min-width: 136px;
  padding: 10px 14px;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.22);
}

.totals span {
  display: block;
  color: #cfe3e0;
  font-size: 12px;
}

.totals strong {
  display: block;
  margin-top: 4px;
  font-size: 24px;
}

main {
  padding: 22px;
}

.quote-panel {
  background: #ffffff;
  border: 1px solid #DDE5E7;
}

.toolbar {
  display: flex;
  gap: 10px;
  padding: 14px;
  border-bottom: 1px solid #DDE5E7;
}

button {
  border: 0;
  padding: 9px 14px;
  color: #ffffff;
  background: #157A6E;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

button.secondary {
  color: #0F5C53;
  background: #e3efed;
}

button.icon {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 50%;
  line-height: 30px;
}

button.delete {
  background: #c0392b;
}

.table-wrap {
  overflow: auto;
}

.quote-note {
  margin: 0;
  padding: 14px 16px;
  color: #0F5C53;
  background: #F5F7F8;
  border-top: 1px solid #DDE5E7;
  font-size: 14px;
  font-weight: 700;
}

.discount-callout {
  margin: 16px;
  padding: 18px;
  color: #0F5C53;
  background: #fff8e8;
  border: 1px solid #efd79f;
  border-left: 5px solid #C89B3C;
}

.discount-callout strong {
  display: block;
  max-width: 980px;
  font-size: 16px;
  line-height: 1.45;
}

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

th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 12px 8px;
  color: #ffffff;
  background: #157A6E;
  border-right: 1px solid rgba(255,255,255,.28);
  font-size: 13px;
  text-align: left;
}

td {
  padding: 7px 6px;
  border: 1px solid #d3dee2;
  background: #eef6ff;
  vertical-align: middle;
}

td.pos {
  width: 48px;
  text-align: center;
  background: #eef2f4;
}

select,
input {
  width: 100%;
  min-height: 32px;
  border: 1px solid #b9ced2;
  padding: 6px 8px;
  font: inherit;
  color: #1F2933;
  background: #d8f5c6;
}

input.qty {
  max-width: 72px;
}

.money {
  min-width: 110px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

tr.invalid td {
  background: #ffe2df;
}

@media (max-width: 780px) {
  .hero {
    grid-template-columns: 1fr;
    margin: 10px;
  }

  .hero-media {
    min-height: 240px;
    order: -1;
  }

  .hero-gallery {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1.1fr .9fr;
  }

  .hero-gallery-main {
    grid-column: 1 / span 2;
    grid-row: auto;
  }

  .app-header {
    align-items: stretch;
    flex-direction: column;
  }

  .totals {
    flex-direction: column;
  }

  main {
    padding: 10px;
  }
}

.app-home-button {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  color: #ffffff;
  background: #157A6E;
  border: 1px solid rgba(255,255,255,.25);
  box-shadow: 0 10px 28px rgba(15, 92, 83, .24);
  font-weight: 800;
  text-decoration: none;
}

.app-home-button:hover {
  color: #ffffff;
  background: #176d49;
}

.app-list-button {
  right: 126px;
  background: #0F5C53;
}

.hero-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  color: #0F5C53;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.hero-brand img {
  width: 62px;
  height: 62px;
  object-fit: contain;
  padding: 7px;
  background: #ffffff;
  border: 1px solid #DDE5E7;
  box-shadow: 0 10px 24px rgba(15, 92, 83, .12);
}
.site-return-button {
  position: fixed;
  left: 18px;
  bottom: 18px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  color: #ffffff;
  background: #0F5C53;
  border: 1px solid rgba(255,255,255,.25);
  box-shadow: 0 10px 28px rgba(15, 92, 83, .24);
  font-weight: 800;
  text-decoration: none;
}

.site-return-button:hover {
  background: #157A6E;
}
body .site-return-button {
  left: 18px !important;
  right: auto !important;
}

body .app-home-button {
  right: 18px !important;
  left: auto !important;
}

body .app-list-button {
  right: 126px !important;
}

@media (max-width: 780px) {
  body .app-home-button {
    right: 12px !important;
    bottom: 18px;
  }

  body .app-list-button {
    right: 12px !important;
    bottom: 70px;
  }

  body .site-return-button {
    left: auto !important;
    right: 12px !important;
    bottom: 122px;
  }
}
