/* ── Reset & Base ────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
/* Design System Tokens (light mode defaults) */
:root {
  /* Spacing */
  --sp2: 2px;
  --sp4: 4px;
  --sp8: 8px;
  --sp12: 12px;
  --sp16: 16px;
  --sp24: 24px;
  --sp32: 32px;
  --sp48: 48px;
  /* Radius — controls r4/r6, chips r6/r8, strips r10, cards/panels r14 */
  --r2: 2px;
  --r4: 4px;
  --r6: 6px;
  --r8: 8px;
  --r10: 10px;
  --r14: 14px;
  --pill: 999px;
  /* Component size */
  --buttonH: 28px;
  --buttonHLg: 40px;
  --inputH: 32px;
  --sectionHeaderH: 32px;
  --hitTarget: 24px;
  --sidebarCollapsed: 48px;
  /* Icon size */
  --iconXs: 12px;
  --iconSm: 14px;
  --iconMd: 16px;
  --iconLg: 20px;
  --iconXl: 28px;
  /* Semantic colors – warm-neutral pro-tool, indigo accent (matches desktop app) */
  --surfaceCanvas: #F5F4F1;
  --surfacePanel: #EFEDEA;
  --surfaceRaised: #FFFFFF;
  --surfaceSunken: #EDEBE6;
  --textPrimary: #1B1A19;
  --textSecondary: #5F5E5A;
  --textMuted: #8C8A85;
  --textDisabled: #B7B5AF;
  --borderHairline: #E7E5E0;
  --borderStrong: #D8D5D0;
  --semanticAccent: #5558D9;
  --semanticAccentDim: var(--semanticAccentDim);
  --semanticSuccess: #1F7A43;
  --semanticSuccessDim: rgba(31,122,67,.12);
  --semanticWarn: #8F6A12;
  --semanticWarnDim: rgba(224,179,87,.18);
  --semanticError: #B04A32;
  --semanticErrorDim: rgba(224,101,85,.12);
  /* Elevation – soft neutral shadows */
  --elevation0: none;
  --elevation1: 0 1px 2px rgba(0,0,0,.05);
  --elevation2: 0 2px 10px rgba(0,0,0,.07);
  --elevation4: 0 16px 40px rgba(0,0,0,.13);
  /* Typography */
  --fontInter: "Instrument Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --fontMono: "IBM Plex Mono", "Consolas", monospace;
  /* Primary button – indigo accent (matches desktop app's dominant action) */
  --btnPrimaryBg: #5558D9;
  --btnPrimaryFg: #FFFFFF;
  --btnPrimaryHover: #4245B8;
  --displayMedium: 22px;
  --titleSmall: 13px;
  --titleMedium: 15px;
  --bodyMedium: 13px;
  --bodySmall: 12px;
  --labelSmall: 11px;
  /* Motion */
  --motionInstant: 0ms;
  --motionFast: 120ms;
  --motionBase: 180ms;
  --motionSlow: 300ms;
  --motionCurve: cubic-bezier(0.22,1,0.36,1);
  --motionLinear: linear;
  --staggerStep: 30ms;
  /* Landing-page aliases (lp-*) — same palette, legacy names */
  --lp-bg:        #F5F4F1;
  --lp-bg-2:      #EFEDEA;
  --lp-dark:      #1B1A19;
  --lp-dark-2:    #211F1E;
  --lp-dark-3:    #2C2A28;
  --lp-fg:        #1B1A19;
  --lp-fg-2:      #45443F;
  --lp-fg-3:      #6B6A66;
  --lp-fg-4:      #8C8A85;
  --lp-border:    #E7E5E0;
  --lp-border-2:  #D8D5D0;
  --lp-white:     #FFFFFF;
  --lp-blue:      #5558D9;
  --lp-blue-dark: #4245B8;
  --lp-green:     #1F7A43;
  --lp-green-b:   #1F7A43;
  /* App window mockup tokens */
  --app-bg:       #FFFFFF;
  --app-panel:    #EFEDEA;
  --app-border:   #E7E5E0;
  --app-border-2: #D8D5D0;
  --app-text:     #1B1A19;
  --app-muted:    #8C8A85;
  --app-dim:      #B7B5AF;
  --app-green:    #1F7A43;
  --app-blue:     #5558D9;
  --app-amber:    #8F6A12;
  --f-sans: var(--fontInter);
  --f-mono: var(--fontMono);
  --r: var(--r6);
}

body {
  font-family: var(--fontInter);
  background: var(--surfaceCanvas);
  color: var(--textPrimary);
  line-height: 1.6;
}
a { color: var(--semanticAccent); text-decoration: none; }
a:hover { text-decoration: underline; }

* {
  scrollbar-color: var(--borderStrong) var(--surfaceSunken);
  scrollbar-width: thin;
}
*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
*::-webkit-scrollbar-track {
  background: var(--surfaceSunken);
}
*::-webkit-scrollbar-thumb {
  background: var(--borderStrong);
  border-radius: var(--r2);
}
*::-webkit-scrollbar-thumb:hover {
  background: var(--textMuted);
}

:where(a, button, input, select, textarea, [role="button"], [tabindex]):focus-visible {
  outline: 2px solid var(--semanticAccent);
  outline-offset: 2px;
}

/* ── Forms ───────────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: var(--sp12); }
.form-group label { display: block; color: var(--textSecondary); font-size: var(--bodySmall); font-weight: 500; margin-bottom: var(--sp4); }
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; min-height: var(--inputH); padding: 0 var(--sp8);
  background: var(--surfaceSunken);
  color: var(--textPrimary);
  border: 1px solid var(--borderHairline); border-radius: var(--r6);
  font-size: var(--bodyMedium); font-family: var(--fontInter);
  transition: border-color var(--motionFast), box-shadow var(--motionFast);
}
.form-group textarea { min-height: 72px; padding: var(--sp8); }
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--textMuted);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--semanticAccent);
  box-shadow: 0 0 0 3px var(--semanticAccentDim);
}
.form-error { color: var(--semanticError); font-size: var(--bodySmall); margin-top: var(--sp2); }

/* ── Buttons ─────────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: var(--hitTarget);
  height: var(--buttonH);
  gap: var(--sp4);
  padding: 0 var(--sp8); border: none; border-radius: var(--r6);
  font-size: var(--bodyMedium); font-weight: 500; cursor: pointer;
  text-decoration: none;
  transition: background var(--motionFast) var(--motionCurve), color var(--motionFast) var(--motionCurve), border-color var(--motionFast) var(--motionCurve), transform var(--motionFast) var(--motionCurve), filter var(--motionFast) var(--motionCurve);
}
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(.98); }
.btn:disabled,
.btn[aria-disabled="true"] {
  color: var(--textDisabled);
  opacity: .5;
  pointer-events: none;
}
.btn-primary   { background: var(--btnPrimaryBg); color: var(--btnPrimaryFg); }
.btn-primary:hover { background: var(--btnPrimaryHover); }
.btn-secondary {
  background: transparent;
  color: var(--textPrimary);
  border: 1px solid var(--borderStrong);
}
.btn-secondary:hover {
  background: var(--surfaceSunken);
  color: var(--textPrimary);
}
.btn-block     { width: 100%; }

/* ── Alerts ──────────────────────────────────────────────────────────────────── */
.page-messages {
  max-width: 1040px;
  margin: 0 auto;
}
.alert {
  --alert-accent: var(--semanticAccent);
  --alert-bg: var(--semanticAccentDim);
  display: flex;
  align-items: flex-start;
  gap: var(--sp8);
  padding: var(--sp12) var(--sp16);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r10);
  background: var(--alert-bg);
  color: var(--textPrimary);
  margin-bottom: var(--sp8);
  font: 400 var(--bodyMedium)/1.45 var(--fontInter);
}
.alert::before {
  content: "";
  flex: none;
  width: 7px;
  height: 7px;
  margin-top: 6px;
  border-radius: 50%;
  background: var(--alert-accent);
  box-shadow: 0 0 0 3px var(--alert-bg);
}
.alert-success { --alert-accent: var(--semanticSuccess); --alert-bg: var(--semanticSuccessDim); }
.alert-info    { --alert-accent: var(--semanticAccent);  --alert-bg: var(--semanticAccentDim); }
.alert-warning { --alert-accent: var(--semanticWarn);    --alert-bg: var(--semanticWarnDim); }
.alert-error, .alert-danger { --alert-accent: var(--semanticError); --alert-bg: var(--semanticErrorDim); }

/* ── Auth page ───────────────────────────────────────────────────────────────── */
.auth-wrapper {
  min-height: 100vh; display: flex;
  align-items: center; justify-content: center;
  background: var(--surfaceCanvas);
  padding: var(--sp16);
  gap: var(--sp24);
}
.auth-card {
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
  box-shadow: var(--elevation4);
  padding: var(--sp24);
  width: 100%; max-width: 416px;
}
.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--sp8);
  color: var(--textPrimary) !important;
  text-decoration: none;
  margin-bottom: var(--sp16);
}
.auth-brand:hover {
  color: var(--textPrimary) !important;
  text-decoration: none;
}
.auth-brand-mark {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: var(--r8);
  display: block;
}
.auth-brand-name {
  display: block;
  font-size: var(--titleSmall);
  font-weight: 600;
  line-height: 1.2;
}
.auth-title {
  font-size: var(--titleMedium);
  font-weight: 600;
  margin-bottom: var(--sp16);
}
.auth-consent {
  margin-top: var(--sp12);
  text-align: center;
  font-size: var(--labelSmall);
  line-height: 1.5;
  color: var(--textMuted);
}
.auth-footer { margin-top: var(--sp16); text-align: center; font-size: var(--bodySmall); color: var(--textSecondary); }
.auth-footer-sep { margin: 0 var(--sp4); color: var(--textMuted); }
.auth-description {
  color: var(--textMuted);
  font-size: var(--bodyMedium);
  margin-bottom: var(--sp24);
}

.social-auth-actions {
  display: grid;
  gap: var(--sp8);
  margin-bottom: var(--sp16);
}

.btn-social {
  background: transparent;
  border: 1px solid var(--borderStrong);
  color: var(--textPrimary);
  font-weight: 600;
}

.btn-social:hover {
  border-color: var(--textMuted);
  background: var(--surfaceSunken);
}

