/* ============================================
   Linilogic.my.id - Style Sheet
   Dark theme · Tech vibe · Clean typography
   ============================================ */

/* ---------- RESET & BASE ---------- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #111118;
  --bg-card: #16161f;
  --bg-card-hover: #1c1c28;
  --bg-section-dark: #0d0d15;

  --text-primary: #e8e8ed;
  --text-secondary: #9494a8;
  --text-muted: #5c5c70;

  --accent: #6c5ce7;
  --accent-light: #a29bfe;
  --accent-glow: rgba(108, 92, 231, 0.15);
  --accent-orange: #f39c12;
  --accent-green: #00b894;

  --border: #1e1e2e;
  --border-hover: #2d2d42;

  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 20px;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent-light);
  text-decoration: none;
  transition: color 0.2s;
}
a:hover {
  color: #fff;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- NAVBAR ---------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.logo {
  font-family: var(--font-mono);
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff !important;
  letter-spacing: -0.5px;
}

.logo-accent {
  color: var(--accent);
  font-weight: 800;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s;
  position: relative;
}

.nav-links a:hover,
.nav-links a.active {
  color: #fff;
}

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
}

/* ---------- HERO ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-top: 68px;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 680px;
}

.hero-badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent-light);
  background: rgba(108, 92, 231, 0.1);
  border: 1px solid rgba(108, 92, 231, 0.2);
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 24px;
  letter-spacing: 0.5px;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1px;
  margin-bottom: 20px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--accent), var(--accent-orange));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 520px;
  margin-bottom: 36px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

.btn-primary {
  display: inline-block;
  background: var(--accent);
  color: #fff !important;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  transition: all 0.25s;
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  background: #5a4bd1;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--accent-glow);
}

.btn-secondary {
  display: inline-block;
  background: transparent;
  color: var(--text-primary) !important;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  transition: all 0.25s;
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: #fff !important;
  background: rgba(108, 92, 231, 0.05);
}

.hero-stats {
  display: flex;
  gap: 40px;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-family: var(--font-mono);
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Code decoration */
.hero-decoration {
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  opacity: 0.15;
  pointer-events: none;
}

.code-snippet {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 2;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
}

.code-comment {
  color: #4a4a6a;
}

.code-keyword {
  color: var(--accent-light);
}

.code-string {
  color: var(--accent-green);
}

.code-func {
  color: var(--accent-orange);
}

/* ---------- SECTIONS ---------- */
.section {
  padding: 100px 0;
}

.section-dark {
  background: var(--bg-section-dark);
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-header h2 {
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  max-width: 500px;
  margin: 0 auto;
}

.section-footer {
  text-align: center;
  margin-top: 48px;
}

/* ---------- ARTICLE CARDS ---------- */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 28px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.3s ease;
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.card-image {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.card:hover .card-image img {
  transform: scale(1.03);
}

.card-category {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 100px;
  letter-spacing: 0.3px;
}

.card-body {
  padding: 22px;
}

.card-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.card-body h3 {
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 10px;
}

.card-body h3 a {
  color: var(--text-primary) !important;
}

.card-body h3 a:hover {
  color: var(--accent-light) !important;
}

.card-body p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 16px;
}

.card-cta {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent-light) !important;
}

/* ---------- CATEGORIES ---------- */
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}

.category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 28px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  transition: all 0.25s;
  color: var(--text-primary) !important;
}

.category-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px var(--accent-glow);
}

.category-icon {
  font-size: 2rem;
}

.category-name {
  font-weight: 600;
  font-size: 0.9rem;
}

.category-count {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ---------- FEATURES ---------- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 24px;
}

.feature-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 24px;
  transition: border-color 0.2s;
}

.feature-item:hover {
  border-color: var(--border-hover);
}

.feature-icon {
  font-size: 2rem;
  margin-bottom: 16px;
}

.feature-item h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-item p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.65;
}

/* ---------- CTA ---------- */
.section-cta {
  background: linear-gradient(135deg, var(--accent-glow), transparent);
  text-align: center;
}

.section-cta h2 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.section-cta p {
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.subscribe-form {
  display: flex;
  gap: 12px;
  max-width: 460px;
  margin: 0 auto;
}

.subscribe-form input {
  flex: 1;
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-primary);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}

.subscribe-form input:focus {
  border-color: var(--accent);
}

.subscribe-form input::placeholder {
  color: var(--text-muted);
}

/* ---------- FOOTER ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding-top: 60px;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  gap: 48px;
  flex-wrap: wrap;
  padding-bottom: 40px;
}

.footer p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-top: 8px;
  max-width: 240px;
}

.footer-links {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col h4 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.footer-col a {
  font-size: 0.9rem;
  color: var(--text-secondary) !important;
}

.footer-col a:hover {
  color: #fff !important;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 20px 0;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.affiliate-disclaimer {
  margin-top: 6px;
  font-size: 0.7rem !important;
  color: var(--text-muted);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 900px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .hero-decoration {
    display: none;
  }

  .article-grid {
    grid-template-columns: 1fr;
  }

  .features-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-content {
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .nav-links {
    display: none;
  }

  .nav-container.open .nav-links {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border);
    padding: 20px 24px;
    gap: 16px;
    z-index: 101;
  }

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

  .hero h1 {
    font-size: 2rem;
  }

  .hero-stats {
    gap: 24px;
  }

  .stat-number {
    font-size: 1.4rem;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .category-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .subscribe-form {
    flex-direction: column;
  }

  .section {
    padding: 60px 0;
  }

  .footer-links {
    gap: 24px;
  }
}
