/* ===== Embedded Electronics — Shared Theme ===== */
/* -- Tweak brand colors here -- */
:root {
  --brand: #0b66b2;       /* primary blue */
  --brand-2: #00a99d;     /* accent teal */
  --ink: #17202a;         /* text */
  --muted: #6b7a86;
  --bg: #f4f6f8;
  --card: #ffffff;
  --maxw: 1100px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: Inter, Segoe UI, Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.55;
}

/* Containers */
.container { width: 92%; max-width: var(--maxw); margin: 0 auto; }

/* Header & Nav */
.site-header {
  background: linear-gradient(90deg, #032b44, #003b5c);
  color: #e6f3fb;
  position: sticky;
  top: 0;
  z-index: 10;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
}
.brand {
  display: flex;
  gap: 10px;
  align-items: center;
  color: #e6f3fb;
  text-decoration: none;
}
.brand-logo { height: 46px; width: auto; }
.brand-name { font-weight: 700; letter-spacing: 0.2px; }
.menu-toggle {
  display: none;
  background: transparent;
  border: 0;
  color: #e6f3fb;
  font-size: 24px;
  cursor: pointer;
}
.nav { display: flex; gap: 10px; }
.nav a {
  color: #e6f3fb;
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.2s;
}
.nav a.active,
.nav a:hover { background: rgba(255, 255, 255, 0.08); }

/* Hero */
.hero {
  background-image: var(--hero);
  background-size: cover;
  background-position: center;
  padding: 80px 0;
  color: white;
}
.hero .container { max-width: var(--maxw); }
.hero h1 { margin: 0 0 8px; }
.hero p { max-width: 720px; margin: 0 0 14px; }
.hero .btn { margin-right: 10px; }

/* Page & Cards */
.page {
  background: var(--card);
  margin: 20px auto;
  padding: 22px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}
.page-header { margin-bottom: 12px; }
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-3 { grid-template-columns: 1fr; } }
.card {
  background: linear-gradient(180deg, #fff, #fbfdff);
  border: 1px solid #e6eef5;
  padding: 14px;
  border-radius: 12px;
  box-shadow: 0 10px 24px rgba(14, 20, 24, 0.04);
}
.card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 10px;
}

/* Buttons */
.btn {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  border: 0;
  padding: 10px 14px;
  border-radius: 10px;
  text-decoration: none;
  cursor: pointer;
}
.btn:hover { filter: brightness(0.95); }
.btn.ghost {
  background: transparent;
  border: 1px solid rgba(11, 102, 178, 0.22);
  color: var(--brand);
}
.btn.small { padding: 8px 12px; }

/* Forms */
input, select, textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #d8e2ea;
  border-radius: 8px;
  background: #fff;
}
label { display: block; margin: 10px 0 4px; }
.actions { display: flex; gap: 10px; align-items: center; margin: 10px 0; }
.muted { color: var(--muted); }

/* Quiz Grid Layout */
.quiz-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 20px;
}
.quiz-card {
  background: #f9f9f9;
  padding: 20px;
  border-radius: 12px;
  text-align: center;
  text-decoration: none;
  color: #333;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
}
.quiz-card:hover {
  transform: translateY(-5px);
  background: #eef5ff;
}

/* Quiz Container */
.quiz-container {
  max-width: 700px;
  margin: 0 auto;
  background: #ffffff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
  font-family: Arial, sans-serif;
}

/* Question Styling */
.quiz-question { margin-bottom: 20px; }
.quiz-question h3 { font-size: 18px; margin-bottom: 10px; }

/* Answer Options */
.quiz-question label {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 8px;
  padding: 6px 8px;
  background: #f9f9f9;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.2s;
  text-align: left;
  width: 100%;
  line-height: 1.4;
  word-break: break-word;
}
.quiz-question label:hover { background: #ececec; }
.quiz-question input[type="radio"] {
  margin-top: 3px;
  transform: scale(1.2);
}

/* Submit Button */
.quiz-submit {
  display: block;
  width: 100%;
  padding: 10px;
  background: #2196f3;
  color: white;
  font-size: 16px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.2s;
}
.quiz-submit:hover { background: #0b7dda; }
.quiz-result {
  margin-top: 20px;
  padding: 10px;
  background: #e8f5e9;
  border-left: 5px solid #4caf50;
  border-radius: 5px;
}

/* ===== Footer ===== */
.site-footer {
  background: #032b44;
  color: #e6f3fb;
  margin-top: 20px;
  border-top: 4px solid rgba(255, 255, 255, 0.06);
}
.site-footer .container {
  padding: 14px 0;
  text-align: center;
}

/* ===== Social Links (Updated for Visibility) ===== */
.social-icons {
  display: flex;
  gap: 15px;
  margin-top: 10px;
  justify-content: center;
}

/* Default color visible on light backgrounds */
.social-link {
  font-size: 24px;
  color: #333;
  transition: color 0.3s ease;
}

/* Hover colors for each platform */
.social-link:nth-child(1):hover { color: #0077b5; } /* LinkedIn */
.social-link:nth-child(2):hover { color: #1877f2; } /* Facebook */
.social-link:nth-child(3):hover { color: #e4405f; } /* Instagram */
.social-link:nth-child(4):hover { color: #ff0000; } /* YouTube */
.social-link:nth-child(5):hover { color: #25D366; } /* WhatsApp */

/* Light icons inside dark footer */
.site-footer .social-link {
  color: #e6f3fb;
}
.site-footer .social-link:hover {
  color: var(--brand-2);
}

/* Grid for Video */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.video-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  padding: 0.5rem;
  text-align: center;
}
.video-card iframe {
  width: 100%;
  height: 200px;
  border: none;
  border-radius: 8px;
}
.video-card p {
  margin-top: 0.5rem;
  font-size: 0.95rem;
  color: #333;
}

/* ===== Responsive Navigation (Final Integrated) ===== */
@media (max-width: 880px) {
  .menu-toggle { display: block; }
  .nav {
    display: none;
    position: absolute;
    right: 4%;
    top: 64px;
    background: #033a56;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 10px;
    flex-direction: column;
    min-width: 200px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  }
  .nav.show { display: flex; }
  .nav a { padding: 10px; text-align: center; }
  .hero { padding: 54px 0; }
  .page { padding: 16px; }
}
