/* ═══════════════════════════════════════════════════════════════
   Vance Algeria Media — Global Styles
   Aesthetic: Editorial / Refined Press
   ═══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400;1,600&family=Source+Serif+4:ital,opsz,wght@0,8..60,300;0,8..60,400;0,8..60,600;1,8..60,300;1,8..60,400&family=DM+Sans:wght@300;400;500&display=swap');

:root {
  --bg:        #F7F4EE;
  --surface:   #FFFFFF;
  --border:    #D9D3C7;
  --border-lt: #EDE8DF;
  --ink:       #1A1612;
  --ink-2:     #4A3F35;
  --ink-3:     #8C7B6E;
  --accent:    #B5272B;
  --accent-2:  #1B3A5C;
  --gold:      #C9A84C;
  --font-head: 'Playfair Display', Georgia, serif;
  --font-body: 'Source Serif 4', Georgia, serif;
  --font-ui:   'DM Sans', system-ui, sans-serif;
  --radius:    4px;
  --shadow:    0 2px 16px rgba(26,22,18,0.08);
  --shadow-lg: 0 8px 40px rgba(26,22,18,0.14);
  --max-w:     1100px;
  --col:       680px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  min-height: 100vh;
}

/* ── Layout ── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 2rem; }
.col { max-width: var(--col); margin: 0 auto; }

/* ── Header ── */
.site-header {
  background: var(--surface);
  border-bottom: 3px solid var(--ink);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  max-width: var(--max-w);
  margin: 0 auto;
}

.site-logo {
  display: flex;
  flex-direction: column;
  gap: 0;
  text-decoration: none;
}

.logo-eyebrow {
  font-family: var(--font-ui);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.logo-name {
  font-family: var(--font-head);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.1;
}

.logo-name span { color: var(--ink); }

.header-date {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  text-align: right;
}

/* ── Hero rule ── */
.section-rule {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 2.5rem 0 2rem;
}

.section-rule::before,
.section-rule::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.section-rule h2 {
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}

/* ── Article Card ── */
.article-list { display: flex; flex-direction: column; gap: 0; }

.article-card {
  background: var(--surface);
  border: 1px solid var(--border-lt);
  border-bottom: none;
  padding: 2rem 2.5rem;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1.5rem;
  align-items: start;
  transition: background 0.15s ease;
  text-decoration: none;
  color: inherit;
}

.article-card:first-child { border-radius: var(--radius) var(--radius) 0 0; }
.article-card:last-child  { border-bottom: 1px solid var(--border-lt); border-radius: 0 0 var(--radius) var(--radius); }

.article-card:hover { background: #FDFAF5; }

.card-body { min-width: 0; }

.card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.card-date {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  text-transform: uppercase;
}

.card-dot {
  width: 3px; height: 3px;
  background: var(--border);
  border-radius: 50%;
}

.card-source {
  font-family: var(--font-ui);
  font-size: 11px;
  color: var(--accent);
  font-weight: 500;
  letter-spacing: 0.05em;
}

.card-title {
  font-family: var(--font-head);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--ink);
  margin-bottom: 0.6rem;
  transition: color 0.15s;
}

.article-card:hover .card-title { color: var(--accent-2); }

.card-excerpt {
  font-size: 0.95rem;
  color: var(--ink-2);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-image {
  width: 160px;
  height: 110px;
  object-fit: cover;
  border-radius: var(--radius);
  flex-shrink: 0;
  border: 1px solid var(--border-lt);
}

.card-arrow {
  align-self: center;
  color: var(--ink-3);
  font-size: 1.2rem;
  margin-left: 0.5rem;
}

/* ── Pagination ── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin: 3rem 0 4rem;
}

.page-btn {
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 500;
  padding: 0.6rem 1.5rem;
  border: 1.5px solid var(--ink);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  border-radius: var(--radius);
  letter-spacing: 0.05em;
  transition: all 0.15s;
}

.page-btn:hover:not(:disabled) { background: var(--ink); color: var(--surface); }
.page-btn:disabled { opacity: 0.3; cursor: not-allowed; }
.page-info { font-family: var(--font-ui); font-size: 12px; color: var(--ink-3); letter-spacing: 0.1em; }

/* ── Footer ── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
  text-align: center;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  text-transform: uppercase;
}

/* ── Article Page ── */
.article-page { padding: 3rem 0 5rem; }

.article-header {
  padding-bottom: 0;
  margin-bottom: 0;
}

.article-eyebrow {
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.article-title {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink);
  margin-bottom: 1rem;
}

.article-dateline {
  font-family: var(--font-ui);
  font-size: 13px;
  color: var(--ink-3);
}

.article-image {
  width: 100%;
  max-height: 480px;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
  border: 1px solid var(--border-lt);
}

.article-divider {
  border: none;
  border-top: 2px solid var(--border);
  margin: 1.5rem 0 2.5rem 0;
}

.article-body {
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--ink-2);
}

.article-body h1, .article-body h2, .article-body h3 {
  font-family: var(--font-head);
  color: var(--ink);
  margin: 2rem 0 0.75rem;
}

.article-body p { margin-bottom: 1.2rem; }
.article-body ul, .article-body ol { margin: 1rem 0 1rem 2rem; }
.article-body li { margin-bottom: 0.4rem; }
.article-body a { color: var(--accent-2); }
.article-body a[href] { target: _blank; }
.article-body img { max-width: 100%; height: auto; border-radius: var(--radius); margin: 1rem 0; display: block; }
.article-body blockquote {
  border-left: 3px solid var(--gold);
  padding-left: 1.5rem;
  color: var(--ink-2);
  font-style: italic;
  margin: 1.5rem 0;
}

.article-source-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 2rem;
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  text-decoration: none;
  margin-bottom: 2.5rem;
  transition: color 0.15s;
}

.back-link:hover { color: var(--ink); }

/* ── Loading skeleton ── */
.skeleton {
  background: linear-gradient(90deg, var(--border-lt) 25%, var(--border) 50%, var(--border-lt) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: var(--radius);
}

@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

.skeleton-card {
  height: 130px;
  margin-bottom: 1px;
}

/* ── Toast ── */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--ink);
  color: #fff;
  font-family: var(--font-ui);
  font-size: 13px;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 9999;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.25s cubic-bezier(.22,.68,0,1.2);
}

.toast.show { transform: translateY(0); opacity: 1; }
.toast.error { background: var(--accent); }

/* ── Responsive ── */
@media (max-width: 680px) {
  .header-inner { padding: 1rem; }
  .container { padding: 0 1rem; }
  .article-card {
    grid-template-columns: 1fr;
    padding: 1.5rem;
  }
  .card-image { width: 100%; height: 180px; }
}
