:root {
  color-scheme: light;
  --ink: #17211c;
  --muted: #647067;
  --line: #dfe6de;
  --panel: #ffffff;
  --wash: #f4f7f1;
  --accent: #0d8f70;
  --accent-dark: #076d57;
  --mark: #e64f2e;
  --gold: #b88b42;
  --shadow: 0 16px 50px rgba(23, 33, 28, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.16)),
    url("https://images.unsplash.com/photo-1594633312681-425c7b97ccd1?auto=format&fit=crop&w=1600&q=80") center / cover fixed;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

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

button {
  cursor: pointer;
}

.shell {
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px clamp(14px, 4vw, 44px);
  border-bottom: 1px solid rgba(223, 230, 222, 0.9);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.logo {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  background: #17211c;
  color: #fff;
  font-weight: 800;
}

.brand-copy {
  min-width: 0;
}

.brand-copy strong,
.brand-copy span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.icon-btn,
.text-btn,
.primary-btn,
.ghost-btn,
.danger-btn {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 700;
}

.icon-btn {
  width: 42px;
  padding: 0;
}

.text-btn,
.primary-btn,
.ghost-btn,
.danger-btn {
  padding: 0 14px;
}

.primary-btn {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.primary-btn:hover {
  background: var(--accent-dark);
}

.ghost-btn {
  background: transparent;
}

.danger-btn {
  border-color: #ffd6cd;
  color: #b23620;
}

.danger-mini-btn {
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid #ffd6cd;
  border-radius: 8px;
  background: #fff;
  color: #b23620;
  font-weight: 800;
}

.danger-mini-btn:disabled {
  opacity: 0.6;
}

.main {
  padding: 18px clamp(12px, 4vw, 44px) 96px;
}

.album-stage {
  position: relative;
  display: grid;
  justify-content: center;
  justify-items: center;
  min-height: calc(100vh - 94px);
}

.album-phone {
  position: relative;
  overflow: hidden;
  width: min(100%, 416px);
  border: 1px solid rgba(23, 33, 28, 0.18);
  background: #fff;
  box-shadow: 0 18px 48px rgba(23, 33, 28, 0.18);
}

.category-page {
  position: relative;
  display: grid;
  justify-content: center;
  justify-items: center;
  min-height: calc(100vh - 36px);
}

.category-phone {
  position: relative;
  overflow: hidden;
  width: min(100%, 416px);
  border: 1px solid rgba(23, 33, 28, 0.18);
  background: #fff;
  box-shadow: 0 18px 48px rgba(23, 33, 28, 0.18);
}

.category-head {
  position: sticky;
  top: 0;
  z-index: 12;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 72px 116px;
  align-items: center;
  min-height: 58px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(10px);
}

.category-back {
  display: grid;
  width: 36px;
  min-height: 36px;
  place-items: center;
  border: 1px solid #edf0ed;
  border-radius: 999px;
  background: #fff;
  color: #111;
  font-size: 28px;
  font-weight: 300;
}

.category-head strong {
  overflow: hidden;
  text-align: center;
  color: #202821;
  font-size: 16px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-menu {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  height: 34px;
  border: 1px solid #e4e8e6;
  border-radius: 999px;
  text-align: center;
  font-weight: 900;
}

.category-search {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  margin: 0 14px 10px;
  padding: 0 12px;
  border-radius: 4px;
  background: #f6f7f8;
  color: #9aa29e;
}

.category-search input {
  flex: 1;
  min-width: 0;
  min-height: 0;
  height: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  outline: 0;
}

.category-page-icons {
  padding-top: 8px;
}

.category-page-icons .circle-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  min-height: 94px;
}

.category-banner {
  margin: 0;
}

.category-tabs {
  top: 58px;
  border-top: 0;
}

.category-product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 10px 8px 64px;
  background: #fff;
}

.category-product-card {
  position: relative;
  overflow: hidden;
  border: 1px solid #eef1ee;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(23, 33, 28, 0.06);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.category-product-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(23, 33, 28, 0.1);
}

.category-card-media {
  overflow: hidden;
  background: #f3f4f2;
}

.category-card-media img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1.02;
  object-fit: cover;
  background: #f3f4f2;
}

.category-card-copy {
  padding: 9px 9px 10px;
}

.category-card-copy p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: #17211c;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.42;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.category-card-copy div {
  display: flex;
  gap: 6px;
  margin-top: 8px;
  overflow: hidden;
}

.category-card-copy span {
  max-width: 76px;
  overflow: hidden;
  padding: 3px 6px;
  border-radius: 999px;
  background: #f3f7f5;
  color: #617068;
  font-size: 11px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-empty {
  display: grid;
  min-height: 180px;
  place-items: center;
  border-top: 1px solid #f0f0f0;
  color: #8a948f;
  font-size: 14px;
}

.mini-topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 76px;
  gap: 8px;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid #edf0ed;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
}

.language-switch {
  width: 100%;
  min-width: 64px;
  height: 36px;
  padding: 0 26px 0 10px;
  border: 1px solid #dfe7e1;
  border-radius: 18px;
  background: #fff;
  color: #15221b;
  font-size: 13px;
  font-weight: 700;
  outline: none;
}

.language-switch:focus {
  border-color: #0f9f73;
  box-shadow: 0 0 0 3px rgba(15, 159, 115, 0.12);
}

.mini-icon,
.mini-avatar,
.mini-pill {
  min-height: 34px;
  border: 1px solid #e3e7e2;
  border-radius: 999px;
  background: #fff;
  color: #15201b;
  font-weight: 800;
}

.mini-search {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  width: 100%;
  height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  background: #f1f3f2;
  color: #8b948f;
  font-size: 14px;
}

.mini-search span {
  flex: 0 0 auto;
}

.mini-search input {
  min-height: 0;
  height: 100%;
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0;
  color: #27352e;
  outline: none;
}

.mini-search input::placeholder {
  color: #8b948f;
}

.mini-search button {
  display: grid;
  width: 24px;
  height: 24px;
  min-height: 24px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: #ffffff;
  color: #718078;
  font-size: 16px;
  line-height: 1;
}

.mini-avatar {
  background: url("https://images.unsplash.com/photo-1500648767791-00dcc994a43e?auto=format&fit=crop&w=100&q=80") center / cover;
}