.auth-divider {
  text-align: center;
  margin: var(--sp16) 0;
  color: var(--textMuted);
  font-size: var(--labelSmall);
  text-transform: uppercase;
  letter-spacing: .01em;
}

.auth-wrapper--split {
  max-width: 980px;
  margin: 0 auto;
  justify-content: space-between;
}

.auth-side-panel {
  flex: 1;
  max-width: 480px;
  background: var(--surfacePanel);
  color: var(--textPrimary);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
  padding: var(--sp24);
  box-shadow: var(--elevation1);
}

.auth-side-panel h1 {
  font-size: var(--displayMedium);
  font-weight: 600;
  line-height: 1.15;
  margin-bottom: var(--sp8);
}

.auth-side-panel p {
  color: var(--textSecondary);
  font-size: var(--bodyMedium);
  margin-bottom: var(--sp16);
}

.auth-side-actions {
  display: flex;
  gap: var(--sp8);
  flex-wrap: wrap;
}
.auth-feature-list {
  display: grid;
  gap: var(--sp8);
  margin-bottom: var(--sp24);
}
.auth-feature-row {
  display: flex;
  align-items: center;
  gap: var(--sp8);
  color: var(--textSecondary);
  font-size: var(--bodyMedium);
}

.password-field {
  position: relative;
}
.password-field input {
  padding-right: calc(var(--buttonH) + var(--sp8));
}
.password-toggle {
  position: absolute;
  top: 50%;
  right: var(--sp4);
  display: inline-flex;
  width: var(--buttonH);
  height: var(--buttonH);
  align-items: center;
  justify-content: center;
  transform: translateY(-50%);
  color: var(--textMuted);
  background: transparent;
  border: 0;
  border-radius: var(--r6);
  cursor: pointer;
  transition: background var(--motionFast) var(--motionCurve), color var(--motionFast) var(--motionCurve);
}
.password-toggle:hover {
  background: var(--surfacePanel);
  color: var(--textPrimary);
}
.password-toggle__icon {
  width: var(--iconMd);
  height: var(--iconMd);
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.password-toggle__icon--hide {
  display: none;
}
.password-toggle[aria-pressed="true"] .password-toggle__icon--show {
  display: none;
}
.password-toggle[aria-pressed="true"] .password-toggle__icon--hide {
  display: block;
}

/* ── Utility ─────────────────────────────────────────────────────────────────── */
.mt-3 { margin-top: var(--sp16); }

@media (max-width: 900px) {
  .auth-wrapper--split {
    flex-direction: column;
    align-items: stretch;
  }

  .auth-side-panel,
  .auth-card {
    max-width: 100%;
  }
}

/* =============================================================================
   LANDING PAGE — Swiss Grid / Desktop Engineering Aesthetic
   Inspired by: Linear, Raycast, developer tools
   Prefix: lp- (landing page, isolated from portal styles)
   ============================================================================= */

/* ── Dark theme ────────────────────────────────────────────────────────────────
   Applied when <html data-theme="dark">. The theme script resolves the "auto"
   mode (prefers-color-scheme) to an explicit light/dark attribute before paint,
   so a single dark block covers both automatic and manual dark. Warm charcoal
   palette that mirrors the light warm-paper hierarchy (canvas < sunken < panel
   < raised). Only token values change — every component reads these tokens. */
html[data-theme="dark"] { color-scheme: dark; }
html[data-theme="light"] { color-scheme: light; }

html[data-theme="dark"] {
  --surfaceCanvas: #161615;
  --surfaceSunken: #121211;
  --surfacePanel:  #1E1E1D;
  --surfaceRaised: #242423;
  --textPrimary:   #ECEBE8;
  --textSecondary: #A6A5A0;
  --textMuted:     #7A7873;
  --textDisabled:  #55534E;
  --borderHairline: #33322E;
  --borderStrong:   #46443E;
  --semanticAccent:     #6B6EE8;
  --semanticAccentDim:  rgba(107,110,232,.16);
  --semanticSuccess:    #5FBF85;
  --semanticSuccessDim: rgba(95,191,133,.16);
  --semanticWarn:       #E3B45E;
  --semanticWarnDim:    rgba(227,180,94,.16);
  --semanticError:      #E06555;
  --semanticErrorDim:   rgba(224,101,85,.16);
  --elevation1: 0 1px 2px rgba(0,0,0,.4);
  --elevation2: 0 4px 14px rgba(0,0,0,.5);
  --elevation4: 0 16px 40px rgba(0,0,0,.6);
  /* Primary button – indigo accent on dark */
  --btnPrimaryBg:    #6B6EE8;
  --btnPrimaryFg:    #FFFFFF;
  --btnPrimaryHover: #7D80F0;
  /* Landing-page aliases */
  --lp-bg:        #161615;
  --lp-bg-2:      #1E1E1D;
  --lp-dark:      #242423;
  --lp-dark-2:    #121211;
  --lp-dark-3:    #2E2E2C;
  --lp-fg:        #ECEBE8;
  --lp-fg-2:      #A6A5A0;
  --lp-fg-3:      #7A7873;
  --lp-fg-4:      #605E59;
  --lp-border:    #33322E;
  --lp-border-2:  #46443E;
  --lp-white:     #1E1E1D;
  --lp-blue:      #6B6EE8;
  --lp-blue-dark: #8F93FF;
  --lp-green:     #5FBF85;
  --lp-green-b:   #5FBF85;
  /* App window tokens */
  --app-bg:       #1E1E1D;
  --app-panel:    #1A1A19;
  --app-border:   #33322E;
  --app-border-2: #46443E;
  --app-text:     #ECEBE8;
  --app-muted:    #7A7873;
  --app-dim:      #55534E;
  --app-green:    #5FBF85;
  --app-blue:     #6B6EE8;
  --app-amber:    #E3B45E;
}

.lp-body {
  background: var(--lp-bg);
  color: var(--lp-fg);
  font-family: var(--f-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  margin: 0;
  padding: 0;
  transition: background var(--motionBase) var(--motionCurve), color var(--motionBase) var(--motionCurve);
}

/* ── Theme toggle (inline nav control; cycles System → Light → Dark) ───────────── */
.theme-toggle {
  flex: none;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--pill);
  border: 1px solid var(--borderStrong);
  background: transparent;
  color: var(--textSecondary);
  cursor: pointer;
  transition: background var(--motionFast) var(--motionCurve), color var(--motionFast) var(--motionCurve), border-color var(--motionFast) var(--motionCurve);
}
.theme-toggle:hover { color: var(--textPrimary); border-color: var(--textMuted); background: var(--surfaceSunken); }
.theme-toggle:focus-visible { outline: 2px solid var(--semanticAccent); outline-offset: 2px; }
.theme-toggle svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.theme-toggle__icon { display: none; }
.theme-toggle:not([data-mode]) .theme-toggle__icon--auto,
.theme-toggle[data-mode="auto"] .theme-toggle__icon--auto,
.theme-toggle[data-mode="light"] .theme-toggle__icon--light,
.theme-toggle[data-mode="dark"]  .theme-toggle__icon--dark { display: block; }
.lp-body *, .lp-body *::before, .lp-body *::after { box-sizing: border-box; }
.lp-body a { color: var(--lp-blue); text-decoration: none; }
.lp-body a:hover { text-decoration: underline; }
.lp-body h1,.lp-body h2,.lp-body h3 { margin: 0; }
.lp-body p { margin: 0; }
.lp-body ul { margin: 0; padding: 0; }
.lp-body button { font-family: inherit; }
.lp-mt-10 { margin-top: 10px !important; }
.lp-mb-0  { margin-bottom: 0 !important; }

/* Container */
.lp-container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.lp-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--lp-white);
  border-bottom: 1px solid var(--lp-border);
  height: 56px;
}
.lp-nav-inner {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  height: 100%;
}
.lp-nav-left {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.lp-nav-collapse {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.lp-nav-burger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin-left: auto;
  padding: 0;
  color: var(--lp-fg);
  background: none;
  border: none;
  border-radius: var(--r6);
  cursor: pointer;
}
.lp-nav-burger:hover { background: var(--surfaceSunken); }
.lp-burger-top,
.lp-burger-mid,
.lp-burger-bot {
  transform-origin: center;
  transition: transform var(--motionFast) var(--motionCurve), opacity var(--motionFast) var(--motionCurve);
}
.lp-nav.is-open .lp-burger-top { transform: translateY(6px) rotate(45deg); }
.lp-nav.is-open .lp-burger-mid { opacity: 0; }
.lp-nav.is-open .lp-burger-bot { transform: translateY(-6px) rotate(-45deg); }
.lp-logo {
  display: inline-flex;
  align-items: center;
  gap: .625rem;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--lp-fg) !important;
  letter-spacing: 0;
  text-decoration: none;
}
.lp-logo:hover { color: var(--lp-fg) !important; text-decoration: none; }
.lp-logo--light { color: #ECEBE8 !important; }
.lp-logo--light:hover { color: #ECEBE8 !important; }
.lp-logo-mark {
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  display: block;
  border-radius: var(--r6);
}
.lp-nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}
.lp-nav-links a {
  font-size: 0.875rem;
  color: var(--lp-fg-3) !important;
  font-weight: 400;
  text-decoration: none;
  transition: color .15s;
}
.lp-nav-links a:hover,
.lp-nav-links a.lp-nav-link--active { color: var(--lp-fg); text-decoration: none; }
.lp-nav-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.lp-nav-form {
  margin: 0;
}
.lp-nav-button {
  background: none;
  border: none;
  cursor: pointer;
}
.lp-nav-text-link {
  font-size: 0.875rem;
  color: var(--lp-fg-3) !important;
  text-decoration: none;
}
.lp-nav-text-link:hover { color: var(--lp-fg) !important; text-decoration: none; }

/* ============================================================
   BUTTONS
   ============================================================ */
.lp-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--hitTarget);
  height: var(--buttonH);
  gap: var(--sp4);
  background: var(--btnPrimaryBg);
  color: var(--btnPrimaryFg) !important;
  font-family: var(--f-sans);
  font-size: var(--bodyMedium);
  font-weight: 500;
  padding: 0 var(--sp8);
  border-radius: var(--r6);
  border: 1px solid var(--btnPrimaryBg);
  cursor: pointer;
  text-decoration: none;
  transition: filter var(--motionFast) var(--motionCurve), transform var(--motionFast) var(--motionCurve), background var(--motionFast) var(--motionCurve), border-color var(--motionFast) var(--motionCurve);
  white-space: nowrap;
}
.lp-btn-primary:hover {
  background: var(--btnPrimaryHover);
  border-color: var(--btnPrimaryHover);
  color: var(--btnPrimaryFg) !important;
  text-decoration: none;
}
.lp-btn-primary:active { transform: scale(.98); }
.lp-btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--hitTarget);
  height: var(--buttonH);
  background: transparent;
  color: var(--textSecondary) !important;
  font-family: var(--f-sans);
  font-size: var(--bodyMedium);
  font-weight: 500;
  padding: 0 var(--sp8);
  border-radius: var(--r6);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--motionFast) var(--motionCurve), color var(--motionFast) var(--motionCurve), transform var(--motionFast) var(--motionCurve);
  white-space: nowrap;
}
.lp-btn-ghost:hover {
  background: var(--surfaceSunken);
  color: var(--textPrimary) !important;
  text-decoration: none;
}
.lp-btn-ghost:active { transform: scale(.98); }
.lp-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--hitTarget);
  height: var(--buttonH);
  background: transparent;
  color: var(--textPrimary) !important;
  font-family: var(--f-sans);
  font-size: var(--bodyMedium);
  font-weight: 500;
  padding: 0 var(--sp8);
  border-radius: var(--r6);
  border: 1px solid var(--borderStrong);
  cursor: pointer;
  text-decoration: none;
  transition: background var(--motionFast) var(--motionCurve), color var(--motionFast) var(--motionCurve), transform var(--motionFast) var(--motionCurve);
  white-space: nowrap;
}
.lp-btn-outline:hover {
  background: var(--surfaceSunken);
  color: var(--textPrimary) !important;
  text-decoration: none;
}
.lp-btn-outline:active { transform: scale(.98); }
.lp-btn-ghost-light {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--hitTarget);
  height: var(--buttonH);
  background: rgba(255,255,255,.1);
  color: rgba(255,255,255,.85);
  font-family: var(--f-sans);
  font-size: var(--bodyMedium);
  font-weight: 500;
  padding: 0 var(--sp8);
  border-radius: var(--r6);
  border: 1px solid rgba(255,255,255,.15);
  text-decoration: none;
  transition: background var(--motionFast) var(--motionCurve), transform var(--motionFast) var(--motionCurve);
  white-space: nowrap;
}
.lp-btn-ghost-light:hover {
  background: rgba(255,255,255,.18);
  text-decoration: none;
  color: #fff;
}
.lp-btn-ghost-light:active { transform: scale(.98); }
.lp-btn-lg {
  height: var(--buttonHLg) !important;
  min-height: var(--buttonHLg) !important;
  font-size: var(--titleSmall) !important;
  padding: 0 var(--sp16) !important;
}
.lp-btn-block { width: 100%; justify-content: center; }

