:root {
  --canvas: #fff8f4;
  --surface: #fffdfb;
  --blush: #f4c0ca;
  --rose: #ef8fa4;
  --rose-deep: #dd7089;
  --champagne: #d8b07b;
  --champagne-soft: #ecd4a6;
  --cocoa: #3c2c2f;
  --ink: #6d5b5d;
  --line: #efdfd7;
  --line-strong: #e7d4ca;
  --shell: 100%;
  --transition: 180ms ease;
}

.placeholder-article-grid,
.main-product-grid {
  display: grid;
  gap: 24px;
}

.placeholder-article {
  display: grid;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.placeholder-article img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.placeholder-article h3,
.main-product-copy h1,
.main-cart-section h1 {
  margin: 0;
  font-family: "Playfair Display", serif;
  color: var(--cocoa);
}

.placeholder-article p,
.main-product-description,
.cart-properties {
  line-height: 1.7;
}

.main-product-media img {
  width: 100%;
  border-radius: 0;
  background: var(--surface);
}

.main-product-copy {
  display: grid;
  align-content: start;
  gap: 18px;
}

.main-product-price {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--cocoa);
}

.main-cart-section {
  max-width: 980px;
}

.main-cart-empty,
.main-cart-form {
  border: 1px solid rgba(231, 212, 202, 0.92);
  border-radius: 18px;
  background: rgba(255, 253, 251, 0.78);
  box-shadow: 0 18px 44px rgba(60, 44, 47, 0.06);
}

.main-cart-empty {
  display: grid;
  justify-items: start;
  gap: 14px;
  padding: 22px;
}

.main-cart-items {
  display: grid;
}

.main-cart-item {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
  border-bottom: 1px solid rgba(239, 223, 215, 0.82);
}

.main-cart-media {
  width: 74px;
  height: 74px;
  overflow: hidden;
  border: 1px solid rgba(239, 223, 215, 0.92);
  border-radius: 14px;
  background: rgba(247, 241, 238, 0.86);
}

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

.main-cart-copy {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.main-cart-line-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
}

.main-cart-item h3 {
  margin: 0;
  color: var(--cocoa);
  font-size: 0.94rem;
  line-height: 1.25;
}

.main-cart-variant {
  margin: 4px 0 0;
  color: rgba(109, 91, 93, 0.7);
  font-size: 0.76rem;
}

.main-cart-line-price {
  color: var(--cocoa);
  font-size: 0.94rem;
  white-space: nowrap;
}

.main-cart-line-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
}

.main-cart-line-controls label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: rgba(109, 91, 93, 0.72);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.main-cart-item input {
  width: 58px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  padding: 6px 8px;
  background: var(--surface);
  color: var(--cocoa);
  font-size: 0.78rem;
  font-weight: 800;
  text-align: center;
}

.main-cart-remove {
  color: rgba(109, 91, 93, 0.72);
  font-size: 0.76rem;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cart-properties-details {
  width: 100%;
}

.cart-properties-details summary {
  width: fit-content;
  cursor: pointer;
  color: #b96278;
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.cart-properties {
  margin: 8px 0 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(247, 241, 238, 0.78);
  font-size: 0.74rem;
  line-height: 1.45;
}

.cart-properties div {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: 10px;
  padding: 4px 0;
}

.cart-properties dt {
  color: rgba(60, 44, 47, 0.78);
  font-weight: 900;
}

.cart-properties dd {
  min-width: 0;
  max-height: 4.2em;
  margin: 0;
  overflow: hidden;
  color: rgba(109, 91, 93, 0.82);
  overflow-wrap: anywhere;
}

.main-cart-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px 18px;
  align-items: center;
  padding: 16px 14px 14px;
}

.main-cart-summary span {
  color: rgba(109, 91, 93, 0.72);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.main-cart-summary strong {
  color: var(--cocoa);
  font-size: 1.18rem;
  line-height: 1;
}

.main-cart-summary-actions {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1fr);
  gap: 10px;
}

.main-cart-summary-actions .button {
  min-height: 42px;
  padding: 10px 16px;
  border-radius: 16px;
  font-size: 0.78rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  overflow-x: hidden;
  background:
    radial-gradient(circle at 18% 0, rgba(255, 255, 255, 0.92) 0, rgba(255, 255, 255, 0) 28%),
    linear-gradient(180deg, #fffaf7 0%, #fff6f1 42%, #fffaf7 100%);
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
  border: 0;
  background: transparent;
}

.shell {
  width: calc(100% - 48px);
  margin: 0 auto;
  max-width: 1360px;
}

/* ========== 移动端优先基础样式 (iPhone 375px-428px) ========== */
/* 顶部提示栏 */
.promo-bar {
  padding: 8px 16px;
  text-align: center;
  background: #e79eac;
  color: var(--surface);
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.4;
}

.promo-bar p {
  margin: 0;
  font-weight: 400;
}

/* 头部 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 120;
  isolation: isolate;
  background: rgba(255, 253, 251, 0.95);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(239, 223, 215, 0.95);
}

.header-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  grid-template-areas:
    "brand actions menu"
    "nav nav nav";
  align-items: center;
  gap: 8px 10px;
  padding: 10px 0;
  min-height: 56px;
}

.brand {
  grid-area: brand;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.brand-logo {
  display: block;
  width: clamp(150px, 44vw, 190px);
  height: auto;
}

.brand-wordmark {
  font-family: "Playfair Display", serif;
  font-size: 1.34rem;
  font-weight: 500;
  letter-spacing: -0.05em;
  color: var(--cocoa);
  line-height: 1;
}

.brand-tag {
  font-size: 0.44rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: rgba(109, 91, 93, 0.78);
}

/* 移动端导航 - 隐藏，菜单按钮显示 */
.menu-toggle {
  grid-area: menu;
  display: flex;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--line);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  flex-shrink: 0;
}

.menu-toggle span {
  width: 16px;
  height: 1.5px;
  background: var(--cocoa);
}

/* 导航菜单 - 默认隐藏 */
.site-nav {
  grid-area: nav;
  display: none;
  width: 100%;
  flex-direction: column;
  gap: 0;
  padding: 12px 0 8px;
  border-top: 1px solid var(--line);
}

.site-nav.is-open {
  display: flex;
}

.site-nav a {
  display: block;
  padding: 12px 0;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cocoa);
  transition: color var(--transition);
}

.site-nav a.is-current,
.site-nav a:hover {
  color: var(--rose);
}

.header-actions {
  grid-area: actions;
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 4px;
  flex-wrap: nowrap;
  min-width: 0;
}

.language-switch {
  display: flex;
  padding: 1px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  flex-shrink: 0;
}

.language-option {
  min-width: 34px;
  height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  color: var(--cocoa);
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: all var(--transition);
}

.language-option.is-active {
  background: linear-gradient(180deg, #f6a3b5 0%, #eb829b 100%);
  color: var(--surface);
}

.icon-button {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  flex-shrink: 0;
}

.icon-button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: var(--cocoa);
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bag-count {
  position: absolute;
  right: 2px;
  top: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--rose);
  color: var(--surface);
  font-size: 0.6rem;
  font-weight: 800;
}

/* 横幅区域 */
.hero {
  position: relative;
  padding: 0;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 1px;
  background: var(--line);
}

.hero-carousel {
  position: relative;
  width: 100%;
  min-height: 420px;
  aspect-ratio: auto;
  overflow: hidden;
  background: #f6ebe4;
}

.hero-slides {
  position: absolute;
  inset: 0;
}

.hero-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  opacity: 0;
  transition: opacity 520ms ease;
}

.hero-slide.is-active {
  opacity: 1;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: flex-end;
}

.hero-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(255, 251, 247, 1) 0%,
    rgba(255, 251, 247, 0.9) 25%,
    rgba(255, 251, 247, 0.4) 50%,
    rgba(255, 251, 247, 0) 70%
  );
}

.hero-copy-shell {
  position: relative;
  z-index: 1;
  width: 100%;
}

.hero-copy {
  padding: 0 20px 24px;
  max-width: 100%;
  width: 100%;
}

.eyebrow {
  margin: 0 0 10px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--rose);
}

.hero-copy h1,
.section-heading h2,
.gift-copy h2 {
  margin: 0;
  font-family: "Playfair Display", serif;
  color: var(--cocoa);
  letter-spacing: -0.03em;
}

.hero-copy h1 {
  font-size: 2.2rem;
  line-height: 1.05;
}

.hero-title-main {
  display: block;
}

.hero-title-accent {
  display: block;
  margin-top: 2px;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-weight: 500;
  font-size: 1.9rem;
  color: var(--rose);
  letter-spacing: -0.02em;
}

.hero-text {
  margin: 12px 0 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--ink);
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 18px;
}

.button {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: all var(--transition);
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: var(--surface);
  background: linear-gradient(180deg, #f091a7 0%, #e77992 100%);
}

.button-secondary {
  color: var(--cocoa);
  background: transparent;
  border: 1px solid var(--line-strong);
}

.button-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cocoa);
}

.button-link::after {
  content: "→";
  color: var(--rose);
}

.hero-seal {
  position: absolute;
  right: 16px;
  top: 50%;
  bottom: auto;
  left: auto;
  transform: translateY(-50%);
  z-index: 3;
  width: 70px;
  height: 70px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--cocoa);
  text-align: center;
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-seal span:last-child {
  font-family:"Cormorant Garamond", serif;
  font-style: italic;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: none;
}

.hero-indicators {
  position: absolute;
  left: 16px;
  bottom: 16px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-indicator {
  width: 24px;
  height: 3px;
  padding: 0;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 2px;
  transition: all var(--transition);
}

.hero-indicator.is-active {
  background: rgba(255, 255, 255, 0.95);
}

/* 信任条 */
.trust-strip {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  background: rgba(255, 252, 249, 0.9);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.trust-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 18px 16px;
}

.trust-item:nth-child(odd) {
  border-right: 1px solid var(--line);
}

.trust-item:nth-child(3),
.trust-item:nth-child(4) {
  border-top: 1px solid var(--line);
}

.trust-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(239, 143, 164, 0.4);
  color: var(--rose);
  font-size: 0.7rem;
  font-weight: 800;
}

.trust-item h2 {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--cocoa);
  line-height: 1.3;
}

.trust-item p {
  margin: 4px 0 0;
  font-size: 0.78rem;
  line-height: 1.5;
}

/* 内容区块 */
.section {
  padding: 56px 0 0;
}

.section-heading {
  max-width: 100%;
}

.section-heading h2 {
  font-size: 1.8rem;
  line-height: 1.15;
}

.section-heading p:last-child {
  margin: 12px 0 0;
  font-size: 0.9rem;
  line-height: 1.65;
}

.doc-page {
  display: grid;
  gap: 28px;
  max-width: 1180px;
}

.doc-hero {
  position: relative;
  display: grid;
  gap: 14px;
  padding: clamp(28px, 5vw, 56px);
  border: 1px solid rgba(231, 212, 202, 0.92);
  border-radius: 18px;
  background:
    radial-gradient(circle at 82% 12%, rgba(239, 143, 164, 0.14), transparent 32%),
    linear-gradient(135deg, rgba(255, 253, 251, 0.92), rgba(255, 248, 244, 0.72));
  box-shadow: 0 24px 60px rgba(120, 88, 82, 0.08);
  overflow: hidden;
}

.doc-hero::after {
  content: "";
  position: absolute;
  right: -54px;
  bottom: -70px;
  width: 180px;
  height: 180px;
  border: 1px solid rgba(216, 176, 123, 0.34);
  border-radius: 50%;
  pointer-events: none;
}

.doc-hero h1,
.doc-story-card h2,
.doc-story-card h3,
.doc-column h2,
.faq-group h2,
.faq-group h3 {
  margin: 0;
  font-family: "Playfair Display", serif;
  color: var(--cocoa);
  line-height: 1.08;
}

.doc-hero h1 {
  max-width: 760px;
  font-size: clamp(2.5rem, 7vw, 5.8rem);
  letter-spacing: -0.05em;
}

.doc-hero p:last-child {
  max-width: 720px;
  margin: 0;
  color: var(--ink);
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  line-height: 1.75;
}

.doc-story-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.7fr);
  gap: 22px;
}

.doc-story-card,
.doc-founder-note,
.doc-column,
.faq-index,
.faq-group {
  border: 1px solid rgba(231, 212, 202, 0.9);
  border-radius: 16px;
  background: rgba(255, 253, 251, 0.78);
  box-shadow: 0 18px 44px rgba(60, 44, 47, 0.055);
}

.doc-story-card {
  padding: clamp(24px, 4vw, 42px);
}

.doc-card-kicker,
.doc-founder-note span {
  color: var(--rose);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.doc-story-card h2,
.doc-story-card h3,
.doc-column h2 {
  margin-top: 12px;
  font-size: clamp(1.7rem, 3vw, 3rem);
}

.doc-story-card p,
.doc-founder-note p,
.doc-column p,
.faq-group p {
  color: var(--ink);
  line-height: 1.72;
}

.doc-founder-note {
  display: grid;
  align-content: center;
  gap: 18px;
  padding: clamp(22px, 3vw, 34px);
  background:
    linear-gradient(180deg, rgba(255, 246, 248, 0.88), rgba(255, 253, 251, 0.72));
}

.doc-founder-note blockquote {
  margin: 0;
  font-family: "Playfair Display", serif;
  color: var(--cocoa);
  font-size: clamp(1.45rem, 2.4vw, 2.3rem);
  line-height: 1.18;
}

.doc-founder-note p {
  margin: 0;
}

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

.doc-column {
  display: grid;
  gap: 18px;
  padding: clamp(22px, 3vw, 34px);
}

.doc-column article {
  padding-top: 16px;
  border-top: 1px solid rgba(231, 212, 202, 0.78);
}

.doc-column h3 {
  margin: 0 0 6px;
  color: var(--cocoa);
  font-size: 1rem;
}

.doc-column p {
  margin: 0;
}

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

.faq-index {
  position: sticky;
  top: 110px;
  display: grid;
  gap: 8px;
  padding: 16px;
}

.faq-index a {
  padding: 10px 12px;
  border-radius: 999px;
  color: var(--cocoa);
  font-size: 0.84rem;
  font-weight: 800;
  background: rgba(255, 248, 244, 0.72);
}

.faq-groups {
  display: grid;
  gap: 18px;
}

.faq-group {
  padding: clamp(20px, 3vw, 32px);
  scroll-margin-top: 120px;
}

.faq-group h2 {
  margin-bottom: 16px;
  font-size: clamp(1.45rem, 2.4vw, 2.3rem);
}

.faq-group h3 {
  margin-bottom: 16px;
  font-size: clamp(1.35rem, 2vw, 2rem);
}

.faq-group details {
  border-top: 1px solid rgba(231, 212, 202, 0.82);
  padding: 0;
}

.faq-group summary {
  cursor: pointer;
  list-style: none;
  padding: 16px 34px 16px 0;
  color: var(--cocoa);
  font-weight: 800;
  line-height: 1.35;
  position: relative;
}

.faq-group summary::-webkit-details-marker {
  display: none;
}

.faq-group summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 50%;
  color: var(--rose-deep);
  font-size: 1.2rem;
  transform: translateY(-50%);
}

.faq-group details[open] summary::after {
  content: "-";
}

.faq-group p {
  margin: -4px 0 16px;
  max-width: 760px;
}

.home-about-section,
.home-faq-section {
  padding-top: 56px;
}

.home-about-section::before,
.home-faq-section::before {
  content: "";
  display: block;
  width: calc(100% - 48px);
  margin: 0 auto 40px;
  border-top: 1px solid var(--line);
}

.home-about-layout,
.home-faq-grid {
  display: grid;
  gap: 22px;
  margin-top: 24px;
}

.home-about-layout {
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.72fr);
}

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

@media (max-width: 767px) {
  .doc-page {
    gap: 18px;
  }

  .doc-story-grid,
  .doc-columns,
  .faq-layout,
  .home-about-layout,
  .home-faq-grid {
    grid-template-columns: 1fr;
  }

  .doc-hero {
    padding: 24px 18px;
    border-radius: 16px;
  }

  .doc-story-card,
  .doc-founder-note,
  .doc-column,
  .faq-group {
    padding: 20px 16px;
    border-radius: 14px;
  }

  .faq-index {
    position: static;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 10px;
    border-radius: 14px;
    scrollbar-width: none;
  }

  .faq-index::-webkit-scrollbar {
    display: none;
  }

  .faq-index a {
    flex: 0 0 auto;
    white-space: nowrap;
  }
}

/* 步骤区域 */
.steps-section {
  position: relative;
}

.steps-layout {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 20px;
}

.steps-grid {
  display: flex;
  gap: 16px;
}

.step-card {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 16px 8px;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.step-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  margin-bottom: 10px;
  background: linear-gradient(180deg, #f2a8b9 0%, #ea8ea5 100%);
  color: var(--surface);
  font-weight: 800;
  font-size: 0.8rem;
}

.step-card h3 {
  margin: 0 0 4px;
  font-family: "Playfair Display", serif;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--cocoa);
}

.step-card p {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--ink);
}

.steps-visual {
  display: none;
}

.steps-visual img {
  width: 80%;
  max-width: 280px;
  height: auto;
}

.steps-badge {
  width: 100px;
  height: 100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px;
  border-radius: 50%;
  background: linear-gradient(180deg, #f6a8b7 0%, #ee91a8 100%);
  color: var(--surface);
  text-align: center;
}

.steps-badge strong {
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1;
}

.steps-badge span {
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 4px;
  line-height: 1.3;
}

/* 定制器区域 */
.builder-section {
  position: relative;
  padding-top: 56px;
}

.builder-section::before {
  content: "";
  display: block;
  width: calc(100% - 48px);
  margin: 0 auto 56px;
  border-top: 1px solid var(--line);
}

.builder-shell {
  padding-top: 0;
}

.builder-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 24px;
}

.builder-controls {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.option-group {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}

.option-group:first-child {
  padding-top: 0;
  border-top: 0;
}

.option-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.option-header h3 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--cocoa);
}

.option-header span {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--rose);
}

.chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.66);
  color: var(--cocoa);
  font-size: 0.85rem;
  font-weight: 700;
  transition: all var(--transition);
}

.chip:hover,
.chip:focus-visible {
  border-color: rgba(239, 143, 164, 0.72);
}

.chip.is-active {
  background: linear-gradient(180deg, rgba(249, 220, 227, 0.94) 0%, rgba(255, 249, 250, 0.98) 100%);
  border-color: rgba(239, 143, 164, 0.9);
}

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

