/* Ensure all company logos have consistent dimensions */
.hero-logo-item.scattered img,
.hero-logo-item.scattered svg,
.logo-item img,
.logo-item svg {
  max-width: 100% !important;
  max-height: 100% !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain !important;
  object-position: center !important;
}

/* Override any inline SVG dimensions to ensure consistent sizing */
.hero-logo-item.scattered svg,
.logo-item svg {
  width: auto !important;
  height: auto !important;
  max-width: 100% !important;
  max-height: 100% !important;
}

/*------------------------------------------------------
ALUMNI PAGE STYLES
------------------------------------------------------*/

.hero-section {
  background: linear-gradient(135deg, #293786 0%, #1e2a5e 100%);
  color: white;
  padding: 100px 0 80px;
  text-align: center;
  position: relative;
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  overflow: hidden;
  min-height: 700px;
}

.hero-logos-container {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 50px;
  color: white;
}

.hero-content h1 {
  color: white;
}

.hero-logo-item.scattered {
  position: absolute;
  width: 70px !important;
  height: 50px !important;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 8px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  transition: all 0.4s ease;
  opacity: 0;
  transform: translateY(30px);
  pointer-events: auto;
  visibility: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  box-sizing: border-box;
  z-index: 10;
}

.hero-logo-item.scattered.animate {
  opacity: 0.8;
  transform: translateY(0);
  visibility: visible;
}

/* Remove all rotation variations for consistent appearance */

.hero-logo-item.scattered:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.hero-logo-item.scattered img {
  max-width: 100% !important;
  max-height: 100% !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain;
  transition: all 0.3s ease;
}

.hero-logo-item.scattered:hover img {
  transform: scale(1.05);
}

.alumni-description {
  max-width: 800px;
  margin: 0 auto 50px;
  font-size: 18px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.stats-container {
  display: flex;
  justify-content: center;
  gap: 80px;
  margin-top: 60px;
}

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

.stat-number {
  font-size: 48px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 10px;
}

.stat-label {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.8);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/*------------------------------------------------------
SENIORS CONGRATULATIONS SECTION
------------------------------------------------------*/

.seniors-congratulations {
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
  padding: 80px 50px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.seniors-congratulations::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #293786 0%, #1e2a5e 50%, #293786 100%);
}

.seniors-container {
  max-width: 900px;
  margin: 0 auto;
}

.seniors-congratulations h2 {
  font-size: 42px;
  color: #293786;
  margin-bottom: 30px;
  font-weight: 700;
  position: relative;
}

.seniors-congratulations h2::after {
  content: '🎓';
  margin-left: 15px;
  font-size: 0.8em;
}

.seniors-message {
  font-size: 18px;
  line-height: 1.8;
  color: #444;
  margin-bottom: 50px;
  font-weight: 500;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 20px;
}

.seniors-photo {
  position: relative;
  display: inline-block;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.seniors-photo:hover {
  transform: translateY(-5px);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.2);
}

.seniors-photo img {
  width: 100%;
  height: auto;
  max-width: 700px;
  display: block;
  border-radius: 20px;
  transition: transform 0.3s ease;
}

.seniors-photo:hover img {
  transform: scale(1.02);
}

.seniors-photo::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(41, 55, 134, 0.1) 0%, rgba(30, 42, 94, 0.1) 100%);
  border-radius: 20px;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 1;
}

.seniors-photo:hover::before {
  opacity: 1;
}

/*------------------------------------------------------
FEATURED ALUMNI
------------------------------------------------------*/

.featured-alumni {
  padding: 80px 50px;
  background: #f8f9fa;
}

.featured-alumni h2 {
  text-align: center;
  margin-bottom: 60px;
  font-size: 36px;
  color: #293786;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.alumni-card {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.alumni-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 50px rgba(0,0,0,0.15);
}

.alumni-card.featured {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
}

