/* ============================================
   Lit(e)Lat - Red de Literatura Electrónica Latinoamericana
   Brand colors: Black (#1a1a1a), White (#fff), Orange (#E8622C)
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.7;
  color: #1a1a1a;
  background: #f5f5f5;
}

a {
  color: #E8622C;
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: #c24e1e;
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* --- Header --- */
.site-header {
  background: #1a1a1a;
  color: #fff;
  padding: 0;
  border-bottom: 4px solid #E8622C;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  padding-top: 12px;
  padding-bottom: 12px;
}

.site-branding {
  flex-shrink: 0;
}

.site-title-link {
  text-decoration: none;
}

.site-logo {
  height: 50px;
  width: auto;
  display: block;
}

.site-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.5px;
}

.site-title-link:hover .site-logo {
  opacity: 0.85;
}

.site-description {
  color: #999;
  font-size: 0.82rem;
  margin-top: 2px;
}

/* --- Navigation --- */
.main-navigation ul {
  list-style: none;
  display: flex;
  gap: 0;
  flex-wrap: wrap;
}

.main-navigation li a {
  display: block;
  padding: 8px 16px;
  color: #ccc;
  font-size: 0.85rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: background 0.2s, color 0.2s;
}

.main-navigation li a:hover {
  color: #E8622C;
  background: rgba(232, 98, 44, 0.08);
  text-decoration: none;
}

.menu-toggle {
  display: none;
  background: none;
  border: 1px solid #555;
  color: #ccc;
  padding: 8px 14px;
  font-size: 0.9rem;
  cursor: pointer;
  border-radius: 3px;
}

.menu-toggle:hover {
  border-color: #E8622C;
  color: #E8622C;
}

/* --- Content Area --- */
.site-content {
  padding: 30px 0;
}

.content-area {
  max-width: 820px;
  margin: 0 auto;
}

/* ============================================
   FEATURED POST (most recent, shown in full)
   ============================================ */
.featured-post {
  background: #fff;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  margin-bottom: 35px;
}

.featured-label {
  background: #E8622C;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 6px 20px;
}

.featured-post-image img {
  width: 100%;
  max-height: 400px;
  object-fit: cover;
  display: block;
}

.featured-post-title {
  font-size: 1.6rem;
  line-height: 1.3;
  padding: 25px 30px 0;
}

.featured-post-title a {
  color: #1a1a1a;
}

.featured-post-title a:hover {
  color: #E8622C;
  text-decoration: none;
}

.featured-post .entry-meta {
  padding: 8px 30px 0;
}

.featured-post-content {
  padding: 20px 30px 25px;
}

.featured-post-link {
  padding: 0 30px 25px;
}

.featured-post-link a {
  font-size: 0.88rem;
  font-weight: 600;
  color: #E8622C;
}

.featured-post-link a:hover {
  text-decoration: underline;
}

/* ============================================
   POST LIST - Compact with thumbnails
   ============================================ */
.post-list-heading {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #888;
  margin-bottom: 15px;
  padding-bottom: 8px;
  border-bottom: 2px solid #E8622C;
}

.post-list-compact {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.post-list-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 12px 15px;
  background: #fff;
  border-bottom: 1px solid #eee;
  transition: background 0.15s;
  text-decoration: none;
  color: inherit;
}

.post-list-item:first-child {
  border-radius: 6px 6px 0 0;
}

.post-list-item:last-child {
  border-bottom: none;
  border-radius: 0 0 6px 6px;
}

.post-list-item:only-child {
  border-radius: 6px;
}

.post-list-item:hover {
  background: #fdf5f1;
  text-decoration: none;
}

.post-list-thumb {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 4px;
  overflow: hidden;
  background: #eee;
}

.post-list-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.post-list-thumb-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #E8622C 0%, #f0a070 100%);
  opacity: 0.2;
}

.post-list-info {
  flex: 1;
  min-width: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.post-list-title {
  font-size: 0.92rem;
  font-weight: 500;
  color: #1a1a1a;
  line-height: 1.4;
}

.post-list-item:hover .post-list-title {
  color: #E8622C;
}

.post-list-date {
  font-size: 0.78rem;
  color: #999;
  white-space: nowrap;
  flex-shrink: 0;
  font-family: monospace;
}

/* ============================================
   PAGINATION
   ============================================ */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  padding-top: 20px;
}

