html { scroll-behavior: smooth; }
/* ===================== BLOG POST ===================== */
.post-container {
  max-width: 800px;
  margin: 30px auto;
  padding: 2rem;
  background: #fff;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);

}

.blog-post h1.post-title {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.post-meta {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.post-image {
  width: 100%;
  height: auto;
  max-width: 100%;
  border-radius: 8px;
  margin: 1rem 0;
  object-fit: contain; /* ensures full image visible */
}

.post-content h2 {
  margin-top: 1.5rem;
  color: #003366;
}

.post-content p {
  margin-bottom: 1rem;
  line-height: 1.7;
}


.toc { background: #f7f7f7; padding: 15px; margin-bottom: 20px; border-left: 4px solid darkblue; }
.toc h2 { margin-top: 0; }
.toc a { display: block; color: #333; text-decoration: none; padding: 5px 0; }
.toc a:hover { color: darkblue; }
.toc li {list-style-type: none;}
.post-content h2, .post-content h3 { border-left: 4px solid #0077cc; padding-left: 12px; margin-top: 25px;}
h2, h3 {
  scroll-margin-top: 80px;
}

ul, ol 
{
  margin-left: 20px;
}
 .mcq-item {
      background: #f7f7f7;
      border-left: 4px solid #0077cc; /* same as h2 border color */
      padding: 15px;
      margin: 10px 0;
    }

    .mcq-question {
      font-weight: bold;
      margin-bottom: 5px;
    }

    .mcq-options {
      margin-left: 20px;
      margin-bottom: 10px;
    }

    .mcq-answer {
      background: #dbeafe; /* soft blue similar to h2 highlight */
      border-left: 4px solid #0077cc;
      padding: 10px;
      margin-left: 20px;
      font-weight: bold;
    }
    .post-content p
    {
      margin: 0;
    }


  .test-mcqs {
  max-width: 700px;
  margin: auto;
}
.test-mcqs .mcq-item {
  background: #f7f7f7;
  border-left: 4px solid #0077cc;
  padding: 15px;
  margin: 10px 0;
}
.mcq-question {
  font-weight: bold;
  margin-bottom: 10px;
}
.mcq-options button {
  display: block;
  text-align: left;
  margin: 5px 0;
  padding: 8px;
  width: 100%;
  border-radius: 4px;
  border: 1px solid #ccc;
  cursor: pointer;
  transition: 0.2s;
  position: relative;
  font-size: 16px;
}
.mcq-options button.correct {
  background-color: #d4edda; 
  border-color: #28a745;
  color: #155724;
}
.mcq-options button.wrong {
  background-color: #f8d7da; 
  border-color: #dc3545;
  color: #721c24;
}
.mcq-options button.correct::after {
  content: " ✅";
  float: right;
}
.mcq-options button.wrong::after {
  content: " ❌";
  float: right;
}
.mcq-options button:hover {
  background-color: #e2e6ea;
}

.test-mcqs h2 {
  border-left: 5px solid #0077cc;
  padding-left: 10px;
  color: #0077cc;
  margin-bottom: 15px;
}

.user-info {
  text-align: center;
  margin-bottom: 15px;
}

#username {
  padding: 10px;
  width: 60%;
  max-width: 300px;
  border-radius: 5px;
  border: 1px solid #ccc;
}

.result-box {
  text-align: center;
  margin-top: 20px;
}

#showResult {
  padding: 10px 20px;
  background: #0077cc;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

#showResult:hover {
  background: #005fa3;
}

#resultText {
  margin-top: 15px;
  font-size: 18px;
  font-weight: bold;
}

/* Highlight input or MCQ when missing */
.highlight-unanswered {
  border: 2px solid #dc3545 !important;
  background-color: #ffe5e5;
  border-radius: 5px;
  padding: 5px;
  transition: 0.3s;
}    

/* Back to top button styling */
  #backToTop {
    display: none; /* Hidden by default */
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 100;
    font-size: 30px;
    background-color: #002959;
    color: white;
    border: none;
    outline: none;
    cursor: pointer;
    padding: 5px 15px;
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    transition: opacity 0.3s ease;
  }

  #backToTop:hover {
    background-color: #0055a5;
  }