.mini-pill {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  place-items: center;
  border-radius: 999px;
}

.album-scroll {
  background: #fff;
}

.category-section {
  padding: 12px 12px 0;
  background: #fff;
}

.section-title {
  margin-bottom: 16px;
  padding: 9px 12px;
  border-radius: 4px;
  background: #fff1df;
  color: #ff7a00;
  font-size: 14px;
  line-height: 1.2;
}

.circle-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px 10px;
  padding: 0 2px 18px;
}

.circle-item {
  display: grid;
  gap: 7px;
  justify-items: center;
  min-width: 0;
  min-height: 84px;
  border: 0;
  background: transparent;
  color: #33413b;
  padding: 0;
  font-size: 12px;
  line-height: 1.2;
}

.circle-item span:last-child {
  width: 100%;
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.circle-photo {
  overflow: hidden;
  width: 54px;
  height: 54px;
  border-radius: 999px;
  background: #ebe6dc;
  box-shadow: inset 0 0 0 1px rgba(23, 33, 28, 0.05);
}

.category-section:first-child .circle-grid {
  gap: 17px 8px;
}

.category-section:first-child .circle-photo {
  width: 58px;
  height: 58px;
}

.circle-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.wide-banner {
  position: relative;
  overflow: hidden;
  height: 154px;
  margin: 0 -12px;
  background: #eceee9;
}

.wide-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.wide-banner span {
  position: absolute;
  right: 32px;
  bottom: 12px;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.65);
}

.wide-banner span:nth-child(3) {
  right: 20px;
}

.wide-banner span:nth-child(4) {
  right: 8px;
  background: #fff;
}

.feed-section {
  background: #fff;
  padding-bottom: 56px;
}

.feed-tabs {
  position: sticky;
  top: 58px;
  z-index: 8;
  display: flex;
  align-items: center;
  gap: 18px;
  height: 52px;
  padding: 0 14px;
  border-top: 1px solid #f0f0f0;
  border-bottom: 1px solid #eeeeee;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
}

.feed-tabs button {
  position: relative;
  min-height: 38px;
  border: 0;
  background: transparent;
  color: #111;
  padding: 0;
  font-size: 14px;
  font-weight: 700;
}

.feed-tabs button.active::after {
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 22px;
  height: 3px;
  border-radius: 999px;
  background: #13c47f;
  content: "";
}

.feed-spacer {
  flex: 1;
}

.feed-tabs .feed-icon {
  display: grid;
  width: 38px;
  height: 42px;
  place-items: center;
  color: #303832;
  font-size: 21px;
  font-weight: 700;
}

.feed-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-bottom: 1px solid #f0f0f0;
}

.feed-grid.feed-mode-large,
.feed-grid.feed-mode-single,
.feed-grid.feed-mode-excel {
  grid-template-columns: 1fr;
}

.feed-grid.feed-mode-small,
.feed-grid.feed-mode-gallery {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feed-grid.feed-mode-waterfall {
  display: block;
  columns: 2;
  column-gap: 0;
}

.feed-grid.gallery-grid-mode {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 2px;
  padding: 2px;
  border: 0;
  background: #fff;
}

.feed-grid.feed-mode-multi,
.feed-grid.feed-mode-dynamic {
  grid-template-columns: 1fr;
}

.feed-grid.feed-mode-multi {
  gap: 0;
  padding: 0 12px 8px;
  border: 0;
}

.feed-grid.feed-mode-multi::before {
  display: block;
  margin: 14px 0 8px;
  color: #111;
  font-size: 18px;
  font-weight: 700;
  content: "昨天⌄";
}

.feed-empty {
  grid-column: 1 / -1;
  display: grid;
  min-height: 180px;
  place-items: center;
  color: #8a948f;
  font-size: 14px;
}

.gallery-card {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: #eeeeee;
}

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

.gallery-card::after {
  position: absolute;
  inset: auto 0 0;
  height: 38%;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.42));
  content: "";
}

.gallery-card span {
  position: absolute;
  left: 6px;
  bottom: 5px;
  z-index: 1;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

.multi-card {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr) 46px;
  gap: 10px;
  align-items: center;
  min-height: 92px;
  padding: 7px 0;
  border-bottom: 1px solid #f1f1f1;
  background: #fff;
  cursor: pointer;
  transition: background 0.16s ease;
}

.multi-card:hover,
.feed-card:hover {
  background: #fafafa;
}

.feed-card {
  cursor: pointer;
}

.multi-photos {
  display: grid;
  grid-template-columns: repeat(2, 38px);
  grid-auto-rows: 38px;
  gap: 4px;
  align-content: center;
  justify-content: center;
}

.multi-photos img {
  width: 38px;
  height: 38px;
  object-fit: cover;
  background: #f0f0f0;
}

.multi-copy {
  min-width: 0;
}

.multi-copy p {
  display: -webkit-box;
  min-height: 38px;
  margin: 0 0 8px;
  overflow: hidden;
  color: #111;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.38;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.multi-links {
  display: flex;
  gap: 10px;
}

.multi-links button {
  min-height: 22px;
  border: 0;
  background: transparent;
  color: #49709c;
  padding: 0;
  font-size: 12px;
}

.multi-save {
  min-height: 28px;
  border: 1px solid #45c86f;
  border-radius: 5px;
  background: #fff;
  color: #2db45f;
  padding: 0 8px;
  font-size: 12px;
  font-weight: 700;
}

.feed-card {
  position: relative;
  min-width: 0;
  border-right: 1px solid #f0f0f0;
  border-bottom: 1px solid #f0f0f0;
  background: #fff;
}

.feed-mode-waterfall .feed-card {
  display: inline-block;
  width: 100%;
  break-inside: avoid;
}

.feed-mode-large .feed-card,
.feed-mode-single .feed-card,
.feed-mode-multi .feed-card,
.feed-mode-dynamic .feed-card,
.feed-mode-excel .feed-card {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  align-items: center;
  border-right: 0;
}

.feed-mode-large .feed-card {
  display: block;
}

.feed-mode-excel .feed-card {
  grid-template-columns: 74px minmax(0, 1fr);
  min-height: 78px;
}

.feed-mode-dynamic .feed-card:nth-child(3n + 1) {
  display: block;
}

