/* ===========================
   GLOBAL STYLES
   =========================== */

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

:root {
  --primary-blue: #0066cc;
  --secondary-blue: #003399;
  --accent-orange: #ff9900;
  --accent-red: #cc0000;
  --accent-green: #00aa00;
  --text-dark: #333333;
  --text-light: #666666;
  --bg-light: #f5f5f5;
  --border-color: #dddddd;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.15);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  background-color: #ffffff;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

/* ===========================
   TOP BAR
   =========================== */

.top-bar {
  background: linear-gradient(
    135deg,
    var(--primary-blue) 0%,
    var(--secondary-blue) 100%
  );
  color: white;
  padding: 10px 0;
  font-size: 13px;
  box-shadow: var(--shadow);
}

.top-bar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
}

.top-bar-left {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.top-bar-left span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.top-bar-right {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-small {
  padding: 6px 12px;
  border: none;
  border-radius: 4px;
  font-size: 11px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  color: white;
  text-decoration: none;
  display: inline-block;
}

.btn-calendar {
  background-color: #cc0000;
}

.btn-calendar:hover {
  background-color: #990000;
}

.btn-prospectus {
  background-color: var(--accent-orange);
}

.btn-prospectus:hover {
  background-color: #ff8800;
}

.btn-admission {
  background-color: var(--accent-green);
}

.btn-admission:hover {
  background-color: #009900;
}

/* ===========================
   HEADER
   =========================== */

header {
  background-color: white;
  box-shadow: var(--shadow);
  position: static;
  z-index: 100;
}

.header-top {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 0 15px 0;
  border-bottom: 1px solid #f0f0f0;
}

.header-nav {
  display: flex;
  justify-content: center;
  align-items: stretch;
  padding: 0;
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  background: linear-gradient(135deg, #d7bd5f 0%, #21b52c 100%);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  gap: 20px;
}

.logo-section {
  display: flex;
  align-items: center;
  gap: 15px;
  text-decoration: none;
  color: var(--text-dark);
}

.logo {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, var(--primary-blue) 0%, #6600cc 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
  font-size: 28px;
  box-shadow: var(--shadow);
}

.college-title h1 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.2;
  margin: 0;
}

.college-title p {
  font-size: 13px;
  color: var(--text-light);
  margin: 0;
}

/* ===========================
   NAVIGATION
   =========================== */

nav {
  display: flex;
  gap: 0;
  flex-wrap: wrap;
  align-items: stretch;
  flex: 1;
}

#navMenu {
  display: flex;
  gap: 0;
  align-items: stretch;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  padding: 15px 14px !important;
  text-decoration: none;
  color: white !important;
  font-size: 13px;
  font-weight: 600;
  border: none !important;
  border-radius: 0 !important;
  transition: all 0.2s ease;
  white-space: nowrap;
  position: relative;
}

.nav-link:hover {
  background-color: rgba(0, 0, 0, 0.3);
  color: var(--primary-blue) !important;
}

.nav-link.active {
  background-color: rgba(255, 153, 0, 0.9);
  color: white !important;
  border-bottom: 3px solid var(--accent-orange) !important;
}

nav a.nav-link {
  border: none;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: white;
  padding: 15px 14px;
}

/* ===========================
   DROPDOWN MENUS
   =========================== */

.dropdown {
  position: relative;
  display: inline-flex;
  align-items: stretch;
}

.dropdown > a {
  cursor: pointer;
  padding: 15px 14px;
  display: inline-flex;
  align-items: center;
}

/* Desktop dropdown arrow */
.dropdown > a.nav-link::after {
  content: " ▼";
  margin-left: 5px;
  font-size: 10px;
  transition: transform 0.3s ease;
}

.dropdown:hover > a.nav-link::after {
  transform: rotate(180deg);
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: white;
  min-width: 200px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
  border-radius: 0 0 4px 4px;
  z-index: 1000;
  border: 1px solid #e0e0e0;
  border-top: 3px solid var(--primary-blue);
}

.dropdown:hover > a:not(:hover) {
  background-color: #004cb2;
  color: var(--primary-blue);
}

.dropdown > a:hover {
  background-color: #f0f5ff;
  color: var(--primary-blue);
}

.dropdown:hover .dropdown-menu {
  display: flex;
  flex-direction: column;
  animation: slideDown 0.2s ease;
}

.dropdown-menu a {
  color: var(--text-dark);
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  font-size: 13px;
  font-weight: 500;
  border: none;
  border-radius: 0;
  transition: all 0.15s ease;
  white-space: normal;
}

.dropdown-menu a:hover {
  background-color: #f0f5ff;
  color: var(--primary-blue);
  padding-left: 20px;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===========================
   HERO SLIDER
   =========================== */

.hero-slider {
  position: relative;
  height: 500px;
  background: transparent;
  overflow: hidden;
  margin-bottom: 40px;
  padding: 0; /* Remove default section padding to eliminate gap below navbar */
}

.slider-container {
  position: relative;
  width: 100%;
  height: 100%;
}

.slide {
  display: none;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  animation: fadeIn 0.5s;
}

.slide.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.slide-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: flex-end; /* move text to bottom */
  flex-direction: column;
  color: white;
  text-align: center;
  text-shadow: 2px 3px 8px rgba(0, 0, 0, 0.6); /* stronger shadow for readability */
  padding-bottom: 28px; /* breathing space from bottom */
}

.slide-overlay h2 {
  font-size: 36px;
  margin-bottom: 10px;
  font-weight: 700;
}

.slide-overlay p {
  font-size: 18px;
  margin-bottom: 20px;
}

.slider-controls {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
}

.dot.active {
  background-color: white;
  transform: scale(1.3);
}

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: rgba(255, 255, 255, 0.7);
  border: none;
  color: var(--text-dark);
  font-size: 24px;
  padding: 10px 15px;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
  z-index: 10;
}