/* =========================================
   FAQ SECTION
========================================= */

.notes-post-faq{

    margin-top:70px;

}

.section-title{

    text-align:center;

    margin-bottom:45px;

}

.section-title span{

    display:inline-block;

    padding:8px 18px;

    background:#dbeafe;

    color:#2563eb;

    border-radius:50px;

    font-size:.85rem;

    font-weight:700;

    text-transform:uppercase;

    letter-spacing:.5px;

    margin-bottom:15px;

}

.section-title h2{

    font-size:2.3rem;

    color:#0f172a;

    margin-bottom:15px;

}

.section-title p{

    max-width:650px;

    margin:auto;

    color:#64748b;

    line-height:1.8;

}

.faq-container{

    max-width:900px;

    margin:auto;

}

.faq-item{

    background:#fff;

    border:1px solid #e2e8f0;

    border-radius:18px;

    margin-bottom:18px;

    overflow:hidden;

    box-shadow:0 10px 30px rgba(15,23,42,.06);

    transition:.35s;

}

.faq-item:hover{

    transform:translateY(-4px);

    box-shadow:0 18px 40px rgba(15,23,42,.10);

}

.faq-question{

    width:100%;

    background:#fff;

    border:none;

    padding:22px 28px;

    text-align:left;

    cursor:pointer;

    font-size:17px;

    font-weight:600;

    color:#0f172a;

    position:relative;

    transition:.3s;

}

.faq-question:hover{

    color:#2563eb;

}

.faq-question::after{

    content:"+";

    position:absolute;

    right:28px;

    top:50%;

    transform:translateY(-50%);

    width:34px;

    height:34px;

    display:flex;

    align-items:center;

    justify-content:center;

    border-radius:50%;

    background:#eff6ff;

    color:#2563eb;

    font-size:22px;

    font-weight:700;

    transition:.3s;

}

.faq-question.active{

    color:#2563eb;

}

.faq-question.active::after{

    content:"−";

    background:#2563eb;

    color:#fff;

}

.faq-answer{

    max-height:0;

    overflow:hidden;

    transition:max-height .35s ease;

}

.faq-answer p{

    padding:0 28px 24px;

    color:#64748b;

    line-height:1.9;

}