.feed-card:nth-child(2n) {
  border-right: 0;
}

.feed-card img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1.18;
  object-fit: cover;
  background: #f7f7f7;
}

.feed-mode-small .feed-card img,
.feed-mode-gallery .feed-card img {
  aspect-ratio: 1 / 1;
}

.feed-mode-large .feed-card img {
  aspect-ratio: 1 / 0.78;
}

.feed-mode-single .feed-card img,
.feed-mode-multi .feed-card img,
.feed-mode-dynamic .feed-card img {
  height: 132px;
  aspect-ratio: auto;
}

.feed-mode-excel .feed-card img {
  height: 78px;
  aspect-ratio: auto;
}

.feed-card p {
  display: -webkit-box;
  min-height: 48px;
  margin: 0;
  overflow: hidden;
  padding: 8px 8px 12px;
  color: #111;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.32;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.feed-mode-small .feed-card p,
.feed-mode-gallery .feed-card p {
  min-height: 42px;
  padding: 6px;
  font-size: 11px;
}

.feed-mode-large .feed-card p {
  min-height: 0;
  padding: 10px 12px 14px;
  font-size: 14px;
}

.feed-mode-single .feed-card p,
.feed-mode-multi .feed-card p,
.feed-mode-dynamic .feed-card p,
.feed-mode-excel .feed-card p {
  min-height: 0;
  padding: 10px;
  -webkit-line-clamp: 3;
}

.feed-mode-excel .feed-card p {
  font-size: 12px;
}

.modal-mask,
.drawer-mask {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  justify-content: center;
  background: rgba(0, 0, 0, 0.46);
}

.modal-mask {
  align-items: end;
}

.display-sheet {
  position: relative;
  width: min(100vw - 24px, 416px);
  margin-bottom: 36px;
  border-radius: 18px 18px 0 0;
  background: #f0f0f0;
  padding: 18px 16px 36px;
  box-shadow: 0 -12px 34px rgba(0, 0, 0, 0.18);
}

.display-sheet h2 {
  margin: 4px 0 18px;
  text-align: center;
  color: #333;
  font-size: 17px;
  font-weight: 500;
}

.category-sheet-mask {
  position: absolute;
  inset: 0;
  z-index: 66;
  width: 100%;
  transform: none;
  align-items: end;
  justify-content: center;
  background: rgba(0, 0, 0, 0.46);
}

.category-sheet {
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr);
  width: 100%;
  height: min(76vh, 640px);
  max-height: calc(100vh - 72px);
  overflow: hidden;
  border: 1px solid rgba(227, 233, 229, 0.92);
  border-radius: 16px 16px 0 0;
  background: #fff;
  box-shadow: 0 -18px 44px rgba(20, 28, 24, 0.22);
}

.category-sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
  padding: 0 16px 0 18px;
  border-bottom: 1px solid #edf1ed;
  background: linear-gradient(180deg, #fff 0%, #fbfcfb 100%);
}

.category-sheet-head strong {
  color: #17211c;
  font-size: 18px;
  font-weight: 800;
}

.category-batch-btn {
  min-height: 30px;
  padding: 0 12px;
  border: 1px solid #e1ebe6;
  border-radius: 999px;
  background: #f8fbf9;
  color: #26352f;
  font-size: 12px;
  font-weight: 800;
}

.category-sheet-tabs {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 11px 12px 10px;
  border-bottom: 1px solid #f2f4f2;
  background: #fff;
  scrollbar-width: none;
}

.category-sheet-tabs::-webkit-scrollbar {
  display: none;
}

.category-sheet-tabs button {
  position: relative;
  flex: 0 0 auto;
  border: 0;
  border-radius: 999px;
  background: #f5f7f6;
  color: #2e3c36;
  padding: 8px 11px;
  font-size: 13px;
  font-weight: 700;
}

.category-sheet-tabs button.active {
  background: #e7f8ef;
  color: #08a664;
}

.category-sheet-tabs button.active::after {
  display: none;
}

.category-sheet-path {
  display: flex;
  gap: 9px;
  align-items: center;
  padding: 12px 14px 11px;
  border-bottom: 1px solid #f1f4f2;
  background: #fff;
  color: #718078;
  font-size: 13px;
}

.category-sheet-path strong {
  color: #08aa67;
  font-size: 13px;
}

.category-sheet-content {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  min-height: 0;
  overflow: hidden;
  background: linear-gradient(90deg, #f6f8f7 0 104px, #fff 104px);
}

.category-sheet-rail {
  display: grid;
  align-content: start;
  overflow: hidden;
  background: transparent;
  scrollbar-width: none;
}

.category-sheet-rail::-webkit-scrollbar {
  display: none;
}

.category-sheet-rail button {
  position: relative;
  min-height: 48px;
  border: 0;
  background: transparent;
  color: #26352f;
  font-size: 13px;
  line-height: 1.25;
  padding: 0 8px;
}

.category-sheet-rail button.active {
  background: #fff;
  color: #08aa67;
  font-weight: 800;
}

.category-sheet-rail button.active::before {
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 3px;
  border-radius: 0 999px 999px 0;
  background: #13c47f;
  content: "";
}

.category-sheet-products {
  overflow-y: auto;
  padding: 12px 12px 86px;
  background: transparent;
  scrollbar-width: thin;
  scrollbar-color: #d5ddd8 transparent;
}

.category-sheet-product-group {
  margin-bottom: 24px;
}

.category-sheet-product-group h4 {
  margin: 0 0 12px;
  color: #26352f;
  font-size: 13px;
  font-weight: 800;
}

.category-sheet-product-group:first-child h4 {
  color: #08aa67;
}

.category-sheet-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px 10px;
}

.category-sheet-card {
  display: grid;
  gap: 7px;
  justify-items: center;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0;
}

.category-sheet-card span {
  overflow: hidden;
  width: 82px;
  max-width: 100%;
  aspect-ratio: 1 / 0.92;
  border-radius: 8px;
  background: #eef1ee;
  box-shadow: inset 0 0 0 1px rgba(23, 33, 28, 0.04);
}

