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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: white;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Additional sections for scrolling */
.intro-section,
.outro-section {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px;
  text-align: center;
}

.intro-section h1,
.outro-section h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #ffffff 0%, #e5e5ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.intro-section p,
.outro-section p {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.8);
  max-width: 600px;
}

.dashboard {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  width: 85%;
}

.description-container {
  width: 95%;
  height: 800px;
  position: relative;
  background-color: #032043ff;
  overflow: hidden; /* Ensures pseudo-element doesn't overflow */
}

/* Add background image with opacity using pseudo-element */
.description-container::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("MAin.png");
  background-repeat: no-repeat;
  background-size: cover;
  opacity: 0.5;
  z-index: 0;
}

/* Put your content above the background */
.description-container > * {
  position: relative;
  z-index: 1;
}

/* Enhanced starfield background with glowing animation */
.stars {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.star {
  position: absolute;
  background: #ffffff;
  border-radius: 50%;
  animation: enhancedTwinkle 3s infinite ease-in-out;
  /* Enhanced base glow */
  box-shadow: 0 0 10px rgba(255, 255, 255, 1), 0 0 20px rgba(255, 255, 255, 0.8),
    0 0 30px rgba(255, 255, 255, 0.6);
}

@keyframes enhancedTwinkle {
  0%,
  100% {
    opacity: 0.7;
    transform: scale(1);
    box-shadow: 0 0 10px rgba(255, 255, 255, 1),
      0 0 20px rgba(255, 255, 255, 0.8), 0 0 30px rgba(255, 255, 255, 0.6);
  }
  50% {
    opacity: 1;
    transform: scale(1.5);
    box-shadow: 0 0 15px rgba(255, 255, 255, 1),
      0 0 30px rgba(255, 255, 255, 0.9), 0 0 45px rgba(255, 255, 255, 0.7),
      0 0 60px rgba(255, 255, 255, 0.5);
  }
}

/* Large bright stars */
.star.large {
  width: 9px;
  height: 9px;
  background: #fff;
  box-shadow: 0 0 15px rgba(255, 255, 255, 1), 0 0 25px rgba(255, 255, 255, 0.8),
    0 0 35px rgba(255, 255, 255, 0.6), 0 0 45px rgba(255, 255, 255, 0.4);
}

/* Individual star positions with enhanced visibility - only 8 stars for 8 boxes */

.star:nth-child(1) {
  top: 22%;
  left: 14%;
  animation-delay: 0s;
}
.star:nth-child(2) {
  top: 32%;
  left: 45%;
  animation-delay: 0.5s;
}
.star:nth-child(3) {
  top: 53%;
  left: 27%;
  animation-delay: 1s;
}
.star:nth-child(4) {
  top: 79%;
  left: 12%;
  animation-delay: 1.5s;
}
.star:nth-child(5) {
  top: 85%;
  left: 45%;
  animation-delay: 0.8s;
}
.star:nth-child(6) {
  top: 48%;
  left: 85%;
  animation-delay: 0.3s;
}
.star:nth-child(7) {
  top: 65%;
  left: 52%;
  animation-delay: 0.7s;
}
.star:nth-child(8) {
  top: 18%;
  left: 75%;
  animation-delay: 1.8s;
}
.second-container {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px;
}

.features-area {
  position: absolute;
  top: 0;
  left: 0;
  width: 70%;
  height: 100vh;
}

/* Base styles for elements that will be animated */
.animate-element {
  opacity: 0;
  transform: translateY(40px) scale(0.95);
  transition: none; /* Remove transition for immediate reset */
}

/* Animation classes that will be added by JavaScript */
.animate-element.animate-in {
  animation: elegantFadeInUp 0.8s ease-out both;
}

.feature-card {
  position: absolute;
  background-color: #002848ff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 16px 20px;
  backdrop-filter: blur(10px);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  width: 270px;
  min-height: 50px;
}

.card {
  position: absolute;
  background: transparent;
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  width: 500px;
  min-height: 250px;
}

@keyframes elegantFadeInUp {
  0% {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
  }
  60% {
    opacity: 0.8;
    transform: translateY(-5px) scale(1.02);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.feature-card:hover {
  background: #1a324fff;
}

.feature-icon {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 16px;
  color: white;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover .feature-icon,
.card:hover .feature-icon {
  transform: scale(1.15) rotate(5deg);
}

.icon-blue {
  background: linear-gradient(135deg, #4a90e2, #357abd);
}
.icon-purple {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}
.icon-green {
  background: linear-gradient(135deg, #10b981, #059669);
}
.icon-gray {
  background: linear-gradient(135deg, #6b7280, #4b5563);
}
.icon-orange {
  background: linear-gradient(135deg, #f59e0b, #d97706);
}
.icon-red {
  background: linear-gradient(135deg, #ef4444, #dc2626);
}
.icon-black {
  background: linear-gradient(135deg, #374151, #1f2937);
}

.feature-content {
  flex: 1;
}

.feature-title {
  color: white;
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 2px;
  line-height: 1.3;
}

.feature-subtitle {
  color: white;
  font-size: 11px;
  line-height: 1.4;
}

/* Animation delays for staggered effect */
.card-bulk-message.animate-in {
  animation-delay: 0.1s;
}
.card-centralized-data.animate-in {
  animation-delay: 0.2s;
}
.card-ai-report.animate-in {
  animation-delay: 0.3s;
}
.card-smart-attendance.animate-in {
  animation-delay: 0.4s;
}
.card-data-security.animate-in {
  animation-delay: 0.5s;
}
.card-role-based.animate-in {
  animation-delay: 0.6s;
}
.card-ai-timetable.animate-in {
  animation-delay: 0.7s;
}
.card-financial.animate-in {
  animation-delay: 0.8s;
}
.card-bank.animate-in {
  animation-delay: 0.9s;
}

/* Desktop positioning - preserved exactly as provided */
.card-bulk-message {
  top: 8%;
  left: 5%;
  animation-delay: 0.1s;
}

.card-centralized-data {
  top: 5%;
  left: 95%;
  animation-delay: 0.2s;
}

.card-ai-report {
  top: 16%;
  left: 50%;
  animation-delay: 0.3s;
}

.card-smart-attendance {
  top: 32%;
  left: 23%;
  animation-delay: 0.4s;
}

.card-data-security {
  top: 28%;
  left: 110%;
  animation-delay: 0.5s;
}

.card-role-based {
  top: 43%;
  left: 60%;
  animation-delay: 0.6s;
}

.card-ai-timetable {
  top: 55%;
  left: 2%;
  animation-delay: 0.7s;
}

.card-financial {
  top: 60%;
  left: 50%;
  animation-delay: 0.8s;
}

.card-bank {
  top: 38%;
  left: 92%;
  animation-delay: 0.9s;
}

.main-title {
  color: white;
  font-size: 48px;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 24px;
  background: linear-gradient(135deg, #ffffff 0%, #e5e5ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.main-description {
  color: rgba(255, 255, 255, 0.8);
  font-size: 18px;
  line-height: 1.6;
  margin-bottom: 32px;
}

.cta-text {
  color: rgba(255, 255, 255, 0.9);
  font-size: 16px;
  font-weight: 500;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  backdrop-filter: blur(10px);
  display: inline-block;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.cta-text:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

/* Enhanced responsive design - Desktop Large (1600px and up) - preserved */
@media (max-width: 1600px) {
  .second-container {
    max-width: 1200px;
  }
}

/* Desktop Medium (1400px and down) - preserved */
@media (max-width: 1400px) {
  .main-title {
    font-size: 42px;
  }

  .card {
    width: 450px;
    min-height: 220px;
  }
}

/* Large Laptop (1200px and down) - where layout starts to change */
@media (max-width: 1200px) {
  .features-area {
    position: relative;
    width: 100%;
    height: auto;
    min-height: 600px;
    margin-bottom: 40px;
  }

  .feature-card {
    width: 280px;
    min-height: 65px;
    padding: 14px 18px;
  }

  .main-title {
    font-size: 38px;
  }

  .card {
    width: 400px;
    min-height: 200px;
  }

  .feature-title {
    font-size: 15px;
  }

  .feature-subtitle {
    font-size: 13px;
  }

  /* Adjusted positions for laptop */
  .card-bulk-message {
    top: 5%;
    left: 1%;
  }
  .card-centralized-data {
    top: 4%;
    right: -1%;
    left: auto;
  }
  .card-ai-report {
    top: 18%;
    left: 40%;
  }
  .card-smart-attendance {
    top: 38%;
    left: 1%;
  }
  .card-data-security {
    top: 30%;
    right: 2%;
    left: auto;
  }
  .card-role-based {
    top: 45%;
    left: 40%;
  }
  .card-ai-timetable {
    top: 70%;
    left: 2%;
  }
  .card-financial {
    top: 90%;
    left: 20%;
  }
  .card-bank {
    top: 62%;
    right: 2%;
    left: auto;
  }
}

/* Tablet Landscape (992px and down) */
@media (max-width: 992px) {
  .second-container {
    padding: 30px 20px;
  }

  .features-area {
    min-height: 550px;
  }

  .feature-card {
    width: 220px;
    min-height: 65px;
    padding: 14px 18px;
  }

  .card {
    width: 350px;
    min-height: 180px;
    padding: 14px 18px;
  }

  .feature-icon {
    width: 34px;
    height: 34px;
    font-size: 15px;
  }

  .feature-title {
    font-size: 12px;
  }

  .feature-subtitle {
    font-size: 10px;
  }

  .main-title {
    font-size: 34px;
  }

  .main-description {
    font-size: 17px;
  }
}

/* Tablet Portrait (768px and down) */
@media (max-width: 768px) {
  .second-container {
    padding: 25px 15px;
  }

  .features-area {
    min-height: 500px;
  }

  .feature-card {
    width: 220px;
    min-height: 60px;
    padding: 12px 16px;
  }

  .card {
    width: 300px;
    min-height: 160px;
    padding: 12px 16px;
  }

  .feature-icon {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }

  .feature-title {
    font-size: 15px;
  }

  .feature-subtitle {
    font-size: 9px;
  }

  .main-title {
    font-size: 30px;
    margin-bottom: 20px;
  }

  .main-description {
    font-size: 16px;
    margin-bottom: 28px;
  }
}

/* Large Mobile (640px and down) */
@media (max-width: 640px) {
  .second-container {
    padding: 20px 12px;
  }

  .features-area {
    min-height: 450px;
  }

  .feature-card {
    width: 170px;
    min-height: 58px;
    padding: 10px 14px;
  }

  .card {
    width: 280px;
    min-height: 150px;
    padding: 10px 14px;
  }

  .main-title {
    font-size: 26px;
    margin-bottom: 18px;
  }

  .main-description {
    font-size: 15px;
    margin-bottom: 24px;
  }

  .cta-text {
    font-size: 15px;
    padding: 10px 20px;
  }
}

/* Standard Mobile (480px and down) */
@media (max-width: 480px) {
  .second-container {
    padding: 15px 10px;
  }

  .features-area {
    min-height: 750px;
  }

  .dashboard {
    display: flex;
    justify-content: center;
    align-items: center;

    width: 100%;
  }

  .feature-card {
    width: 160px;
    min-height: 55px;
    padding: 10px 12px;
  }

  .card {
    width: 260px;
    min-height: 140px;
    padding: 10px 12px;
  }

  .feature-icon {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }

  .feature-title {
    font-size: 8px;
  }

  .main-title {
    font-size: 20px;
    
  }

  .main-description {
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.5;
  }

  .cta-text {
    font-size: 14px;
    padding: 8px 16px;
  }

  .star.large {
    width: 9px;
    height: 9px;
    background: #fff;
    box-shadow: 0 0 15px rgba(255, 255, 255, 1),
      0 0 25px rgba(255, 255, 255, 0.8), 0 0 35px rgba(255, 255, 255, 0.6),
      0 0 45px rgba(255, 255, 255, 0.4);
  }

  .star:nth-child(1) {
    top: 13%;
    left: 24%;
    animation-delay: 0s;
  }
  .star:nth-child(2) {
    top: 13%;
    left: 75%;
    animation-delay: 0.5s;
  }
  .star:nth-child(3) {
    top: 29%;
    left: 24%;
    animation-delay: 1s;
  }
  .star:nth-child(4) {
    top: 29%;
    left: 75%;
    animation-delay: 1.5s;
  }
  .star:nth-child(5) {
    top: 44%;
    left: 24%;
    animation-delay: 0.8s;
  }
  .star:nth-child(6) {
    top: 44%;
    left: 75%;
    animation-delay: 0.3s;
  }
  .star:nth-child(7) {
    top: 60%;
    left: 24%;
    animation-delay: 0.7s;
  }
  .star:nth-child(8) {
    top: 60%;
    left: 75%;
    animation-delay: 1.8s;
  }

  .card-bulk-message {
    top: 1%;
    animation-delay: 0.1s;
  }

  .card-centralized-data {
    top: 16%;
    left: 55%;
    animation-delay: 0.2s;
  }

  .card-ai-report {
    top: 16%;
    left: 1%;
    animation-delay: 0.3s;
  }

  .card-smart-attendance {
    top: 1%;
    left: 55%;
    animation-delay: 0.4s;
  }

  .card-data-security {
    top: 32%;
    left: 1%;
    animation-delay: 0.5s;
  }

  .card-role-based {
    top: 32%;
    left: 55%;
    animation-delay: 0.6s;
  }

  .card-ai-timetable {
    top: 48%;
    left: 1%;
    animation-delay: 0.7s;
  }

  .card-financial {
    top: 48%;
    left: 55%;
    animation-delay: 0.8s;
  }

  .card-bank {
    top: 64%;
    right: 11%;
    animation-delay: 0.9s;
  }
}

/* Small Mobile (360px and down) */
@media (max-width: 360px) {
  .second-container {
    padding: 12px 8px;
  }

  .features-area {
    min-height: 380px;
  }

  .feature-card {
    width: 145px;
    min-height: 50px;
    padding: 8px 10px;
  }

  .card {
    width: 240px;
    min-height: 130px;
    padding: 8px 10px;
  }

  .feature-icon {
    width: 26px;
    height: 26px;
    font-size: 11px;
  }

  .feature-title {
    font-size: 10px;
  }

  .feature-subtitle {
    font-size: 8px;
  }

  .main-title {
    font-size: 22px;
    margin-bottom: 14px;
  }

  .main-description {
    font-size: 13px;
    margin-bottom: 18px;
  }

  .cta-text {
    font-size: 13px;
    padding: 7px 14px;
  }

  .star.large {
    width: 9px;
    height: 9px;
    background: #fff;
    box-shadow: 0 0 15px rgba(255, 255, 255, 1),
      0 0 25px rgba(255, 255, 255, 0.8), 0 0 35px rgba(255, 255, 255, 0.6),
      0 0 45px rgba(255, 255, 255, 0.4);
  }

  .star:nth-child(1) {
    top: 13%;
    left: 24%;
    animation-delay: 0s;
  }
  .star:nth-child(2) {
    top: 13%;
    left: 75%;
    animation-delay: 0.5s;
  }
  .star:nth-child(3) {
    top: 29%;
    left: 24%;
    animation-delay: 1s;
  }
  .star:nth-child(4) {
    top: 29%;
    left: 75%;
    animation-delay: 1.5s;
  }
  .star:nth-child(5) {
    top: 44%;
    left: 24%;
    animation-delay: 0.8s;
  }
  .star:nth-child(6) {
    top: 44%;
    left: 75%;
    animation-delay: 0.3s;
  }
  .star:nth-child(7) {
    top: 60%;
    left: 24%;
    animation-delay: 0.7s;
  }
  .star:nth-child(8) {
    top: 60%;
    left: 75%;
    animation-delay: 1.8s;
  }

  .card-bulk-message {
    top: 1%;
    animation-delay: 0.1s;
  }

  .card-centralized-data {
    top: 16%;
    left: 55%;
    animation-delay: 0.2s;
  }

  .card-ai-report {
    top: 16%;
    left: 1%;
    animation-delay: 0.3s;
  }

  .card-smart-attendance {
    top: 1%;
    left: 55%;
    animation-delay: 0.4s;
  }

  .card-data-security {
    top: 32%;
    left: 1%;
    animation-delay: 0.5s;
  }

  .card-role-based {
    top: 32%;
    left: 55%;
    animation-delay: 0.6s;
  }

  .card-ai-timetable {
    top: 48%;
    left: 1%;
    animation-delay: 0.7s;
  }

  .card-financial {
    top: 48%;
    left: 55%;
    animation-delay: 0.8s;
  }

  .card-bank {
    top: 64%;
    right: 11%;
    animation-delay: 0.9s;
  }
}

/* Extra Small Mobile (320px and down) */
@media (max-width: 320px) {
  .second-container {
    padding: 10px 5px;
  }

  .features-area {
    min-height: 360px;
  }

  .feature-card {
    width: 135px;
    min-height: 45px;
    padding: 6px 8px;
  }

  .card {
    width: 220px;
    min-height: 120px;
    padding: 6px 8px;
  }

  .feature-icon {
    width: 24px;
    height: 24px;
    font-size: 10px;
  }

  .feature-title {
    font-size: 9px;
  }

  .feature-subtitle {
    font-size: 7px;
  }

  .main-title {
    font-size: 20px;
    margin-bottom: 12px;
  }

  .main-description {
    font-size: 12px;
    margin-bottom: 16px;
  }

  .cta-text {
    font-size: 12px;
    padding: 6px 12px;
  }

  .star.large {
    width: 9px;
    height: 9px;
    background: #fff;
    box-shadow: 0 0 15px rgba(255, 255, 255, 1),
      0 0 25px rgba(255, 255, 255, 0.8), 0 0 35px rgba(255, 255, 255, 0.6),
      0 0 45px rgba(255, 255, 255, 0.4);
  }

  .star:nth-child(1) {
    top: 73%;
    left: 24%;
    animation-delay: 0s;
  }
  .star:nth-child(2) {
    top: 73%;
    left: 75%;
    animation-delay: 0.5s;
  }
  .star:nth-child(3) {
    top: 79%;
    left: 24%;
    animation-delay: 1s;
  }
  .star:nth-child(4) {
    top: 79%;
    left: 75%;
    animation-delay: 1.5s;
  }
  .star:nth-child(5) {
    top: 74%;
    left: 24%;
    animation-delay: 0.8s;
  }
  .star:nth-child(6) {
    top: 74%;
    left: 75%;
    animation-delay: 0.3s;
  }
  .star:nth-child(7) {
    top: 60%;
    left: 24%;
    animation-delay: 0.7s;
  }
  .star:nth-child(8) {
    top: 60%;
    left: 75%;
    animation-delay: 1.8s;
  }

  .card-bulk-message {
    top: 1%;
    animation-delay: 0.1s;
  }

  .card-centralized-data {
    top: 16%;
    left: 55%;
    animation-delay: 0.2s;
  }

  .card-ai-report {
    top: 16%;
    left: 1%;
    animation-delay: 0.3s;
  }

  .card-smart-attendance {
    top: 1%;
    left: 55%;
    animation-delay: 0.4s;
  }

  .card-data-security {
    top: 32%;
    left: 1%;
    animation-delay: 0.5s;
  }

  .card-role-based {
    top: 32%;
    left: 55%;
    animation-delay: 0.6s;
  }

  .card-ai-timetable {
    top: 48%;
    left: 1%;
    animation-delay: 0.7s;
  }

  .card-financial {
    top: 48%;
    left: 55%;
    animation-delay: 0.8s;
  }

  .card-bank {
    top: 64%;
    right: 11%;
    animation-delay: 0.9s;
  }
}

/* iPhone SE (1st gen) and similar very small devices */
@media (max-width: 280px) {
  .second-container {
    padding: 8px 3px;
  }

  .features-area {
    min-height: 340px;
  }

  .feature-card {
    width: 125px;
    min-height: 40px;
    padding: 5px 6px;
    gap: 8px;
  }

  .card {
    width: 200px;
    min-height: 110px;
    padding: 5px 6px;
    gap: 8px;
  }

  .feature-icon {
    width: 22px;
    height: 22px;
    font-size: 9px;
  }

  .feature-title {
    font-size: 8px;
  }

  .feature-subtitle {
    font-size: 6px;
  }

  .main-title {
    font-size: 18px;
    margin-bottom: 10px;
  }

  .main-description {
    font-size: 11px;
    margin-bottom: 14px;
  }

  .cta-text {
    font-size: 11px;
    padding: 5px 10px;
  }

  .star.large {
    width: 9px;
    height: 9px;
    background: #fff;
    box-shadow: 0 0 15px rgba(255, 255, 255, 1),
      0 0 25px rgba(255, 255, 255, 0.8), 0 0 35px rgba(255, 255, 255, 0.6),
      0 0 45px rgba(255, 255, 255, 0.4);
  }

  .star:nth-child(1) {
    top: 73%;
    left: 24%;
    animation-delay: 0s;
  }
  .star:nth-child(2) {
    top: 73%;
    left: 75%;
    animation-delay: 0.5s;
  }
  .star:nth-child(3) {
    top: 79%;
    left: 24%;
    animation-delay: 1s;
  }
  .star:nth-child(4) {
    top: 79%;
    left: 75%;
    animation-delay: 1.5s;
  }
  .star:nth-child(5) {
    top: 74%;
    left: 24%;
    animation-delay: 0.8s;
  }
  .star:nth-child(6) {
    top: 74%;
    left: 75%;
    animation-delay: 0.3s;
  }
  .star:nth-child(7) {
    top: 60%;
    left: 24%;
    animation-delay: 0.7s;
  }
  .star:nth-child(8) {
    top: 60%;
    left: 75%;
    animation-delay: 1.8s;
  }
}