.card-image {
  position: relative;
  height: 250px;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.alumni-card:hover .card-image img {
  transform: scale(1.05);
}

.company-logo {
  position: absolute;
  bottom: 15px;
  right: 15px;
  background: rgba(41, 55, 134, 0.9);
  color: white;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  backdrop-filter: blur(10px);
}

.card-content {
  padding: 30px;
}

.card-content h3 {
  margin: 0 0 10px 0;
  font-size: 24px;
  color: #293786;
  text-align: left;
}

.role {
  font-size: 18px;
  color: #666;
  margin: 0 0 10px 0;
  font-weight: 600;
}

.class {
  font-size: 14px;
  color: #888;
  margin: 0 0 25px 0;
  font-style: italic;
}

.card-actions {
  display: flex;
  gap: 15px;
}

.linkedin-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #0077b5;
  color: white;
  padding: 12px 20px;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.3s ease;
  font-size: 14px;
}

.linkedin-btn:hover {
  background: #005885;
  transform: translateY(-2px);
}

/*------------------------------------------------------
ALL ALUMNI SECTION
------------------------------------------------------*/

.all-alumni {
  padding: 80px 50px;
  max-width: 1400px;
  margin: 0 auto;
}

.all-alumni h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 36px;
  color: #293786;
}

.class-tabs {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 60px;
}

.tab-btn {
  background: transparent;
  border: 2px solid #293786;
  color: #293786;
  padding: 12px 30px;
  border-radius: 25px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
}

.tab-btn.active,
.tab-btn:hover {
  background: #293786;
  color: white;
}

.alumni-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 30px;
}

