/* ==========================================================================
   OpenManager Web - High-Performance Dark Theme (v2)
   ========================================================================== */

:root {
  --bg-dark: #0a0c10;
  --bg-card: #13171f;
  --bg-card-hover: #191f2b;
  --bg-alt: #0e1117;
  --primary: #2196f3;
  --primary-hover: #1976d2;
  --primary-glow: rgba(33, 150, 243, 0.22);
  --accent: #10b981;
  --border: #232936;
  --border-light: #323b4e;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --text-sub: #6b7280;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ==========================================================================
   Navbar
   ========================================================================== */

.navbar {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background: rgba(10, 12, 16, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-main);
}

.brand-logo {
  border-radius: var(--radius-sm);
  filter: drop-shadow(0 2px 8px var(--primary-glow));
}

.brand-name {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.badge-tag {
  background: rgba(33, 150, 243, 0.12);
  color: #64b5f6;
  border: 1px solid rgba(33, 150, 243, 0.28);
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: nowrap;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  transition: var(--transition);
}

.nav-links a:hover {
  color: var(--text-main);
}

/* Language Switcher */
.lang-selector {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
}

.lang-icon {
  font-size: 0.9rem;
}

.lang-selector select {
  background: transparent;
  border: none;
  color: var(--text-main);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  font-family: inherit;
}

.lang-selector select option {
  background: #15181e;
  color: #fff;
}

.nav-btn-release {
  background: rgba(255, 255, 255, 0.07);
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.nav-btn-release:hover {
  background: rgba(255, 255, 255, 0.14) !important;
  color: #fff !important;
}

.nav-btn-gh {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--text-main);
  color: #0a0c10 !important;
  padding: 6px 15px;
  border-radius: var(--radius-sm);
  font-weight: 700 !important;
}

.nav-btn-gh:hover {
  background: #e5e7eb;
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

.mobile-menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-main);
  margin: 5px 0;
  border-radius: 2px;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

section, header {
  scroll-margin-top: 80px;
}

.hero {
  position: relative;
  padding: clamp(2.5rem, 5vw, 4.5rem) 0 45px;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: 40px;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 380px;
  background: radial-gradient(ellipse at center, rgba(33, 150, 243, 0.16) 0%, rgba(16, 185, 129, 0.06) 40%, transparent 70%);
  filter: blur(70px);
  pointer-events: none;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 1100px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 210px 1fr;
  gap: 40px;
  align-items: center;
  text-align: left;
  margin-bottom: 32px;
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-icon-card {
  position: relative;
  padding: 14px;
  background: linear-gradient(145deg, rgba(25, 31, 43, 0.95), rgba(14, 17, 24, 0.9));
  border: 1px solid var(--border-light);
  border-radius: 26px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5), 0 0 32px rgba(33, 150, 243, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.hero-icon-card:hover {
  transform: translateY(-4px) scale(1.02);
  border-color: rgba(33, 150, 243, 0.45);
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.6), 0 0 40px rgba(33, 150, 243, 0.28);
}

.hero-app-icon {
  width: 180px;
  height: 180px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 20px;
  display: block;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.4));
}

.hero-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.hero-text .hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(33, 150, 243, 0.1);
  border: 1px solid rgba(33, 150, 243, 0.25);
  color: #90caf9;
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.83rem;
  margin-bottom: 16px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 10px #10b981;
}

.hero-text .hero-title {
  font-size: clamp(2rem, 1.2rem + 3.2vw, 3.2rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  text-align: left;
  margin-bottom: 16px;
}

.gradient-text {
  background: linear-gradient(135deg, #64b5f6 0%, #2196f3 50%, #10b981 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-text .hero-subtitle {
  font-size: clamp(0.95rem, 0.85rem + 0.35vw, 1.12rem);
  color: var(--text-muted);
  max-width: 720px;
  margin: 0 0 28px 0;
  line-height: 1.68;
  text-align: left;
}

.hero-text .hero-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 12px 26px;
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
  transition: var(--transition);
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: #fff;
  box-shadow: 0 4px 18px var(--primary-glow);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(33, 150, 243, 0.38);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-main);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-light);
  transform: translateY(-2px);
}