.pagination-link {
  display: inline-block;
  padding: 8px 18px;
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: 4px;
  transition: all 0.2s;
}

.pagination-prev,
.pagination-next {
  background: #1a1a1a;
  color: #fff;
}

.pagination-prev:hover,
.pagination-next:hover {
  background: #E8622C;
  color: #fff;
  text-decoration: none;
}

.pagination-info {
  font-size: 0.85rem;
  color: #999;
  font-weight: 600;
}

.pagination-disabled {
  background: #ddd;
  color: #aaa;
  cursor: default;
  pointer-events: none;
}

/* ============================================
   SINGLE POST
   ============================================ */
.single-post {
  background: #fff;
  border-radius: 6px;
  padding: 35px 40px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.entry-header {
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 2px solid #f0f0f0;
}

.entry-header .entry-title {
  font-size: 1.8rem;
  line-height: 1.3;
  color: #1a1a1a;
  margin-bottom: 10px;
}

.entry-meta {
  font-size: 0.83rem;
  color: #999;
}

.entry-meta a {
  color: #999;
}

.entry-meta a:hover {
  color: #E8622C;
}

.featured-image {
  margin-bottom: 25px;
}

.featured-image img {
  border-radius: 4px;
  width: 100%;
}

/* --- Entry Content --- */
.entry-content {
  font-size: 1rem;
  line-height: 1.8;
  color: #333;
}

.entry-content p {
  margin-bottom: 1.2em;
}

.entry-content h2 {
  font-size: 1.4rem;
  margin-top: 1.8em;
  margin-bottom: 0.6em;
  color: #1a1a1a;
}

.entry-content h3 {
  font-size: 1.2rem;
  margin-top: 1.5em;
  margin-bottom: 0.5em;
  color: #333;
}

.entry-content ul, .entry-content ol {
  margin-bottom: 1.2em;
  padding-left: 1.8em;
}

.entry-content li {
  margin-bottom: 0.3em;
}

.entry-content blockquote {
  border-left: 4px solid #E8622C;
  padding: 10px 20px;
  margin: 1.5em 0;
  background: #fdf5f1;
  font-style: italic;
  color: #555;
}

.entry-content img {
  border-radius: 4px;
  margin: 1em 0;
}

.entry-content iframe {
  max-width: 100%;
  margin: 1em 0;
}

.entry-content figure {
  margin: 1.5em 0;
}

.entry-content figcaption {
  font-size: 0.85rem;
  color: #999;
  text-align: center;
  margin-top: 5px;
}

.entry-content a {
  color: #E8622C;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.entry-content a:hover {
  color: #c24e1e;
}

/* --- Original Link --- */
.original-link {
  margin-top: 30px;
  padding-top: 15px;
  border-top: 1px solid #eee;
  color: #999;
}

/* --- Post Navigation --- */
.post-navigation {
  display: flex;
  justify-content: space-between;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 2px solid #f0f0f0;
  font-size: 0.88rem;
}

.nav-previous, .nav-next {
  max-width: 45%;
}

.nav-next {
  text-align: right;
  margin-left: auto;
}

.nav-previous a, .nav-next a {
  color: #E8622C;
  font-weight: 500;
}

/* ============================================
   PAGE
   ============================================ */
.page {
  background: #fff;
  border-radius: 6px;
  padding: 35px 40px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.page .entry-header {
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 2px solid #f0f0f0;
}

.page .entry-title {
  font-size: 1.8rem;
  color: #1a1a1a;
}

/* ============================================
   ARCHIVE
   ============================================ */
.archive-year {
  font-size: 1.2rem;
  color: #1a1a1a;
  margin-top: 30px;
  margin-bottom: 10px;
  padding-bottom: 5px;
  border-bottom: 2px solid #E8622C;
}

.archive-posts {
  list-style: none;
  padding: 0;
}

.archive-posts li {
  padding: 6px 0;
  border-bottom: 1px solid #f0f0f0;
  display: flex;
  gap: 15px;
  align-items: baseline;
}

.archive-posts time {
  font-size: 0.82rem;
  color: #999;
  font-family: monospace;
  flex-shrink: 0;
  width: 45px;
}

.archive-posts a {
  color: #1a1a1a;
}

.archive-posts a:hover {
  color: #E8622C;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: #1a1a1a;
  color: #999;
  padding: 30px 0;
  margin-top: 40px;
  text-align: center;
  font-size: 0.85rem;
}

.site-footer a {
  color: #E8622C;
}

.site-footer a:hover {
  color: #f0a070;
}

.footer-note {
  margin-top: 5px;
  font-size: 0.78rem;
  color: #666;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .menu-toggle {
    display: block;
    margin-top: 10px;
  }

  .header-right {
    width: 100%;
    align-items: flex-start;
  }

  .main-navigation {
    display: none;
    width: 100%;
  }

  .main-navigation.toggled {
    display: block;
  }

  .main-navigation ul {
    flex-direction: column;
  }

  .main-navigation li a {
    padding: 10px 0;
    border-top: 1px solid #333;
  }

  .single-post, .page {
    padding: 20px;
  }

  .entry-header .entry-title {
    font-size: 1.4rem;
  }

  .featured-post-title {
    font-size: 1.3rem;
    padding: 20px 20px 0;
  }

  .featured-post .entry-meta {
    padding: 8px 20px 0;
  }

  .featured-post-content {
    padding: 15px 20px 20px;
  }

  .featured-post-link {
    padding: 0 20px 20px;
  }

  .post-list-info {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }

  .post-navigation {
    flex-direction: column;
    gap: 15px;
  }

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

  .pagination {
    gap: 10px;
  }

  .pagination-link {
    padding: 6px 12px;
    font-size: 0.82rem;
  }
}

/* ============================================
   WORDPRESS CONTENT COMPATIBILITY
   ============================================ */
.wp-block-image,
.wp-block-embed {
  margin: 1.5em 0;
}

.aligncenter {
  display: block;
  margin: 1em auto;
  text-align: center;
}

.alignleft {
  float: left;
  margin: 0 1.5em 1em 0;
}

.alignright {
  float: right;
  margin: 0 0 1em 1.5em;
}

.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 1.5em 0;
}

