/* ═══════════════════════════════════════════════════
   ZONA ZERO — Editorial Music Archive
   Dark theme
═══════════════════════════════════════════════════ */

:root {
  --bg:            #0b0b0b;
  --bg-noise:      #0f0f0f;
  --surface:       #141414;
  --surface-2:     #1c1c1c;
  --border:        #242424;
  --border-bright: #333;

  --text:          #ebebeb;
  --text-dim:      #999;
  --text-faint:    #555;

  --red:     #e63946;
  --red-dim: rgba(230, 57, 70, 0.18);
  --blue:    #4ea8de;
  --blue-dim:rgba(78, 168, 222, 0.18);
  --gold:    #f4a261;
  --gold-dim:rgba(244, 162, 97, 0.18);

  --font-display: 'Bebas Neue', Impact, sans-serif;
  --font-ui:      'Oswald', 'Arial Narrow', sans-serif;
  --font-body:    'Source Serif 4', Georgia, 'Times New Roman', serif;

  --radius:   2px;
  --shadow:   0 16px 48px rgba(0,0,0,0.6);
}

/* ─── Reset ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
button { cursor: pointer; }
a { color: inherit; }

/* ─── Header ─────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(11, 11, 11, 0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 2rem;
  height: 70px;
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

/* Logo */
.logo-area {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.logo-wordmark {
  font-family: var(--font-display);
  font-size: 2.4rem;
  line-height: 1;
  letter-spacing: 0.04em;
}

.logo-zona { color: var(--text-dim); }
.logo-zero { color: var(--red); }

.logo-meta {
  display: flex;
  flex-direction: column;
  border-left: 1px solid var(--border-bright);
  padding-left: 1rem;
  gap: 0.1rem;
}

.logo-tagline {
  font-family: var(--font-ui);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.logo-years {
  font-family: var(--font-ui);
  font-size: 0.6rem;
  font-weight: 300;
  letter-spacing: 0.12em;
  color: var(--text-faint);
}

/* Search */
.search-area {
  position: relative;
  flex: 1;
  max-width: 520px;
}

.search-icon {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--text-faint);
  pointer-events: none;
}

.search-area input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 0.88rem;
  font-weight: 300;
  letter-spacing: 0.04em;
  padding: 0.65rem 2.5rem 0.65rem 2.6rem;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.search-area input:focus {
  background: var(--surface-2);
  border-color: var(--red);
}

.search-area input::placeholder { color: var(--text-faint); }

.search-clear {
  position: absolute;
  right: 0.7rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-faint);
  font-size: 0.75rem;
  padding: 0.2rem 0.4rem;
  transition: color 0.2s;
}
.search-clear:hover { color: var(--text); }

/* ─── Filter Bar ─────────────────────────────────── */
.filter-bar {
  position: sticky;
  top: 70px;
  z-index: 199;
  background: rgba(14, 14, 14, 0.97);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.filter-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  overflow-x: auto;
  scrollbar-width: none;
}
.filter-inner::-webkit-scrollbar { display: none; }

.filter-btn {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  color: var(--text-dim);
  font-family: var(--font-ui);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  padding: 0.95rem 1.4rem;
  text-transform: uppercase;
  transition: color 0.2s, border-color 0.2s;
  white-space: nowrap;
}

.filter-btn:hover { color: var(--text); }
.filter-btn.active { color: var(--text); border-bottom-color: var(--red); }

.btn-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dot-resena    { background: var(--red); }
.dot-cronica   { background: var(--blue); }
.dot-entrevista{ background: var(--gold); }
.dot-rockzone  { background: #e8b4f0; }

.badge {
  background: var(--border);
  border-radius: 20px;
  font-size: 0.68rem;
  font-weight: 400;
  padding: 0.1rem 0.55rem;
  color: var(--text-dim);
}

/* ─── Results Bar ─────────────────────────────────── */
.results-bar {
  border-bottom: 1px solid var(--border);
  background: var(--bg-noise);
}

.results-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0.5rem 2rem;
}

.results-label {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  text-transform: uppercase;
}

/* ─── Main Grid ──────────────────────────────────── */
main {
  max-width: 1440px;
  margin: 0 auto;
  padding: 2rem;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 1.25rem;
}

/* ─── Cards ─────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  transition: transform 0.18s ease, border-color 0.18s, box-shadow 0.18s;
}

/* Colored left stripe */
.card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
}

.card.card-resena::before    { background: var(--red); }
.card.card-cronica::before   { background: var(--blue); }
.card.card-entrevista::before{ background: var(--gold); }

.card:hover {
  border-color: var(--border-bright);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.card:hover .card-title { color: var(--red); }
.card.card-cronica:hover .card-title { color: var(--blue); }
.card.card-entrevista:hover .card-title { color: var(--gold); }

/* ─── Card cover art ─────────────────────────────── */
.card-art {
  width: 100%;
  height: 160px;
  overflow: hidden;
  flex-shrink: 0;
}

.card-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Placeholder shown when no cover art / image fails */
.card-art-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
}

