@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

:root {
  /* -- Couleurs du paysage -- */
  --color-sky: #a8e063;
  --color-sky-bottom: #56ab2f;
  --color-sun: #ffeb3b;
  --color-cloud: #ffffff;
  --color-mountain-far: #2e7d32;
  --color-mountain-mid: #1b5e20;
  --color-mountain-near: #0a3d1b;

  /* -- Couleurs de l'interface -- */
  --color-text: #1a2a1c;
  --color-text-light: #ffffff;
  --color-text-subtle: #556b57;
  --color-surface: rgba(248, 255, 249, 0.8);
  --color-surface-input: rgba(248, 255, 249, 0.6);
  --color-border: rgba(27, 94, 32, 0.2);

  /* -- Couleurs des superpositions (overlays) -- */
  --color-hero-overlay-start: rgba(26, 42, 28, 0.7);
  --color-hero-overlay-end: rgba(26, 42, 28, 0.1);
  --color-hero-text-shadow: rgba(0, 0, 0, 0.4);

  /* -- Typographie (statique) -- */
  --font-main: "Poppins", sans-serif;
}
/* --- Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
body {
  background-color: var(--color-sky-top);
  font-family: var(--font-main);
  color: var(--color-text);
  font-size: 16px;
  line-height: 1.7;
}
.page-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  margin: 0 auto;
  padding: 32px;
}
a {
  color: var(--color-text);
  text-decoration: none;
  font-weight: 600;
}

/* --- Fond Animé --- */
.animated-landscape {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 1;
  overflow: hidden;
}
.sky {
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, var(--color-sky-top), var(--color-sky-bottom));
}
.sun {
  position: absolute;
  top: 10%;
  left: 15%;
  width: 100px;
  height: 100px;
  background-color: var(--color-sun);
  border-radius: 50%;
  box-shadow: 0 0 50px var(--color-sun);
  animation: pulse 10s infinite ease-in-out;
}
.sun,
.mountain {
  will-change: transform;
}
.cloud {
  position: absolute;
  width: 200px;
  height: 60px;
  background: var(--color-cloud);
  border-radius: 60px;
  opacity: 0.5;
}
.cloud::before,
.cloud::after {
  content: "";
  position: absolute;
  background: var(--color-cloud);
  border-radius: 50%;
}
.cloud::before {
  width: 100px;
  height: 100px;
  top: -50px;
  left: 40px;
}
.cloud::after {
  width: 120px;
  height: 120px;
  top: -70px;
  right: 30px;
}
.cloud-1 {
  top: 15%;
  right: -200px;
  animation: drift 80s linear infinite;
}
.cloud-2 {
  top: 25%;
  right: -200px;
  animation: drift 120s linear infinite 10s;
}
.mountain {
  position: absolute;
  bottom: -50px;
  width: 120%;
  height: 40%;
  border-radius: 50% 50% 0 0;
}
.mountain-far {
  background-color: var(--color-mountain-far);
  left: -10%;
  z-index: 10;
}
.mountain-mid {
  background-color: var(--color-mountain-mid);
  left: 0%;
  bottom: -100px;
  z-index: 11;
}
.mountain-near {
  background-color: var(--color-mountain-near);
  left: -5%;
  bottom: -200px;
  z-index: 12;
}
.sun[data-speed] {
  data-speed: 0.1;
}
.mountain-far[data-speed] {
  data-speed: 0.2;
}
.mountain-mid[data-speed] {
  data-speed: 0.4;
}
.mountain-near[data-speed] {
  data-speed: 0.6;
}
@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}
@keyframes drift {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-150vw);
  }
}

/* --- Structure commune --- */
.site-header,
.breadcrumb,
.category-section,
.site-footer,
.hero-section,
.auth-form,
.post-item,
.profile-header {
  background: var(--color-surface);
  backdrop-filter: blur(10px);
  border: 1px solid var(--color-border);
  border-radius: 12px;
}
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  margin-bottom: 24px;
}
.logo-link {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.5rem;
  font-weight: 700;
}
.logo {
  height: 32px;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}
.nav-link.active {
  font-weight: 700;
}
.breadcrumb {
  padding: 12px 24px;
  margin-bottom: 32px;
  font-size: 0.9rem;
  font-weight: 500;
}
.breadcrumb a {
  color: var(--color-text-subtle);
}
.breadcrumb .separator {
  margin: 0 8px;
  color: var(--color-text-subtle);
}
.page-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 24px;
}
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}
.nav-button {
  background-color: var(--color-mountain-near);
  color: var(--color-text-light);
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 600;
  border: none;
}
.nav-button:hover {
  background-color: var(--color-text);
}
.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 32px;
  padding: 32px;
  margin-top: 32px;
  color: var(--color-text-subtle);
  font-size: 0.9rem;
}
.footer-column h4 {
  color: var(--color-text);
  font-weight: 600;
  margin-bottom: 8px;
}
.footer-column a {
  color: var(--color-text-subtle);
  display: block;
  padding: 4px 0;
  font-weight: 400;
}
.footer-column a:hover {
  color: var(--color-text);
}

