:root {
  --ink: #1e2522;
  --muted: #5b6762;
  --paper: #f7f1e6;
  --panel: #fffdf7;
  --line: #d8d1c0;
  --green: #315d48;
  --green-2: #5e806d;
  --orange: #c75f35;
  --yellow: #e9bd55;
  --blue: #47758f;
  --shadow: 0 18px 50px rgba(30, 37, 34, .12);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--paper);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
  background:
    linear-gradient(90deg, rgba(49, 93, 72, .06), transparent 42%),
    var(--paper);
}

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

button {
  cursor: pointer;
}

a {
  color: inherit;
}

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

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 24px;
  border-right: 1px solid var(--line);
  background: rgba(255, 253, 247, .86);
  backdrop-filter: blur(16px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  text-decoration: none;
  font-weight: 850;
}

.brand img {
  flex: 0 0 auto;
}

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

.tab-button {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 10px 12px;
  color: var(--muted);
  background: transparent;
  text-align: left;
}

.tab-button span {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-weight: 800;
}

.tab-button.active {
  color: var(--ink);
  background: #f1eadb;
  border-color: var(--line);
}

.trust-panel {
  margin-top: auto;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #eef3ee;
}

.trust-panel p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.workspace {
  min-width: 0;
  padding: 28px;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.builder-grid {
  display: grid;
  grid-template-columns: minmax(320px, 460px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.sales-hero {
  min-height: calc(100vh - 56px);
  display: grid;
  grid-template-columns: minmax(320px, .95fr) minmax(0, 1.05fr);
  gap: 28px;
  align-items: stretch;
}

.sales-copy {
  display: grid;
  align-content: center;
  gap: 18px;
  min-width: 0;
}

.sales-copy h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(3rem, 7vw, 6.8rem);
  line-height: .9;
  letter-spacing: 0;
}

.sales-lede {
  max-width: 680px;
  margin: 0;
  color: var(--muted);
  font-size: 1.12rem;
  line-height: 1.55;
}

.price-lockup {
  width: min(100%, 420px);
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: #fffdf7;
}

.price-lockup span {
  color: var(--orange);
  font-size: .76rem;
  font-weight: 850;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.price-lockup strong {
  display: block;
  font-size: clamp(3.2rem, 9vw, 5.4rem);
  line-height: .95;
}

.price-lockup small {
  color: var(--muted);
  line-height: 1.45;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-proof span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #bfd0c4;
  border-radius: 999px;
  padding: 5px 10px;
  color: #254e39;
  background: #eaf1eb;
  font-size: .84rem;
  font-weight: 800;
}

.sales-visual {
  min-height: 620px;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.sales-visual img {
  display: block;
  width: 100%;
  height: calc(100% - 48px);
  min-height: 560px;
  object-fit: cover;
}

.sales-visual figcaption {
  min-height: 48px;
  display: flex;
  align-items: center;
  padding: 12px 14px;
  color: var(--muted);
  font-size: .92rem;
}

.control-panel,
.results-panel,
.admin-list-panel,
.admin-detail,
.policy-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 247, .94);
  box-shadow: var(--shadow);
}

.control-panel {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.panel-heading h1,
.section-heading h1,
.policy-panel h1 {
  margin: 4px 0 8px;
  font-size: clamp(2rem, 4vw, 3.8rem);
  line-height: .95;
  letter-spacing: 0;
}

.panel-heading p,
.section-heading p {
  margin: 0;
  color: var(--muted);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--orange);
  font-size: .78rem;
  font-weight: 850;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.field {
  display: grid;
  gap: 7px;
}

.field span,
.address-fields legend,
.segmented legend {
  color: var(--muted);
  font-size: .88rem;
  font-weight: 750;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid #c9c1ad;
  border-radius: 6px;
  padding: 10px 12px;
  color: var(--ink);
  background: #fff;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 3px solid rgba(71, 117, 143, .22);
  border-color: var(--blue);
}

.address-fields {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(130px, .6fr);
  gap: 12px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.address-fields legend {
  grid-column: 1 / -1;
  padding: 0;
}

.address-street,
.address-city {
  grid-column: 1 / -1;
}

.address-state {
  grid-column: span 1;
}

.address-zip {
  grid-column: span 1;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.segmented legend {
  grid-column: 1 / -1;
}

.segmented label,
.toggle-grid label {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #c9c1ad;
  border-radius: 6px;
  padding: 9px 10px;
  background: #fff;
}

.segmented label span {
  overflow-wrap: anywhere;
}

.segmented input,
.toggle-grid input {
  accent-color: var(--green);
}

.segmented label:has(input:checked) {
  border-color: var(--green);
  background: #eaf1eb;
  color: var(--green);
  font-weight: 800;
}

.inline-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

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

.consent-box {
  display: grid;
  gap: 9px;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #f4f8f4;
}

.consent-box legend {
  padding: 0 4px;
  color: var(--green);
  font-size: .88rem;
  font-weight: 850;
}

.consent-box label {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
  color: var(--muted);
  font-size: .9rem;
  line-height: 1.4;
}

.consent-box input {
  margin-top: 3px;
  accent-color: var(--green);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.primary-button,
.secondary-button,
.danger-button,
.primary-link-button,
.secondary-link-button {
  min-height: 44px;
  border-radius: 6px;
  padding: 10px 14px;
  font-weight: 850;
}

.primary-button {
  border: 1px solid var(--green);
  color: #fff;
  background: var(--green);
}

.primary-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--green);
  color: #fff;
  background: var(--green);
  text-decoration: none;
}

.secondary-button {
  border: 1px solid #b7ad98;
  color: var(--ink);
  background: #fff;
}

.secondary-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #b7ad98;
  color: var(--ink);
  background: #fff;
  text-decoration: none;
}

.danger-button {
  border: 1px solid #b64a31;
  color: #fff;
  background: #b64a31;
}

.primary-button[disabled],
.secondary-button[disabled],
.danger-button[disabled] {
  opacity: .56;
  cursor: wait;
}

.results-panel {
  min-height: calc(100vh - 56px);
  overflow: hidden;
}

.product-preview {
  display: grid;
  grid-template-columns: minmax(240px, 42%) minmax(0, 1fr);
  gap: 22px;
  align-items: end;
  padding: 22px;
  border-bottom: 1px solid var(--line);
  background: #edf2ee;
}

.product-preview img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid #c9c1ad;
  border-radius: 6px;
  background: #e8dfcd;
}

.product-preview h2 {
  margin: 0 0 8px;
  font-size: clamp(1.8rem, 4vw, 3.6rem);
  line-height: .98;
  letter-spacing: 0;
}

.product-preview p {
  color: var(--muted);
  line-height: 1.55;
}

.marketing-band {
  margin-top: 28px;
  padding: 30px 0 8px;
}

.marketing-heading {
  max-width: 860px;
  margin-bottom: 22px;
}

.marketing-heading h2 {
  margin: 0 0 10px;
  max-width: 820px;
  font-size: clamp(2rem, 5vw, 4.4rem);
  line-height: .96;
  letter-spacing: 0;
}

.marketing-heading p {
  margin: 0;
  max-width: 720px;
  color: var(--muted);
  line-height: 1.55;
}

.marketing-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 22px;
}

.marketing-image-card {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.marketing-image-card img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

.marketing-image-card figcaption {
  padding: 12px 14px;
  color: var(--muted);
  font-size: .92rem;
  line-height: 1.4;
}

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

.included-item {
  min-height: 190px;
  display: grid;
  align-content: start;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: rgba(255, 253, 247, .92);
}

.included-item span {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--green);
  font-weight: 850;
}

.included-item h3 {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.2;
}

.included-item p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.order-section {
  margin-top: 30px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.order-heading {
  max-width: 760px;
  margin-bottom: 18px;
}

.order-heading h2,
.compact-heading h3 {
  margin: 0 0 8px;
  letter-spacing: 0;
}

.order-heading h2 {
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: .96;
}

.order-heading p,
.compact-heading p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.snapshot-output {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.empty-state {
  min-height: 260px;
  align-content: center;
  color: var(--muted);
}

.status-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border-radius: 999px;
  padding: 5px 10px;
  color: var(--ink);
  background: #efe7d6;
  font-weight: 800;
  font-size: .84rem;
}

.pill.good {
  background: #dfeee2;
  color: #254e39;
}

.pill.warn {
  background: #f7e3ce;
  color: #8b3f21;
}

.pill.bad {
  background: #f1d5cd;
  color: #8a2c1d;
}

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

.mini-card {
  min-height: 152px;
  display: grid;
  gap: 8px;
  align-content: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fff;
}

.mini-card strong {
  text-transform: capitalize;
}

.mini-card span {
  color: var(--orange);
  font-weight: 850;
}

.mini-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.fact-list,
.admin-list {
  display: grid;
  gap: 10px;
}

.fact-row,
.admin-row {
  display: grid;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fff;
}

.fact-row strong,
.admin-row strong {
  overflow-wrap: anywhere;
}

.fact-row p,
.admin-row p {
  margin: 0;
  color: var(--muted);
  line-height: 1.4;
}

.guide-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.guide-actions a {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #b7ad98;
  border-radius: 6px;
  padding: 9px 12px;
  background: #fff;
  text-decoration: none;
  font-weight: 850;
}

.guide-actions a.primary-action {
  border-color: var(--green);
  color: #fff;
  background: var(--green);
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(300px, 420px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.admin-list-panel,
.admin-detail,
.policy-panel {
  padding: 22px;
}

.admin-list-panel {
  display: grid;
  gap: 16px;
}

.admin-row {
  text-align: left;
  cursor: pointer;
}

.admin-row.active {
  border-color: var(--green);
  box-shadow: inset 4px 0 0 var(--green);
}

.admin-detail {
  min-height: calc(100vh - 56px);
}

.admin-detail h2,
.policy-panel h2,
.snapshot-output h2 {
  margin: 0 0 10px;
  letter-spacing: 0;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0;
}

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

.detail-metric span {
  display: block;
  color: var(--muted);
  font-size: .8rem;
}

.detail-metric strong {
  display: block;
  margin-top: 4px;
  font-size: 1.15rem;
}

.admin-textarea {
  width: 100%;
  min-height: 110px;
  resize: vertical;
  border: 1px solid #c9c1ad;
  border-radius: 6px;
  padding: 10px 12px;
  background: #fff;
}

.manual-verification-form {
  display: grid;
  gap: 12px;
  margin: 12px 0 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fffdf7;
}

.admin-address-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 88px 120px;
  gap: 10px;
}

.contact-editor {
  display: grid;
  gap: 10px;
}

.contact-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
  margin: 0;
  border: 1px solid #d8d1c0;
  border-radius: 8px;
  padding: 12px;
  background: #fff;
}

.contact-row legend {
  padding: 0 4px;
  color: var(--green);
  font-weight: 850;
}

.contact-notes {
  grid-column: 1 / -1;
}

.plant-workflow {
  display: grid;
  gap: 12px;
  margin: 12px 0 22px;
}

.source-note-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #eef4ee;
}

.source-note-box p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.plant-subject-list,
.plant-candidates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.plant-subject-list article,
.plant-candidate,
.plant-asset-row {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fff;
}

.plant-subject-list span,
.plant-candidate span {
  display: block;
  margin-bottom: 6px;
  color: var(--orange);
  font-size: .78rem;
  font-weight: 850;
  text-transform: capitalize;
}

.plant-subject-list strong,
.plant-candidate strong {
  display: block;
  overflow-wrap: anywhere;
}

.plant-subject-list em {
  display: block;
  margin-top: 2px;
  color: var(--muted);
}

.plant-subject-list p,
.plant-candidate p {
  margin: 7px 0 0;
  color: var(--muted);
  line-height: 1.42;
  overflow-wrap: anywhere;
}

.plant-discovery-form,
.plant-assets-form {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fffdf7;
}

.plant-candidate {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 12px;
}

.plant-candidate img {
  width: 110px;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #e8dfcd;
}

.plant-candidate.accepted {
  border-color: #8bb195;
}

.plant-candidate.rejected {
  background: #fbf0eb;
}

.plant-asset-row {
  display: grid;
  gap: 10px;
  margin: 0;
}

.plant-asset-row legend {
  padding: 0 4px;
  color: var(--green);
  font-weight: 850;
}

.policy-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, .9fr);
  gap: 24px;
}

