* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

body {
  background-color: white;
  display: flex;
  flex-direction: column;
  font-size: 18px;
}

label {
  display: block;
  font-weight: bold;
  margin: 5px 0;
}

textarea,
input {
  resize: none;
  font-family: inherit;
  font-size: inherit;
  overflow: hidden;
  min-height: 1.2em;
  line-height: 1.2;
  border: none;
  outline: none;
  margin-left: 10px;
}

input:hover,
textarea:hover {
  cursor: pointer;
}
input:focus,
textarea:focus {
  border-bottom: 2px solid #000;
}

header {
  background: linear-gradient(135deg, #2c3e50, #34495e);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 30px;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

.logo-title {
  display: flex;
  align-items: center;
  gap: 15px;
}

.logo {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.logo:hover {
  transform: scale(1.1);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

.title-text h1 {
  font-size: clamp(16px, 4vw, 22px);
  font-weight: 700;
  margin: 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  letter-spacing: 0.5px;
}

.title-text p {
  font-size: clamp(11px, 2.5vw, 14px);
  margin: 2px 0 0 0;
  opacity: 0.9;
  font-weight: 400;
}

.nav-container {
  position: relative;
}

.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 4px;
  transition: background-color 0.3s ease;
  width: 40px;
  height: 40px;
}

.mobile-menu-toggle:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.hamburger-line {
  width: 24px;
  height: 2px;
  background-color: white;
  margin: 3px 0;
  transition: all 0.3s ease;
  transform-origin: center;
  display: block;
}

.mobile-menu-toggle.active .hamburger-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(2) {
  opacity: 0;
  transform: scale(0);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 25px;
}

.nav-menu a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  font-size: clamp(14px, 2.5vw, 16px);
  padding: 8px 16px;
  border-radius: 25px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.nav-menu a::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.5s;
}

.nav-menu a:hover::before {
  left: 100%;
}

.nav-menu a:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.nav-menu a:active {
  transform: translateY(0);
}

/* Mobile responsive header */
@media screen and (max-width: 768px) {
  header {
    padding: 15px 20px;
    position: relative;
  }

  .logo-title {
    justify-content: flex-start;
    text-align: left;
    flex: 1;
    padding-right: 60px; /* Make space for hamburger button */
  }

  .logo {
    width: 50px;
    height: 50px;
  }

  .mobile-menu-toggle {
    display: flex;
    position: absolute;
    top: -10px;
    right: 5px;
    transform: translateY(-50%);
  }

  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: linear-gradient(135deg, #34495e, #2c3e50);
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    flex-direction: column;
    gap: 8px;
    min-width: 150px;
    z-index: 1000;
    margin-top: 10px;
  }

  .nav-menu.active {
    display: flex;
  }

  .nav-menu a {
    padding: 8px 12px;
    text-align: center;
    white-space: nowrap;
  }
}

main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.report-container {
  height: 297mm;
  width: 210mm;
  min-width: 210mm;
  min-height: 297mm;
  padding: 10mm;
  background: white;
  margin: 20px;
  border: 1px solid #000;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.report-container img.logo-center {
  width: 150px;
}

.report-container h2 {
  font-weight: bold;
  margin-bottom: 10px;
}

.report-container p {
  margin-top: 5px;
  margin-bottom: 15px;
}

.watermark {
  background-image: url("../images/logo.png");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.1;
  width: 60%;
  height: 60%;
  z-index: 1;
  pointer-events: none;
}

.department {
  margin: 30px auto;
  font-size: 20px;
  text-align: center;
  display: flex;
  justify-content: center;
}

.department-input {
  border: none;
  font-weight: bold;
  outline: none;
  font-size: 20px;
  text-align: center;
  width: 100%;
}

.department-input:focus {
  border-bottom: 2px solid #000;
}

.content-section {
  margin-top: -125px;
}

.input-box {
  margin: 30px 0;
  width: 100%;
  font-size: 20px;
}

.input-box textarea {
  width: 100%;
  padding: 10px;
  text-align: center;
  margin: 0;
}

.course-child {
  display: flex;
  justify-content: center;
  margin: 10px 0;
}

.course-child input,
textarea {
  width: 50%;
}

.submission {
  display: flex;
  justify-content: center;
  text-align: left;
  flex-wrap: wrap;
}

.submission-box {
  width: 48%;
  border: 1px solid #000;
  padding: 20px;
  min-height: 120px;
  flex: 1;
  min-width: 280px;
}

.submission-box div {
  display: flex;
  align-items: center;
  margin: 8px 0;
}

.submission-box label {
  display: inline-block;
  width: 25%;
  font-weight: bold;
  text-align: left;
  margin: 0;
}

.submission-box strong {
  display: inline-block;
  margin-bottom: 1rem;
}

.submission-input {
  width: 100%;
  border: none;
  padding: 2px 5px 0 5px;
  outline: none;
  margin: 0;
  resize: none;
  font-family: inherit;
  font-size: inherit;
  overflow: hidden;
  min-height: 1.2em;
  line-height: 1.2;
}

.submission-input:focus {
  border-bottom: 2px solid #000;
}

#roll-no {
  width: 80%;
}

.level-term {
  display: flex;
}

.level-term div {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.level-term label {
  width: 30%;
  margin: 0;
}

.level-term textarea {
  width: fit-content;
  margin: 0;
  margin-left: 5px;
  padding: 2px 5px 0 5px;
}

.date-section {
  margin-top: 30px;
}

.date-section label {
  display: inline-block;
  font-weight: bold;
}

.button-container {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin: 20px auto;
}

.download-btn,
.print-btn {
  background: linear-gradient(45deg, #007bff, #0056b3);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 25px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s, box-shadow 0.2s;
  z-index: 1000;
}

.download-btn:hover,
.print-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

.download-btn:active,
.print-btn:active {
  transform: translateY(0);
}

.download-btn {
  background: linear-gradient(45deg, #28a745, #20c997);
}

footer {
  background: linear-gradient(135deg, #2c3e50, #34495e);
  color: white;
  text-align: center;
  padding: 10px 20px;
  margin-top: auto;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  width: 100vw;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: clamp(16px, 3vw, 18px);
  font-weight: bold;
}

footer-logo span {
  font-size: clamp(20px, 4vw, 25px);
}

.footer-content p {
  font-size: clamp(14px, 2.5vw, 16px);
  gap: 0;
  margin-top: -10px;
}

.footer-logo img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
}

.footer-links {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-links a {
  color: #ecf0f1;
  text-decoration: none;
  font-weight: 500;
  font-size: clamp(12px, 2vw, 14px);
  transition: color 0.3s ease, transform 0.3s ease;
  position: relative;
}

.footer-links a:hover {
  color: #3498db;
  transform: translateY(-2px);
}

.footer-links a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -5px;
  left: 50%;
  background: #3498db;
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.footer-links a:hover::after {
  width: 100%;
}

.footer-bottom {
  font-size: clamp(11px, 2vw, 14px);
  color: #bdc3c7;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* Mobile responsive main and report container */
@media screen and (max-width: 768px) {
  main {
    padding: 10px;
    align-items: flex-start;
  }

  .report-container {
    height: auto !important;
    min-height: auto !important;
    width: 100% !important;
    min-width: auto !important;
    margin: 0 !important;
    padding: 15px !important;
  }

  .report-container img.logo-center {
    width: 120px;
  }

  .content-section {
    margin-top: -35px;
  }


  .submission {
    flex-direction: column;
  }

  .submission-box {
    width: 100%;
    min-width: auto;
  }
  #roll-no {
    width: 100%;
  }
  .submission-box label {
    width: 35%;
  }
}

/* Mobile responsive footer */
@media (max-width: 768px) {
  footer {
    padding: 20px 15px 12px 15px;
  }

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

/* Print styles */

@media print {
  @page {
    size: A4;
    margin: 0;
  }

  .report-container {
    border: none;
    page-break-after: always;
    width: 100%;
    margin: 0;
    padding: 10mm;
  }

  .watermark {
    background-image: url("../images/logo.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0.05;
    width: 60%;
    height: 60%;
    z-index: 1;
    pointer-events: none;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  header,
  footer {
    display: none;
  }

  main {
    padding: 0;
  }

  .print-btn,
  .download-btn,
  .button-container {
    display: none;
  }
}
