:root {
  --ink: #161712;
  --paper: #f4efe3;
  --surface: #fffaf0;
  --sage: #243522;
  --leaf: #63723a;
  --oxblood: #7d2f2d;
  --brass: #a9763f;
  --blue: #2c5364;
  --muted: #706a5d;
  --line: rgba(22, 23, 18, 0.13);
  --soft-line: rgba(255, 250, 240, 0.14);
  --shadow: 0 18px 48px rgba(23, 21, 15, 0.18);
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

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

body {
  min-height: 100%;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 20% 0%, rgba(169, 118, 63, 0.16), transparent 28%),
    linear-gradient(180deg, rgba(36, 53, 34, 0.98) 0, rgba(36, 53, 34, 0.98) 190px, var(--paper) 191px),
    var(--paper);
}

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

button {
  color: inherit;
}

.app-shell {
  width: min(100%, 560px);
  min-height: 100svh;
  margin: 0 auto;
  background: var(--paper);
  position: relative;
  overflow: hidden;
  border-left: 1px solid rgba(255, 250, 240, 0.08);
  border-right: 1px solid rgba(255, 250, 240, 0.08);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 72px;
  padding: calc(env(safe-area-inset-top) + 10px) 16px 10px;
  background: rgba(38, 56, 35, 0.97);
  color: #fffdf8;
  border-bottom: 1px solid var(--soft-line);
}

.brand-button {
  border: 0;
  background: transparent;
  color: inherit;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 0;
  text-align: left;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  background: #101410;
  object-fit: cover;
  flex: 0 0 auto;
}

.brand-button strong,
.brand-button small {
  display: block;
  line-height: 1.1;
}

.brand-button strong {
  font-size: 15px;
  letter-spacing: 0;
}

.brand-button small {
  margin-top: 3px;
  color: rgba(255, 253, 248, 0.72);
  font-size: 12px;
}

.icon-button {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 253, 248, 0.22);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.08);
  color: #fffdf8;
  display: grid;
  place-items: center;
  font-size: 24px;
  font-weight: 800;
}

.button-icon {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.main-stage {
  min-height: calc(100svh - 142px);
  padding: 16px 14px calc(92px + env(safe-area-inset-bottom));
}

.tabbar {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 30;
  transform: translateX(-50%);
  width: min(100%, 560px);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
  background: rgba(255, 250, 240, 0.97);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.tab-button {
  min-width: 0;
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.tab-button.active {
  background: #e6ebd7;
  color: var(--sage);
}

.screen {
  display: grid;
  gap: 16px;
}

.hero-band {
  position: relative;
  min-height: 278px;
  overflow: hidden;
  border-radius: 10px;
  background: var(--ink);
  color: #fffdf8;
}

.hero-band img {
  width: 100%;
  height: 100%;
  min-height: 278px;
  object-fit: cover;
  display: block;
  opacity: 0.9;
}

.hero-band::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(23, 24, 23, 0.08), rgba(23, 24, 23, 0.78)),
    linear-gradient(90deg, rgba(23, 24, 23, 0.52), transparent 58%);
}

.hero-copy {
  position: absolute;
  z-index: 1;
  left: 16px;
  right: 16px;
  bottom: 14px;
  display: grid;
  gap: 10px;
}

.eyebrow {
  color: var(--brass);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin: 0;
}

.hero-copy h1 {
  max-width: 13ch;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 32px;
  line-height: 0.98;
  font-weight: 700;
  letter-spacing: 0;
}

.hero-copy p {
  color: rgba(255, 253, 248, 0.82);
  font-size: 14px;
  line-height: 1.42;
}

.hero-actions,
.row-actions,
.detail-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.button {
  border: 1px solid transparent;
  border-radius: 7px;
  background: var(--sage);
  color: #fffdf8;
  min-height: 42px;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.button.secondary {
  background: #fffdf8;
  color: var(--sage);
  border-color: var(--line);
}

.button.ghost {
  background: transparent;
  color: var(--sage);
  border-color: var(--line);
}

.filter-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 0 4px;
  scrollbar-width: none;
}

.filter-row::-webkit-scrollbar {
  display: none;
}

.chip {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--sage);
  min-height: 36px;
  padding: 0 13px;
  font-size: 13px;
  font-weight: 800;
}

.chip.active {
  background: var(--sage);
  color: #fffdf8;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 12px;
  margin-top: 2px;
}

.section-heading > div {
  display: grid;
  gap: 4px;
}