.category-sheet-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-sheet-card em {
  width: 100%;
  overflow: hidden;
  color: #66746d;
  font-size: 12.5px;
  font-style: normal;
  line-height: 1.25;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-sheet-card:active span {
  box-shadow: 0 0 0 2px rgba(19, 196, 127, 0.28);
}

.category-sheet-card:active em {
  color: #07945a;
}

.sheet-close {
  position: absolute;
  left: 18px;
  top: 18px;
  display: grid;
  width: 24px;
  height: 24px;
  min-height: 24px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #5f6c65;
  font-size: 18px;
}

.mode-group {
  margin-top: 18px;
}

.mode-title {
  margin: 0 0 9px 8px;
  color: #747d78;
  font-size: 13px;
}

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

.mode-card {
  position: relative;
  display: grid;
  gap: 8px;
  min-height: 124px;
  border: 2px solid transparent;
  border-radius: 8px;
  background: #fff;
  padding: 7px 6px 9px;
  color: #333;
  font-size: 14px;
  font-weight: 400;
}

.mode-card.active {
  border-color: #45c86f;
}

.mode-check {
  position: absolute;
  right: -2px;
  top: -2px;
  display: grid;
  width: 19px;
  height: 19px;
  place-items: center;
  border-radius: 0 7px 0 8px;
  background: #45c86f;
  color: #fff;
  font-size: 13px;
}

.mode-preview {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 5px;
  min-height: 72px;
  border-radius: 5px;
  background: #f1f1f1;
  padding: 8px;
}

.mode-preview i {
  display: block;
  min-height: 13px;
  border-radius: 3px;
  background: #fff;
}

.mode-card strong {
  font-size: 14px;
  font-weight: 500;
}

.drawer-mask {
  align-items: stretch;
  justify-content: center;
}

.filter-drawer {
  display: grid;
  grid-template-rows: auto 1fr auto;
  width: min(100vw - 42px, 374px);
  min-height: calc(100vh - 52px);
  margin-top: 26px;
  margin-left: 42px;
  border-radius: 16px 16px 0 0;
  background: #fff;
  box-shadow: -10px 0 32px rgba(0, 0, 0, 0.2);
}

.drawer-head {
  display: grid;
  grid-template-columns: 44px 1fr 110px;
  align-items: center;
  height: 58px;
  padding: 0 16px;
}

.drawer-x {
  border: 0;
  background: transparent;
  color: #1f2a24;
  font-size: 32px;
  font-weight: 300;
}

.drawer-head strong {
  text-align: center;
  font-size: 16px;
  font-weight: 500;
}

.drawer-mini {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  height: 34px;
  border: 1px solid #e4e8e6;
  border-radius: 999px;
  text-align: center;
  font-weight: 800;
}

.filter-body {
  padding: 6px 18px;
  color: #202a25;
}

.filter-row,
.filter-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 18px;
  font-size: 14px;
}

.clear-filter,
.filter-line button {
  border: 0;
  background: transparent;
  color: #b8d9c3;
  font-size: 14px;
}

.filter-line button {
  color: #8e9892;
}

.date-range,
.quick-filter {
  display: grid;
  grid-template-columns: 1fr 28px 1fr;
  gap: 10px;
  align-items: center;
  margin-top: 14px;
}

.date-range button,
.quick-filter button,
.reset-filter,
.confirm-filter {
  min-height: 36px;
  border: 0;
  border-radius: 999px;
  background: #f6f7f7;
  color: #87918b;
  font-size: 14px;
  font-weight: 500;
}

.date-range span {
  text-align: center;
}

.quick-filter {
  grid-template-columns: repeat(3, 1fr);
}

.quick-filter.single {
  grid-template-columns: 104px;
}

.quick-filter button {
  color: #333;
}

.quick-filter button.active,
.date-range button.active {
  background: #e7f8ed;
  color: #21a957;
  font-weight: 700;
}

.active-filter-note {
  margin-top: 18px;
  color: #6f7a73;
  font-size: 13px;
}

.drawer-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 12px 18px 10px;
}

.reset-filter,
.confirm-filter {
  min-height: 40px;
  color: #222;
}

.confirm-filter {
  background: #49c66c;
  color: #fff;
}

.feed-share {
  position: absolute;
  right: 10px;
  top: 10px;
  display: grid;
  width: 22px;
  height: 22px;
  min-height: 22px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: #c7c7c7;
  font-size: 13px;
}

.feed-share.video-mark {
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
}

.feed-share.gallery-count-mark {
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.video-mask {
  position: fixed;
  inset: 0;
  z-index: 74;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.58);
}

.video-sheet {
  position: relative;
  width: min(100vw - 34px, 382px);
  border-radius: 12px;
  background: #fff;
  padding: 12px;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.26);
}

.video-sheet > button {
  position: absolute;
  right: 10px;
  top: 10px;
  z-index: 1;
  width: 32px;
  min-height: 32px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  font-size: 22px;
}

.video-player {
  display: grid;
  width: 100%;
  aspect-ratio: 16 / 10;
  place-items: center;
  border-radius: 10px;
  background: #111;
  color: #fff;
  font-size: 54px;
}

.video-sheet strong {
  display: block;
  margin-top: 12px;
  color: #111;
  font-size: 15px;
  line-height: 1.4;
}

.video-sheet p {
  margin: 8px 0 0;
  color: #68756e;
  font-size: 13px;
}

.gallery-share {
  z-index: 2;
  right: 6px;
  top: 6px;
  background: rgba(255, 255, 255, 0.82);
  color: #b9b9b9;
}

.bottom-tabs {
  position: sticky;
  bottom: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  height: 50px;
  border-top: 1px solid #ebebeb;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
}

.bottom-tabs button {
  border: 0;
  border-right: 1px solid #efefef;
  background: transparent;
  color: #111;
  font-size: 13px;
  font-weight: 700;
}

.bottom-tabs button:active {
  background: #f3f7f5;
}

.batch-mask {
  position: fixed;
  inset: 0;
  z-index: 65;
  display: grid;
  align-items: end;
  justify-content: center;
  background: rgba(0, 0, 0, 0.36);
}

.batch-panel {
  width: min(100vw, 416px);
  max-height: 78vh;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  border-radius: 18px 18px 0 0;
  background: #fff;
  box-shadow: 0 -16px 36px rgba(0, 0, 0, 0.2);
}