/* ============================================================
   SECTION SHARED
   ============================================================ */
.lp-section-header { text-align: center; margin-bottom: 3.5rem; }
.lp-section-header--left { text-align: left; }
.lp-section-h2 {
  font-size: clamp(1.5rem, 2.5vw, 1.875rem);
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.2;
  color: var(--lp-fg);
  margin-bottom: .75rem;
}
.lp-section-sub {
  font-size: 1.0625rem;
  color: var(--lp-fg-3);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.65;
}
.lp-section-header--left .lp-section-sub { margin: 0; }

/* ============================================================
   HERO
   ============================================================ */
.lp-hero {
  padding: 5rem 0 4rem;
  background: var(--lp-white);
  border-bottom: 1px solid var(--lp-border);
  overflow: hidden;
}
.lp-hero-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 3rem;
  align-items: center;
}
.lp-hero-copy {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.lp-hero-h1 {
  font-size: clamp(2rem, 3.5vw, 2.875rem);
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.1;
  color: var(--lp-fg);
}
.lp-hero-sub {
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--lp-fg-3);
  max-width: 440px;
}
.lp-hero-actions {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
}
.lp-hero-meta {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--f-mono);
  font-size: 0.75rem;
  color: var(--lp-fg-4);
  flex-wrap: wrap;
}
.lp-meta-sep { color: var(--lp-border-2); }
.lp-hero-visual {
  display: flex;
  align-items: flex-start;
}

/* ============================================================
   TRUST STRIP
   ============================================================ */
.lp-trust-strip {
  background: var(--lp-white);
  border-bottom: 1px solid var(--lp-border);
  padding: .875rem 0;
}
.lp-trust-inner {
  display: flex;
  align-items: center;
  gap: .875rem;
  flex-wrap: wrap;
  font-size: 0.8125rem;
  color: var(--lp-fg-3);
}
.lp-trust-label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--lp-fg-4);
}
.lp-trust-sep { color: var(--lp-border-2); }

/* ============================================================
   APP WINDOW COMPONENT (shared)
   ============================================================ */
.lp-app-win {
  background: var(--app-bg);
  border: 1px solid var(--app-border);
  border-radius: var(--r8);
  overflow: hidden;
  width: 100%;
}
.lp-app-win--hero    { box-shadow: 0 28px 64px rgba(0,0,0,.16), inset 0 0 0 1px rgba(255,255,255,.5); }
.lp-app-win--feature { box-shadow: 0 16px 40px rgba(0,0,0,.12); }
.lp-app-win--gallery { box-shadow: 0 8px 24px rgba(0,0,0,.09); }
/* Dark mode: black drop-shadows vanish on a dark canvas, so lift the windows with a
   hairline top highlight + a deeper ambient shadow instead of the light-mode white inset. */
html[data-theme="dark"] .lp-app-win--hero    { box-shadow: 0 24px 60px rgba(0,0,0,.55), inset 0 1px 0 rgba(255,255,255,.05); }
html[data-theme="dark"] .lp-app-win--feature { box-shadow: 0 14px 36px rgba(0,0,0,.5),  inset 0 1px 0 rgba(255,255,255,.04); }
html[data-theme="dark"] .lp-app-win--gallery { box-shadow: 0 8px 22px rgba(0,0,0,.45),  inset 0 1px 0 rgba(255,255,255,.04); }

/* Titlebar */
.lp-app-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 36px;
  padding: 0 12px;
  background: var(--app-panel);
  border-bottom: 1px solid var(--app-border);
  flex-shrink: 0;
}
.lp-app-dots { display: flex; align-items: center; gap: 6px; }
.lp-dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.lp-dot--r { background: #FF5F57; }
.lp-dot--y { background: #FEBC2E; }
.lp-dot--g { background: #28C840; }
.lp-app-title {
  font-family: var(--f-sans);
  font-size: 11px;
  color: var(--app-muted);
  letter-spacing: .01em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lp-app-titlebar-spacer { width: 52px; flex-shrink: 0; }

/* Three-panel body */
.lp-app-body { display: flex; min-height: 280px; }
.lp-app-body--single { min-height: 200px; }

/* Panels */
.lp-app-panel {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--app-border);
}
.lp-app-panel:last-child { border-right: none; }
.lp-panel--side {
  width: 160px;
  flex-shrink: 0;
  padding: 10px 0;
}
.lp-panel--main { flex: 1; min-width: 0; }
.lp-panel--preview {
  width: 130px;
  flex-shrink: 0;
  padding: 10px 8px;
  align-items: center;
}
.lp-panel--xml {
  width: 165px;
  flex-shrink: 0;
  padding: 10px 0;
}

/* Section label in app */
.lp-app-section-label {
  font-family: var(--f-mono);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: .1em;
  color: var(--app-muted);
  text-transform: uppercase;
  padding: 0 10px;
  margin-bottom: 6px;
  margin-top: 2px;
}

/* Device items */
.lp-app-device {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 5px 10px;
}
.lp-device--active { background: var(--semanticAccentDim); }
.lp-device-name {
  font-family: var(--f-sans);
  font-size: 11px;
  font-weight: 500;
  color: var(--app-text);
  line-height: 1.2;
}
.lp-device-meta {
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--app-muted);
  line-height: 1.2;
  margin-top: 1px;
}
.lp-app-preset {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--app-muted);
  padding: 3px 10px;
  line-height: 1.4;
}
.lp-preset--active { color: var(--app-text); }

/* Status Dot – updated to 8×8pt per design system */
.lp-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
}
.lp-status--success { background: var(--semanticSuccess); }
.lp-status--warning { background: var(--semanticWarn); }
.lp-status--error   { background: var(--semanticError); }
.lp-status--info    { background: var(--semanticAccent); }
.lp-status--gray    { background: var(--app-dim); }
.lp-status--green   { background: var(--semanticSuccess); }
.lp-status--blue    { background: var(--semanticAccent); }

/* Pulse animation */
.lp-pulse { animation: lp-pulse 1.2s ease-in-out infinite; }
@keyframes lp-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .35; }
}

/* Toolbar */
.lp-app-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 12px;
  border-bottom: 1px solid var(--app-border);
  flex-shrink: 0;
}
.lp-toolbar-actions { display: flex; gap: 6px; }
.lp-app-run-btn {
  font-family: var(--f-mono);
  font-size: 10px;
  font-weight: 500;
  background: var(--app-blue);
  color: #fff;
  border: none;
  padding: 3px 10px;
  border-radius: 3px;
  cursor: default;
  letter-spacing: .02em;
}
/* ToolbarButton – primary action button used in toolbars */
.lp-toolbar-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: var(--buttonH);
  min-height: var(--hitTarget);
  padding: 0 var(--sp8);
  font-family: var(--f-sans);
  font-size: var(--labelSmall);
  font-weight: 500;
  color: var(--btnPrimaryFg);
  background: var(--btnPrimaryBg);
  border: none;
  border-radius: var(--r6);
  cursor: pointer;
  transition: background var(--motionFast), opacity var(--motionFast);
}
.lp-toolbar-btn:hover {
  background: var(--btnPrimaryHover);
  opacity: 1;
}

