:root {
  --bg: #0f1a14;
  --panel: #16241c;
  --card: #1c2e24;
  --text: #f4efe6;
  --muted: #b7c4ba;
  --accent: #e63946;
  --gold: #f0c14b;
  --line: rgba(255, 255, 255, 0.08);
  --radius: 16px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 10% -10%, #2a4a35 0%, transparent 55%),
    radial-gradient(900px 500px at 90% 0%, #5a1a22 0%, transparent 50%),
    var(--bg);
  min-height: 100vh;
  padding-bottom: calc(4.5rem + var(--safe-bottom));
}
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }

.top {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1rem; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; backdrop-filter: blur(10px);
  background: rgba(15, 26, 20, 0.9); z-index: 20;
  gap: 0.75rem;
}
.brand { display: flex; gap: 0.65rem; align-items: center; min-width: 0; }
.logo { font-size: 1.5rem; flex-shrink: 0; }
.brand strong { font-size: 1rem; }
.tag { display: block; color: var(--muted); font-size: 0.72rem; font-weight: 400; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 42vw; }
nav { display: flex; gap: 0.75rem; align-items: center; flex-shrink: 0; }
nav a { color: var(--muted); font-size: 0.9rem; }
nav .nav-link { display: none; }
.btn-sm {
  background: var(--accent); color: #fff !important; padding: 0.5rem 0.9rem;
  border-radius: 999px; text-decoration: none !important; font-weight: 700;
  font-size: 0.85rem; white-space: nowrap;
  min-height: 40px; display: inline-flex; align-items: center;
}
@media (min-width: 720px) {
  .top { padding: 1rem 1.5rem; }
  .tag { max-width: none; font-size: 0.8rem; }
  nav .nav-link { display: inline; }
  body { padding-bottom: 0; }
}

