/* ==========================================================================
   Clean Academic Design System (Option B)
   Website Portofolio & Bahan Ajar Guru SMK TKJ
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@500;600;700;800&display=swap');

:root {
  --primary-navy: #1e3a8a;
  --primary-hover: #1e40af;
  --accent-teal: #0d9488;
  --accent-teal-hover: #0f766e;
  --bg-main: #f8fafc;
  --bg-alt: #f1f5f9;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -1px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -2px rgba(0,0,0,0.03);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
}

[data-theme="dark"] {
  --primary-navy: #60a5fa;
  --primary-hover: #93c5fd;
  --accent-teal: #2dd4bf;
  --accent-teal-hover: #5eead4;
  --bg-main: #0b0f19;
  --bg-alt: #111827;
  --bg-card: #151e2e;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --border-color: #243247;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.4);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.5), 0 2px 4px -1px rgba(0,0,0,0.3);
  --shadow-lg: 0 10px 25px -3px rgba(0,0,0,0.6);
}

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

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
  color: var(--primary-navy);
  margin-bottom: 0.75rem;
  font-weight: 700;
}

a {
  color: var(--primary-navy);
  text-decoration: none;
  transition: all 0.2s ease;
}

a:hover {
  color: var(--accent-teal);
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* ===========================
   PREMIUM NAVBAR
   =========================== */
.site-header {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 1px 20px rgba(0, 0, 0, 0.06);
  transition: all 0.3s ease;
}

.site-header.scrolled {
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 4px 24px rgba(30, 58, 138, 0.12);
  border-bottom-color: rgba(30, 58, 138, 0.15);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 0;
}

/* Brand Logo */
.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.brand-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--primary-navy) 0%, var(--accent-teal) 100%);
  color: white;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  box-shadow: 0 4px 12px rgba(30, 58, 138, 0.35);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  flex-shrink: 0;
}

.brand-logo:hover .brand-icon {
  transform: rotate(-8deg) scale(1.08);
  box-shadow: 0 6px 18px rgba(30, 58, 138, 0.45);
}

.brand-text .title {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--primary-navy);
  line-height: 1.2;
  transition: color 0.2s;
}

.brand-logo:hover .brand-text .title {
  color: var(--accent-teal);
}

.brand-text .subtitle {
  font-size: 0.7rem;
  color: var(--accent-teal);
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  opacity: 0.85;
}

/* Nav Links */
.nav-links {
  display: flex;
  list-style: none;
  gap: 0.1rem;
  align-items: center;
  margin: 0;
  padding: 0;
}

.nav-links a {
  font-weight: 500;
  font-size: 0.9rem;
  color: #475569;
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  position: relative;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.nav-links a i {
  font-size: 0.8rem;
  opacity: 0.75;
  transition: opacity 0.2s, transform 0.2s;
}

.nav-links a:hover {
  color: var(--primary-navy);
  background: #eff6ff;
  font-weight: 600;
}

.nav-links a:hover i {
  opacity: 1;
  transform: translateY(-1px);
}

.nav-links a.active {
  color: var(--primary-navy);
  background: #eff6ff;
  font-weight: 700;
}

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 3px;
  background: var(--accent-teal);
  border-radius: 2px;
}

/* Admin Button */
.btn-admin-login {
  background: linear-gradient(135deg, var(--primary-navy) 0%, #2563eb 100%) !important;
  color: white !important;
  padding: 0.5rem 1.2rem !important;
  border-radius: var(--radius-md) !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.45rem !important;
  box-shadow: 0 3px 10px rgba(30, 58, 138, 0.35) !important;
  transition: all 0.25s ease !important;
  font-size: 0.88rem !important;
}

.btn-admin-login:hover {
  background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 100%) !important;
  color: white !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 20px rgba(30, 58, 138, 0.45) !important;
}

/* Hamburger Button */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 0;
  transition: all 0.2s ease;
  z-index: 1100;
}

.hamburger:hover {
  background: #eff6ff;
  border-color: var(--primary-navy);
}

.hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--primary-navy);
  border-radius: 2px;
  transition: all 0.3s ease;
  transform-origin: center;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Hero Section */
.hero-section {
  background: linear-gradient(135deg, #1e3a8a 0%, #0f172a 100%);
  color: white;
  padding: 4rem 0;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(13, 148, 136, 0.25) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  padding: 0.4rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #5eead4;
  margin-bottom: 1.25rem;
  border: 1px solid rgba(255,255,255,0.2);
}

.hero-title {
  color: white;
  font-size: 2.75rem;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: #cbd5e1;
  margin-bottom: 2rem;
  font-weight: 300;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-primary {
  background: var(--accent-teal);
  color: white;
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  background: var(--accent-teal-hover);
  color: white;
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: white;
  border: 2px solid rgba(255,255,255,0.3);
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-outline:hover {
  background: rgba(255,255,255,0.1);
  color: white;
  border-color: white;
}

.hero-profile-card {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.avatar-wrapper {
  width: 120px;
  height: 120px;
  margin: 0 auto 1.25rem;
  border-radius: 50%;
  border: 4px solid var(--accent-teal);
  background: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  color: var(--primary-navy);
  box-shadow: var(--shadow-md);
}

.profile-name {
  color: white;
  font-size: 1.4rem;
  margin-bottom: 0.25rem;
}

.profile-role {
  color: #94a3b8;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.quick-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 1.25rem;
}

.stat-item .num {
  font-size: 1.4rem;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  color: #5eead4;
}

.stat-item .lbl {
  font-size: 0.75rem;
  color: #cbd5e1;
}

/* Sections */
.section {
  padding: 4rem 0;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 3rem;
}

.section-title {
  font-size: 2rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: var(--accent-teal);
  margin: 0.5rem auto 0;
  border-radius: 2px;
}

.section-desc {
  color: var(--text-muted);
  font-size: 1rem;
}

/* Cards & Grid */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: #cbd5e1;
}

.card-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  width: fit-content;
  margin-bottom: 1rem;
}

.badge-x { background: #e0f2fe; color: #0369a1; }
.badge-xi { background: #f0fdf4; color: #15803d; }
.badge-xii { background: #fef3c7; color: #b45309; }
.badge-umum { background: #f3e8ff; color: #6b21a8; }

.card-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.card-desc {
  color: var(--text-muted);
  font-size: 0.925rem;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.card-footer {
  border-top: 1px solid var(--border-color);
  padding-top: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.btn-sm {
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
  border-radius: var(--radius-sm);
}

/* Certifications Badges */
.cert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.cert-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  box-shadow: var(--shadow-sm);
}

.cert-icon {
  width: 54px;
  height: 54px;
  background: #eff6ff;
  color: var(--primary-navy);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  flex-shrink: 0;
}

.cert-info h4 {
  font-size: 1rem;
  margin-bottom: 0.2rem;
}

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

/* Interactive Tools UI */
.tool-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-md);
  margin-bottom: 2rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 0.95rem;
  transition: all 0.2s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-navy);
  box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

/* Tables & Admin Panel */
.table-responsive {
  overflow-x: auto;
}

.custom-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.custom-table th, .custom-table td {
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.custom-table th {
  background: #f1f5f9;
  font-family: 'Outfit', sans-serif;
  color: var(--primary-navy);
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
}

.custom-table tr:hover {
  background: #f8fafc;
}

.alert {
  padding: 1rem 1.25rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.alert-success { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; }
.alert-danger { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.alert-info { background: #e0f2fe; color: #075985; border: 1px solid #bae6fd; }

/* Footer */
.site-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 3rem 0 1.5rem;
  margin-top: auto;
  border-top: 4px solid var(--primary-navy);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-brand h3 {
  color: white;
  font-size: 1.3rem;
}

.footer-links h4 {
  color: white;
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.footer-links ul {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: #94a3b8;
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: #5eead4;
}

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
}

/* Floating WhatsApp Button */
.wa-float {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background: #25d366;
  color: white;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  box-shadow: var(--shadow-lg);
  z-index: 999;
  transition: transform 0.2s ease;
}

.wa-float:hover {
  transform: scale(1.1);
  color: white;
}

/* Code Blocks */
pre {
  background: #0f172a;
  color: #f8fafc;
  padding: 1.25rem;
  border-radius: var(--radius-md);
  overflow-x: auto;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.9rem;
  margin: 1rem 0;
}

code {
  background: #f1f5f9;
  color: #0f172a;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.9rem;
}

pre code {
  background: transparent;
  color: inherit;
  padding: 0;
}

/* ===========================
   RESPONSIVE BREAKPOINTS
   =========================== */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-actions {
    justify-content: center;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  /* Mobile Navbar */
  .hamburger {
    display: flex;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 280px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    padding: 5rem 1.5rem 2rem;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.12);
    z-index: 1050;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .nav-links.open {
    display: flex;
    transform: translateX(0);
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border-radius: var(--radius-md);
    color: var(--text-main);
  }

  .nav-links a.active::after {
    display: none;
  }

  .nav-links a.active {
    background: #eff6ff;
    border-left: 4px solid var(--accent-teal);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
  }

  /* Overlay */
  .nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    z-index: 1040;
    backdrop-filter: blur(2px);
  }

  .nav-overlay.open {
    display: block;
  }
}

/* ==========================================================================
   DARK MODE COMPONENT OVERRIDES
   ========================================================================== */
[data-theme="dark"] .site-header {
  background: rgba(11, 15, 25, 0.88);
  border-bottom-color: #243247;
}

[data-theme="dark"] .site-header.scrolled {
  background: rgba(11, 15, 25, 0.98);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .nav-links a {
  color: #94a3b8;
}

[data-theme="dark"] .nav-links a:hover,
[data-theme="dark"] .nav-links a.active {
  color: #60a5fa;
  background: #1e293b;
}

[data-theme="dark"] .form-control {
  background: #0f172a;
  border-color: #334155;
  color: #f8fafc;
}

[data-theme="dark"] .form-control:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.2);
}

[data-theme="dark"] .custom-table {
  background: var(--bg-card);
}

[data-theme="dark"] .custom-table th {
  background: #1e293b;
  color: #60a5fa;
  border-color: #334155;
}

[data-theme="dark"] .custom-table td {
  border-color: #243247;
  color: #cbd5e1;
}

[data-theme="dark"] .custom-table tr:hover {
  background: #1e293b;
}

[data-theme="dark"] .cert-card {
  background: var(--bg-card);
  border-color: var(--border-color);
}

[data-theme="dark"] .cert-icon {
  background: #1e293b;
  color: #60a5fa;
}

[data-theme="dark"] code {
  background: #0f172a;
  color: #38bdf8;
  border: 1px solid #334155;
}

[data-theme="dark"] .hamburger {
  border-color: #334155;
}

[data-theme="dark"] .hamburger span {
  background: #e2e8f0;
}

@media (max-width: 900px) {
  [data-theme="dark"] .nav-links {
    background: rgba(15, 23, 42, 0.98);
  }
}

/* Header Actions & Theme Toggle Button */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.theme-toggle-btn {
  background: transparent;
  border: 1.5px solid var(--border-color);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-navy);
  cursor: pointer;
  font-size: 1.05rem;
  transition: all 0.2s ease;
}

.theme-toggle-btn:hover {
  background: #eff6ff;
  border-color: var(--primary-navy);
  transform: rotate(15deg);
}

[data-theme="dark"] .theme-toggle-btn {
  color: #facc15;
  border-color: #334155;
}

[data-theme="dark"] .theme-toggle-btn:hover {
  background: #1e293b;
  border-color: #facc15;
}

/* ==========================================================================
   TOOL: RJ45 CRIMPING VISUALIZER & LAN TESTER
   ========================================================================== */
.rj45-connector {
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-top: 1rem;
}

.wire-pins-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 6px;
  margin: 1rem 0;
}

.wire-pin {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-align: center;
}

.wire-stripe {
  width: 100%;
  height: 90px;
  border-radius: 4px;
  box-shadow: inset 0 0 4px rgba(0,0,0,0.25);
  border: 1px solid rgba(0,0,0,0.15);
  transition: transform 0.2s ease;
}

.wire-pin:hover .wire-stripe {
  transform: translateY(-4px) scale(1.05);
}

.pin-label {
  color: var(--text-muted);
  font-size: 0.7rem;
}

/* Wire Color Schemes */
.wire-wo { background: repeating-linear-gradient(45deg, #ffffff, #ffffff 6px, #ea580c 6px, #ea580c 12px); }
.wire-o  { background: #ea580c; }
.wire-wg { background: repeating-linear-gradient(45deg, #ffffff, #ffffff 6px, #16a34a 6px, #16a34a 12px); }
.wire-b  { background: #2563eb; }
.wire-wb { background: repeating-linear-gradient(45deg, #ffffff, #ffffff 6px, #2563eb 6px, #2563eb 12px); }
.wire-g  { background: #16a34a; }
.wire-wbr{ background: repeating-linear-gradient(45deg, #ffffff, #ffffff 6px, #854d0e 6px, #854d0e 12px); }
.wire-br { background: #78350f; }

/* LAN Tester LED Indicators */
.tester-box {
  background: #0f172a;
  color: #e2e8f0;
  padding: 1.25rem;
  border-radius: var(--radius-md);
  margin-top: 1.5rem;
  border: 1px solid #334155;
}

.tester-leds {
  display: flex;
  justify-content: space-around;
  gap: 0.5rem;
  margin: 1rem 0;
}

.led-indicator {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #334155;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: #94a3b8;
  transition: all 0.15s ease;
}

.led-indicator.active {
  background: #22c55e;
  color: #ffffff;
  box-shadow: 0 0 12px #22c55e, 0 0 20px rgba(34, 197, 94, 0.6);
  transform: scale(1.15);
}

/* ==========================================================================
   TOOL: BINARY - DECIMAL - HEX 8-BIT CONVERTER
   ========================================================================== */
.bit-matrix {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 0.5rem;
  margin: 1.5rem 0;
}

.bit-cell {
  background: var(--bg-card);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.75rem 0.25rem;
  text-align: center;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
}

.bit-cell.on {
  border-color: var(--accent-teal);
  background: rgba(13, 148, 136, 0.1);
}

.bit-weight {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.bit-val {
  font-size: 1.5rem;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  color: var(--primary-navy);
  margin-top: 0.25rem;
}

.bit-cell.on .bit-val {
  color: var(--accent-teal);
}

/* ==========================================================================
   QUIZ CBT INTERACTIVE SYSTEM
   ========================================================================== */
.quiz-header-card {
  background: linear-gradient(135deg, #1e3a8a 0%, #0d9488 100%);
  color: white;
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-lg);
}

.quiz-progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  overflow: hidden;
  margin: 1.25rem 0 0.5rem;
}

.quiz-progress-fill {
  height: 100%;
  background: #34d399;
  width: 0%;
  transition: width 0.3s ease;
}

.question-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-md);
  margin-bottom: 2rem;
}

.quiz-options {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin: 1.5rem 0;
}

.quiz-option {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--bg-card);
  font-size: 0.95rem;
}

.quiz-option:hover {
  border-color: var(--accent-teal);
  background: rgba(13, 148, 136, 0.05);
}

.quiz-option.selected {
  border-color: var(--accent-teal);
  background: rgba(13, 148, 136, 0.12);
  font-weight: 600;
}

.opt-letter {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
  color: var(--text-main);
  transition: all 0.2s;
}

.quiz-option.selected .opt-letter {
  background: var(--accent-teal);
  color: white;
}

.quiz-result-score {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-navy) 0%, var(--accent-teal) 100%);
  color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  box-shadow: 0 8px 24px rgba(13, 148, 136, 0.35);
}

.quiz-result-score .number {
  font-size: 2.75rem;
  font-weight: 800;
  font-family: 'Outfit', sans-serif;
  line-height: 1;
}

.quiz-result-score .label {
  font-size: 0.8rem;
  opacity: 0.85;
  text-transform: uppercase;
  font-weight: 600;
}

.review-item {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1rem;
  background: var(--bg-card);
}

.review-item.correct {
  border-left: 5px solid #22c55e;
}

.review-item.incorrect {
  border-left: 5px solid #ef4444;
}

.review-explanation {
  background: rgba(13, 148, 136, 0.08);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  margin-top: 0.75rem;
  font-size: 0.88rem;
  color: var(--text-main);
}

/* ==========================================================================
   8. Material Reader Content Typography & Code Blocks
   ========================================================================== */
.material-content {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--text-main);
}

.material-content .materi-h2 {
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--primary-navy);
  margin-top: 2.2rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--border-color);
}

.material-content .materi-h3 {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--primary-navy);
  margin-top: 1.8rem;
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.material-content .materi-h4 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--accent-teal);
  margin-top: 1.4rem;
  margin-bottom: 0.65rem;
}

.material-content .materi-p {
  margin-bottom: 1.15rem;
  color: var(--text-main);
}

.material-content .materi-ul,
.material-content .materi-ol {
  margin-bottom: 1.25rem;
  padding-left: 1.75rem;
}

.material-content .materi-ul li,
.material-content .materi-ol li {
  margin-bottom: 0.5rem;
  line-height: 1.7;
}

.material-content .materi-quote {
  background: rgba(13, 148, 136, 0.08);
  border-left: 4px solid var(--accent-teal);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 0.9rem 1.25rem;
  margin: 1.25rem 0;
  font-style: italic;
  color: var(--text-main);
}

.material-content .materi-hr {
  border: 0;
  border-top: 1px dashed var(--border-color);
  margin: 2rem 0;
}

.material-content .inline-code {
  background: var(--bg-alt);
  color: #e11d48;
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 0.9em;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
  border: 1px solid var(--border-color);
}

[data-theme="dark"] .material-content .inline-code {
  color: #fb7185;
  background: #1e293b;
}

.code-block-container {
  margin: 1.35rem 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid #334155;
  background: #0f172a;
  box-shadow: var(--shadow-md);
}

.code-block-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 1rem;
  background: #1e293b;
  border-bottom: 1px solid #334155;
  font-size: 0.8rem;
  color: #94a3b8;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
}

.code-block-header .code-lang {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #38bdf8;
  letter-spacing: 0.05em;
}

.code-block-header .btn-copy-code {
  background: transparent;
  border: 1px solid #475569;
  color: #cbd5e1;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.75rem;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.code-block-header .btn-copy-code:hover {
  background: #334155;
  color: #ffffff;
  border-color: #64748b;
}

.code-block {
  margin: 0;
  padding: 1.15rem 1.25rem;
  overflow-x: auto;
  font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
  font-size: 0.92rem;
  line-height: 1.65;
  color: #e2e8f0;
  background: #0f172a;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
  margin: 1.5rem 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.materi-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.95rem;
}

.materi-table th {
  background: var(--bg-alt);
  color: var(--primary-navy);
  font-weight: 700;
  padding: 0.85rem 1rem;
  border-bottom: 2px solid var(--border-color);
  white-space: nowrap;
}

.materi-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-main);
}

.materi-table tbody tr:last-child td {
  border-bottom: none;
}

.materi-table tbody tr:hover {
  background: rgba(13, 148, 136, 0.04);
}

/* ==========================================================================
   Interactive PC Builder, Motherboard Explorer & Hardware Catalog Styles
   ========================================================================== */

/* Sub-Tab Navigation inside Tool Boxes */
.tool-subtabs {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.75rem;
  margin-bottom: 1.5rem;
}

.tool-subtab-btn {
  background: transparent;
  border: 1px solid var(--border-color);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
}

.tool-subtab-btn:hover {
  color: var(--primary-navy);
  border-color: var(--primary-navy);
  background: rgba(30, 58, 138, 0.04);
}

.tool-subtab-btn.active {
  background: var(--primary-navy);
  color: #ffffff;
  border-color: var(--primary-navy);
}

[data-theme="dark"] .tool-subtab-btn.active {
  background: var(--accent-teal);
  color: #0b0f19;
  border-color: var(--accent-teal);
}

/* PC Step Stepper / Timeline */
.pc-stepper-nav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 0.4rem;
  margin-bottom: 1.5rem;
}

.pc-step-pill {
  background: var(--bg-alt);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.5rem;
  text-align: center;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
}

.pc-step-pill .step-num {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
}

.pc-step-pill:hover {
  border-color: var(--accent-teal);
  color: var(--accent-teal);
}

.pc-step-pill.active {
  background: var(--accent-teal);
  color: #ffffff;
  border-color: var(--accent-teal);
}

.pc-step-pill.active .step-num {
  color: #ffffff;
}

.pc-step-pill.completed {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.08);
  color: #10b981;
}

/* PC Step Content Box */
.pc-step-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
}

.pc-step-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 1.25rem;
}

