/* ============================================
   Showerhammer — Official Dark Brand Theme
   "A black-and-orange technical field journal with personality."
   ============================================ */

:root {
  /* Brand Colors (official) */
  --sh-black: #000000;
  --sh-orange: #f0801d;
  --sh-yellow: #fec900;

  /* Dark UI Surfaces */
  --bg: #050505;
  --bg-elevated: #0d0d0d;
  --surface: #141414;
  --surface-soft: #1d1d1d;
  --border: #2a2a2a;

  /* Text */
  --text: #f2f2f2;
  --text-muted: #b8b8b8;
  --text-soft: #8c8c8c;

  /* Accents */
  --accent: var(--sh-orange);
  --accent-strong: var(--sh-yellow);
  --accent-soft: rgba(240, 128, 29, 0.14);
  --accent-yellow-soft: rgba(254, 201, 0, 0.12);

  /* Utility */
  --code-bg: #090909;
  --danger: #ff5f57;

  /* Layout */
  --font: Arial, Helvetica, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-brand: "Arial Black", Arial, Helvetica, sans-serif;
  --font-tagline: Georgia, "Times New Roman", serif;
}

/* Base */
body {
  font-family: var(--font);
  line-height: 1.7;
  max-width: var(--max-width);
  margin: 0 auto;
  color: var(--text);
  background: var(--bg);
}

/* Header + Logo (brand critical) — wide container system */
.site-header {
  background: #0a0a0a;
  border-bottom: 1px solid #222;
  margin-bottom: 20px;
}

.header-container {
  max-width: var(--frame-max-width);
  margin: 0 auto;
  padding: 0 32px;
}

/* Content width system (960 grid) */
:root {
  --frame-max-width: 1400px;
  --content-max-width: 960px;
  --sidebar-width: 280px;
  --content-gap: 48px;
}