.policy-list {
  margin: 18px 0 0;
  padding-left: 20px;
  line-height: 1.65;
}

.source-panel p {
  color: var(--muted);
  line-height: 1.55;
}

.loading {
  position: relative;
}

.loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 253, 247, .72);
}

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

  .sidebar {
    position: static;
    height: auto;
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
  }

  .nav-tabs {
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    overflow-x: auto;
  }

  .trust-panel {
    width: 100%;
    margin-top: 0;
  }

  .sales-hero,
  .builder-grid,
  .admin-layout,
  .policy-grid {
    grid-template-columns: 1fr;
  }

  .sales-hero {
    min-height: auto;
  }

  .sales-visual {
    min-height: 460px;
  }

  .sales-visual img {
    min-height: 400px;
  }

  .marketing-gallery,
  .included-grid {
    grid-template-columns: 1fr 1fr;
  }

  .results-panel,
  .admin-detail {
    min-height: auto;
  }
}

@media (max-width: 720px) {
  .workspace {
    padding: 14px;
  }

  .sidebar {
    padding: 14px;
  }

  .product-preview,
  .inline-fields,
	  .address-fields,
	  .admin-address-grid,
	  .card-grid,
	  .detail-grid,
	  .marketing-gallery,
	  .included-grid,
	  .plant-subject-list,
	  .plant-candidates {
	    grid-template-columns: 1fr;
	  }

  .address-state,
  .address-zip {
    grid-column: 1 / -1;
  }

  .sales-copy h1 {
    font-size: clamp(2.7rem, 16vw, 4.2rem);
  }

  .sales-visual {
    min-height: auto;
  }

  .sales-visual img {
    height: auto;
    min-height: 0;
    aspect-ratio: 3 / 2;
  }

	  .segmented,
	  .toggle-grid,
	  .contact-row,
	  .plant-candidate {
	    grid-template-columns: 1fr;
	  }

	  .plant-candidate img {
	    width: 100%;
	  }
	}
