/* =========================================================
   Day Break With Jesus — Site-wide styles (style.css)
   Applies to: includes/header.php nav + About + All Devotionals
   (Home page uses its own inline CSS in index.php)
   ========================================================= */

/* ===== GLOBAL RESET ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root{
  --accent-gold: #ffd166;

  /* Match the "bright" home hero overlay feel */
  --overlay-light: rgba(255, 255, 255, 0.08);
  --overlay-lighter: rgba(255, 255, 255, 0.15);

  --page-bg: #f7f9fc;
  --text: #1e2a36;
  --muted: #6b7280;
  --card: #ffffff;

  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 10px 26px rgba(15, 23, 42, 0.10);

  --radius: 14px;
}

html, body { height: 100%; }

body{
  font-family: "Open Sans", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  background: var(--page-bg);
  line-height: 1.6;

  /* Keeps footer at bottom on short pages */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== TOP NAV (includes/header.php) ===== */
header.topnav{
  position: absolute; /* overlays hero */
  top: 0;
  left: 0;
  width: 100%;
  z-index: 50;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;

  padding: 1.15rem 2rem;
  background: transparent;
}

header.topnav .branding{
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  max-width: 60%;
}

header.topnav .brand{
  color: #ffffff;
  text-decoration: none;
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.1;
  text-shadow: 0 2px 5px rgba(0,0,0,0.35);
}

header.topnav .tagline{
  color: rgba(255,255,255,0.88);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-shadow: 0 2px 5px rgba(0,0,0,0.30);
}

header.topnav nav ul{
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1.35rem;
  margin: 0;
  padding: 0;
}

header.topnav nav ul li a{
  color: rgba(255,255,255,0.95);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding-bottom: 0.15rem;
  text-shadow: 0 2px 5px rgba(0,0,0,0.35);
}

header.topnav nav ul li a:hover,
header.topnav nav ul li a.active{
  border-bottom: 2px solid rgba(255,255,255,0.95);
  color: #ffffff;
}

@media (max-width: 760px){
  header.topnav{
    padding: 1rem 1.1rem;
  }
  header.topnav .branding{ max-width: 55%; }
  header.topnav nav ul{ gap: 0.9rem; }
  header.topnav nav ul li a{ font-size: 0.9rem; }
  header.topnav .tagline{ letter-spacing: 0.14em; }
}

@media (max-width: 520px){
  header.topnav{
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
  }
  header.topnav .branding{ max-width: 100%; }
  header.topnav nav ul{ width: 100%; justify-content: flex-end; }
}

/* ===== HERO (secondary pages: <section class="hero">) ===== */
section.hero{
  position: relative;
  width: 100%;
  min-height: 48vh;

  /* Match the "bright" home hero feel */
  background-image:
    linear-gradient(to bottom, var(--overlay-light), var(--overlay-lighter)),
    url("images/hero-coffee-bible-surf.jpg");
  background-size: cover;
  background-position: center;

  display: flex;
  align-items: center;
  justify-content: center;

  text-align: center;
  color: #ffffff;

  /* Give room so nav overlay never feels tight */
  padding: 6.25rem 1.25rem 2.75rem;
}

/* The markup contains .hero-overlay; keep it but don't double-darken */
section.hero .hero-overlay{
  display: none;
}

section.hero .hero-text{
  position: relative;
  z-index: 2;
  max-width: 900px;
  padding: 0 1rem;
}

section.hero .hero-text h1{
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 2.75rem;
  line-height: 1.1;
  margin-bottom: 0.55rem;
  text-shadow: 0 2px 6px rgba(0,0,0,0.35);
}

section.hero .hero-text p{
  font-size: 1.05rem;
  color: rgba(255,255,255,0.92);
  text-shadow: 0 2px 6px rgba(0,0,0,0.30);
}

@media (max-width: 700px){
  section.hero{ min-height: 42vh; padding-top: 6.75rem; }
  section.hero .hero-text h1{ font-size: 2.2rem; }
  section.hero .hero-text p{ font-size: 1rem; }
}

/* ===== ALL DEVOTIONALS (view-all-devotionals.php) ===== */
main.devotionals-container{
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 2.75rem 1.5rem 4rem;

  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.9rem;
}

.devotional-card{
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  padding: 1.4rem 1.5rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.devotional-card:hover{
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.devotional-date{
  font-size: 0.78rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: none; /* FIXED: Changed from uppercase to none */
  margin-bottom: 0.65rem;
}

.devotional-title{
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 0.85rem;
  color: #111827;
}

.devotional-link a{
  color: #1d4ed8;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
}

.devotional-link a:hover{
  text-decoration: underline;
}

.no-devotionals{
  grid-column: 1 / -1;
  text-align: center;
  color: var(--muted);
  background: rgba(255,255,255,0.85);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-soft);
}

/* ===== ABOUT (about.php) ===== */
main.about-section{
  width: 100%;
  padding: 3rem 1.5rem 4rem;
}

.about-container{
  max-width: 900px;
  margin: 0 auto;
  background: var(--card);
  border-radius: var(--radius);
  padding: 2.4rem 2.75rem;
  box-shadow: var(--shadow-soft);
}

.about-container h3{
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 1.65rem;
  margin-bottom: 1.25rem;
  color: #111827;
}

.about-container p{
  margin-bottom: 1.05rem;
  font-size: 1rem;
  color: #374151;
}

/* Prevent awkward line breaks in scripture references */
.devotional-content p em {
  display: inline-block;
  hyphens: none;
}

/* Keep scripture reference numbers together */
.devotional-content {
  word-break: keep-all;
  overflow-wrap: break-word;
}

@media (max-width: 600px){
  .about-container{
    padding: 1.75rem 1.5rem;
  }
  .about-container h3{
    font-size: 1.4rem;
  }
  /* Allow wrapping on mobile if needed */
  .devotional-content p em {
    white-space: normal;
  }
}

/* ===== FOOTER (includes/footer.php) ===== */
footer{
  margin-top: auto;           /* push to bottom */
  text-align: center;
  padding: 1.35rem 1rem;
  color: rgba(17,24,39,0.72);
  font-size: 0.88rem;
}
/* ===== INDIVIDUAL DEVOTIONAL PAGE (devotional.php) ===== */
.devotional-main {
  max-width: 800px;
  margin: 40px auto; /* Reduced from 80px to raise content */
  padding: 2rem;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.devotional-article {
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.8;
  color: var(--text);
}

.devotional-article .devotional-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.devotional-article .devotional-date {
  font-size: 0.88rem;
  color: var(--muted);
  margin-bottom: 2rem;
  text-transform: none;
}

.devotional-article .devotional-content {
  font-size: 1.05rem;
  line-height: 1.8;
}

.devotional-article .devotional-content p {
  margin-bottom: 1.5rem;
}

.devotional-article .devotional-content em {
  font-style: italic;
  color: #374151;
}

.devotional-article .devotional-content h2 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.5rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: #111827;
  font-weight: 600;
}

.devotional-article .devotional-content strong {
  font-weight: 700;
  color: #111827;
}

@media (max-width: 768px) {
  .devotional-main {
    margin: 40px 1rem;
    padding: 1.5rem;
  }
  
  .devotional-article .devotional-title {
    font-size: 1.5rem;
  }
  
  .devotional-article .devotional-content {
    font-size: 1rem;
  }
}

/* Share link styling */
.devotional-share {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #e5e7eb;
  text-align: center;
}

.devotional-share .share-link {
  display: inline-block;
  padding: 12px 24px;
  background: var(--accent-gold);
  color: #1e2a36;
  text-decoration: none;
  border-radius: 28px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(255, 209, 102, 0.3);
  border: none;
  cursor: pointer;
  font-family: 'Playfair Display', serif;
}

.devotional-share .share-link:hover {
  background: #ffbe3d;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 209, 102, 0.4);
}

/* ===== ADDITIONAL MOBILE & LAYOUT FIXES ===== */

/* Home page - raise hero content to show more cup/Bible */
body.home-page .hero-container {
  padding-top: 3.5rem !important;
  min-height: 85vh !important;
}

/* Devotional page - add top margin to clear header and language dropdown */
body.devotional-page .devotional-main {
  margin-top: 120px !important;
}

@media (max-width: 768px) {
  body.devotional-page .devotional-main {
    margin-top: 100px !important;
  }
}
