/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600&display=swap');

body {
  font-family: 'Poppins', sans-serif;
  margin: 0;
  background-color: #f0f2f5;
  color: #333;
}

/* Navbar */
nav {
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.container {
  max-width: 900px;
  margin: 40px auto;
  padding: 0 20px;
}

/* --- Generator Card Design --- */
.generator-card {
  background: white;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
  border-top: 5px solid #0056b3;
  margin-bottom: 30px;
}

.generator-card h1 {
  text-align: center;
  color: #0056b3;
  margin-bottom: 25px;
  font-size: 28px;
}

/* Form Layout */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 25px;
}

.input-group {
  display: flex;
  flex-direction: column;
}

.input-group label {
  font-weight: 600;
  margin-bottom: 8px;
  color: #555;
  font-size: 14px;
}

.input-group input {
  padding: 12px;
  border: 2px solid #e1e4e8;
  border-radius: 8px;
  font-size: 15px;
  outline: none;
  transition: 0.3s;
}

.input-group input:focus {
  border-color: #0056b3;
  box-shadow: 0 0 8px rgba(0, 86, 179, 0.1);
}

/* Button Group */
.button-group {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

button {
  padding: 12px 30px;
  border: none;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  color: white;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

/* Button Colors */
.btn-generate { background: linear-gradient(135deg, #007bff, #0056b3); }
.btn-print { background: linear-gradient(135deg, #28a745, #218838); }
.btn-pdf { background: linear-gradient(135deg, #dc3545, #b21f2d); }

/* --- OMR Sheet Output Area --- */
#omrSheetContainer {
  background: white;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
  margin-top: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.omr-sheet {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  width: 100%;
  border: 2px solid #333;
  padding: 15px;
  background-color: #fff;
  /* ওয়াটারমার্কের জন্য পজিশন রিলেটিভ এবং ওভারফ্লো হিডেন করা হলো */
  position: relative;
  overflow: hidden;
}

/* ওয়াটারমার্ক ডিজাইন */
.watermark-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-45deg);
  font-size: 70px;
  color: rgba(0, 0, 0, 0.04);
  font-weight: bold;
  text-transform: uppercase;
  white-space: nowrap;
  pointer-events: none;
  z-index: 0;
}

/* Column Styling */
.column {
  border-right: 1px dashed #ccc;
  padding: 2px 5px;
  position: relative;
  z-index: 2; /* বাবলগুলো ওয়াটারমার্কের উপরে রাখার জন্য */
}
.column:last-child { border-right: none; }

.question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 13px;
  position: relative;
  z-index: 2;
}

.question span {
  font-weight: bold;
  width: 20px;
  font-size: 12px;
}

/* --- Bubble Styling (Super Compact) --- */
.bubble {
  display: inline-flex;
  width: 14px;
  height: 14px;
  border: 1px solid #333;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  margin-left: 4px;   
  font-weight: 600;
  cursor: pointer;
  line-height: 1;
}

/* Signature Section */
.signature-section {
  width: 100%;
  margin-top: 30px;
  display: flex;
  justify-content: space-between;
  padding: 0 20px;
  font-weight: bold;
  font-size: 14px;
}

/* SEO Section */
.seo-article {
  background: white;
  padding: 30px;
  margin-top: 40px;
  border-radius: 10px;
  border-left: 5px solid #28a745;
}

.seo-article h2 { color: #28a745; }
.seo-article h3 { color: #333; margin-top: 20px; }

/* Mobile Responsive */
@media (max-width: 768px) {
  .form-grid { grid-template-columns: 1fr; }
  .omr-sheet { grid-template-columns: repeat(2, 1fr); } 
  .signature-section { flex-direction: column; gap: 20px; }
}

/* Printing Rules */
@media print {
  body * { visibility: hidden; }
  #omrSheetContainer, #omrSheetContainer * { visibility: visible; }
  #omrSheetContainer {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    margin: 0;
    padding: 0;
    box-shadow: none;
  }
  .omr-sheet { border: 2px solid black; }
}