/* global.css */

/* General Reset and Variables */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #0B1957;         /* Deep blue for headers and accents */
  --secondary: #9ECCFA;       /* Light blue for buttons and links */
  --tertiary: #4ECDC4;        /* Soft teal for additional accents */
  --neutral: #F5F7FA;         /* Light gray for backgrounds */
  --light: #FFFFFF;           /* White for clarity */
  --dark: #1A2A44;            /* Darker blue for text and shadows */
  --accent: #FFD700;          /* Soft gold for highlights */
  --transition-default: all 0.3s ease;
  --shadow-light: 0 4px 15px rgba(0, 0, 0, 0.1);
  --shadow-dark: 0 6px 20px rgba(0, 0, 0, 0.15);
}

body {
  line-height: 1.7;
  color: var(--dark);
  background: var(--neutral);
  font-family: 'Poppins', sans-serif;
  font-weight: 400;
  overflow-x: hidden;
  padding-top: 6rem;
  transition: background 0.5s ease, color 0.5s ease;
}

/* Smooth Scroll */
html {
  scroll-behavior: smooth;
}

/* General Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  color: var(--primary);
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.1);
}

p {
  font-size: 1.15rem;
  margin-bottom: 1.5rem;
  color: var(--dark);
}

/* Accessibility: Skip Link */
.skip-link {
  position: absolute;
  top: -60px;
  left: 0;
  background: linear-gradient(45deg, var(--secondary), var(--tertiary));
  color: var(--light);
  padding: 1rem 2rem;
  z-index: 1003;
  transition: top 0.3s ease, transform 0.3s ease;
  font-family: 'Montserrat', sans-serif;
  font-weight: 100;
  border-radius: 0 0 8px 8px;
  box-shadow: var(--shadow-light);
}

.skip-link:focus {
  top: 0;
  transform: scale(1.05);
  outline: 3px solid var(--accent);
  box-shadow: 0 0 15px rgba(11, 25, 87, 0.5);
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  height: 120px;
  width: 100%;
  background: linear-gradient(45deg, rgba(11, 25, 87, 0.98), rgba(26, 42, 68, 0.98));
  padding: 1.5rem 6%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1000;
  box-shadow: var(--shadow-dark);
  backdrop-filter: blur(10px);
}

.logo img {
  height: 120px;
  width: auto;
  transition: transform 0.3s ease;
}

.logo:hover img {
  transform: rotate(5deg) scale(1.1);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--light);
  font-size: 2rem;
  cursor: pointer;
  transition: color 0.3s ease, transform 0.3s ease;
}

.menu-toggle:hover,
.menu-toggle:focus {
  color: var(--accent);
  transform: rotate(90deg);
  outline: none;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 3rem;
}

.nav-links li a {
  color: var(--light);
  text-decoration: none;
  font-size: 1.2rem;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  position: relative;
  padding: 0.6rem 0;
  transition: var(--transition-default);
}

.nav-links li a.active {
  color: var(--accent);
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.nav-links li a.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--tertiary));
  animation: underline 0.5s ease forwards;
}

@keyframes underline {
  from { width: 0; }
  to { width: 100%; }
}

.nav-links li a:hover,
.nav-links li a:focus {
  color: var(--accent);
  transform: translateY(-2px);
  outline: none;
}

.dropdown {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  background: linear-gradient(45deg, rgba(11, 25, 87, 0.98), rgba(26, 42, 68, 0.98));
  min-width: 200px;
  box-shadow: var(--shadow-dark);
  border-radius: 10px;
  z-index: 1001;
  list-style: none;
  padding: 1rem 0;
  top: 100%;
  opacity: 0;
  transform: translateY(15px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.dropdown:hover .dropdown-menu {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

.dropdown-menu li a {
  color: var(--light);
  padding: 0.8rem 1.8rem;
  display: block;
  font-size: 1.1rem;
  transition: var(--transition-default);
}

.dropdown-menu li a:hover,
.dropdown-menu li a:focus {
  color: var(--accent);
  background: rgba(255, 255, 255, 0.15);
  transform: translateX(5px);
}

.nav-button {
  background: linear-gradient(45deg, var(--secondary), var(--tertiary));
  color: var(--light);
  border: none;
  padding: 0.8rem 2rem;
  border-radius: 10px;
  cursor: pointer;
  font-size: 1.2rem;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-light);
  transition: var(--transition-default);
}

.nav-button:hover,
.nav-button:focus {
  background: linear-gradient(45deg, var(--tertiary), var(--accent));
  color: var(--primary);
  transform: translateY(-3px) scale(1.05);
  box-shadow: var(--shadow-dark);
  outline: 3px solid var(--primary);
}

/* General Section Styling */
.section {
  padding: 8rem 8%;
  background: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: auto;
  position: relative;
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 0.8s ease, transform 0.8s ease;
  margin-bottom: 2px;
}

.section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 20% 80%, rgba(78-calculateExpression(78,205,196,0.1), transparent));
  z-index: -1;
}

