/*
Theme Name: ABOT News Theme
Theme URI: https://abocean.org
Description: Custom child theme for ABOT news blog — matches the static site design
Author: Dogtooth Creative
Author URI: https://dogtoothcreative.co.uk
Version: 1.0
*/

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;1,9..40,300&family=DM+Serif+Display:ital@0;1&display=swap');

:root {
  --blue:       #0062C5;
  --cyan:       #00E7FB;
  --cyan-pale:  #E0FBFF;
  --dark:       #04234A;
  --mid:        #54595F;
  --text:       #444444;
  --light:      #E8F4FF;
  --white:      #ffffff;
}

/* ── RESET & BASE ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  color: var(--text);
  background: var(--white);
  overflow-x: hidden;
}

/* ── HIDE ORIGINAL THEME HEADER & FOOTER ── */
.site-header,
.site-footer,
header.entry-header .site-branding,
.main-navigation,
#masthead,
#colophon,
.wp-block-template-part { display: none !important; }

/* ── CUSTOM NAV ── */
#abot-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 72px;
  background: rgba(4,35,74,0.97);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
#abot-nav .nav-logo img {
  height: 64px;
  width: auto;
  mix-blend-mode: screen;
  display: block;
}
#abot-nav .nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}
#abot-nav .nav-links a {
  font-size: 13px;
  color: rgba(255,255,255,0.82);
  text-decoration: none;
  letter-spacing: 0.03em;
  transition: color 0.2s;
}
#abot-nav .nav-links a:hover { color: var(--cyan); }
.nav-dropdown { position: relative; }
.nav-dropdown-toggle { display: flex; align-items: center; gap: 5px; }
.nav-dropdown-toggle svg { transition: transform 0.2s; flex-shrink: 0; }
.nav-dropdown:hover .nav-dropdown-toggle svg, .nav-dropdown:focus-within .nav-dropdown-toggle svg { transform: rotate(180deg); }
.nav-dropdown-menu { list-style: none; position: absolute; top: 100%; left: 50%; margin-top: 16px; min-width: 210px; background: var(--dark); border: 1px solid rgba(255,255,255,0.1); border-radius: 12px; padding: 8px; box-shadow: 0 16px 40px rgba(0,0,0,0.35); opacity: 0; visibility: hidden; transform: translateX(-50%) translateY(6px); transition: opacity 0.2s, transform 0.2s, visibility 0.2s; }
.nav-dropdown:hover .nav-dropdown-menu, .nav-dropdown:focus-within .nav-dropdown-menu, .nav-dropdown.open .nav-dropdown-menu { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.nav-dropdown-menu li { list-style: none; }
.nav-dropdown-menu a { display: block; padding: 10px 14px; font-size: 13px; color: rgba(255,255,255,0.78); text-decoration: none; border-radius: 8px; letter-spacing: 0.02em; white-space: nowrap; transition: background 0.15s, color 0.15s; }
.nav-dropdown-menu a:hover { background: rgba(255,255,255,0.08); color: var(--cyan); }
.mobile-nav-sub { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-top: -10px; }
.mobile-nav-sub a { font-size: 14px !important; font-family: 'DM Sans', sans-serif !important; letter-spacing: 0.02em !important; color: rgba(255,255,255,0.55) !important; }
.mobile-nav-sub a:hover { color: var(--cyan) !important; }
#abot-nav .nav-donate {
  background: var(--cyan) !important;
  color: var(--dark) !important;
  font-weight: 500 !important;
  padding: 9px 22px;
  border-radius: 30px;
}
#abot-nav .nav-donate:hover { background: #fff !important; }
#abot-nav .nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
#abot-nav .nav-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
}
#abot-mobile-nav {
  display: none;
  position: fixed;
  top: 72px; left: 0; right: 0; bottom: 0;
  background: rgba(4,35,74,0.98);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
}
#abot-mobile-nav.open { display: flex; }
#abot-mobile-nav a {
  font-size: 22px;
  color: rgba(255,255,255,0.88);
  text-decoration: none;
  font-family: 'Bebas Neue', sans-serif;
  letter-spacing: 0.06em;
}
#abot-mobile-nav a:hover { color: var(--cyan); }
#abot-mobile-nav .nav-donate {
  background: var(--cyan);
  color: var(--dark) !important;
  padding: 12px 36px;
  border-radius: 30px;
}

/* ── MAIN CONTENT WRAPPER ── */
#page, .site, .wp-site-blocks { margin-top: 72px; }
.site-content, #content, main, .wp-block-group { max-width: none !important; padding: 0 !important; }

/* ── BLOG ARCHIVE (post list) ── */
.blog .posts-container,
.archive .posts-container,
.home .posts-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 56px 48px 72px;
}

