/* ============================================================
   Habits interactive demo — demo-only styles.
   Everything visual inside the app viewport comes from app.css
   (the real compiled app stylesheet); this file only styles the
   browser-chrome frame, modal, toasts, and loading animation.
   ============================================================ */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

/* Tailwind v4 resets buttons to cursor: default — everything clickable
   in the demo should read as clickable. */
button:not(:disabled),
a,
[role='button'],
select,
label[for] {
  cursor: pointer;
}

button:disabled { cursor: not-allowed; }

body {
  background: var(--marketing-background, #0a1628);
  font-family: 'Inter', ui-sans-serif, system-ui, sans-serif;
  padding: clamp(6px, 1.5vh, 20px) clamp(6px, 1.5vw, 24px);
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  display: flex;
  align-items: stretch;
  justify-content: center;
}

/* ---------- Fake browser chrome frame ---------- */

.demo-frame {
  width: 100%;
  max-width: 1600px;
  height: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background: #000;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
}

.demo-chrome {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: clamp(7px, 1.2vh, 12px) 18px;
  background: #000;
  flex-shrink: 0;
}

.demo-chrome-nav {
  display: flex;
  align-items: center;
  gap: 14px;
  color: #9ca3af;
}

.demo-chrome-nav svg { display: block; }

.demo-chrome-url {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  max-width: 560px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  padding: 7px 16px;
  color: #e5e7eb;
  font-size: 13px;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.demo-chrome-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(109, 210, 51, 0.12);
  border: 1px solid rgba(109, 210, 51, 0.45);
  color: #6dd233;
  font-size: 12px;
  font-weight: 600;
  border-radius: 999px;
  padding: 6px 13px;
  cursor: pointer;
  transition: background 150ms ease;
}

.demo-chrome-badge:hover { background: rgba(109, 210, 51, 0.22); }

.demo-chrome-btn {
  display: none;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #e5e7eb;
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  border-radius: 999px;
  padding: 6px 13px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 150ms ease;
}

.demo-chrome-btn:hover { background: rgba(255, 255, 255, 0.15); }

/* Persistent exit back to the marketing site — same pill as
   .demo-chrome-btn but always visible (that one is scene-toggled). */
.demo-chrome-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #e5e7eb;
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  border-radius: 999px;
  padding: 6px 13px;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: background 150ms ease;
}

.demo-chrome-link:hover { background: rgba(255, 255, 255, 0.15); }

.demo-chrome-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #6dd233;
  animation: demo-pulse 2s ease-in-out infinite;
}

@keyframes demo-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

.demo-viewport {
  flex: 1;
  min-height: 0;
  background: var(--marketing-background, #0a1628);
}

/* The app shell markup uses h-screen in the real app; inside the
   frame it should fill the viewport div instead. */
.demo-viewport .app-shell { height: 100%; }

/* The app sidebar has no internal scroll in the real app (it assumes a
   tall h-screen). Inside the flexible frame it must scroll on short
   windows instead of clipping the Support/account buttons. Desktop
   only — at mobile widths the sidebar stacks above the content and
   min-height: 0 would let flexbox collapse it. */
@media (min-width: 768px) {
  #scene-app > div:first-child {
    overflow-y: auto !important;
    min-height: 0;
    scrollbar-width: none;
  }

  #scene-app > div:first-child::-webkit-scrollbar { display: none; }
}

/* ---------- Loading / generation animation ---------- */

.demo-gen {
  border: 1px solid rgba(109, 210, 51, 0.25);
  background: rgba(109, 210, 51, 0.04);
  border-radius: 12px;
  padding: 22px 24px;
  margin-top: 12px;
}

.demo-gen-row {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--primary-text, #f4f4f6);
  font-size: 13px;
  font-weight: 500;
  min-height: 20px;
}

.demo-gen-spinner {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 2px solid rgba(109, 210, 51, 0.25);
  border-top-color: #6dd233;
  animation: demo-spin 0.8s linear infinite;
  flex-shrink: 0;
}

@keyframes demo-spin { to { transform: rotate(360deg); } }

.demo-gen-bar {
  margin-top: 16px;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  overflow: hidden;
}

.demo-gen-bar-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #4ea922, #6dd233);
  transition: width 600ms ease;
}

