:root {
  --primary: #c0392b;
  --primary-light: #e74c3c;
  --green: #10b981;
  --blue: #3b82f6;
  --bg: #faf8f6;
  --card: #ffffff;
  --text: #1a1a1a;
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;
  --border: #f0ece8;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04), 0 1px 3px rgba(0,0,0,0.03);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.05), 0 2px 4px -2px rgba(0,0,0,0.03);
  --radius: 16px;
  --radius-sm: 10px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  padding: 24px;
  padding-bottom: 56px;
  position: relative;
}

.bg-decoration {
  position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden;
}

.bg-orb {
  position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0.4;
}

.bg-orb-1 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(192,57,43,0.12) 0%, transparent 70%);
  top: -100px; right: -100px;
}

.bg-orb-2 {
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(245,158,11,0.08) 0%, transparent 70%);
  bottom: 10%; left: -50px;
}

.bg-orb-3 {
  width: 250px; height: 250px;
  background: radial-gradient(circle, rgba(16,185,129,0.06) 0%, transparent 70%);
  top: 50%; right: 10%;
}

.container { max-width: 900px; margin: 0 auto; position: relative; z-index: 1; }

.top-actions {
  position: fixed; top: 20px; right: 20px; z-index: 50;
  display: flex; align-items: center; gap: 8px;
}

.lang-select,
.contact-btn,
.about-btn {
  padding: 8px 14px; border-radius: 8px; font-size: 13px; font-weight: 500;
  font-family: inherit; color: var(--text-secondary); background: rgba(255,255,255,0.92);
  border: 1px solid var(--border); box-shadow: var(--shadow-sm); cursor: pointer;
  transition: all 0.2s; backdrop-filter: blur(8px);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.lang-select {
  padding-right: 28px;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M3 4.5 6 7.5 9 4.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

.contact-btn:hover,
.about-btn:hover,
.lang-select:hover {
  color: var(--primary); border-color: rgba(192,57,43,0.25); box-shadow: var(--shadow-md);
}

.header { text-align: center; padding: 20px 0 24px; }

.logo-text {
  font-size: 28px; font-weight: 800; letter-spacing: -0.5px;
}

.logo-highlight { color: var(--primary); }

.top-nav {
  display: flex; justify-content: center; gap: 6px; margin-top: 14px; flex-wrap: wrap;
}

.nav-link {
  padding: 8px 20px; border-radius: 8px; font-size: 13px; font-weight: 500;
  color: var(--text-secondary); text-decoration: none; border: 1px solid transparent;
  transition: all 0.2s;
}

.nav-link:hover, .nav-link.active {
  background: #fff; color: var(--primary); border-color: var(--border);
  font-weight: 600; box-shadow: var(--shadow-sm);
}

.nav-link-external {
  font-family: inherit; background: transparent; cursor: pointer;
}

.nav-link-external:hover { color: var(--primary); }

.page-title {
  text-align: center; font-size: 15px; color: var(--text-secondary); margin-bottom: 28px;
}

.catalog-skeleton {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sk-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 0 24px;
  align-items: stretch;
}

.sk-label {
  display: block;
  align-self: center;
  width: 28px;
  height: 14px;
  margin: 0 auto;
  border-radius: 4px;
  background: linear-gradient(90deg, #eee 25%, #f5f5f5 50%, #eee 75%);
  background-size: 200% 100%;
  animation: sk-shine 1.2s ease-in-out infinite;
}

.sk-cards {
  display: grid;
  gap: 16px;
  min-width: 0;
}

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

.sk-card {
  display: block;
  min-height: 128px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: linear-gradient(90deg, #f0ece8 25%, #faf8f6 50%, #f0ece8 75%);
  background-size: 200% 100%;
  animation: sk-shine 1.2s ease-in-out infinite;
}

@keyframes sk-shine {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

.product-catalog {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 24px;
}

.product-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 0 24px;
  align-items: stretch;
}

.product-row-label {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  line-height: 1.3;
  letter-spacing: 0.02em;
  padding: 8px 12px 8px 0;
  margin-right: 4px;
  border-right: 1px solid var(--border);
  align-self: stretch;
}

.product-row-cards {
  display: grid;
  gap: 16px;
  min-width: 0;
  align-content: start;
}

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

.detail-cdk-foot {
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.6;
}

.detail-cdk-foot a {
  color: var(--primary);
  font-weight: 500;
  text-decoration: none;
}

.detail-cdk-foot a:hover {
  text-decoration: underline;
}

.product-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow-sm); cursor: pointer; transition: all 0.2s;
  text-decoration: none; color: inherit;
  display: flex; flex-direction: column;
}

.product-card:hover {
  box-shadow: var(--shadow-md); border-color: rgba(192,57,43,0.2); transform: translateY(-2px);
}

.product-card--account {
  min-height: 128px;
  padding: 16px 18px;
}

.product-card--account .product-name {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
  min-height: 0;
}

.product-card--account .product-desc {
  font-size: 12px;
  margin-bottom: 8px;
  min-height: 0;
}

.product-card--account .product-price {
  margin-top: auto;
  padding-top: 8px;
}

.product-card--sms {
  min-height: 140px;
}

.product-badge {
  display: inline-block; align-self: flex-start;
  font-size: 11px; font-weight: 600; padding: 3px 8px;
  border-radius: 6px; background: #fff5f5; color: var(--primary); margin-bottom: 8px;
  line-height: 16px; border: 1px solid rgba(192, 57, 43, 0.12);
}

.product-card-badges {
  display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px;
}

.product-card-badges .product-badge { margin-bottom: 0; }

.product-badge--ready {
  background: rgba(192, 57, 43, 0.08); border-color: rgba(192, 57, 43, 0.22);
}

.product-badge--ghost {
  visibility: hidden;
  margin-bottom: 0;
}

.product-name {
  font-size: 14px; font-weight: 600; margin-bottom: 6px;
  line-height: 1.4;
}

.product-desc {
  font-size: 12px; color: var(--text-secondary); margin-bottom: 10px; line-height: 1.45;
  flex: 1;
}

.product-detail {
  font-size: 14px; color: var(--text-secondary); line-height: 1.7;
}

.product-price {
  font-size: 22px; font-weight: 700; color: var(--primary);
  margin-top: auto; line-height: 1;
}
.product-card--account .product-price { font-size: 26px; }
.product-price small { font-size: 14px; font-weight: 600; margin-right: 2px; }

.card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); overflow: hidden;
}