.chip-grid--charms .chip {
  min-width: 0;
  text-align: center;
}

.helper-text {
  margin: 12px 0 0;
  font-size: 0.82rem;
  color: var(--ink);
}

/* 预览卡片 */
.builder-preview-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.preview-stage {
  --tone: linear-gradient(135deg, #f0c6cf 0%, #d797a6 100%);
  position: relative;
  min-height: 280px;
  border-radius: 16px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 38%, rgba(255, 255, 255, 0.72) 0, rgba(255, 255, 255, 0) 26%),
    linear-gradient(180deg, #fdf5ef 0%, #f8e7e0 100%);
}

.preview-halo {
  position: absolute;
  inset: 20%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.74) 0%, rgba(255, 255, 255, 0) 70%);
}

.preview-chain {
  position: absolute;
  left: 15%;
  right: 15%;
  top: 25%;
  bottom: 25%;
  border-radius: 999px;
  border: 10px solid transparent;
  background:
    linear-gradient(#f7ebe8, #f7ebe8) padding-box,
    var(--tone) border-box;
}

.chain-cable {
  border-width: 8px;
}

.chain-bead {
  border-width: 14px;
  border-style: dotted;
}

.chain-rope {
  border-width: 12px;
}

.preview-charm {
  position: absolute;
  top: 50%;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--cocoa);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transform: translateY(-50%);
}

.preview-charm--one {
  left: 12%;
}

.preview-charm--two {
  left: 42%;
}

.preview-charm--three {
  right: 12%;
}

.preview-tag {
  position: absolute;
  left: 16px;
  bottom: 12px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cocoa);
}

.finish-rose {
  --tone: linear-gradient(135deg, #f6cad2 0%, #d992a3 100%);
}

.finish-gold {
  --tone: linear-gradient(135deg, #f4deb1 0%, #d2ad75 100%);
}

.finish-silver {
  --tone: linear-gradient(135deg, #eef1f5 0%, #aab3bf 100%);
}

/* 摘要区域 */
.builder-summary {
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.summary-header {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.summary-label {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--rose);
}

.summary-header h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--cocoa);
}

.summary-header strong {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--cocoa);
}

.summary-list {
  margin: 16px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.summary-list > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.summary-list dt {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(109, 91, 93, 0.6);
}

.summary-list dd {
  margin: 0;
  font-size: 0.88rem;
  color: var(--cocoa);
  word-break: break-word;
}

.summary-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 18px;
}

/* 收藏区域 */
.collections-section {
  padding-top: 56px;
}

.collections-section::before {
  content: "";
  display: block;
  width: calc(100% - 48px);
  margin: 0 auto 40px;
  border-top: 1px solid var(--line);
}

.section-heading--inline {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.collection-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 24px;
}

.collection-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  padding: 14px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 254, 252, 0.98) 0%, rgba(255, 248, 244, 0.96) 100%);
  box-shadow: 0 18px 36px rgba(211, 176, 157, 0.09);
  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.collection-card:hover,
.collection-card:focus-within {
  transform: translateY(-2px);
  border-color: rgba(239, 143, 164, 0.62);
  box-shadow: 0 22px 42px rgba(211, 176, 157, 0.13);
}

.collection-media {
  display: block;
  aspect-ratio: 1 / 1;
  border-radius: 18px;
  overflow: hidden;
  background: #f6ebe4;
}

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

.collection-copy {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 8px;
  padding: 18px 6px 6px;
}

.collection-kicker {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--rose);
}

.collection-copy h3 {
  margin: 0;
  font-family: "Playfair Display", serif;
  font-size: 1.18rem;
  font-weight: 500;
  color: var(--cocoa);
}

.collection-copy p {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.6;
  color: rgba(105, 88, 90, 0.88);
}

.collection-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 14px;
}

.collection-meta span {
  font-size: 1rem;
  font-weight: 800;
  color: var(--cocoa);
}

.collection-meta a {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--rose);
}

.collection-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.collection-action-button {
  min-height: 46px;
  padding: 0 14px;
  border-radius: 999px;
  justify-content: center;
  text-transform: none;
  letter-spacing: 0.04em;
  box-shadow: none;
}

.collection-action-button[disabled] {
  opacity: 0.42;
  cursor: not-allowed;
}

.collection-status {
  min-height: 1.3em;
  margin-top: 10px;
  font-size: 0.74rem;
  color: rgba(109, 91, 93, 0.74);
}

@media (max-width: 767px) {
  .collections-section {
    overflow: hidden;
  }

  .collections-section .section-heading {
    margin-bottom: 0;
  }

  .collection-grid {
    grid-auto-columns: clamp(84px, calc((100vw - 64px) / 3), 112px);
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-template-rows: repeat(2, auto);
    gap: 8px;
    margin-top: 18px;
    padding: 0 0 10px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .collection-grid::-webkit-scrollbar {
    display: none;
  }

  .collection-card {
    min-width: 0;
    min-height: 0;
    padding: 7px;
    border-radius: 14px;
    box-shadow: 0 10px 20px rgba(211, 176, 157, 0.08);
    scroll-snap-align: start;
  }

  .collection-card:hover,
  .collection-card:focus-within {
    transform: none;
  }

  .collection-media {
    border-radius: 10px;
  }

  .collection-copy {
    gap: 5px;
    padding: 8px 2px 2px;
  }

  .collection-kicker,
  .collection-copy > p:not(.collection-kicker),
  .collection-actions,
  .collection-status {
    display: none;
  }

  .collection-copy h3 {
    display: -webkit-box;
    min-height: 2.5em;
    overflow: hidden;
    font-size: 0.72rem;
    line-height: 1.25;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .collection-meta {
    gap: 4px;
    align-items: flex-end;
    padding-top: 4px;
  }

  .collection-meta span {
    font-size: 0.74rem;
  }

  .collection-meta a {
    max-width: 52px;
    overflow: hidden;
    font-size: 0.56rem;
    letter-spacing: 0.04em;
    line-height: 1.1;
    text-align: right;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* 评价区域 */
.testimonials-section {
  padding-top: 56px;
}

.testimonials-section::before {
  content: "";
  display: block;
  width: calc(100% - 48px);
  margin: 0 auto 40px;
  border-top: 1px solid var(--line);
}

.gift-panel {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.gift-copy h2 {
  font-size: 1.7rem;
  line-height: 1.15;
}

.gift-copy p {
  margin: 12px 0 0;
  font-size: 0.9rem;
  line-height: 1.6;
}

.gift-copy .button {
  margin-top: 20px;
  width: 100%;
}

.gift-points {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.gift-points article {
  padding-left: 16px;
  border-left: 2px solid var(--line);
}

.gift-points strong {
  color: var(--cocoa);
  font-size: 0.92rem;
  font-weight: 700;
}

.gift-points p {
  margin: 4px 0 0;
  font-size: 0.85rem;
  line-height: 1.5;
}

.testimonial-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: 36px;
  border-top: 1px solid var(--line);
}

.testimonial-card {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}

.testimonial-card:last-child {
  border-bottom: none;
}

.testimonial-card p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.6;
}

.testimonial-card span {
  display: block;
  margin-top: 12px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rose);
}

/* 页脚 */
.site-footer {
  padding: 48px 0 36px;
  margin-top: 56px;
}

.footer-grid {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.brand--footer .brand-logo {
  width: clamp(180px, 54vw, 230px);
}

.brand--footer {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.theme-version-badge {
  flex: 0 0 auto;
  margin-top: 2px;
  padding: 4px 8px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  color: rgba(109, 91, 93, 0.72);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1;
}

.footer-copy {
  margin: 10px 0 0;
  font-size: 0.88rem;
  line-height: 1.6;
  max-width: 100%;
}

.footer-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.footer-links h3 {
  margin: 0 0 8px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--cocoa);
}

.footer-links a {
  display: block;
  margin-top: 6px;
  font-size: 0.85rem;
  color: var(--ink);
}

.newsletter-panel label {
  display: block;
  margin-bottom: 12px;
  font-size: 0.88rem;
  color: var(--cocoa);
  line-height: 1.6;
}

.newsletter-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.newsletter-row input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--cocoa);
  font-size: 0.9rem;
}

.newsletter-row .button {
  width: 100%;
}

/* ========== 平板适配 (768px+) ========== */
@media (min-width: 768px) {
  .shell {
    width: calc(100% - 64px);
  }

  .promo-bar {
    font-size: 0.7rem;
    font-weight: 400;
  }

  .header-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    grid-template-areas: "brand nav actions";
    gap: 20px;
    padding: 16px 0;
    min-height: 72px;
  }

  .brand-logo {
    width: 210px;
  }

  .brand-tag {
    font-size: 0.55rem;
    letter-spacing: 0.25em;
  }

  .menu-toggle {
    display: none;
  }

  .site-nav {
    display: flex;
    flex-direction: row;
    justify-content: center;
    width: auto;
    padding: 0;
    border-top: none;
  }

  .site-nav a {
    padding: 8px 16px;
    font-size: 0.82rem;
  }

  .language-option {
    min-width: 48px;
    height: 32px;
    padding: 0 12px;
    font-size: 0.72rem;
  }

  .icon-button {
    width: 40px;
    height: 40px;
  }

  .hero {
    padding: 0;
  }

  .hero-carousel {
    min-height: 420px;
    aspect-ratio: 16 / 9;
  }

  .hero-overlay {
    align-items: center;
  }

  .hero-mask {
    background: linear-gradient(
      90deg,
      rgba(255, 251, 247, 0.98) 0%,
      rgba(255, 251, 247, 0.95) 34%,
      rgba(255, 251, 247, 0.84) 54%,
      rgba(255, 251, 247, 0.56) 74%,
      rgba(255, 251, 247, 0) 100%
    );
  }

  .hero-copy {
    max-width: 480px;
    padding: 0 0 0 24px;
  }

  .hero-copy h1 {
    font-size: 2.6rem;
  }

  .hero-title-accent {
    font-size: 2.2rem;
  }

  .hero-text {
    max-width: 380px;
    font-size: 0.95rem;
  }

  .hero-actions {
    flex-direction: row;
    gap: 14px;
  }

  .button {
    min-width: auto;
  }

  .hero-seal {
    width: 100px;
    height: 100px;
    right: 40px;
    bottom: 40px;
    font-size: 0.7rem;
  }

  .hero-seal span:last-child {
    font-size: 0.95rem;
  }

  .hero-indicators {
    right: auto;
    left: 50%;
    transform: translateX(-50%);
    bottom: 24px;
  }

  .trust-strip {
    grid-template-columns: repeat(4, 1fr);
  }

  .trust-item {
    padding: 24px 20px;
  }

  .trust-item:nth-child(3),
  .trust-item:nth-child(4) {
    border-top: none;
  }

  .trust-item:nth-child(3) {
    border-left: 1px solid var(--line);
  }

  .trust-item:nth-child(odd) {
    border-right: none;
  }

  .trust-icon {
    width: 48px;
    height: 48px;
    font-size: 0.78rem;
  }

  .trust-item h2 {
    font-size: 0.95rem;
  }

  .section {
    padding: 72px 0 0;
  }

  .section-heading h2 {
    font-size: 2.2rem;
  }

  .steps-layout {
    flex-direction: row;
    gap: 24px;
    margin-top: 24px;
  }

  .steps-grid {
    flex: 1;
    gap: 16px;
  }

  .step-card {
    flex: 1;
    padding: 16px 12px;
    text-align: center;
    align-items: center;
  }

  .step-card h3 {
    font-size: 1.1rem;
  }

  .steps-visual {
    display: none;
  }

  .builder-section {
    padding-top: 72px;
  }

  .builder-section::before {
    margin-bottom: 48px;
  }

  .builder-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    margin-top: 32px;
  }

  .option-group {
    padding: 24px 0;
  }

  .option-header {
    flex-direction: row;
    justify-content: space-between;
    align-items: baseline;
  }

  .chip {
    font-size: 0.88rem;
  }

  .chip-grid--charms {
    display: flex;
    flex-wrap: wrap;
    grid-template-columns: repeat(3, 1fr);
  }

  .preview-stage {
    min-height: 340px;
    border-radius: 20px;
  }

  .preview-chain {
    border-width: 12px;
  }

  .preview-charm {
    width: 64px;
    height: 64px;
    font-size: 0.78rem;
    border-radius: 16px;
  }

  .summary-header {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }

  .summary-header strong {
    font-size: 1.6rem;
  }

  .summary-actions {
    flex-direction: row;
  }

  .collections-section {
    padding-top: 72px;
  }

  .collections-section::before {
    margin-bottom: 48px;
  }

  .collection-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 28px;
  }

  .collection-card {
    padding: 16px;
  }

  .collection-copy {
    padding: 20px 8px 8px;
  }

  .collection-meta {
    padding-top: 16px;
  }

  .collection-actions {
    gap: 12px;
    margin-top: 14px;
  }

  .collection-action-button {
    min-height: 48px;
  }

  .testimonials-section {
    padding-top: 72px;
  }

  .testimonials-section::before {
    margin-bottom: 48px;
  }

  .gift-panel {
    flex-direction: row;
    gap: 40px;
  }

  .gift-copy {
    flex: 1;
  }

  .gift-copy h2 {
    font-size: 2rem;
  }

  .gift-points {
    flex: 1;
    gap: 20px;
  }

  .gift-points article {
    padding-left: 20px;
  }

  .testimonial-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin-top: 36px;
  }

  .testimonial-card {
    padding: 0 24px 0 0;
    border-bottom: none;
    border-right: 1px solid var(--line);
  }

  .testimonial-card:last-child {
    border-right: none;
    padding-right: 0;
  }

  .site-footer {
    padding: 64px 0 40px;
    margin-top: 72px;
  }

  .footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1.2fr;
    gap: 32px;
    padding-top: 32px;
  }

  .footer-copy {
    max-width: 320px;
  }

  .newsletter-row {
    flex-direction: row;
  }

  .newsletter-row input {
    width: auto;
    flex: 1;
  }

  .newsletter-row .button {
    width: auto;
  }
}

/* ========== 桌面适配 (1024px+) ========== */
@media (min-width: 1024px) {
  .shell {
    width: calc(100% - 80px);
    max-width: 1360px;
  }

  .header-row {
    gap: 32px;
    min-height: 80px;
  }

  .brand-logo {
    width: 236px;
  }

  .brand-tag {
    letter-spacing: 0.3em;
  }

  .site-nav {
    gap: 16px 28px;
  }

  .site-nav a {
    font-size: 0.85rem;
  }

  .hero {
    padding: 0;
  }

  .hero-carousel {
    min-height: 480px;
    aspect-ratio: 3 / 1;
  }

  .hero-mask {
    width: min(50%, 700px);
  }

  .hero-copy {
    max-width: 520px;
    padding: 0 0 0 32px;
  }

  .hero-copy h1 {
    font-size: 3rem;
  }

  .hero-title-accent {
    font-size: 2.5rem;
  }

  .hero-text {
    max-width: 420px;
    font-size: 1rem;
    line-height: 1.7;
  }

  .hero-actions {
    gap: 16px;
    margin-top: 24px;
  }

  .button {
    padding: 0 28px;
    font-size: 0.88rem;
  }

  .hero-seal {
    width: 110px;
    height: 110px;
    right: 48px;
    bottom: 32px;
    font-size: 0.72rem;
  }

  .hero-seal span:last-child {
    font-size: 1rem;
  }

  .hero-indicators {
    right: 200px;
    left: auto;
    transform: none;
    bottom: 32px;
  }

  .trust-item {
    padding: 28px 24px;
  }

  .section {
    padding: 88px 0 0;
  }

  .section-heading h2 {
    font-size: 2.5rem;
  }

  .section-heading p:last-child {
    margin-top: 16px;
  }

  .steps-layout {
    gap: 32px;
    margin-top: 28px;
  }

  .step-card {
    padding: 20px 16px;
  }

  .step-card h3 {
    font-size: 1.2rem;
  }

  .step-card p {
    font-size: 0.88rem;
  }

  .step-number {
    width: 36px;
    height: 36px;
    margin-bottom: 12px;
  }

  .steps-visual {
    flex: 0 0 340px;
  }

  .steps-badge {
    width: 130px;
    height: 130px;
    padding: 16px;
  }

  .steps-badge strong {
    font-size: 2rem;
  }

  .steps-badge span {
    font-size: 0.72rem;
  }

  .builder-section {
    padding-top: 88px;
  }

  .builder-section::before {
    margin-bottom: 64px;
  }

  .builder-grid {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    margin-top: 40px;
  }

  .option-group {
    padding: 28px 0;
  }

  .option-header h3 {
    font-size: 1.05rem;
  }

  .chip {
    min-height: 44px;
    padding: 0 18px;
    font-size: 0.9rem;
  }

  .preview-stage {
    min-height: 400px;
    border-radius: 24px;
  }

  .preview-chain {
    left: 14%;
    right: 14%;
    top: 20%;
    bottom: 20%;
    border-width: 14px;
  }

  .chain-cable {
    border-width: 10px;
  }

  .chain-bead {
    border-width: 18px;
  }

  .chain-rope {
    border-width: 16px;
  }

  .preview-charm {
    width: 70px;
    height: 70px;
    font-size: 0.85rem;
    border-radius: 18px;
  }

  .preview-charm--one {
    left: 16%;
  }

  .preview-charm--two {
    left: 43%;
  }

  .preview-charm--three {
    right: 16%;
  }

  .preview-halo {
    inset: 18%;
  }

  .preview-tag {
    font-size: 0.72rem;
  }

  .summary-header h3 {
    font-size: 1.1rem;
  }

  .summary-header strong {
    font-size: 1.8rem;
  }

  .summary-list {
    margin-top: 22px;
    gap: 14px;
  }

  .summary-actions {
    margin-top: 22px;
    gap: 14px;
  }

  .collections-section {
    padding-top: 88px;
  }

  .collections-section::before {
    margin-bottom: 64px;
  }

  .collection-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 36px;
    gap: 24px;
  }

  .collection-card {
    padding: 18px;
  }

  .collection-copy {
    padding: 22px 10px 10px;
  }

  .collection-copy h3 {
    font-size: 1.32rem;
  }

  .collection-copy p {
    font-size: 0.9rem;
  }

  .collection-meta {
    margin-top: 20px;
    padding-top: 18px;
  }

  .collection-meta span {
    font-size: 1.1rem;
  }

  .collection-action-button {
    min-height: 50px;
  }

  .testimonials-section {
    padding-top: 88px;
  }

  .testimonials-section::before {
    margin-bottom: 64px;
  }

  .gift-panel {
    gap: 48px;
  }

  .gift-copy h2 {
    font-size: 2.2rem;
  }

  .gift-points {
    gap: 22px;
  }

  .gift-points strong {
    font-size: 0.98rem;
  }

  .testimonial-grid {
    margin-top: 40px;
  }

  .testimonial-card {
    padding: 24px 28px 0 0;
  }

  .testimonial-card p {
    font-size: 0.95rem;
  }

  .site-footer {
    padding: 80px 0 44px;
    margin-top: 88px;
  }

  .footer-grid {
    gap: 36px;
    padding-top: 36px;
  }

  .brand--footer .brand-logo {
    width: 260px;
  }

  .theme-version-badge {
    font-size: 0.68rem;
  }

  .footer-copy {
    font-size: 0.9rem;
    max-width: 360px;
  }

  .footer-links {
    gap: 28px;
  }
}