.btn-lg {
  padding: 15px 32px;
  font-size: 1.02rem;
}

.tech-pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.tech-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.tech-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--border-light);
  color: var(--text-main);
}

.pill-img {
  width: 15px;
  height: 15px;
  object-fit: contain;
  border-radius: 2px;
  flex-shrink: 0;
}

.pill-svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.highlight-pill-shizuku {
  border-color: rgba(33, 150, 243, 0.35) !important;
  background: rgba(33, 150, 243, 0.09) !important;
  color: #93c5fd !important;
}

.highlight-pill-dfroot {
  border-color: rgba(239, 68, 68, 0.35) !important;
  background: rgba(239, 68, 68, 0.09) !important;
  color: #fca5a5 !important;
}

/* ==========================================================================
   Metrics Bar
   ========================================================================== */

.metrics-bar {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 30px 0;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  text-align: center;
}

.metric-item {
  padding: 6px 12px;
}

.metric-number {
  font-size: 2.1rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.02em;
  margin-bottom: 2px;
}

.metric-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* ==========================================================================
   Sections
   ========================================================================== */

.section {
  padding: 85px 0;
}

.bg-alt {
  background-color: var(--bg-alt);
}

.section-header {
  margin-bottom: 48px;
}

.text-center {
  text-align: center;
}

.section-title {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.section-subtitle {
  font-size: 1.02rem;
  color: var(--text-muted);
  max-width: 660px;
  margin: 0 auto;
}

/* ==========================================================================
   Category Tabs
   ========================================================================== */

.category-tabs {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.cat-tab {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: var(--transition);
}

.cat-tab:hover {
  background: var(--bg-card-hover);
  color: var(--text-main);
  border-color: var(--border-light);
}

.cat-tab.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 2px 12px var(--primary-glow);
}

/* ==========================================================================
   Features Grid
   ========================================================================== */

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.feature-card.hidden {
  display: none !important;
}

.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(33, 150, 243, 0.35);
  transform: translateY(-3px);
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  transition: var(--transition);
}

.feature-icon svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  display: block;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover .feature-icon svg {
  transform: scale(1.14);
}

.feature-icon-asset {
  width: 32px;
  height: 32px;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.35));
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover .feature-icon-asset {
  transform: scale(1.15);
}

