body.market-body {
  margin: 0;
  color: #183625;
  background: #f8f6f0;
  font: 400 1rem/1.55 "Rethink Sans", system-ui, sans-serif;
}
.market-body *, .market-body *::before, .market-body *::after { box-sizing: border-box; }
.market-body a { color: inherit; text-underline-offset: 0.2em; }
.market-body :focus-visible, .market-account-link:focus-visible { outline: 3px solid #a16a24; outline-offset: 4px; }
.market-body button, .market-body input, .market-body select, .market-body textarea { font: inherit; }
.market-skip { position: absolute; top: -8rem; }
.market-skip:focus { top: 0.75rem; left: 0.75rem; z-index: 10; color: #183625; background: #fff; padding: 0.75rem; }
.market-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding: 1rem clamp(1rem, 5vw, 4rem);
  color: #fff;
  background: #183625;
}
.market-header nav, .market-row-actions, .market-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: center;
}
.market-header a, .market-logout { text-decoration: none; }
.market-header a:hover, .market-logout:hover { color: #f0d5a8; }
.market-brand { font-size: 1.125rem; font-weight: 750; }
.market-logout { color: inherit; padding: 0; background: none; border: 0; cursor: pointer; }
.market-main { width: min(100% - 2rem, 70rem); margin: clamp(2rem, 5vw, 4.75rem) auto 5rem; }
.market-narrow { width: min(100% - 2rem, 29rem); }
.market-heading { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }
.market-heading h1 { margin: 0; font: 750 clamp(2rem, 5vw, 3.5rem)/1.06 "Rethink Sans", system-ui, sans-serif; letter-spacing: -0.04em; }
.market-heading p, .market-row p { margin: 0.35rem 0 0; color: #4c5c52; }
.market-panel {
  background: #fffefa;
  border: 1px solid #dbe4d8;
  border-radius: 1rem;
  padding: clamp(1rem, 3vw, 1.75rem);
}
.market-form { display: grid; gap: 1.15rem; }
.market-form label { display: grid; gap: 0.35rem; min-width: 0; font-weight: 650; }
.market-form input:not([type="checkbox"]), .market-form select, .market-form textarea {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.55rem 0.75rem;
  border: 1px solid #aebbad;
  border-radius: 0.5rem;
  background: #fff;
  color: #183625;
}
.market-form input[type="file"] { padding: 0.4rem; }
.market-form textarea { resize: vertical; }
.market-form p, .market-form small { margin: 0; color: #4c5c52; font-weight: 400; }
.market-form .market-inline { display: flex; align-items: center; flex-wrap: wrap; align-self: center; }
.market-field-grid { display: grid; gap: 1rem; }
.market-button, .market-body a.market-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 2.75rem;
  padding: 0.55rem 1rem;
  border: 1px solid #214632;
  border-radius: 999px;
  color: #fff;
  background: #214632;
  cursor: pointer;
  font-weight: 700;
  text-decoration: none;
}
.market-button:hover, .market-body a.market-button:hover { background: #356047; }

.market-auth {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  width: min(calc(100% - 2 * clamp(1rem, 4vw, 4rem)), 82rem);
  min-height: min(46rem, calc(100svh - 5rem));
  margin: clamp(1rem, 4vh, 3rem) auto;
  overflow: hidden;
  border: 1px solid #dbe4d8;
  border-radius: 1.5rem;
  background: #fffefa;
  box-shadow: 0 1.5rem 4rem rgb(24 54 37 / 10%);
}

.market-auth-photo { position: relative; background: #183625; }
.market-auth-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.market-auth-pane { display: grid; align-items: center; padding: clamp(1.5rem, 4vw, 4rem); }
.market-auth-content { width: min(100%, 26rem); margin-inline: auto; }
.market-auth-home { display: flex; width: fit-content; gap: 0.55rem; align-items: center; font-size: 0.875rem; font-weight: 700; text-decoration: none; }
.market-auth-home:hover { text-decoration: underline; }
.market-auth-logo {
  display: grid;
  width: min(12rem, 100%);
  place-items: center;
  margin: 1.5rem 0 1.65rem;
  padding: 0.6rem 0.85rem;
  border-radius: 0.75rem;
  background: #183625;
}
.market-auth-logo img { display: block; width: min(10rem, 100%); height: auto; }
.market-auth .market-heading { display: block; margin-bottom: 1.5rem; }
.market-auth .market-heading h1 { font-size: clamp(2rem, 3.35vw, 3.25rem); }
.market-auth .market-heading p { margin-top: 0.55rem; }
.market-auth-form { gap: 0.95rem; }
.market-auth-form input:not([type="checkbox"]) {
  min-height: 3rem;
  padding-inline: 0.85rem;
  border-color: #bdcabe;
  border-radius: 0.65rem;
}
.market-auth-form .market-button { width: 100%; min-height: 3.15rem; border-radius: 0.65rem; }
.market-auth-form .market-auth-switch { text-align: center; }
.market-auth-switch a { font-weight: 700; }

@media (max-width: 740px) {
  .market-auth { grid-template-columns: minmax(0, 1fr); min-height: 0; max-width: 32rem; }
  .market-auth-photo { min-height: clamp(9rem, 35vw, 15rem); }
  .market-auth-photo img { object-position: center 53%; }
}

.market-button.market-secondary, .market-body a.market-button.market-secondary { background: transparent; color: #214632; }
.market-button.market-secondary:hover, .market-body a.market-button.market-secondary:hover { background: #eaf0e5; }
.market-button.market-delete { background: #873a33; border-color: #873a33; }
.market-message { padding: 0.8rem 1rem; background: #e3eee1; border-radius: 0.65rem; }
.market-error { color: #73281e; background: #fce9e6; }
.market-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr)); gap: 0.75rem; margin: 0 0 1.5rem; }
.market-stats div { padding: 1rem; border-radius: 0.85rem; background: #eaf0e5; }
.market-stats dt { font-size: 0.88rem; font-weight: 600; }
.market-stats dd { margin: 0.15rem 0 0; font-size: 1.8rem; font-weight: 750; line-height: 1.1; }
.market-list { display: grid; gap: 0.75rem; }
.market-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1.25rem; }
.market-row > div:first-child { min-width: 0; overflow-wrap: anywhere; }
.market-row h2 { margin: 0; font-size: 1.15rem; }
.market-status { border-radius: 999px; padding: 0.3rem 0.7rem; font-size: 0.82rem; font-weight: 700; background: #eeece3; }
.market-status[data-status="published"] { background: #dbeadb; }
.market-status[data-status="pending"] { color: #65450e; background: #faedcc; }
.market-status[data-status="rejected"] { color: #73281e; background: #fce9e6; }
.market-danger { margin-top: 1.5rem; color: #73281e; }
.market-danger summary { cursor: pointer; }
.market-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr)); gap: 0.75rem; }
.market-photos img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 0.5rem; }
.market-preview { width: min(100%, 18rem); max-height: 12rem; object-fit: contain; object-position: left center; border-radius: 0.5rem; }
.market-logo-preview { padding: 0.5rem; background: #183625; }
.market-lead-details { white-space: pre-wrap; }
.market-pagination { margin-top: 1.5rem; }
.market-custom-logo { max-height: 4rem; object-fit: contain; }
.farmhouse-sale-card[id] { scroll-margin-top: 6rem; }
.market-account-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.5rem;
  padding: 0.45rem 0.9rem;
  border: 1px solid rgb(248 246 240 / 40%);
  border-radius: 999px;
  white-space: nowrap;
  font-size: 0.875rem;
  font-weight: 700;
}
.market-account-link:hover { background: rgb(248 246 240 / 12%); }
.market-blog {
  min-height: 64vh;
  padding: clamp(8rem, 12vw, 10rem) 1rem 4rem;
  color: #183625;
  background: #f8f6f0;
}
.market-blog-inner { width: min(100%, 69rem); margin-inline: auto; }
.market-blog-article { width: min(100%, 48rem); margin-inline: auto; }
.market-blog h1 { margin: 0.5rem 0 1.25rem; font-size: clamp(2.3rem, 5vw, 4rem); line-height: 1.1; }
.market-blog-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); align-items: start; gap: 1rem; }
.market-blog-card { display: block; overflow: hidden; border: 1px solid #dbe4d8; border-radius: 1rem; background: #fffefa; }
.market-blog-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.market-blog-card div { padding: 1.25rem; }
.market-blog-card h2 { font-size: 1.35rem; }
.market-blog-card:hover h2, .market-blog-back { text-decoration: underline; text-underline-offset: 0.2em; }
.market-blog-card p { margin-top: 0.5rem; }
.market-blog time { color: #526456; font-size: 0.875rem; }
.market-blog-cover { width: 100%; max-height: 32rem; margin: 1.5rem 0; border-radius: 1rem; object-fit: cover; }
.market-blog-content { margin-top: 1.5rem; font-size: 1.0625rem; line-height: 1.75; overflow-wrap: anywhere; }
.market-blog-content > * + * { margin-top: 1rem; }
.market-blog-content h2 { margin-top: 2rem; font-size: 1.6rem; }
.market-blog-content ul { padding-left: 1.5rem; list-style: disc; }
@media (min-width: 40rem) { .market-field-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.market-blog-content :is(h2, h3, h4) { line-height: 1.25; font-weight: 700; }
.market-blog-content h3 { margin-top: 1.5rem; font-size: 1.3rem; }
.market-blog-content h4 { margin-top: 1.25rem; font-size: 1.125rem; }
.market-blog-content ol { padding-left: 1.5rem; list-style: decimal; }
.market-blog-content blockquote {
  margin-inline: 0;
  padding: 0.3rem 0 0.3rem 1rem;
  border-left: 3px solid #aa854e;
  color: #49594e;
}
.market-blog-content a { color: #285b3e; text-decoration: underline; text-underline-offset: 0.15em; }
.market-blog-content :is(.blog-size-small, font[size="2"]) { font-size: 0.875rem; }
.market-blog-content :is(.blog-size-normal, font[size="3"]) { font-size: 1.0625rem; }
.market-blog-content :is(.blog-size-large, font[size="4"]) { font-size: 1.25rem; }
.market-blog-content :is(.blog-size-larger, font[size="5"]) { font-size: 1.5rem; }

.market-editor [hidden] { display: none; }
.market-editor .market-editor-label { margin-bottom: 0.4rem; color: #183625; font-weight: 650; }
.market-editor-toolbar, .market-editor-link {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0.55rem;
  border: 1px solid #aebbad;
  background: #edf2eb;
}
.market-editor-toolbar { border-radius: 0.65rem 0.65rem 0 0; }
.market-editor-link { border-top: 0; }
.market-editor-link label { flex: 1 1 14rem; }
.market-editor .market-editor-select { gap: 0.1rem; font-size: 0.8rem; }
.market-editor-toolbar button, .market-editor-link button {
  min-height: 2.75rem;
  padding: 0.4rem 0.7rem;
  border: 1px solid #aebbad;
  border-radius: 0.45rem;
  background: #fff;
  color: #183625;
  font-size: 0.875rem;
  cursor: pointer;
}
.market-editor-toolbar button[aria-pressed="true"], .market-editor-toolbar button:hover, .market-editor-link button:hover {
  border-color: #648571;
  background: #dceadc;
}
.market-editor-area {
  min-height: 20rem;
  margin: 0;
  padding: clamp(0.75rem, 2vw, 1.25rem);
  border: 1px solid #aebbad;
  border-top: 0;
  border-radius: 0 0 0.65rem 0.65rem;
  background: #fff;
}
.market-editor-area:focus { outline: 2px solid #a16a24; outline-offset: -2px; }
.market-editor-area > :first-child { margin-top: 0; }
.market-editor-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.25rem 0.75rem; margin-top: 0.35rem; }
.market-form .market-editor-error { margin-top: 0.5rem; color: #73281e; }

.market-header-actions { display: flex; align-items: center; gap: clamp(0.375rem, 1vw, 1rem); }

.market-header-phone {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.6rem 0.875rem;
  border-radius: 999px;
  background: #e8c589;
  color: #0f2418;
  font-size: 0.875rem;
  font-weight: 750;
  white-space: nowrap;
}

.market-header-phone:hover { background: #f2d7a5; }
.market-header-phone:focus-visible, .market-list-nav:focus-visible, .market-list-button:focus-visible {
  outline: 2px solid #d4a359;
  outline-offset: 3px;
}
.market-list-nav { color: #e8c589; font-weight: 650; white-space: nowrap; }
.market-list-nav:hover { color: #f8f6f0; }

.market-list-section {
  padding-block: clamp(2rem, 5vw, 4rem);
  background: #edf0e8;
  color: #183625;
  scroll-margin-top: 84px;
}

.market-list-panel {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem 2.5rem;
  padding: clamp(1.5rem, 4.5vw, 3.5rem);
  border: 1px solid #d8dfd2;
  border-radius: 1.25rem;
  background: #fbfaf4;
}

.market-list-panel h2 {
  font-size: clamp(1.85rem, 3.5vw, 3rem);
  line-height: 1.12;
}

.market-list-panel p { max-width: 58ch; margin-top: 0.75rem; line-height: 1.65; color: #49574c; }
.market-list-button {
  display: inline-flex;
  justify-content: center;
  padding: 0.75rem 1.25rem;
  border-radius: 999px;
  color: #f8f6f0;
  background: #183625;
  font-weight: 700;
}
.market-list-button:hover { background: #294b36; }

@media (max-width: 639px) {
  #navbar .home-navbar-brand img { width: min(27vw, 7.5rem); }
  #navbar .market-header-actions { gap: 0.375rem; }
  #navbar .market-header-phone { padding: 0.5rem 0.5rem; font-size: 0.6875rem; }
  #navbar .market-header-phone i { display: none; }
  #navbar .market-account-link { padding-inline: 0.45rem; font-size: 0.75rem; }
  #navbar .market-header-actions button { width: 2rem; height: 2rem; }
}