.section-heading h2 {
  font-size: 19px;
  line-height: 1.1;
  letter-spacing: 0;
}

.section-heading p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

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

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

.product-card,
.drop-card,
.story-card,
.inquiry-card,
.profile-panel,
.empty-state,
.search-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.product-card {
  display: grid;
  text-align: left;
  border: 1px solid var(--line);
  padding: 0;
  color: inherit;
  box-shadow: none;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.product-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 26px rgba(23, 21, 15, 0.11);
  border-color: rgba(36, 53, 34, 0.25);
}

.image-frame {
  width: 100%;
  aspect-ratio: 1 / 1.03;
  overflow: hidden;
  background: #ebe5d7;
  display: block;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.product-info {
  display: grid;
  gap: 7px;
  padding: 11px;
}

.product-tags,
.passport-tags,
.drop-pieces {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.product-tags span,
.passport-tags span,
.drop-pieces span {
  width: max-content;
  max-width: 100%;
  border: 1px solid rgba(36, 53, 34, 0.14);
  border-radius: 999px;
  background: #f1eadc;
  color: var(--sage);
  padding: 4px 8px;
  font-size: 10px;
  font-weight: 900;
}

.product-title-line {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  align-items: start;
}

.product-title-line h3 {
  font-size: 14px;
  line-height: 1.2;
  letter-spacing: 0;
}

.price {
  color: var(--sage);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.meta-line {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.status {
  width: max-content;
  max-width: 100%;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.status.available {
  background: #dfe8d6;
  color: #1f4e2c;
}

.status.reserved {
  background: #efe2c7;
  color: #6f4e11;
}

.status.sold {
  background: #ead7d6;
  color: #7d2f2d;
}

.status.coming_soon {
  background: #dbe5e7;
  color: #2c5364;
}

.drop-section {
  display: grid;
  gap: 10px;
}

.drop-scroll {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(248px, 82%);
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.drop-scroll::-webkit-scrollbar {
  display: none;
}

.drop-card {
  display: grid;
  min-height: 100%;
}

.drop-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #ebe5d7;
}

.drop-body {
  display: grid;
  gap: 10px;
  padding: 13px;
}

.drop-body h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  line-height: 1.05;
}

.drop-body p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.story-card {
  display: grid;
  gap: 0;
}

.story-compose {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px;
}

.story-compose h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  line-height: 1.1;
  letter-spacing: 0;
  margin: 3px 0 6px;
}

.story-media {
  width: 100%;
  aspect-ratio: 16 / 10.5;
  object-fit: cover;
  background: #ede6d9;
}

.story-body {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.story-author {
  display: flex;
  align-items: center;
  gap: 9px;
}

.story-author strong,
.story-author small {
  display: block;
}

.story-author strong {
  font-size: 13px;
}

.story-author small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
}

.story-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--brass);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.story-body h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 23px;
  line-height: 1.1;
  letter-spacing: 0;
}

.story-body p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.47;
}

.story-engagement {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
}

.story-engagement span {
  border-radius: 999px;
  background: #f0eadf;
  color: var(--muted);
  padding: 5px 8px;
  font-size: 11px;
  font-weight: 800;
}

.story-reader {
  display: grid;
  gap: 12px;
}

.story-reader p {
  color: var(--ink);
  font-size: 15px;
  line-height: 1.58;
}

.avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--sage);
}

.mini-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.mini-actions button {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdf8;
  color: var(--sage);
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
}

.mini-actions button.active {
  background: var(--sage);
  color: #fffdf8;
}

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

.community-strip div,
.prompt-panel {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.community-strip div {
  display: grid;
  gap: 3px;
  padding: 11px;
}

.community-strip strong {
  font-size: 18px;
}

.community-strip span {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.prompt-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
}

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

.prompt-card {
  min-height: 68px;
  border: 1px solid rgba(36, 53, 34, 0.18);
  border-radius: 8px;
  background: #f7f1e5;
  color: var(--sage);
  padding: 10px;
  text-align: left;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.2;
}

.form-grid {
  display: grid;
  gap: 10px;
}

.form-grid label {
  display: grid;
  gap: 6px;
  color: var(--sage);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.file-field span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  text-transform: none;
  letter-spacing: 0;
}

.input,
.textarea,
.select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdf8;
  color: var(--ink);
  padding: 11px 12px;
  font-size: 16px;
}

.textarea {
  min-height: 104px;
  resize: vertical;
}

.inquiry-card,
.profile-panel,
.empty-state,
.search-box {
  padding: 15px;
}

.inquiry-card {
  display: grid;
  gap: 8px;
}