/* ========== 大屏适配 (1280px+) ========== */
@media (min-width: 1280px) {
  .hero-copy h1 {
    font-size: 3.4rem;
  }

  .hero-title-accent {
    font-size: 2.8rem;
  }

  .section-heading h2 {
    font-size: 2.8rem;
  }

  .gift-copy h2 {
    font-size: 2.4rem;
  }

  .section-heading--wide {
    max-width: 900px;
  }

  .section-heading--inline {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
  }

  .section-heading--inline .button-link {
    margin-top: 0;
  }
}

/* ========== 额外优化 ========== */

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
  .chip,
  .button,
  .language-option,
  .hero-indicator,
  .menu-toggle {
    -webkit-tap-highlight-color: transparent;
  }

  .site-nav a,
  .footer-links a {
    padding: 12px 0;
  }
}

/* 高对比度模式支持 */
@media (prefers-contrast: high) {
  .chip {
    border-width: 2px;
    border-color: var(--cocoa);
  }

  .chip.is-active {
    border-color: var(--rose-deep);
    background: var(--surface);
  }

  .button {
    border: 2px solid currentColor;
  }
}

/* 安全区域适配 - iPhone刘海屏 */
@supports (padding-top: env(safe-area-inset-top)) {
  .site-header {
    padding-top: env(safe-area-inset-top);
  }

  .promo-bar {
    padding-top: calc(10px + env(safe-area-inset-top));
  }
}

/* 减少动画 */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* Focus 可视化 */
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid var(--rose);
  outline-offset: 2px;
}

/* ========== DIY Builder Refresh ========== */
.diy-top {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 24px;
}

.diy-preview-card,
.diy-setting-card,
.diy-summary-card,
.diy-database-card {
  border: 1px solid rgba(231, 212, 202, 0.9);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 20px 40px rgba(211, 176, 157, 0.12);
}

.diy-preview-stage {
  position: relative;
  z-index: 0;
  isolation: isolate;
  min-height: 320px;
  border-radius: 24px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 36%, rgba(255, 255, 255, 0.92) 0, rgba(255, 255, 255, 0) 30%),
    linear-gradient(180deg, #fff9f5 0%, #f9ece5 100%);
}

.diy-preview-stage-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(239, 223, 215, 0.55) 1px, transparent 1px),
    linear-gradient(90deg, rgba(239, 223, 215, 0.55) 1px, transparent 1px);
  background-size: 36px 36px;
  opacity: 0.6;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0.8));
}

.diy-preview-rope {
  position: absolute;
  inset: 11%;
  width: 78%;
  height: 78%;
  margin: auto;
  object-fit: contain;
  filter: drop-shadow(0 16px 24px rgba(148, 118, 111, 0.16));
}

.diy-preview-items {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.diy-preview-item {
  position: absolute;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 12px 28px rgba(120, 88, 82, 0.14);
  backdrop-filter: blur(10px);
}

.diy-preview-item.is-insert-preview {
  opacity: 0.64;
  outline: 0;
  outline-offset: 0;
  background: transparent;
  box-shadow: none;
  pointer-events: none;
}

.diy-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.diy-preview-badge {
  position: absolute;
  left: 16px;
  top: 16px;
  max-width: calc(100% - 32px);
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--cocoa);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.diy-preview-metrics {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.diy-preview-metrics > div {
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(231, 212, 202, 0.92);
  background: rgba(255, 255, 255, 0.86);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.diy-preview-metrics span {
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(109, 91, 93, 0.68);
}

.diy-preview-metrics strong {
  font-size: 1rem;
  color: var(--cocoa);
}

.diy-preview-metrics .is-accent {
  background: linear-gradient(180deg, rgba(253, 241, 245, 0.96) 0%, rgba(255, 255, 255, 0.94) 100%);
}

.diy-preview-stage.is-overlimit .diy-preview-metrics .is-accent {
  border-color: rgba(204, 94, 94, 0.28);
  background: rgba(255, 240, 240, 0.96);
}

.diy-config-panel {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.diy-setting-card,
.diy-summary-card,
.diy-database-card {
  padding: 20px;
}

.diy-setting-header {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.diy-setting-header h3,
.diy-subheading h3 {
  margin: 0;
  font-family: "Playfair Display", serif;
  font-size: 1.42rem;
  line-height: 1.2;
  color: var(--cocoa);
}

.diy-length-field {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 18px;
}

.diy-length-label {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rose);
}

.diy-length-input-wrap {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  background: rgba(255, 255, 255, 0.92);
}

.diy-length-input-wrap input {
  width: 92px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--cocoa);
  font-size: 1.4rem;
  font-weight: 800;
}

.diy-length-input-wrap input:focus {
  outline: none;
}

.diy-length-hint,
.diy-matrix-caption,
.diy-selection-note {
  margin: 0;
  color: var(--ink);
  font-size: 0.88rem;
  line-height: 1.7;
}

.diy-selection-note {
  margin-top: 16px;
}

.diy-assembly-options {
  min-inline-size: 0;
  margin: 16px 0 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.diy-assembly-options legend {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
  padding: 0;
}

.diy-assembly-options legend span {
  color: var(--rose);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.diy-assembly-options legend strong {
  color: var(--cocoa);
  font-size: 0.98rem;
  line-height: 1.3;
}

.diy-assembly-options > p {
  margin: 8px 0 12px;
  color: rgba(109, 91, 93, 0.78);
  font-size: 0.76rem;
  line-height: 1.5;
}

.diy-assembly-option {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid rgba(231, 212, 202, 0.88);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.86);
  cursor: pointer;
}

.diy-assembly-option + .diy-assembly-option {
  margin-top: 8px;
}

.diy-assembly-option.is-selected {
  border-color: rgba(239, 143, 164, 0.78);
  background: rgba(255, 244, 248, 0.98);
  box-shadow: 0 10px 24px rgba(194, 108, 132, 0.1);
}

.diy-assembly-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.diy-assembly-radio {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border: 1.5px solid rgba(109, 91, 93, 0.34);
  border-radius: 999px;
  background: #fff;
}

.diy-assembly-option.is-selected .diy-assembly-radio {
  border-color: var(--rose);
  box-shadow: inset 0 0 0 4px #fff;
  background: var(--rose);
}

.diy-assembly-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.diy-assembly-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.diy-assembly-line strong {
  color: var(--cocoa);
  font-size: 0.84rem;
  line-height: 1.25;
}

.diy-assembly-line em {
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--rose);
  color: #fff;
  font-size: 0.62rem;
  font-style: normal;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.diy-assembly-copy small {
  color: rgba(109, 91, 93, 0.72);
  font-size: 0.72rem;
  line-height: 1.45;
}

.diy-mockup-note {
  margin-top: 10px;
}

.diy-mockup-panel {
  position: relative;
  margin-top: 12px;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 26px;
  background: rgba(255, 251, 248, 0.52);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.diy-mockup-loading {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  gap: 12px;
  background: rgba(255, 251, 248, 0.76);
  text-align: center;
}

.diy-mockup-loading[hidden],
.diy-mockup-image-button[hidden],
.diy-mockup-image[hidden],
.diy-share-result[hidden] {
  display: none !important;
}

.diy-mockup-status {
  margin: 0;
  padding-top: 44px;
  font-size: 0.78rem;
  font-weight: 700;
  color: rgba(109, 91, 93, 0.84);
}

.diy-mockup-image-button {
  position: relative;
  z-index: 3;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
  appearance: none;
  -webkit-appearance: none;
  opacity: 1;
  filter: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.diy-mockup-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 26px;
  box-shadow: none;
  opacity: 1 !important;
  filter: none !important;
}

.diy-mockup-panel[data-has-image="true"] {
  background: transparent !important;
  isolation: isolate;
  opacity: 1 !important;
  filter: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.diy-mockup-panel[data-has-image="true"] .diy-mockup-loading {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  background: transparent !important;
}

.diy-mockup-panel[data-has-image="true"] .diy-mockup-image-button {
  display: block !important;
  position: relative;
  z-index: 10;
  opacity: 1 !important;
  filter: none !important;
  mix-blend-mode: normal !important;
  background: transparent !important;
}

.diy-summary-card--mockup,
.diy-summary-card--mockup .diy-mockup-panel,
.diy-summary-card--mockup .diy-mockup-image-button,
.diy-summary-card--mockup .diy-mockup-image {
  opacity: 1 !important;
  mix-blend-mode: normal !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.diy-summary-card--mockup .diy-mockup-image-button::before,
.diy-summary-card--mockup .diy-mockup-image-button::after,
.diy-summary-card--mockup .diy-mockup-panel::before,
.diy-summary-card--mockup .diy-mockup-panel::after {
  display: none !important;
  content: none !important;
}

.diy-mockup-panel[data-has-image="true"] .diy-mockup-image {
  display: block !important;
  position: relative;
  z-index: 11;
  opacity: 1 !important;
  filter: none !important;
  mix-blend-mode: normal !important;
}

.diy-generate-spinner--panel {
  opacity: 1;
}

.diy-mockup-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.diy-mockup-action-button {
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--cocoa);
  box-shadow: none;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.diy-mockup-action-button:hover,
.diy-mockup-action-button:focus-visible {
  transform: none;
  border-color: rgba(239, 143, 164, 0.72);
  background: rgba(255, 248, 249, 0.98);
}

.diy-mockup-action-button[disabled] {
  background: rgba(255, 255, 255, 0.7);
  color: rgba(109, 91, 93, 0.46);
  border-color: rgba(231, 212, 202, 0.72);
}

.diy-mockup-actions .button[disabled] {
  opacity: 0.42;
  cursor: not-allowed;
}

.diy-lightbox {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
}

.diy-lightbox[hidden] {
  display: none !important;
}

.diy-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(48, 34, 39, 0.7);
  backdrop-filter: blur(4px);
}

.diy-lightbox-dialog {
  position: relative;
  z-index: 1;
  width: min(92vw, 620px);
  min-height: 140px;
  padding: 18px;
  display: grid;
  place-items: center;
}

.diy-lightbox-close {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--cocoa);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.diy-lightbox-image {
  display: block;
  width: 100%;
  max-height: 82vh;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.96);
  border-radius: 22px;
  box-shadow: 0 28px 70px rgba(24, 16, 19, 0.34);
}

.diy-summary-list {
  gap: 14px;
}

.diy-matrix-section,
.diy-database-section {
  margin-top: 28px;
}

.diy-subheading {
  gap: 14px;
  margin-bottom: 16px;
}

.diy-table-scroll {
  overflow-x: auto;
  padding-bottom: 6px;
}

.diy-matrix-table,
.diy-database-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.diy-matrix-table {
  min-width: 1080px;
  border: 1px solid rgba(231, 212, 202, 0.94);
  border-radius: 24px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.62);
}

.diy-matrix-table th,
.diy-matrix-table td,
.diy-database-table th,
.diy-database-table td {
  padding: 14px;
  text-align: left;
  border-right: 1px solid rgba(239, 223, 215, 0.9);
  border-bottom: 1px solid rgba(239, 223, 215, 0.9);
}

.diy-matrix-table tr:last-child th,
.diy-matrix-table tr:last-child td,
.diy-database-table tr:last-child th,
.diy-database-table tr:last-child td {
  border-bottom: 0;
}

.diy-matrix-table th:last-child,
.diy-matrix-table td:last-child,
.diy-database-table th:last-child,
.diy-database-table td:last-child {
  border-right: 0;
}

.diy-matrix-table thead th,
.diy-database-table thead th {
  background: #fff3ee;
  color: var(--cocoa);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.diy-matrix-table tbody th {
  width: 140px;
  vertical-align: top;
  background: rgba(255, 248, 244, 0.92);
  color: var(--cocoa);
  font-size: 0.82rem;
  font-weight: 700;
}

.diy-matrix-table tbody td {
  min-width: 200px;
  vertical-align: top;
  background: rgba(255, 255, 255, 0.76);
}

.diy-card-grid {
  display: grid;
  gap: 12px;
}

.diy-card {
  width: 100%;
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border-radius: 20px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  background: rgba(255, 255, 255, 0.92);
  text-align: left;
  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition),
    background var(--transition);
}

.diy-card:hover,
.diy-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(239, 143, 164, 0.72);
  box-shadow: 0 12px 24px rgba(214, 169, 160, 0.14);
}

.diy-card.is-active {
  border-color: rgba(239, 143, 164, 0.9);
  background: linear-gradient(180deg, rgba(255, 244, 247, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
}

.diy-card-thumb {
  width: 72px;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 248, 244, 0.94) 0%, rgba(251, 238, 231, 0.92) 100%);
}

.diy-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.diy-card-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.diy-card-copy strong {
  font-size: 0.92rem;
  color: var(--cocoa);
}

.diy-card-subline,
.diy-card-meta {
  font-size: 0.76rem;
  line-height: 1.45;
  color: var(--ink);
}

.diy-matrix-empty {
  min-height: 144px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  border-radius: 18px;
  border: 1px dashed rgba(231, 212, 202, 0.98);
  background: rgba(255, 250, 247, 0.84);
  color: rgba(109, 91, 93, 0.72);
  font-size: 0.82rem;
  text-align: center;
}

.diy-database-grid {
  display: grid;
  gap: 18px;
}

.diy-database-card h4 {
  margin: 0 0 14px;
  font-size: 1rem;
  color: var(--cocoa);
}

.diy-database-table {
  min-width: 520px;
  border: 1px solid rgba(231, 212, 202, 0.94);
  border-radius: 20px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.76);
}

.diy-database-table tbody td {
  font-size: 0.84rem;
  color: var(--cocoa);
}

@media (min-width: 768px) {
  .diy-top {
    display: grid;
    grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
    gap: 28px;
    margin-top: 32px;
    align-items: start;
  }

  .diy-preview-stage {
    min-height: 400px;
  }

  .diy-setting-header h3,
  .diy-subheading h3 {
    font-size: 1.58rem;
  }

  .diy-subheading {
    flex-direction: row;
    justify-content: space-between;
    align-items: end;
  }

  .diy-matrix-caption {
    max-width: 420px;
  }

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

@media (min-width: 1024px) {
  .diy-top {
    grid-template-columns: minmax(0, 1.06fr) minmax(360px, 0.94fr);
    gap: 40px;
  }

  .diy-preview-panel {
    position: sticky;
    top: 104px;
  }

  .diy-preview-stage {
    min-height: 470px;
  }

  .diy-preview-rope {
    inset: 10%;
    width: 80%;
    height: 80%;
  }

  .diy-preview-metrics strong {
    font-size: 1.12rem;
  }

  .diy-card {
    grid-template-columns: 80px 1fr;
    gap: 14px;
  }

  .diy-card-thumb {
    width: 80px;
    padding: 10px;
  }

  .diy-matrix-section,
  .diy-database-section {
    margin-top: 40px;
  }

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

/* ========== DIY Compact Filter Overrides ========== */
.diy-preview-item {
  padding: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 10px 20px rgba(120, 88, 82, 0.16);
  backdrop-filter: none;
}

.diy-preview-item img {
  filter: drop-shadow(0 4px 6px rgba(92, 74, 70, 0.1));
}

.diy-component-section {
  margin-top: 28px;
}

.diy-filter-drawer {
  border: 1px solid rgba(231, 212, 202, 0.92);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 20px 36px rgba(211, 176, 157, 0.1);
  overflow: hidden;
}

.diy-filter-drawer summary {
  list-style: none;
}

.diy-filter-drawer summary::-webkit-details-marker {
  display: none;
}

.diy-filter-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  cursor: pointer;
}

.diy-filter-summary > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.diy-filter-summary strong {
  font-size: 1rem;
  color: var(--cocoa);
}

.diy-filter-summary span:not(.diy-filter-pill) {
  font-size: 0.82rem;
  color: var(--ink);
}

.diy-filter-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(249, 220, 227, 0.94) 0%, rgba(255, 249, 250, 0.98) 100%);
  color: var(--cocoa);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
}

.diy-filter-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 18px 20px 20px;
  border-top: 1px solid rgba(239, 223, 215, 0.9);
}

.diy-filter-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.diy-filter-label {
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--rose);
}

.diy-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.diy-filter-chip {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  background: rgba(255, 255, 255, 0.92);
  color: var(--cocoa);
  font-size: 0.8rem;
  font-weight: 700;
  transition:
    border-color var(--transition),
    background var(--transition),
    transform var(--transition);
}

.diy-filter-chip:hover,
.diy-filter-chip:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(239, 143, 164, 0.72);
}

.diy-filter-chip.is-active {
  border-color: rgba(239, 143, 164, 0.92);
  background: linear-gradient(180deg, rgba(249, 220, 227, 0.94) 0%, rgba(255, 249, 250, 0.98) 100%);
}

.diy-component-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.diy-card {
  grid-template-columns: 64px 1fr;
  gap: 12px;
  padding: 12px;
}

.diy-card-thumb {
  width: 64px;
  padding: 8px;
}

.diy-filter-empty {
  padding: 24px 18px;
  border-radius: 18px;
  border: 1px dashed rgba(231, 212, 202, 0.96);
  background: rgba(255, 250, 247, 0.84);
  color: rgba(109, 91, 93, 0.72);
  font-size: 0.86rem;
  text-align: center;
}