.section.visible {
  opacity: 1;
  transform: translateY(0);
}

.section h2 {
  font-size: 3.5rem;
  margin-bottom: 4rem;
  text-align: center;
  text-shadow: 1px 1px 6px rgba(11, 25, 87, 0.1);
  animation: fadeIn 1s ease-in-out;
}

.section h2 i {
  margin-left: 0.8rem;
  color: var(--tertiary);
}

/* Buttons */
.cta-button, .learn-more {
  background: linear-gradient(45deg, var(--secondary), var(--tertiary));
  color: var(--light);
  border: none;
  padding: 0.8rem 1.8rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.1rem;
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: var(--shadow-light);
  transition: var(--transition-default);
  max-width: 250px;
}

.cta-button:hover,
.cta-button:focus,
.learn-more:hover,
.learn-more:focus {
  background: linear-gradient(45deg, var(--tertiary), var(--accent));
  color: var(--primary);
  transform: translateY(-3px) scale(1.05);
  box-shadow: var(--shadow-dark);
  outline: 2px solid var(--primary);
}

.cta-button i,
.learn-more i {
  transition: transform 0.3s ease;
}

.cta-button:hover i,
.learn-more:hover i {
  transform: translateX(6px) rotate(20deg);
}

/* Footer */
footer.section[role="contentinfo"] {
  margin: 0;
  padding: 0;
  position: relative;
  color: var(--light);
  overflow: visible;
  font-family: 'Poppins', sans-serif;
}

.footer-container {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: stretch;
  gap: 3rem;
  padding: 5rem 6%;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  border-top: 8px solid var(--secondary);
  z-index: 2;
  box-sizing: border-box;
}

/* Animated Background */
.footer-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #0b1957 0%, #1a2a6c 40%, #2b406e 100%);
  animation: gradientShift 15s ease infinite;
  z-index: -1;
}

.footer-bg::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 70%);
  animation: pulseGlow 10s ease infinite;
}

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes pulseGlow {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.05); }
}

/* Contact h2 */
#footer-contact {
  color: #F5F7FA;
}

/* Contact Info */
.footer-info {
  flex: 1;
  min-width: 300px;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 15px;
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow-wrap: break-word;
  word-break: break-word; /* Break long words to prevent overflow */
  overflow: hidden; /* Hide any content that might overflow */
  text-overflow: ellipsis; /* Add ellipsis for overflowing text (optional) */
}

.footer-info:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.25);
}

.footer-info h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 2rem;
  margin: 0 0 2rem 0;
  color: var(--secondary);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.contact-details {
  list-style: none;
  padding: 0;
  margin: 0;
}

.contact-details li {
  margin: 0 0  1.5rem 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap; /* Allow flex items to wrap if too long */
  word-break: break-word; /* Ensure long words break */
}

.contact-details i {
  width: 28px;
  margin-right: 1.2rem;
  color: var(--secondary);
  font-size: 1.4rem;
  transition: transform 0.3s ease, color 0.3s ease;
}

.contact-details li:hover i {
  transform: rotate(10deg) scale(1.15);
  color: #fff;
}

.contact-details a,
.contact-details span {
  color: #e6ecff;
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 400;
  transition: color 0.3s ease, transform 0.3s ease;
  max-width: 100%; /* Prevent text from exceeding container width */
  white-space: normal; /* Allow text to wrap naturally */
}

.contact-details a:hover {
  color: var(--secondary);
  transform: translateX(5px);
}

/* Modal Overlay */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}

/* Modal visibility when active */
.modal[style*="block"] {
  opacity: 1;
}

/* Modal Content */
.modal-content {
  position: relative;
  background: var(--light);
  padding: 2rem;
  border-radius: 15px;
  max-width: 500px;
  width: 90%;
  margin: 15vh auto;
  box-shadow: var(--shadow-dark);
  transform: translateY(-20px);
  transition: transform 0.3s ease-in-out;
  font-family: 'Poppins', sans-serif;
}

/* Modal content when visible */
.modal[style*="block"] .modal-content {
  transform: translateY(0);
}

/* Close Button */
.close-modal {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--dark);
  cursor: pointer;
  transition: color 0.3s ease, transform 0.3s ease;
}