.ph-resena    { background: var(--red-dim); }
.ph-cronica   { background: var(--blue-dim); }
.ph-entrevista{ background: var(--gold-dim); }

.ph-initial {
  font-family: var(--font-display);
  font-size: 2.8rem;
  line-height: 1;
  opacity: 0.5;
}
.ph-resena    .ph-initial { color: var(--red); }
.ph-cronica   .ph-initial { color: var(--blue); }
.ph-entrevista .ph-initial { color: var(--gold); }

.ph-label {
  font-family: var(--font-ui);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.45;
}

/* ─── Card info area ─────────────────────────────── */
.card-info {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 0.85rem 1.1rem 0 1.2rem;
}

.type-pill {
  font-family: var(--font-ui);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  padding: 0.2rem 0.55rem;
  border-radius: 2px;
  text-transform: uppercase;
  align-self: flex-start;
}

/* Wrapper for type pill + optional RockZone badge */
.card-pills {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.65rem;
}

.type-pill.pill-resena {
  background: var(--red-dim);
  color: var(--red);
  border: 1px solid rgba(230,57,70,0.3);
}
.type-pill.pill-cronica {
  background: var(--blue-dim);
  color: var(--blue);
  border: 1px solid rgba(78,168,222,0.3);
}
.type-pill.pill-entrevista {
  background: var(--gold-dim);
  color: var(--gold);
  border: 1px solid rgba(244,162,97,0.3);
}

/* RockZone badge */
.rz-badge {
  font-family: var(--font-ui);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  padding: 0.2rem 0.55rem;
  border-radius: 2px;
  text-transform: uppercase;
  background: rgba(232,180,240,0.15);
  color: #e8b4f0;
  border: 1px solid rgba(232,180,240,0.35);
}

.card-title {
  font-family: var(--font-ui);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.25;
  margin-bottom: 0.25rem;
  text-transform: uppercase;
  transition: color 0.18s;
}

.card-subtitle {
  color: var(--text-faint);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-style: italic;
  margin-bottom: 0.7rem;
  line-height: 1.3;
}

.card-excerpt {
  color: var(--text-dim);
  font-size: 0.8rem;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

/* Card footer: pushed to bottom */
.card-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  border-top: 1px solid var(--border);
  margin-top: 0.85rem;
  padding: 0.55rem 0;
}

.card-cta {
  font-family: var(--font-ui);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
  transition: color 0.18s;
}

.card:hover .card-cta { color: var(--text-dim); }

/* ─── No Results ─────────────────────────────────── */
.no-results {
  padding: 5rem 2rem;
  text-align: center;
}

.no-results-inner {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.no-results-icon {
  font-size: 2.5rem;
  color: var(--border-bright);
}

.no-results p {
  font-family: var(--font-ui);
  font-size: 1rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  text-transform: uppercase;
}

.no-results button {
  background: none;
  border: 1px solid var(--border-bright);
  border-radius: var(--radius);
  color: var(--text-dim);
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  padding: 0.6rem 1.2rem;
  text-transform: uppercase;
  transition: border-color 0.2s, color 0.2s;
}
.no-results button:hover { border-color: var(--red); color: var(--red); }

.hidden { display: none !important; }

/* ─── Modal ─────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  z-index: 1000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  overflow-y: auto;
  padding: 3rem 1.5rem 5rem;
  backdrop-filter: blur(6px);
}

.modal {
  background: var(--surface);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius);
  max-width: 720px;
  width: 100%;
  margin: auto;
  position: relative;
  box-shadow: var(--shadow);
  animation: modal-in 0.22s ease;
  overflow: visible;
}

@keyframes modal-in {
  from { opacity: 0; transform: translateY(24px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* Close button */
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(0,0,0,0.45);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 50%;
  color: var(--text-dim);
  width: 2.1rem;
  height: 2.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.modal-close:hover { border-color: var(--red); color: var(--red); background: var(--red-dim); }
.modal-close svg { width: 14px; height: 14px; }

/* Cover image */
.modal-cover {
  width: 100%;
  height: 260px;
  overflow: hidden;
  flex-shrink: 0;
}
.modal-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}
.modal-cover-placeholder {
  width: 100%;
  height: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

/* Header */
.modal-header {
  padding: 2rem 2.5rem 1.75rem;
  border-bottom: 1px solid var(--border);
  position: relative;
}

/* Colored top bar */
.modal-header::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
}
.modal-header.modal-resena::before    { background: var(--red); }
.modal-header.modal-cronica::before   { background: var(--blue); }
.modal-header.modal-entrevista::before{ background: var(--gold); }