@media (min-width: 768px) {
  .diy-filter-summary {
    padding: 20px 22px;
  }

  .diy-filter-body {
    padding: 18px 22px 22px;
  }

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

@media (min-width: 1024px) {
  .diy-component-section {
    margin-top: 40px;
  }

  .diy-filter-summary {
    padding: 22px 24px;
  }

  .diy-filter-body {
    padding: 20px 24px 24px;
  }

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

/* ========== DIY Dense Selection Overrides ========== */
.diy-preview-items {
  pointer-events: none;
}

.diy-preview-item {
  padding: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  cursor: grab;
  pointer-events: auto;
  touch-action: none;
  user-select: none;
  will-change: left, top, transform;
  transition:
    left 220ms cubic-bezier(0.18, 0.86, 0.2, 1),
    top 220ms cubic-bezier(0.18, 0.86, 0.2, 1),
    transform 260ms cubic-bezier(0.16, 1, 0.3, 1),
    filter 180ms ease;
}

.diy-preview-item.is-dragging {
  cursor: grabbing;
  filter: drop-shadow(0 12px 22px rgba(120, 88, 82, 0.18));
  transition:
    left 74ms cubic-bezier(0.2, 0.8, 0.2, 1),
    top 74ms cubic-bezier(0.2, 0.8, 0.2, 1),
    transform 120ms cubic-bezier(0.16, 1, 0.3, 1),
    filter 120ms ease;
}

.diy-preview-item.is-trash-target {
  filter: drop-shadow(0 18px 30px rgba(207, 112, 134, 0.26));
}

.diy-preview-item.is-removing {
  animation: diy-preview-remove-to-trash 0.26s cubic-bezier(0.2, 0.78, 0.18, 1) forwards;
  pointer-events: none;
}

.diy-preview-item.is-insert-preview {
  animation: none;
  filter:
    drop-shadow(0 7px 7px rgba(63, 49, 46, 0.12))
    drop-shadow(0 14px 12px rgba(120, 88, 82, 0.08));
}

.diy-preview-item.is-yielding-for-insert {
  animation: diy-preview-yield 0.46s ease-out both;
}

.diy-preview-item img {
  filter:
    drop-shadow(0 7px 7px rgba(63, 49, 46, 0.16))
    drop-shadow(0 16px 14px rgba(120, 88, 82, 0.1));
  transform: translateZ(0);
}

.diy-filter-summary {
  gap: 12px;
  padding: 14px 16px;
}

.diy-filter-body {
  gap: 12px;
  padding: 12px 14px 14px;
}

.diy-filter-group {
  gap: 8px;
}

.diy-filter-chips {
  gap: 6px;
}

.diy-filter-chip {
  min-height: 32px;
  padding: 0 12px;
  font-size: 0.74rem;
}

.diy-component-section {
  margin-top: 22px;
}

.diy-component-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  max-height: 360px;
  overflow: auto;
  overscroll-behavior: contain;
  padding-right: 2px;
  align-content: start;
  scrollbar-width: thin;
}

.diy-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 9px;
  border-radius: 16px;
}

.diy-card-main {
  width: 100%;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  text-align: left;
}

.diy-card-thumb {
  width: 46px;
  padding: 0;
  border-radius: 0;
  background: none;
}

.diy-card-thumb img {
  filter: drop-shadow(0 4px 8px rgba(110, 90, 82, 0.12));
}

.diy-card-copy strong {
  font-size: 0.78rem;
  line-height: 1.3;
}

.diy-card-subline,
.diy-card-meta {
  font-size: 0.64rem;
  line-height: 1.35;
}

.diy-card-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 3px 6px;
}

.diy-card-qty {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding-top: 6px;
  border-top: 1px solid rgba(239, 223, 215, 0.92);
}

.diy-card-qty.is-visible {
  display: flex;
}

.diy-card-qty-count,
.diy-card-rope-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(250, 232, 236, 0.9);
  color: var(--cocoa);
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.diy-card-rope-pill {
  align-self: flex-start;
}

.diy-card-qty-actions {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.diy-card-qty-button {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  background: rgba(255, 255, 255, 0.94);
  color: var(--cocoa);
  font-size: 0.9rem;
  font-weight: 800;
  line-height: 1;
  transition:
    transform var(--transition),
    border-color var(--transition),
    background var(--transition);
}

.diy-card-qty-button:hover,
.diy-card-qty-button:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(239, 143, 164, 0.84);
  background: rgba(255, 248, 250, 0.98);
}

.diy-card-qty-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

@media (min-width: 768px) {
  .diy-filter-summary {
    padding: 16px 18px;
  }

  .diy-filter-body {
    padding: 14px 18px 18px;
  }

  .diy-component-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    max-height: 420px;
  }
}

@media (min-width: 1024px) {
  .diy-filter-summary {
    padding: 18px 20px;
  }

  .diy-filter-body {
    padding: 16px 20px 20px;
  }

  .diy-component-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    max-height: 520px;
  }

  .diy-card-main {
    grid-template-columns: 52px minmax(0, 1fr);
  }

  .diy-card-thumb {
    width: 52px;
  }
}

/* ========== Builder Page Overrides ========== */
body.builder-page {
  overflow-x: clip;
}

.builder-page .builder-shell {
  max-width: 1120px;
}

.builder-page .section-heading--wide {
  margin-bottom: 14px;
}

.builder-page .diy-setting-card,
.builder-page .diy-summary-card,
.builder-page .diy-filter-drawer {
  border-radius: 14px;
  border-color: rgba(231, 212, 202, 0.96);
  background: rgba(255, 252, 249, 0.92);
  box-shadow: 0 10px 24px rgba(211, 176, 157, 0.08);
  min-width: 0;
  width: 100%;
}

.builder-page .diy-preview-card {
  position: relative;
  min-width: 0;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.builder-page .diy-length-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 8px 0 10px;
  margin-top: 8px;
  border: 0;
  border-top: 1px solid rgba(231, 212, 202, 0.7);
  border-bottom: 1px solid rgba(231, 212, 202, 0.9);
  border-radius: 0;
  background: linear-gradient(180deg, rgba(255, 252, 249, 0.64) 0%, rgba(255, 252, 249, 0) 100%);
  box-shadow: none;
}

.builder-page .diy-length-bar-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
  min-width: 0;
}

.builder-page .diy-length-bar-copy .eyebrow {
  margin: 0;
  color: var(--rose);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
}

.builder-page .diy-length-bar-copy h3 {
  display: none;
  margin: 0;
  max-width: 280px;
  font-family: "Manrope", sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.35;
  color: rgba(109, 91, 93, 0.82);
}

.builder-page .diy-length-field {
  margin: 0;
  justify-self: center;
  justify-content: center;
  flex-direction: row;
  align-items: flex-end;
  gap: 0 12px;
  flex-wrap: nowrap;
}

.builder-page .diy-length-label {
  display: none;
}

.builder-page .diy-length-input-wrap {
  min-width: 128px;
  justify-content: center;
  padding: 0 6px 5px;
  border: 0;
  border-bottom: 1px solid rgba(61, 43, 45, 0.34);
  border-radius: 0;
  background: transparent;
  gap: 10px;
}

.builder-page .diy-length-input-wrap input {
  width: 58px;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-align: center;
}

.builder-page .diy-length-input-wrap span {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink);
}

.builder-page .diy-length-hint {
  font-size: 0.72rem;
  line-height: 1.4;
}

.builder-page .diy-length-bar-spacer {
  justify-self: end;
  width: 72px;
  height: 1px;
  min-width: 0;
  background: rgba(221, 201, 193, 0.92);
}

.builder-page .diy-top {
  margin-top: 8px;
}

.builder-page .diy-workbench,
.builder-page .diy-preview-panel {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.builder-page .diy-preview-stage {
  width: 100%;
  aspect-ratio: 1 / 1;
  min-height: 0;
  height: auto;
  max-width: 640px;
  margin: 0 auto;
  border: 1px solid rgba(223, 214, 208, 0.92);
  border-radius: 14px;
  background: #fff;
  flex: 0 0 auto;
  z-index: 0;
  isolation: isolate;
}

.builder-page .diy-preview-stage-grid {
  display: none;
}

.builder-page .diy-preview-rope-guide {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 72%;
  height: 72%;
  border: 1.5px dashed rgba(141, 122, 121, 0.58);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.builder-page .diy-preview-stage-logo {
  position: absolute;
  left: 50%;
  top: 36%;
  z-index: 0;
  width: clamp(90px, 15vw, 140px);
  height: auto;
  opacity: 1;
  transform: translate(-50%, -50%);
  pointer-events: none;
  user-select: none;
}

.builder-page .diy-preview-trash {
  position: absolute;
  left: 50%;
  top: 61%;
  z-index: 3;
  width: clamp(30px, 7vw, 46px);
  height: clamp(30px, 7vw, 46px);
  display: grid;
  place-items: center;
  border: 1px solid rgba(231, 212, 202, 0.86);
  border-radius: 999px;
  background: rgba(255, 253, 251, 0.78);
  color: rgba(109, 91, 93, 0.52);
  transform: translate(-50%, -50%);
  box-shadow: 0 10px 24px rgba(120, 88, 82, 0.08);
  transition: color var(--transition), border-color var(--transition), background var(--transition), box-shadow var(--transition), transform var(--transition);
  pointer-events: none;
}

.builder-page .diy-preview-trash svg {
  width: 52%;
  height: 52%;
}

.builder-page .diy-preview-stage.is-dragging-preview-item .diy-preview-trash {
  border-color: rgba(239, 143, 164, 0.72);
  background: rgba(255, 246, 248, 0.94);
  color: rgba(207, 112, 134, 0.78);
}

.builder-page .diy-preview-trash.is-preview-trash-hover {
  border-color: rgba(221, 112, 137, 0.98);
  background: rgba(251, 228, 235, 0.98);
  color: #b96278;
  box-shadow: 0 14px 34px rgba(207, 112, 134, 0.2);
  transform: translate(-50%, -50%) scale(1.08);
}

.builder-page .diy-preview-trash.is-preview-trash-drop {
  animation: diy-trash-confirm 0.32s ease-out both;
}

.builder-page .diy-preview-badge {
  display: none;
}

.builder-page .diy-preview-side-notes {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 12px;
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: nowrap;
  text-align: left;
  overflow: hidden;
  pointer-events: none;
}

.builder-page .diy-preview-side-notes p {
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 4px;
  min-width: 0;
}

.builder-page .diy-preview-side-note--rope {
  flex: 1 1 auto;
  overflow: hidden;
}

.builder-page .diy-preview-side-notes span {
  flex: 0 0 auto;
  font-size: 0.46rem;
  line-height: 1.2;
  letter-spacing: 0.06em;
  color: rgba(109, 91, 93, 0.72);
}

.builder-page .diy-preview-side-notes strong {
  color: var(--cocoa);
  font-size: 0.62rem;
  line-height: 1.18;
  font-weight: 700;
  white-space: nowrap;
}

.builder-page .diy-preview-side-notes em {
  display: none;
}

.builder-page .diy-preview-side-note--rope strong {
  overflow: hidden;
  text-overflow: ellipsis;
}

.builder-page .diy-preview-metrics {
  left: 12px;
  right: 12px;
  bottom: 12px;
  gap: 8px;
}

.builder-page .diy-preview-metrics > div {
  padding: 8px 10px;
  border-radius: 10px;
}

.builder-page .diy-preview-metrics span {
  font-size: 0.58rem;
  letter-spacing: 0.1em;
}

.builder-page .diy-preview-metrics strong {
  font-size: 0.92rem;
}

.builder-page .diy-component-section {
  margin-top: 0;
  min-width: 0;
}

.builder-page .diy-subheading {
  margin-bottom: 8px;
}

.builder-page .diy-subheading h3 {
  font-family: "Manrope", sans-serif;
  font-size: 0.92rem;
  font-weight: 700;
}

.builder-page .diy-matrix-caption {
  font-size: 0.74rem;
  line-height: 1.45;
}

.builder-page .diy-filter-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px 10px;
}

.builder-page .diy-filter-summary strong {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-align: left;
}

.builder-page .diy-filter-summary span:not(.diy-filter-pill) {
  font-size: 0.68rem;
  line-height: 1.35;
}

.builder-page .diy-filter-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  flex-wrap: nowrap;
  gap: 6px;
  margin-left: auto;
}

.builder-page .diy-history-button {
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 10px;
  background: #fff;
  color: var(--cocoa);
  font-size: 0.64rem;
  font-weight: 700;
  line-height: 1;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.builder-page .diy-history-button:disabled {
  opacity: 0.42;
  cursor: default;
}

.builder-page .diy-preview-history-actions {
  position: absolute;
  left: 50%;
  bottom: 8px;
  z-index: 4;
  display: flex;
  justify-content: center;
  gap: 6px;
  width: max-content;
  max-width: calc(100% - 24px);
  transform: translateX(-50%);
  pointer-events: none;
}

.builder-page .diy-preview-history-actions .diy-history-button {
  min-height: 28px;
  padding: 0 11px;
  background: rgba(255, 253, 251, 0.94);
  border-color: rgba(231, 212, 202, 0.98);
  box-shadow: 0 8px 18px rgba(120, 88, 82, 0.08);
  pointer-events: auto;
}

.builder-page .diy-filter-pill {
  min-height: 28px;
  padding: 0 10px;
  font-size: 0.62rem;
}

.builder-page .diy-filter-body {
  gap: 12px;
  padding: 14px 12px 14px;
  border-top: 0;
  min-width: 0;
}

.builder-page .diy-filter-group {
  gap: 8px;
  min-width: 0;
  width: 100%;
}

.builder-page .diy-filter-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
}

.builder-page .diy-component-search {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  color: rgba(109, 91, 93, 0.72);
}

.builder-page .diy-component-search:focus-within {
  border-color: rgba(239, 143, 164, 0.82);
  color: #cf7086;
}

.builder-page .diy-component-search-icon {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  display: inline-flex;
}

.builder-page .diy-component-search-icon svg {
  width: 100%;
  height: 100%;
}

.builder-page .diy-component-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--cocoa);
  font: inherit;
  font-size: 0.66rem;
  font-weight: 600;
  line-height: 1;
}

.builder-page .diy-component-search input::placeholder {
  color: rgba(109, 91, 93, 0.58);
}

.builder-page .diy-component-search input:focus {
  outline: none;
}

