/* ============================================
   Article Page (shared by plugins/scripts/contact)
   ============================================ */

/* Page Header */
.page-header {
  padding: var(--space-3xl) 0 var(--space-xl);
  background: var(--gradient-subtle);
  border-bottom: 1px solid var(--color-border-light);
}

.page-header__breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: var(--font-size-sm);
  color: var(--color-text-tertiary);
  margin-bottom: var(--space-md);
}

.page-header__breadcrumb a {
  color: var(--color-text-secondary);
  transition: color var(--transition-fast);
}

.page-header__breadcrumb a:hover {
  color: var(--color-text-primary);
}

.page-header__breadcrumb .separator {
  color: var(--color-text-tertiary);
}

.page-header__title {
  font-size: var(--font-size-3xl);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.page-header__subtitle {
  color: var(--color-text-secondary);
  margin-top: var(--space-sm);
  font-size: var(--font-size-lg);
}

/* Article Layout */
.article {
  padding: var(--space-3xl) 0;
}

.article__inner {
  margin: 0 auto;
}

.article__section {
  margin-bottom: var(--space-3xl);
}

.article__section:last-child {
  margin-bottom: 0;
}

.article__section-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  margin-bottom: var(--space-lg);
  padding-bottom: var(--space-sm);
  border-bottom: 1px solid var(--color-border-light);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.article__section-title svg {
  color: var(--color-text-secondary);
  flex-shrink: 0;
}

.article p {
  line-height: var(--line-height-relaxed);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-md);
}

.article p:last-child {
  margin-bottom: 0;
}

/* ============================================
   Plugin Article Specific
   ============================================ */

.plugin-hero {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: var(--space-2xl);
  align-items: start;
  margin-bottom: var(--space-3xl);
}

.plugin-hero__info {
  position: sticky;
  top: calc(var(--nav-height) + var(--space-lg));
}

.plugin-hero__icon {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-lg);
  background: var(--gradient-hero);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
  box-shadow: var(--shadow-md);
}

.plugin-hero__icon svg {
  width: 36px;
  height: 36px;
  fill: #fff;
}

.plugin-hero__name {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  margin-bottom: var(--space-xs);
}

.plugin-hero__version {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.plugin-hero__desc {
  color: var(--color-text-secondary);
  line-height: var(--line-height-relaxed);
  margin-bottom: var(--space-xl);
}

.plugin-hero__download {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

/* Video Showcase (.plugin-showcase now wraps a Bilibili iframe) */
.plugin-showcase__video {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.plugin-showcase__video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: var(--radius-lg);
}
.plugin-showcase {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--color-border-light);
  background: var(--color-bg-secondary);
}

.plugin-showcase__slides {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.plugin-showcase__slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg-secondary);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.plugin-showcase__slide--active {
  opacity: 1;
}

.plugin-showcase__slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: var(--space-lg);
}

.plugin-showcase__slide-placeholder {
  color: var(--color-text-tertiary);
  font-size: var(--font-size-sm);
  text-align: center;
}

.plugin-showcase__nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md);
  border-top: 1px solid var(--color-border-light);
}

.plugin-showcase__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-border);
  border: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  padding: 0;
}

.plugin-showcase__dot--active {
  background: var(--color-accent);
  width: 24px;
  border-radius: 4px;
}

.plugin-showcase__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-surface);
  border: 1px solid var(--color-border-light);
  border-radius: 50%;
  cursor: pointer;
  z-index: 1;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.plugin-showcase__arrow:hover {
  background: var(--color-bg-tertiary);
  box-shadow: var(--shadow-md);
}

.plugin-showcase__arrow--prev {
  left: var(--space-md);
}

.plugin-showcase__arrow--next {
  right: var(--space-md);
}

/* ============================================
   Script Article Specific
   ============================================ */

.script-code-wrapper {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid #3c3c3c;
  margin-bottom: var(--space-lg);
  background: #1e1e1e;
  display: flex;
  flex-direction: column;
}

.script-code-wrapper__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-sm) var(--space-md);
  background: #252526;
  border-bottom: 1px solid #3c3c3c;
}

.script-code-wrapper__lang {
  font-size: var(--font-size-xs);
  color: #858585;
  font-weight: 500;
  text-transform: uppercase;
}

.script-code-wrapper__actions {
  display: flex;
  gap: var(--space-sm);
}

