/*
 * style.css
 *
 * Defines the visual appearance of the EVSELab web site.  A modern,
 * minimalist aesthetic is achieved through the use of a restrained colour
 * palette inspired by the company logo – deep navy, vibrant green and a
 * burgundy accent.  Consistent spacing, typography and modular
 * components ensure a cohesive look and responsive behaviour across
 * devices.  Sections are separated with generous padding and subtle
 * backgrounds to improve readability.
 */

/* Colour variables for easy theme adjustment */
:root {
  --colour-dark: #001e3c;      /* deep navy for backgrounds */
  --colour-navy: #0a2f5c;      /* mid navy for accents */
  --colour-green: #00a84f;     /* vibrant green from the logo */
  --colour-burgundy: #8e004d;  /* burgundy accent for highlights */
  --colour-light: #f4f7f9;     /* very light grey for page background */
  --colour-text: #212529;      /* primary text colour */
  --colour-muted: #6c757d;     /* muted text for secondary information */
}

/* Global resets */
html, body {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Tahoma, sans-serif;
  color: var(--colour-text);
  background-color: var(--colour-light);
  scroll-behavior: smooth;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Header and navigation */
header {
  background-color: var(--colour-dark);
  color: #ffffff;
  position: sticky;
  top: 0;
  z-index: 999;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}

.logo img {
  max-height: 48px;
}

.navigation .nav-links {
  display: flex;
  gap: 1.5rem;
}
.navigation .nav-links a {
  color: #ffffff;
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}
.navigation .nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--colour-green);
  transition: width 0.3s ease;
}
.navigation .nav-links a:hover::after {
  width: 100%;
}

.lang-switch {
  display: flex;
  gap: 0.5rem;
}
.lang-btn {
  background-color: transparent;
  border: 1px solid var(--colour-green);
  color: #ffffff;
  padding: 0.35rem 0.8rem;
  border-radius: 3px;
  font-size: 0.8rem;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.lang-btn.active,
.lang-btn:hover {
  background-color: var(--colour-green);
  color: var(--colour-dark);
}

/* Hero section */
.hero {
  position: relative;
  background-image: url('../images/hero.png');
  background-size: cover;
  background-position: center;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #ffffff;
}
.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.55);
  z-index: 0;
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  padding: 2rem;
}
.hero-content h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  color: var(--colour-green);
}
.hero-content p {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  color: #f1f1f1;
}
.hero-content .btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: var(--colour-green);
  color: var(--colour-dark);
  border-radius: 4px;
  font-weight: 600;
  transition: background-color 0.3s ease;
}
.hero-content .btn:hover {
  background-color: #019f49;
}

/* Generic section styling */
.section {
  padding: 4rem 0;
}
.section.dark {
  background-color: var(--colour-dark);
  color: #ffffff;
}
.section.light {
  background-color: #ffffff;
}
.section-title {
  font-size: 2rem;
  margin-bottom: 1rem;
  text-align: center;
  color: var(--colour-dark);
}
.section.dark .section-title {
  color: var(--colour-green);
}
.section-subtitle {
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  text-align: center;
  color: var(--colour-muted);
}
.section.dark .section-subtitle {
  color: #cbd6e2;
}

/* Cards grid */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.card {
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform 0.2s ease;
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}
.card img {
  width: 100%;
  border-radius: 6px;
  margin-bottom: 1rem;
  object-fit: cover;
  height: 160px;
}
.card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  color: var(--colour-dark);
}
.card p {
  flex-grow: 1;
  color: var(--colour-muted);
  font-size: 0.95rem;
  line-height: 1.5;
}
.card .btn {
  margin-top: 1rem;
  align-self: flex-start;
  padding: 0.5rem 1rem;
  background-color: var(--colour-green);
  color: var(--colour-dark);
  border-radius: 4px;
  font-weight: 600;
  transition: background-color 0.3s ease;
  font-size: 0.9rem;
}
.card .btn:hover {
  background-color: #019f49;
}

/* Two column layouts */
.two-columns {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center;
}
.two-columns .col {
  flex: 1 1 300px;
}
.two-columns img {
  max-width: 100%;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

/* Footer */
footer {
  background-color: var(--colour-dark);
  color: #f5f5f5;
  padding: 3rem 0 1rem 0;
  font-size: 0.9rem;
}
.footer-content {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: space-between;
}
.footer-section {
  flex: 1 1 200px;
}
.footer-section h4 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  color: var(--colour-green);
  font-size: 1.1rem;
}
.footer-section ul li {
  margin-bottom: 0.5rem;
}
.footer-section a {
  color: #cbe7db;
  font-size: 0.9rem;
}
.footer-section a:hover {
  color: var(--colour-green);
}
.footer-bottom {
  text-align: center;
  margin-top: 2rem;
  color: #a0b5c7;
  font-size: 0.8rem;
}

/* Contact form */
.contact-form {
  max-width: 600px;
  margin: 0 auto;
}
.contact-form form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.contact-form input,
.contact-form textarea {
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
}
.contact-form button {
  padding: 0.75rem;
  background-color: var(--colour-green);
  color: var(--colour-dark);
  border: none;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.contact-form button:hover {
  background-color: #019f49;
}

/* Article styling */
.article {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem 1rem;
  line-height: 1.6;
}
.article h2 {
  color: var(--colour-dark);
  margin-bottom: 1rem;
}
.article h3 {
  color: var(--colour-navy);
  margin-top: 1.5rem;
}
.article p {
  margin-bottom: 1rem;
  color: var(--colour-text);
}
.article ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}
.article li {
  margin-bottom: 0.5rem;
}
.article .references {
  margin-top: 2rem;
  font-size: 0.85rem;
  color: var(--colour-muted);
}
.article .references ol {
  padding-left: 1.5rem;
}
.article .references li a {
  color: var(--colour-navy);
  text-decoration: underline;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .nav-container {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  .navigation .nav-links {
    flex-wrap: wrap;
    gap: 0.75rem;
  }
  .hero-content h1 {
    font-size: 2rem;
  }
  .hero-content p {
    font-size: 1rem;
  }
}