.builder-page .diy-result-count {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(251, 228, 235, 0.74);
  color: #b96278;
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.builder-page .diy-filter-label {
  font-size: 0.58rem;
  letter-spacing: 0.14em;
  color: rgba(109, 91, 93, 0.7);
}

.builder-page [data-category-filters],
.builder-page [data-material-filters] {
  display: grid;
  align-content: start;
  min-width: 0;
  width: 100%;
}

.builder-page [data-category-filters] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.builder-page [data-material-filters] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.builder-page .diy-filter-chip {
  width: 100%;
  min-width: 0;
  padding: 0;
  border-radius: 12px;
  border-color: rgba(231, 212, 202, 0.96);
  background: #fff;
  color: var(--cocoa);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.builder-page .diy-filter-chip:hover,
.builder-page .diy-filter-chip:focus-visible {
  transform: none;
  border-color: rgba(239, 143, 164, 0.72);
}

.builder-page .diy-filter-chip.is-active {
  border-color: rgba(239, 143, 164, 0.94);
  background: linear-gradient(180deg, rgba(251, 228, 235, 0.96) 0%, rgba(255, 245, 248, 0.98) 100%);
  color: #cf7086;
}

.builder-page .diy-filter-chip--category {
  min-height: 34px;
  flex-direction: row;
  gap: 5px;
  padding: 0 10px;
  border-radius: 12px;
}

.builder-page .diy-filter-chip--material,
.builder-page .diy-filter-chip--diameter {
  min-height: 32px;
  padding: 0 10px;
  border-radius: 12px;
}

.builder-page .diy-filter-chip-icon {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.builder-page .diy-filter-chip-icon svg {
  width: 100%;
  height: 100%;
}

.builder-page .diy-filter-chip-text {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.builder-page .diy-filter-chip--category .diy-filter-chip-text {
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.builder-page .diy-filter-chip--material .diy-filter-chip-text,
.builder-page .diy-filter-chip--diameter .diy-filter-chip-text {
  font-size: 0.62rem;
  font-weight: 800;
  white-space: nowrap;
}

.builder-page .diy-component-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px 6px;
  max-height: none;
  overflow: visible;
  min-width: 0;
  width: 100%;
}

.builder-page .diy-component-browser {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  min-width: 0;
  width: 100%;
}

.builder-page .diy-material-rail {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-self: start;
  max-height: calc((var(--diy-visible-card-row, 130px) * 4) + 24px);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: none;
}

.builder-page .diy-material-rail::-webkit-scrollbar {
  display: none;
}

.builder-page .diy-material-rail-button {
  min-height: 32px;
  width: 100%;
  padding: 4px 7px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.94);
  color: rgba(60, 48, 52, 0.82);
  font: inherit;
  font-size: 0.58rem;
  font-weight: 800;
  line-height: 1.08;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
  cursor: pointer;
  touch-action: manipulation;
}

.builder-page .diy-material-rail-button.is-active,
.builder-page .diy-material-rail-button:hover,
.builder-page .diy-material-rail-button:focus-visible {
  border-color: rgba(239, 143, 164, 0.9);
  background: rgba(251, 228, 235, 0.9);
  color: #b96278;
}

.builder-page .diy-component-grid.is-rope-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 8px;
}

.builder-page .diy-card {
  position: relative;
  gap: 8px;
  padding: 10px 8px 8px;
  border: 1px solid rgba(231, 212, 202, 0.92);
  border-radius: 18px;
  background: #fff;
  box-shadow: none;
  transition:
    border-color var(--transition),
    background var(--transition),
    transform var(--transition);
}

.builder-page .diy-card:hover,
.builder-page .diy-card:focus-within {
  border-color: rgba(239, 143, 164, 0.52);
}

.builder-page .diy-card.is-disabled {
  opacity: 0.5;
  filter: none;
}

.builder-page .diy-card.is-muted {
  opacity: 0.58;
}

.builder-page .diy-card.is-active {
  border-color: rgba(239, 143, 164, 0.92);
  background: linear-gradient(180deg, rgba(255, 247, 249, 0.98) 0%, rgba(255, 255, 255, 1) 100%);
}

.builder-page .diy-card.is-disabled .diy-card-main {
  cursor: not-allowed;
}

.builder-page .diy-card--rope {
  width: 100%;
  padding: 10px 10px 8px;
  cursor: pointer;
  text-align: center;
  font: inherit;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.builder-page .diy-card--rope.is-active::after {
  content: none;
}

.builder-page .diy-card--rope.is-active {
  border-color: rgba(239, 143, 164, 0.92);
  background: linear-gradient(180deg, rgba(255, 247, 249, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
}

.builder-page .diy-card-main {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: stretch;
  text-align: center;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
}

.builder-page .diy-card--rope .diy-card-main {
  gap: 10px;
}

.builder-page .diy-card--compact {
  padding: 6px 5px;
  border-radius: 15px;
}

.builder-page .diy-card--compact .diy-card-main {
  gap: 5px;
}

.builder-page .diy-card-main.is-card-drag-source {
  opacity: 0.46;
}

.builder-page .diy-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 249, 247, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
}

.builder-page .diy-card--rope .diy-card-thumb {
  aspect-ratio: 1.12 / 1;
  padding: 12px 8px;
}

.builder-page .diy-card--compact .diy-card-thumb {
  min-height: 50px;
  padding: 4px;
  border-radius: 12px;
}

.builder-page .diy-card-thumb img,
.builder-page .diy-card--rope .diy-card-thumb img {
  width: 88%;
  height: 88%;
  object-fit: contain;
  filter: none;
  -webkit-user-drag: none;
  user-select: none;
  pointer-events: none;
}

.builder-page .diy-card--compact .diy-card-thumb img {
  width: 90%;
  height: 90%;
}

.builder-page .diy-card--compact .diy-card-thumb::after {
  content: none !important;
  display: none !important;
}

.builder-page .diy-card--compact.is-active .diy-card-thumb::after {
  opacity: 0;
}

.builder-page .diy-card-overlay {
  position: absolute;
  top: 4px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  max-width: calc(100% - 8px);
  padding: 1px 4px;
  border-radius: 999px;
  line-height: 1.15;
  white-space: nowrap;
}

.builder-page .diy-card-overlay--left {
  left: 4px;
  font-size: 0.46rem;
  color: rgba(109, 91, 93, 0.78);
  background: rgba(247, 241, 238, 0.96);
}

.builder-page .diy-card-overlay--right {
  right: 4px;
  font-size: 0.48rem;
  color: #df8298;
  font-weight: 800;
  background: rgba(251, 228, 235, 0.92);
}

.builder-page .diy-card-copy {
  display: grid;
  gap: 3px;
  justify-items: center;
}

.builder-page .diy-card-copy strong {
  font-size: clamp(0.68rem, 2.5vw, 0.76rem);
  line-height: 1.35;
  display: -webkit-box;
  min-height: 2.7em;
  overflow: hidden;
  text-wrap: balance;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.builder-page .diy-card--compact .diy-card-copy {
  gap: 3px;
  justify-items: stretch;
}

.builder-page .diy-card--compact .diy-card-copy strong {
  min-height: auto;
  font-size: 0.61rem;
  line-height: 1.16;
  white-space: nowrap;
  text-align: left;
  text-overflow: ellipsis;
  -webkit-line-clamp: 1;
}

.builder-page .diy-card-material-tab {
  position: absolute;
  top: 50%;
  left: -1px;
  z-index: 6;
  max-height: calc(100% - 12px);
  padding: 5px 2px;
  border: 1px solid rgba(231, 212, 202, 0.94);
  border-left: 0;
  border-radius: 0 8px 8px 0;
  background: rgba(255, 250, 252, 0.96);
  color: rgba(109, 91, 93, 0.72);
  font: inherit;
  font-size: 0.46rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
  transform: translateY(-50%) rotate(180deg);
  cursor: pointer;
  touch-action: manipulation;
}

.builder-page .diy-card-material-tab.is-active,
.builder-page .diy-card-material-tab:hover,
.builder-page .diy-card-material-tab:focus-visible {
  border-color: rgba(239, 143, 164, 0.86);
  background: rgba(251, 228, 235, 0.96);
  color: #b96278;
}

.builder-page .diy-card-price-line {
  display: block;
  color: #df8298;
  font-size: 0.62rem;
  font-weight: 900;
  line-height: 1;
  text-align: center;
}

.builder-page .diy-card-price {
  color: #df8298;
  font-size: 0.84rem;
  font-weight: 800;
  line-height: 1;
}

.builder-page .diy-card-meta {
  display: block;
  font-size: 0.62rem;
  line-height: 1.35;
  color: rgba(109, 91, 93, 0.72);
}

.builder-page .diy-card-subline,
.builder-page .diy-card-meta-row {
  display: none;
}

.builder-page .diy-card--compact .diy-card-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.builder-page .diy-card--compact .diy-card-price {
  font-size: 0.7rem;
}

.builder-page .diy-card--compact .diy-card-meta {
  font-size: 0.54rem;
  line-height: 1;
  white-space: nowrap;
}

.builder-page .diy-card-qty-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  color: #cf7086;
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  line-height: 1;
  transform: translate(-50%, -50%);
  z-index: 4;
  -webkit-text-stroke: 0;
  text-shadow: none;
}

.builder-page .diy-card--rope.is-active .diy-card-qty-badge {
  display: inline-flex !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.builder-page .diy-card-qty {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding-top: 6px;
  border-top: 1px solid rgba(239, 223, 215, 0.92);
}

.builder-page .diy-card-qty.is-visible {
  display: flex;
}

.builder-page .diy-card--rope .diy-card-qty {
  display: none !important;
}

.builder-page .diy-card-qty--compact {
  padding-top: 5px;
  gap: 4px;
  justify-content: space-between;
}

.builder-page .diy-card-qty-count {
  min-height: 21px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(251, 228, 235, 0.9);
  color: #b96278;
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.builder-page .diy-card-qty--compact .diy-card-qty-count {
  min-height: 18px;
  padding: 0 6px;
  font-size: 0.5rem;
}

.builder-page .diy-card-qty-actions {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.builder-page .diy-card-qty-button {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  background: #fff;
  color: var(--cocoa);
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1;
}

.builder-page .diy-card-qty-button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.builder-page .diy-card--compact .diy-card-qty-button {
  width: 20px;
  height: 20px;
  font-size: 0.86rem;
}

.builder-page .diy-card-rope-pill {
  min-height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  background: rgba(251, 228, 235, 0.72);
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.builder-page .diy-preview-toast {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(0.98);
  z-index: 2147483647;
  width: min(92vw, 720px);
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(60, 44, 47, 0.96);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  box-shadow: 0 18px 44px rgba(60, 44, 47, 0.28);
  transition: opacity var(--transition), transform var(--transition);
}

.builder-page .diy-preview-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.builder-page .diy-card-drag-ghost {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 2147483646;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(239, 223, 215, 0.66);
  border-radius: 999px;
  background: rgba(255, 253, 251, 0.7);
  box-shadow: 0 12px 26px rgba(120, 88, 82, 0.14);
  pointer-events: none;
  transform: translate(-50%, -50%);
  overflow: visible;
}

.builder-page .diy-card-drag-ghost img {
  width: 94%;
  height: 94%;
  object-fit: contain;
  filter:
    drop-shadow(0 7px 8px rgba(63, 49, 46, 0.16))
    drop-shadow(0 16px 16px rgba(120, 88, 82, 0.12));
}

.builder-page .diy-card-drag-ghost.is-snapped {
  border-color: rgba(239, 223, 215, 0.7);
  background: rgba(255, 253, 251, 0.78);
  box-shadow:
    0 14px 32px rgba(120, 88, 82, 0.15),
    0 0 16px rgba(239, 143, 164, 0.09);
  transform: translate(-50%, -50%);
  animation: diy-card-ghost-breathe 0.86s ease-in-out infinite alternate;
}

.builder-page .diy-card-drag-ghost.is-snapped::after {
  content: "";
  position: absolute;
  inset: -4px;
  z-index: -1;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(239, 143, 164, 0.16), rgba(239, 143, 164, 0));
  animation: diy-card-ghost-halo 0.86s ease-in-out infinite alternate;
  pointer-events: none;
}

.builder-page .diy-preview-stage.is-card-drag-active .diy-preview-rope-guide {
  border-color: rgba(239, 143, 164, 0.66);
}

.builder-page .diy-preview-stage.is-card-drag-over-ring .diy-preview-rope-guide {
  border-color: #cf7086;
  box-shadow: 0 0 0 5px rgba(239, 143, 164, 0.12);
}

.builder-page .diy-preview-stage.is-card-drag-over-ring::after {
  content: "";
  position: absolute;
  inset: 11.5%;
  z-index: 0;
  border-radius: 50%;
  border: 1px solid rgba(239, 143, 164, 0.22);
  box-shadow:
    inset 0 0 0 10px rgba(239, 143, 164, 0.035),
    0 0 28px rgba(239, 143, 164, 0.12);
  pointer-events: none;
  animation: diy-ring-ready 0.72s ease-in-out infinite alternate;
}

.builder-page .diy-preview-tip {
  position: absolute;
  left: 50%;
  bottom: 17%;
  z-index: 5;
  max-width: min(78%, 360px);
  padding: 7px 12px;
  border: 1px solid rgba(231, 212, 202, 0.64);
  border-radius: 999px;
  background: rgba(255, 253, 251, 0.68);
  color: rgba(60, 44, 47, 0.72);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.15;
  text-align: center;
  box-shadow: 0 10px 26px rgba(120, 88, 82, 0.08);
  backdrop-filter: blur(12px);
  opacity: 0;
  transform: translate(-50%, 8px);
  transition: opacity 0.22s ease, transform 0.22s ease;
  pointer-events: none;
}

.builder-page .diy-preview-stage:not(.has-preview-parts):not(.is-card-drag-active) .diy-preview-tip {
  opacity: 1;
  transform: translate(-50%, 0);
}

.builder-page .diy-preview-panel {
  position: relative;
}

.builder-page .diy-onboarding-demo {
  position: absolute;
  inset: 0;
  z-index: 28;
  display: none;
  overflow: hidden;
  border-radius: var(--diy-panel-radius, 18px);
  background: rgba(255, 248, 251, 0.14);
  pointer-events: none;
}

.builder-page .diy-onboarding-demo.is-playing {
  display: block;
  animation: diy-onboarding-demo 5.8s ease forwards;
}

.builder-page .diy-onboarding-demo.is-finished {
  display: none;
}

.builder-page .diy-onboarding-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.builder-page .diy-onboarding-stage-target {
  fill: rgba(239, 143, 164, 0.2);
  stroke: rgba(207, 112, 134, 0.42);
  stroke-width: 2;
  opacity: 0;
  transform-origin: 285px 306px;
  animation: diy-onboarding-stage-target 5.8s ease forwards;
}

.builder-page .diy-onboarding-click-ring {
  fill: none;
  stroke: rgba(207, 112, 134, 0.58);
  stroke-width: 4;
  opacity: 0;
  transform-origin: 720px 174px;
  animation: diy-onboarding-click-ring 5.8s ease forwards;
}

.builder-page .diy-onboarding-bead {
  opacity: 0;
  transform: translate(720px, 174px) scale(0.86);
  animation: diy-onboarding-bead 5.8s cubic-bezier(0.2, 0.72, 0.18, 1) forwards;
}

.builder-page .diy-onboarding-cursor {
  opacity: 0;
  transform: translate(782px, 226px) scale(0.9);
  animation: diy-onboarding-cursor 5.8s cubic-bezier(0.2, 0.72, 0.18, 1) forwards;
}

.builder-page .diy-preview-stage.is-preview-trash-hover {
  box-shadow:
    inset 0 0 0 1px rgba(239, 143, 164, 0.1),
    0 18px 42px rgba(207, 112, 134, 0.08);
}

@keyframes diy-onboarding-demo {
  0%,
  88% {
    opacity: 1;
    visibility: visible;
  }

  100% {
    opacity: 0;
    visibility: hidden;
  }
}

@keyframes diy-onboarding-stage-target {
  0%,
  54% {
    opacity: 0;
    transform: scale(0.82);
  }

  66%,
  86% {
    opacity: 1;
    transform: scale(1);
  }

  100% {
    opacity: 0;
    transform: scale(1.12);
  }
}

@keyframes diy-onboarding-click-ring {
  0%,
  20% {
    opacity: 0;
    transform: scale(0.7);
  }

  26% {
    opacity: 1;
    transform: scale(1);
  }

  40%,
  100% {
    opacity: 0;
    transform: scale(1.65);
  }
}

@keyframes diy-onboarding-bead {
  0%,
  16% {
    opacity: 0;
    transform: translate(720px, 174px) scale(0.86);
  }

  24%,
  38% {
    opacity: 0.62;
    transform: translate(720px, 174px) scale(0.86);
  }

  72%,
  88% {
    opacity: 0.48;
    transform: translate(285px, 306px) scale(1);
  }

  100% {
    opacity: 0;
    transform: translate(285px, 306px) scale(1);
  }
}

@keyframes diy-onboarding-cursor {
  0%,
  12% {
    opacity: 0;
    transform: translate(782px, 226px) scale(0.9);
  }

  20% {
    opacity: 0.72;
    transform: translate(760px, 202px) scale(0.9);
  }

  30%,
  38% {
    opacity: 0.72;
    transform: translate(742px, 190px) scale(0.82);
  }

  72% {
    opacity: 0.66;
    transform: translate(318px, 335px) scale(0.9);
  }

  88%,
  100% {
    opacity: 0;
    transform: translate(318px, 335px) scale(0.9);
  }
}

@media (prefers-reduced-motion: reduce) {
  .builder-page .diy-onboarding-demo.is-playing {
    display: none;
    animation: none;
  }
}

@keyframes diy-preview-yield {
  0% {
    filter: drop-shadow(0 5px 10px rgba(100, 80, 75, 0.12));
  }

  45% {
    filter: drop-shadow(0 12px 20px rgba(207, 112, 134, 0.16));
  }

  100% {
    filter: drop-shadow(0 5px 10px rgba(100, 80, 75, 0.12));
  }
}

@keyframes diy-preview-remove {
  to {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.28);
    filter: blur(1px);
  }
}

@keyframes diy-preview-remove-to-trash {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.08);
    filter: drop-shadow(0 18px 30px rgba(207, 112, 134, 0.26));
  }

  72% {
    opacity: 0.82;
    transform: translate(calc(-50% + var(--diy-remove-x, 0px)), calc(-50% + var(--diy-remove-y, 0px))) scale(0.22);
    filter: drop-shadow(0 5px 10px rgba(207, 112, 134, 0.18));
  }

  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--diy-remove-x, 0px)), calc(-50% + var(--diy-remove-y, 0px))) scale(0.05);
    filter: blur(1px);
  }
}

@keyframes diy-trash-confirm {
  0% {
    transform: translate(-50%, -50%) scale(1.08);
  }

  55% {
    transform: translate(-50%, -50%) scale(1.22);
  }

  100% {
    transform: translate(-50%, -50%) scale(1);
  }
}

@keyframes diy-ring-ready {
  from {
    opacity: 0.36;
    transform: scale(0.992);
  }

  to {
    opacity: 0.82;
    transform: scale(1.008);
  }
}

@keyframes diy-card-ghost-breathe {
  from {
    transform: translate(-50%, -50%) scale(0.98);
  }

  to {
    transform: translate(-50%, -50%) scale(1.06);
  }
}

@keyframes diy-card-ghost-halo {
  from {
    opacity: 0.32;
    transform: scale(0.88);
  }

  to {
    opacity: 0.82;
    transform: scale(1.18);
  }
}

@keyframes diy-rope-attention-pulse {
  0%,
  100% {
    border-color: rgba(231, 212, 202, 0.96);
    box-shadow: 0 0 0 0 rgba(239, 143, 164, 0);
  }

  50% {
    border-color: rgba(239, 143, 164, 0.96);
    box-shadow: 0 0 0 4px rgba(239, 143, 164, 0.14);
  }
}

.builder-page .diy-filter-chip--category.is-rope-attention {
  animation: diy-rope-attention-pulse 1.35s ease-in-out infinite;
}

.builder-page .diy-summary-card--footer {
  margin-top: 14px;
  padding: 14px;
}

.builder-page .diy-summary-card--footer .summary-header {
  align-items: start;
}

.builder-page .diy-summary-card--footer .summary-header h3 {
  font-size: 1rem;
}

.builder-page .diy-summary-list {
  gap: 10px;
}

.builder-page .diy-selection-note {
  margin-top: 12px;
  font-size: 0.76rem;
  line-height: 1.45;
}

.builder-page [data-summary-rope],
.builder-page [data-summary-selection] {
  font-size: 0.7rem;
  line-height: 1.6;
  color: #000;
  overflow-wrap: anywhere;
}

.builder-page .summary-actions {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.builder-page .summary-actions .button {
  width: 100%;
  justify-content: center;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  text-transform: none;
  letter-spacing: 0.04em;
}

.builder-page .summary-order-button {
  min-height: 58px;
  border-radius: 22px;
  box-shadow: none;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.builder-page .summary-order-button:hover,
.builder-page .summary-order-button:focus-visible {
  transform: none;
}

.builder-page .diy-summary-card--mockup .summary-order-button {
  min-height: 54px;
  letter-spacing: 0.08em;
}

.builder-page .summary-secondary-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.builder-page .summary-action-tile {
  min-width: 0;
  min-height: 54px;
  padding: 10px 6px;
  border: 1px solid rgba(231, 212, 202, 0.92);
  border-radius: 22px;
  background: #fff;
  color: var(--cocoa);
  flex-direction: row;
  gap: 6px;
  box-shadow: none;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
}

.builder-page .summary-action-tile::before {
  display: none;
}

.builder-page .summary-action-tile[data-summary-action="save"]::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ef8fa4' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 4.5h10l2 2v13H6z'/%3E%3Cpath d='M9 4.5v4h6v-4'/%3E%3Cpath d='M9 19v-6h6v6'/%3E%3C/svg%3E");
}

.builder-page .summary-action-tile[data-summary-action="share"]::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ef8fa4' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='6' cy='12' r='2.3'/%3E%3Ccircle cx='18' cy='6' r='2.3'/%3E%3Ccircle cx='18' cy='18' r='2.3'/%3E%3Cpath d='M8 11l7.2-4'/%3E%3Cpath d='M8 13l7.2 4'/%3E%3C/svg%3E");
}

.builder-page .summary-action-tile[data-summary-action="generate"]::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ef8fa4' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4.5' y='4.5' width='15' height='15' rx='2.5'/%3E%3Ccircle cx='9' cy='10' r='1.4'/%3E%3Cpath d='M6.7 17l4.1-4.1 2.5 2.5 2.8-2.8 1.2 1.2'/%3E%3C/svg%3E");
}

.builder-page .summary-action-tile:hover,
.builder-page .summary-action-tile:focus-visible {
  transform: none;
  border-color: rgba(239, 143, 164, 0.72);
  color: #cf7086;
}

