/*
Theme Name:   Save Antioch (Divi Child)
Theme URI:    https://saveantioch.org
Description:  Revolution-themed Divi child for Save Antioch. Black / blood-red / gold palette, heavy serif headings, raised-fist energy.
Author:       M00nshadow
Author URI:   https://m00nshadow.boppers.net
Template:     Divi
Version:      0.2.0
License:      GNU General Public License v2 or later
License URI:  https://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  divi-child
*/

/* ============================================================
   Save Antioch — palette
   ============================================================ */
:root {
  --sa-black:      #0a0a0a;
  --sa-ink:        #1a1a1a;
  --sa-red:        #b91c1c;   /* blood red */
  --sa-red-deep:   #7f1414;   /* hover */
  --sa-gold:       #d4a017;   /* cockade gold */
  --sa-paper:      #f4f1ea;   /* off-white */
  --sa-rule:       #2a0808;   /* near-black-red for thin rules */
}

/* ============================================================
   Typography — Playfair Display (serif) + Inter (sans)
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,500;0,700;0,900;1,700&family=Inter:wght@400;500;700&display=swap');

/* Force black background EVERYWHERE — kill Divi's white page templates */
html,
body,
#page-container,
#et-main-area,
#main-content,
#content-area,
.container,
.et_pb_section,
.et_pb_section_regular,
.et_pb_section_specialty,
.et_pb_row,
.et_pb_column,
.et_pb_text,
.et_pb_text_inner,
.et_pb_post,
.et_pb_blog_grid,
.et_pb_with_background,
.et_pb_post_content,
.et_pb_image,
.et_post_meta_wrapper,
.entry-content,
.entry-summary,
.page,
.single,
article,
article.et_pb_post,
.et_pb_module,
.et_pb_sidebar_0,
#sidebar,
.widget,
.dlw-container,
.dlp-table,
.dlp-table tbody,
.dlp-table tbody td,
.dlp-table tbody tr {
  background-color: var(--sa-black) !important;
  color: var(--sa-paper) !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Override hardcoded WP block / Divi text colors */
.entry-content p,
.entry-content li,
.entry-content td,
.entry-content dt,
.entry-content dd,
.et_pb_text_inner p,
.et_pb_text_inner li,
.dlp-table td,
.widget li,
.widget p {
  color: var(--sa-paper) !important;
}

/* Table inside doc library: stripe odd rows for legibility */
.dlp-table tbody tr:nth-child(odd) td { background-color: #141414 !important; }
.dlp-table a { color: var(--sa-gold); }
.dlp-table a:hover { color: var(--sa-red); }

h1, h2, h3, h4, h5, h6,
.et_pb_module h1, .et_pb_module h2, .et_pb_module h3,
.entry-title {
  font-family: 'Playfair Display', 'Georgia', serif !important;
  font-weight: 900 !important;
  color: var(--sa-paper) !important;
  letter-spacing: -0.01em;
}

h1, .entry-title { font-size: clamp(2rem, 4vw, 3.5rem); line-height: 1.05; }
h2 { font-size: clamp(1.5rem, 3vw, 2.4rem); }

/* Thin red rule under entry titles */
.entry-title::after,
.et_pb_post_title .entry-title::after {
  content: "";
  display: block;
  width: 3.5rem;
  height: 3px;
  margin-top: 0.6rem;
  background: var(--sa-red);
}

/* ============================================================
   Links, buttons
   ============================================================ */
a, a:visited {
  color: var(--sa-red);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .15s, border-color .15s;
}
a:hover {
  color: var(--sa-gold);
  border-bottom-color: var(--sa-gold);
}

.et_pb_button,
.et_pb_button:hover,
input[type="submit"],
button {
  background-color: var(--sa-red) !important;
  color: var(--sa-paper) !important;
  border: 2px solid var(--sa-red) !important;
  border-radius: 0 !important;
  font-family: 'Inter', sans-serif !important;
  font-weight: 700 !important;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.75rem 1.5rem !important;
  transition: background .15s, border-color .15s, color .15s;
}
.et_pb_button:hover,
input[type="submit"]:hover,
button:hover {
  background-color: var(--sa-black) !important;
  border-color: var(--sa-gold) !important;
  color: var(--sa-gold) !important;
}
.et_pb_button::after { color: var(--sa-paper) !important; }

/* ============================================================
   Header / nav
   ============================================================ */
#main-header {
  background-color: var(--sa-black) !important;
  box-shadow: 0 1px 0 var(--sa-red) !important;
}
#top-menu li a {
  color: var(--sa-paper) !important;
  font-family: 'Inter', sans-serif !important;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.85rem;
}
#top-menu li.current-menu-item a,
#top-menu li a:hover {
  color: var(--sa-red) !important;
}
#logo { filter: brightness(0) invert(1); }