.content-container {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* Optional: pages with a small sidebar (desktop) */
.page-with-sidebar {
  display: grid;
  grid-template-columns: var(--content-max-width) var(--sidebar-width);
  gap: var(--content-gap);
  max-width: var(--frame-max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.page-with-sidebar .main-content {
  min-width: 0; /* prevent overflow */
}

@media (max-width: 1100px) {
  .page-with-sidebar {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

.site-header nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0;
  gap: 1.5rem;
}



/* Logo */
.logo {
  height: 85px;
  width: auto;
  display: block;
}

.logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  line-height: 0;
}

/* Navigation links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 1.85rem;
  flex: 1;
  justify-content: center;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: color 0.15s ease;
  position: relative;
}

.nav-links a:hover {
  color: var(--sh-orange);
}

/* Header right area (for Kamino/SURFforge back link) */
.header-right {
  display: flex;
  align-items: center;
  min-width: 160px;
  justify-content: flex-end;
}

.header-right .kamino-back {
  font-size: 0.85rem;
  color: #f0801d;
  text-decoration: none;
  white-space: nowrap;
}

/* Typography */
h1, h2, h3, h4 {
  font-family: var(--font-brand);
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--text);
}

h1 { font-size: 2.1rem; margin: 0 0 0.5rem; }
h2 { font-size: 1.45rem; margin-top: 2.25rem; }
h3 { font-size: 1.2rem; margin-top: 1.75rem; }

.subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.meta {
  font-size: 0.9rem;
  color: var(--text-soft);
  margin: 0.5rem 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
}

.tags { margin: 1rem 0; }
.tag {
  font-size: 0.8rem;
  background: var(--surface);
  color: var(--text-muted);
  padding: 0.15rem 0.55rem;
  border-radius: 3px;
  margin-right: 0.4rem;
  text-decoration: none;
  border: 1px solid var(--border);
}
.tag:hover {
  border-color: var(--sh-orange);
  color: var(--sh-orange);
}

/* Links */
a {
  color: var(--sh-orange);
  text-decoration: underline;
  text-underline-offset: 2px;
}
a:hover {
  color: var(--sh-yellow);
}

/* Code & Blockquotes */
pre, code {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Monaco, Consolas, monospace;
}
pre {
  overflow-x: auto;
  padding: 1rem;
  border-radius: 0.6rem;
  background: var(--code-bg);
  border: 1px solid var(--border);
  font-size: 0.9rem;
}
blockquote {
  border-left: 4px solid var(--sh-orange);
  padding-left: 1rem;
  color: var(--text-muted);
  margin-left: 0;
}

/* ============================================
   Article Experience
   ============================================ */

.article-header {
  margin-bottom: 1.75rem;
}

.byline {
  font-size: 0.9rem;
  color: var(--text-soft);
  margin-top: 0.5rem;
}

/* Improve long-form reading experience */
.e-content {
  font-size: 1.05rem;
  line-height: 1.75;
}

.e-content h2 {
  margin-top: 2.25rem;
  margin-bottom: 0.75rem;
}

.e-content h3 {
  margin-top: 1.85rem;
}

.e-content p {
  margin-bottom: 1.1rem;
}

.e-content ul,
.e-content ol {
  margin-bottom: 1.1rem;
  padding-left: 1.35rem;
}

.article-meta {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.article-projects {
  margin-top: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-soft);
}

.project-tag {
  background: var(--surface);
  color: var(--text-muted);
  padding: 0.1rem 0.5rem;
  border-radius: 3px;
  margin-right: 0.4rem;
  text-decoration: none;
  border: 1px solid var(--border);
  font-size: 0.8rem;
}

.project-tag:hover {
  border-color: var(--sh-orange);
  color: var(--sh-orange);
}

/* ============================================
   Callout System — "Black & Orange Technical Field Journal"
   ============================================ */

.callout {
  border: 1px solid var(--border);
  border-left: 6px solid var(--sh-orange);
  background: linear-gradient(
    90deg,
    rgba(240, 128, 29, 0.09),
    rgba(15, 15, 15, 0.96)
  );
  padding: 1.1rem 1.35rem;
  border-radius: 0.5rem;
  margin: 1.75rem 0;
  font-size: 0.98rem;
  line-height: 1.6;
}

.callout strong,
.callout b {
  display: block;
  font-family: var(--font-brand);
  font-size: 0.92rem;
  letter-spacing: -0.02em;
  margin-bottom: 0.4rem;
  text-transform: uppercase;
  color: var(--sh-orange);
}

/* Variants */
.callout-thesis {
  border-left-color: var(--sh-yellow);
}
.callout-thesis strong {
  color: var(--sh-yellow);
}

.callout-principle {
  border-left-color: var(--sh-orange);
}

.callout-field-note {
  border-left-color: #5fa3ff;
}
.callout-field-note strong {
  color: #5fa3ff;
}

.callout-operational {
  border-left-color: #ff7a4d;
}
.callout-operational strong {
  color: #ff7a4d;
}

.callout-warning {
  border-left-color: var(--danger);
}
.callout-warning strong {
  color: var(--danger);
}

/* Primary Sources (machine layer at bottom of articles) */
.primary-sources {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--text-muted);
}

.primary-sources h3 {
  font-size: 0.95rem;
  margin-bottom: 0.6rem;
  color: var(--text);
  font-family: var(--font-brand);
  letter-spacing: -0.01em;
}

.primary-sources p {
  margin-bottom: 0.8rem;
  line-height: 1.5;
}

.source-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-bottom: 1rem;
}

.source-links a {
  color: var(--sh-orange);
  text-decoration: none;
  font-size: 0.85rem;
}

.source-links a:hover {
  color: var(--sh-yellow);
  text-decoration: underline;
}

.philosophical-note {
  font-size: 0.85rem;
  font-style: italic;
  color: var(--text-soft);
  border-top: 1px solid var(--border);
  padding-top: 0.8rem;
  margin-top: 0.8rem;
}