/* Automation steps */
.lp-app-step {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 7px 12px;
  border-bottom: 1px solid var(--app-border);
  font-family: var(--f-mono);
  font-size: 11px;
}
.lp-app-step:last-of-type { border-bottom: none; }
.lp-step-icon { flex-shrink: 0; width: 14px; text-align: center; font-size: 10px; }
.lp-step-cmd  { flex-shrink: 0; color: var(--app-text); }
.lp-step-arg  { color: var(--app-muted); font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lp-step--done .lp-step-icon { color: var(--app-green); }
.lp-step--done .lp-step-cmd  { color: var(--app-dim); }
.lp-step--done .lp-step-arg  { opacity: .55; }
.lp-step--running { background: var(--semanticAccentDim); }
.lp-step--running .lp-step-icon { color: var(--app-blue); }
.lp-step--running .lp-step-cmd  { color: var(--app-text); }
.lp-step--pending .lp-step-icon { color: var(--app-dim); }
.lp-step--pending .lp-step-cmd  { color: var(--app-dim); }
.lp-step--pending .lp-step-arg  { opacity: .45; }

/* Progress row */
.lp-app-progress-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-top: 1px solid var(--app-border);
  margin-top: auto;
}
.lp-app-progress-track { flex: 1; height: 3px; background: var(--app-border); border-radius: 2px; overflow: hidden; }
.lp-app-progress-fill  { height: 100%; background: var(--app-blue); border-radius: 2px; }
.lp-app-progress-label { font-family: var(--f-mono); font-size: 9px; color: var(--app-muted); flex-shrink: 0; }

/* Phone preview */
.lp-phone-frame {
  width: 68px;
  height: 120px;
  background: #101010;
  border: 1.5px solid var(--app-border-2);
  border-radius: var(--r10);
  overflow: hidden;
  margin: 0 auto 8px;
  flex-shrink: 0;
}
.lp-phone-notch {
  width: 24px;
  height: 5px;
  background: var(--app-border-2);
  border-radius: 0 0 4px 4px;
  margin: 0 auto;
}
.lp-phone-screen {
  padding: 3px 4px 4px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.lp-ui-bar { border-radius: 2px; width: 100%; display: block; }
.lp-ui-bar--nav   { height: 7px; background: var(--app-blue); opacity: .9; }
.lp-ui-bar--hero  { height: 28px; background: #262338; }
.lp-ui-bar--text  { height: 4px; background: var(--app-dim); }
.lp-ui-bar--short { width: 60% !important; }
.lp-ui-bar--btn   { height: 7px; width: 45% !important; background: var(--app-blue); border-radius: 2px; margin: 2px 0; }
.lp-capture-status {
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--app-muted);
}

/* App statusbar */
.lp-app-statusbar {
  display: flex;
  justify-content: space-between;
  padding: 4px 12px;
  background: var(--app-panel);
  border-top: 1px solid var(--app-border);
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--app-muted);
  flex-shrink: 0;
}

/* XML tree */
.lp-xml-tree { padding: 0 8px; }
.lp-xml-node {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--app-dim);
  padding: 2px 0;
  white-space: nowrap;
}
.lp-xml-depth-0 { padding-left: 0; color: var(--app-text); }
.lp-xml-depth-1 { padding-left: 10px; }
.lp-xml-depth-2 { padding-left: 20px; }
.lp-xml-node--selected {
  color: var(--app-blue) !important;
  background: var(--semanticAccentDim);
  padding-left: 18px !important;
  border-left: 2px solid var(--app-blue);
}
.lp-xml-attr {
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--app-muted);
  padding: 1px 0 1px 26px;
  white-space: nowrap;
}

/* ============================================================
   FEATURES
   ============================================================ */
.lp-features { padding: 5rem 0; background: var(--lp-white); }
.lp-feature-row {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 4rem;
  align-items: center;
  padding: 3.5rem 0;
  border-top: 1px solid var(--lp-border);
}
.lp-feature-row:first-child { border-top: none; padding-top: 0; }
.lp-feature-row--alt { grid-template-columns: 7fr 5fr; }
.lp-feature-row--alt .lp-feature-copy   { order: 2; }
.lp-feature-row--alt .lp-feature-visual { order: 1; }
.lp-feature-h2 {
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.2;
  color: var(--lp-fg);
  margin-bottom: .875rem;
}
.lp-feature-desc {
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--lp-fg-3);
  margin-bottom: 1.25rem;
}
.lp-feature-list { list-style: none; display: flex; flex-direction: column; gap: .5rem; }
.lp-feature-list li {
  font-size: 0.875rem;
  color: var(--lp-fg-2);
  padding-left: 1.1rem;
  position: relative;
  line-height: 1.55;
}
.lp-feature-list li::before {
  content: '\2014';
  position: absolute;
  left: 0;
  color: var(--lp-border-2);
  font-size: 0.75rem;
  top: 0.1em;
}

/* Device manager feature mockup */
.lp-device-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 12px;
  border-bottom: 1px solid var(--app-border);
}
.lp-badge {
  font-family: var(--f-mono);
  font-size: 9px;
  padding: 2px 7px;
  border-radius: 3px;
}
.lp-badge--green { background: var(--semanticSuccessDim); color: var(--app-green); }
.lp-badge--gray  { background: var(--surfaceSunken); color: var(--app-muted); }
.lp-device-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--app-border);
}
.lp-device-card--active  { background: var(--semanticAccentDim); }
.lp-device-card--offline { opacity: .5; }
.lp-device-card-info { flex: 1; min-width: 0; }
.lp-device-badge {
  font-family: var(--f-mono);
  font-size: 9px;
  padding: 2px 7px;
  border-radius: 3px;
  background: var(--app-border);
  color: var(--app-muted);
  flex-shrink: 0;
}
.lp-connect-row {
  display: flex;
  gap: 6px;
  padding: 8px 12px;
  align-items: center;
}
.lp-adb-input {
  flex: 1;
  background: var(--app-border);
  border: 1px solid var(--app-border-2);
  border-radius: 3px;
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--app-muted);
  padding: 3px 7px;
  display: inline-block;
}

/* Preset editor feature mockup */
.lp-step-editor-row {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border-bottom: 1px solid var(--app-border);
}
.lp-step-editor-row--active { background: var(--semanticAccentDim); }
.lp-step-num {
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--app-muted);
  width: 12px;
  flex-shrink: 0;
}
.lp-step-select-mock {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--app-text);
  background: var(--app-border);
  border: 1px solid var(--app-border-2);
  border-radius: 3px;
  padding: 2px 6px;
  flex-shrink: 0;
}
.lp-step-val {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--app-muted);
  background: var(--app-panel);
  border: 1px solid var(--app-border);
  border-radius: 3px;
  padding: 2px 6px;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Export tree feature mockup */
.lp-export-tree { padding: 8px 12px; }
.lp-tree-entry {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--app-muted);
  padding: 2px 0;
  white-space: nowrap;
}
.lp-tree-entry--dir { color: var(--app-text); font-weight: 500; }
.lp-tree-depth-0 { padding-left: 0; }
.lp-tree-depth-1 { padding-left: 14px; }
.lp-tree-depth-2 { padding-left: 28px; }
.lp-file-meta { color: var(--app-dim); font-size: 9px; margin-left: 6px; }
.lp-export-summary {
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--app-green);
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid var(--app-border);
}

/* ============================================================
   WORKFLOW
   ============================================================ */
.lp-workflow {
  padding: 5rem 0;
  background: var(--lp-dark);
}
.lp-workflow .lp-section-h2 { color: #ECEBE8; }
.lp-workflow .lp-section-sub { color: #A6A5A0; }
.lp-workflow-steps {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr;
  align-items: flex-start;
  margin-top: 3rem;
}
.lp-wf-step { }
.lp-wf-connector {
  display: flex;
  align-items: flex-start;
  padding-top: 17px;
  padding: 17px 1.25rem 0;
  color: #6B6962;
  font-size: 1.125rem;
}
.lp-wf-connector::after { content: '\2192'; }
.lp-wf-num {
  font-size: 0.875rem;
  font-weight: 600;
  color: #7A7873;
  margin-bottom: .5rem;
}
.lp-wf-title {
  font-size: 1rem;
  font-weight: 600;
  color: #ECEBE8;
  letter-spacing: 0;
  margin-bottom: .625rem;
}
.lp-wf-desc {
  font-size: 0.875rem;
  color: #A6A5A0;
  line-height: 1.65;
}

/* ============================================================
   GALLERY
   ============================================================ */
.lp-gallery {
  padding: 5rem 0;
  background: var(--lp-bg-2);
  border-top: 1px solid var(--lp-border);
  border-bottom: 1px solid var(--lp-border);
}
.lp-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.lp-gallery-label {
  font-size: 0.8125rem;
  color: var(--lp-fg-3);
  margin-top: .75rem;
  font-weight: 500;
}
.lp-gallery-body {
  padding: 12px;
}
.lp-gallery-body--centered {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 12px;
}
.lp-gallery-step {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--app-dim);
  padding: 5px 8px;
  border-bottom: 1px solid var(--app-border);
}
.lp-gallery-step--done    { color: var(--app-green); opacity: .75; }
.lp-gallery-step--running { color: var(--app-blue); background: var(--semanticAccentDim); }
.lp-export-done-check  { font-size: 1.5rem; color: var(--app-green); font-weight: 700; }
.lp-export-done-count  { font-family: var(--f-mono); font-size: 11px; color: var(--app-text); }
.lp-export-done-path   { font-family: var(--f-mono); font-size: 9px; color: var(--app-muted); }
.lp-export-done-bundles { font-family: var(--f-mono); font-size: 9px; color: var(--app-blue); }

/* ============================================================
   PRICING
   ============================================================ */
.lp-pricing { padding: 5rem 0; background: var(--lp-white); }
.lp-pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--lp-border);
  border: 1px solid var(--lp-border);
  border-radius: var(--r14);
  overflow: hidden;
}
/* In-portal plan chooser shows only Pro + Team → two centred columns. */
.lp-pricing-grid--portal {
  grid-template-columns: repeat(2, 1fr);
  max-width: 760px;
  margin: 0 auto;
}
/* Float the "most popular" label as a corner badge so it doesn't push the
   featured card's rows down — keeps both cards' features/prices aligned. */