.pc-step-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary-navy);
  margin-bottom: 0;
}

.pc-badge-level {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-risk-low {
  background: #dcfce7;
  color: #15803d;
}
.badge-risk-med {
  background: #fef9c3;
  color: #a16207;
}
.badge-risk-high {
  background: #fee2e2;
  color: #b91c1c;
}

/* Checklist items */
.checklist-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  background: var(--bg-alt);
  margin-bottom: 0.5rem;
  font-size: 0.92rem;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid transparent;
}

.checklist-item:hover {
  border-color: var(--accent-teal);
}

.checklist-item.checked {
  background: rgba(16, 185, 129, 0.08);
  border-color: #10b981;
  text-decoration: line-through;
  color: var(--text-muted);
}

.checklist-item input[type="checkbox"] {
  margin-top: 0.2rem;
  width: 17px;
  height: 17px;
  accent-color: var(--accent-teal);
  cursor: pointer;
}

/* Motherboard Explorer */
.motherboard-explorer-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 1.5rem;
  align-items: start;
}

@media (max-width: 992px) {
  .motherboard-explorer-grid {
    grid-template-columns: 1fr;
  }
}

.motherboard-svg-box {
  background: #090d16;
  border: 1px solid #1e293b;
  border-radius: var(--radius-md);
  padding: 1rem;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.mb-part {
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.mb-part:hover {
  filter: drop-shadow(0 0 8px rgba(6, 182, 212, 0.95)) brightness(1.25);
}

.mb-part.active {
  filter: drop-shadow(0 0 12px rgba(13, 148, 136, 1)) drop-shadow(0 0 20px rgba(56, 189, 248, 0.8)) brightness(1.35);
}

.mb-part.active rect, .mb-part.active circle, .mb-part.active path {
  stroke: #22d3ee !important;
  stroke-width: 2.5px !important;
}

.mb-inspector-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 90px;
}

.mb-inspector-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.mb-inspector-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: rgba(13, 148, 136, 0.12);
  color: var(--accent-teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.mb-tag-pill {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: var(--bg-alt);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

.mb-quick-pill {
  background: var(--bg-alt);
  border: 1px solid var(--border-color);
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.mb-quick-pill:hover, .mb-quick-pill.active {
  background: var(--accent-teal);
  color: #ffffff;
  border-color: var(--accent-teal);
}

/* Hardware Components Catalog Cards */
.hw-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  margin-bottom: 1.5rem;
}

.hw-card:hover {
  box-shadow: var(--shadow-md);
}

.hw-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.hw-spec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.85rem;
  margin: 1rem 0;
}

.hw-spec-item {
  background: var(--bg-alt);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.75rem;
}

.hw-spec-item .label {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: block;
  margin-bottom: 0.2rem;
  font-weight: 600;
}

.hw-spec-item .value {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
}