.section { padding: 20px 24px; border-bottom: 1px solid var(--border); }
.section:last-child { border-bottom: none; }

.section-head {
  display: flex; align-items: center; gap: 8px; margin-bottom: 16px;
  font-size: 15px; font-weight: 600;
}

.section-icon { font-size: 18px; }

.info-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px 24px;
}

.info-item label {
  display: block; font-size: 12px; color: var(--text-muted); margin-bottom: 4px;
}

.info-item span { font-size: 14px; font-weight: 500; }

.status-paid { color: var(--green); font-weight: 600; }

.cdk-box {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: #fafafa; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.cdk-text {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 14px; word-break: break-all; flex: 1;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 18px; border-radius: var(--radius-sm); font-size: 13px; font-weight: 600;
  border: none; cursor: pointer; transition: all 0.2s; text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-light), var(--primary)); color: #fff;
}

.btn-primary:hover { opacity: 0.92; transform: translateY(-1px); }

.btn-outline {
  background: #fff; color: var(--text); border: 1px solid var(--border);
}

.btn-outline:hover { border-color: var(--primary); color: var(--primary); }

.btn-sm { padding: 6px 12px; font-size: 12px; }

.btn-group { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

.instructions {
  font-size: 13px; line-height: 1.8; color: var(--text-secondary); white-space: pre-wrap;
}

.instructions a { color: var(--blue); text-decoration: none; }
.instructions a:hover { text-decoration: underline; }

.instructions .warn { color: var(--primary); font-weight: 600; }

.product-detail {
  font-size: 13px; line-height: 1.6; color: var(--text-secondary);
}

.product-detail a { color: var(--blue); text-decoration: none; }
.product-detail a:hover { text-decoration: underline; }

.detail-tags {
  display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px;
}

.detail-tag {
  display: inline-block; padding: 4px 10px; font-size: 12px; line-height: 1.35;
  color: var(--text-secondary); background: rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border); border-radius: 999px;
}