.script-copy-btn,
.script-install-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-md);
  font-size: var(--font-size-xs);
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  cursor: pointer;
  border: none;
  text-decoration: none;
}

.script-copy-btn {
  background: #3c3c3c;
  color: #cccccc;
}

.script-copy-btn:hover {
  background: #505050;
}

.script-install-btn {
  background: #0e639c;
  color: #ffffff;
}

.script-install-btn:hover {
  background: #1177bb;
}

.script-code-wrapper pre {
  margin: 0 !important;
  padding: var(--space-lg) !important;
  background: #1e1e1e !important;
  color: #ffffff !important;
  overflow: auto;
  flex: 1;
  min-height: 0;
}

/* VS Code 滚动条 */
.script-code-wrapper pre::-webkit-scrollbar {
  height: 10px;
  width: 14px;
}

.script-code-wrapper pre::-webkit-scrollbar-track {
  background: #1e1e1e;
}

.script-code-wrapper pre::-webkit-scrollbar-thumb {
  background: #424242;
  border-radius: 5px;
  border: 3px solid #1e1e1e;
}

.script-code-wrapper pre::-webkit-scrollbar-thumb:hover {
  background: #555555;
}

.script-code-wrapper pre::-webkit-scrollbar-corner {
  background: #1e1e1e;
}

.script-code-wrapper .code-block {
  border-radius: 0;
  border: none;
  background: #1e1e1e;
  color: #d4d4d4 !important;
  font-family: 'Consolas', 'Courier New', monospace;
  white-space: pre;
  word-break: normal;
}

.script-code-wrapper pre.code-highlighted {
  margin: 0 !important;
  padding: var(--space-lg) !important;
  background: #1e1e1e !important;
  overflow: auto;
  flex: 1;
  min-height: 0;
}

.script-code-wrapper pre.code-highlighted code {
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: var(--font-size-sm);
  line-height: 1.7;
  tab-size: 2;
}

/* ============================================
   VS Code Dark+ Syntax Highlighting
   ============================================ */
.hljs-keyword { color: #569cd6; }
.hljs-control { color: #569cd6; font-style: italic; }
.hljs-string { color: #ce9178; }
.hljs-number { color: #b5cea8; }
.hljs-comment { color: #6a9955; font-style: italic; }
.hljs-function { color: #dcdcaa; }
.hljs-operator { color: #d4d4d4; }
.hljs-punctuation { color: #d4d4d4; }
.hljs-variable { color: #9cdcfe; }
.hljs-property { color: #9cdcfe; }
.hljs-type { color: #4ec9b0; }
.hljs-tag { color: #569cd6; }
.hljs-meta { color: #569cd6; }
.hljs-attr { color: #9cdcfe; }
.hljs-value { color: #ce9178; }

/* ============================================
   Future Plans / Roadmap
   ============================================ */

.roadmap {
  position: relative;
  padding-left: var(--space-xl);
}

.roadmap::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--color-border-light);
  border-radius: 1px;
}

.roadmap__item {
  position: relative;
  padding-bottom: var(--space-lg);
}

.roadmap__item:last-child {
  padding-bottom: 0;
}

.roadmap__item::before {
  content: '';
  position: absolute;
  left: calc(-1 * var(--space-xl) + 1px);
  top: 8px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--color-bg);
  border: 2px solid var(--color-border);
}

.roadmap__item--done::before {
  background: var(--color-success);
  border-color: var(--color-success);
}

.roadmap__item--wip::before {
  background: var(--color-warning);
  border-color: var(--color-warning);
}

.roadmap__item--planned::before {
  background: var(--color-bg-tertiary);
  border-color: var(--color-border);
}

.roadmap__item-title {
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--color-text-primary);
  margin-bottom: var(--space-xs);
}

.roadmap__item-desc {
  font-size: var(--font-size-sm);
  color: var(--color-text-tertiary);
}

.roadmap__item-status {
  display: inline-block;
  font-size: var(--font-size-xs);
  margin-left: var(--space-sm);
  vertical-align: middle;
}

/* Responsive */
@media (max-width: 768px) {
  .plugin-hero {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
  }

  .plugin-hero__info {
    position: static;
  }

  .plugin-hero__icon {
    width: 56px;
    height: 56px;
  }

  .plugin-hero__icon svg {
    width: 28px;
    height: 28px;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .plugin-hero {
    grid-template-columns: 1fr 1.2fr;
  }
}