.lp-pricing-grid--portal .lp-pricing-featured-label {
  position: absolute;
  top: 1.15rem;
  right: 1.15rem;
  margin: 0;
  padding: .2rem .55rem;
  background: rgba(255, 255, 255, .16);
  border-radius: var(--pill);
}
/* Billing period toggle (Monthly / Yearly) above the plan chooser. */
.pd-period-row { text-align: center; margin-bottom: 1.5rem; }
.pd-period-toggle {
  display: inline-flex;
  gap: .25rem;
  padding: .25rem;
  background: var(--lp-bg-2);
  border: 1px solid var(--lp-border);
  border-radius: var(--pill);
}
.pd-period-opt {
  border: 0;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
  font-size: .875rem;
  font-weight: 500;
  color: var(--lp-fg-3);
  padding: .4rem .95rem;
  border-radius: var(--pill);
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  transition: background .15s ease, color .15s ease;
}
.pd-period-opt.is-active { background: var(--lp-blue); color: #FFFFFF; }
.pd-period-save {
  font-family: var(--f-mono);
  font-size: .66rem;
  font-weight: 600;
  padding: .1rem .4rem;
  border-radius: var(--pill);
  background: var(--semanticSuccessDim);
  color: var(--lp-green);
}
.pd-period-opt.is-active .pd-period-save { background: rgba(255, 255, 255, .22); color: #FFFFFF; }

/* Show only the active period's price/permo/savings. */
.pd-plans-wrap[data-period="yearly"] [data-show="monthly"],
.pd-plans-wrap[data-period="monthly"] [data-show="yearly"] { display: none; }

/* Yearly-first pricing: per-month equivalent + savings badge. */
.pd-plan-permo {
  font-size: .8125rem;
  color: var(--lp-fg-3);
  margin: -.15rem 0 .6rem;
}
.lp-pricing-col--featured .pd-plan-permo { color: rgba(255, 255, 255, .72); }
.pd-plan-save {
  display: inline-block;
  font-family: var(--f-mono);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .01em;
  padding: .2rem .55rem;
  border-radius: var(--pill);
  margin-bottom: 1.25rem;
  background: var(--semanticSuccessDim);
  color: var(--lp-green);
}
.lp-pricing-col--featured .pd-plan-save {
  background: rgba(255, 255, 255, .18);
  color: #FFFFFF;
}
.lp-pricing-col {
  background: var(--lp-white);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
}
.lp-pricing-col--featured { background: var(--lp-blue); }
.lp-pricing-featured-label {
  font-family: var(--f-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255,255,255,.72);
  margin-bottom: .75rem;
}
.lp-pricing-tier {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--lp-fg);
  margin-bottom: .5rem;
}
.lp-pricing-col--featured .lp-pricing-tier { color: #FFFFFF; }
.lp-pricing-price {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--lp-fg);
  line-height: 1;
  margin-bottom: .5rem;
}
.lp-pricing-col--featured .lp-pricing-price { color: #FFFFFF; }
.lp-price-period { font-size: 0.875rem; font-weight: 400; color: var(--lp-fg-3); letter-spacing: 0; }
.lp-pricing-col--featured .lp-price-period { color: rgba(255,255,255,.72); }
.lp-pricing-desc {
  font-size: 0.875rem;
  color: var(--lp-fg-3);
  line-height: 1.5;
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--lp-border);
}
.lp-pricing-col--featured .lp-pricing-desc { color: rgba(255,255,255,.75); border-bottom-color: rgba(255,255,255,.18); }
.lp-pricing-features {
  list-style: none;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin-bottom: 1.5rem;
}
.lp-pricing-features li {
  font-size: 0.875rem;
  padding-left: 1.25rem;
  position: relative;
  line-height: 1.5;
}
.lp-pricing-features li::before { position: absolute; left: 0; font-size: 0.75rem; top: 0.1em; }
.lp-pricing-features li.yes { color: var(--lp-fg-2); }
.lp-pricing-col--featured .lp-pricing-features li.yes { color: rgba(255,255,255,.9); }
.lp-pricing-col--featured .lp-pricing-features li.yes::before { color: #FFFFFF; }
.lp-pricing-features li.yes::before { content: '\2713'; color: var(--lp-green); }
.lp-pricing-features li.no  { color: var(--lp-fg-4); }
.lp-pricing-col--featured .lp-pricing-features li.no  { color: rgba(255,255,255,.55); }
.lp-pricing-features li.no::before  { content: '\2013'; color: var(--lp-border-2); }
.lp-pricing-note {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.8125rem;
  color: var(--lp-fg-4);
}
/* Pro column button override */
.lp-pricing-col--featured .lp-btn-primary { background: #FFFFFF; color: var(--lp-blue) !important; border-color: #FFFFFF; }
.lp-pricing-col--featured .lp-btn-primary:hover { background: #EEF0FF; border-color: #EEF0FF; color: var(--lp-blue-dark) !important; }

/* ============================================================
   FAQ
   ============================================================ */
.lp-faq {
  padding: 5rem 0;
  background: var(--lp-bg-2);
  border-top: 1px solid var(--lp-border);
}
.lp-faq-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--lp-border);
  border: 1px solid var(--lp-border);
  border-radius: var(--r14);
  overflow: hidden;
}
.lp-faq-item { background: var(--lp-white); padding: 1.5rem; }
.lp-faq-q {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--lp-fg);
  margin-bottom: .5rem;
  letter-spacing: 0;
}
.lp-faq-a { font-size: 0.875rem; color: var(--lp-fg-3); line-height: 1.68; }
.lp-faq-a a { color: var(--lp-blue); }

/* ============================================================
   CTA BAND
   ============================================================ */
.lp-cta-band {
  background: var(--lp-dark);
  padding: 4rem 0;
  border-top: 1px solid rgba(255,255,255,.08);
}
.lp-cta-band-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.lp-cta-band-h {
  font-size: 1.625rem;
  font-weight: 600;
  color: #ECEBE8;
  letter-spacing: 0;
  margin-bottom: .375rem;
}
.lp-cta-band-sub { font-size: 0.9375rem; color: #A6A5A0; }
.lp-cta-band-actions { display: flex; gap: .75rem; flex-shrink: 0; flex-wrap: wrap; }

/* ============================================================
   FOOTER
   ============================================================ */
.lp-footer {
  background: var(--lp-dark-2);
  padding: 3rem 0 0;
  border-top: 1px solid rgba(255,255,255,.08);
}
.lp-footer-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
  padding-bottom: 2.5rem;
}
.lp-footer-tagline { font-size: 0.8125rem; color: var(--textMuted); max-width: 220px; line-height: 1.5; margin-top: .5rem; }
.lp-footer-nav { display: flex; gap: 3rem; flex-wrap: wrap; }
.lp-footer-col { display: flex; flex-direction: column; gap: .5rem; }
.lp-footer-col-label {
  font-family: var(--f-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--textMuted);
  margin-bottom: .25rem;
}
.lp-footer-col a { font-size: 0.875rem; color: #A6A5A0; text-decoration: none; transition: color .15s; }
.lp-footer-col a:hover { color: #ECEBE8; text-decoration: none; }
.lp-footer-bottom { border-top: 1px solid rgba(255,255,255,.08); padding: 1rem 0; }
.lp-footer-bottom-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .5rem;
  font-size: 0.75rem;
  color: #6B6962;
  font-family: var(--f-mono);
}

/* ============================================================
   DASHBOARD / PORTAL
   ============================================================ */
.lp-main {
  padding: 2.5rem 0 4rem;
  min-height: calc(100vh - 56px);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .lp-hero { padding: 3.5rem 0 3rem; }
  .lp-hero-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .lp-app-body { min-height: 220px; }
  .lp-panel--preview { width: 100px; }
  .lp-workflow-steps { grid-template-columns: 1fr; gap: 2rem; }
  .lp-wf-connector { display: none; }
}
@media (max-width: 768px) {
  /* Mobile nav: collapse links + account into a burger dropdown */
  .lp-nav-burger { display: inline-flex; }
  .lp-nav-collapse {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: var(--sp8) 0;
    background: var(--lp-white);
    border-bottom: 1px solid var(--lp-border);
    box-shadow: var(--elevation2);
  }
  .lp-nav.is-open .lp-nav-collapse { display: flex; }
  .lp-nav-links {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .lp-nav-links a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0 2rem;
  }
  .lp-nav-right {
    flex-direction: column;
    align-items: stretch;
    gap: var(--sp4);
    margin-top: var(--sp8);
    padding: var(--sp12) 2rem 0;
    border-top: 1px solid var(--lp-border);
  }
  .lp-nav-right .lp-nav-text-link {
    display: flex;
    align-items: center;
    min-height: 44px;
  }
  .lp-nav-right .lp-btn-primary {
    height: 44px;
    justify-content: center;
  }

  .lp-hero { padding: 2.5rem 0 2rem; }
  .lp-hero-grid { grid-template-columns: 1fr; }
  .lp-hero-visual { display: none; }

  /* Dense desktop mockups are illegible/clipped on phones — drop them */
  .lp-feature-visual { display: none; }
  .lp-feature-row { grid-template-columns: 1fr !important; gap: 2rem; padding: 2.5rem 0; }
  .lp-feature-row--alt .lp-feature-copy,
  .lp-feature-row--alt .lp-feature-visual { order: unset; }

  /* Tighter vertical rhythm so the page isn't mostly empty space */
  .lp-features,
  .lp-workflow,
  .lp-gallery,
  .lp-pricing,
  .lp-faq,
  .lp-cta-band { padding: 3rem 0; }

  .lp-gallery-grid { grid-template-columns: 1fr; }
  .lp-pricing-grid { grid-template-columns: 1fr; }
  .lp-faq-grid { grid-template-columns: 1fr; }
  .lp-cta-band-inner { flex-direction: column; align-items: flex-start; }
  .lp-footer-nav { gap: 2rem; }

  /* Comfortable tap targets */
  .lp-btn-block { height: 44px; min-height: 44px; }
  .lp-hero-actions .lp-btn-lg,
  .lp-cta-band-actions .lp-btn-lg { width: 100%; }
}
@media (max-width: 480px) {
  .lp-container { padding: 0 1rem; }
  .lp-hero-h1 { font-size: 1.75rem; }
  .lp-section-h2 { font-size: 1.375rem; }
  .lp-pricing-col { padding: 1.5rem; }
  .lp-faq-item { padding: 1.25rem; }
}

/* ============================================================
   PORTAL SHARED — status pills, storage bar, screenshot grid,
   lightbox. Used by the pd-* portal pages.
   ============================================================ */

.lp-status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp4);
  font-size: var(--labelSmall);
  font-weight: 500;
  letter-spacing: .01em;
  padding: var(--sp4) var(--sp8);
  border-radius: var(--pill);
  white-space: nowrap;
}
.lp-status-pill--active {
  background: var(--semanticSuccessDim);
  color: var(--semanticSuccess);
}
.lp-status-pill--on_trial {
  background: var(--semanticAccentDim);
  color: var(--semanticAccent);
}
.lp-status-pill--cancelled {
  background: var(--semanticErrorDim);
  color: var(--semanticError);
}
.lp-status-pill--expired {
  background: var(--surfaceSunken);
  color: var(--textMuted);
}
.lp-status-pill--paused {
  background: var(--semanticWarnDim);
  color: var(--semanticWarn);
}
.lp-status-pill--none {
  background: var(--surfaceSunken);
  color: var(--textMuted);
}