.detail-tag--accent {
  color: var(--primary); background: rgba(192, 57, 43, 0.08);
  border-color: rgba(192, 57, 43, 0.25);
}

.detail-section {
  padding-top: 16px; padding-bottom: 12px; border-top: 1px solid var(--border);
}

.detail-section-head {
  font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 10px;
}

.detail-platform {
  margin: 0 0 10px; font-size: 13px; line-height: 1.5;
  word-break: break-all;
}

.detail-steps {
  margin: 0; padding-left: 1.2em; line-height: 1.6;
}

.detail-steps li + li { margin-top: 6px; }

.detail-sample {
  padding: 10px 12px; margin-bottom: 10px; font-size: 13px; line-height: 1.7;
  background: rgba(0, 0, 0, 0.03); border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
}

.detail-sample code { font-family: inherit; color: var(--text); font-weight: 500; }

.detail-note { margin: 0 0 2px; font-size: 12px; line-height: 1.5; color: var(--text-secondary); }

.detail-steps + .instructions-diagram { margin-top: 12px; margin-bottom: 0; }

.detail-steps + .diagram-thumb-btn { margin-top: 12px; }

.diagram-thumb-btn {
  display: block; margin: 0; padding: 0; border: none; background: none;
  cursor: zoom-in; line-height: 0;
}

.diagram-enlarge-btn {
  display: block; max-width: 260px; margin: 0 0 14px; padding: 0;
  border: none; background: none; cursor: zoom-in; line-height: 0;
}

.diagram-enlarge-btn .instructions-diagram { margin: 0; }

.diagram-enlarge-btn + .detail-steps { margin-top: 4px; }

.diagram-thumb {
  display: block; width: 100%; max-width: 130px;
  border-radius: var(--radius-sm); border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.instructions-diagram {
  display: block; width: 100%; max-width: 260px; margin: 0 0 14px;
  border-radius: var(--radius-sm); border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.instructions-diagram + .detail-steps { margin-top: 4px; }

.detail-card { max-width: 640px; margin: 0 auto; }

.detail-header { padding: 28px 24px; text-align: center; border-bottom: 1px solid var(--border); }
.detail-header h1 { font-size: 20px; margin-bottom: 8px; }
.detail-header .price { font-size: 32px; font-weight: 700; color: var(--primary); }

.detail-body { padding: 24px; }
.detail-body p { font-size: 13px; color: var(--text-secondary); line-height: 1.7; margin-bottom: 20px; }

.detail-body > .field-label {
  margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--border);
}

.buy-bar { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 16px; }

.field-label {
  display: block; font-size: 13px; font-weight: 600; margin-bottom: 10px;
}

.field-input {
  width: 100%; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 14px; font-family: inherit; background: #fff;
}

.field-input:focus {
  outline: none; border-color: rgba(192,57,43,0.4); box-shadow: 0 0 0 3px rgba(192,57,43,0.08);
}

.field-hint {
  font-size: 12px; color: var(--text-muted); margin: 8px 0 0;
}

.field-hint--delivery { margin-top: 12px; margin-bottom: 0; }

.empty {
  text-align: center; padding: 48px 24px; color: var(--text-muted); font-size: 14px;
}

.order-list { display: flex; flex-direction: column; gap: 12px; }

.order-item {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 16px 20px; display: flex; justify-content: space-between; align-items: center;
  gap: 12px; flex-wrap: wrap; cursor: pointer; transition: all 0.2s;
}

.order-item:hover { border-color: rgba(192,57,43,0.3); box-shadow: var(--shadow-sm); }

.toast {
  position: fixed; top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.92);
  background: rgba(26, 26, 26, 0.94); color: #fff;
  padding: 14px 24px; border-radius: 12px;
  font-size: 14px; font-weight: 500; line-height: 1.5;
  z-index: 300; opacity: 0; transition: opacity 0.25s, transform 0.25s;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
  max-width: min(320px, calc(100vw - 48px));
  text-align: center; pointer-events: none;
}

