/* Shared styles for fix detail pages */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --purple-dark: #1a0a2e;
  --purple-accent: #6b3fa0;
  --purple-glow: #9d4edd;
  --purple-light: #c77dff;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--purple-dark);
  color: #fff;
  min-height: 100vh;
  overflow-x: hidden;
}

.bg-pattern {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(107, 63, 160, 0.4), transparent),
    radial-gradient(ellipse 60% 40% at 100% 100%, rgba(157, 78, 221, 0.25), transparent),
    linear-gradient(180deg, var(--purple-dark) 0%, #0d0618 100%);
}

.grid-overlay {
  position: fixed;
  inset: 0;
  z-index: 0;
  background-image:
    linear-gradient(rgba(157, 78, 221, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(157, 78, 221, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
}

.top-banner {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 101;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 50px 12px 24px;
  background: rgba(30, 20, 50, 0.98);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.top-banner.hidden { display: none; }

.top-banner-text { flex: 1; text-align: center; font-size: 0.95rem; color: rgba(255, 255, 255, 0.95); }
.top-banner-actions { display: flex; align-items: center; gap: 16px; }

.banner-discord-btn {
  display: inline-flex;
  padding: 8px 18px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
}
.banner-discord-btn:hover { background: rgba(255, 255, 255, 0.12); }

.banner-close {
  background: none; border: none;
  color: rgba(255, 255, 255, 0.5);
  cursor: pointer; padding: 4px;
  display: flex; align-items: center; justify-content: center;
}
.banner-close:hover { color: #fff; }
.banner-close svg { width: 20px; height: 20px; }

.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 14px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(18, 10, 32, 0.95);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
}
.header.has-banner { top: 48px; }

.navbar-brand { display: flex; align-items: center; text-decoration: none; }
.navbar-brand img { height: 48px; width: auto; }

.navbar-center { display: flex; align-items: center; gap: 8px; }

.nav-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: inherit;
  text-decoration: none;
  border-radius: 999px;
  transition: all 0.2s;
}
.nav-badge {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}
.nav-pill.active .nav-badge {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 6px rgba(255, 255, 255, 0.5);
}
.nav-pill:not(.active) .nav-badge {
  background: rgba(255, 255, 255, 0.35);
}
.nav-pill.active {
  background: linear-gradient(135deg, var(--purple-glow), var(--purple-accent));
  color: #fff;
  border: none;
}
.nav-pill:not(.active) {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.6);
}
.nav-pill:not(.active):hover {
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.9);
}

.navbar-right { display: flex; align-items: center; gap: 20px; }

.nav-support-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s;
}
.nav-support-link:hover { color: var(--purple-light); }
.nav-support-link svg { width: 20px; height: 20px; }

.nav-discord-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: linear-gradient(135deg, #5865f2, #4752c4);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 999px;
  transition: all 0.2s;
  box-shadow: 0 2px 12px rgba(88, 101, 242, 0.35);
}
.nav-discord-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(88, 101, 242, 0.45);
}
.nav-discord-btn svg { width: 22px; height: 22px; }