.lp-empty {
  color: var(--textMuted);
  font-size: var(--bodyMedium);
  margin: 0;
}

.lp-storage-bar {
  position: relative;
  height: var(--sp8);
  width: 100%;
  background: var(--surfaceSunken);
  border-radius: var(--pill);
  overflow: hidden;
  margin: var(--sp8) 0;
}
.lp-storage-bar__fill {
  display: block;
  height: 100%;
  min-width: 2px;
  background: var(--semanticAccent);
  transition: width var(--motionSlow) var(--motionCurve);
}
.lp-storage-bar--warn .lp-storage-bar__fill {
  background: var(--semanticWarn);
}

.lp-screenshot-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.5rem;
}
@media (max-width: 900px) {
  .lp-screenshot-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (max-width: 600px) {
  .lp-screenshot-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
.lp-screenshot-thumb {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  border-radius: var(--r);
  overflow: hidden;
  background: var(--lp-bg-2);
  text-decoration: none;
  color: inherit;
}
.lp-screenshot-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.lp-screenshot-thumb-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--lp-fg-3);
  font-size: 0.75rem;
  text-align: center;
  padding: 0.5rem;
}
.lp-screenshot-thumb-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0.375rem 0.5rem;
  background: linear-gradient(to top, rgba(0,0,0,0.65), transparent);
  color: #fff;
  font-size: 0.6875rem;
  display: flex;
  justify-content: space-between;
  gap: 0.375rem;
  opacity: 0;
  transition: opacity var(--motionFast) var(--motionCurve);
}
.lp-screenshot-thumb:hover .lp-screenshot-thumb-caption {
  opacity: 1;
}
.lp-screenshot-thumb:hover img {
  opacity: 0.85;
}

/* ── Lightbox overlay ───────────────────────────────────────────────── */
.lb-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.lb-overlay[hidden] {
  display: none;
}
.lb-img {
  max-width: 92vw;
  max-height: 92vh;
  object-fit: contain;
  cursor: default;
  border-radius: var(--r6);
  user-select: none;
}
.lb-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  background: none;
  border: none;
  color: #fff;
  font-size: 2.5rem;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity var(--motionFast) var(--motionCurve);
  line-height: 1;
}
.lb-close:hover {
  opacity: 1;
}
.lb-prev,
.lb-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #fff;
  font-size: 3rem;
  cursor: pointer;
  opacity: 0.5;
  transition: opacity var(--motionFast) var(--motionCurve);
  line-height: 1;
  padding: 0.5rem;
}
.lb-prev:hover,
.lb-next:hover {
  opacity: 1;
}
.lb-prev {
  left: 1rem;
}
.lb-next {
  right: 1rem;
}

/* ============================================================
   AUTH PAGES (login / register / password reset)
   ============================================================ */
.portal-auth-body {
  background: var(--surfaceCanvas);
  color: var(--textPrimary);
  font: 400 13px/1.45 var(--fontInter);
}

.portal-auth-body .auth-wrapper {
  min-height: 100vh;
  max-width: none;
  display: grid;
  grid-template-columns: minmax(300px, 420px) minmax(340px, 440px);
  align-items: stretch;
  align-content: center;
  justify-content: center;
  gap: var(--sp24);
  padding: var(--sp48) var(--sp24);
  background: var(--surfaceCanvas);
}

.portal-auth-body .auth-side-panel,
.portal-auth-body .auth-card {
  border-radius: var(--r14);
  border: 1px solid var(--borderHairline);
  background: var(--surfacePanel);
  box-shadow: none;
  display: flex;
  flex-direction: column;
}

.portal-auth-body .auth-side-panel {
  max-width: 420px;
  padding: var(--sp32);
}

/* The form card is the primary surface — lift it above the canvas. */
.portal-auth-body .auth-card {
  max-width: 440px;
  padding: var(--sp32);
  background: var(--surfaceRaised);
  box-shadow: var(--elevation2);
}

.portal-auth-body .auth-brand {
  margin-bottom: var(--sp24);
}

.portal-auth-body .auth-brand-mark {
  width: 36px;
  height: 36px;
  border-radius: var(--r6);
}

.portal-auth-body .auth-side-panel h1 {
  color: var(--textPrimary);
  font: 600 24px/1.2 var(--fontInter);
  letter-spacing: -.01em;
  margin-bottom: var(--sp8);
}

/* Feature list → indigo check chips */
.portal-auth-body .auth-side-panel ul {
  list-style: none;
  margin: var(--sp16) 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.portal-auth-body .auth-side-panel ul li {
  position: relative;
  padding-left: 22px;
  color: var(--textSecondary);
  font: 400 13.5px/1.45 var(--fontInter);
}
.portal-auth-body .auth-side-panel ul li::before {
  content: '\2713';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--semanticAccent);
  font: 600 13px/1.45 var(--fontInter);
}
.portal-auth-body .auth-side-actions {
  margin-top: auto;
  padding-top: var(--sp24);
}

.portal-auth-body .auth-side-panel p,
.portal-auth-body .auth-feature-row,
.portal-auth-body .auth-footer {
  color: var(--textSecondary);
  font: 400 13px/1.45 var(--fontInter);
}

.portal-auth-body .auth-title {
  color: var(--textPrimary);
  font: 600 18px/1.25 var(--fontInter);
  letter-spacing: -.01em;
  margin-bottom: var(--sp24);
}

.portal-auth-body .auth-divider {
  color: var(--textMuted);
  font: 500 11px/1.25 var(--fontInter);
  letter-spacing: .01px;
}

/* Form fields — clearly defined inputs with an indigo focus ring */
.portal-auth-body .form-group {
  margin-bottom: var(--sp16);
}
.portal-auth-body .form-group label {
  font: 500 12px/1.3 var(--fontInter);
  color: var(--textSecondary);
  margin-bottom: 6px;
}
.portal-auth-body .form-group input {
  height: var(--buttonHLg);
  padding: 0 var(--sp12);
  background: var(--surfaceSunken);
  border: 1px solid var(--borderStrong);
  border-radius: var(--r6);
  font: 400 14px/1 var(--fontInter);
  color: var(--textPrimary);
}
.portal-auth-body .form-group input::placeholder { color: var(--textMuted); }
.portal-auth-body .form-group input:focus {
  outline: none;
  border-color: var(--semanticAccent);
  box-shadow: 0 0 0 3px var(--semanticAccentDim);
}

.portal-auth-body .btn,
.portal-auth-body .btn-primary,
.portal-auth-body .btn-secondary,
.portal-auth-body .btn-social {
  height: var(--buttonHLg);
  min-height: var(--buttonHLg);
  border-radius: var(--r6);
  font: 600 13px/1 var(--fontInter);
}

.portal-auth-body .btn-primary {
  color: var(--btnPrimaryFg);
  background: var(--btnPrimaryBg);
}

.portal-auth-body .btn-secondary,
.portal-auth-body .btn-social {
  color: var(--textPrimary);
  background: transparent;
  border: 1px solid var(--borderStrong);
}

.portal-auth-body .password-toggle {
  width: var(--buttonH);
  height: var(--buttonH);
}

/* Desktop app authorization — a focused, single-card auth surface. */
.portal-auth-body .desktop-login-wrapper {
  grid-template-columns: minmax(0, 480px);
}

.portal-auth-body .desktop-login-card {
  width: 100%;
  max-width: 480px;
  min-height: 0;
}

.desktop-login-heading {
  display: flex;
  align-items: center;
  gap: var(--sp12);
  margin-bottom: var(--sp16);
}

.desktop-login-heading .auth-title,
.desktop-login-result .auth-title {
  margin: 2px 0 0;
}

.desktop-login-eyebrow {
  color: var(--textMuted);
  font: 500 10px/1.25 var(--fontMono);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.desktop-login-state-icon {
  display: inline-flex;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--borderHairline);
  border-radius: var(--r10);
}

.desktop-login-state-icon svg,
.desktop-login-notice svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.desktop-login-state-icon--pending {
  color: var(--semanticAccent);
  background: var(--semanticAccentDim);
}

.desktop-login-state-icon--success {
  color: var(--semanticSuccess);
  background: var(--semanticSuccessDim);
}

.desktop-login-state-icon--neutral {
  color: var(--textSecondary);
  background: var(--surfaceSunken);
}

.desktop-login-state-icon--error {
  color: var(--semanticError);
  background: var(--semanticErrorDim);
}

.desktop-login-copy {
  margin: 0 0 var(--sp20);
  color: var(--textSecondary);
  font: 400 13.5px/1.55 var(--fontInter);
}

.desktop-login-details {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--borderHairline);
  border-radius: var(--r8);
  background: var(--surfaceSunken);
}

.desktop-login-detail-row {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: var(--sp12);
  align-items: center;
  padding: 11px var(--sp12);
}

.desktop-login-detail-row + .desktop-login-detail-row {
  border-top: 1px solid var(--borderHairline);
}

.desktop-login-detail-row dt {
  color: var(--textMuted);
  font: 500 10px/1.3 var(--fontMono);
  letter-spacing: .04em;
  text-transform: uppercase;
}