.alumni-card.compact {
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.alumni-card.compact:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.alumni-card.compact .card-image {
  height: 200px;
}

.alumni-card.compact .card-content {
  padding: 20px;
}

.alumni-card.compact h3 {
  font-size: 20px;
  margin-bottom: 8px;
}

.alumni-card.compact .role {
  font-size: 16px;
  margin-bottom: 8px;
}

.alumni-card.compact .class {
  font-size: 13px;
  margin-bottom: 20px;
}

/*------------------------------------------------------
COMPANIES SECTION
------------------------------------------------------*/

.companies-section {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  padding: 80px 50px;
  text-align: center;
  overflow: hidden;
}

.companies-section h2 {
  margin-bottom: 60px;
  font-size: 36px;
  color: #293786;
}

.companies-showcase {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
}

.companies-collage {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 40px;
  align-items: center;
  justify-items: center;
  min-height: 400px;
}

.logo-item {
  width: 90px !important;
  height: 60px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  border-radius: 12px;
  padding: 12px !important;
  box-shadow: 0 6px 20px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  opacity: 0;
  position: relative;
  box-sizing: border-box;
}

.logo-item img {
  max-width: 100% !important;
  max-height: 100% !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.logo-item:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.logo-item:hover img {
  transform: scale(1.02);
}

/* Animation classes */
.logo-item.fade-left {
  transform: translateX(-100px);
  animation: slideInLeft 0.8s ease forwards;
}

.logo-item.fade-right {
  transform: translateX(100px);
  animation: slideInRight 0.8s ease forwards;
}

@keyframes slideInLeft {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/*------------------------------------------------------
RESPONSIVE DESIGN
------------------------------------------------------*/

/* Large desktop adjustments */
@media screen and (max-width: 1400px) {
  /* No size changes - keep logos uniform */
}

/* Laptop adjustments */
@media screen and (max-width: 1200px) {
  .hero-section {
    min-height: 600px;
  }
  
  /* Keep logo sizes uniform - no size changes */
}

@media screen and (max-width: 768px) {
  .hero-section {
    padding: 80px 0 60px;
    min-height: 500px;
  }
  
  .hero-content {
    padding: 0 30px;
  }
  
  /* Hide scattered company logo icons on mobile */
  .hero-logo-item.scattered {
    display: none !important;
    pointer-events: none !important;
    visibility: hidden !important;
    z-index: -1 !important;
  }
  
  /* Keep logo sizes uniform - no size changes */
  
  /* Reset positions to prevent edge overflow */
  .hero-logo-item.scattered[style*="left: 1%"],
  .hero-logo-item.scattered[style*="left: 2%"] { 
    left: 5% !important; 
  }
  .hero-logo-item.scattered[style*="right: 1%"],
  .hero-logo-item.scattered[style*="right: 2%"] { 
    right: 5% !important; 
  }
  
  .stats-container {
    flex-direction: column;
    gap: 40px;
  }
  
  .seniors-congratulations {
    padding: 60px 30px;
  }
  
  .seniors-congratulations h2 {
    font-size: 32px;
    margin-bottom: 25px;
  }
  
  .seniors-message {
    font-size: 16px;
    margin-bottom: 40px;
    padding: 0 10px;
  }
  
  .seniors-photo img {
    max-width: 100%;
  }
  
  .featured-alumni,
  .all-alumni,
  .companies-section {
    padding: 60px 30px;
  }
  
  .featured-grid {
    grid-template-columns: 1fr;
  }
  
  .class-tabs {
    flex-wrap: wrap;
    gap: 15px;
  }
  
  .tab-btn {
    padding: 10px 20px;
    font-size: 14px;
  }
  
  .alumni-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
  }
  
  .companies-collage {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    min-height: 350px;
  }
  
  /* Keep companies showcase logos uniform - no size changes */
}

@media screen and (max-width: 480px) {
  .hero-section {
    padding: 60px 0 40px;
    min-height: 450px;
  }
  
  .hero-content {
    padding: 0 20px;
  }
  
  /* Keep logo sizes uniform - no size changes */
  
  /* Ensure logos stay within safe boundaries */
  .hero-logo-item.scattered[style*="left"] { 
    left: 5% !important; 
  }
  .hero-logo-item.scattered[style*="right"] { 
    right: 5% !important; 
  }
  
  .featured-grid,
  .alumni-grid {
    grid-template-columns: 1fr;
  }
  
  .stat-number {
    font-size: 36px;
  }
  
  .hero-section h1 {
    font-size: 32px;
  }
  
  .seniors-congratulations {
    padding: 40px 20px;
  }
  
  .seniors-congratulations h2 {
    font-size: 28px;
    margin-bottom: 20px;
  }
  
  .seniors-message {
    font-size: 15px;
    margin-bottom: 30px;
    padding: 0 5px;
  }
  
  .featured-alumni h2,
  .all-alumni h2,
  .companies-section h2 {
    font-size: 28px;
  }
  
  .companies-collage {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    min-height: 300px;
  }
  
  /* Keep companies showcase logos uniform - no size changes */
}

/* Fallback animations for when JavaScript is disabled */
@media (prefers-reduced-motion: no-preference) {
  .hero-logo-item.scattered {
    animation: logoFadeIn 0.8s ease-out forwards;
    animation-delay: calc(var(--delay, 0) * 1ms);
  }
  
  @keyframes logoFadeIn {
    from {
      opacity: 0;
      transform: translateY(30px);
      visibility: hidden;
    }
    to {
      opacity: 0.8;
      transform: translateY(0);
      visibility: visible;
    }
  }
  
  /* Staggered delays for fallback animation */
  .hero-logo-item.scattered:nth-child(1) { --delay: 100; }
  .hero-logo-item.scattered:nth-child(2) { --delay: 300; }
  .hero-logo-item.scattered:nth-child(3) { --delay: 500; }
  .hero-logo-item.scattered:nth-child(4) { --delay: 700; }
  .hero-logo-item.scattered:nth-child(5) { --delay: 900; }
  .hero-logo-item.scattered:nth-child(6) { --delay: 1100; }
  .hero-logo-item.scattered:nth-child(7) { --delay: 1300; }
  .hero-logo-item.scattered:nth-child(8) { --delay: 1500; }
}

/* Disable fallback animations when JavaScript is working */
.js-enabled .hero-logo-item.scattered {
  animation: none;
}