main { max-width: 1040px; margin: 0 auto; padding: 1.25rem 1rem 3rem; }
@media (min-width: 720px) {
  main { padding: 2rem 1.25rem 4rem; }
}
.hero { padding: 1.25rem 0 0.5rem; }
.eyebrow {
  display: inline-block; color: var(--gold); letter-spacing: 0.04em;
  text-transform: uppercase; font-size: 0.72rem; margin: 0 0 0.65rem;
}
h1 { font-size: clamp(1.65rem, 5.5vw, 2.8rem); line-height: 1.15; margin: 0 0 0.85rem; }
h1 em { font-style: normal; color: var(--gold); }
.lede { color: var(--muted); font-size: 1.05rem; max-width: 40rem; line-height: 1.5; margin: 0 0 1rem; }
.bullets { color: var(--muted); padding-left: 1.2rem; margin: 0 0 1.25rem; }
.bullets li { margin: 0.4rem 0; }
.fine { color: #7f9086; font-size: 0.8rem; }
.hero .btn {
  width: 100%;
  text-align: center;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
@media (min-width: 480px) {
  .hero .btn { width: auto; }
}

.btn {
  display: inline-block; border: 0; cursor: pointer;
  background: linear-gradient(135deg, #e63946, #c1121f);
  color: #fff; font-weight: 700; padding: 0.9rem 1.25rem;
  border-radius: 999px; font-size: 1rem; margin-top: 0.35rem;
  min-height: 48px;
  -webkit-tap-highlight-color: transparent;
}
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn.secondary {
  background: linear-gradient(135deg, #3d5a45, #2a4032);
  border: 1px solid var(--gold); color: var(--gold);
}
.btn:hover:not(:disabled) { filter: brightness(1.05); }
.btn:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

.how { margin: 2rem 0; }
.how h2 { font-size: 1.25rem; margin: 0 0 0.75rem; }
.steps {
  display: grid; gap: 0.65rem; padding: 0; margin: 0;
  list-style: none; counter-reset: step;
}
.steps li {
  color: var(--muted); background: var(--card);
  border: 1px solid var(--line); border-radius: 12px;
  padding: 0.85rem 1rem 0.85rem 2.75rem; position: relative;
}
.steps li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0.85rem; top: 50%; transform: translateY(-50%);
  width: 1.5rem; height: 1.5rem; border-radius: 50%;
  background: #e6394633; color: var(--gold); font-weight: 800;
  font-size: 0.8rem; display: flex; align-items: center; justify-content: center;
}
.steps li strong { color: var(--text); }

.panel {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1rem;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}
@media (min-width: 720px) {
  .panel { padding: 1.25rem; }
}
.panel.narrow { max-width: 520px; margin: 4rem auto; }
.panel-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 0.75rem; flex-wrap: wrap;
}
.panel-head h2 { margin: 0; font-size: clamp(1.1rem, 3.5vw, 1.4rem); }
.badge {
  font-size: 0.68rem; font-weight: 800; letter-spacing: 0.06em;
  background: #f0c14b22; color: var(--gold); border: 1px solid #f0c14b55;
  padding: 0.35rem 0.6rem; border-radius: 999px; white-space: nowrap;
}
.badge.live { background: #2a9d8f33; color: #7dffc8; border-color: #2a9d8f88; }

.grid {
  display: grid; grid-template-columns: 1fr; gap: 1rem; margin-top: 1rem;
}
@media (min-width: 860px) {
  .grid { grid-template-columns: 1fr 1fr; gap: 1.25rem; }
  .preview-wrap { order: 0; }
  .controls { order: 0; }
}

/* On narrow screens: preview after controls is fine; keep upload first */
.drop {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  gap: 0.5rem;
  min-height: 140px; border: 2px dashed #3d5a45; border-radius: 14px;
  background: var(--card); color: var(--muted); cursor: pointer; padding: 1.1rem;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
.drop:hover, .drop:focus-within { border-color: #5a8a68; }
.drop.drag { border-color: var(--gold); color: var(--gold); background: #1f3528; }
.drop-icon { font-size: 1.75rem; line-height: 1; }
.drop-title { color: var(--text); font-weight: 700; font-size: 1rem; }
.drop-sub { font-size: 0.85rem; color: var(--muted); }
.drop.has-file .drop-title { color: var(--gold); }

.looks {
  border: 0; margin: 1rem 0 0.75rem; padding: 0;
}
.looks legend {
  color: var(--text); font-weight: 700; font-size: 0.95rem;
  margin-bottom: 0.55rem; padding: 0;
}
.look-options {
  display: grid; grid-template-columns: 1fr; gap: 0.5rem;
}
@media (min-width: 420px) {
  .look-options { grid-template-columns: repeat(3, 1fr); }
}
.look-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 0.2rem;
  margin: 0; cursor: pointer;
  background: var(--card); border: 1.5px solid var(--line);
  border-radius: 12px; padding: 0.75rem 0.7rem;
  color: var(--muted); min-height: 64px;
  transition: border-color 0.15s, background 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.look-card:has(input:checked),
.look-card.selected {
  border-color: var(--gold);
  background: #24382c;
  color: var(--text);
  box-shadow: inset 0 0 0 1px #f0c14b44;
}
.look-card input { position: absolute; opacity: 0; pointer-events: none; }
.look-emoji { font-size: 1.25rem; line-height: 1; }
.look-name { font-weight: 700; font-size: 0.88rem; color: inherit; }
.look-desc { font-size: 0.72rem; color: #8a9a90; line-height: 1.25; }

.actions {
  display: flex; flex-direction: column; gap: 0.55rem; margin-top: 0.75rem;
}
.actions .btn { width: 100%; margin-top: 0; text-align: center; }
@media (min-width: 560px) {
  .actions { flex-direction: row; flex-wrap: wrap; }
  .actions .btn { width: auto; flex: 1 1 auto; min-width: 160px; }
}

/* Sticky unlock bar on mobile after preview ready */
.mobile-cta {
  display: none;
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  padding: 0.65rem 1rem calc(0.65rem + var(--safe-bottom));
  background: rgba(15, 26, 20, 0.94);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(12px);
  box-shadow: 0 -8px 24px rgba(0,0,0,0.35);
}
.mobile-cta.visible { display: block; }
.mobile-cta .btn { width: 100%; margin: 0; }
@media (min-width: 860px) {
  .mobile-cta { display: none !important; }
}

.status { min-height: 1.4em; color: var(--gold); font-size: 0.9rem; margin: 0.5rem 0 0; }

.preview-wrap { display: flex; flex-direction: column; gap: 0.5rem; }
#canvas {
  width: 100%; aspect-ratio: 1; background: #0a120e;
  border-radius: 12px; border: 1px solid var(--line);
  max-height: min(72vw, 640px);
  object-fit: contain;
}
.hint { color: #7f9086; font-size: 0.85rem; margin: 0; }
.watermark-note {
  display: flex; align-items: center; gap: 0.4rem;
  color: #c9b27a; font-size: 0.82rem; margin: 0;
}

.seo-block { margin-top: 2.5rem; color: var(--muted); }
.seo-block h2 { color: var(--text); font-size: 1.2rem; }
footer {
  text-align: center; padding: 2rem 1rem 3rem; color: #7f9086;
  border-top: 1px solid var(--line);
}
body.simple { display: flex; flex-direction: column; min-height: 100vh; justify-content: center; padding-bottom: 0; }

.unlock-panel { text-align: center; }
.unlock-actions { justify-content: center; margin-top: 1rem; }
.download-preview {
  margin: 1rem 0;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #0a120e;
  overflow: hidden;
}
.download-preview img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}


/* Sample results gallery */
.hero-ctas {
  display: flex; flex-direction: column; gap: 0.55rem; margin-top: 0.25rem;
}
.hero-ctas .btn { margin-top: 0; width: 100%; text-align: center;
  display: inline-flex; align-items: center; justify-content: center; }
@media (min-width: 480px) {
  .hero-ctas { flex-direction: row; flex-wrap: wrap; }
  .hero-ctas .btn { width: auto; }
}

.samples {
  margin: 2rem 0 0.5rem;
  padding: 1.1rem 1rem 1.25rem;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.samples-head h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.2rem, 4vw, 1.55rem);
}
.samples-lede {
  color: var(--muted);
  margin: 0 0 0.65rem;
  line-height: 1.45;
  font-size: 0.98rem;
}
.honest-note {
  margin: 0 0 1rem;
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  background: #f0c14b14;
  border: 1px solid #f0c14b44;
  color: #e6d4a0;
  font-size: 0.88rem;
  line-height: 1.4;
}
.demo-callout {
  margin: 0.75rem 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.4;
}
.sample-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
}
@media (min-width: 720px) {
  .sample-grid { grid-template-columns: repeat(3, 1fr); gap: 1rem; }
}
.sample-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.75rem;
}
.sample-look {
  margin: 0 0 0.55rem;
  font-size: 0.95rem;
  color: var(--gold);
}
.ba {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0.35rem;
  align-items: center;
}
.ba figure { margin: 0; }
.ba img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #0a120e;
}
.ba figcaption {
  text-align: center;
  color: #8a9a90;
  font-size: 0.72rem;
  margin-top: 0.3rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.ba-arrow {
  color: var(--gold);
  font-weight: 800;
  font-size: 1.1rem;
  line-height: 1;
  padding-bottom: 1rem;
}

/* FAQ — 哥飞 long-tail / semantic */
.hero-honest { margin: 0.75rem 0 0; max-width: 40rem; }
.faq {
  margin: 2rem 0 0;
  padding: 1.25rem 1rem;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.faq h2 {
  margin: 0 0 0.4rem;
  font-size: clamp(1.2rem, 4vw, 1.55rem);
}
.faq-lede {
  color: var(--muted);
  margin: 0 0 1rem;
  font-size: 0.95rem;
  line-height: 1.45;
}
.faq-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  margin: 0 0 0.55rem;
  padding: 0.15rem 0.75rem;
}
.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  padding: 0.75rem 0.15rem;
  list-style: none;
  color: var(--text);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before {
  content: "+ ";
  color: var(--gold);
  font-weight: 800;
}
.faq-item[open] summary::before { content: "− "; }
.faq-item p {
  margin: 0 0 0.85rem;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}
.seo-block {
  margin: 2rem 0 0;
  padding: 1.1rem 1rem;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.55;
}
.seo-block h2 {
  margin: 0 0 0.55rem;
  font-size: 1.1rem;
  color: var(--text);
}
.seo-block p { margin: 0 0 0.65rem; }
.seo-block p:last-child { margin-bottom: 0; }
.footer-nav { margin-top: 0.5rem; }
.footer-nav a { color: var(--muted); }


/* Orchard / free tools internal links */
.tools-block {
  margin: 2rem 0 0;
  padding: 1.25rem 1rem;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.tools-block h2 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
}
.tools-lede {
  color: var(--muted);
  margin: 0 0 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
  max-width: 40rem;
}
.tools-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .tools-grid { grid-template-columns: repeat(3, 1fr); }
}
.tool-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1rem;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--text);
  text-decoration: none !important;
  min-height: 96px;
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.tool-card:hover {
  border-color: var(--gold);
  transform: translateY(-1px);
}
.tool-card strong {
  color: var(--gold);
  font-size: 1rem;
}
.tool-card span {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.4;
}
.orchard-hero { padding-bottom: 0.25rem; }