.desktop-login-detail-row dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--textPrimary);
  font: 500 13px/1.4 var(--fontInter);
}

.desktop-login-notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: var(--sp12);
  padding: var(--sp12);
  border-radius: var(--r8);
  color: var(--textSecondary);
  background: var(--semanticAccentDim);
  font: 400 12px/1.5 var(--fontInter);
}

.desktop-login-notice svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  color: var(--semanticAccent);
}

.desktop-login-actions {
  display: grid;
  grid-template-columns: 1fr 1.55fr;
  gap: var(--sp8);
  margin-top: var(--sp24);
}

.desktop-login-result {
  text-align: center;
}

.desktop-login-result .desktop-login-state-icon {
  margin: 0 auto var(--sp16);
}

.desktop-login-result .desktop-login-copy {
  max-width: 320px;
  margin: var(--sp12) auto 0;
}

.desktop-login-error {
  margin-top: var(--sp20);
  text-align: left;
}

@media (max-width: 520px) {
  .portal-auth-body .desktop-login-wrapper {
    align-content: start;
    padding: var(--sp16);
  }

  .portal-auth-body .desktop-login-card {
    padding: var(--sp24);
  }

  .desktop-login-detail-row {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .desktop-login-actions {
    grid-template-columns: 1fr;
  }

  .desktop-login-actions .btn-primary {
    grid-row: 1;
  }
}

/* Email confirmation landing */
.email-confirm-card { text-align: center; }

.email-confirm-icon {
  display: grid;
  width: 48px;
  height: 48px;
  margin: 0 auto 18px;
  place-items: center;
  border: 1px solid var(--borderStrong);
  border-radius: var(--r10);
  background: var(--surfaceSunken);
}

.email-confirm-icon svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.email-confirm-icon--ready {
  color: var(--semanticAccent);
  border-color: color-mix(in srgb, var(--semanticAccent) 30%, var(--borderStrong));
  background: color-mix(in srgb, var(--semanticAccent) 10%, var(--surfaceRaised));
}

.email-confirm-icon--error {
  color: var(--semanticError);
  border-color: color-mix(in srgb, var(--semanticError) 30%, var(--borderStrong));
  background: var(--semanticErrorDim);
}

.email-confirm-card .auth-description { margin: 14px 0 4px; }

.email-confirm-address {
  overflow-wrap: anywhere;
  color: var(--textPrimary);
  font: 600 14px/1.5 var(--fontInter);
}

.email-confirm-copy {
  margin: 16px 0 22px;
  color: var(--textSecondary);
  font: 400 13px/1.6 var(--fontInter);
}

.email-confirm-form { margin-top: 22px; }

@media (max-width: 760px) {
  .portal-auth-body .auth-wrapper {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ============================================================
   PORTAL — Storeframe v3 redesign (web-scoped)
   A centered content page under the shared top navbar — no app
   rail or inspector. Keeps the v3 visual language: mono eyebrows,
   featured "continue" card, accent-bar project cards, status
   pills, summary strip.
   Prefix: pd- (portal dashboard). Reuses .lp-nav, :root tokens,
   .lp-btn-*, .mono-chip, .lp-status-pill, .lp-screenshot-grid /
   .lb-thumb and the lightbox.
   ============================================================ */

/* ── Legal / policy documents ───────────────────────────────── */
.legal-doc {
  max-width: 760px;
  margin: 0 auto;
  color: var(--textSecondary);
}
.legal-doc h1 {
  margin: 0 0 6px;
  color: var(--textPrimary);
  font: 600 clamp(1.5rem, 2.5vw, 1.875rem)/1.15 var(--fontInter);
  letter-spacing: -.01em;
}
.legal-updated {
  margin-bottom: var(--sp32);
  color: var(--textMuted);
  font: 400 11px/1.3 var(--fontMono);
  letter-spacing: .04em;
}
.legal-doc h2 {
  margin: var(--sp32) 0 var(--sp8);
  color: var(--textPrimary);
  font: 600 1.125rem/1.3 var(--fontInter);
}
.legal-doc p,
.legal-doc li {
  font: 400 0.95rem/1.7 var(--fontInter);
  color: var(--textSecondary);
}
.legal-doc p { margin: 0 0 var(--sp12); }
.legal-doc ul { margin: 0 0 var(--sp12); padding-left: 1.25rem; }
.legal-doc li { margin-bottom: var(--sp4); }
.legal-doc a { color: var(--semanticAccent); }
.legal-doc strong { color: var(--textPrimary); font-weight: 600; }
.legal-note {
  margin-top: var(--sp32);
  padding: var(--sp16);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
  font: 400 0.85rem/1.6 var(--fontInter);
  color: var(--textMuted);
}

/* ── Footer legal links row ─────────────────────────────────── */
.lp-footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp16);
}
.lp-footer-legal a { font-size: 0.75rem; color: var(--textMuted); }
.lp-footer-legal a:hover { color: #ECEBE8; text-decoration: none; }

.pd-page {
  max-width: 1040px;
  margin: 0 auto;
}

/* ── Page header ────────────────────────────────────────────── */
.pd-page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--sp16);
  margin-bottom: var(--sp24);
}
.pd-title {
  margin: 0;
  color: var(--textPrimary);
  font: 600 clamp(1.5rem, 2.5vw, 1.875rem)/1.15 var(--fontInter);
  letter-spacing: -.01em;
}
.pd-page-actions {
  display: flex;
  align-items: center;
  gap: var(--sp8);
  flex-shrink: 0;
}

/* ── Summary strip (Plan · Storage · Projects) ──────────────── */
.pd-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp12);
  margin-bottom: var(--sp24);
}
.pd-stat {
  padding: var(--sp16);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
}
.pd-stat-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp8);
  color: var(--textMuted);
  font: 500 11px/1.2 var(--fontInter);
  letter-spacing: .02em;
}
.pd-stat-value {
  margin-top: 10px;
  color: var(--textPrimary);
  font: 600 22px/1.15 var(--fontInter);
}
.pd-stat-hint {
  margin-top: 4px;
  color: var(--textMuted);
  font: 400 12px/1.4 var(--fontInter);
}
.pd-stat .lp-storage-bar { margin: 10px 0 0; }

/* ── Limited / locked banner ────────────────────────────────── */
.pd-banner {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--sp16);
  padding: var(--sp12) var(--sp16);
  margin-bottom: var(--sp24);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
}
.pd-banner-tag {
  flex: none;
  padding: 3px 9px;
  color: var(--semanticAccent);
  border: 1px solid var(--semanticAccent);
  border-radius: var(--r6);
  font: 600 11px/1.3 var(--fontInter);
}
.pd-banner-body { flex: 1; min-width: 0; }
.pd-banner-title { font: 600 13px/1.3 var(--fontInter); }
.pd-banner-sub { margin-top: 1px; color: var(--textMuted); font: 400 12px/1.4 var(--fontInter); }
.pd-banner-actions { flex: none; margin: 0; }

/* Warning variant — used by the email-verification banner (base.html). */
.pd-banner--warn { border-color: var(--semanticWarn); background: var(--semanticWarnDim); }
.pd-banner--warn .pd-banner-tag { color: var(--semanticWarn); border-color: var(--semanticWarn); }

@media (max-width: 560px) {
  .pd-banner { flex-wrap: wrap; }
  .pd-banner-actions { width: 100%; }
  .pd-banner-actions .lp-btn-primary { width: 100%; }
}

/* ── Section divider ────────────────────────────────────────── */
.pd-divider {
  display: flex;
  align-items: center;
  gap: var(--sp12);
  margin-bottom: var(--sp12);
}
.pd-divider:not(:first-child) { margin-top: var(--sp32); }
.pd-divider-label {
  color: var(--textMuted);
  font: 500 12px/1.2 var(--fontInter);
  letter-spacing: .02em;
}
.pd-divider-line { flex: 1; height: 1px; background: var(--borderHairline); }
.pd-divider-actions { display: flex; align-items: center; gap: var(--sp8); }

/* ── Action rows (buttons under panels/cards) ───────────────── */
.pd-featured-actions { display: flex; flex-wrap: wrap; gap: var(--sp8); margin-top: var(--sp12); }

/* ── Project cards ──────────────────────────────────────────── */
.pd-projects {
  display: flex;
  flex-direction: column;
  gap: var(--sp12);
}
.pd-card {
  position: relative;
  padding: var(--sp16) var(--sp16) var(--sp16);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.pd-card:hover { border-color: var(--borderStrong); }
.pd-card--archived { opacity: .82; }
.pd-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp12);
}
.pd-card-heading {
  display: flex;
  align-items: center;
  gap: var(--sp8);
  min-width: 0;
}
.pd-card-name {
  margin: 0;
  color: var(--textPrimary);
  font: 600 16px/1.25 var(--fontInter);
  letter-spacing: -.01em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pd-card-count {
  flex: none;
  padding: 4px 10px;
  color: var(--textSecondary);
  background: var(--surfaceSunken);
  border-radius: var(--pill);
  font: 400 11px/1.3 var(--fontMono);
  letter-spacing: .02em;
}
.pd-badge-archived {
  padding: 2px 8px;
  color: var(--textMuted);
  background: var(--surfaceSunken);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r6);
  font: 500 11px/1.4 var(--fontInter);
}
.pd-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp8) var(--sp24);
  margin: 12px 0 0;
}
.pd-card-meta div { display: flex; flex-direction: column; gap: 2px; }
.pd-card-meta dt {
  color: var(--textMuted);
  font: 500 11px/1.2 var(--fontInter);
  letter-spacing: .01em;
}
.pd-card-meta dd {
  margin: 0;
  color: var(--textSecondary);
  font: 400 12.5px/1.3 var(--fontInter);
}
.pd-card-desc {
  margin-top: 12px;
  color: var(--textSecondary);
  font: 400 12.5px/1.45 var(--fontInter);
}
.pd-card-shots { margin-top: var(--sp16); }
.pd-card-shots.lp-screenshot-grid {
  grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
  gap: var(--sp8);
}
.pd-card-shots .lp-screenshot-thumb {
  aspect-ratio: 9 / 16;
  border-radius: var(--r8);
  border: 1px solid var(--borderHairline);
  background: var(--surfaceSunken);
}
.pd-card-shots .lp-screenshot-thumb .mono-chip {
  position: absolute;
  left: var(--sp4);
  right: var(--sp4);
  bottom: var(--sp4);
}
.pd-card-shots .portal-screenshot-thumb--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp8);
  text-align: center;
  color: var(--textMuted);
  font: 400 11px/1.35 var(--fontInter);
}
.pd-empty-shots {
  margin-top: var(--sp12);
  padding: var(--sp16);
  text-align: center;
  color: var(--textMuted);
  background: var(--surfaceCanvas);
  border: 1px dashed var(--borderStrong);
  border-radius: var(--r8);
  font: 400 12px/1.4 var(--fontInter);
}