.bg-blue { background: rgba(33, 150, 243, 0.14); color: #60a5fa; }
.bg-emerald { background: rgba(16, 185, 129, 0.14); color: #34d399; }
.bg-purple { background: rgba(139, 92, 246, 0.14); color: #c084fc; }
.bg-cyan { background: rgba(6, 182, 212, 0.14); color: #22d3ee; }
.bg-amber { background: rgba(245, 158, 11, 0.14); color: #fbbf24; }
.bg-indigo { background: rgba(99, 102, 241, 0.14); color: #818cf8; }
.bg-red { background: rgba(239, 68, 68, 0.14); color: #f87171; }
.bg-teal { background: rgba(20, 184, 166, 0.14); color: #2dd4bf; }
.bg-orange { background: rgba(249, 115, 22, 0.14); color: #fb923c; }
.bg-pink { background: rgba(236, 72, 153, 0.14); color: #f472b6; }
.bg-yellow { background: rgba(234, 179, 8, 0.14); color: #facc15; }

.feature-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-main);
}

.feature-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.55;
}

.feature-desc code {
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 5px;
  border-radius: 4px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85em;
  color: #93c5fd;
}

/* ==========================================================================
   Gallery Grid
   ========================================================================== */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-card);
  aspect-ratio: 9 / 19.5;
  cursor: pointer;
  transition: var(--transition);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
}

.gallery-item:hover img {
  transform: scale(1.03);
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(10, 12, 16, 0.95) 0%, rgba(10, 12, 16, 0.4) 60%, transparent 100%);
  padding: 14px 10px 10px;
  text-align: center;
}

.gallery-overlay span {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-main);
}

/* ==========================================================================
   Comparison Table
   ========================================================================== */

.table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-card);
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.comparison-table th,
.comparison-table td {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 0.92rem;
}

.comparison-table th {
  background: rgba(255, 255, 255, 0.03);
  font-weight: 700;
  color: var(--text-main);
}

.comparison-table .highlight-col {
  background: rgba(33, 150, 243, 0.05);
}

.comparison-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.badge-success {
  color: #34d399;
  font-weight: 700;
}

.table-inline-icon {
  width: 18px;
  height: 18px;
  object-fit: contain;
  vertical-align: -3px;
  margin-right: 8px;
  border-radius: 4px;
}

/* ==========================================================================
   Code Terminal
   ========================================================================== */

.code-terminal {
  max-width: 720px;
  margin: 0 auto;
  background: #111419;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.terminal-bar {
  background: #161a22;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
}

.t-dots {
  display: flex;
  gap: 7px;
}

.t-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}

.t-dot.red { background: #ef4444; }
.t-dot.yellow { background: #f59e0b; }
.t-dot.green { background: #10b981; }

.terminal-title {
  font-size: 0.8rem;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-muted);
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  color: var(--text-main);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}

.copy-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--border-light);
}

.terminal-body {
  padding: 20px 24px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9rem;
  line-height: 1.65;
  overflow-x: auto;
}

.c-comment { color: #6b7280; }
.c-cmd { color: #60a5fa; font-weight: 600; }

/* ==========================================================================
   CTA Banner
   ========================================================================== */

.cta-banner {
  padding: 85px 0;
  background: radial-gradient(ellipse at center, rgba(33, 150, 243, 0.12) 0%, transparent 70%);
  border-top: 1px solid var(--border);
}

.cta-title {
  font-size: 2.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.cta-subtitle {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 30px;
}

.cta-buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  background: #08090c;
  border-top: 1px solid var(--border);
  padding: 50px 0 35px;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  gap: 36px;
  flex-wrap: wrap;
}

.footer-brand {
  max-width: 360px;
}

.footer-logo {
  vertical-align: middle;
  margin-right: 8px;
}

.footer-name {
  font-size: 1.15rem;
  font-weight: 800;
}

.footer-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin: 10px 0;
}

.footer-copyright {
  font-size: 0.76rem;
  color: var(--text-sub);
  line-height: 1.6;
}

.footer-copyright a {
  color: var(--text-muted);
  text-decoration: none;
}

.footer-links-group {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-links-group h4 {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.footer-links-group a {
  font-size: 0.86rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
}

.footer-links-group a:hover {
  color: var(--primary);
}

/* ==========================================================================
   Lightbox Modal
   ========================================================================== */

.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(8px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 82vh;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

.lightbox-caption {
  margin-top: 12px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-main);
  text-align: center;
}

.lightbox-close {
  position: absolute;
  top: -38px;
  right: 0;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 992px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 24px;
  }

  .hero-text {
    align-items: center;
  }

  .hero-text .hero-title,
  .hero-text .hero-subtitle {
    text-align: center;
    margin-inline: auto;
  }

  .hero-text .hero-actions {
    justify-content: center;
  }

  .hero-app-icon {
    width: 140px;
    height: 140px;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #0d1016;
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 20px;
    gap: 14px;
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.5);
  }

  .nav-links.active {
    display: flex;
  }

  .mobile-menu-toggle {
    display: block;
  }

  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .metrics-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
}

@media (max-width: 768px) {
  .features-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .metrics-grid { grid-template-columns: 1fr; }
  .hero-app-icon {
    width: 110px;
    height: 110px;
  }
}