.batch-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 10px;
  border-bottom: 1px solid #eef1ee;
}

.batch-head strong {
  font-size: 16px;
}

.batch-head button {
  width: 32px;
  min-height: 32px;
  border: 0;
  border-radius: 999px;
  background: #f4f6f5;
  font-size: 22px;
}

.batch-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  overflow: auto;
  padding: 12px;
}

.batch-item {
  position: relative;
  display: grid;
  gap: 6px;
  min-height: 132px;
  border: 1px solid #eef1ee;
  border-radius: 8px;
  background: #fff;
  padding: 6px;
  text-align: left;
}

.batch-item.active {
  border-color: #25d366;
  box-shadow: inset 0 0 0 1px #25d366;
}

.batch-item img {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 6px;
  object-fit: cover;
  background: #f2f2f2;
}

.batch-item span {
  display: -webkit-box;
  overflow: hidden;
  color: #1a241f;
  font-size: 12px;
  line-height: 1.3;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.batch-item i {
  position: absolute;
  right: 8px;
  top: 8px;
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 999px;
  background: #25d366;
  color: #fff;
  font-style: normal;
  font-weight: 900;
}

.batch-item:not(.active) i {
  display: none;
}

.batch-actions {
  display: grid;
  grid-template-columns: 1fr 72px 1.4fr;
  gap: 8px;
  padding: 10px 12px 12px;
  border-top: 1px solid #eef1ee;
}

.bottom-tabs button:last-child {
  border-right: 0;
}

.bottom-tabs button.active {
  color: #126cc8;
}

.compact-toolbar {
  grid-template-columns: 1fr 1fr;
  margin: 0 0 14px;
}

.compact-toolbar input {
  grid-column: 1 / -1;
}

.float-top {
  position: fixed;
  right: max(18px, calc((100vw - 416px) / 2 + 14px));
  bottom: 86px;
  z-index: 25;
  width: 48px;
  min-height: 48px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  color: #303832;
  box-shadow: 0 10px 28px rgba(23, 33, 28, 0.18);
  font-size: 24px;
  line-height: 1;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 24px;
  align-items: stretch;
  min-height: 420px;
  margin-bottom: 24px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(22px, 5vw, 56px) 0;
}

.eyebrow {
  color: var(--gold);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  max-width: 760px;
  margin-bottom: 16px;
  font-size: clamp(38px, 7vw, 82px);
  line-height: 0.95;
  letter-spacing: 0;
}

.hero-copy p {
  max-width: 620px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.hero-actions,
.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.hero-media {
  position: relative;
  overflow: hidden;
  min-height: 380px;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-chip {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 8px;
  align-items: center;
  max-width: calc(100% - 28px);
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  font-size: 13px;
  font-weight: 800;
}

.toolbar,
.admin-toolbar {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) repeat(3, minmax(120px, 180px));
  gap: 10px;
  align-items: center;
  margin: 20px 0;
}

.field,
.upload-zone {
  display: grid;
  gap: 7px;
}

label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 10px 12px;
}

textarea {
  min-height: 92px;
  resize: vertical;
}

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

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

.product-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 8px 26px rgba(23, 33, 28, 0.06);
}

.product-grid-compact .product-card {
  min-width: 0;
  box-shadow: 0 8px 20px rgba(23, 33, 28, 0.08);
}

.product-card a {
  color: inherit;
  text-decoration: none;
}

.thumb {
  position: relative;
  aspect-ratio: 4 / 5;
  background: #e8ece5;
}

.product-grid-compact .thumb {
  aspect-ratio: 1 / 1.05;
}

.thumb img,
.detail-photo img,
.small-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.badge {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 6px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--mark);
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  display: grid;
  gap: 8px;
  padding: 12px;
}

.product-grid-compact .card-body {
  gap: 7px;
  padding: 10px;
}

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

.card-title h3 {
  margin: 0;
  font-size: 15px;
  line-height: 1.35;
}

.product-grid-compact .card-title {
  display: grid;
  gap: 4px;
}

.product-grid-compact .card-title h3 {
  overflow: hidden;
  font-size: 14px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
  word-break: keep-all;
}

.price {
  color: var(--accent-dark);
  font-weight: 900;
  white-space: nowrap;
}

.product-grid-compact .price {
  font-size: 14px;
}

.muted {
  color: var(--muted);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  padding: 5px 7px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.product-grid-compact .tags {
  flex-wrap: nowrap;
  overflow: hidden;
}

.product-grid-compact .tag {
  max-width: 76px;
  overflow: hidden;
  padding: 4px 6px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-grid-compact .muted {
  overflow: hidden;
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
  word-break: keep-all;
}

.product-grid-compact .row-actions {
  display: grid;
  grid-template-columns: 1fr 34px 34px;
  gap: 7px;
}

.product-grid-compact .primary-btn {
  min-width: 0;
  padding: 0 8px;
  white-space: nowrap;
}

.product-grid-compact .icon-btn {
  width: 34px;
  min-height: 36px;
}

.product-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 450px);
  gap: 24px;
}

.commerce-detail {
  position: relative;
  width: min(100%, 416px);
  min-height: calc(100vh - 36px);
  margin: 0 auto;
  padding-bottom: 82px;
  border: 1px solid rgba(23, 33, 28, 0.14);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 18px 48px rgba(23, 33, 28, 0.16);
}

