/* ==============================
   home.css
   Homepage Styles
============================== */

/* Hero Section */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 1;
}
.hero-slideshow img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  position: absolute;
  top: 0; left: 0;
  opacity: 0;
  transition: opacity 2s ease-in-out;
}
.hero-slideshow img.active { opacity: 1; }
.hero-container {
  position: relative;
  z-index: 2;
  max-width: 900px;
  padding: 20px;
}
.hero h1 {
  font-size: 52px;
  margin-bottom: 15px;
  font-weight: bold;
  text-shadow: 0 3px 6px rgba(0,0,0,0.5);
}
.hero p {
  font-size: 20px;
  margin-bottom: 30px;
  color: #f5f5f5;
  text-shadow: 0 2px 4px rgba(0,0,0,0.4);
}

/* Search Bar */
.search-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 20px;
}
.search-bar input {
  padding: 14px;
  border: none;
  border-radius: 6px;
  min-width: 200px;
  font-size: 15px;
}
.search-bar button {
  padding: 14px 24px;
  font-size: 15px;
  border-radius: 6px;
}

/* CTA Buttons */
.cta-buttons {
  margin-top: 20px;
  display: flex;
  justify-content: center;
  gap: 20px;
}

/* Stats Section */
.stats {
  position: relative;
  background: url('images/ship3.jpg') no-repeat center center/cover;
  padding: 100px 20px;
  overflow: hidden;
}
.stats-overlay {
  background: rgba(0, 30, 50, 0.75);
  padding: 60px 0;
}
.stats-container {
  display: flex;
  justify-content: center;
  gap: 80px;
  flex-wrap: wrap;
  text-align: center;
}
.stat-card {
  flex: 1 1 200px;
  padding: 20px;
  color: #fff;
  animation: fadeUp 1s ease-out;
}
.stat-card h2 {
  font-size: 48px;
  font-weight: bold;
  color: var(--primary-teal);
  margin-bottom: 10px;
}
.stat-card p {
  font-size: 16px;
  color: #f1f1f1;
}

/* Latest Jobs */
.latest-jobs {
  padding: 100px 20px;
  background: linear-gradient(135deg, #f9fafb, #eef3f4);
  text-align: center;
}
.latest-jobs h2 {
  font-size: 34px;
  margin-bottom: 50px;
  color: var(--dark-navy);
  font-weight: bold;
  letter-spacing: 1px;
}
.job-carousel-wrapper {
  position: relative;
  overflow: hidden;
  max-width: 1200px;
  margin: auto;
}
.job-carousel {
  display: flex;
  transition: transform 0.6s ease;
}
.job-card {
  flex: 0 0 33.333%;
  background: #fff;
  border-radius: 10px;
  margin: 0 10px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  text-align: left;
}
.carousel-btn {
  position: absolute;
  top: 40%;
  transform: translateY(-50%);
  background: var(--primary-teal);
  border: none;
  color: #fff;
  font-size: 28px;
  padding: 10px 15px;
  cursor: pointer;
  border-radius: 50%;
  z-index: 5;
}
.carousel-btn.prev { left: -50px; }
.carousel-btn.next { right: -50px; }

/* Companies */
.companies {
  padding: 80px 20px;
  background: #f9fafb;
}
.companies h2 {
  text-align: center;
  margin-bottom: 40px;
  color: var(--dark-navy);
}
.company-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(220px,1fr));
  gap: 20px;
}
.company-card {
  background: #fff;
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  text-align: center;
}

/* Events */
.events {
  padding: 80px 20px;
  background: linear-gradient(135deg,#eef3f4,#f9fafb);
}
.events h2 {
  text-align: center;
  margin-bottom: 40px;
  color: var(--dark-navy);
}
.event-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(220px,1fr));
  gap: 20px;
}
.event-card {
  background: #fff;
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  text-align: center;
}

/* Testimonials */
.testimonials {
  padding: 80px 20px;
}
.testimonials h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 30px;
  color: var(--dark-navy);
}
.testimonial-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 25px;
  justify-content: center;
}
.testimonial-cards .card {
  max-width: 360px;
  background: var(--off-white);
  border-radius: 8px;
  padding: 25px;
  font-style: italic;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

/* Animations */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==============================
   Responsive Fixes
============================== */

/* Tablets */
@media (max-width: 992px) {
  .job-card {
    flex: 0 0 50%; /* 2 cards per slide */
  }
  .carousel-btn.prev { left: -30px; }
  .carousel-btn.next { right: -30px; }
}

/* Mobiles */
@media (max-width: 600px) {
  .hero h1 { font-size: 32px; }
  .hero p { font-size: 16px; }

  .search-bar input {
    min-width: 100%;
  }

  .job-card {
    flex: 0 0 100%; /* 1 card per slide */
    margin: 0 5px;
  }

  .carousel-btn {
    font-size: 22px;
    padding: 6px 10px;
  }
}