/* --- Contenu spécifique --- */
.hero-section {
  position: relative;
  padding: 64px 48px;
  overflow: hidden;
  text-align: center;
  color: var(--color-text-light);
}
.hero-background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  opacity: 0.8;
}
.hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    45deg,
    var(--color-hero-overlay-start),
    var(--color-hero-overlay-end)
  );
  z-index: -1;
}
.hero-content {
  position: relative;
  z-index: 2;
}
.hero-content h1 {
  font-size: 3rem;
  font-weight: 700;
  text-shadow: 1px 1px 10px var(--color-hero-text-shadow);
}
.hero-content p {
  font-size: 1.2rem;
  opacity: 0.9;
}
.category-section {
  padding: 32px;
  margin-bottom: 32px;
}
.category-section h2 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--color-border);
}
.thread-list {
  display: flex;
  flex-direction: column;
}
.thread-item {
  position: relative;
  padding: 16px 0;
  border-bottom: 1px solid var(--color-border);
}
.thread-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.thread-item:hover .thread-title a {
  color: var(--color-mountain-near);
}
.thread-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 4px;
}
.thread-link-cover {
  transition: color 0.2s ease;
}
.thread-link-cover::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
}
.thread-meta {
  font-size: 0.9rem;
  color: var(--color-text-subtle);
}
.thread-meta a {
  position: relative;
  z-index: 2;
  color: var(--color-text);
}
.thread-meta a:hover {
  color: var(--color-mountain-near);
}
.category-list-full .category-item-full {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px;
  margin-bottom: 16px;
  border-radius: 12px;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  backdrop-filter: blur(10px);
  text-decoration: none;
}
.post-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.post-item {
  display: flex;
  gap: 16px;
  padding: 24px;
}
.post-author {
  flex-shrink: 0;
  text-align: center;
  width: 120px;
}
.post-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  margin-bottom: 8px;
}
.author-name {
  font-weight: 600;
}
.profile-header {
  padding: 32px;
  text-align: center;
  margin-bottom: 32px;
}
.profile-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  margin-bottom: 16px;
}
.profile-header h1 {
  font-size: 2.2rem;
  font-weight: 700;
}
.auth-container {
  max-width: 450px;
  margin: 64px auto;
}
.auth-form {
  padding: 32px;
  text-align: center;
}
.auth-form h2 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 24px;
}
.form-group {
  margin-bottom: 16px;
  text-align: left;
}
.form-group label {
  font-weight: 600;
  margin-bottom: 4px;
  display: block;
}
.form-group input {
  width: 100%;
  padding: 12px;
  border-radius: 6px;
  border: 1px solid var(--color-border);
  background: var(--color-surface-input);
  font-family: var(--font-main);
}
.auth-form .nav-button {
  width: 100%;
  padding: 12px;
  font-size: 1rem;
}
.auth-switch {
  text-align: center;
  margin-top: 24px;
  font-size: 0.9rem;
  color: var(--color-text-subtle);
}
.auth-switch a {
  color: var(--color-text);
  text-decoration: underline;
}

/* .forum-item {
    display: grid;
    grid-template-columns: 48px minmax(0, 3fr) minmax(0, 1.5fr) minmax(0, 1fr) minmax(0, 1.5fr);
    gap: 16px;
    align-items: center;
    padding: 16px;
}

.forum-item:first-of-type {
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}
.forum-item:last-of-type {
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
    margin-bottom: 0;
}
.forum-item:only-of-type {
    border-radius: 8px;
} */

.forum-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: block;
}

/* .forum-subject {
    font-size: 1.1rem;
    font-weight: 700;
    text-decoration: none;
    line-height: 1.4;
}
.forum-subject:hover {
    text-decoration: underline;
}

.forum-author,
.forum-messages,
.forum-last-message {
    font-size: 0.9rem;
}

.forum-author a {
    font-weight: 600;
    text-decoration: none;
}
.forum-author a:hover {
    text-decoration: underline;
}

.forum-messages {
    text-align: center;
}

.forum-last-message {
    text-align: right;
    white-space: nowrap;
} */