.detail-shopbar {
  position: sticky;
  top: 0;
  z-index: 18;
  display: grid;
  grid-template-columns: 32px 40px minmax(0, 1fr) 68px 42px;
  gap: 8px;
  align-items: center;
  min-height: 58px;
  padding: 8px 10px;
  border-bottom: 1px solid #e9eee9;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.detail-back,
.detail-tool {
  display: grid;
  min-height: 38px;
  place-items: center;
  border: 1px solid #dfe6de;
  border-radius: 8px;
  background: #fff;
  color: #17211c;
  font-size: 20px;
  font-weight: 700;
}

.detail-back {
  border: 0;
  background: transparent;
  font-size: 34px;
  font-weight: 300;
}

.detail-shopbar strong {
  overflow: hidden;
  font-size: 16px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-hero {
  position: relative;
  margin: 12px 8px 14px;
  width: auto;
  overflow: hidden;
  border-radius: 9px;
  background: #f1f2f0;
  box-shadow: 0 12px 34px rgba(23, 33, 28, 0.14);
}

.detail-hero-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  cursor: grab;
  touch-action: pan-y;
  user-select: none;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.detail-hero-track.dragging {
  cursor: grabbing;
  scroll-behavior: auto;
  scroll-snap-type: none;
}

.detail-hero-track::-webkit-scrollbar {
  display: none;
}

.detail-hero-track img {
  display: block;
  flex: 0 0 100%;
  width: 100%;
  min-height: 420px;
  max-height: 620px;
  object-fit: cover;
  scroll-snap-align: start;
  -webkit-user-drag: none;
}

.detail-hero-track img {
  cursor: zoom-in;
}

.detail-carousel-arrow {
  position: absolute;
  top: 50%;
  z-index: 2;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 999px;
  background: rgba(20, 24, 22, 0.28);
  color: #fff;
  font-size: 26px;
  line-height: 1;
  display: grid;
  place-items: center;
  transform: translateY(-50%);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
}

.detail-carousel-arrow.prev {
  left: 10px;
}

.detail-carousel-arrow.next {
  right: 10px;
}

.detail-carousel-arrow:disabled {
  opacity: 0.22;
}

.detail-carousel-dots {
  position: absolute;
  left: 50%;
  bottom: 12px;
  z-index: 2;
  display: flex;
  gap: 5px;
  transform: translateX(-50%);
}

.detail-carousel-dots span {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.56);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.22);
}

.detail-carousel-dots span.active {
  width: 16px;
  background: #fff;
}

.detail-zoom-hint {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 3;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: 999px;
  background: rgba(20, 24, 22, 0.36);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(8px);
}

.detail-count {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  font-size: 12px;
}

.detail-video-card {
  margin: 0 10px 12px;
  overflow: hidden;
  border: 1px solid rgba(223, 230, 222, 0.95);
  border-radius: 8px;
  background: #fff;
}

.detail-video-frame {
  position: relative;
  background: #111;
}

.detail-video-frame img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  opacity: 0.78;
}

.detail-video-frame video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  object-fit: contain;
}

.detail-video-frame span {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #111;
  font-size: 24px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

.detail-video-copy {
  padding: 11px 12px 13px;
}

.detail-video-copy strong {
  color: #111;
  font-size: 15px;
  font-weight: 800;
}

.detail-video-copy p {
  margin: 5px 0 0;
  color: #68756e;
  font-size: 13px;
  line-height: 1.5;
}

.detail-info-card,
.detail-option-card {
  margin: 0 10px 12px;
  border: 1px solid rgba(223, 230, 222, 0.95);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  padding: 12px;
}

.detail-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.detail-price-row strong {
  color: #00866c;
  font-size: 23px;
  font-weight: 900;
}

.detail-price-row button {
  min-height: 32px;
  border: 1px solid #dfe6de;
  border-radius: 999px;
  background: #fff;
  color: #52635a;
  padding: 0 12px;
  font-size: 13px;
}

.detail-info-card h1 {
  margin: 0 0 8px;
  color: #101b16;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.45;
}

.detail-info-card p {
  margin-bottom: 10px;
  color: #68756e;
  font-size: 13px;
  line-height: 1.6;
}

.detail-mini-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.detail-mini-specs span {
  padding: 5px 8px;
  border: 1px solid #dfe8e0;
  border-radius: 999px;
  color: #52635a;
  font-size: 12px;
}

.detail-option-card {
  display: grid;
  gap: 0;
  padding: 0 12px;
}

.detail-text-card {
  margin: 0 10px 12px;
  border: 1px solid rgba(223, 230, 222, 0.95);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.97);
  padding: 14px 14px 16px;
}

.detail-text-card h2 {
  display: inline-block;
  margin: 0 0 22px;
  padding-bottom: 4px;
  border-bottom: 3px solid #0d8f70;
  color: #111;
  font-size: 16px;
  font-weight: 800;
}

.detail-text-card p,
.detail-text-card li {
  color: #202b25;
  font-size: 14px;
  line-height: 1.75;
}

.detail-text-card p {
  margin: 0 0 4px;
}

.detail-custom-copy {
  color: #202b25;
  font-size: 14px;
  line-height: 1.78;
  white-space: pre-line;
  word-break: break-word;
}

.detail-empty {
  color: var(--muted);
}

.detail-text-card ul {
  display: grid;
  gap: 2px;
  margin: 0 0 4px;
  padding-left: 0;
  list-style: none;
}

.detail-text-card li::before {
  content: "· ";
}

.option-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid #edf1ed;
  color: #738077;
  font-size: 13px;
}

.option-row:last-child {
  border-bottom: 0;
}

.option-row strong {
  color: #19231e;
  font-weight: 700;
  text-align: right;
}

.detail-section-title {
  margin: 16px 10px 10px;
  padding-left: 9px;
  border-left: 3px solid #0d8f70;
  color: #18231e;
  font-size: 15px;
  font-weight: 800;
}

.detail-image-flow {
  display: grid;
  gap: 14px;
  padding: 0 10px;
}

.detail-image-flow img {
  width: 100%;
  border-radius: 8px;
  object-fit: cover;
  background: #eef0ec;
  cursor: zoom-in;
}

.image-viewer-mask {
  position: fixed;
  inset: 0;
  z-index: 86;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.82);
}

.image-viewer {
  position: relative;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto auto;
  width: min(100vw, 416px);
  height: 100vh;
  background: #050505;
}

.image-viewer-close {
  position: absolute;
  right: 14px;
  top: 14px;
  z-index: 2;
  display: grid;
  width: 36px;
  min-height: 36px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 26px;
}

.image-viewer-stage {
  display: grid;
  min-height: 0;
  place-items: center;
  padding: 56px 0 12px;
}

.image-viewer-stage img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.image-viewer-bar {
  display: grid;
  grid-template-columns: 52px 1fr 52px;
  align-items: center;
  padding: 8px 16px;
  color: #fff;
}

.image-viewer-bar button {
  min-height: 42px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 30px;
}

.image-viewer-bar strong {
  text-align: center;
  font-size: 14px;
}

.image-viewer-thumbs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 8px 12px 16px;
}

