:root {
  color-scheme: light;
  font: 16px/1.55 "Segoe UI", system-ui, sans-serif;
  color: #25392f;
  background: #f7f8f3;
  --ink: #25392f;
  --muted: #51645a;
  --forest: #123f34;
  --accent: #a84829;
  --accent-hover: #88381d;
  --sage: #e1ead8;
  --line: #dce3d9;
  --paper: #fffefa;
  --radius: 1rem;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
a { color: var(--forest); text-underline-offset: .18em; }
a:hover { color: var(--accent); }
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }
.bar, main { width: min(1160px, calc(100% - 3rem)); margin: auto; }
.bar { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem 1.15rem; min-height: 72px; padding: .6rem 0; }
.brand { color: var(--forest); font-size: 1.8rem; font-weight: 850; letter-spacing: -.075em; text-decoration: none; }
.brand span { color: var(--accent); }
nav, .actions { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .65rem; }
nav { flex: 1; gap: .2rem; }
nav a { display: inline-flex; align-items: center; gap: .35rem; color: var(--muted); padding: .55rem .7rem; border-radius: .55rem; text-decoration: none; font-weight: 620; white-space: nowrap; }
nav a:hover, nav a[aria-current] { background: #ecf1e7; color: var(--forest); }
.activity-badge { display: inline-grid; place-items: center; min-width: 1.3rem; padding: .07rem .3rem; border-radius: 1rem; background: var(--accent); color: #fff; font-size: .75rem; line-height: 1.45; }
.header-create { white-space: nowrap; }
#plan-link { background: transparent; color: var(--muted); padding-inline: .35rem; font-weight: 620; }
#plan-link:hover, #plan-link[aria-current] { color: var(--forest); text-decoration: underline; }
.account-menu { position: relative; }
.account-menu summary { display: flex; gap: .6rem; align-items: center; cursor: pointer; max-width: 13rem; padding: .55rem .8rem; background: #ecf1e7; border-radius: .55rem; font-weight: 650; overflow-wrap: anywhere; }
.account-menu summary::after { content: ""; width: .42rem; height: .42rem; margin-bottom: .22rem; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); flex: none; }
.account-menu summary::-webkit-details-marker { display: none; }
.account-menu #username { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-actions { display: grid; position: absolute; right: 0; z-index: 3; top: calc(100% + .45rem); min-width: 12rem; padding: .4rem; background: var(--paper); border: 1px solid var(--line); border-radius: .65rem; box-shadow: 0 .75rem 2rem #123f3415; }
.account-actions a, .account-actions button { display: block; width: 100%; min-height: 40px; padding: .55rem .7rem; border: 0; background: transparent; border-radius: .4rem; text-decoration: none; text-align: left; color: var(--ink); font-weight: 550; }
.account-actions a:hover, .account-actions button:hover { background: #ecf1e7; color: var(--forest); }
main { padding: clamp(1.75rem, 4.5vw, 3.5rem) 0 4rem; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(2.15rem, 5.1vw, 4.8rem); line-height: 1.02; letter-spacing: -.055em; margin-bottom: .8rem; }
h2 { font-size: 1.35rem; letter-spacing: -.025em; }
.page-heading { margin-bottom: 1.8rem; }
.page-heading h1 { font-size: clamp(2rem, 4vw, 3.1rem); margin-bottom: .5rem; }
.page-heading p { margin-bottom: 0; }
.page-heading p, .muted { color: var(--muted); }
.hero { position: relative; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); overflow: hidden; border-radius: 1.5rem; background: var(--forest); color: #fffef7; }
.hero-copy { position: relative; z-index: 1; padding: clamp(1.65rem, 6vw, 4.5rem); }
.hero h1 { max-width: 11ch; letter-spacing: -.06em; }
.hero p { max-width: 33ch; color: #dceadc; font-size: 1.15rem; margin-bottom: 1.5rem; }
.hero-art { position: relative; min-height: 180px; overflow: hidden; isolation: isolate; }
.hero-art::before { content: ""; position: absolute; inset: -30%; transform: rotate(-27deg); background: repeating-linear-gradient(0deg, transparent 0 32px, #c4d9ae48 33px 35px, transparent 36px 56px), repeating-linear-gradient(90deg, transparent 0 46px, #c4d9ae48 47px 50px, transparent 51px 81px); }
.hero-radius { position: absolute; top: 50%; left: 49%; width: min(54%, 310px); aspect-ratio: 1; transform: translate(-50%, -50%); border: 1px solid #dcecc2a3; border-radius: 50%; background: #b4d3a624; box-shadow: 0 0 0 2.2rem #c4dcac24; }
.pin { position: absolute; display: block; width: 1.05rem; height: 1.05rem; border: 3px solid #f5f7ee; border-radius: 52% 52% 52% 5%; background: #f5f7ee; transform: translate(-50%, -50%) rotate(-45deg); }
.pin-main { top: 50%; left: 49%; width: 2.1rem; height: 2.1rem; background: #df8258; }
.pin-north { top: 23%; left: 32%; }
.pin-east { top: 35%; left: 75%; }
.pin-south { top: 73%; left: 34%; }
.landing-details { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 1.5rem; margin: 2rem 0; }
.landing-details > div { padding: 1rem .25rem; border-top: 1px solid var(--line); }
.landing-details p { color: var(--muted); margin-bottom: 0; }
.panel { min-width: 0; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1rem, 3vw, 1.5rem); }
.narrow { max-width: 540px; }
.form-panel { max-width: 690px; }
.columns { display: grid; grid-template-columns: minmax(190px, 255px) minmax(0, 1fr); gap: 1.4rem; align-items: start; }
button, .button { display: inline-flex; align-items: center; justify-content: center; font: inherit; font-weight: 680; text-decoration: none; cursor: pointer; border: 1px solid transparent; background: var(--accent); color: #fff; border-radius: .6rem; padding: .52rem .9rem; min-height: 44px; justify-self: start; }
button:hover, .button:hover { background: var(--accent-hover); color: #fff; }
button.quiet, .button.quiet { background: var(--sage); color: var(--forest); }
button.quiet:hover, .button.quiet:hover { background: #cdddc7; }
button:disabled { cursor: wait; opacity: .65; }
:focus-visible { outline: 3px solid #a84829; outline-offset: 2px; }
form, label { display: grid; min-width: 0; gap: .4rem; }
form { gap: 1rem; }
label, legend { font-size: .93rem; font-weight: 650; }
input, select, textarea { width: 100%; min-width: 0; font: inherit; color: var(--ink); background: #fff; border: 1px solid #aebfb1; border-radius: .5rem; padding: .55rem .65rem; min-height: 44px; }
select { appearance: none; background-image: linear-gradient(45deg,transparent 50%,var(--muted) 50%),linear-gradient(135deg,var(--muted) 50%,transparent 50%); background-position: calc(100% - 16px) 50%,calc(100% - 11px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 1.75rem; }
textarea { resize: vertical; min-height: 5.25rem; }
fieldset { min-width: 0; border: 1px solid var(--line); border-radius: .65rem; padding: .8rem; margin: 0; }
legend { padding: 0 .35rem; }
.map-panel { margin: .7rem 0 1rem; }
.map-panel p, .field-hint { color: var(--muted); font-size: .88rem; font-weight: 400; margin-bottom: .5rem; }
.file-label .field-hint { margin-bottom: 0; }
input[type="file"] { min-height: 54px; padding: .45rem .55rem; border: 1px dashed #a5b8a6; background: #f5f8f1; color: var(--muted); font-size: .88rem; font-weight: 500; cursor: pointer; }
input[type="file"]::file-selector-button { margin-right: .75rem; padding: .55rem .75rem; border: 0; border-radius: .4rem; background: #e2ebdd; color: var(--forest); font: inherit; font-weight: 680; cursor: pointer; }
input[type="file"]:hover::file-selector-button { background: #d3e2ce; }
input[type="file"]:disabled, input[type="file"]:disabled::file-selector-button { cursor: not-allowed; }
.form-section { display: grid; gap: .8rem; padding: 0; border: 0; border-top: 1px solid var(--line); border-radius: 0; }
.form-section legend { padding: 0 .65rem 0 0; font-size: 1.02rem; }
.form-actions { justify-content: space-between; margin-top: 1.35rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.form-actions .danger { margin-top: 0; }
#business-map { width: 100%; height: clamp(260px, 45vw, 390px); margin-bottom: .65rem; }
.cards, .pair, .filters { display: grid; gap: 1rem; }
.cards { grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr)); margin-top: 1rem; }
.pair { grid-template-columns: 1fr 1fr; }
.catalog-layout { display: grid; grid-template-columns: minmax(210px, 255px) minmax(0, 1fr); gap: 1.45rem; align-items: start; }
.filters { position: sticky; top: 1rem; gap: .95rem; }
.filter-options { border-top: 1px solid var(--line); }
.filter-options summary { padding-top: .85rem; cursor: pointer; font-weight: 650; }
.filter-fields { display: grid; gap: .85rem; padding-top: .85rem; }
.filter-fields .actions { gap: .5rem; }
.filter-fields button { font-size: .9rem; padding-inline: .65rem; }
.catalog-results { min-width: 0; }
.results-bar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .35rem 1rem; margin: 0 0 .8rem; color: var(--muted); font-size: .91rem; }
.results-bar strong { color: var(--ink); }
.offer-list { display: grid; gap: .75rem; }
.offer-list > p { margin: 0; }
.offer-card { display: grid; grid-template-columns: clamp(105px, 13vw, 150px) minmax(0, 1fr) max-content; gap: 1rem; align-items: center; padding: .8rem; }
.offer-cover { min-width: 0; display: grid; place-items: center; width: 100%; aspect-ratio: 4/3; overflow: hidden; border-radius: .65rem; background: #e8eee4; text-decoration: none; }
.offer-cover img { display: block; width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.offer-cover-empty { color: #345e50; font-size: 2rem; font-weight: 700; }
.offer-content { min-width: 0; overflow-wrap: anywhere; }
.offer-content h2 { margin: .35rem 0 .4rem; font-size: 1.23rem; line-height: 1.22; }
.offer-content h2 a { text-decoration: none; color: var(--ink); }
.offer-content h2 a:hover { text-decoration: underline; }
.offer-meta, .offer-people { display: flex; flex-wrap: wrap; align-items: baseline; gap: .2rem .42rem; color: var(--muted); font-size: .87rem; }
.offer-people { margin-bottom: .25rem; }
.offer-business { font-weight: 650; }
.offer-address { color: var(--muted); font-size: .87rem; margin: 0; }
.distance-tag { font-weight: 700; color: var(--forest); white-space: nowrap; }
.premium-label { color: #7b472e; }
.offer-price { justify-self: end; min-width: 105px; display: grid; justify-items: end; text-align: right; gap: .15rem; }
.offer-price strong { font-size: 1.12rem; white-space: nowrap; }
.offer-price span { font-size: .86rem; color: var(--muted); }
.offer-price .button { margin-top: .35rem; justify-self: end; font-size: .9rem; min-height: 40px; }
#notice { padding: .75rem 1rem; background: var(--sage); border-radius: .55rem; overflow-wrap: anywhere; }
#notice.error { color: #7e2e22; background: #f8dfd8; }
.business-list { list-style: none; padding: 0; margin: 0 0 1rem; }
.business-list li + li { margin-top: .4rem; }
.business-list li:has(a) { padding: .5rem .6rem; border-radius: .55rem; }
.business-list li:has([aria-current]) { background: #ecf1e7; }
.business-list span, .thread-list span { display: block; color: var(--muted); font-size: .88rem; }
.thread-list { display: grid; gap: .5rem; }
.thread-list a { padding: .55rem .7rem; border-radius: .5rem; }
.thread-list a[aria-current], .thread-list a:hover { background: var(--sage); }
.thread-list .thread-activity { display: flex; flex-wrap: wrap; gap: .3rem; margin-top: .3rem; }
.thread-list .thread-activity span { border-radius: .4rem; padding: .1rem .38rem; font-size: .75rem; }
.thread-list .thread-unread { background: #f4e4da; color: #78351e; }
.thread-list .thread-requests { background: #eaf0e5; color: var(--forest); }
.section-heading { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; justify-content: space-between; }
.section-heading h2 { margin-bottom: 0; }
.orders-heading { margin: 1.5rem 0 .5rem; }
#messages, #orders { margin: .85rem 0; }
#messages p, #orders p { background: #edf1e9; padding: .6rem .8rem; border-radius: .5rem; overflow-wrap: anywhere; }
#messages p.own-message { background: #e3ecda; }
#messages p { width: fit-content; max-width: 85%; }
#messages p.own-message { margin-left: auto; }
#quantity { max-width: 10rem; }
.landing-section { margin: clamp(2rem, 6vw, 4rem) 0; }
.landing-section > h2, .landing-plan h2 { font-size: clamp(1.7rem, 3.7vw, 2.35rem); line-height: 1.1; }
.landing-section .landing-details { margin: 1rem 0 0; }
.format-cards article p { color: var(--muted); margin-bottom: 0; }
.landing-plan { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; background: var(--sage); }
.landing-plan p { margin-bottom: 0; max-width: 56ch; }
.faq details { border-top: 1px solid var(--line); padding: .8rem 0; }
.faq summary { cursor: pointer; font-weight: 650; }
.faq details p { color: var(--muted); margin: .6rem 0 0; }
.auth-dialog { width: min(460px, calc(100% - 2rem)); color: var(--ink); }
.auth-dialog::backdrop { background: #10282199; }
.auth-dialog .section-heading { margin-bottom: 1rem; }
#auth-error { color: #7e2e22; background: #f8dfd8; padding: .65rem; border-radius: .5rem; }
.plan-cards { grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); }
.featured-plan { border-color: #a2b59e; background: #eef4e9; }
.plan-price, .plan-options strong { font-weight: 750; font-size: 1.45rem; }
.plan-options { display: flex; flex-wrap: wrap; gap: 1rem; margin: 1.15rem 0; }
.plan-options p { margin-bottom: .35rem; }
.plan-options + p { margin-bottom: 0; }
.pending-plan { margin-top: 1rem; }
.quota { color: var(--muted); font-size: .92rem; }
.danger { margin-top: 1.35rem; border-color: #cbaca4; background: transparent; color: #842c20; }
.danger:hover { background: #842c20; }
.site-footer { color: #e6f0e8; background: var(--forest); padding: 2.25rem 0 1.1rem; }
.footer-grid, .footer-bottom { width: min(1180px, calc(100% - 2rem)); margin-inline: auto; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 1.5rem; }
.site-footer a { display: block; color: #f5f9f3; overflow-wrap: anywhere; }
.site-footer h2 { color: #fff; font-size: 1.05rem; margin-bottom: .65rem; }
.site-footer p { margin: .35rem 0; white-space: pre-line; overflow-wrap: anywhere; }
.footer-bottom { border-top: 1px solid #73958a; margin-top: 1.5rem; padding-top: .85rem; }
.details-page { overflow-wrap: anywhere; }
.details-page h1, #profile-form h1 { font-size: clamp(2rem, 4.5vw, 3.4rem); }
.details-block { margin-top: 1.5rem; }
.preserve-lines { white-space: pre-wrap; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 135px), 1fr)); gap: .75rem; margin-bottom: 1rem; }
.photo-grid:empty { display: none; }
.photo-tile { min-width: 0; }
.photo-open { display: block; width: 100%; height: clamp(7.5rem, 22vw, 14rem); padding: .4rem; border: 1px solid var(--line); border-radius: .8rem; background: #edf2e9; cursor: zoom-in; }
.photo-open:hover { border-color: #98ac9c; background: #e3ebe0; }
.photo-open img { display: block; width: 100%; height: 100%; object-fit: contain; }
.photo-feature { display: flex; flex-wrap: wrap; align-items: flex-start; margin-bottom: clamp(1rem, 3vw, 1.75rem); }
.photo-feature > .photo-tile { flex: 0 1 calc((100% - 2.25rem) / 4); max-width: 8rem; }
.photo-feature > .photo-banner { flex-basis: 100%; max-width: none; }
.photo-feature .photo-open { height: auto; aspect-ratio: 4 / 3; }
.photo-feature .photo-banner .photo-open {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  height: clamp(12rem, 40vw, 28rem);
  aspect-ratio: auto;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: #182c25;
}
.photo-banner .photo-open img { position: absolute; inset: 0; }
.photo-banner .photo-open .photo-backdrop { object-fit: cover; filter: blur(24px) brightness(.58); transform: scale(1.14); }
.photo-banner .photo-open:hover .photo-backdrop { filter: blur(24px) brightness(.7); }
.photo-count { position: absolute; right: .75rem; bottom: .75rem; padding: .25rem .6rem; border-radius: 2rem; color: #fff; background: #102821e8; font-size: .85rem; }
.photo-tile > .quiet { margin-top: .4rem; padding: .25rem .65rem; min-height: 36px; font-size: .88rem; }
#listing-photo-preview:not(:empty) { margin-bottom: 0; }
.media-dialog { width: min(38rem, calc(100% - 1.5rem)); max-height: calc(100% - 1.5rem); color: var(--ink); }
.media-dialog::backdrop { background: #102821c9; }
.media-dialog h2 { margin-bottom: .75rem; }
.media-dialog .actions { justify-content: flex-end; }
.crop-preview { display: grid; place-items: center; min-height: 8rem; margin-bottom: .8rem; background: #edf2e9; border-radius: .65rem; padding: .45rem; }
.crop-preview canvas { display: block; max-width: 100%; max-height: min(38dvh, 20rem); object-fit: contain; }
.crop-preview .avatar-crop-preview { border-radius: 50%; }
.crop-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .35rem .75rem; margin-bottom: .75rem; }
.crop-controls input[type="range"] { min-height: 32px; padding: 0; accent-color: var(--forest); }
.crop-controls input:disabled { opacity: .5; }
.gallery-dialog {
  width: min(70rem, calc(100% - 1.5rem));
  height: min(85dvh, 48rem);
  padding: clamp(.5rem, 2vw, 1rem);
  overflow: hidden;
}
.gallery-dialog[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; gap: .6rem; }
.gallery-stage { position: relative; grid-row: 2; min-width: 0; overflow: hidden; border-radius: .55rem; background: #162b23; }
.gallery-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.gallery-toolbar { display: flex; justify-content: space-between; align-items: center; gap: .5rem; }
.gallery-toolbar p { margin: 0; font-weight: 650; }
.profile-heading { display: flex; align-items: center; flex-wrap: wrap; gap: 1rem; margin-bottom: .85rem; }
.profile-heading h1 { margin: 0; }
.profile-avatar { display: grid; place-items: center; flex: none; width: 5rem; height: 5rem; border-radius: 50%; overflow: hidden; background: var(--sage); color: var(--forest); font-size: 2rem; font-weight: 750; }
.profile-avatar img { display: block; width: 100%; height: 100%; min-height: 0; object-fit: cover; }
.avatar-form { margin-block: 1rem 1.5rem; padding-bottom: 1.35rem; border-bottom: 1px solid var(--line); }
.avatar-form .file-label { margin-block: .6rem; }
.own-listings { display: grid; gap: .75rem; padding: 0; margin: 0; list-style: none; }
.own-listing { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .7rem 1.25rem; }
.own-listing h2, .own-listing p { margin-bottom: .25rem; }
.own-listing h2 { overflow-wrap: anywhere; }
.own-listing .delete-listing { color: #78351e; background: #f4e4da; }
.own-listing .delete-listing:hover { background: #eed8cb; }
.checkbox-label { display: flex; align-items: center; gap: .65rem; }
.checkbox-label input { width: 1.12rem; min-height: 0; height: 1.12rem; margin: 0; accent-color: var(--forest); }
.admin-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 145px), 1fr)); gap: .8rem; margin: 0; }
.admin-stats dt { color: var(--muted); }
.admin-stats dd { margin: .25rem 0 0; font-size: 1.65rem; font-weight: 750; }
.table-scroll { overflow-x: auto; }
.table-scroll table { width: 100%; border-collapse: collapse; text-align: left; }
.table-scroll th, .table-scroll td { padding: .65rem .55rem; border-bottom: 1px solid var(--line); }
.table-scroll th { color: var(--muted); font-size: .9rem; }
.table-scroll button { min-height: 36px; font-size: .9rem; }
.admin-more { margin-top: .9rem; }
.review-card { padding: 1rem 0; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.review-card:last-child { border-bottom: 0; padding-bottom: 0; }
.review-card > p { margin-bottom: .4rem; }
.review-card h3 { margin-bottom: .4rem; }
.review-card .photo-grid { margin-block: .75rem; }
#moderation-queue { margin-top: .75rem; }

@media (max-width: 820px) {
  nav { order: 3; flex-basis: 100%; }
  .bar { gap: .45rem .65rem; }
  .bar, main { width: min(1160px, calc(100% - 2rem)); }
  .bar .brand { margin-right: auto; }
  .header-create { order: 3; }
  .catalog-layout { grid-template-columns: minmax(0, 1fr); }
  .filters { position: static; }
}

@media (max-width: 640px) {
  .bar { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; grid-template-areas: "brand plan user" "nav nav nav" "create create create"; }
  .bar .brand { grid-area: brand; margin: 0; }
  .bar nav { grid-area: nav; }
  .bar #plan-link { grid-area: plan; font-size: .78rem; }
  .bar #account, .bar > #login-link, .bar > .actions { grid-area: user; justify-self: end; }
  .account-menu summary { max-width: clamp(5rem, 25vw, 9rem); font-size: .82rem; padding: .5rem .55rem; }
  .bar > .actions { justify-content: flex-end; gap: .25rem; }
  .bar > .actions > .button { min-height: 36px; padding: .35rem .5rem; font-size: .8rem; }
  .columns, .hero { grid-template-columns: minmax(0, 1fr); }
  .hero-art { height: 200px; }
  .offer-card { grid-template-columns: minmax(66px, 25%) minmax(0, 1fr); gap: .65rem .8rem; align-items: start; }
  .offer-price { grid-column: 2; justify-self: stretch; justify-items: start; text-align: left; grid-template-columns: auto 1fr; align-items: baseline; gap: .15rem .35rem; }
  .offer-price .button { grid-column: 1 / -1; justify-self: start; }
  nav a { padding-inline: .3rem; font-size: .87rem; }
  .header-create { grid-area: create; justify-self: start; font-size: .88rem; min-height: 40px; padding-inline: .65rem; }
}

@media (max-width: 390px) {
  .pair { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 520px) {
  .gallery-toolbar button { padding-inline: .55rem; font-size: .86rem; }
}