.close-modal:hover,
.close-modal:focus {
  color: var(--accent);
  transform: scale(1.1);
  outline: none;
}

/* Modal Title */
.modal-content h3 {
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.modal-content h3 i {
  color: var(--tertiary);
}

/* Modal Text */
.modal-content p {
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--dark);
  line-height: 1.6;
  margin-bottom: 0;
}

/* Modal Link */
.modal-content a {
  color: var(--secondary);
  text-decoration: none;
  transition: color 0.3s ease;
}

.modal-content a:hover,
.modal-content a:focus {
  color: var(--accent);
  outline: none;
}

/* Branding */
.footer-brand {
  flex: 1;
  min-width: 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 15px;
  backdrop-filter: blur(8px);
}

.footer-logo {
  width: 240px;
  height: auto;
  margin-bottom: 2rem;
  cursor: pointer;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.footer-logo:hover {
  transform: scale(1.1) rotate(2deg);
  filter: drop-shadow(0 0 10px rgba(244, 162, 97, 0.5));
}

.footer-tagline {
  font-family: 'Poppins', sans-serif;
  font-size: 1.4rem;
  font-style: italic;
  font-weight: 300;
  color: #d9e1ff;
  opacity: 0.9;
  margin: 0 0 1.8rem 0;
}

.footer-accent {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  position: relative;
}

.accent-curve {
  width: 80px;
  height: 4px;
  background: var(--secondary);
  border-radius: 50px;
  position: relative;
  overflow: hidden;
}

.accent-curve::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(to right, transparent, #fff, transparent);
  animation: shine 4s infinite;
}

@keyframes shine {
  0% { left: -100%; }
  20% { left: 100%; }
  100% { left: 100%; }
}

.accent-text {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--light);
  text-transform: uppercase;
  letter-spacing: 2.5px;
  text-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}

/* Footer Image */
.footer-image-container {
  flex: 1;
  min-width: 300px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.image-wrapper {
  position: relative;
  width: 100%;
  max-width: 480px;
  transition: transform 0.4s ease;
}

.image-wrapper:hover {
  transform: scale(1.05);
}

.footer-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 5px;
}

/* Bottom Section */
.footer-bottom {
  width: 100%;
  text-align: center;
  padding: 2.5rem 6%;
  background: rgba(0, 0, 0, 0.15);
  border-top: 3px solid rgba(244, 162, 97, 0.2);
  backdrop-filter: blur(5px);
  box-sizing: border-box;
}

.footer-bottom p {
  margin: 0.8rem 0;
  font-size: 1.1rem;
  font-weight: 400;
  color: #e0e6ff;
}

.legal-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
}

.legal-links a {
  color: var(--light);
  text-decoration: none;
  font-family: 'Poppins', sans-serif;
  font-size: 1.1rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  transition: all 0.3s ease;
}

.legal-links a span {
  margin-left: 0.5rem;
  opacity: 0;
  transform: translateX(-10px);
  transition: all 0.3s ease;
}

.legal-links a:hover span {
  opacity: 1;
  transform: translateX(0);
}

.legal-links a:hover {
  color: var(--secondary);
  text-shadow: 0 0 8px rgba(244, 162, 97, 0.6);
}

.legal-links i {
  font-size: 1.2rem;
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: linear-gradient(45deg, var(--secondary), var(--tertiary));
  color: var(--light);
  padding: 1rem 1.5rem;
  border-radius: 50%;
  font-size: 1.5rem;
  box-shadow: var(--shadow-light);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-default);
  z-index: 1000;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover,
.back-to-top:focus {
  background: linear-gradient(45deg, var(--tertiary), var(--accent));
  color: var(--primary);
  transform: translateY(-5px);
  box-shadow: var(--shadow-dark);
  outline: 3px solid var(--primary);
}

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

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes typewriter {
  from { width: 0; }
  to { width: 100%; }
}

/* Responsive Adjustments */
@media (max-width: 1024px) {
  .logo img {
    height: 75px;
    width: auto;
  }
  .footer-container {
    flex-direction: column;
    padding: 4rem 5%;
  }
  .footer-image-container {
    order: 2;
    justify-content: center;
    padding-top: 2rem;
  }
  .footer-image {
    max-width: 400px;
  }
}