.image-viewer-thumbs button {
  flex: 0 0 54px;
  overflow: hidden;
  width: 54px;
  height: 54px;
  border: 2px solid transparent;
  border-radius: 6px;
  background: #111;
  padding: 0;
}

.image-viewer-thumbs button.active {
  border-color: #12c27d;
}

.image-viewer-thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-bottom-bar {
  position: fixed;
  left: 50%;
  bottom: 10px;
  z-index: 30;
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr) minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  width: min(calc(100vw - 24px), 396px);
  min-height: 64px;
  transform: translateX(-50%);
  border: 1px solid rgba(13, 143, 112, 0.32);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 12px 36px rgba(23, 33, 28, 0.16);
  padding: 9px 10px;
}

.detail-bottom-bar div {
  display: grid;
  min-width: 0;
}

.detail-bottom-bar strong {
  font-size: 14px;
}

.detail-bottom-bar span {
  overflow: hidden;
  color: #68756e;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-bottom-bar button {
  min-width: 0;
  min-height: 44px;
  padding: 0 10px;
  white-space: nowrap;
}

.share-platform-trigger {
  position: relative;
  display: grid;
  grid-template-rows: 18px 16px;
  gap: 2px;
  place-items: center;
  border: 1px solid #dfe6de;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff, #f7fbf8);
  color: #168f64;
  font-size: 12px;
  font-weight: 800;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}

.share-platform-trigger .cart-icon {
  color: #0d8f70;
  font-size: 18px;
  line-height: 1;
}

.share-platform-trigger em {
  position: absolute;
  right: 9px;
  top: 6px;
  display: grid;
  min-width: 17px;
  height: 17px;
  place-items: center;
  border-radius: 999px;
  background: #ff4d35;
  color: #fff;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.inquiry-orange,
.share-green {
  border: 0;
  border-radius: 9px;
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(23, 33, 28, 0.12);
}

.inquiry-orange {
  background: linear-gradient(180deg, #ffa83f, #ff8f25);
}

.share-green {
  background: linear-gradient(180deg, #54cf75, #39b85d);
}

.share-mask {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  align-items: end;
  justify-content: center;
  background: rgba(0, 0, 0, 0.36);
}

.share-sheet {
  width: min(100vw, 416px);
  border-radius: 18px 18px 0 0;
  background: #fff;
  padding: 10px 16px 16px;
  box-shadow: 0 -16px 36px rgba(0, 0, 0, 0.2);
}

.share-handle {
  width: 42px;
  height: 4px;
  margin: 0 auto 12px;
  border-radius: 999px;
  background: #d8ded9;
}

.share-sheet h2 {
  margin: 0 0 14px;
  text-align: center;
  color: #15201b;
  font-size: 16px;
  font-weight: 800;
}

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

.share-platforms button {
  display: grid;
  gap: 7px;
  justify-items: center;
  min-height: 76px;
  border: 1px solid #edf1ed;
  border-radius: 8px;
  background: #fbfcfb;
  color: #18231e;
  padding: 10px 6px;
}

.platform-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  font-size: 16px;
  font-weight: 900;
}

.platform-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.2;
}

.platform-icon.wa svg,
.platform-icon.ms svg {
  fill: currentColor;
  stroke: none;
}

.platform-icon .brand-letter {
  color: inherit;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
}

.platform-icon.wa {
  background: #25d366;
}

.platform-icon.ig {
  background: radial-gradient(circle at 30% 110%, #feda75 0 24%, #fa7e1e 35%, #d62976 58%, #962fbf 78%, #4f5bd5 100%);
}

.platform-icon.fb,
.platform-icon.ms {
  background: #1877f2;
}

.platform-icon.x {
  background: #111;
}

.platform-icon.cp {
  background: #6b7b72;
}

.share-platforms strong {
  font-size: 12px;
}

.share-cancel {
  width: 100%;
  min-height: 42px;
  margin-top: 14px;
  border: 0;
  border-radius: 8px;
  background: #f4f6f5;
  color: #53635b;
  font-weight: 800;
}

.cart-mask {
  position: fixed;
  inset: 0;
  z-index: 72;
  display: grid;
  align-items: end;
  justify-content: center;
  background: rgba(0, 0, 0, 0.36);
}

.forward-cart-sheet {
  width: min(100vw, 416px);
  max-height: 76vh;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  border-radius: 18px 18px 0 0;
  background: #fff;
  box-shadow: 0 -16px 36px rgba(0, 0, 0, 0.22);
}

.cart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 10px;
  border-bottom: 1px solid #edf1ed;
}

.cart-head div {
  display: grid;
  gap: 2px;
}

.cart-head strong {
  color: #14211b;
  font-size: 17px;
}

.cart-head span {
  color: #68766f;
  font-size: 12px;
}

.cart-head button {
  display: grid;
  width: 32px;
  min-height: 32px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: #f4f6f5;
  color: #222;
  font-size: 22px;
}

.forward-cart-list {
  overflow: auto;
  padding: 8px 12px;
}

.forward-cart-item {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) 50px;
  gap: 10px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #edf1ed;
}

.forward-cart-item img {
  width: 62px;
  height: 62px;
  border-radius: 7px;
  object-fit: cover;
  background: #f1f1f1;
}

.forward-cart-item div {
  min-width: 0;
}

.forward-cart-item strong {
  display: -webkit-box;
  overflow: hidden;
  color: #14211b;
  font-size: 13px;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.forward-cart-item span {
  display: block;
  overflow: hidden;
  margin-top: 4px;
  color: #6a7870;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.forward-cart-item button {
  min-height: 30px;
  border: 1px solid #ffd7d1;
  border-radius: 7px;
  background: #fff;
  color: #d64b36;
  font-size: 12px;
  font-weight: 700;
}

.forward-cart-empty {
  display: grid;
  min-height: 180px;
  place-items: center;
  color: #748078;
  font-size: 14px;
  text-align: center;
}

.forward-cart-actions {
  display: grid;
  grid-template-columns: 72px 1fr 1.25fr;
  gap: 8px;
  padding: 10px 12px 12px;
  border-top: 1px solid #edf1ed;
}

.forward-cart-actions button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.whatsapp-side {
  position: fixed;
  left: calc(50% + 118px);
  bottom: 126px;
  z-index: 28;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  border: 0;
  border-radius: 4px;
  background: #25d366;
  box-shadow: 0 10px 24px rgba(23, 33, 28, 0.18);
  padding: 0 9px 0 7px;
}

.whatsapp-side .wa-mark {
  width: 15px;
  height: 15px;
  border-radius: 999px;
  background: transparent;
  color: #fff;
}

.whatsapp-side svg {
  display: block;
  width: 15px;
  height: 15px;
  fill: currentColor;
}

.whatsapp-side small {
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  line-height: 28px;
}

@media (max-width: 480px) {
  .whatsapp-side {
    right: 18px;
    left: auto;
  }
}

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

.detail-photo {
  overflow: hidden;
  aspect-ratio: 4 / 5;
  border-radius: 8px;
  background: #e8ece5;
}

.detail-panel,
.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 18px;
  box-shadow: 0 8px 26px rgba(23, 33, 28, 0.06);
}

