/*
 * Global Stylesheet for Agnivanta one‑page website
 *
 * This CSS defines a responsive, modern layout aligned with the
 * premium aesthetic described in the business requirements document.
 * Colors and typography derive from the company's visual identity
 * (dark backgrounds with warm, energetic highlights). Sections are
 * spaced thoughtfully to guide the reader through mission, capabilities,
 * differentiators and contact information. All images include alt
 * attributes for accessibility and SEO.
 */

/* CSS Reset and basic variables */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-dark: #0d1a26;
  --color-primary: #e85d04; /* warm orange derived from logo */
  --color-secondary: #f48c06; /* lighter accent */
  --color-light: #fdfdfd;
  --color-gray: #bfc9d1;
  --max-width: 1200px;
  --transition: all 0.3s ease-in-out;
}

body {
  font-family: 'Open Sans', sans-serif;
  line-height: 1.6;
  color: var(--color-dark);
  background-color: var(--color-light);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

img {
  display: block;
  max-width: 100%;
  height: 300%;
}

/* Container utility class */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(13, 26, 38, 0.9);
  backdrop-filter: blur(8px);
  width: 100%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}
.header .nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0;
}
.header .logo img {
  height: 48px;
}
.header nav {
  display: flex;
  gap: 1.5rem;
}
.header nav a {
  color: var(--color-light);
  font-weight: 600;
  padding: 0.25rem 0;
  position: relative;
}
.header nav a:hover {
  color: var(--color-secondary);
}

/* Login buttons in the header */
.login-buttons {
  display: flex;
  gap: 1rem;
}
.btn-login {
  padding: 0.45rem 0.9rem;
  border-radius: 20px;
  background-color: var(--color-primary);
  color: var(--color-light);
  font-weight: 600;
  transition: var(--transition);
  white-space: nowrap;
}
.login-dropdown {
  position: relative;
}
.login-toggle {
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.login-menu {
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  background-color: #fff;
  color: var(--color-dark);
  border-radius: 10px;
  min-width: 180px;
  padding: 0.4rem 0;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  transition: var(--transition);
}
.login-menu a {
  display: block;
  padding: 0.6rem 1rem;
  font-weight: 600;
  color: var(--color-dark);
}
.login-menu a:hover {
  color: var(--color-primary);
  background-color: rgba(232, 93, 4, 0.08);
}
.login-dropdown.is-open .login-menu {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.btn-login:hover {
  background-color: var(--color-secondary);
}

/* Hero section */
.hero {
  position: relative;
  min-height: 80vh;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-light);
  background: url('./assets/Pic5.jpeg') no-repeat center/cover;
  overflow: hidden;
  padding: 0;
}
.hero-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}
.hero-text {
  flex: 1 1 500px;
  background-color: rgba(0, 0, 0, 0.35);
  padding: 2rem 2.5rem;
  border-radius: 16px;
  backdrop-filter: blur(2px);
}
.hero-slides {
  position: relative;
  min-height: 9rem;
}
.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateY(10px);
  animation: heroSlide 25s ease-in-out infinite;
}
.hero-slide:nth-child(1) {
  animation-delay: 0s;
}
.hero-slide:nth-child(2) {
  animation-delay: 5s;
}
.hero-slide:nth-child(3) {
  animation-delay: 10s;
}
.hero-slide:nth-child(4) {
  animation-delay: 15s;
}
.hero-slide:nth-child(5) {
  animation-delay: 20s;
}
.hero-slide > * {
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}
.hero-slide .hero-subtitle {
  max-width: 550px;
}
@keyframes heroSlide {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  5% {
    opacity: 1;
    transform: translateY(0);
  }
  15% {
    opacity: 1;
    transform: translateY(0);
  }
  20% {
    opacity: 0;
    transform: translateY(-6px);
  }
  100% {
    opacity: 0;
    transform: translateY(-6px);
  }
}
.hero-title {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  margin-bottom: 0.75rem;
  line-height: 1.15;
  color: var(--color-light);
}
.hero-subtitle {
  font-size: 1.1rem;
  color: var(--color-gray);
  line-height: 1.6;
}

/* Section base styles */
section {
  padding: 4rem 0;
}
section.dark-section {
  background-color: var(--color-dark);
  color: var(--color-light);
}
section.light-section {
  background-color: var(--color-light);
  color: var(--color-dark);
}

section h2 {
  font-size: 2rem;
  margin-bottom: 1.5rem;
  text-align: center;
}

/* Mission and Vision */
.mission-container {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
}
.mission-item {
  flex: 1 1 280px;
  background-color: rgba(232, 93, 4, 0.05);
  border-left: 4px solid var(--color-primary);
  padding: 1.5rem;
  border-radius: 8px;
}
.mission-item h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--color-primary);
}
.mission-item p {
  color: var(--color-dark);
}

/* Capabilities */
.capabilities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}
.capability-card {
  background-color: #fff;
  border-radius: 8px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  transition: var(--transition);
  height: 100%;
}
.capability-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}
.capability-card i {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
}
.capability-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}
.capability-card p {
  font-size: 0.95rem;
  color: #555;
}

/* Differentiators */
.differentiators-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}
.diff-card {
  background-color: var(--color-dark);
  color: var(--color-light);
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  border: 1px solid rgba(255,255,255,0.1);
  transition: var(--transition);
}
.diff-card:hover {
  background-color: rgba(13,26,38,0.85);
}
.diff-card i {
  font-size: 2rem;
  color: var(--color-secondary);
  margin-bottom: 1rem;
}
.diff-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}
.diff-card p {
  font-size: 0.9rem;
  color: var(--color-gray);
}