/* ====================== ADDING COMMENTS =============== */

  
  .wrap { max-width: 660px; margin: auto; }

  /* PUBLIC INPUT */
  .input-card {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 18px;
    display: flex; flex-direction: column; gap: 10px;
    margin-bottom: 28px; box-shadow: var(--shadow);
  }
  .input-card input, .input-card textarea {
    padding: 10px 14px; border: 1px solid var(--border); border-radius: 8px;
    font-family: 'DM Sans', sans-serif; font-size: 14px;
    color: var(--text); background: var(--bg); resize: vertical; transition: border-color 0.2s;
  }
  .input-card input:focus, .input-card textarea:focus { outline: none; border-color: var(--accent); }
  .input-card textarea { min-height: 80px; }

  button {
    width: fit-content; padding: 9px 20px;
    /* background: var(--accent); color: white; border: none; */
    border-radius: 6px; font-family: 'DM Sans', sans-serif;
    /* font-size: 13px; font-weight: 600; cursor: pointer; */
    transition: background 0.2s, transform 0.1s;
  }
  button:hover { background: var(--accent-hover); 
  cursor: pointer;}
  button:active { transform: scale(0.97); 
  }

  /* COMMENT CARD */
  .comment-card {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 16px;
    margin-bottom: 14px; box-shadow: var(--shadow);
    animation: fadeIn 0.2s ease;
  }
  @keyframes fadeIn { from { opacity:0; transform:translateY(5px); } to { opacity:1; transform:translateY(0); } }

  .comment-row { display: flex; gap: 12px; align-items: flex-start; }

  .avatar {
    width: 36px; height: 36px; min-width: 36px; border-radius: 50%;
    background: #2c2825; color: white;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 14px;
  }
  .avatar.admin-av { background: var(--accent); }

  .comment-body { flex: 1; min-width: 0; }
  .comment-header { font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
  .comment-time { font-size: 11px; color: var(--muted); font-weight: 400; }
  .badge {
    font-size: 10px; font-weight: 700; letter-spacing: 0.5px;
    background: var(--accent); color: white; padding: 1px 6px; border-radius: 20px;
  }
  .comment-text { font-size: 14px; margin-top: 4px; line-height: 1.55; }

  /* ADMIN reply trigger */
  .admin-reply-btn {
    font-size: 11px; color: var(--muted); margin-top: 6px;
    cursor: pointer; display: none; font-weight: 500; width: fit-content;
  }
  .admin-reply-btn:hover { color: var(--accent); }
  .admin-mode .admin-reply-btn { display: inline-block; }

  /* THREAD */
  .thread {
    margin-top: 12px;
    display: flex; flex-direction: column; gap: 10px;
    border-left: 3px solid var(--border); padding-left: 14px;
  }

  /* Admin reply bubble */
  .reply-bubble {
    display: flex; gap: 10px; align-items: flex-start;
    background: var(--admin-bg); border: 1px solid var(--admin-border);
    border-radius: 8px; padding: 10px 12px;
  }
  .reply-bubble .avatar { width: 28px; height: 28px; min-width: 28px; font-size: 11px; }
  .reply-bubble .comment-body {}

  /* Visitor reply-back bubble */
  .visitor-reply-bubble {
    display: flex; gap: 10px; align-items: flex-start;
    background: var(--visitor-bg); border: 1px solid var(--visitor-border);
    border-radius: 8px; padding: 10px 12px;
  }
  .visitor-reply-bubble .avatar { width: 28px; height: 28px; min-width: 28px; font-size: 11px; background: #3a5a8c; }

  /* Visitor reply-back input box — shown after admin replies */
  .visitor-reply-box {
    display: none; flex-direction: column; gap: 8px;
    background: #f9f8f6; border: 1px solid var(--border);
    border-radius: 8px; padding: 12px; margin-top: 4px;
  }
  .visitor-reply-box textarea {
    padding: 8px 12px; border: 1px solid var(--border); border-radius: 6px;
    font-family: 'DM Sans', sans-serif; font-size: 13px;
    background: var(--surface); color: var(--text);
    resize: none; min-height: 56px; transition: border-color 0.2s;
  }
  .visitor-reply-box textarea:focus { outline: none; border-color: var(--accent); }
  .visitor-reply-box button { font-size: 12px; padding: 7px 14px; }

  /* Admin reply input box */
  .admin-reply-box {
    display: none; flex-direction: column; gap: 8px;
    background: #f9f8f6; border: 1px solid var(--border);
    border-radius: 8px; padding: 12px; margin-top: 6px;
  }
  .admin-reply-box textarea {
    padding: 8px 12px; border: 1px solid var(--border); border-radius: 6px;
    font-family: 'DM Sans', sans-serif; font-size: 13px;
    background: var(--surface); color: var(--text);
    resize: none; min-height: 60px; transition: border-color 0.2s;
  }
  .admin-reply-box textarea:focus { outline: none; border-color: var(--accent); }
  .admin-reply-box button { font-size: 12px; padding: 7px 14px; }

  /* ADMIN BAR */
  #admin-bar {
    position: relative; bottom: 20px; right: 20px;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 12px 16px;
    box-shadow: var(--shadow); display: flex; gap: 8px; align-items: center;
  }
  #admin-bar input {
    padding: 7px 12px; border: 1px solid var(--border); border-radius: 6px;
    font-family: 'DM Sans', sans-serif; font-size: 13px; background: var(--bg); width: 160px;
  }
  #admin-bar input:focus { outline: none; border-color: var(--accent); }
  #admin-bar button { padding: 7px 14px; font-size: 12px; }

  .empty { text-align: center; color: var(--muted); font-size: 13px; padding: 30px 0; }