.blog article.post,
.archive article.post,
.home article.post {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  padding: 32px 0;
  border-bottom: 1px solid #eaf0f8;
}
.blog article.post:first-of-type,
.archive article.post:first-of-type { padding-top: 0; }
.blog article.post:last-of-type,
.archive article.post:last-of-type { border-bottom: none; }

.post-thumbnail-wrap {
  width: 180px;
  height: 120px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
}
.post-thumbnail-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s;
}
article.post:hover .post-thumbnail-wrap img { transform: scale(1.05); }

.post-content-wrap { flex: 1; }

.post-category {
  display: inline-block;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 20px;
  background: var(--light);
  color: var(--blue);
  margin-bottom: 8px;
}

.post-date {
  font-size: 11px;
  color: var(--mid);
  margin-bottom: 6px;
}

.post-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 26px;
  color: var(--dark);
  letter-spacing: 0.04em;
  line-height: 1.1;
  margin-bottom: 10px;
}
.post-title a {
  text-decoration: none;
  color: var(--dark);
  transition: color 0.2s;
}
.post-title a:hover { color: var(--blue); }

.post-excerpt {
  font-size: 14px;
  color: var(--mid);
  line-height: 1.7;
  margin-bottom: 14px;
}

.post-read-more {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 500;
  color: var(--blue);
  text-decoration: none;
  border-bottom: 1.5px solid var(--cyan);
  padding-bottom: 1px;
  transition: color 0.2s;
}
.post-read-more:hover { color: var(--cyan); }
.post-read-more::after { content: '→'; }

/* ── SINGLE POST ── */
.single-post-hero {
  background: var(--dark);
  padding: 56px 48px 48px;
  margin-top: 0;
}
.single-post-eyebrow {
  font-size: 10.5px;
  font-weight: 500;
  color: var(--cyan);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.single-post-eyebrow::before {
  content: '';
  display: block;
  width: 3px;
  height: 16px;
  background: var(--cyan);
  border-radius: 2px;
}
.single-post-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(32px, 5vw, 56px);
  color: var(--white);
  letter-spacing: 0.04em;
  line-height: 1;
  margin-bottom: 16px;
}
.single-post-meta {
  font-size: 13px;
  color: rgba(255,255,255,0.5);
}
.single-post-featured-img {
  width: 100%;
  max-height: 480px;
  object-fit: cover;
  display: block;
}
.single-post-hero.has-photo {
  position: relative;
  padding: 0;
  height: 320px;
  overflow: hidden;
}
.single-post-hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
}
.single-post-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(4,35,74,0.88) 0%, rgba(4,35,74,0.5) 55%, rgba(4,35,74,0.2) 100%), linear-gradient(to top, rgba(4,35,74,0.7) 0%, transparent 60%);
}
.single-post-hero-content {
  position: absolute;
  bottom: 40px;
  left: 48px;
  right: 48px;
  z-index: 1;
}
.single-post-hero-content .single-post-eyebrow,
.single-post-hero-content .single-post-title {
  margin-bottom: 0;
}
.single-post-hero-content .single-post-eyebrow {
  margin-bottom: 12px;
}
@media (max-width: 768px) {
  .single-post-hero.has-photo { height: 240px; }
  .single-post-hero-content { left: 20px; right: 20px; bottom: 28px; }
}
.single-post-content {
  max-width: 780px;
  margin: 0 auto;
  padding: 52px 48px 80px;
}
.single-post-content p {
  font-size: 16px;
  line-height: 1.85;
  color: var(--text);
  margin-bottom: 20px;
}
.single-post-content h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 32px;
  color: var(--dark);
  letter-spacing: 0.04em;
  margin: 36px 0 16px;
}
.single-post-content h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 24px;
  color: var(--dark);
  letter-spacing: 0.04em;
  margin: 28px 0 12px;
}
.single-post-content img {
  width: 100%;
  border-radius: 10px;
  margin: 28px 0;
  display: block;
}
.single-post-content a { color: var(--blue); }
.single-post-content a:hover { color: var(--cyan); }
.single-post-content ul, .single-post-content ol {
  margin: 0 0 20px 24px;
  line-height: 1.85;
  color: var(--text);
}
.single-post-content blockquote {
  border-left: 3px solid var(--cyan);
  padding: 12px 20px;
  background: var(--light);
  border-radius: 0 8px 8px 0;
  margin: 24px 0;
  font-style: italic;
  color: var(--mid);
}

/* Back to news link */
.back-to-news {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--blue);
  text-decoration: none;
  margin-bottom: 28px;
  transition: color 0.2s;
}
.back-to-news:hover { color: var(--cyan); }
.back-to-news::before { content: '←'; }

