/* RESET & GLOBAL STYLES */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --color-primary: #0a192f; /* Deep Navy Blue */
  --color-secondary: #5a7a9e; /* Muted Blue */
  --color-accent: #88a4be; /* Soft Institutional Blue */
  --color-bg: #f0f2f5; /* Light Neutral Grey */
  --color-text: #333d4b; /* Dark Neutral Grey */
  --color-text-light: #e6f1ff;
  --color-white: #ffffff;
  --font-family-base: 'Lato', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --spacing-unit: 8px;
  --border-radius: 8px;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  --header-height: 80px;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-family-base);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 calc(var(--spacing-unit) * 3);
}

section {
  padding: clamp(60px, 10vw, 100px) 0;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Roboto', var(--font-family-base);
  color: var(--color-primary);
  line-height: 1.2;
  margin-bottom: calc(var(--spacing-unit) * 3);
  font-weight: 700;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2rem); }
p { margin-bottom: calc(var(--spacing-unit) * 2); max-width: 75ch; }
a { color: var(--color-secondary); text-decoration: none; transition: color 0.3s ease; }
a:hover { color: var(--color-accent); }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; filter: saturate(0) brightness(0.95) sepia(0.1); }

/* HEADER & NAVIGATION */
.main-header {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.logo {
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-links {
  display: flex;
  gap: calc(var(--spacing-unit) * 4);
}

.nav-links a {
  font-weight: 500;
  color: var(--color-primary);
  position: relative;
  padding: 5px 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-accent);
  transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}
.nav-links a.active {
    color: var(--color-secondary);
    font-weight: 700;
}

.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 120%;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--color-white);
  box-shadow: var(--shadow);
  border-radius: var(--border-radius);
  min-width: 250px;
  padding: var(--spacing-unit);
  z-index: 1;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, top 0.3s ease;
}

.dropdown:hover .dropdown-content {
  display: block;
  opacity: 1;
  visibility: visible;
  top: 100%;
}

.dropdown-content a {
  display: block;
  padding: calc(var(--spacing-unit) * 1.5) calc(var(--spacing-unit) * 2);
  white-space: nowrap;
}
.dropdown-content a::after {
    display: none;
}
.dropdown-content a:hover {
    background-color: var(--color-bg);
}


.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
}

.mobile-menu-toggle .hamburger-icon {
  width: 30px;
  height: 22px;
  position: relative;
  transform: rotate(0deg);
  transition: .5s ease-in-out;
}
.hamburger-icon span {
  display: block;
  position: absolute;
  height: 3px;
  width: 100%;
  background: var(--color-primary);
  border-radius: 9px;
  opacity: 1;
  left: 0;
  transform: rotate(0deg);
  transition: .25s ease-in-out;
}
.hamburger-icon span:nth-child(1) { top: 0; }
.hamburger-icon span:nth-child(2),
.hamburger-icon span:nth-child(3) { top: 9px; }
.hamburger-icon span:nth-child(4) { top: 18px; }

.main-header.nav-open .hamburger-icon span:nth-child(1),
.main-header.nav-open .hamburger-icon span:nth-child(4) { top: 9px; width: 0%; left: 50%; }
.main-header.nav-open .hamburger-icon span:nth-child(2) { transform: rotate(45deg); }
.main-header.nav-open .hamburger-icon span:nth-child(3) { transform: rotate(-45deg); }

/* HERO SECTION */
.hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--color-white);
  padding: 100px 0;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
.page-hero { min-height: 40vh; }

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, var(--color-primary) 0%, rgba(10, 25, 47, 0.7) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
}

.hero h1 { color: var(--color-white); }
.hero p {
  font-size: clamp(1rem, 1.5vw, 1.25rem);
  color: var(--color-text-light);
  max-width: 80ch;
  margin: 0 auto;
}

/* GENERAL SECTIONS & COMPONENTS */
.section-light { background-color: var(--color-white); }
.section-dark { background-color: var(--color-primary); color: var(--color-text-light); }
.section-dark h2, .section-dark h3 { color: var(--color-white); }

.text-center { text-align: center; }
.section-title { margin-bottom: calc(var(--spacing-unit) * 6); }
.section-intro { max-width: 70ch; margin: 0 auto calc(var(--spacing-unit) * 6); }

/* BUTTONS */
.btn {
  display: inline-block;
  padding: calc(var(--spacing-unit) * 1.5) calc(var(--spacing-unit) * 3);
  font-weight: 700;
  text-align: center;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}
.btn-primary { background-color: var(--color-secondary); color: var(--color-white); }
.btn-primary:hover { background-color: var(--color-accent); }
.btn-secondary { background-color: transparent; color: var(--color-secondary); border-color: var(--color-secondary); }
.btn-secondary:hover { background-color: var(--color-secondary); color: var(--color-white); }


/* FEATURE GRID */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: calc(var(--spacing-unit) * 4);
}

.feature-card {
  background-color: var(--color-white);
  padding: calc(var(--spacing-unit) * 4);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  text-align: center;
}
.feature-card-icon {
    font-size: 3rem;
    color: var(--color-accent);
    margin-bottom: calc(var(--spacing-unit) * 2);
}
.feature-card h3 {
  font-size: 1.25rem;
  margin-bottom: calc(var(--spacing-unit) * 2);
}