/* ============================================================
   Tagline in header (Divi hides it by default)
   ============================================================ */
.logo_container,
#logo_container { position: relative; }

.logo_container::after {
  content: var(--sa-tagline, "");
  display: block;
  font-family: 'Playfair Display', 'Georgia', serif;
  font-style: italic;
  color: var(--sa-paper);
  font-size: 0.95rem;
  margin-top: 0.15rem;
  letter-spacing: 0.01em;
  opacity: 0.9;
  text-shadow: 0 1px 0 var(--sa-black);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Shrink Divi's logo image to leave room for tagline */
#logo { max-height: 48px !important; }

@media (max-width: 980px) {
  .logo_container::after { font-size: 0.8rem; }
}

/* ============================================================
   Hide Uncategorized references anywhere they leak through
   ============================================================ */
.cat-item-1,
.cat-links a[href*="/category/uncategorized"],
.entry-meta a[href*="/category/uncategorized"],
.et_pb_post .post-meta a[href*="/category/uncategorized"],
a[rel="category tag"][href*="/category/uncategorized"] {
  display: none !important;
}

/* ============================================================
   Posts, archive, entries
   ============================================================ */
.post,
.et_pb_post,
article.et_pb_post,
.single .entry-content {
  background-color: var(--sa-ink);
  padding: 2rem;
  margin-bottom: 1.5rem;
  border-left: 4px solid var(--sa-red);
}
.et_pb_post .post-meta,
.entry-meta {
  color: rgba(244, 241, 234, 0.6);
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.et_pb_post .post-meta a { color: var(--sa-gold); }

blockquote {
  border-left: 4px solid var(--sa-gold);
  padding-left: 1.5rem;
  margin-left: 0;
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 1.25rem;
  color: var(--sa-paper);
}

/* ============================================================
   Footer
   ============================================================ */
#main-footer,
#footer-bottom {
  background-color: var(--sa-black) !important;
  border-top: 2px solid var(--sa-red);
  color: rgba(244, 241, 234, 0.7);
}
#footer-bottom a { color: var(--sa-gold); }

/* ============================================================
   PDF Embedder, Document Library — minor color tweaks
   ============================================================ */
.pdfemb-viewer { background: var(--sa-ink) !important; }
.dlp-table thead {
  background: var(--sa-red);
  color: var(--sa-paper);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ============================================================
   Hero / utility classes (used by custom modules)
   ============================================================ */
.sa-hero {
  background: linear-gradient(180deg, var(--sa-black) 60%, var(--sa-rule) 100%);
  color: var(--sa-paper);
  padding: 6rem 0 5rem;
  text-align: center;
  border-bottom: 1px solid var(--sa-red);
}
.sa-hero h1 {
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 1.02;
  color: var(--sa-red) !important;
}
.sa-hero h1::after { display: none; }
.sa-hero .sa-tagline {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(1.1rem, 2vw, 1.6rem);
  color: var(--sa-paper);
  max-width: 38rem;
  margin: 1rem auto 0;
  opacity: 0.85;
}

/* Section dividers — thin red rule */
hr,
.sa-rule {
  border: 0;
  height: 2px;
  background: var(--sa-red);
  width: 4rem;
  margin: 2.5rem auto;
}