.modal-type {
  display: inline-block;
  font-family: var(--font-ui);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 0.25rem 0.7rem;
  border-radius: 2px;
  margin-bottom: 1rem;
}
.modal-type.pill-resena    { background: var(--red-dim);  color: var(--red);  border: 1px solid rgba(230,57,70,0.3); }
.modal-type.pill-cronica   { background: var(--blue-dim); color: var(--blue); border: 1px solid rgba(78,168,222,0.3); }
.modal-type.pill-entrevista{ background: var(--gold-dim); color: var(--gold); border: 1px solid rgba(244,162,97,0.3); }

.modal-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 5vw, 3rem);
  letter-spacing: 0.04em;
  line-height: 1;
  margin-bottom: 0.75rem;
  color: var(--text);
}

.modal-subtitle {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-style: italic;
  color: var(--text-dim);
  line-height: 1.45;
}

/* Body */
.modal-body {
  padding: 2rem 2.5rem 2.5rem;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.9;
  color: var(--text-dim);
  overflow-wrap: break-word;
  word-break: break-word;
}

.modal-body p {
  margin-bottom: 1.5rem;
}
.modal-body p:last-child { margin-bottom: 0; }

.modal-body h4 {
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 2.5rem 0 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border);
}

.modal-body h3 {
  font-family: var(--font-ui);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--text);
  margin: 2rem 0 0.6rem;
}

.modal-body h2, .modal-body h1 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.04em;
  color: var(--text);
  margin: 2.5rem 0 0.75rem;
}

.modal-body strong {
  color: var(--text);
  font-weight: 700;
}

.modal-body em {
  font-style: italic;
  color: var(--text);
}

.modal-body blockquote {
  border-left: 3px solid var(--border-bright);
  padding: 0.25rem 0 0.25rem 1.25rem;
  margin: 1.5rem 0;
  color: var(--text-faint);
  font-style: italic;
}

/* Share bar */
.modal-share {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2.5rem;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
}

.modal-share-btn {
  flex-shrink: 0;
  background: none;
  border: 1px solid var(--border-bright);
  border-radius: var(--radius);
  color: var(--text-dim);
  font-family: var(--font-ui);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  padding: 0.45rem 1rem;
  text-transform: uppercase;
  transition: border-color 0.2s, color 0.2s;
  cursor: pointer;
  white-space: nowrap;
}
.modal-share-btn:hover { border-color: var(--red); color: var(--red); }

.modal-share-url {
  font-family: var(--font-ui);
  font-size: 0.68rem;
  color: var(--text-faint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}

/* ─── Footer ─────────────────────────────────────── */
.site-footer {
  margin-top: 6rem;
  border-top: 1px solid var(--border);
  background: var(--bg-noise);
}

.footer-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 2.5rem 2rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.footer-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--red);
  letter-spacing: 0.1em;
}

.footer-sub {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 300;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.footer-credit {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-style: italic;
  color: var(--text-faint);
  margin-top: 0.3rem;
}

/* ─── Responsive ─────────────────────────────────── */
@media (max-width: 860px) {
  .header-inner {
    padding: 0 1rem;
    gap: 1rem;
  }

  .logo-meta { display: none; }

  .filter-bar { top: 70px; }
  .filter-btn { padding: 0.9rem 1rem; font-size: 0.75rem; }

  main { padding: 1.25rem; }
  .articles-grid { gap: 1rem; }

  .modal-overlay { padding: 0.75rem 0.5rem 3rem; }
  .modal-cover, .modal-cover-placeholder { height: 200px; }
  .modal-header { padding: 1.5rem 1.5rem 1.25rem; }
  .modal-body { padding: 1.5rem 1.5rem 2rem; font-size: 1rem; line-height: 1.85; }
  .modal-share { padding: 0.85rem 1.5rem; }
  .modal-title { font-size: 1.9rem; }
}

@media (max-width: 500px) {
  .articles-grid { grid-template-columns: 1fr; }
  .logo-wordmark { font-size: 1.9rem; }
  .modal-overlay { padding: 0 0 3rem; }
  .modal { border-left: none; border-right: none; border-radius: 0; }
  .modal-cover, .modal-cover-placeholder { height: 170px; }
  .modal-header { padding: 1.25rem 1.1rem 1rem; }
  .modal-body { padding: 1.25rem 1.1rem 1.75rem; font-size: 1rem; line-height: 1.8; }
  .modal-body p { margin-bottom: 1.25rem; }
  .modal-share { padding: 0.75rem 1.1rem; flex-wrap: wrap; }
  .modal-share-url { min-width: 0; width: 100%; }
}

/* ─── Loading state ──────────────────────────────── */
.loading-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 1.25rem;
}

.skeleton-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem;
  animation: pulse 1.4s ease-in-out infinite;
}

.skeleton-line {
  background: var(--surface-2);
  border-radius: 3px;
  margin-bottom: 0.6rem;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.5; }
}