@media (min-width: 768px) {
  .builder-page .summary-actions {
    gap: 12px;
    margin-top: 16px;
  }

  .builder-page .summary-order-button {
    min-height: 64px;
    font-size: 1.06rem;
  }

  .builder-page .diy-summary-card--mockup .summary-order-button {
    min-height: 58px;
  }

  .builder-page .summary-secondary-actions {
    gap: 12px;
  }

  .builder-page .summary-action-tile {
    min-height: 118px;
    padding: 20px 12px 16px;
    gap: 14px;
    font-size: 0.98rem;
  }

  .builder-page .summary-action-tile::before {
    width: 32px;
    height: 32px;
  }
}

@media (max-width: 767px) {
  .builder-page .diy-length-bar {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    padding: 12px 0 14px;
  }

  .builder-page .diy-length-bar-copy h3 {
    max-width: 180px;
    font-size: 0.74rem;
  }

  .builder-page .diy-length-bar-spacer {
    display: none;
  }

  .builder-page .diy-preview-panel {
    gap: 10px;
  }

  .builder-page .diy-preview-card {
    position: sticky;
    top: 72px;
    z-index: 24;
    padding: 0 0 8px;
    border-radius: 0;
    background: transparent;
    backdrop-filter: none;
    box-shadow: none;
  }

  .builder-page .diy-preview-stage {
    max-width: min(82vw, 320px);
  }

  .builder-page .diy-preview-side-notes {
    left: 10px;
    right: 10px;
    bottom: 8px;
    gap: 8px;
  }

  .builder-page .diy-preview-side-note--rope {
    flex: 1 1 auto;
  }

  .builder-page .diy-preview-side-notes span {
    font-size: 0.4rem;
    letter-spacing: 0.04em;
  }

  .builder-page .diy-preview-side-notes strong {
    font-size: 0.54rem;
  }

  .builder-page .diy-component-section {
    margin-top: 6px;
    scroll-margin-top: 124px;
  }

  .builder-page .diy-filter-summary {
    padding: 12px 12px 10px;
  }

  .builder-page .diy-filter-body {
    gap: 12px;
    padding: 0 12px 12px;
  }

  .builder-page .diy-filter-label {
    display: none;
  }

  .builder-page [data-category-filters] {
    gap: 6px;
  }

  .builder-page [data-material-filters] {
    gap: 5px;
  }

  .builder-page .diy-filter-toolbar {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
  }

  .builder-page .diy-component-search {
    min-height: 32px;
    padding: 0 9px;
  }

  .builder-page .diy-component-search input {
    font-size: 0.62rem;
  }

  .builder-page .diy-result-count {
    justify-self: start;
    min-height: 26px;
    padding: 0 8px;
    font-size: 0.56rem;
  }

  .builder-page .diy-filter-chip--category {
    min-height: 32px;
    gap: 4px;
    padding: 0 8px;
  }

  .builder-page .diy-filter-chip--material,
  .builder-page .diy-filter-chip--diameter {
    min-height: 30px;
    padding: 0 8px;
    border-radius: 11px;
  }

  .builder-page .diy-filter-chip-icon {
    width: 15px;
    height: 15px;
  }

  .builder-page .diy-filter-chip--category .diy-filter-chip-text {
    font-size: 0.58rem;
  }

  .builder-page .diy-filter-chip--material .diy-filter-chip-text,
  .builder-page .diy-filter-chip--diameter .diy-filter-chip-text {
    font-size: 0.58rem;
  }

  .builder-page .diy-component-grid {
    max-height: none;
    gap: 8px 6px;
  }

  .builder-page .diy-component-grid.is-dense-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .builder-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 8px;
  }

  .builder-page .diy-card {
    border-radius: 16px;
    padding: 7px 6px;
  }

  .builder-page .diy-card-thumb {
    border-radius: 14px;
    padding: 8px;
  }

  .builder-page .diy-card--compact {
    padding: 5px;
    border-radius: 14px;
  }

  .builder-page .diy-card--compact .diy-card-thumb {
    min-height: 46px;
    padding: 4px;
    border-radius: 11px;
  }

  .builder-page .diy-card-copy strong {
    min-height: 2.5em;
    font-size: 0.7rem;
  }

  .builder-page .diy-card--compact .diy-card-copy strong {
    min-height: auto;
    font-size: 0.62rem;
  }

  .builder-page .diy-card-price {
    font-size: 0.78rem;
  }

  .builder-page .diy-card-meta {
    font-size: 0.58rem;
  }

  .builder-page .diy-card--compact .diy-card-copy strong {
    min-height: 2.3em;
    font-size: 0.58rem;
    line-height: 1.14;
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
  }

  .builder-page .diy-card--compact .diy-card-meta-row,
  .builder-page .diy-card--rope .diy-card-meta-row {
    display: none !important;
  }

  .builder-page .diy-card--compact .diy-card-copy,
  .builder-page .diy-card--rope .diy-card-copy {
    padding-top: 0 !important;
  }

  .builder-page .diy-card-overlay--left {
    font-size: 0.42rem;
  }

  .builder-page .diy-card-overlay--right {
    font-size: 0.44rem;
  }

  .builder-page .diy-card-qty-count {
    font-size: 0.54rem;
  }
}

@media (max-width: 359px) {
  .builder-page [data-category-filters],
  .builder-page [data-material-filters],
  .builder-page .diy-component-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .builder-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.diy-share-modal[hidden] {
  display: none;
}

.diy-share-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
}

.diy-share-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 16, 18, 0.18);
}

.diy-share-dialog {
  position: relative;
  z-index: 1;
  width: min(92vw, 560px);
  margin: min(10vh, 72px) auto 0;
  padding: 22px 22px 20px;
  max-height: calc(100vh - 96px);
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid rgba(218, 210, 206, 0.96);
  background: #fff;
  box-shadow: none;
}

.diy-share-close {
  position: absolute;
  top: 12px;
  right: 14px;
  z-index: 2;
  min-width: 28px;
  min-height: 28px;
  padding: 4px;
  border: 0;
  background: none;
  color: var(--cocoa);
  font-size: 1rem;
  line-height: 1;
}

.diy-share-dialog-head h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--cocoa);
}

.diy-share-dialog-head p {
  margin: 4px 0 0;
  font-size: 0.72rem;
  color: rgba(109, 91, 93, 0.72);
}

.diy-share-poster {
  margin-top: 14px;
  display: grid;
  gap: 14px;
  padding: 0;
  border: 0;
  background: none;
}

.diy-share-poster-head,
.diy-share-poster-title-row,
.diy-share-poster-footer {
  position: static;
}

.diy-share-poster-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.diy-share-poster-brand {
  font-size: 0.62rem;
  letter-spacing: 0.24em;
  color: #9f7a70;
}

.diy-share-poster-kicker {
  font-size: 0.68rem;
  color: rgba(109, 91, 93, 0.7);
}

.diy-share-poster-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.diy-share-poster-title-copy h4 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.5rem;
  line-height: 0.96;
  color: var(--cocoa);
}

.diy-share-poster-title-copy p {
  margin: 6px 0 0;
  font-size: 0.74rem;
  color: rgba(109, 91, 93, 0.76);
}

.diy-share-poster-price {
  flex: 0 0 auto;
  padding-top: 4px;
  font-size: 0.98rem;
  color: var(--cocoa);
}

.diy-share-poster-stage {
  padding: 18px 0;
  border-top: 1px solid rgba(226, 217, 213, 0.92);
  border-bottom: 1px solid rgba(226, 217, 213, 0.92);
}

.diy-share-card-image,
.diy-share-result-media img {
  display: block;
  width: min(100%, 420px);
  margin: 0 auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border: 0;
  background: #fff;
}

.diy-share-result-media {
  position: relative;
  display: grid;
  place-items: center;
  min-height: min(72vw, 420px);
  background: #fff;
}

.diy-generate-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 42px;
  height: 42px;
  margin: -21px 0 0 -21px;
  border: 2px solid rgba(214, 198, 191, 0.72);
  border-top-color: var(--rose);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
  animation: diy-spinner-rotate 0.8s linear infinite;
  transition: opacity var(--transition);
}

.diy-share-poster-footer {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 12px;
  padding-top: 2px;
  border-top: 1px solid rgba(226, 217, 213, 0.92);
  padding-top: 12px;
}

.diy-share-poster-detail {
  flex: 1 1 0;
  display: grid;
  gap: 4px;
  padding: 0;
  border: 0;
  background: none;
}

.diy-share-poster-detail span,
.diy-share-result-label,
.diy-share-status {
  font-size: 0.72rem;
  color: rgba(109, 91, 93, 0.78);
}

.diy-share-poster-detail strong {
  font-size: 0.84rem;
  letter-spacing: 0.08em;
  color: var(--cocoa);
}

.diy-share-result {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(226, 217, 213, 0.92);
}

.diy-share-link {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(226, 217, 213, 0.92);
}

.diy-share-link-head {
  display: grid;
  gap: 4px;
}

.diy-share-link-head strong {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(109, 91, 93, 0.82);
}

.diy-share-link-head p {
  margin: 0;
  font-size: 0.72rem;
  color: rgba(109, 91, 93, 0.7);
}

.diy-share-link-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.diy-share-link-field {
  min-width: 0;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  background: rgba(255, 251, 248, 0.96);
  color: var(--cocoa);
  font-size: 0.78rem;
}

.diy-share-link-field:focus {
  outline: none;
  border-color: rgba(239, 143, 164, 0.66);
}

.diy-share-link-button {
  min-height: 44px;
  padding-inline: 18px;
  border-radius: 999px;
  border: 1px solid rgba(239, 143, 164, 0.36);
  background: rgba(255, 245, 247, 0.96);
  color: #cf7086;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  box-shadow: none;
}

.diy-share-modal[data-generating="true"] .diy-generate-spinner {
  opacity: 1;
}

.diy-share-modal[data-mode="generate"] .diy-share-poster {
  display: none;
}

.diy-share-modal[data-mode="share"] .diy-share-result[hidden] {
  display: none;
}

.diy-share-result-label {
  margin: 0 0 8px;
}

.diy-share-status {
  min-height: 1.2em;
  margin: 12px 0 0;
}

@media (max-width: 767px) {
  .diy-share-dialog {
    width: min(86vw, 420px);
    margin: 52px auto 0;
    padding: 16px 16px 14px;
    max-height: calc(100vh - 104px);
  }

  .diy-share-close {
    top: 8px;
    right: 8px;
    min-width: 32px;
    min-height: 32px;
    font-size: 0.96rem;
  }

  .diy-share-dialog-head h3 {
    font-size: 0.92rem;
    line-height: 1.2;
  }

  .diy-share-dialog-head p {
    font-size: 0.66rem;
  }

  .diy-share-poster {
    margin-top: 10px;
    gap: 10px;
  }

  .diy-share-poster-head,
  .diy-share-poster-title-row,
  .diy-share-poster-footer {
    gap: 8px;
  }

  .diy-share-poster-title-copy h4 {
    font-size: 1.18rem;
  }

  .diy-share-poster-title-copy p,
  .diy-share-poster-kicker,
  .diy-share-poster-brand {
    font-size: 0.62rem;
  }

  .diy-share-poster-price {
    font-size: 0.86rem;
  }

  .diy-share-poster-stage {
    padding: 10px 0;
  }

  .diy-share-card-image,
  .diy-share-result-media img {
    width: min(100%, 288px);
  }

  .diy-share-result {
    margin-top: 10px;
    padding-top: 10px;
  }

  .diy-share-link {
    margin-top: 10px;
    padding-top: 10px;
  }

  .diy-share-link-row {
    grid-template-columns: 1fr;
  }

  .diy-share-link-field,
  .diy-share-link-button {
    min-height: 40px;
    font-size: 0.72rem;
  }

  .diy-share-result-media {
    min-height: min(58vw, 288px);
  }

  .diy-share-poster-detail span,
  .diy-share-result-label,
  .diy-share-status {
    font-size: 0.66rem;
  }

  .diy-share-poster-detail strong {
    font-size: 0.76rem;
  }

  .diy-mockup-panel {
    border-radius: 20px;
  }

  .diy-mockup-image {
    border-radius: 20px;
  }

  .diy-lightbox-dialog {
    width: min(94vw, 480px);
    padding: 12px;
  }
}

@keyframes diy-spinner-rotate {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@media (min-width: 768px) {
  .builder-page .diy-length-bar {
    padding: 12px 0 16px;
  }

  .builder-page .diy-preview-stage {
    max-width: 700px;
  }

  .builder-page .diy-preview-side-notes {
    top: auto;
    left: 14px;
    right: 14px;
    bottom: 12px;
    width: auto;
    max-width: none;
  }

  .builder-page .diy-component-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    max-height: 340px;
  }

  .builder-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .diy-share-dialog {
    padding: 20px;
  }
}

@media (min-width: 1024px) {
  .builder-page .diy-preview-panel {
    gap: 10px;
  }

  .builder-page .diy-component-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    max-height: 360px;
  }

  .builder-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ========== Builder Entry ========== */
.builder-entry-shell {
  display: grid;
  gap: 18px;
  align-items: center;
}

.builder-entry-copy p:last-of-type {
  margin: 10px 0 0;
  font-size: 0.92rem;
  line-height: 1.65;
}

.builder-entry-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 18px;
}

.builder-entry-art {
  border: 1px solid rgba(231, 212, 202, 0.9);
  border-radius: 18px;
  background: linear-gradient(180deg, #fff9f5 0%, #f9ece5 100%);
  overflow: hidden;
}

.builder-entry-art--video {
  min-height: 320px;
  background: #f7eee8;
}

.builder-entry-video {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
}

.builder-entry-stage {
  position: relative;
  min-height: 320px;
}

.builder-entry-rope {
  position: absolute;
  inset: 10%;
  width: 80%;
  height: 80%;
  margin: auto;
  object-fit: contain;
}

.builder-entry-bead {
  position: absolute;
  filter: drop-shadow(0 5px 10px rgba(110, 90, 82, 0.12));
}

.builder-entry-stage .bead-one {
  width: 52px;
  left: 50%;
  top: 8%;
  transform: translateX(-50%);
}

.builder-entry-stage .bead-two {
  width: 62px;
  right: 15%;
  top: 22%;
}

.builder-entry-stage .bead-three {
  width: 68px;
  right: 20%;
  bottom: 17%;
}

.builder-entry-stage .bead-four {
  width: 48px;
  left: 18%;
  bottom: 20%;
}

@media (min-width: 768px) {
  .builder-entry-shell {
    grid-template-columns: minmax(0, 0.9fr) minmax(340px, 1.1fr);
  }

  .builder-entry-actions {
    flex-direction: row;
  }
}

@media (max-width: 767px) {
  .builder-entry-art--video,
  .builder-entry-video {
    min-height: 230px;
  }
}

/* ========== Desktop Window Adaptation ========== */
@media (min-width: 1024px) and (max-width: 1199px) {
  .shell {
    width: calc(100% - 64px);
  }

  .header-row {
    gap: 18px;
    min-height: 72px;
  }

  .brand-logo {
    width: 210px;
  }

  .brand-tag {
    font-size: 0.52rem;
    letter-spacing: 0.22em;
  }

  .site-nav {
    gap: 8px 10px;
  }

  .site-nav a {
    padding: 8px 10px;
    font-size: 0.76rem;
    letter-spacing: 0.08em;
  }

  .header-actions {
    gap: 6px;
  }

  .language-option {
    min-width: 44px;
    height: 30px;
    padding: 0 10px;
    font-size: 0.64rem;
  }

  .icon-button {
    width: 36px;
    height: 36px;
  }

  .hero-carousel {
    min-height: 540px;
    aspect-ratio: 14 / 7;
  }

  .hero-mask {
    width: min(58%, 620px);
  }

  .hero-copy {
    max-width: 440px;
    padding: 0 0 32px 24px;
  }

  .hero-copy h1 {
    font-size: 2.75rem;
  }

  .hero-title-accent {
    font-size: 2.28rem;
  }

  .hero-actions {
    gap: 12px;
    margin-top: 22px;
  }

  .hero-seal {
    width: 96px;
    height: 96px;
    right: 28px;
    bottom: 28px;
  }

  .hero-indicators {
    right: 132px;
    bottom: 26px;
  }

  .steps-layout {
    gap: 26px;
  }

  .steps-visual {
    flex: 0 0 300px;
  }

  .collection-card {
    padding: 16px;
  }

  .testimonial-card {
    padding-right: 18px;
  }

  .footer-grid {
    grid-template-columns: 0.95fr 0.95fr 1.1fr;
    gap: 24px;
  }

  .builder-entry-shell {
    grid-template-columns: minmax(0, 0.96fr) minmax(320px, 1.04fr);
    gap: 24px;
  }

  .builder-page .builder-shell {
    max-width: 1040px;
  }

  .builder-page .diy-length-bar {
    padding: 12px 0 16px;
    gap: 18px;
  }

  .builder-page .diy-top {
    display: grid;
    grid-template-columns: minmax(0, 1.02fr) minmax(300px, 0.98fr);
    gap: 22px;
    align-items: start;
  }

  .builder-page .diy-preview-panel {
    position: sticky;
    top: 92px;
    gap: 10px;
  }

  .builder-page .diy-preview-stage {
    max-width: 560px;
  }

  .builder-page .diy-preview-side-notes {
    left: 14px;
    right: 14px;
    bottom: 12px;
    width: auto;
    max-width: none;
  }

  .builder-page .diy-filter-summary {
    padding: 10px 12px;
  }

  .builder-page .diy-component-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    max-height: 420px;
  }

  .builder-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .builder-page .diy-summary-card--footer {
    padding: 18px;
  }

  .builder-page .diy-summary-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 24px;
  }

  .builder-page .summary-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .builder-page .summary-actions .button {
    flex: 1 1 0;
    min-width: 160px;
  }
}