/* Industries */
.industries-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}
.industry-card {
  text-align: center;
  padding: 1.5rem;
  border-radius: 8px;
  background-color: #fff;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  transition: var(--transition);
}
.industry-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}
.industry-card i {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 0.75rem;
}
.industry-card h4 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.industry-card p {
  font-size: 0.85rem;
  color: #555;
}

/* Trust Section */
.trust-logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  margin-top: 1.5rem;
}
.trust-logos img {
  height: 40px;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.8;
  transition: var(--transition);
}
.trust-logos img:hover {
  filter: none;
  opacity: 1;
}
.trust-logos .client-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-dark);
}

/* Why Section */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}
.why-card {
  background-color: #fff;
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  transition: var(--transition);
}
.why-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}
.why-card i {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 0.75rem;
}
.why-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}
.why-card p {
  font-size: 0.9rem;
  color: #555;
}

/* Call to Action / Contact Section */
.cta-section {
  background-color: var(--color-dark);
  color: var(--color-light);
  text-align: center;
  padding: 3rem 1rem;
}
.cta-section h2 {
  margin-bottom: 1rem;
  font-size: 2rem;
}
.cta-section p {
  margin-bottom: 2rem;
  font-size: 1rem;
  color: var(--color-gray);
}
.cta-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  max-width: 600px;
  margin: 0 auto;
}
.cta-form input,
.cta-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 4px;
  border: 1px solid #ccc;
  font-size: 1rem;
}
.cta-form textarea {
  grid-column: span 2;
  resize: vertical;
  min-height: 120px;
}
.cta-form button {
  grid-column: span 2;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 30px;
  background-color: var(--color-primary);
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.cta-form button:hover {
  background-color: var(--color-secondary);
}
.form-message {
  margin-top: 1rem;
  font-size: 0.95rem;
  color: var(--color-secondary);
}

/* Footer */
footer {
  background-color: #07121f;
  color: var(--color-gray);
  padding: 2rem 1rem;
}
footer .footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2rem;
}
footer .footer-column {
  flex: 1 1 250px;
}
footer h4 {
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
  color: var(--color-light);
}
footer ul {
  list-style: none;
}
footer ul li {
  margin-bottom: 0.5rem;
}
footer a {
  color: var(--color-gray);
}

/* ensure social links inside the footer display icons and text clearly */
footer .footer-column ul a {
  color: var(--color-light);
}
footer a:hover {
  color: var(--color-secondary);
}
footer .social-links {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}
footer .social-links a {
  /* brighter icons for better visibility on dark background */
  color: var(--color-light);
  font-size: 1.3rem;
  transition: var(--transition);
}
footer .social-links a:hover {
  color: var(--color-secondary);
}
footer .copyright {
  text-align: center;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--color-gray);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .hero-content {
    flex-direction: column;
    text-align: center;
  }
  .hero-text {
    width: 100%;
  }
  .hero-slides {
    min-height: 11rem;
  }
  .cta-form {
    grid-template-columns: 1fr;
  }
  .hero-text {
    padding: 1.5rem 1.75rem;
  }
  .hero-subtitle {
    max-width: 100%;
  }
}

/* Map wrapper used in the location section */
.map-wrapper iframe {
  width: 100%;
  border: 0;
  height: 350px;
}

/* Preloader overlay for initial page load animation */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  background-color: var(--color-dark);
  display: flex;
  align-items: center;
  justify-content: center;
}
#preloader img {
  max-width: 80%;
  max-height: 80%;
  opacity: 0;
  animation: preloaderFadeIn 1.5s forwards, preloaderFadeOut 1.5s forwards 3s;
}
@keyframes preloaderFadeIn {
  from {
    opacity: 0;
    transform: scale(1.05);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
@keyframes preloaderFadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}
/* Responsive layout improvements for smaller screens */
@media (max-width: 1024px) {
  .header .nav-container {
    flex-wrap: wrap;
    gap: 0.75rem;
  }
  .header nav {
    flex: 1 1 100%;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
  }
  .login-buttons {
    flex: 1 1 100%;
    justify-content: center;
    flex-wrap: wrap;
  }
  .hero {
    min-height: 80vh;
    height: auto;
  }
  .hero-subtitle {
    max-width: 100%;
  }
}

@media (max-width: 640px) {
  .header .nav-container {
    padding: 0.35rem 0;
    gap: 0.5rem;
  }
  .header .logo img {
    height: 34px;
  }
  .header nav a {
    font-size: 0.9rem;
  }
  .header nav {
    gap: 0.6rem;
  }
  .login-buttons {
    gap: 0.5rem;
  }
  .btn-login {
    padding: 0.35rem 0.7rem;
    font-size: 0.85rem;
  }
  .login-menu {
    left: 50%;
    right: auto;
    transform: translate(-50%, -4px);
  }
  .login-dropdown.is-open .login-menu {
    transform: translate(-50%, 0);
  }
  section {
    padding: 3rem 0;
  }
  .hero-text {
    padding: 1.25rem 1.5rem;
  }
  .hero-title {
    font-size: clamp(1.8rem, 8vw, 2.4rem);
  }
  .hero-subtitle {
    font-size: 0.98rem;
  }
  .hero-slides {
    min-height: 12.5rem;
  }
  .capability-card,
  .industry-card,
  .why-card,
  .diff-card {
    padding: 1.25rem;
  }
  .cta-section {
    padding: 2.5rem 1rem;
  }
  .cta-form input,
  .cta-form textarea {
    font-size: 0.95rem;
  }
  footer .footer-container {
    gap: 1.5rem;
  }
}
