/* The landing page. Loaded after app.css and pages.css. */
.lp-head { position: sticky; top: 0; z-index: 5; background: linear-gradient(var(--night) 60%, transparent); }
.lp-head .btn.primary { padding: 9px 20px; }
.lp { width: 100%; max-width: 1180px; margin: 0 auto; display: flex; flex-direction: column; gap: 110px; padding: 24px 0 90px; }

/* ---------- Hero ---------- */
.lp-hero { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.2fr); gap: 48px; align-items: center; }
.lp-kicker { font-family: var(--mono); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--brass); margin: 0 0 14px; }
.lp-hero h1 { font-family: var(--display); font-weight: 800; text-transform: uppercase; font-size: clamp(52px, 7.4vw, 104px); line-height: 0.88; margin: 0 0 22px; }
.lp-hero h1 em { font-style: normal; color: var(--brass); }
.lp-hero .lede { font-size: 18px; line-height: 1.55; color: var(--ink-dim); margin: 0 0 28px; max-width: 520px; }
.lp-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.lp-cta .btn { padding: 12px 24px; font-size: 15.5px; }
.lp-hero-shot { animation: lp-rise 0.9s cubic-bezier(.2,.8,.2,1) both 0.15s; transform-origin: 30% 60%; }
.lp-hero-shot img { animation: lp-drift 22s ease-in-out infinite alternate; }
@keyframes lp-rise { from { opacity: 0; transform: translateY(26px) scale(0.97); } }
@keyframes lp-drift { from { transform: scale(1.02) translateX(0); } to { transform: scale(1.1) translateX(-3%); } }

/* ---------- Browser frame around screenshots ---------- */
.lp-frame {
  margin: 0; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: #0f0f0e;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(0, 0, 0, 0.4);
}
.lp-frame-bar { display: flex; gap: 6px; padding: 10px 12px; background: #1c1c1a; border-bottom: 1px solid var(--line); }
.lp-frame-bar i { width: 9px; height: 9px; border-radius: 50%; background: rgba(233, 223, 199, 0.18); }
.lp-frame-view { position: relative; aspect-ratio: 16 / 10; overflow: hidden; }
.lp-frame-view img, .lp-frame-view svg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- Sections ---------- */
.lp-h2 { font-family: var(--display); font-weight: 800; text-transform: uppercase; font-size: clamp(36px, 4.6vw, 58px); line-height: 0.95; margin: 0 0 12px; }
.lp-sub { color: var(--ink-dim); font-size: 17px; line-height: 1.55; margin: 0 0 32px; max-width: 640px; }

/* ---------- Steps ---------- */
.lp-step-tabs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 22px; }
.lp-step-tabs button {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 12px; text-align: left; padding: 14px 16px; cursor: pointer;
  border: 1px solid var(--line); border-radius: 12px; background: rgba(255, 255, 255, 0.03); color: var(--ink-dim); font-weight: 600; font-size: 14.5px; line-height: 1.25;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}
.lp-step-tabs button b { font-family: var(--display); font-weight: 800; font-size: 30px; color: var(--ink-faint); line-height: 1; transition: color 0.2s; }
.lp-step-tabs button[aria-selected=true] { color: var(--ink); border-color: rgba(240, 194, 122, 0.55); background: rgba(240, 194, 122, 0.07); }
.lp-step-tabs button[aria-selected=true] b { color: var(--brass); }
.lp-step-tabs button i { position: absolute; left: 0; bottom: 0; height: 2px; width: 0; background: var(--brass); }
.lp-steps.auto .lp-step-tabs button[aria-selected=true] i { animation: lp-progress 6s linear forwards; }
@keyframes lp-progress { to { width: 100%; } }
.lp-step-body { display: grid; grid-template-columns: minmax(0, 0.55fr) minmax(0, 1.45fr); gap: 36px; align-items: center; }
.lp-step-text p { font-size: 18px; line-height: 1.6; color: var(--ink-dim); margin: 0; animation: lp-in 0.5s ease both; }
/* Every step's text sits in the same cell, so the box is as tall as the longest
   and the page doesn't jump when the steps change. */