@media (max-width: 768px) {
  /* Navigation */
  .navbar {
    height: auto;
    padding: 1rem 3%;
    align-items: flex-start;
  }
  .menu-toggle {
    display: block;
  }
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: linear-gradient(45deg, var(--primary), var(--dark));
    padding: 0.5rem 0;
    box-shadow: var(--shadow-dark);
    max-height: 60vh;
    overflow-y: auto;
  }
  .nav-links.active {
    display: flex;
  }
  .nav-links li {
    margin: 0.5rem 0;
  }
  .nav-links li a {
    font-size: 1.1rem;
    padding: 0.8rem 1.5rem;
    display: block;
  }
  .dropdown-menu {
    position: static;
    width: 100%;
    padding: 0.5rem 0;
    background: rgba(11, 25, 87, 0.95);
    box-shadow: none;
  }
  .dropdown-menu li a {
    padding: 0.6rem 2rem;
    font-size: 1rem;
  }
  .nav-button {
    padding: 0.6rem 1.5rem;
    font-size: 1rem;
    margin: 0.5rem auto;
    width: fit-content;
  }

  /* Sections */
  .section {
    padding: 4rem 5%;
  }
  .section h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
  }

  /* Buttons */
  .cta-button, .learn-more {
    padding: 0.7rem 1.5rem;
    font-size: 1rem;
    max-width: 200px;
  }

  /* Footer */
  .footer-container {
    padding: 3rem 4%;
    flex-direction: column;
    gap: 2rem;
    width: 100%;
  }
  .footer-info,
  .footer-brand,
  .footer-image-container {
    min-width: 100%;
    padding: 1.5rem;
    margin: 0;
    width: 100%;
    box-sizing: border-box;
  }
  .footer-info {
    padding: 1.5rem;
    width: 100%;
    box-sizing: border-box;
  }
  .footer-info h2 {
    font-size: 1.8rem;
  }
  .contact-details li {
    font-size: 1rem;
    margin-bottom: 1rem;
  }
  .contact-details a,
  .contact-details span {
    font-size: 1rem;
    line-height: 1.5;
  }
  .footer-logo {
    width: 200px;
  }
  .footer-tagline {
    font-size: 1.3rem;
  }
  .footer-image {
    max-width: 300px;
    width: 100%;
  }
  .footer-accent {
    flex-direction: column;
    gap: 0.5rem;
  }
  .accent-curve {
    width: 60px;
  }
  .footer-bottom {
    padding: 2rem 4%;
  }

  /* Modal */
  .modal-content {
    padding: 1.5rem;
    max-width: 400px;
    margin: 10vh auto;
  }
  .modal-content h3 {
    font-size: 1.5rem;
  }
  .modal-content p {
    font-size: 1rem;
  }

  /* Back to Top */
  .back-to-top {
    padding: 0.8rem 1.2rem;
    font-size: 1.2rem;
    bottom: 20px;
    right: 20px;
  }
}

@media (max-width: 480px) {
  /* Navigation */
  .nav-links li a {
    font-size: 1rem;
  }
  .nav-button {
    padding: 0.5rem 1.2rem;
    font-size: 0.9rem;
  }

  /* Sections */
  .section {
    padding: 3rem 3%;
  }
  .section h2 {
    font-size: 2rem;
  }
  p {
    font-size: 1rem;
  }

  /* Buttons */
  .cta-button, .learn-more {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
    max-width: 180px;
  }

  /* Footer */
  .footer-container {
    padding: 2rem 3%;
  }
  .footer-info,
  .footer-brand,
  .footer-image-container {
    padding: 1rem;
    min-width: 100%;
    width: 100%;
    box-sizing: border-box;
  }
  .footer-info {
    padding: 1rem;
  }
  .footer-info h2 {
    font-size: 1.3rem;
  }
  .contact-details li {
    font-size: 0.9rem;
  }
  .contact-details a,
  .contact-details span {
    font-size: 0.9rem;
  }
  .footer-logo {
    width: 160px;
  }
  .footer-tagline {
    font-size: 0.9rem;
  }
  .accent-text {
    font-size: 1rem;
  }
  .accent-curve {
    width: 50px;
  }
  .footer-image {
    max-width: 240px;
  }
  .footer-bottom {
    padding: 1.5rem 3%;
  }
  .footer-bottom p,
  .legal-links a {
    font-size: 0.9rem;
  }

  /* Modal */
  .modal-content {
    padding: 0.8rem;
    max-width: 90%;
    margin: 3vh auto;
  }
  .modal-content h3 {
    font-size: 1.2rem;
  }
  .modal-content p {
    font-size: 0.85rem;
  }

  /* Back to Top */
  .back-to-top {
    padding: 0.6rem 1rem;
    font-size: 1rem;
    bottom: 15px;
    right: 15px;
  }
}