.detail-panel {
  position: sticky;
  top: 82px;
  align-self: start;
}

.spec-list {
  display: grid;
  gap: 9px;
  margin: 18px 0;
}

.spec-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.spec-row strong {
  color: var(--ink);
  text-align: right;
}

.sticky-inquiry {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(13, 143, 112, 0.35);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.admin-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 18px;
}

.side-nav {
  position: sticky;
  top: 82px;
  align-self: start;
  display: grid;
  gap: 8px;
}

.side-nav button {
  justify-content: flex-start;
  text-align: left;
}

.admin-login-wrap {
  display: grid;
  min-height: calc(100vh - 120px);
  place-items: center;
}

.admin-login-card {
  width: min(100%, 420px);
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
}

.admin-login-card .logo {
  width: 48px;
  height: 48px;
  margin-bottom: 14px;
}

.admin-login-card h1 {
  margin: 0 0 8px;
  font-size: 28px;
}

.admin-login-card p {
  margin: 0 0 20px;
  color: var(--muted);
}

.admin-login-card label {
  display: grid;
  gap: 7px;
  margin-bottom: 14px;
  font-weight: 700;
}

.admin-login-card input {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: #fff;
}

.admin-login-card button {
  width: 100%;
  margin-top: 8px;
}

.admin-login-card em {
  display: block;
  min-height: 20px;
  margin-top: 10px;
  color: #b23620;
  font-style: normal;
  font-weight: 700;
}

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

.form-grid .wide {
  grid-column: 1 / -1;
}

.upload-zone {
  min-height: 150px;
  place-items: center;
  border: 1px dashed #aebbb0;
  border-radius: 8px;
  background: #fbfcfa;
  padding: 18px;
  text-align: center;
}

.admin-media-preview {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 10px;
  width: 100%;
  margin: 14px 0 6px;
  text-align: left;
}

.admin-media-preview figure {
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-media-preview img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.admin-media-preview figcaption {
  padding: 6px 7px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
  text-align: center;
}

.admin-video-preview {
  width: min(100%, 420px);
  margin: 14px auto 6px;
  text-align: left;
}

.admin-video-preview span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
}

.admin-video-preview video {
  display: block;
  width: 100%;
  max-height: 220px;
  border-radius: 8px;
  background: #111;
}

.image-strip,
.inquiry-list {
  display: grid;
  gap: 10px;
}

.small-img,
.inquiry-item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 8px;
}

.small-img {
  grid-template-columns: 58px minmax(0, 1fr) auto;
}

.small-img figure,
.inquiry-item figure {
  overflow: hidden;
  width: 58px;
  height: 70px;
  margin: 0;
  border-radius: 8px;
  background: #e8ece5;
}

.table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
}

.table th,
.table td {
  padding: 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

.table th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

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

.kpi strong {
  display: block;
  font-size: 28px;
}

.empty {
  display: grid;
  min-height: 240px;
  place-items: center;
  border: 1px dashed #aebbb0;
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  text-align: center;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 40;
  transform: translateX(-50%);
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  box-shadow: var(--shadow);
}

@media (max-width: 980px) {
  .hero,
  .product-detail,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .hero-media {
    min-height: 320px;
  }

  .toolbar,
  .admin-toolbar,
  .form-grid {
    grid-template-columns: 1fr 1fr;
  }

  .grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .product-grid-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-panel,
  .side-nav {
    position: static;
  }
}

@media (max-width: 680px) {
  .topbar {
    padding: 10px 12px;
  }

  .brand-copy span,
  .nav .text-btn {
    display: none;
  }

  .main {
    padding: 16px 12px 88px;
  }

  h1 {
    font-size: 42px;
  }

  .hero {
    gap: 12px;
    min-height: 0;
  }

  .hero-copy {
    padding: 10px 0 0;
  }

  .hero-media {
    min-height: 260px;
  }

  .toolbar,
  .admin-toolbar,
  .form-grid,
  .gallery,
  .kpis {
    grid-template-columns: 1fr;
  }

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

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

  .card-title {
    display: grid;
  }

  .sticky-inquiry {
    right: 12px;
    bottom: 12px;
    left: 12px;
    justify-content: space-between;
  }

  .table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

/* Refined mobile catalog typography. */
body {
  font-family: "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

input,
select,
textarea {
  font-size: 14px;
  letter-spacing: 0;
}

.section-title {
  font-weight: 600;
}

.circle-item {
  font-weight: 500;
}

.product-card {
  font-family: "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", Inter, system-ui, sans-serif;
}

.badge {
  font-weight: 700;
}

.card-title h3 {
  font-weight: 700;
}

.product-grid-compact .card-title h3 {
  color: #111f1a;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.42;
}

.price {
  font-weight: 800;
}

.product-grid-compact .price {
  color: #007b65;
  font-size: 14px;
  line-height: 1.1;
}

.tag {
  font-weight: 500;
}

.product-grid-compact .tag {
  padding: 4px 7px;
  border-color: #dce8df;
  color: #50625a;
  font-size: 12px;
}

.product-grid-compact .muted {
  color: #65746d;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
}

.product-grid-compact .primary-btn {
  display: inline-grid;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0;
}

.product-grid-compact .icon-btn {
  display: inline-grid;
  place-items: center;
  border-color: #dce8df;
  border-radius: 7px;
  font-size: 15px;
  font-weight: 700;
}
