/* BlaguesPacker Styles */
:root {
  --accent-color: #8bc34a;
  --text-color: #333;
  --bg-color: #fff;
  --border-color: #ddd;
  --light-bg: #f9f9f9;
}

* {
  box-sizing: border-box;
}

body {
  font-family: "Lato", "Source Sans Pro", sans-serif;
  line-height: 1.8;
  color: var(--text-color);
  background: var(--bg-color);
  margin: 0;
  padding: 0;
}

/* Header */
header {
  background: #b0bec5;
  text-align: center;
}

header.site-header {
  position: relative;
  padding: 0;
  overflow: hidden;
}

.header-banner {
  width: 100%;
  max-width: 1600px;
  height: auto;
  display: block;
  margin: 0 auto;
}

.site-branding {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: white;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.site-branding a {
  color: white;
  text-decoration: none;
}

.site-title {
  font-size: 3em;
  margin: 0;
  font-weight: 700;
}

.site-title::after {
  content: "";
  display: block;
  width: 100px;
  height: 4px;
  background: white;
  margin: 15px auto;
}

.site-description {
  font-size: 1.3em;
  margin: 0;
  font-style: italic;
}

/* Navigation */
nav.main-nav {
  background: #f5f5f5;
  padding: 15px 0;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
}

nav.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

nav.main-nav a {
  display: block;
  padding: 8px 14px;
  text-decoration: none;
  color: var(--text-color);
  border-radius: 4px;
  transition: background 0.2s;
  font-size: 0.95em;
}

nav.main-nav a:hover,
nav.main-nav a.active {
  background: var(--accent-color);
  color: white;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Main content */
main {
  padding: 40px 0;
}

/* Article styles */
article {
  max-width: 800px;
  margin: 0 auto;
  padding: 40px 20px;
}

article h1 {
  font-size: 2.2em;
  margin: 0 0 10px;
  color: #2c3e50;
  line-height: 1.3;
}

article time {
  color: #888;
  font-size: 0.95em;
}

article .tag.en-bref {
  background: #7f8c8d;
  color: white;
  padding: 2px 10px;
  border-radius: 3px;
  font-size: 0.85em;
  margin-left: 15px;
}

article .article-meta {
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--accent-color);
}

article h2 {
  font-size: 1.6em;
  margin: 40px 0 20px;
  color: #2c3e50;
  border-left: 4px solid var(--accent-color);
  padding-left: 15px;
}

article h3 {
  font-size: 1.3em;
  margin: 30px 0 15px;
  color: #2c3e50;
}

article p {
  margin: 0 0 1.5em;
  text-align: justify;
}

article a {
  color: var(--accent-color);
  text-decoration: none;
}

article a:hover {
  text-decoration: underline;
}

/* Figures and images */
figure {
  margin: 30px 0;
  padding: 0;
  text-align: center;
}

figure img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

figcaption {
  margin-top: 12px;
  font-size: 0.9em;
  color: #666;
  font-style: italic;
  text-align: center;
}

/* Standalone images (not in figures) */
article p img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 30px auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Articles list (homepage/country pages) */
.articles-list {
  list-style: none;
  padding: 0;
}

.articles-list li {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
}

.articles-list li:last-child {
  border-bottom: none;
}

.article-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.article-link:hover h2 {
  color: var(--accent-color);
}

.article-link h2 {
  margin: 0 0 5px;
  font-size: 1.4em;
  transition: color 0.2s;
  border: none;
  padding: 0;
}

.article-meta {
  color: #666;
  font-size: 0.9em;
}

.article-meta .tag {
  color: white;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 0.85em;
  margin-left: 10px;
}

/* Country-specific colors */
.article-meta .country-australie {
  background: #e74c3c; /* Red */
}

.article-meta .country-nouvelle-zelande {
  background: #3498db; /* Blue */
}

.article-meta .country-nouvelle-caledonie {
  background: #9b59b6; /* Purple */
}

.article-meta .country-perou {
  background: #e67e22; /* Orange */
}

.article-meta .country-bolivie {
  background: #f1c40f; /* Yellow */
  color: #333;
}

.article-meta .country-chili {
  background: #1abc9c; /* Teal */
}

.article-meta .country-argentine {
  background: #2980b9; /* Dark blue */
}

/* En bref tag */
.article-meta .en-bref {
  background: #7f8c8d; /* Gray */
}

/* Author badges */
.article-meta .author-irene {
  background: #e91e63; /* Pink */
}

.article-meta .author-thomas {
  background: #2196f3; /* Blue */
}

/* Post Navigation */
.post-navigation {
  display: flex;
  justify-content: space-between;
  margin-top: 50px;
  padding-top: 30px;
  border-top: 1px solid var(--border-color);
  gap: 20px;
}

.post-navigation .nav-prev,
.post-navigation .nav-next {
  flex: 1;
  max-width: 45%;
}

.post-navigation .nav-prev {
  text-align: right;
}

.post-navigation .nav-next {
  text-align: left;
}

.post-navigation a {
  display: block;
  text-decoration: none;
  color: var(--text-color);
  padding: 15px;
  border-radius: 8px;
  background: var(--light-bg);
  transition:
    background 0.2s,
    transform 0.2s;
}

.post-navigation a:hover {
  background: #f0f0f0;
  transform: translateY(-2px);
}

.post-navigation .nav-label {
  display: block;
  font-size: 0.85em;
  color: #888;
  margin-bottom: 5px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.post-navigation .nav-title {
  display: block;
  font-weight: 600;
  color: var(--accent-color);
}

/* Footer */
footer.site-footer {
  background: #333;
  color: white;
  padding: 20px 0;
  text-align: center;
  margin-top: 40px;
}

footer.site-footer a {
  color: var(--accent-color);
}

/* Responsive */
@media (max-width: 768px) {
  .site-title {
    font-size: 1.8em;
  }

  .site-description {
    font-size: 1em;
  }

  nav.main-nav ul {
    gap: 5px;
  }

  nav.main-nav a {
    padding: 6px 10px;
    font-size: 0.85em;
  }

  article {
    padding: 20px 15px;
  }

  article h1 {
    font-size: 1.7em;
  }

  article h2 {
    font-size: 1.3em;
  }
}

@media (max-width: 600px) {
  .post-navigation {
    flex-direction: column;
  }

  .post-navigation .nav-prev,
  .post-navigation .nav-next {
    max-width: 100%;
    text-align: left;
  }

  .site-branding {
    width: 90%;
  }

  .site-title {
    font-size: 1.5em;
  }

  .site-description {
    font-size: 0.9em;
  }
}