.demo-gen-hint {
  margin-top: 12px;
  font-size: 11px;
  color: var(--text-secondary, #9ca3af);
  opacity: 0.75;
}

.demo-fade-in { animation: demo-fade-in 500ms ease both; }

@keyframes demo-fade-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Toast ---------- */

.demo-toast {
  position: fixed;
  left: 50%;
  bottom: 34px;
  transform: translate(-50%, 16px);
  background: var(--marketing-background-tertiary, #1a2332);
  border: 1px solid var(--marketing-border, rgba(255, 255, 255, 0.08));
  color: var(--marketing-text-primary, #f4f4f6);
  font-size: 13px;
  line-height: 1.45;
  border-radius: 12px;
  padding: 12px 18px;
  max-width: 420px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease, transform 220ms ease;
  z-index: 90;
}

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

/* ---------- Email gate modal ---------- */

.demo-modal-overlay {
  position: fixed;
  inset: 0;
  background: var(--modal-overlay, rgba(0, 0, 0, 0.65));
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
  padding: 20px;
}

.demo-modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.demo-modal {
  width: 100%;
  max-width: 460px;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  background: var(--theme-modal-bg, #121c2e);
  border: 1px solid var(--theme-modal-border, rgba(255, 255, 255, 0.08));
  border-radius: 20px;
  padding: 30px 32px 28px;
  color: var(--theme-modal-text, #f4f4f6);
  position: relative;
  transform: translateY(14px) scale(0.98);
  transition: transform 220ms ease;
}

.demo-modal-overlay.open .demo-modal { transform: translateY(0) scale(1); }

.demo-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  color: var(--marketing-text-secondary, #9ca3af);
  cursor: pointer;
  padding: 6px;
  line-height: 0;
  border-radius: 8px;
}

.demo-modal-close:hover { color: #fff; background: rgba(255, 255, 255, 0.06); }

.demo-modal h3 {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.demo-modal p {
  margin: 0 0 20px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--marketing-text-secondary, #9ca3af);
}

.demo-modal input[type="email"] {
  width: 100%;
  height: 48px;
  border-radius: 12px;
  border: 1px solid var(--modal-input-border, rgba(255, 255, 255, 0.08));
  background: var(--modal-input-bg, rgba(255, 255, 255, 0.04));
  color: var(--modal-input-text, #f4f4f6);
  font-size: 15px;
  font-family: inherit;
  padding: 0 16px;
  outline: none;
  margin-bottom: 12px;
}

.demo-modal input[type="email"]:focus { border-color: #6dd233; }

.demo-modal input[type="email"]::placeholder { color: var(--modal-input-placeholder, #6b7280); }

.demo-modal-submit {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 12px;
  background: var(--brand-primary, #6dd233);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: filter 150ms ease;
}

.demo-modal-submit:hover { filter: brightness(1.07); }

.demo-modal-skip {
  display: block;
  width: 100%;
  margin-top: 12px;
  background: none;
  border: none;
  color: var(--marketing-text-muted, #6b7280);
  font-size: 12.5px;
  font-family: inherit;
  cursor: pointer;
  padding: 6px;
}

.demo-modal-skip:hover { color: var(--marketing-text-secondary, #9ca3af); }

.demo-modal-error {
  color: #f87171;
  font-size: 12px;
  margin: -6px 0 10px;
  display: none;
}

.demo-modal-code {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px dashed rgba(109, 210, 51, 0.5);
  background: rgba(109, 210, 51, 0.08);
  border-radius: 12px;
  padding: 14px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #6dd233;
  margin-bottom: 14px;
  cursor: pointer;
}

/* ---------- LinkedIn / extension scene ---------- */

.demo-linkedin {
  display: flex;
  height: 100%;
  background: #f4f2ee;
  color: #1d1d1d;
  font-family: 'Inter', -apple-system, sans-serif;
  overflow: hidden;
  position: relative;
}

.demo-li-page {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  padding-bottom: 40px;
}

.demo-li-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #ffffff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  padding: 8px 24px;
  position: sticky;
  top: 0;
  z-index: 5;
}

.demo-li-logo {
  width: 34px;
  height: 34px;
  border-radius: 4px;
  background: #0a66c2;
  color: #fff;
  font-weight: 800;
  font-size: 20px;
  display: grid;
  place-items: center;
}

.demo-li-searchbox {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #edf3f8;
  border-radius: 4px;
  padding: 7px 12px;
  font-size: 13px;
  color: #56687a;
  width: 260px;
}

.demo-li-nav-icons {
  display: flex;
  gap: 26px;
  margin-left: auto;
  padding-right: 8px;
}

.demo-li-nav-icons span {
  width: 22px;
  height: 22px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.14);
}

.demo-li-card {
  max-width: 780px;
  margin: 16px auto 0;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.demo-li-banner {
  height: 130px;
  background: linear-gradient(135deg, #0a1628 0%, #002153 55%, #003070 100%);
  border-bottom: 3px solid #6dd233;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 16px 20px;
  color: #fff;
}

.demo-li-banner-brand {
  margin: 0 0 2px;
  font-size: 12px;
  font-weight: 700;
}

.demo-li-banner-line {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.3;
  max-width: 360px;
}

.demo-li-banner-line em {
  font-style: normal;
  color: #6dd233;
}

.demo-li-avatar {
  position: absolute;
  top: 68px;
  left: 24px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid #fff;
  background: linear-gradient(135deg, #003070, #002153);
  color: #fff;
  font-size: 38px;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.demo-li-body { padding: 66px 24px 20px; }

.demo-li-body h2 {
  margin: 0 0 2px;
  font-size: 22px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.demo-li-degree { font-size: 14px; font-weight: 400; color: #56687a; }
.demo-li-headline { margin: 0 0 6px; font-size: 15px; }
.demo-li-meta { margin: 0 0 2px; font-size: 13px; color: #56687a; }
.demo-li-meta button { background: none; border: none; color: #0a66c2; font-weight: 600; font-size: 13px; cursor: pointer; padding: 0; font-family: inherit; }
.demo-li-link { margin: 0 0 6px; font-size: 13.5px; color: #0a66c2; font-weight: 600; }
.demo-li-followers { margin: 0 0 14px; font-size: 13.5px; color: #56687a; font-weight: 600; }

.demo-li-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.demo-li-btn {
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  border-radius: 999px;
  padding: 7px 16px;
  cursor: pointer;
  border: 1px solid #0a66c2;
  background: #fff;
  color: #0a66c2;
}

.demo-li-btn--primary { background: #0a66c2; color: #fff; }

.demo-li-section { padding: 18px 24px; }
.demo-li-section h3 { margin: 0 0 10px; font-size: 18px; font-weight: 700; }
.demo-li-section:last-child { margin-bottom: 16px; }

.demo-li-clamp p { margin: 0 0 12px; font-size: 14px; line-height: 1.55; color: #1d1d1d; }
.demo-li-clamp p:last-child { margin-bottom: 0; }

/* collapsed state mimics LinkedIn's 3-line truncation */
.demo-li-clamp:not(.demo-li-clamp--open) {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.demo-li-more {
  background: none;
  border: none;
  padding: 2px 0 0;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: #56687a;
  cursor: pointer;
}

.demo-li-more:hover { color: #0a66c2; text-decoration: underline; }

/* posts (Featured + Activity) */
.demo-li-activity-followers { margin: -6px 0 10px; font-size: 13px; color: #56687a; }

.demo-li-pills { display: flex; gap: 8px; margin-bottom: 14px; }

.demo-li-pill {
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  border-radius: 999px;
  padding: 5px 14px;
  border: 1px solid #56687a;
  background: #fff;
  color: #56687a;
  cursor: pointer;
}

.demo-li-pill--active { background: #01754f; border-color: #01754f; color: #fff; }

.demo-li-post {
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  padding: 14px 16px 12px;
  margin-bottom: 12px;
}

.demo-li-post:last-of-type { margin-bottom: 0; }

.demo-li-post-head { display: flex; gap: 10px; margin-bottom: 10px; }
.demo-li-post-head img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.demo-li-post-name { margin: 0; font-size: 14px; font-weight: 600; color: #1d1d1d; }
.demo-li-post-name span { font-weight: 400; color: #56687a; }
.demo-li-post-sub { margin: 0; font-size: 12px; color: #56687a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 420px; }
.demo-li-post-time { margin: 1px 0 0; font-size: 12px; color: #56687a; display: flex; align-items: center; gap: 3px; }

.demo-li-post-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  font-size: 12.5px;
  color: #56687a;
}

.demo-li-reactions { display: inline-flex; align-items: center; gap: 4px; }

.demo-li-reaction {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid #fff;
  display: inline-block;
}

.demo-li-reaction--like { background: #378fe9; }
.demo-li-reaction--celebrate { background: #6dae4f; margin-left: -7px; }
.demo-li-reaction--support { background: #df704d; margin-left: -7px; }

.demo-li-linkcard {
  display: block;
  width: 100%;
  text-align: left;
  margin-top: 10px;
  padding: 10px 14px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  background: #f8f8f5;
  font-family: inherit;
  cursor: pointer;
}

.demo-li-linkcard:hover { background: #eef3f8; }
.demo-li-linkcard-title { display: block; font-size: 13.5px; font-weight: 600; color: #1d1d1d; }
.demo-li-linkcard-domain { display: block; margin-top: 2px; font-size: 12px; color: #56687a; }

.demo-li-showall {
  display: block;
  width: 100%;
  margin-top: 12px;
  padding: 8px;
  background: none;
  border: none;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: #56687a;
  cursor: pointer;
}

.demo-li-showall:hover { color: #0a66c2; }

/* experience / education rows */
.demo-li-exp { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid rgba(0, 0, 0, 0.06); }
.demo-li-exp:last-child { border-bottom: none; padding-bottom: 0; }

.demo-li-exp-logo {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.demo-li-exp-logo--habits { background: #0a1628; }
.demo-li-exp-logo--habits img { width: 26px; height: 26px; }

.demo-li-exp-title { margin: 0; font-size: 14px; font-weight: 600; color: #1d1d1d; }
.demo-li-exp-org { margin: 0; font-size: 13px; color: #1d1d1d; }
.demo-li-exp-dates { margin: 1px 0 0; font-size: 12.5px; color: #56687a; }
.demo-li-exp-desc { margin: 6px 0 0; font-size: 13px; line-height: 1.5; color: #1d1d1d; }

.demo-li-exp-sub { margin-top: 10px; padding-left: 14px; border-left: 2px solid rgba(0, 0, 0, 0.08); }

.demo-ext-panel {
  width: 400px;
  flex-shrink: 0;
  border-left: 1px solid rgba(0, 0, 0, 0.12);
  background: #f4f4f6;
  display: flex;
  flex-direction: column;
}

.demo-ext-titlebar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  font-size: 13.5px;
  font-weight: 600;
  color: #1d1d1d;
  font-family: 'Inter', sans-serif;
}

.demo-ext-panel iframe { flex: 1; width: 100%; border: none; }

@media (max-width: 1100px) {
  .demo-ext-panel { width: 340px; }
}

/* Narrow screens: stack the LinkedIn page and the extension panel,
   letting the scene scroll as one page. */
@media (max-width: 900px) {
  .demo-linkedin {
    flex-direction: column;
    overflow-y: auto;
  }
  .demo-li-page {
    flex: none;
    overflow: visible;
    padding-bottom: 16px;
  }
  .demo-ext-panel {
    width: 100%;
    flex: none;
    height: 70vh;
    min-height: 480px;
    border-left: none;
    border-top: 1px solid rgba(0, 0, 0, 0.15);
  }
}

/* ---------- Guided tour ---------- */

.demo-tour-card {
  position: fixed;
  right: 28px;
  bottom: 28px;
  z-index: 85;
  width: 340px;
  max-width: calc(100vw - 40px);
  background: var(--marketing-background-tertiary, #1a2332);
  border: 1px solid rgba(109, 210, 51, 0.35);
  border-radius: 16px;
  padding: 18px 20px 16px;
  color: var(--marketing-text-primary, #f4f4f6);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
  display: none;
}

.demo-tour-card.show { display: block; animation: demo-fade-in 300ms ease; }

/* Flip to the bottom-left when the highlighted control sits on the
   right half of the screen, so the card never covers its own target. */
.demo-tour-card--left {
  right: auto;
  left: 28px;
}

.demo-tour-step {
  margin: 0 0 6px;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6dd233;
  font-weight: 700;
}

.demo-tour-text {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--marketing-text-secondary, #9ca3af);
}

.demo-tour-text b { color: var(--marketing-text-primary, #f4f4f6); font-weight: 600; }

.demo-tour-hint {
  margin: 12px 0 0;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: #6dd233;
}

.demo-tour-hint.hidden,
.demo-tour-next.hidden { display: none; }

.demo-tour-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
}

.demo-tour-next {
  background: var(--brand-primary, #6dd233);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 16px;
  font-weight: 600;
  font-size: 12.5px;
  font-family: inherit;
  cursor: pointer;
  transition: filter 150ms ease;
}

.demo-tour-next:hover { filter: brightness(1.07); }

.demo-tour-skip {
  background: none;
  border: none;
  color: var(--marketing-text-muted, #6b7280);
  font-size: 12px;
  font-family: inherit;
  cursor: pointer;
  padding: 4px 0;
}

.demo-tour-skip:hover { color: var(--marketing-text-secondary, #9ca3af); }

/* Floating highlight ring — tracks the current tour target on screen
   (works across the extension iframe boundary, unlike a CSS class on
   the element) and pulses expanding ripples for motion. */
#demo-tour-ring {
  position: fixed;
  z-index: 84;
  pointer-events: none;
  border: 3px solid #6dd233;
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(109, 210, 51, 0.35);
  display: none;
}

#demo-tour-ring.show { display: block; }

#demo-tour-ring::before,
#demo-tour-ring::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: inherit;
  animation: demo-ring-ripple 1.6s ease-out infinite;
}

#demo-tour-ring::after { animation-delay: 0.8s; }

@keyframes demo-ring-ripple {
  0%   { box-shadow: 0 0 0 0 rgba(109, 210, 51, 0.65); }
  100% { box-shadow: 0 0 0 18px rgba(109, 210, 51, 0); }
}

/* ---------- Small fixes inside the app viewport ---------- */

/* Sources rendered without live URLs (placeholder data) */
.demo-source-pending { color: var(--text-secondary, #9ca3af); }

/* Keyboard focus ring consistency inside demo */
.demo-viewport button:focus-visible { outline: 2px solid rgba(109, 210, 51, 0.6); outline-offset: 2px; }

@media (max-width: 900px) {
  body { padding: 0; }
  .demo-frame { border-radius: 0; border: none; }
  .demo-chrome-url { display: none; }
}

/* Tight phone widths: keep the back-to-website pill as an icon so it
   doesn't crowd the "try it free" badge. */
@media (max-width: 560px) {
  .demo-chrome-link .demo-chrome-link-label { display: none; }
  .demo-chrome-link { padding: 6px 9px; }
}

/* Compact sidebar: the real app's sidebar assumes a tall desktop
   screen; denser sizing keeps the full nav, extension card, and
   account button in view and reads more professional. */
@media (min-width: 768px) {
  #scene-app > div:first-child .bg-sidebar-panel { padding: 14px; }

  #scene-app > div:first-child nav > a > div {
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
  }

  #scene-app > div:first-child nav .h-12 {
    height: 2.25rem;
    width: 2.25rem;
  }

  #scene-app > div:first-child .w-10 { width: 1.9rem; }

  #scene-app > div:first-child span.text-\[28px\] {
    font-size: 21px;
    line-height: 30px;
  }

  #scene-app > div:first-child .h-\[74px\] { height: 52px; }

  #scene-app .sidebar-nav-label { font-size: 13.5px; }

  #scene-app > div:first-child .text-\[15px\] { font-size: 13.5px; }

  #scene-app > div:first-child .text-\[12\.5px\] { font-size: 11.5px; }
}

/* Denser type inside the app scene — the real app's 18px inputs and
   60px field heights eat vertical space the demo frame doesn't have. */
#scene-app .text-\[18px\],
#scene-app .md\:text-\[18px\],
#scene-app .sm\:text-\[16px\] { font-size: 14px !important; }

#scene-app input.h-\[60px\],
#scene-app .md\:h-\[60px\] { height: 42px !important; }

#scene-app textarea.h-\[120px\] { height: 84px !important; }

#scene-app .md\:text-\[32px\] { font-size: 24px !important; }
#scene-app .md\:leading-\[44px\] { line-height: 32px !important; }

#scene-app .h-\[50px\] { height: 40px !important; }
#scene-app .w-\[50px\] { width: 40px !important; }

/* Narrow screens: the app shell stacks sidebar above content (its
   native sub-md layout), so let the whole shell scroll as one page. */
@media (max-width: 767px) {
  #scene-app { overflow-y: auto !important; }
  #dashboard-content { overflow: visible !important; }
}