.lp-step-text { display: grid; }
.lp-step-text p { grid-area: 1 / 1; }
.lp-step-text p[hidden] { display: block !important; visibility: hidden; animation: none; }
.lp-pane { position: absolute; inset: 0; opacity: 0; transition: opacity 0.6s ease; }
.lp-pane.on { opacity: 1; }
.lp-pane img { transform: scale(1.03); transition: transform 6s ease-out; }
.lp-pane.on img { transform: scale(1); }
@keyframes lp-in { from { opacity: 0; transform: translateY(8px); } }

/* The tracing animation: scale, then the corners, then the room fills in. */
.lp-trace { background: #f3f1ea; }
.lp-trace-line { fill: none; stroke: #e0a94e; stroke-width: 4; stroke-linejoin: round; stroke-dasharray: 100; stroke-dashoffset: 100; }
.lp-trace-fill { fill: rgba(240, 194, 122, 0.28); opacity: 0; }
.lp-trace-dots circle { fill: #1b1a17; stroke: #f0c27a; stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.lp-trace-scale { opacity: 0; }
.lp-trace.play .lp-trace-scale { animation: lp-scale 5.6s ease both; }
.lp-trace.play .lp-trace-line { animation: lp-draw 3s cubic-bezier(.5,0,.5,1) forwards 1.4s; }
.lp-trace.play .lp-trace-dots circle { animation: lp-dot 0.3s ease forwards; animation-delay: calc(1.4s + var(--d) * 0.5s); }
.lp-trace.play .lp-trace-fill { animation: lp-fill 0.8s ease forwards 4.4s; }
@keyframes lp-scale { 0% { opacity: 0; } 8%, 70% { opacity: 1; } 100% { opacity: 0; } }
@keyframes lp-draw { to { stroke-dashoffset: 0; } }
@keyframes lp-dot { from { opacity: 0; transform: scale(2.2); } to { opacity: 1; transform: scale(1); } }
@keyframes lp-fill { to { opacity: 1; } }

/* ---------- Room look ---------- */
.lp-look { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 48px; align-items: center; }
.lp-look-names { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.lp-look-names li { padding: 10px 14px 10px 18px; border-left: 2px solid var(--line); color: var(--ink-dim); animation: lp-name 18s infinite; }
.lp-look-names li:nth-child(2) { animation-delay: 6s; }
.lp-look-names li:nth-child(3) { animation-delay: 12s; }
@keyframes lp-name { 0%, 30% { border-color: var(--brass); color: var(--ink); } 36%, 100% { border-color: var(--line); color: var(--ink-dim); } }
.lp-fade img { opacity: 0; animation: lp-fade 18s infinite; }
.lp-fade img:nth-child(1) { animation-delay: -1s; }
.lp-fade img:nth-child(2) { animation-delay: 5s; }
.lp-fade img:nth-child(3) { animation-delay: 11s; }
@keyframes lp-fade { 0% { opacity: 0; } 5%, 33% { opacity: 1; } 39%, 100% { opacity: 0; } }

/* ---------- Features ---------- */
.lp-feats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.lp-feats article { border: 1px solid var(--line); border-radius: 14px; padding: 22px 20px; background: var(--panel); }
.lp-feats h3 { font-size: 17px; margin: 0 0 8px; }
.lp-feats h3::before { content: ""; display: block; width: 22px; height: 3px; background: var(--brass); margin-bottom: 14px; }
.lp-feats p { margin: 0; color: var(--ink-dim); line-height: 1.55; font-size: 14.5px; }

.lp-end { text-align: center; display: flex; flex-direction: column; align-items: center; padding: 20px 0; }
.lp-end .lp-h2 { margin-bottom: 24px; }
.lp-end .btn { padding: 12px 28px; font-size: 16px; }

@media (max-width: 980px) {
  .lp { gap: 80px; }
  .lp-hero, .lp-look, .lp-step-body { grid-template-columns: 1fr; }
  .lp-feats { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 620px) {
  .lp-step-tabs { grid-template-columns: 1fr 1fr; }
  .lp-feats { grid-template-columns: 1fr; }
  .lp-hero .lede, .lp-sub, .lp-step-text p { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .lp-hero-shot, .lp-hero-shot img, .lp-step-text p { animation: none; }
  .lp-trace .lp-trace-line { stroke-dashoffset: 0; }
  .lp-trace .lp-trace-dots circle, .lp-trace .lp-trace-fill, .lp-trace .lp-trace-scale { opacity: 1; animation: none !important; }
  .lp-fade img, .lp-look-names li { animation: none; }
  .lp-fade img:first-child { opacity: 1; }
}