/* ── Empty state ────────────────────────────────────────────── */
.pd-empty {
  display: flex;
  min-height: 320px;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--surfaceRaised);
  border: 1px dashed var(--borderStrong);
  border-radius: var(--r14);
}
.pd-empty-inner { max-width: 360px; }
.pd-empty-icon { color: var(--textMuted); }
.pd-empty-icon svg { width: 28px; height: 28px; }
.pd-empty-title { margin-top: 14px; color: var(--textSecondary); font: 600 15px/1.3 var(--fontInter); }
.pd-empty-desc { margin-top: 6px; color: var(--textMuted); font: 400 12.5px/1.45 var(--fontInter); }

/* ── Downloads ──────────────────────────────────────────────── */
.pd-downloads {
  margin-top: var(--sp32);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
  padding: var(--sp16);
}
.pd-dl-list {
  list-style: none;
  margin: var(--sp4) 0 0;
  padding: 0;
}
.pd-dl-row {
  display: flex;
  align-items: flex-start;
  gap: var(--sp16);
  padding: var(--sp16) 0;
  border-top: 1px solid var(--borderHairline);
}
.pd-dl-row:first-child { border-top: 0; padding-top: var(--sp8); }
.pd-dl-row:last-child { padding-bottom: var(--sp4); }
.pd-dl-os {
  width: 40px;
  height: 40px;
  flex: none;
  display: grid;
  place-items: center;
  color: var(--textSecondary);
  background: var(--surfaceSunken);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r10);
}
.pd-dl-os svg { width: 20px; height: 20px; fill: currentColor; }
.pd-dl-info { flex: 1; min-width: 0; }
.pd-dl-title {
  display: flex;
  align-items: baseline;
  gap: var(--sp8);
  min-width: 0;
}
.pd-dl-name { color: var(--textPrimary); font: 600 14px/1.3 var(--fontInter); }
.pd-dl-sub {
  margin-top: 2px;
  overflow: hidden;
  color: var(--textMuted);
  font: 400 12px/1.4 var(--fontInter);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pd-dl-btn { align-self: center; }
@media (max-width: 560px) {
  .pd-dl-row { flex-wrap: wrap; }
  .pd-dl-info { flex-basis: calc(100% - 40px - var(--sp16)); }
  .pd-dl-btn { width: 100%; }
}
.pd-divider-link {
  flex: none;
  color: var(--semanticAccent);
  font: 500 12px/1.3 var(--fontInter);
  text-decoration: none;
}
.pd-divider-link:hover { text-decoration: underline; }

/* ── Installation guide ────────────────────────────────────── */
.install-guide { max-width: 860px; }
.install-guide-hero {
  padding: 36px 0 28px;
  border-bottom: 1px solid var(--borderHairline);
}
.install-guide-hero h1 {
  margin: 8px 0 10px;
  color: var(--textPrimary);
  font-size: clamp(2rem, 5vw, 3.25rem);
  line-height: 1.05;
  letter-spacing: -.04em;
}
.install-guide-hero p {
  max-width: 620px;
  margin: 0 0 20px;
  color: var(--textSecondary);
  font-size: 16px;
  line-height: 1.6;
}
.install-guide-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 18px 0;
  border-bottom: 1px solid var(--borderHairline);
}
.install-guide-jump a {
  padding: 7px 12px;
  color: var(--textSecondary);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--pill);
  font: 500 12px/1.3 var(--fontMono);
  text-decoration: none;
}
.install-guide-jump a:hover { color: var(--semanticAccent); border-color: var(--semanticAccent); }
.install-guide-section {
  padding: 42px 0;
  border-bottom: 1px solid var(--borderHairline);
  scroll-margin-top: 72px;
}
.install-guide-section h2 {
  margin: 4px 0 0;
  color: var(--textPrimary);
  font-size: 24px;
  letter-spacing: -.02em;
}
.install-guide-heading { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.install-guide-os {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  flex: none;
  color: var(--semanticAccent);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderStrong);
  border-radius: var(--r10);
}
.install-guide-os svg { width: 24px; height: 24px; fill: currentColor; }
.install-guide-intro { max-width: 680px; color: var(--textSecondary); line-height: 1.6; }
.install-guide-steps { margin: 0; padding: 0; list-style: none; counter-reset: install-step; }
.install-guide-steps li {
  position: relative;
  min-height: 42px;
  padding: 0 0 24px 54px;
  counter-increment: install-step;
}
.install-guide-steps li::before {
  content: counter(install-step);
  position: absolute;
  top: 0;
  left: 0;
  color: var(--semanticAccent);
  font: 600 13px/32px var(--fontInter);
}
.install-guide-steps li::after {
  content: "";
  position: absolute;
  top: 32px;
  bottom: 4px;
  left: 9px;
  width: 1px;
  background: var(--borderHairline);
}
.install-guide-steps li:last-child::after { display: none; }
.install-guide-steps strong { color: var(--textPrimary); font-size: 15px; }
.install-guide-steps p { margin: 6px 0 0; color: var(--textSecondary); line-height: 1.55; }
.install-guide-steps code:not(.install-guide-command), .install-guide-note code {
  font-family: var(--fontMono);
  font-size: .9em;
}
.install-guide-command {
  display: block;
  margin: 10px 0;
  padding: 12px 14px;
  overflow-x: auto;
  color: var(--textPrimary);
  background: var(--surfaceSunken);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r8);
  font: 500 12px/1.5 var(--fontMono);
  white-space: nowrap;
}
.install-guide-note {
  margin-top: 4px;
  padding: 16px 18px;
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r10);
}
.install-guide-note strong { color: var(--textPrimary); font-size: 13px; }
.install-guide-note p { margin: 5px 0 0; color: var(--textSecondary); font-size: 13px; line-height: 1.55; }
.install-guide-steps--compact { margin-top: 22px; }
.install-guide-support { margin: 0; color: var(--textSecondary); }
.install-guide-support a { color: var(--semanticAccent); }
@media (max-width: 600px) {
  .install-guide-hero { padding-top: 24px; }
  .install-guide-section { padding: 32px 0; }
  .install-guide-steps li { padding-left: 42px; }
}
.pd-checksum {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: min(420px, 100%);
  margin-top: 8px;
  padding: 5px 9px;
  background: var(--surfaceSunken);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r8);
  cursor: pointer;
  text-align: left;
  transition: border-color .15s ease, color .15s ease;
}
.pd-checksum:hover { border-color: var(--semanticAccent); }
.pd-checksum-label {
  flex: none;
  color: var(--textMuted);
  font: 700 9px/1.2 var(--fontMono);
  letter-spacing: .1em;
}
.pd-checksum code {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--textMuted);
  font: 400 10.5px/1.3 var(--fontMono);
}
.pd-checksum.is-copied { border-color: var(--semanticAccent); }
.pd-checksum.is-copied .pd-checksum-label { color: var(--semanticAccent); }
.pd-verify { margin-top: 6px; }
.pd-verify summary {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--textMuted);
  font: 400 11px/1.3 var(--fontMono);
  letter-spacing: .02em;
  cursor: pointer;
  list-style: none;
}
.pd-verify summary::-webkit-details-marker { display: none; }
.pd-verify summary::before { content: "+"; color: var(--textDisabled); font-weight: 700; }
.pd-verify[open] summary::before { content: "\2212"; }
.pd-verify summary:hover { color: var(--textSecondary); }
.pd-verify-hint { margin: 8px 0 6px; color: var(--textMuted); font: 400 11.5px/1.4 var(--fontInter); }
.pd-verify-cmd {
  display: block;
  padding: 8px 10px;
  overflow-x: auto;
  color: var(--textSecondary);
  background: var(--surfaceSunken);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r8);
  font: 400 11px/1.4 var(--fontMono);
  white-space: nowrap;
}

/* ── Settings / account page ────────────────────────────────── */
.pd-settings { max-width: 600px; }
.pd-id-card {
  display: flex;
  align-items: center;
  gap: var(--sp16);
  padding: var(--sp16);
  margin-bottom: var(--sp16);
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
}
.pd-id-avatar {
  width: 48px;
  height: 48px;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--semanticAccentDim);
  color: var(--semanticAccent);
  border-radius: var(--r10);
  font: 700 15px/1 var(--fontMono);
}
.pd-id-main { flex: 1; min-width: 0; }
.pd-id-name { font: 600 15px/1.25 var(--fontInter); }
.pd-id-mail { color: var(--textMuted); font: 400 11.5px/1.3 var(--fontMono); margin-top: 1px; }
.pd-panel {
  background: var(--surfaceRaised);
  border: 1px solid var(--borderHairline);
  border-radius: var(--r14);
  overflow: hidden;
  margin-bottom: 16px;
}
.pd-panel-head {
  padding: var(--sp12) var(--sp16);
  border-bottom: 1px solid var(--borderHairline);
  color: var(--textSecondary);
  font: 600 12px/1.2 var(--fontInter);
  letter-spacing: .02em;
}
.pd-panel-body { padding: var(--sp16); }
.pd-panel-body > .pd-card-desc:first-child { margin-top: 0; }
.pd-about-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--surfaceSunken);
  font: 400 12.5px/1.4 var(--fontInter);
  color: var(--textSecondary);
}
.pd-about-row:last-child { border-bottom: none; }
.pd-about-row .mono-chip { background: transparent; padding: 0; }
.pd-inline-form { display: inline; margin: 0; }

@media (max-width: 820px) {
  .pd-summary { grid-template-columns: 1fr; }
  .pd-page-head { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 640px) {
  .pd-divider-actions { margin-left: auto; }
}
