/* Labs owns the page shell. The imported showcase owns only #showcase-root. */
.learn-shell { position: relative; }
.learn-shell { padding-top: var(--nav-height); }
#showcase-root { position: relative; font-family: 'Inter', 'Noto Sans TC', sans-serif; background: transparent; }
.learn-index #showcase-root > .container { max-width: var(--max-width); padding-inline: 24px; }
#showcase-root[data-scenario] { max-width: 1440px; margin-inline: auto; }
#showcase-root ion-icon { display: inline-block; width: 1em; height: 1em; flex-shrink: 0; vertical-align: -.125em; }
#showcase-root ion-icon svg { width: 100%; height: 100%; fill: currentColor; }
#showcase-root .learn-scene-tools { display: flex; align-items: center; gap: 6px; margin: 0 0 12px; flex-shrink: 0; }
#showcase-root .learn-scene-home, #showcase-root .learn-scene-action { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 8px; border: 1px solid transparent; border-radius: 8px; color: #c4b5fd; background: transparent; font-size: .8125rem; font-weight: 600; line-height: 1.25; white-space: nowrap; cursor: pointer; }
#showcase-root .learn-scene-home { justify-content: flex-start; padding-inline: 0; margin-right: auto; }
#showcase-root .learn-scene-pagination { display: inline-flex; flex-shrink: 0; border: 1px solid rgba(148, 163, 184, .18); border-radius: 8px; background: rgba(148, 163, 184, .04); }
#showcase-root .learn-scene-pagination .learn-scene-action { width: 44px; min-height: 44px; padding: 0; border: 0; border-radius: 7px 0 0 7px; color: #dedaf3; }
#showcase-root .learn-scene-pagination .learn-scene-action + .learn-scene-action { border-left: 1px solid rgba(148, 163, 184, .18); border-radius: 0 7px 7px 0; }
#showcase-root .learn-scene-restart { color: #b8b8cb; border-color: rgba(148, 163, 184, .18); }
#showcase-root .learn-scene-home ion-icon, #showcase-root .learn-scene-action ion-icon { font-size: 18px; }
#showcase-root .learn-scene-action:hover:not([aria-disabled="true"]), #showcase-root .learn-scene-home:hover { color: #fff; background: rgba(139, 92, 246, .12); border-color: rgba(167, 139, 250, .45); }
#showcase-root .learn-scene-home:hover { border-color: transparent; }
#showcase-root .learn-scene-pagination [aria-disabled="true"] { opacity: .4; }
#showcase-root .learn-visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
#showcase-root .learn-scenario-heading { flex-shrink: 0; }
#showcase-root .learn-scenario-id { flex: 0 0 auto; color: #c4b5fd; font-size: 1.125rem; font-weight: 700; letter-spacing: .015em; }
#showcase-root .learn-scenario-title { display: flex; align-items: baseline; gap: 10px; margin: 0; color: #fff; font-size: 1.25rem; font-weight: 700; line-height: 1.35; letter-spacing: -.025em; }
#showcase-root .learn-scenario-name { min-width: 0; overflow-wrap: break-word; }
#showcase-root .learn-scenario-heading .learn-scenario-subtitle { margin-top: 4px; color: #a8a8c2; font-size: .8125rem; line-height: 1.4; }
#showcase-root .learn-scenario-reading { margin-top: 14px; padding-top: 16px; border-top: 1px solid rgba(55, 65, 81, .5); font-size: 16px; line-height: 1.7; }
#showcase-root .learn-scenario-reading > div + div { margin-top: 20px; }
#showcase-root .learn-scenario-reading h2 { margin-bottom: 10px; font-size: 18px; font-weight: 600; line-height: 28px; color: #d8b4fe; }
#showcase-root .learn-scenario-reading > div > p { margin-bottom: 0; font-size: 14px; line-height: 1.75; color: #d1d5db; }
#showcase-root .learn-technical-card { padding: 16px; background: #1f2937; border: 1px solid #374151; border-radius: 8px; }
#showcase-root .learn-technical-card h3 { margin-bottom: 10px; font-size: 16px; font-weight: 600; line-height: 1.15; color: #d1d5db; }
#showcase-root .learn-technical-copy { font-size: .8125rem; line-height: 1.7; color: #b5bfce; }
#showcase-root .learn-technical-copy p { margin-bottom: 0; font-size: 13px; line-height: 1.7; color: #b5bfce; }
#showcase-root .learn-technical-copy > p + p { margin-top: 16px; }
#showcase-root .learn-technical-copy strong { color: #c084fc; font-weight: 700; }
#showcase-root .learn-scenario-sidebar { padding: 16px; background: rgba(15, 23, 42, .6); min-width: 0; border-color: rgba(55, 65, 81, .5); }
#showcase-root .learn-scenario-workspace { background: transparent; color: #e5e7eb; }
#showcase-root .learn-scenario-sidebar > .flex-grow { display: flex; flex-direction: column; min-height: 0; }
#showcase-root .learn-scenario-reading { min-height: 0; padding-right: 12px; overflow-y: auto; }
#showcase-root .learn-simulation-panel { min-width: 0; }
#showcase-root[data-scenario^="llm02"] .learn-simulation-panel,
#showcase-root[data-scenario="llm03-sc"] .learn-simulation-panel,
#showcase-root[data-scenario="llm04-poisoning"] .learn-simulation-panel,
#showcase-root[data-scenario^="llm05"] .learn-simulation-panel,
#showcase-root[data-scenario="llm06-excessive-agency"] .learn-simulation-panel { color: #334155; }
#showcase-root .progress-container > #progress-text { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; pointer-events: none; }
#showcase-root pre { white-space: pre-wrap; overflow-wrap: anywhere; }
#showcase-root input, #showcase-root textarea { min-width: 0; max-width: 100%; }
#showcase-root button { overflow-wrap: break-word; }
#showcase-root p, #showcase-root h1, #showcase-root h2, #showcase-root h3, #showcase-root h4 { overflow-wrap: break-word; }
#showcase-root a:focus-visible, #showcase-root button:focus-visible, #showcase-root [role="button"]:focus-visible { outline: 2px solid #c4b5fd; outline-offset: 4px; }
#showcase-root .main-content-panel { background-image: none; background-color: transparent; min-width: 0; }
#showcase-root .sidebar-panel { min-height: 0; }
#showcase-root .showcase-card[aria-disabled="true"] { cursor: default; }
#showcase-root .showcase-card[aria-disabled="true"]:hover { transform: none; box-shadow: none; }
#showcase-root a[aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
#showcase-root .showcase-card:not(.placeholder):hover { border-color: var(--card-hover-color); }
#showcase-root .showcase-card.placeholder .status-badge { background-color: #374151 !important; color: #d1d5db !important; }
#showcase-root .showcase-card .learn-card-heading { margin: 8px 0 16px; }
#showcase-root .learn-catalog-link { display: block; height: 100%; color: inherit; text-decoration: none; border-radius: 16px; }
#showcase-root .learn-catalog-link > .showcase-card { height: 100%; }
#showcase-root .showcase-card p { height: auto; min-height: 0; }
#showcase-root .showcase-card h4 { margin-bottom: 0; }
#showcase-root .learn-catalog-intro { line-height: 1.65; }
#showcase-root .learn-series-picker { display: inline-block; position: relative; max-width: 100%; margin-inline: .1em; vertical-align: baseline; color: #fff; }
#showcase-root .learn-series-measure { display: block; visibility: hidden; white-space: nowrap; padding: .05em 1.15em .05em .3em; border: 1px solid transparent; }
#showcase-root .learn-series-picker::after { content: ''; position: absolute; right: .45em; top: calc(50% - .2em); width: .3em; height: .3em; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); pointer-events: none; }
#showcase-root .learn-series-select { position: absolute; inset: 0; appearance: none; width: 100%; height: 100%; min-width: 0; padding: .05em 1.15em .05em .3em; border: 1px solid rgba(148, 163, 184, .3); border-radius: 6px; background: rgba(5, 10, 21, .6); color: inherit; font: inherit; letter-spacing: inherit; cursor: pointer; }
#showcase-root .learn-series-select option { color: var(--text-primary); background: var(--bg-secondary); }
#showcase-root .learn-series-select option:disabled { color: var(--text-muted); }
#showcase-root .learn-series-picker:hover .learn-series-select { border-color: rgba(148, 163, 184, .55); }
#showcase-root .learn-series-select:focus-visible { outline: 2px solid var(--accent-blue-light); outline-offset: 3px; }
#showcase-root > [id^="llm"][id$="-modal"] { top: var(--nav-height); }
#showcase-root[data-scenario] > [role="dialog"] { top: var(--nav-height); }
#showcase-root .modal-panel { max-height: calc(100dvh - var(--nav-height) - 32px); overflow-y: auto; }
#showcase-root .modal-content { max-height: calc(100dvh - var(--nav-height) - 32px); overflow-y: auto; }
#showcase-root .modal-close { min-width: 44px; min-height: 44px; }
#showcase-root[data-scenario="llm10-model-replication"] .modal-overlay { position: fixed; top: var(--nav-height); }
#showcase-root[data-scenario="llm10-model-replication"] .modal-content > h2 { padding-right: 44px; text-align: left; font-size: clamp(1.125rem, 2vw, 1.5rem); line-height: 1.4; }
#showcase-root[data-scenario="llm10-model-replication"] .modal-close { top: 12px; right: 12px; display: inline-flex; align-items: center; justify-content: center; }
#showcase-root #toast { top: calc(var(--nav-height) + 12px); left: 50%; right: auto; translate: -50% 0; --tw-translate-x: 0; max-width: calc(100vw - 32px); width: max-content; pointer-events: none; }
@media (min-width: 1024px) {
  body.learn-case { overflow: hidden; }
  .learn-case .learn-shell { padding: calc(var(--nav-height) + 24px) 24px 24px; }
  #showcase-root[data-scenario] { height: calc(100dvh - var(--nav-height) - 48px); min-height: 0; border: 1px solid rgba(148, 163, 184, .18); border-radius: 20px; overflow: hidden; box-shadow: 0 16px 48px rgba(0, 0, 0, .22); }
  #showcase-root[data-scenario] > .main-container { height: 100%; }
  #showcase-root[data-scenario] > .main-container { display: flex; }
  #showcase-root .learn-scenario-workspace { display: flex; flex-direction: row; height: 100%; min-height: 0; }
  #showcase-root .learn-scenario-sidebar { width: 380px; min-width: 340px; max-width: 420px; flex: 0 0 30%; height: 100%; padding: 24px; overflow: hidden; }
  #showcase-root[data-scenario="llm08-rag"] .learn-scenario-sidebar > .flex-shrink-0 { flex: 0 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
  #showcase-root[data-scenario="llm08-rag"] .learn-scenario-sidebar > .flex-1.min-h-0 { flex: 1 1 0%; min-height: 180px; }
  #showcase-root .learn-simulation-panel { flex: 1 1 0%; width: auto; height: 100%; overflow: auto; }
  #showcase-root .device-frame { height: 100%; max-height: 100%; }
  #showcase-root .browser-window { height: 100%; max-height: 100%; }
  #showcase-root .phone-frame { height: 100%; min-height: 0; max-height: 820px; }
  #showcase-root .learn-scenario-sidebar #attack-result { max-height: 45%; overflow-y: auto; }
  #showcase-root .main-content-panel { overflow: hidden; }
}
@media (max-width: 1023px) {
  #showcase-root[data-scenario], #showcase-root[data-scenario] > .main-container { height: auto; }
  #showcase-root .learn-scenario-workspace { display: flex; flex-direction: column; height: auto; }
  #showcase-root .sidebar-panel > div.flex-grow { min-height: auto; }
  #showcase-root .learn-scenario-sidebar > .flex-grow { min-height: auto; }
  #showcase-root .learn-scenario-sidebar > .sidebar-content { max-height: none; overflow: visible; }
  #showcase-root .learn-scenario-sidebar { width: 100%; max-width: none; height: auto; border-bottom: 1px solid rgba(71, 85, 105, .5); }
  #showcase-root .learn-scenario-reading { overflow: visible; }
  #showcase-root .learn-simulation-panel { width: 100%; min-height: 640px; }
  #showcase-root .main-content-panel { padding: 16px; }
  #showcase-root .homeos-header { flex-direction: row; align-items: center; flex-wrap: wrap; }
  #showcase-root .device-frame { min-height: 660px; height: 85vh; }
  #showcase-root .browser-window { min-height: 640px; height: 85vh; }
  #showcase-root .chat-modal-content { width: 100%; max-width: 32rem; height: min(36rem, calc(100dvh - var(--nav-height) - 64px)); }
}
@media (max-width: 600px) {
  .learn-index #showcase-root > .container { padding-inline: 16px; }
  #showcase-root .device-frame { padding: 12px; }
  #showcase-root #attack-form { gap: 10px; }
  #showcase-root #prompt-input { min-width: 0; }
  #showcase-root .phishing-modal-content { margin: 8px; padding: 20px; }
  #showcase-root #summarizer-view input { min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  #showcase-root *, #showcase-root *::before, #showcase-root *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