/* EDITORIAL PREVIEW */
.editorial-preview {
    background-color: var(--color-bg);
}
.preview-card {
    background-color: var(--color-white);
    padding: calc(var(--spacing-unit) * 4);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.preview-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}
.preview-card p{
    margin-bottom: calc(var(--spacing-unit) * 3);
}
.preview-card .read-more {
    font-weight: 700;
    color: var(--color-secondary);
}

/* ABOUT PAGE */
.about-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: calc(var(--spacing-unit) * 6);
}
.about-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: var(--border-radius);
    max-height: 500px;
}
.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: calc(var(--spacing-unit) * 3);
    margin-top: calc(var(--spacing-unit) * 4);
}
.value-card {
    border-left: 4px solid var(--color-accent);
    padding-left: calc(var(--spacing-unit) * 2);
}
.value-card h4 {
    font-size: 1.1rem;
    color: var(--color-primary);
}


/* ARTICLE PAGE */
.article-content {
    max-width: 800px;
    margin: 0 auto;
}
.article-content h3, .article-content h4 { margin-top: calc(var(--spacing-unit) * 5); }
.article-content ul {
    list-style: disc;
    padding-left: calc(var(--spacing-unit) * 4);
    margin-bottom: calc(var(--spacing-unit) * 2);
}
.related-articles { margin-top: calc(var(--spacing-unit) * 8); border-top: 1px solid #ddd; padding-top: calc(var(--spacing-unit) * 4); }
.related-articles h3 { margin-bottom: calc(var(--spacing-unit) * 3); }
.related-articles ul a { display: block; padding: 10px 0; }

/* CONTACT PAGE */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: calc(var(--spacing-unit) * 6);
  align-items: start;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: calc(var(--spacing-unit) * 2);
}

.form-group {
  display: flex;
  flex-direction: column;
}

.contact-form label {
  font-weight: 500;
  margin-bottom: var(--spacing-unit);
}

.contact-form input,
.contact-form textarea {
  padding: calc(var(--spacing-unit) * 1.5);
  border: 1px solid #ccc;
  border-radius: var(--border-radius);
  font-family: inherit;
  font-size: 1rem;
  width: 100%;
}

.contact-form textarea {
  min-height: 150px;
  resize: vertical;
}

.disclaimer-box {
    background-color: var(--color-bg);
    padding: calc(var(--spacing-unit) * 2);
    border-radius: var(--border-radius);
    border-left: 4px solid var(--color-accent);
    margin-top:  calc(var(--spacing-unit) * 3);
    font-size: 0.9rem;
    font-style: italic;
}


/* LEGAL PAGE */
.legal-content {
    max-width: 800px;
    margin: 0 auto;
}
.legal-content h3 {
    margin-top: calc(var(--spacing-unit) * 4);
}

/* FOOTER */
.main-footer {
  background-color: var(--color-primary);
  color: var(--color-text-light);
  padding: calc(var(--spacing-unit) * 6) 0 calc(var(--spacing-unit) * 3);
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: calc(var(--spacing-unit) * 4);
  margin-bottom: calc(var(--spacing-unit) * 4);
}
.footer-column h4 {
  color: var(--color-white);
  margin-bottom: var(--spacing-unit) * 2;
  font-size: 1.1rem;
}
.footer-column ul li {
  margin-bottom: var(--spacing-unit);
}
.footer-column ul a {
  color: var(--color-text-light);
  opacity: 0.8;
}
.footer-column ul a:hover {
  opacity: 1;
  color: var(--color-white);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: calc(var(--spacing-unit) * 3);
  text-align: center;
  font-size: 0.9rem;
  opacity: 0.7;
}

/* COOKIE BANNER */
#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: rgba(10, 25, 47, 0.95);
  color: var(--color-text-light);
  padding: calc(var(--spacing-unit) * 2) calc(var(--spacing-unit) * 3);
  display: none; /* Initially hidden */
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--spacing-unit) * 2);
  z-index: 9999;
  flex-wrap: wrap;
  border-top: 1px solid var(--color-secondary);
}
#cookie-banner p { flex-grow: 1; margin: 0; font-size: 0.9rem; }
.cookie-buttons { display: flex; gap: var(--spacing-unit); flex-shrink: 0;}

/* RESPONSIVE DESIGN */
@media (min-width: 768px) {
    .about-content { grid-template-columns: 1fr 1fr; }
    .contact-grid { grid-template-columns: 2fr 1fr; }
}

@media (max-width: 767px) {
  .nav-links {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background-color: var(--color-white);
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: calc(var(--spacing-unit) * 5);
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
  }
  .main-header.nav-open .nav-links {
    transform: translateX(0);
  }
  .nav-links li {
    width: 100%;
    text-align: center;
  }
  .nav-links a {
    display: block;
    padding: var(--spacing-unit) * 2;
    font-size: 1.2rem;
  }
  .dropdown:hover .dropdown-content { display: none; }
  .dropdown-content {
    position: static;
    display: block;
    transform: none;
    background: transparent;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    min-width: auto;
    padding: 0;
    margin-top: 10px;
  }
  .dropdown-content a {
    font-size: 1.1rem;
    color: var(--color-text);
  }
  #cookie-banner {
    flex-direction: column;
    text-align: center;
  }

  .mobile-menu-toggle { display: block; }
}