/* ── PAGINATION ── */
.pagination-wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 48px 64px;
  display: flex;
  gap: 8px;
}
.pagination-wrap .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  font-size: 13px;
  text-decoration: none;
  color: var(--mid);
  border: 1px solid #eaf0f8;
  transition: all 0.2s;
}
.pagination-wrap .page-numbers.current,
.pagination-wrap .page-numbers:hover {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}

/* ── FOOTER ── */
#abot-footer {
  background: var(--dark);
  padding: 56px 48px 0;
}
.abot-footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.6fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.abot-footer-logo img {
  height: 52px;
  width: auto;
  mix-blend-mode: screen;
  margin-bottom: 14px;
  display: block;
}
.abot-footer-tagline {
  font-size: 13px;
  color: rgba(255,255,255,0.42);
  line-height: 1.8;
}
.abot-footer-col-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 16px;
  color: var(--cyan);
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}
.abot-footer-link {
  display: block;
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  margin-bottom: 9px;
  transition: color 0.2s;
}
.abot-footer-link:hover { color: #fff; }
.abot-footer-nl-label {
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  margin-bottom: 14px;
  line-height: 1.6;
}
.abot-footer-form { display: flex; gap: 8px; }
.abot-footer-input {
  flex: 1;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
  color: #fff;
  font-family: 'DM Sans', sans-serif;
  outline: none;
}
.abot-footer-input::placeholder { color: rgba(255,255,255,0.3); }
.abot-footer-input:focus { border-color: var(--cyan); }
.abot-footer-submit {
  background: var(--cyan);
  color: var(--dark);
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
}
.abot-footer-submit:hover { background: #fff; }
.abot-footer-bottom {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 18px 0;
}
.abot-footer-copy {
  font-size: 12px;
  color: rgba(255,255,255,0.28);
}
.abot-footer-copy a { color: rgba(255,255,255,0.45); text-decoration: none; }
.abot-footer-copy a:hover { color: var(--cyan); }
.abot-footer-social { display: flex; gap: 16px; margin-top: 24px; }
.abot-footer-social a { display: flex; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 50%; background: rgba(255,255,255,0.16); border: 1.5px solid rgba(255,255,255,0.28); color: var(--white); transition: background 0.2s, color 0.2s, transform 0.2s, border-color 0.2s; text-decoration: none; }
.abot-footer-social a svg { width: 26px; height: 26px; }
.abot-footer-social a:hover { background: var(--cyan); color: var(--dark); border-color: var(--cyan); transform: translateY(-3px); }

/* ── WAVE ── */
.abot-wave { background: var(--white); line-height: 0; }
.abot-wave svg { display: block; width: 100%; }
.abot-wave-dark { background: var(--dark); line-height: 0; }
.abot-wave-dark svg { display: block; width: 100%; }

/* ── MOBILE ── */
@media (max-width: 768px) {
  #abot-nav { padding: 0 20px; }
  #abot-nav .nav-logo img { height: 48px; }
  #abot-nav .nav-links { display: none; }
  #abot-nav .nav-hamburger { display: flex; }
  .blog .posts-container,
  .archive .posts-container,
  .home .posts-container { padding: 40px 20px 52px; }
  article.post { flex-direction: column; gap: 16px; }
  .post-thumbnail-wrap { width: 100%; height: 200px; }
  .single-post-hero { padding: 40px 20px 36px; }
  .single-post-content { padding: 36px 20px 60px; }
  .pagination-wrap { padding: 0 20px 48px; }
  #abot-footer { padding: 40px 20px 0; }
  .abot-footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .abot-footer-bottom { flex-direction: column; gap: 12px; text-align: center; padding: 20px 0; }
}
@media (min-width: 769px) and (max-width: 1024px) {
  #abot-nav { padding: 0 24px; }
  .blog .posts-container,
  .archive .posts-container,
  .home .posts-container { padding: 48px 32px 60px; }
  .single-post-content { padding: 48px 32px 72px; }
  #abot-footer { padding: 48px 32px 0; }
  .abot-footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}

/* ── ENSURE HERO BACKGROUND ALWAYS SHOWS ── */
.single-post-hero:not(.has-photo) {
  background: #04234A !important;
  padding: 128px 48px 48px !important;
  margin-top: 0 !important;
}
@media (max-width: 768px) {
  .single-post-hero:not(.has-photo) { padding: 112px 20px 36px !important; }
}
.single-post-title {
  font-family: 'Bebas Neue', sans-serif !important;
  color: #ffffff !important;
}
.single-post-meta {
  color: rgba(255,255,255,0.5) !important;
}
.single-post-eyebrow {
  color: #00E7FB !important;
}

/* ══════════════════════════════════════════════════════════
   NEWS LANDING PAGE (page-news.php) — Facebook leads, full
   width; WP blog + newsletter sidebar are secondary content.
   ══════════════════════════════════════════════════════════ */
.news-section-tag {
  display: inline-block; font-size: 11px; font-weight: 500; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--blue); border-left: 3px solid var(--cyan);
  padding-left: 12px; margin-bottom: 10px;
}
.news-section-h2 {
  font-family: 'Bebas Neue', sans-serif; font-size: 34px; color: var(--dark);
  letter-spacing: 0.03em; line-height: 1.05;
}
.news-h2-italic {
  font-family: 'DM Serif Display', serif; font-style: italic; color: var(--blue);
}

/* Facebook — full width */
.news-fb-section { background: var(--white); padding: 64px 48px 24px; }
.news-fb-inner { max-width: 1200px; margin: 0 auto; }
.news-fb-header { max-width: 640px; margin-bottom: 32px; }
.news-fb-intro { font-size: 14.5px; color: var(--mid); line-height: 1.7; margin-top: 10px; }
/* Give the Smash Balloon grid room + a card look consistent with the rest of the site */
.news-fb-inner .csf-wrapper-full-width,
.news-fb-inner .cff-post-inner {
  border-radius: 12px !important;
}

/* Blog + sidebar */
.news-content-wrap {
  max-width: 1200px; margin: 0 auto; padding: 56px 48px 72px;
  display: grid; grid-template-columns: 1fr 340px; gap: 56px; align-items: start;
}
.news-section-header { margin-bottom: 28px; }
.news-grid { display: flex; flex-direction: column; }
.news-card { display: flex; gap: 24px; align-items: flex-start; padding: 24px 0; border-bottom: 1px solid #eaf0f8; }
.news-card:first-child { padding-top: 0; }
.news-card:last-child { border-bottom: none; }
.news-card-img { width: 140px; height: 96px; border-radius: 10px; overflow: hidden; flex-shrink: 0; }
.news-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.news-card-tag {
  display: inline-block; font-size: 10px; font-weight: 500; letter-spacing: 0.12em;
  text-transform: uppercase; padding: 3px 10px; border-radius: 20px;
  background: var(--light); color: var(--blue); margin-bottom: 8px;
}
.news-card-date { font-size: 11px; color: var(--mid); margin-bottom: 6px; }
.news-card-title { font-family: 'Bebas Neue', sans-serif; font-size: 21px; color: var(--dark); letter-spacing: 0.03em; line-height: 1.1; margin-bottom: 8px; }
.news-card-excerpt { font-size: 13.5px; color: var(--mid); line-height: 1.6; margin-bottom: 10px; }
.news-card-link {
  font-size: 12px; color: var(--blue); font-weight: 500; text-decoration: none;
  border-bottom: 1.5px solid var(--cyan); padding-bottom: 1px;
}
.news-card-link:hover { color: var(--cyan); }

/* Sidebar */
.news-sidebar { display: flex; flex-direction: column; gap: 28px; }
.news-archive-section { background: var(--white); border-radius: 16px; overflow: hidden; }
.news-archive-header { background: var(--dark); padding: 20px 22px 16px; }
.news-archive-title { font-family: 'Bebas Neue', sans-serif; font-size: 20px; color: var(--white); letter-spacing: 0.04em; }
.news-archive-item { display: flex; align-items: center; justify-content: space-between; padding: 14px 22px; border-bottom: 1px solid #f0f4f8; gap: 12px; }
.news-archive-item:last-child { border-bottom: none; }
.news-archive-item-latest { background: var(--light); }
.news-archive-item-title { font-size: 13px; font-weight: 500; color: var(--dark); line-height: 1.2; }
.news-archive-item-date { font-size: 11px; color: var(--mid); margin-top: 2px; }
.news-archive-download { font-size: 11px; color: var(--blue); font-weight: 500; text-decoration: none; white-space: nowrap; }
.news-archive-download:hover { color: var(--cyan); }
.news-archive-download-latest { font-size: 12px; font-weight: 700; color: var(--blue); }
.news-archive-footer { background: var(--dark); height: 16px; }

@media (max-width: 768px) {
  .news-fb-section { padding: 44px 20px 12px; }
  .news-content-wrap { grid-template-columns: 1fr; padding: 40px 20px 56px; gap: 32px; }
  .news-card { flex-direction: column; gap: 14px; }
  .news-card-img { width: 100%; height: 180px; }
}
@media (min-width: 769px) and (max-width: 1024px) {
  .news-content-wrap { grid-template-columns: 1fr; padding: 48px 32px; }
  .news-sidebar { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
}