.inquiry-card h3,
.profile-panel h2 {
  font-size: 17px;
  line-height: 1.2;
}

.profile-panel {
  display: grid;
  gap: 14px;
}

.notice-strip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid rgba(169, 118, 63, 0.24);
  border-radius: 10px;
  background: #fbf1df;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.notice-strip strong {
  color: var(--ink);
  white-space: nowrap;
}

.profile-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.profile-head img {
  width: 62px;
  height: 62px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--sage);
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.stat {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #f7f4ec;
}

.stat strong,
.stat span {
  display: block;
}

.stat strong {
  font-size: 18px;
}

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

.empty-state {
  display: grid;
  gap: 8px;
  color: var(--muted);
}

.reply-box {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-radius: 8px;
  background: #f3ead9;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.reply-box strong {
  color: var(--ink);
}

.empty-state strong {
  color: var(--ink);
}

.sheet {
  position: fixed;
  z-index: 60;
  inset: 0;
  background: rgba(16, 18, 15, 0.38);
  display: grid;
  align-items: end;
}

.sheet.hidden,
.hidden {
  display: none;
}

.sheet-panel {
  width: min(100%, 560px);
  max-height: 92svh;
  margin: 0 auto;
  overflow: auto;
  background: var(--paper);
  border-radius: 16px 16px 0 0;
  box-shadow: var(--shadow);
  padding: 10px 14px calc(18px + env(safe-area-inset-bottom));
}

.sheet-top {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 6px 0 10px;
  background: var(--paper);
}

.close-button {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdf8;
  color: var(--sage);
  font-size: 20px;
  font-weight: 800;
}

.detail-media {
  width: 100%;
  aspect-ratio: 1 / 0.82;
  border-radius: 10px;
  object-fit: cover;
  background: #e9e2d4;
}

.detail-body {
  display: grid;
  gap: 14px;
}

.detail-title {
  display: grid;
  gap: 7px;
}

.detail-title h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 29px;
  line-height: 1.02;
  letter-spacing: 0;
}

.detail-copy {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.48;
}

.passport-card {
  display: grid;
  gap: 12px;
  border: 1px solid rgba(36, 53, 34, 0.18);
  border-radius: 10px;
  background: #fffaf0;
  padding: 13px;
}

.passport-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}

.passport-header span {
  color: var(--brass);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.passport-header strong {
  color: var(--sage);
  font-size: 12px;
}

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

.passport-grid div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.passport-grid span,
.passport-note strong {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.passport-grid strong {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.25;
}

.passport-note {
  display: grid;
  gap: 5px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}

.passport-note p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

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

.detail-list li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
  color: var(--muted);
  font-size: 14px;
}

.detail-list strong {
  color: var(--ink);
  font-weight: 800;
  text-align: right;
  overflow-wrap: anywhere;
}

.toast {
  position: fixed;
  z-index: 80;
  left: 50%;
  bottom: calc(78px + env(safe-area-inset-bottom));
  transform: translateX(-50%) translateY(12px);
  width: max-content;
  max-width: calc(100% - 28px);
  border-radius: 8px;
  background: var(--ink);
  color: #fffdf8;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 800;
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.manager-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.manager-tabs::-webkit-scrollbar {
  display: none;
}

.manager-list {
  display: grid;
  gap: 10px;
}

.manager-card {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 12px;
  align-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.manager-card-wide {
  grid-template-columns: 1fr;
}

.manager-card img {
  width: 74px;
  height: 74px;
  object-fit: cover;
  border-radius: 8px;
  background: #e9e0cf;
}

.manager-card h3 {
  margin: 0 0 5px;
  font-size: 15px;
  line-height: 1.2;
}

.small-button {
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf0;
  color: var(--sage);
  padding: 0 9px;
  font-size: 11px;
  font-weight: 800;
}

.small-button.active {
  background: var(--sage);
  color: #fffaf0;
}

.toggle-list {
  display: grid;
  gap: 10px;
}

.toggle-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.toggle-row input {
  width: 20px;
  height: 20px;
  accent-color: var(--sage);
}

.search-results {
  display: grid;
  gap: 10px;
}

@media (min-width: 700px) {
  body {
    padding: 24px 0;
  }

  .app-shell {
    min-height: calc(100svh - 48px);
    border-radius: 18px;
    box-shadow: var(--shadow);
  }

  .topbar {
    border-radius: 18px 18px 0 0;
  }

  .tabbar {
    border-radius: 0 0 18px 18px;
  }
}
