/* leopophasca.com — Companion Journal + Slow Living Archive */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Georgia, 'Times New Roman', serif;
  color: #222222;
  line-height: 1.75;
  font-size: 1.05rem;
  background-image:
    linear-gradient(rgba(247, 245, 242, 0.86), rgba(247, 245, 242, 0.86)),
    url('../images/background_companion_memory.jpg');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: url('../images/background_paper_texture.jpg');
  opacity: 0.05;
  pointer-events: none;
  z-index: -1;
}

/* Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(154, 183, 201, 0.25);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.04);
}

.nav-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-logo {
  font-size: 1.15rem;
  font-weight: normal;
  letter-spacing: 0.04em;
  color: #222222;
  text-decoration: none;
}

.site-logo:hover {
  color: #9ab7c9;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 1.75rem;
}

.nav-menu a {
  color: #222222;
  text-decoration: none;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  position: relative;
  padding-bottom: 2px;
}

.nav-menu a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: #9ab7c9;
  transition: width 0.3s ease;
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
  width: 100%;
}

.nav-menu a:hover,
.nav-menu a.active {
  color: #9ab7c9;
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #222222;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Layout */
.page-wrapper,
.article-container,
.contact-container,
.privacy-container {
  background: rgba(255, 255, 255, 0.74);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

.page-wrapper {
  max-width: 780px;
  margin: 2.5rem auto;
  padding: 3rem 2.5rem;
}

.article-container,
.contact-container,
.privacy-container {
  max-width: 720px;
  margin: 2.5rem auto;
  padding: 3rem 2.5rem;
}

/* Typography */
h1 {
  font-size: 2rem;
  font-weight: normal;
  line-height: 1.3;
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

h2 {
  font-size: 1.45rem;
  font-weight: normal;
  margin: 2.5rem 0 1.25rem;
  color: #222222;
  letter-spacing: 0.01em;
}

h3 {
  font-size: 1.15rem;
  font-weight: normal;
  margin: 1.5rem 0 0.75rem;
}

p {
  margin-bottom: 1.25rem;
}

.intro-italic {
  font-style: italic;
  color: #444444;
  margin-bottom: 2rem;
  font-size: 1.1rem;
  line-height: 1.7;
}

a {
  color: #222222;
  text-decoration: underline;
  text-decoration-color: rgba(154, 183, 201, 0.5);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.3s ease, color 0.3s ease;
}

a:hover {
  color: #9ab7c9;
  text-decoration-color: #9ab7c9;
}

/* Homepage sections */
.journal-section {
  margin-bottom: 3rem;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.journal-section.visible {
  opacity: 1;
  transform: translateY(0);
}

.section-divider {
  border: none;
  border-top: 1px solid rgba(154, 183, 201, 0.3);
  margin: 3rem 0;
}

/* Blog Dashboard */
.blog-dashboard {
  margin-top: 1rem;
}

.blog-dashboard h2 {
  text-align: center;
  margin-bottom: 2rem;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.blog-card {
  background: rgba(255, 255, 255, 0.74);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
  padding: 1.75rem;
  text-decoration: none;
  color: #222222;
  display: block;
  transition: transform 0.35s ease, box-shadow 0.35s ease, background 0.35s ease;
  border: 1px solid rgba(154, 183, 201, 0.15);
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 0.88);
  color: #222222;
  text-decoration: none;
}

.blog-card h3 {
  margin: 0 0 0.75rem;
  font-size: 1.1rem;
  color: #222222;
}

.blog-card .excerpt {
  font-size: 0.92rem;
  color: #555555;
  line-height: 1.65;
  margin: 0;
}

.blog-card .read-more {
  display: inline-block;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: #9ab7c9;
  text-decoration: none;
}

.blog-card:hover .read-more {
  text-decoration: underline;
}

/* Article page */
.article-meta {
  font-size: 0.9rem;
  color: #777777;
  margin-bottom: 2rem;
}

.article-body p {
  text-align: left;
}

.related-articles {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(154, 183, 201, 0.3);
}

.related-articles h2 {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.related-articles ul {
  list-style: none;
  padding: 0;
}

.related-articles li {
  margin-bottom: 0.6rem;
}

.return-link {
  display: inline-block;
  margin-top: 2.5rem;
  font-style: italic;
}

/* Contact */
.contact-details {
  margin: 2rem 0;
  padding: 1.5rem;
  background: rgba(247, 245, 242, 0.5);
  border-radius: 12px;
  border-left: 3px solid #9ab7c9;
}

.contact-details p {
  margin-bottom: 0.5rem;
}

.contact-form {
  margin-top: 2.5rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.95rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: Georgia, serif;
  font-size: 1rem;
  border: 1px solid rgba(154, 183, 201, 0.4);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.8);
  color: #222222;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #9ab7c9;
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.btn-submit {
  background: #9ab7c9;
  color: #ffffff;
  border: none;
  padding: 0.75rem 2rem;
  font-family: Georgia, serif;
  font-size: 1rem;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
}

.btn-submit:hover {
  background: #7a9bb0;
  transform: translateY(-1px);
}

/* Privacy */
.privacy-container h2 {
  margin-top: 2rem;
}

.privacy-container h2:first-of-type {
  margin-top: 1rem;
}

/* Footer */
.site-footer {
  text-align: center;
  padding: 2rem 1.5rem 3rem;
  font-size: 0.85rem;
  color: #666666;
}

.site-footer a {
  color: #666666;
}

/* Fade-in for articles */
.fade-in {
  opacity: 0;
  transform: translateY(12px);
  animation: fadeInUp 0.8s ease forwards;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Mobile */
@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 57px;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    flex-direction: column;
    align-items: center;
    padding: 1.5rem 0;
    gap: 1.25rem;
    transform: translateY(-120%);
    opacity: 0;
    transition: transform 0.35s ease, opacity 0.35s ease;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  }

  .nav-menu.open {
    transform: translateY(0);
    opacity: 1;
  }

  .page-wrapper,
  .article-container,
  .contact-container,
  .privacy-container {
    margin: 1.25rem;
    padding: 2rem 1.5rem;
  }

  h1 {
    font-size: 1.6rem;
  }

  body {
    background-attachment: scroll;
  }

  .blog-grid {
    grid-template-columns: 1fr;
  }
}