.lang-selector-wrap { display: flex; align-items: center; }
.lang-select {
  padding: 6px 12px; font-size: 0.85rem; font-family: inherit;
  background: rgba(45, 27, 78, 0.7); border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px; color: rgba(255, 255, 255, 0.9); cursor: pointer; outline: none;
  appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='rgba(255,255,255,0.6)' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 8px center; padding-right: 28px;
}
.lang-select:hover { border-color: rgba(157, 78, 221, 0.4); }
.lang-select option { background: #1a0a2e; color: #fff; }

/* Fix detail page */
.fix-detail-page {
  position: relative;
  z-index: 2;
  padding: 120px 24px 100px;
  max-width: 720px;
  margin: 0 auto;
}

.fix-detail-page .breadcrumb {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 16px;
}
.fix-detail-page .breadcrumb a {
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
}
.fix-detail-page .breadcrumb a:hover { color: var(--purple-light); }

.fix-detail-page .back-link {
  display: inline-block;
  font-size: 0.95rem;
  color: var(--purple-light);
  text-decoration: none;
  margin-bottom: 28px;
  transition: opacity 0.2s;
}
.fix-detail-page .back-link:hover { opacity: 0.85; }

.fix-detail-page h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.fix-detail-page .fix-lead {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.6;
  margin-bottom: 32px;
}
.fix-detail-page .fix-lead a {
  color: var(--purple-light);
  text-decoration: none;
}
.fix-detail-page .fix-lead a:hover { text-decoration: underline; }

.fix-content {
  background: rgba(26, 10, 46, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 32px;
}
.fix-content a {
  color: var(--purple-light);
  text-decoration: none;
}
.fix-content a:hover { text-decoration: underline; }

.fix-content ol,
.fix-content ul {
  margin: 0 0 0 24px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 1rem;
  line-height: 1.8;
}
.fix-content li { margin-bottom: 12px; }

.fix-content code {
  display: block;
  padding: 14px 18px;
  background: rgba(0, 0, 0, 0.35);
  border-radius: 10px;
  font-family: 'Consolas', monospace;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.95);
  margin: 16px 0;
  overflow-x: auto;
}

.fix-content .fix-step {
  margin-top: 28px;
  margin-bottom: 8px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.fix-content .fix-step:first-of-type { margin-top: 0; }
.fix-content .fix-step:last-of-type { border-bottom: none; padding-bottom: 0; }
.fix-content .fix-step h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--purple-light);
  margin-bottom: 10px;
}
.fix-content .fix-step p {
  font-weight: 400;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 10px;
  line-height: 1.6;
  font-size: 0.98rem;
}
.fix-content pre {
  background: rgba(0, 0, 0, 0.35);
  padding: 14px 18px;
  border-radius: 10px;
  overflow-x: auto;
  margin: 12px 0;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.95);
  white-space: pre-wrap;
  word-break: break-word;
}
.fix-content pre code {
  display: inline;
  padding: 0;
  margin: 0;
  background: none;
}
.fix-content .fix-source {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.fix-content .fix-source a {
  color: var(--purple-light);
  font-weight: 600;
  text-decoration: none;
}
.fix-content .fix-source a:hover { text-decoration: underline; }

.fix-content .fix-image {
  display: block;
  max-width: 100%;
  border-radius: 12px;
  margin: 18px 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.fix-content .fix-figure {
  margin: 24px 0;
}
.fix-content .fix-figure img {
  display: block;
  max-width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.fix-content .fix-figure figcaption {
  margin-top: 10px;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.55);
}

.fix-content .fix-alt-section {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.fix-content .discord-note {
  margin-top: 24px;
  padding: 16px 20px;
  background: rgba(88, 101, 242, 0.15);
  border-radius: 12px;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.9);
}
.fix-content .discord-note a {
  color: var(--purple-light);
  text-decoration: none;
  font-weight: 600;
}
.fix-content .discord-note a:hover { text-decoration: underline; }

.footer {
  position: relative;
  z-index: 2;
  margin-top: 80px;
  padding: 48px 24px 32px;
  background: rgba(18, 10, 32, 0.95);
  border-top: 1px solid rgba(157, 78, 221, 0.15);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.footer-brand { display: flex; align-items: center; text-decoration: none; }
.footer-brand img { height: 40px; width: auto; }

.footer-links { display: flex; align-items: center; gap: 28px; }

.footer-links a {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.95rem;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--purple-light); }

.footer-discord {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: linear-gradient(135deg, #5865f2, #4752c4);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 10px;
  transition: all 0.2s;
}
.footer-discord:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(88, 101, 242, 0.4);
}
.footer-discord svg { width: 20px; height: 20px; }

.footer-bottom {
  max-width: 1200px;
  margin: 32px auto 0;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  text-align: center;
}

.footer-bottom p { font-size: 0.9rem; color: rgba(255, 255, 255, 0.4); margin-bottom: 4px; }
.footer-bottom p:last-child { margin-bottom: 0; }
.footer-credit { color: rgba(255, 255, 255, 0.6); text-decoration: none; transition: color 0.2s; }
.footer-credit:hover { color: var(--purple-light); }

@media (max-width: 640px) {
  .fix-detail-page { padding: 100px 16px 80px; }
  .fix-detail-page h1 { font-size: 1.6rem; }
  .fix-content { padding: 24px; }
  .header { padding: 12px 16px; }
  .navbar-center { display: none; }
  .nav-support-link .nav-support-text { display: none; }
}

@media (max-width: 768px) {
  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
}
