/* Guardian Source Design System Stylesheet for Powernews */

:root {
  --gu-brand: #052962;
  --gu-brand-text: #ffffff;
  --gu-kicker: #c70000;
  --gu-bg: #f6f6f6;
  --gu-card-bg: #ffffff;
  --gu-text: #121212;
  --gu-text-muted: #555555;
  --gu-border: #dcdcdc;
  --gu-highlight: #ffe500;
  --gu-callout-bg: #f0f4f8;
  --gu-callout-border: #052962;
  --gu-font-headline: "Georgia", "Times New Roman", serif;
  --gu-font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

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

body {
  background-color: var(--gu-bg);
  color: var(--gu-text);
  font-family: var(--gu-font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Header & Masthead */
header.gu-masthead {
  background-color: var(--gu-brand);
  color: var(--gu-brand-text);
  padding: 1.25rem 2rem;
  border-bottom: 4px solid var(--gu-kicker);
}

.gu-masthead-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

.gu-titlepiece {
  font-family: var(--gu-font-headline);
  font-size: 2.25rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: #ffffff;
  text-decoration: none;
}

.gu-date {
  font-size: 0.875rem;
  color: #c1d0e6;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Navigation Bar */
nav.gu-nav {
  background-color: #041f4a;
  padding: 0.5rem 2rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.gu-nav-list {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  max-width: 1200px;
  margin: 0 auto;
  overflow-x: auto;
}

.gu-nav-item a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.25rem 0;
}

.gu-nav-item a:hover {
  color: var(--gu-highlight);
}

/* Main Container */
main.gu-container {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 1.5rem;
}

/* Section Container & Headers */
.gu-section {
  margin-bottom: 3rem;
}

.gu-section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-bottom: 2px solid var(--gu-brand);
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
}

.gu-section-title {
  font-family: var(--gu-font-headline);
  font-size: 1.5rem;
  color: var(--gu-brand);
}

.gu-section-link {
  color: var(--gu-kicker);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.875rem;
}

.gu-section-link:hover {
  text-decoration: underline;
}

/* Grid & Cards */
.gu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem;
}

.gu-card {
  background: var(--gu-card-bg);
  border: 1px solid var(--gu-border);
  border-top: 3px solid var(--gu-brand);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.gu-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.1);
}

.gu-kicker {
  color: var(--gu-kicker);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.35rem;
}

.gu-headline {
  font-family: var(--gu-font-headline);
  font-size: 1.25rem;
  line-height: 1.35;
  margin-bottom: 0.75rem;
}

.gu-headline a {
  color: var(--gu-text);
  text-decoration: none;
}

.gu-headline a:hover {
  color: var(--gu-brand);
}

.gu-byline {
  font-size: 0.8rem;
  color: var(--gu-text-muted);
  margin-top: auto;
}

/* Article Detail Page (Guardian Long-Read Format) */
.gu-article {
  background: #ffffff;
  border: 1px solid var(--gu-border);
  padding: 3rem 3.5rem;
  max-width: 900px;
  margin: 0 auto;
  box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.gu-article-header {
  margin-bottom: 2rem;
  border-bottom: 2px solid var(--gu-brand);
  padding-bottom: 1.75rem;
}

.gu-article-title {
  font-family: var(--gu-font-headline);
  font-size: 2.65rem;
  line-height: 1.18;
  margin: 0.5rem 0 1rem;
  color: #0b0b0b;
}

.gu-lead {
  font-size: 1.2rem;
  font-weight: 500;
  color: #2b2b2b;
  line-height: 1.65;
  margin-bottom: 1.75rem;
}

/* Callout / Result Box */
.gu-result-box {
  background-color: #f0f4f8;
  border-left: 5px solid var(--gu-brand);
  padding: 1.35rem 1.75rem;
  margin: 2rem 0;
  border-radius: 0 6px 6px 0;
}

.gu-result-box-title {
  font-family: var(--gu-font-headline);
  font-size: 1.15rem;
  color: var(--gu-brand);
  margin-bottom: 0.5rem;
  font-weight: 700;
}

/* Body Content & Academic Typography */
.gu-body {
  font-size: 1.1rem;
  line-height: 1.75;
  color: #1a1a1a;
}

.gu-body p {
  margin-bottom: 1.5rem;
}

.gu-body h2 {
  font-family: var(--gu-font-headline);
  font-size: 1.65rem;
  line-height: 1.25;
  margin: 2.5rem 0 1rem;
  color: var(--gu-brand);
  border-bottom: 2px solid var(--gu-kicker);
  padding-bottom: 0.4rem;
}

.gu-body h3 {
  font-family: var(--gu-font-headline);
  font-size: 1.35rem;
  line-height: 1.3;
  margin: 2rem 0 0.85rem;
  color: #1a1a1a;
}

.gu-body ul, .gu-body ol {
  margin: 1.25rem 0 1.5rem 2rem;
}

.gu-body li {
  margin-bottom: 0.65rem;
}

.gu-body blockquote {
  border-left: 4px solid var(--gu-kicker);
  padding-left: 1.25rem;
  margin: 1.75rem 0;
  font-style: italic;
  color: #444444;
}

.gu-body pre {
  background-color: #0f172a;
  color: #f8fafc;
  padding: 1.35rem 1.5rem;
  border-radius: 6px;
  overflow-x: auto;
  margin: 1.75rem 0;
  font-family: "Fira Code", "Consolas", "Monaco", monospace;
  font-size: 0.92rem;
  line-height: 1.5;
  border-left: 4px solid var(--gu-brand);
}

.gu-body code {
  background-color: #f1f5f9;
  color: #b91c1c;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
  font-family: "Fira Code", "Consolas", monospace;
  font-size: 0.92em;
}

.gu-body pre code {
  background-color: transparent;
  color: inherit;
  padding: 0;
  border-radius: 0;
}

/* Pagination */
.gu-pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--gu-border);
}

.gu-page-btn {
  background-color: var(--gu-brand);
  color: #ffffff;
  padding: 0.5rem 1.25rem;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.9rem;
}

.gu-page-btn.disabled {
  background-color: #cccccc;
  pointer-events: none;
}