.gallery-item {
  flex: 1 1 200px;
}

.gallery-item img {
  width: 100%;
  height: auto;
}

.wp-caption {
  max-width: 100%;
  margin: 1em 0;
}

.wp-caption-text {
  font-size: 0.85rem;
  color: #999;
  text-align: center;
  padding: 5px 0;
}

/* --- Header Right (nav + lang switcher) --- */
.header-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

/* --- Language Switcher --- */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
}

.lang-option {
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 3px 8px;
  border-radius: 3px;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.lang-option:hover {
  background: #E8622C;
  color: #fff;
  text-decoration: none;
}

.lang-option.active {
  background: #E8622C;
  color: #fff;
}

.lang-divider {
  color: #666;
  font-size: 0.8rem;
}

/* --- Landing Page --- */
.landing-page {
  text-align: center;
  padding: 80px 20px;
  max-width: 600px;
  margin: 0 auto;
}

.landing-logo {
  max-width: 300px;
  margin-bottom: 30px;
}

.landing-subtitle {
  font-size: 1.1rem;
  color: #555;
  margin-bottom: 40px;
  line-height: 1.8;
}

.landing-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.landing-btn {
  display: inline-block;
  padding: 14px 40px;
  font-size: 1.1rem;
  font-weight: 600;
  border-radius: 5px;
  text-decoration: none;
  transition: all 0.2s;
  background: #1a1a1a;
  color: #fff;
}

.landing-btn:hover {
  background: #E8622C;
  color: #fff;
  text-decoration: none;
}

/* --- Translation Link --- */
.translation-link {
  margin: 20px 0;
  padding: 12px 20px;
  background: #f0f0f0;
  border-left: 4px solid #E8622C;
  border-radius: 3px;
}

.translation-link a {
  font-weight: 600;
  text-decoration: none;
}

@media (max-width: 768px) {
  .lang-switcher {
    margin-left: 0;
    margin-top: 10px;
    justify-content: center;
  }

  .landing-buttons {
    flex-direction: column;
    align-items: center;
  }

  .landing-btn {
    width: 200px;
    text-align: center;
  }
}