.slider-btn:hover {
  background-color: white;
}

.slider-btn.prev {
  left: 20px;
}

.slider-btn.next {
  right: 20px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* ===========================
   SECTIONS
   =========================== */

section {
  padding: 40px 0;
}

section.light-bg {
  background-color: var(--bg-light);
}

section.light-bg-home {
  background-color: var(--bg-light);
  color: var(--text-dark);
}

section.light-bg-home h2 {
  color: var(--text-dark);
}

section.light-bg-home h3 {
  color: var(--text-dark);
}

section.light-bg-home p {
  color: var(--text-light) !important;
}

section.light-bg-page {
  background-color: #004ab0;
  color: white;
}

section.light-bg-page h2 {
  color: white;
}

section.light-bg-page h3 {
  color: white;
}

section.light-bg-page p {
  color: white !important;
}

section.light-bg-page a {
  color: #ffffff;
}

section.hero-section {
  background-color: var(--bg-light);
  color: var(--text-dark);
}

section.hero-section h2 {
  color: var(--text-dark);
}

section.hero-section h3 {
  color: var(--text-dark);
}

section.hero-section p {
  color: var(--text-light) !important;
}

section h2 {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 30px;
  text-align: center;
  position: relative;
  padding-bottom: 15px;
}

section h2::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-blue), var(--accent-orange));
  border-radius: 2px;
}

section h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--primary-blue);
  margin-bottom: 15px;
}

section p {
  color: var(--text-light);
  margin-bottom: 15px;
  line-height: 1.8;
}

/* ===========================
   CARDS & GRID
   =========================== */

.grid {
  display: grid;
  gap: 25px;
  margin-bottom: 30px;
}

.grid.cols-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid.cols-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid.cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

.card {
  background: white;
  border-radius: 8px;
  padding: 25px;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  border-left: 4px solid var(--primary-blue);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
}

.card h4 {
  font-size: 18px;
  font-weight: 600;
  color: var(--primary-blue);
  margin-bottom: 10px;
}

.card p {
  font-size: 14px;
  color: var(--text-light);
}

/* ===========================
   TABLES
   =========================== */

.table-responsive {
  overflow-x: auto;
  margin-bottom: 30px;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  box-shadow: var(--shadow);
  border-radius: 8px;
  overflow: hidden;
}