@media (min-width: 1200px) and (max-width: 1439px) {
  .shell {
    width: calc(100% - 88px);
    max-width: 1320px;
  }

  .header-row {
    gap: 26px;
    min-height: 78px;
  }

  .site-nav {
    gap: 12px 18px;
  }

  .site-nav a {
    padding: 8px 12px;
    font-size: 0.81rem;
  }

  .hero-carousel {
    min-height: 580px;
    aspect-ratio: 15 / 6;
  }

  .hero-mask {
    width: min(54%, 680px);
  }

  .hero-copy {
    max-width: 500px;
    padding: 0 0 40px 32px;
  }

  .hero-copy h1 {
    font-size: 3.15rem;
  }

  .hero-title-accent {
    font-size: 2.6rem;
  }

  .hero-seal {
    width: 108px;
    height: 108px;
    right: 40px;
    bottom: 30px;
  }

  .hero-indicators {
    right: 170px;
    bottom: 30px;
  }

  .builder-entry-shell {
    gap: 28px;
  }

  .builder-page .builder-shell {
    max-width: 1160px;
  }

  .builder-page .diy-top {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(350px, 0.92fr);
    gap: 30px;
    align-items: start;
  }

  .builder-page .diy-preview-panel {
    top: 100px;
    gap: 10px;
  }

  .builder-page .diy-preview-stage {
    max-width: 620px;
  }

  .builder-page .diy-preview-side-notes {
    left: 14px;
    right: 14px;
    bottom: 12px;
    width: auto;
    max-width: none;
  }

  .builder-page .diy-summary-card--footer {
    padding: 20px;
  }

  .builder-page .diy-summary-list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px 18px;
  }

  .builder-page .summary-actions {
    flex-direction: row;
  }

  .builder-page .summary-actions .button {
    flex: 1 1 0;
  }

  .builder-page .diy-component-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    max-height: 430px;
  }

  .builder-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1440px) {
  .shell {
    width: calc(100% - 112px);
    max-width: 1360px;
  }

  .header-row {
    gap: 34px;
    min-height: 82px;
  }

  .site-nav {
    gap: 16px 24px;
  }

  .hero {
    padding-top: 18px;
  }

  .hero-carousel {
    min-height: 640px;
    aspect-ratio: 16 / 6;
  }

  .hero-mask {
    width: min(48%, 720px);
  }

  .hero-copy {
    max-width: 560px;
    padding: 0 0 44px 40px;
  }

  .hero-copy h1 {
    font-size: 3.5rem;
  }

  .hero-title-accent {
    font-size: 2.95rem;
  }

  .hero-seal {
    right: 52px;
    bottom: 34px;
  }

  .hero-indicators {
    right: 190px;
    bottom: 34px;
  }

  .builder-entry-shell {
    grid-template-columns: minmax(0, 0.9fr) minmax(420px, 1.1fr);
    gap: 32px;
  }

  .builder-page .builder-shell {
    max-width: 1240px;
  }

  .builder-page .diy-top {
    display: grid;
    grid-template-columns: minmax(0, 1.14fr) minmax(390px, 0.86fr);
    gap: 42px;
    align-items: start;
  }

  .builder-page .diy-preview-panel {
    top: 108px;
  }

  .builder-page .diy-preview-stage {
    max-width: 680px;
  }

  .builder-page .diy-component-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    max-height: 460px;
  }
}

/* ========== Builder Responsive Stage / Panel Layout ========== */
@media (max-width: 1023px) {
  .builder-page .diy-workbench,
  .builder-page .diy-preview-panel {
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }

  .builder-page .diy-preview-card {
    align-self: stretch;
  }

  .builder-page .diy-component-section {
    width: 100%;
  }
}

@media (min-width: 1024px) {
  .builder-page .diy-top {
    display: block;
    width: 100%;
  }

  .builder-page .diy-workbench {
    width: 100%;
  }

  .builder-page .diy-preview-panel {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(20px, 2vw, 32px);
    align-items: start;
    position: relative;
    top: auto;
  }

  .builder-page .diy-preview-card {
    position: sticky;
    top: 92px;
    align-self: start;
    width: 100%;
  }

  .builder-page .diy-preview-stage {
    width: 100%;
    max-width: none;
    margin: 0;
  }

  .builder-page .diy-component-section {
    width: 100%;
    margin-top: 0;
  }

  .builder-page [data-category-filters] {
    grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
  }

  .builder-page [data-material-filters] {
    grid-template-columns: repeat(auto-fit, minmax(108px, 1fr));
  }

  .builder-page .diy-component-grid {
    gap: 8px;
    max-height: none;
  }

  .builder-page .diy-component-grid.is-dense-grid {
    grid-template-columns: repeat(auto-fit, minmax(108px, 1fr));
  }

  .builder-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
  }
}

@media (min-width: 1280px) {
  .builder-page .diy-preview-card {
    top: 100px;
  }
}

@media (min-width: 1440px) {
  .builder-page .diy-preview-card {
    top: 108px;
  }
}

/* Shopify theme hardening: keep the DIY builder layout stable even when the
   section is added to a normal page instead of the dedicated template. */
.giftherspace-diy-page #top {
  overflow: visible;
}

.giftherspace-diy-page .builder-section {
  width: 100%;
  padding: clamp(28px, 4vw, 56px) 0 clamp(48px, 6vw, 84px);
}

.giftherspace-diy-page .builder-shell {
  width: calc(100% - 32px);
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  gap: 18px;
}

.giftherspace-diy-page .diy-length-bar {
  --diy-panel-radius: 18px;
  --diy-stage-radius: 16px;
  --diy-inner-radius: 14px;
  width: 100%;
  margin: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  padding: 18px 22px;
  border: 1px solid rgba(239, 223, 215, 0.95);
  border-radius: var(--diy-panel-radius);
  background: linear-gradient(180deg, rgba(255, 251, 248, 0.96) 0%, rgba(255, 255, 255, 0.98) 100%);
}

.giftherspace-diy-page .diy-top,
.giftherspace-diy-page .diy-workbench {
  width: 100%;
  min-width: 0;
}

.giftherspace-diy-page .diy-preview-panel {
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.giftherspace-diy-page .diy-preview-card,
.giftherspace-diy-page .diy-filter-drawer,
.giftherspace-diy-page .diy-summary-card--footer {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(239, 223, 215, 0.95);
  border-radius: var(--diy-panel-radius);
  background: rgba(255, 253, 251, 0.96);
  box-shadow: none;
}

.giftherspace-diy-page .diy-preview-card {
  padding: 0;
  border: 0;
  background: transparent;
}

.giftherspace-diy-page .diy-preview-stage {
  width: 100%;
  max-width: none;
  margin: 0 auto;
}

.giftherspace-diy-page .diy-component-section {
  width: 100%;
  min-width: 0;
  margin: 0;
}

.giftherspace-diy-page .diy-component-browser {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.giftherspace-diy-page .diy-filter-drawer {
  overflow: hidden;
}

.giftherspace-diy-page .diy-filter-body {
  display: grid;
  gap: 14px;
}

.giftherspace-diy-page [data-category-filters],
.giftherspace-diy-page [data-material-filters],
.giftherspace-diy-page .diy-component-grid {
  width: 100%;
  min-width: 0;
}

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

.giftherspace-diy-page .diy-component-grid.is-dense-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.giftherspace-diy-page .diy-component-grid.is-rope-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.giftherspace-diy-page .diy-card,
.giftherspace-diy-page .diy-card--compact,
.giftherspace-diy-page .diy-card--rope {
  min-width: 0;
  border-radius: 14px;
}

.giftherspace-diy-page .diy-card-thumb {
  min-height: 0;
}

.giftherspace-diy-page .diy-card-copy strong {
  word-break: normal;
  overflow-wrap: anywhere;
}

.giftherspace-diy-page .diy-summary-card--footer {
  margin-top: 0;
  padding: clamp(16px, 2vw, 22px);
}

.giftherspace-diy-page .summary-actions {
  width: 100%;
}

@media (min-width: 700px) {
  .giftherspace-diy-page .builder-shell {
    width: calc(100% - 48px);
    gap: 22px;
  }

  .giftherspace-diy-page .diy-component-grid,
  .giftherspace-diy-page .diy-component-grid.is-dense-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .giftherspace-diy-page .builder-shell {
    gap: 24px;
  }

  .giftherspace-diy-page .diy-preview-panel {
    grid-template-columns: minmax(500px, 1.02fr) minmax(0, 0.98fr);
    gap: 24px;
  }

  .giftherspace-diy-page .diy-preview-card {
    position: sticky;
    top: 104px;
  }

  .giftherspace-diy-page .diy-preview-stage {
    width: 100%;
    max-width: 640px;
  }

  .giftherspace-diy-page .diy-component-grid,
  .giftherspace-diy-page .diy-component-grid.is-dense-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .giftherspace-diy-page .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (min-width: 1280px) {
  .giftherspace-diy-page .diy-preview-panel {
    grid-template-columns: minmax(560px, 1.02fr) minmax(0, 0.98fr);
    gap: 32px;
  }
}

.giftherspace-diy-root,
.giftherspace-diy-root * {
  box-sizing: border-box;
}

.giftherspace-diy-root {
  width: 100%;
  isolation: isolate;
}

.giftherspace-diy-root svg {
  display: block;
  max-width: 100%;
  max-height: 100%;
}

.giftherspace-diy-root button,
.giftherspace-diy-root input {
  font: inherit;
}

.giftherspace-diy-root .builder-section {
  padding-top: clamp(20px, 3vw, 40px);
}

.giftherspace-diy-root .builder-shell {
  max-width: 1240px;
}

.giftherspace-diy-root .diy-preview-panel {
  align-items: start;
}

.giftherspace-diy-root .diy-length-bar-copy h3 {
  max-width: 320px;
  font-size: 0.96rem;
  font-weight: 700;
  line-height: 1.35;
  color: rgba(109, 91, 93, 0.82);
}

.giftherspace-diy-root .diy-length-field {
  display: grid;
  justify-items: center;
  gap: 6px;
}

.giftherspace-diy-root .diy-length-input-wrap {
  min-width: 176px;
  padding: 4px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.giftherspace-diy-root .diy-length-input-wrap input {
  width: 58px;
  font-size: 0.98rem;
  font-weight: 800;
  text-align: center;
}

.giftherspace-diy-root .diy-length-unit {
  min-width: 34px;
  padding: 0 7px;
  border-radius: 999px;
  background: rgba(249, 232, 237, 0.82);
  color: #b96a7e;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
}

.giftherspace-diy-root .diy-length-step {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 250, 247, 0.98) 0%, rgba(255, 255, 255, 1) 100%);
  color: var(--cocoa);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
}

.giftherspace-diy-root .diy-length-step:hover,
.giftherspace-diy-root .diy-length-step:focus-visible {
  border-color: rgba(239, 143, 164, 0.8);
  color: #cf7086;
}

.giftherspace-diy-root .diy-length-hint {
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.45;
  color: rgba(109, 91, 93, 0.72);
  text-align: center;
}

.giftherspace-diy-root .diy-length-presets {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.giftherspace-diy-root .diy-length-preset {
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--cocoa);
  font-size: 0.66rem;
  font-weight: 700;
}

.giftherspace-diy-root .diy-length-preset.is-active {
  border-color: rgba(239, 143, 164, 0.88);
  background: rgba(251, 228, 235, 0.86);
  color: #cf7086;
}

.giftherspace-diy-root .diy-filter-drawer {
  border-radius: var(--diy-panel-radius);
}

.giftherspace-diy-root .diy-filter-summary {
  min-height: 54px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid rgba(239, 223, 215, 0.9);
}

.giftherspace-diy-root .diy-filter-body {
  padding: clamp(16px, 2vw, 22px);
}

.giftherspace-diy-root .diy-filter-group {
  display: grid;
  gap: 10px;
}

.giftherspace-diy-root .diy-filter-inline-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.giftherspace-diy-root .diy-filter-inline-row--material .diy-filter-chips {
  flex: 1 1 auto;
  min-width: 0;
}

.giftherspace-diy-root .diy-filter-label {
  display: block;
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  line-height: 1;
  margin: 0;
  color: rgba(109, 91, 93, 0.72);
}

.giftherspace-diy-root [data-category-filters] {
  display: flex !important;
  flex-wrap: nowrap;
  gap: 6px !important;
  overflow-x: auto;
  scrollbar-width: none;
  min-width: 0;
}

.giftherspace-diy-root [data-material-filters] {
  display: flex !important;
  flex-wrap: nowrap;
  gap: 6px !important;
  overflow-x: auto;
  scrollbar-width: none;
  min-width: 0;
}

.giftherspace-diy-root [data-category-filters]::-webkit-scrollbar,
.giftherspace-diy-root [data-material-filters]::-webkit-scrollbar {
  display: none;
}

.giftherspace-diy-root .diy-filter-chip {
  min-width: 0;
  flex: 0 0 auto;
  margin: 0;
  transform: none !important;
}

.giftherspace-diy-root .diy-filter-chip--category {
  width: auto;
  height: 30px;
  min-height: 30px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px solid rgba(231, 212, 202, 0.96);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
}

.giftherspace-diy-root .diy-filter-chip--material,
.giftherspace-diy-root .diy-filter-chip--diameter {
  width: auto;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.68rem;
  background: rgba(255, 255, 255, 0.92);
}

.giftherspace-diy-root .diy-filter-chip-icon {
  width: 13px !important;
  height: 13px !important;
  max-width: 13px !important;
  max-height: 13px !important;
}

.giftherspace-diy-root .diy-filter-chip-icon svg {
  width: 13px !important;
  height: 13px !important;
  max-width: 13px !important;
  max-height: 13px !important;
  stroke-width: 1.8;
}

.giftherspace-diy-root .diy-step-index {
  display: none;
}

.giftherspace-diy-root .diy-filter-chip-text {
  width: auto;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  white-space: nowrap;
  font-size: 0.66rem !important;
  line-height: 1 !important;
  font-weight: 700;
}

.giftherspace-diy-root .diy-filter-chip.is-active {
  border-color: rgba(239, 143, 164, 0.88);
  background: rgba(251, 228, 235, 0.78);
  box-shadow: none;
}

.giftherspace-diy-root .diy-filter-chip.is-active .diy-step-index,
.giftherspace-diy-root .diy-filter-chip.is-active .diy-filter-chip-text {
  color: #cf7086;
}

.giftherspace-diy-root .diy-filter-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.giftherspace-diy-root .diy-component-search {
  height: 42px;
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 14px;
  border-radius: 999px;
}

.giftherspace-diy-root .diy-component-search--inline {
  width: 42px;
  min-width: 42px;
  padding: 0;
  border-color: transparent;
  background: transparent;
  overflow: hidden;
  cursor: text;
  transition:
    width 180ms ease,
    min-width 180ms ease,
    border-color var(--transition),
    color var(--transition);
}

.giftherspace-diy-root .diy-component-search--inline.is-open,
.giftherspace-diy-root .diy-component-search--inline:focus-within {
  width: 168px;
  min-width: 168px;
  padding: 0 12px;
  border-color: rgba(231, 212, 202, 0.96);
  background: rgba(255, 255, 255, 0.96);
}

.giftherspace-diy-root .diy-component-search-icon {
  width: 18px !important;
  height: 18px !important;
  flex: 0 0 18px !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
}

.giftherspace-diy-root .diy-component-search--inline .diy-component-search-icon {
  width: 42px !important;
  height: 42px !important;
  flex-basis: 42px !important;
}

.giftherspace-diy-root .diy-component-search-icon svg {
  width: 18px !important;
  height: 18px !important;
  max-width: 18px !important;
  max-height: 18px !important;
}

.giftherspace-diy-root .diy-component-search input {
  min-width: 0;
  height: auto;
  padding: 0;
  border: 0;
  box-shadow: none;
  outline: none;
}

.giftherspace-diy-root .diy-component-search--inline input {
  width: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 140ms ease;
}

.giftherspace-diy-root .diy-component-search--inline.is-open input,
.giftherspace-diy-root .diy-component-search--inline:focus-within input {
  width: 100%;
  opacity: 1;
  pointer-events: auto;
}

.giftherspace-diy-root .diy-result-count {
  white-space: nowrap;
}

.giftherspace-diy-root .diy-component-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 12px !important;
  align-items: stretch;
  padding-top: 4px;
}

.giftherspace-diy-root .diy-component-grid.is-dense-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.giftherspace-diy-root .diy-component-grid.is-rope-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.giftherspace-diy-root .diy-card {
  min-width: 0;
  height: 100%;
  padding: 7px 6px;
  border-radius: 14px;
}

.giftherspace-diy-root .diy-card-thumb {
  width: 100%;
  min-width: 0;
  aspect-ratio: 1 / 1;
  padding: 5px;
  border-radius: 12px;
}

.giftherspace-diy-root .diy-card-thumb img {
  width: 88% !important;
  height: 88% !important;
  max-width: 88% !important;
  max-height: 88% !important;
  object-fit: contain;
  -webkit-user-drag: none;
  user-select: none;
  pointer-events: none;
}

.giftherspace-diy-root .diy-card-copy strong {
  min-height: 2.1em;
  font-size: 0.66rem;
  line-height: 1.16;
}

.giftherspace-diy-root .diy-card--compact .diy-card-copy strong,
.giftherspace-diy-root .diy-card--rope .diy-card-copy strong {
  min-height: 2.15em;
  white-space: normal;
  text-align: center;
  -webkit-line-clamp: 2;
}

.giftherspace-diy-root .diy-card--compact .diy-card-meta-row,
.giftherspace-diy-root .diy-card--rope .diy-card-meta-row {
  display: none;
}

.giftherspace-diy-root .diy-card--compact .diy-card-meta,
.giftherspace-diy-root .diy-card--rope .diy-card-meta {
  font-size: 0.54rem;
  line-height: 1;
  white-space: nowrap;
}

.giftherspace-diy-root .diy-card--rope .diy-card-main {
  gap: 5px;
}

.giftherspace-diy-root .diy-card--rope .diy-card-thumb {
  aspect-ratio: 1 / 1;
  padding: 5px;
}

.giftherspace-diy-root .diy-card-price-line {
  font-size: 0.58rem;
}

.giftherspace-diy-root .diy-card-material-tab {
  font-size: 0.42rem;
  padding: 4px 1px;
}

.giftherspace-diy-root .diy-preview-stage {
  min-height: 0;
  height: auto;
  aspect-ratio: 1 / 1;
  border-radius: var(--diy-stage-radius);
}

.giftherspace-diy-root .diy-preview-card {
  align-self: start;
}

.giftherspace-diy-root .diy-summary-card--footer {
  border-radius: var(--diy-panel-radius);
}

@media (max-width: 699px) {
  .giftherspace-diy-root .builder-shell {
    width: calc(100% - 24px);
  }

  .giftherspace-diy-page .diy-length-bar {
    grid-template-columns: 1fr;
    justify-items: stretch;
    gap: 8px;
    padding: 10px 12px;
  }

  .giftherspace-diy-root .diy-length-bar-copy h3 {
    max-width: none;
  }

  .giftherspace-diy-root .diy-length-presets {
    justify-content: flex-start;
  }

  .giftherspace-diy-root .diy-preview-card,
  .builder-page .diy-preview-card {
    width: 100%;
    align-self: stretch;
  }

  .giftherspace-diy-root .diy-preview-stage,
  .builder-page .diy-preview-stage {
    display: block;
    width: 100% !important;
    max-width: none !important;
    min-width: 0;
    min-height: 0 !important;
    height: auto !important;
    aspect-ratio: 1 / 1 !important;
  }

  .giftherspace-diy-root .diy-preview-side-notes,
  .builder-page .diy-preview-side-notes {
    position: static;
    top: auto;
    left: auto;
    right: auto;
    transform: none;
    width: 100%;
    max-width: none;
    margin-top: 8px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
    padding: 0;
    background: transparent;
    backdrop-filter: none;
  }

  .giftherspace-diy-root .diy-preview-side-notes span,
  .builder-page .diy-preview-side-notes span {
    font-size: 0.4rem;
    line-height: 1.15;
    letter-spacing: 0.04em;
  }

  .giftherspace-diy-root .diy-preview-side-notes strong,
  .builder-page .diy-preview-side-notes strong {
    font-size: 0.52rem;
    line-height: 1.14;
    word-break: break-word;
  }

  .giftherspace-diy-root .diy-preview-side-note--rope,
  .builder-page .diy-preview-side-note--rope {
    grid-column: 1 / -1;
  }

  .giftherspace-diy-root .diy-preview-side-notes p,
  .builder-page .diy-preview-side-notes p {
    min-height: 0;
    padding: 6px 7px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 18px rgba(82, 57, 66, 0.06);
  }

  .giftherspace-diy-root .diy-preview-side-notes em,
  .builder-page .diy-preview-side-notes em {
    font-size: 0.45rem;
    line-height: 1.12;
    color: rgba(109, 91, 93, 0.84);
  }

  .giftherspace-diy-root [data-category-filters] {
    justify-content: flex-start;
    gap: 4px !important;
  }

  .giftherspace-diy-root .diy-filter-chip--category {
    height: 30px;
    min-height: 30px;
    padding: 0 9px;
    border-radius: 12px;
  }

  .giftherspace-diy-root .diy-filter-inline-row {
    gap: 6px;
  }

  .giftherspace-diy-root .diy-component-search--inline {
    width: 34px;
    min-width: 34px;
    padding: 0;
  }

  .giftherspace-diy-root .diy-component-search--inline.is-open,
  .giftherspace-diy-root .diy-component-search--inline:focus-within {
    width: 116px;
    min-width: 116px;
    padding: 0 9px;
  }

  .giftherspace-diy-root .diy-component-search--inline .diy-component-search-icon {
    width: 34px !important;
    height: 34px !important;
    flex-basis: 34px !important;
  }

  .giftherspace-diy-root .diy-filter-chip-icon,
  .giftherspace-diy-root .diy-filter-chip-icon svg {
    width: 11px !important;
    height: 11px !important;
  }

  .giftherspace-diy-root .diy-filter-chip-text {
    font-size: 0.56rem !important;
  }

  .giftherspace-diy-root .diy-filter-chip--material,
  .giftherspace-diy-root .diy-filter-chip--diameter {
    min-height: 30px;
    padding: 0 9px;
    border-radius: 12px;
  }

  .giftherspace-diy-root [data-material-filters] {
    gap: 4px !important;
  }

  .giftherspace-diy-root .diy-component-section {
    width: calc(100% + 24px);
    margin-left: -12px;
    margin-right: -12px;
  }

  .giftherspace-diy-root .diy-filter-body {
    padding-left: 8px;
    padding-right: 8px;
  }

  .giftherspace-diy-root .diy-component-browser {
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 5px;
  }

  .giftherspace-diy-root .diy-material-rail {
    gap: 4px;
  }

  .giftherspace-diy-root .diy-material-rail-button {
    min-height: 30px;
    padding: 3px 4px;
    border-radius: 12px;
    font-size: 0.46rem;
    line-height: 1.06;
    letter-spacing: 0;
  }

  .giftherspace-diy-root .diy-result-count {
    justify-self: start;
  }

  .giftherspace-diy-root .diy-component-grid,
  .giftherspace-diy-root .diy-component-grid.is-dense-grid,
  .giftherspace-diy-root .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px 4px !important;
  }

  .giftherspace-diy-root .diy-card {
    padding: 4px;
    border-radius: 10px;
  }

  .giftherspace-diy-root .diy-card-thumb {
    padding: 2px;
    border-radius: 8px;
  }

  .giftherspace-diy-root .diy-card-thumb img {
    width: 82% !important;
    height: 82% !important;
    max-width: 82% !important;
    max-height: 82% !important;
    -webkit-user-drag: none;
    user-select: none;
    pointer-events: none;
  }

  .giftherspace-diy-root .diy-card-copy {
    position: relative;
    gap: 2px;
    padding-top: 0;
  }

  .giftherspace-diy-root .diy-card-copy strong {
    min-height: 1.7em;
    font-size: 0.44rem;
    line-height: 1.02;
    -webkit-line-clamp: 2;
  }

  .giftherspace-diy-root .diy-card--compact .diy-card-copy strong,
  .giftherspace-diy-root .diy-card--rope .diy-card-copy strong {
    min-height: 2.05em;
    font-size: 0.5rem;
    line-height: 1.08;
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
  }

  .giftherspace-diy-root .diy-card--compact .diy-card-meta-row,
  .giftherspace-diy-root .diy-card--rope .diy-card-meta-row {
    display: none !important;
  }

  .giftherspace-diy-root .diy-card-price,
  .giftherspace-diy-root .diy-card--compact .diy-card-price {
    order: 2;
    font-size: 0.48rem;
    padding: 1px 3px;
    border-radius: 999px;
    background: rgba(251, 228, 235, 0.92);
    line-height: 1.2;
  }

  .giftherspace-diy-root .diy-card-price-line {
    font-size: 0.48rem;
  }

  .giftherspace-diy-root .diy-card-material-tab {
    max-height: calc(100% - 8px);
    font-size: 0.36rem;
    padding: 3px 1px;
    border-radius: 0 6px 6px 0;
  }

  .giftherspace-diy-root .diy-card-meta,
  .giftherspace-diy-root .diy-card--compact .diy-card-meta,
  .giftherspace-diy-root .diy-card--rope .diy-card-meta {
    order: 1;
    font-size: 0.46rem;
    padding: 1px 3px;
    border-radius: 999px;
    background: rgba(247, 241, 238, 0.96);
    line-height: 1.2;
  }

  .giftherspace-diy-root .diy-card-qty-badge {
    min-width: 0;
    height: auto;
    padding: 0;
    font-size: 0.86rem;
  }

  .giftherspace-diy-root .diy-card-qty,
  .giftherspace-diy-root .diy-card-qty--compact {
    display: none !important;
  }
}