.toast.show {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

.modal {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.45); display: flex; align-items: center; justify-content: center;
  padding: 24px;
}

.modal[hidden] { display: none; }

.modal-card {
  background: var(--card); border-radius: var(--radius); padding: 20px 24px 24px;
  max-width: 300px; width: 100%; text-align: center; position: relative;
  box-shadow: var(--shadow-md); border: 1px solid var(--border);
}

.modal--image {
  padding: 16px;
}

.modal-card--image {
  max-width: none; width: auto; max-height: calc(100vh - 32px);
  padding: 28px 12px 12px; overflow: auto;
}

.modal-image {
  display: block; width: auto; height: auto;
  object-fit: contain; image-rendering: auto;
  border-radius: var(--radius-sm);
}

.modal-close {
  position: absolute; top: 10px; right: 12px; border: none; background: transparent;
  font-size: 24px; line-height: 1; color: var(--text-muted); cursor: pointer;
}

.modal-title { font-size: 17px; margin-bottom: 12px; }

.modal-qr {
  display: block; width: 150px; height: 150px; margin: 0 auto 10px;
  object-fit: contain; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: #fff;
}

.modal-text { font-size: 15px; margin: 8px 0 0; }

.modal-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.6; }

.modal-links {
  display: flex; justify-content: center; gap: 28px; margin-top: 14px;
}

.social-item {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}

.social-note {
  font-size: 13px; color: var(--text-muted); line-height: 1;
}

.social-link {
  display: inline-flex; align-items: center; justify-content: center;
  width: 46px; height: 46px; border-radius: 12px;
  border: 1px solid var(--border); background: #fafafa; color: #1a1a1a;
  transition: all 0.2s;
}

.social-link svg { width: 22px; height: 22px; }

.social-link:hover {
  border-color: rgba(192, 57, 43, 0.3); box-shadow: var(--shadow-sm); transform: translateY(-1px);
}

.social-link--xhs { color: #ff2442; }

.social-link--xhs:hover { color: #e01f3a; }

.order-ticker {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  background: rgba(255, 255, 255, 0.96);
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.04);
  backdrop-filter: blur(8px);
}

.order-ticker-inner { overflow: hidden; padding: 10px 0; }

.order-ticker-track {
  display: flex; width: max-content; gap: 40px;
  animation: order-ticker-scroll 100s linear infinite;
}

.order-ticker-track:hover { animation-play-state: paused; }

.order-ticker-item {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; color: var(--text-secondary); white-space: nowrap;
}

.order-ticker-item strong { color: var(--text); font-weight: 600; }

.order-ticker-dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--green); flex-shrink: 0;
}

@keyframes order-ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@media (max-width: 900px) {
  .product-row { grid-template-columns: 44px minmax(0, 1fr); gap: 0 20px; }
  .product-row-cards--triple { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 600px) {
  body { padding: 16px; padding-bottom: 52px; }
  .header { padding-top: 46px; }
  .top-actions { top: 12px; right: 12px; gap: 6px; }
  .lang-select, .contact-btn, .about-btn { padding: 7px 10px; font-size: 12px; }
  .top-actions { max-width: calc(100vw - 24px); flex-wrap: wrap; justify-content: flex-end; }
  .product-row { grid-template-columns: 1fr; gap: 8px; }
  .product-row-label {
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding: 0 0 8px;
    justify-content: flex-start;
    text-align: left;
  }
  .product-row-cards--triple { grid-template-columns: 1fr; }
  .product-card { min-height: 0; }
  .product-name { min-height: 0; }
  .section { padding: 16px; }
  .info-grid { grid-template-columns: 1fr; }
}