thead {
  background: linear-gradient(
    135deg,
    var(--primary-blue) 0%,
    var(--secondary-blue) 100%
  );
  color: white;
}

th {
  padding: 15px;
  text-align: left;
  font-weight: 600;
  font-size: 14px;
}

td {
  padding: 12px 15px;
  border-bottom: 1px solid var(--border-color);
  font-size: 14px;
}

tbody tr:hover {
  background-color: #f9f9f9;
}

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

/* ===========================
   BUTTONS
   =========================== */

.btn {
  padding: 12px 24px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn-primary {
  background-color: var(--primary-blue);
  color: white;
}

.btn-primary:hover {
  background-color: var(--secondary-blue);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background-color: var(--accent-orange);
  color: white;
}

.btn-secondary:hover {
  background-color: #ff8800;
}

/* ===========================
   FOOTER
   =========================== */

footer {
  background: linear-gradient(135deg, var(--text-dark) 0%, #1a1a1a 100%);
  color: white;
  padding: 40px 0 20px;
  margin-top: 40px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-bottom: 30px;
}

.footer-section h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 15px;
  color: var(--accent-orange);
}

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

.footer-section ul li {
  margin-bottom: 10px;
}

.footer-section ul li a {
  color: #cccccc;
  text-decoration: none;
  transition: all 0.3s ease;
}

.footer-section ul li a:hover {
  color: var(--accent-orange);
  padding-left: 5px;
}

.footer-section p {
  color: #cccccc;
  font-size: 14px;
  line-height: 1.8;
}

.footer-bottom {
  border-top: 1px solid #444444;
  padding-top: 20px;
  text-align: center;
  color: #999999;
  font-size: 13px;
}

/* ===========================
   MOBILE RESPONSIVE (REWRITTEN)
   =========================== */

@media (max-width: 768px) {
  /* Top bar mobile */
  .top-bar-content {
    flex-direction: column;
    gap: 10px;
  }

  .top-bar-left {
    flex-direction: column;
    gap: 10px;
  }

  .top-bar-right {
    width: 100%;
    justify-content: center;
  }

  /* Header mobile */
  .header-content {
    flex-direction: column;
    gap: 10px;
  }

  .college-title h1 {
    font-size: 20px !important;
  }

  .college-title p {
    font-size: 15px !important;
  }

  /* Mobile navigation container */
  .header-nav {
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    background: linear-gradient(135deg, #d7bd5f 0%, #21b52c 100%);
    padding: 10px 15px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }

  /* Menu toggle button */
  .menu-toggle {
    display: block;
    background: transparent;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    margin-bottom: 10px;
  }

  .menu-toggle:hover {
    background: transparent;
  }

  /* Main navigation menu */
  #navMenu {
    display: none;
    flex-direction: column;
    width: 100%;
    background: transparent;
  }

  #navMenu.active {
    display: flex;
  }

  /* Navigation links */
  #navMenu > a.nav-link,
  #navMenu > .dropdown > a.nav-link {
    color: white;
    padding: 12px 0;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 14px;
    font-weight: 500;
    width: 100%;
    display: block;
  }

  #navMenu > a.nav-link:hover,
  #navMenu > .dropdown > a.nav-link:hover {
    background: rgba(0, 0, 0, 0.1);
    padding-left: 10px;
  }

  /* Dropdown container */
  .dropdown {
    width: 100%;
  }

  /* Dropdown menu */
  .dropdown-menu {
    display: none;
    background: #1a4b26;
    width: 100%;
    flex-direction: column;
    padding-left: 15px;
    border-left: 2px solid rgba(255, 255, 255, 0.3);
    margin-top: 5px;
  }

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

  /* Dropdown links */
  .dropdown-menu a {
    color: rgba(255, 255, 255, 0.9);
    padding: 8px 0;
    text-decoration: none;
    font-size: 13px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .dropdown-menu a:hover {
    color: white;
    padding-left: 10px;
  }

  /* Dropdown indicator */
  .dropdown > a.nav-link::after {
    content: " ▼";
    float: right;
    font-size: 10px;
    transition: transform 0.3s ease;
  }

  .dropdown.active > a.nav-link::after {
    transform: rotate(180deg);
  }

  /* Other mobile styles */
  .hero-slider {
    height: 500px;
  }

  .slide-overlay h2 {
    font-size: 24px;
  }

  .slide-overlay p {
    font-size: 14px;
  }

  section h2 {
    font-size: 22px;
  }

  section h3 {
    font-size: 18px;
  }

  .grid.cols-2,
  .grid.cols-3 {
    grid-template-columns: 1fr;
  }

  table {
    font-size: 12px;
  }

  th,
  td {
    padding: 10px;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .cols-4 {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .menu-toggle {
    background: transparent !important;
    border: none !important;
    width: auto !important;
    height: auto !important;
    font-size: 14px !important;
    color: white !important;
    border-radius: 0 !important;
    margin: 8px 0 !important;
    padding: 10px 20px !important;
    cursor: pointer !important;
    z-index: 1001 !important;
  }

  .hero-slider {
    height: 580px;
  }

  .slide-overlay h2 {
    font-size: 24px;
  }

  .slide-overlay p {
    font-size: 14px;
  }

  section h2 {
    font-size: 22px;
  }

  section h3 {
    font-size: 18px;
  }

  .grid.cols-2,
  .grid.cols-3 {
    grid-template-columns: 1fr;
  }

  table {
    font-size: 12px;
  }

  th,
  td {
    padding: 10px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 10px;
  }

  .logo {
    width: 50px;
    height: 50px;
    font-size: 20px;
  }

  .college-title h1 {
    font-size: 14px;
  }

  .college-title p {
    font-size: 10px;
  }

  .hero-slider {
    height: 500px;
    margin-bottom: 20px;
  }

  .slide-overlay h2 {
    font-size: 18px;
  }

  .slide-overlay p {
    font-size: 12px;
  }

  section {
    padding: 25px 0;
  }

  section h2 {
    font-size: 18px;
    margin-bottom: 20px;
  }

  .card {
    padding: 15px;
  }

  .btn-small {
    padding: 5px 10px;
    font-size: 10px;
  }
}

/* ===========================
   UTILITY CLASSES
   =========================== */

.text-center {
  text-align: center;
}

.mt-20 {
  margin-top: 20px;
}

.mb-20 {
  margin-bottom: 20px;
}

.mt-40 {
  margin-top: 40px;
}

.mb-40 {
  margin-bottom: 40px;
}

.hidden {
  display: none;
}

.visible {
  display: block;
}

/* ===========================
   NEWS & LEADERSHIP STYLES
   =========================== */

.news-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.news-item {
  background: white;
  border-left: 4px solid var(--primary-blue);
  padding: 20px;
  border-radius: 5px;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.news-date {
  display: inline-block;
  background: var(--primary-blue);
  color: white;
  padding: 5px 10px;
  border-radius: 3px;
  font-size: 12px;
  font-weight: bold;
  margin-bottom: 10px;
}

.news-item h4 {
  color: var(--text-dark);
  margin-bottom: 10px;
  font-size: 16px;
}

.news-item p {
  color: var(--text-light);
  font-size: 14px;
  line-height: 1.6;
}

.leadership-card {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-align: center;
}

.leadership-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
}

.leadership-image {
  width: 100%;
  height: 250px;
  overflow: hidden;
  background: linear-gradient(
    135deg,
    var(--primary-blue) 0%,
    var(--secondary-blue) 100%
  );
}

.leadership-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.leadership-card h4 {
  color: var(--text-dark);
  font-size: 16px;
  margin: 15px 15px 10px 15px;
}

.leadership-card p {
  color: var(--text-light);
  font-size: 13px;
  margin: 0 15px 15px 15px;
  line-height: 1.5;
}

@media (max-width: 768px) {
  .news-container {
    grid-template-columns: 1fr;
  }

  .cols-4 {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 480px) {
  .cols-4 {
    grid-template-columns: 1fr !important;
  }

  .leadership-image {
    height: 200px;
  }
}

/* ===========================
   GALLERY STYLES
   =========================== */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  aspect-ratio: 4/3;
}

.gallery-item:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-lg);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}