@media (min-width: 1024px) {
  .giftherspace-diy-root .diy-component-grid.is-dense-grid,
  .giftherspace-diy-root .diy-component-grid.is-rope-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }
}

/* Compact DIY browser density, 4-row component viewport. */
.giftherspace-diy-root .diy-preview-panel {
  gap: 14px;
}

.giftherspace-diy-root .diy-filter-summary {
  min-height: 46px;
  padding: 12px 16px 9px;
}

.giftherspace-diy-root .diy-filter-body {
  gap: 9px;
  padding: 12px 16px 14px;
}

.giftherspace-diy-root .diy-filter-group {
  gap: 5px;
}

.giftherspace-diy-root .diy-filter-label {
  font-size: 0.58rem;
  letter-spacing: 0.11em;
}

.giftherspace-diy-root [data-category-filters],
.giftherspace-diy-root [data-material-filters] {
  gap: 5px !important;
}

.giftherspace-diy-root .diy-filter-chip--category,
.giftherspace-diy-root .diy-filter-chip--material,
.giftherspace-diy-root .diy-filter-chip--diameter {
  min-height: 30px;
  border-radius: 12px;
}

.giftherspace-diy-root .diy-filter-chip--category {
  height: 30px;
  padding: 0 9px;
}

.giftherspace-diy-root .diy-filter-chip--material,
.giftherspace-diy-root .diy-filter-chip--diameter {
  padding: 0 9px;
}

.giftherspace-diy-root .diy-filter-chip-text {
  font-size: 0.62rem !important;
}

.giftherspace-diy-root .diy-filter-inline-row {
  gap: 6px;
}

.giftherspace-diy-root .diy-component-search {
  height: 34px;
  min-height: 34px;
}

.giftherspace-diy-root .diy-component-search--inline {
  width: 34px;
  min-width: 34px;
}

.giftherspace-diy-root .diy-component-search--inline .diy-component-search-icon {
  width: 34px !important;
  height: 34px !important;
  flex-basis: 34px !important;
}

.giftherspace-diy-root .diy-component-search-icon svg {
  width: 16px !important;
  height: 16px !important;
}

.giftherspace-diy-root .diy-component-grid,
.giftherspace-diy-root .diy-component-grid.is-dense-grid,
.giftherspace-diy-root .diy-component-grid.is-rope-grid {
  --diy-visible-card-row: clamp(112px, 14vw, 170px);
  gap: 8px !important;
  max-height: calc((var(--diy-visible-card-row) * 4) + 24px) !important;
  overflow-y: auto !important;
  overflow-x: hidden;
  padding: 2px 2px 4px;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(207, 112, 134, 0.34) transparent;
}

.giftherspace-diy-root .diy-card {
  padding: 5px;
}

.giftherspace-diy-root .diy-card-main {
  gap: 5px;
}

.giftherspace-diy-root .diy-card-thumb {
  padding: 3px;
}

.giftherspace-diy-root .diy-card-copy {
  gap: 2px;
}

@media (max-width: 699px) {
  .giftherspace-diy-root .diy-filter-summary {
    min-height: 42px;
    padding: 10px 12px 8px;
  }

  .giftherspace-diy-root .diy-filter-body {
    gap: 8px;
    padding: 10px 12px 12px;
  }

  .giftherspace-diy-root .diy-filter-group {
    gap: 4px;
  }

  .giftherspace-diy-root .diy-component-grid,
  .giftherspace-diy-root .diy-component-grid.is-dense-grid,
  .giftherspace-diy-root .diy-component-grid.is-rope-grid {
    --diy-visible-card-row: clamp(88px, 23vw, 112px);
    gap: 6px 5px !important;
    max-height: calc((var(--diy-visible-card-row) * 4) + 18px) !important;
    padding: 1px 1px 3px;
  }
}

/* Header separation and secondary summary actions. */
.site-header {
  background: linear-gradient(180deg, #fffaf7 0%, #fffdfb 100%);
  box-shadow: 0 10px 24px rgba(92, 65, 60, 0.06);
}

.site-header .brand {
  gap: 1px;
}

.site-header .brand-tag {
  display: block;
  margin-top: -2px;
  padding-left: clamp(10px, 3vw, 22px);
}

.builder-page .summary-secondary-actions {
  gap: 10px;
}

.builder-page .summary-action-tile,
.builder-page .diy-summary-card--mockup .summary-action-tile {
  min-height: 44px;
  padding: 0 18px;
  border-radius: 14px;
  background: rgba(255, 253, 251, 0.92);
  border-color: rgba(231, 212, 202, 0.96);
  color: var(--cocoa);
  font-size: 0.82rem;
  font-weight: 800;
  box-shadow: none;
}

.builder-page .summary-action-tile:hover,
.builder-page .summary-action-tile:focus-visible {
  background: rgba(255, 247, 249, 0.96);
}

@media (min-width: 768px) {
  .builder-page .summary-secondary-actions {
    gap: 10px;
  }

  .builder-page .summary-action-tile,
  .builder-page .diy-summary-card--mockup .summary-action-tile {
    min-height: 46px;
    padding: 0 18px;
    border-radius: 14px;
    gap: 6px;
    font-size: 0.86rem;
  }
}

@media (max-width: 767px) {
  .builder-page .summary-secondary-actions {
    gap: 8px;
  }

  .builder-page .summary-action-tile,
  .builder-page .diy-summary-card--mockup .summary-action-tile {
    min-height: 38px;
    padding: 0 10px;
    border-radius: 12px;
    background: rgba(255, 253, 251, 0.98);
    font-size: 0.68rem;
    line-height: 1;
    white-space: nowrap;
  }
}

/* Desktop stage metrics sit inside the stage, aligned to the top edge. */
@media (min-width: 700px) {
  .giftherspace-diy-root .diy-preview-side-notes,
  .builder-page .diy-preview-side-notes {
    position: absolute;
    top: 10px;
    left: 14px;
    right: 14px;
    bottom: auto;
    display: flex;
    align-items: baseline;
    gap: 12px;
    width: auto;
    max-width: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    text-align: left;
    pointer-events: none;
  }

  .giftherspace-diy-root .diy-preview-side-notes p,
  .builder-page .diy-preview-side-notes p {
    display: flex;
    align-items: baseline;
    gap: 4px;
    min-width: 0;
    min-height: 0;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }

  .giftherspace-diy-root .diy-preview-side-note--rope,
  .builder-page .diy-preview-side-note--rope {
    flex: 1 1 auto;
    grid-column: auto;
    overflow: hidden;
  }

  .giftherspace-diy-root .diy-preview-side-notes span,
  .builder-page .diy-preview-side-notes span {
    flex: 0 0 auto;
    font-size: 0.46rem;
    line-height: 1.2;
    letter-spacing: 0.06em;
  }

  .giftherspace-diy-root .diy-preview-side-notes strong,
  .builder-page .diy-preview-side-notes strong {
    font-size: 0.62rem;
    line-height: 1.18;
    white-space: nowrap;
    word-break: normal;
  }

  .giftherspace-diy-root .diy-preview-side-notes em,
  .builder-page .diy-preview-side-notes em {
    display: none;
  }
}

/* Mobile keeps the DIY stage square but visually smaller, leaving more room for component browsing. */
@media (max-width: 699px) {
  .giftherspace-diy-root .diy-preview-stage,
  .builder-page .diy-preview-stage {
    width: min(78vw, 320px) !important;
    max-width: 320px !important;
    margin-inline: auto !important;
    aspect-ratio: 1 / 1 !important;
  }
}

.icon-button {
  color: inherit;
  text-decoration: none;
}

.member-page {
  padding-top: 64px;
}

.member-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 430px);
  gap: 28px;
  align-items: end;
  padding-bottom: 34px;
  border-bottom: 1px solid rgba(218, 190, 177, 0.6);
}

.member-hero h1,
.member-panel h2 {
  margin: 0;
  color: var(--cocoa);
  font-family: var(--font-serif);
}

.member-hero h1 {
  max-width: 760px;
  font-size: clamp(2.7rem, 6vw, 5.4rem);
  line-height: 0.96;
}

.member-hero p:not(.eyebrow) {
  max-width: 620px;
  margin: 18px 0 0;
  color: rgba(69, 53, 57, 0.72);
  font-size: 1rem;
  line-height: 1.8;
}

.member-email-form {
  display: grid;
  gap: 10px;
  padding: 18px;
  border: 1px solid rgba(226, 201, 190, 0.9);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 18px 45px rgba(107, 69, 83, 0.08);
}

.member-email-form label {
  color: var(--cocoa);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.member-email-form > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.member-email-form input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid rgba(218, 190, 177, 0.9);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--cocoa);
  font: inherit;
}

.member-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.78fr) minmax(0, 1.22fr);
  gap: 24px;
  margin-top: 30px;
}

.member-panel {
  padding: 26px;
  border: 1px solid rgba(226, 201, 190, 0.9);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.66);
}

.member-panel-head {
  display: grid;
  gap: 8px;
  margin-bottom: 20px;
}

.member-panel h2 {
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  line-height: 1;
}

.member-empty-state {
  display: grid;
  gap: 16px;
  align-items: start;
  padding: 20px;
  border: 1px dashed rgba(218, 190, 177, 0.92);
  border-radius: 16px;
  background: rgba(255, 248, 246, 0.72);
}

.member-empty-state p {
  margin: 0;
  color: rgba(69, 53, 57, 0.72);
  line-height: 1.7;
}

.member-plan-list {
  display: grid;
  gap: 16px;
}

.member-plan-card {
  display: grid;
  grid-template-columns: 154px minmax(0, 1fr);
  gap: 18px;
  padding: 14px;
  border: 1px solid rgba(226, 201, 190, 0.92);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.82);
}

.member-plan-media {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 14px;
  background: #fff7f8;
  color: var(--rose);
  font-weight: 900;
  letter-spacing: 0.08em;
  text-decoration: none;
}

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

.member-plan-copy {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.member-plan-kicker {
  margin: 0 0 4px;
  color: var(--rose);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.member-plan-card h3 {
  margin: 0;
  color: var(--cocoa);
  font-size: 1.05rem;
}

.member-plan-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
  margin: 0;
}

.member-plan-details div {
  min-width: 0;
}

.member-plan-details dt {
  color: rgba(69, 53, 57, 0.5);
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.member-plan-details dd {
  margin: 3px 0 0;
  color: var(--cocoa);
  font-size: 0.82rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.member-plan-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.member-plan-actions strong {
  color: var(--cocoa);
  font-size: 1rem;
}

.member-grid--auth {
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.78fr);
  align-items: start;
}

.member-auth-form {
  display: grid;
  gap: 12px;
}

.member-auth-form label {
  color: var(--cocoa);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.member-auth-form input {
  width: 100%;
  min-height: 50px;
  padding: 0 16px;
  border: 1px solid rgba(218, 190, 177, 0.9);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--cocoa);
  font: inherit;
}

.member-form-errors,
.member-form-success {
  color: var(--rose);
  font-size: 0.9rem;
  line-height: 1.6;
}

.member-form-success {
  color: var(--cocoa);
}

.member-recover-panel {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(218, 190, 177, 0.65);
}

.member-recover-panel summary {
  color: var(--cocoa);
  cursor: pointer;
  font-weight: 800;
}

.member-recover-panel .member-auth-form {
  margin-top: 16px;
}

.member-order-list {
  display: grid;
  gap: 12px;
}

.member-order-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(226, 201, 190, 0.92);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
}

.member-order-card h3 {
  margin: 0;
  color: var(--cocoa);
  font-size: 1rem;
}

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

.member-order-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  color: rgba(69, 53, 57, 0.68);
  font-size: 0.8rem;
}

.member-order-meta strong {
  color: var(--cocoa);
}

.member-pagination {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}

@media (max-width: 860px) {
  .member-hero,
  .member-grid,
  .member-grid--auth {
    grid-template-columns: 1fr;
  }

  .member-email-form > div,
  .member-plan-card,
  .member-plan-details,
  .member-order-card {
    grid-template-columns: 1fr;
  }

  .member-order-meta {
    justify-content: flex-start;
  }

  .member-plan-media {
    max-width: 180px;
  }
}