/* Projects Grid */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.home-projects {
  margin-top: 1rem;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1.25rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, transform 0.1s ease;
}

.project-card:hover {
  border-color: var(--sh-orange);
  transform: translateY(-2px);
}

.project-card h3 {
  margin: 0 0 0.5rem;
  color: var(--text);
  font-size: 1.15rem;
}

.project-card p {
  margin: 0 0 0.5rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.5;
}

.project-card .project-status {
  display: inline-block;
  font-size: 0.7rem;
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--sh-orange);
  margin-top: 0.25rem;
}

.project-link {
  margin-top: 1.25rem;
}

.project-link a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: var(--accent-soft);
  color: var(--sh-orange);
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.15s ease;
}

.project-link a:hover {
  background: rgba(254, 201, 0, 0.18);
  color: var(--sh-yellow);
}

/* Project Pages */
.project-page h1 {
  margin-bottom: 0.5rem;
}

.project-summary {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.project-meta {
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
}

/* Homepage */
.latest-article {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
}

.latest-article h3 {
  margin: 0 0 0.35rem;
  font-size: 1.25rem;
}

.more-articles {
  margin-top: 1rem;
}

.more-articles h4 {
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  color: var(--text-muted);
}

.more-articles ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

/* Articles listing */
.article-list {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.article-teaser {
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.article-teaser:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.article-teaser h2 {
  font-size: 1.35rem;
  margin: 0 0 0.35rem;
  line-height: 1.3;
}

.teaser-subtitle {
  color: var(--text-muted);
  margin: 0.25rem 0 0.5rem;
  font-size: 1rem;
}

.teaser-meta {
  font-size: 0.8rem;
  color: var(--text-soft);
  display: flex;
  gap: 0.75rem;
}

/* Footer — consistent wide container system */
.site-footer {
  background: #0a0a0a;
  border-top: 1px solid #222;
  padding: 2.5rem 0 1.5rem;
  color: #888;
  font-size: 0.9rem;
  margin-top: 20px;
}

.footer-container {
  max-width: var(--frame-max-width);
  margin: 0 auto;
  padding: 0 32px;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-brand {
  margin: 0;
  color: #aaa;
}

.footer-brand strong {
  color: #f0801d;
}

.footer-links a {
  margin-right: 1.25rem;
  color: #aaa;
  text-decoration: none;
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: var(--sh-orange);
}

.footer-philosophy {
  font-style: italic;
  opacity: 0.7;
  margin: 0;
  color: #888;
  font-size: 0.85rem;
}

.footer-platform {
  margin: 0.5rem 0 0;
  opacity: 0.55;
  font-size: 0.78rem;
  color: #777;
}

.footer-platform strong {
  color: #f0801d;
  font-weight: 600;
}

/* Share buttons - brand aligned */
.share-buttons {
  margin: 2rem 0 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.share-buttons button,
.share-buttons a {
  border: 1px solid rgba(240, 128, 29, 0.5);
  color: var(--text);
  background: rgba(240, 128, 29, 0.06);
  border-radius: 999px;
  padding: 0.4rem 0.95rem;
  font-size: 0.82rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all 0.15s ease;
  cursor: pointer;
}

.share-buttons button:hover,
.share-buttons a:hover {
  border-color: var(--sh-yellow);
  background: rgba(254, 201, 0, 0.12);
  color: var(--sh-yellow);
}

/* Responsive */
@media (max-width: 900px) {
  .header-container,
  .footer-container {
    padding: 0 20px;
  }

  .nav-links {
    gap: 1.1rem;
  }

  .nav-links a {
    font-size: 0.92rem;
  }

  .footer-content {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-links {
    margin: 0.5rem 0;
  }
}

@media (max-width: 640px) {
  .logo {
    height: 58px;
  }
  .nav-links {
    gap: 0.9rem;
  }
  .nav-links a {
    font-size: 0.85rem;
  }
}
