/* ============================================================
   Olive Branch church of Christ — Main Stylesheet
   Mobile-first responsive design
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Nunito+Sans:ital,wght@0,300;0,400;0,600;0,700;1,400&display=swap');

:root {
  --color-primary: #1B2A4A;
  --color-primary-light: #2C4066;
  --color-accent: #B8860B;
  --color-accent-light: #D4A843;
  --color-cream: #FAF8F5;
  --color-warm-gray: #F0ECE6;
  --color-text: #2D2D2D;
  --color-text-light: #5A5A5A;
  --color-white: #FFFFFF;
  --color-border: #E0DBD3;
  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Nunito Sans', 'Segoe UI', sans-serif;
  --shadow-sm: 0 1px 3px rgba(27,42,74,0.08);
  --shadow-md: 0 4px 12px rgba(27,42,74,0.10);
  --shadow-lg: 0 8px 30px rgba(27,42,74,0.12);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --max-width: 1200px;
  --header-height: 70px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 17px; scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body { font-family: var(--font-body); color: var(--color-text); background: var(--color-cream); line-height: 1.75; overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--color-primary); text-decoration: none; transition: color 0.25s ease; }
a:hover { color: var(--color-accent); }
h1, h2, h3, h4, h5 { font-family: var(--font-heading); font-weight: 600; line-height: 1.25; color: var(--color-primary); }
h1 { font-size: clamp(1.8rem, 5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.5rem); }
ul { list-style: none; }
p + p { margin-top: 1em; }
.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 1.25rem; }

/* Skip Link */
.skip-link { position: absolute; top: -100%; left: 1rem; background: var(--color-primary); color: var(--color-white); padding: 0.5rem 1rem; border-radius: var(--radius-sm); z-index: 9999; font-size: 0.875rem; }
.skip-link:focus { top: 0.5rem; color: var(--color-white); }

/* noscript safety: show everything if JS disabled */
noscript .reveal { opacity: 1 !important; transform: none !important; }

/* ============================================================
   HEADER & NAVIGATION
   ============================================================ */
.site-header { position: fixed; top: 0; left: 0; right: 0; height: var(--header-height); background: var(--color-primary); box-shadow: 0 2px 8px rgba(0,0,0,0.15); z-index: 1000; transition: box-shadow 0.3s ease; }
.site-header.scrolled { box-shadow: 0 4px 16px rgba(0,0,0,0.2); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 1.25rem; }
.logo { display: flex; align-items: center; gap: 0.75rem; font-family: var(--font-heading); font-weight: 700; font-size: 1.1rem; color: var(--color-white); white-space: nowrap; z-index: 1001; }
.logo img { height: 44px; width: auto; }
.logo-text-full { display: none; }
.logo-text-short { display: inline; }

.nav-toggle { display: flex; flex-direction: column; justify-content: center; gap: 5px; background: none; border: none; cursor: pointer; padding: 0.5rem; z-index: 1001; }
.nav-toggle span { display: block; width: 26px; height: 2.5px; background: var(--color-white); border-radius: 2px; transition: transform 0.3s ease, opacity 0.3s ease; }
.nav-toggle.active span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

.main-nav { position: fixed; top: 0; right: -100%; width: 85%; max-width: 360px; height: 100vh; background: var(--color-white); box-shadow: var(--shadow-lg); padding: calc(var(--header-height) + 1rem) 1.5rem 2rem; overflow-y: auto; transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1); z-index: 999; }
.main-nav.open { right: 0; }
.nav-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); opacity: 0; visibility: hidden; transition: opacity 0.35s ease, visibility 0.35s ease; z-index: 998; }
.nav-overlay.visible { opacity: 1; visibility: visible; }
.nav-list > li { border-bottom: 1px solid var(--color-border); }
.nav-list > li > a, .nav-list > li > .dropdown-toggle { display: flex; align-items: center; justify-content: space-between; padding: 0.85rem 0; font-weight: 600; font-size: 1rem; color: var(--color-primary); background: none; border: none; width: 100%; cursor: pointer; font-family: var(--font-body); }
.nav-list > li > a:hover, .nav-list > li > .dropdown-toggle:hover { color: var(--color-accent); }
.dropdown-toggle .arrow { display: inline-block; width: 8px; height: 8px; border-right: 2px solid var(--color-primary); border-bottom: 2px solid var(--color-primary); transform: rotate(45deg); transition: transform 0.3s ease; margin-left: auto; }
.dropdown-toggle.expanded .arrow { transform: rotate(-135deg); }
.sub-nav { max-height: 0; overflow: hidden; transition: max-height 0.35s ease; }
.sub-nav.open { max-height: 600px; }
.sub-nav a { display: block; padding: 0.6rem 0 0.6rem 1.25rem; font-size: 0.95rem; color: var(--color-text-light); border-left: 2px solid var(--color-border); }
.sub-nav a:hover { color: var(--color-accent); border-left-color: var(--color-accent); }

@media (min-width: 768px) {
  .logo-text-full { display: inline; }
  .logo-text-short { display: none; }
}
@media (min-width: 1024px) {
  .nav-toggle { display: none; }
  .nav-overlay { display: none; }
  .main-nav { position: static; width: auto; max-width: none; height: auto; background: transparent; box-shadow: none; padding: 0; overflow: visible; transition: none; }
  .nav-list { display: flex; align-items: center; gap: 0.15rem; }
  .nav-list > li { border-bottom: none; position: relative; }
  .nav-list > li > a, .nav-list > li > .dropdown-toggle { padding: 0.5rem 0.7rem; font-size: 0.88rem; white-space: nowrap; border-radius: var(--radius-sm); color: rgba(255,255,255,0.9); }
  .nav-list > li > a:hover, .nav-list > li > .dropdown-toggle:hover { background: rgba(255,255,255,0.12); color: #fff; }
  .dropdown-toggle .arrow { width: 6px; height: 6px; margin-left: 0.35rem; border-color: rgba(255,255,255,0.7); }
  .sub-nav { position: absolute; top: 100%; left: 0; min-width: 240px; background: var(--color-white); box-shadow: var(--shadow-lg); border-radius: var(--radius-md); max-height: 0; opacity: 0; visibility: hidden; overflow: hidden; transition: max-height 0.3s ease, opacity 0.3s ease, visibility 0.3s ease; padding: 0; z-index: 100; }
  .sub-nav.open { max-height: 600px; opacity: 1; visibility: visible; padding: 0.5rem 0; }
  .sub-nav a { padding: 0.55rem 1.25rem; border-left: none; font-size: 0.88rem; color: var(--color-text); }
  .sub-nav a:hover { background: var(--color-warm-gray); color: var(--color-accent); }
}

/* ============================================================
   HERO SLIDESHOW
   ============================================================ */
.hero { position: relative; width: 100%; height: 65vh; min-height: 350px; max-height: 650px; overflow: hidden; margin-top: var(--header-height); background: var(--color-primary); }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease-in-out; }
.hero-slide.active { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(27,42,74,0.25) 0%, rgba(27,42,74,0.65) 100%); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 2rem 1.5rem; }
.hero-heading { font-family: var(--font-heading); font-size: clamp(2rem, 6vw, 3.5rem); font-weight: 700; color: var(--color-white); margin-bottom: 0.75rem; text-shadow: 0 2px 8px rgba(0,0,0,0.3); opacity: 0; transform: translateY(20px); animation: heroFadeUp 0.8s ease forwards 0.3s; }
.hero-sub { font-size: clamp(0.95rem, 2.5vw, 1.2rem); color: rgba(255,255,255,0.92); max-width: 600px; text-shadow: 0 1px 4px rgba(0,0,0,0.3); opacity: 0; transform: translateY(20px); animation: heroFadeUp 0.8s ease forwards 0.5s; }
.hero-dots { position: absolute; bottom: 1.5rem; left: 50%; transform: translateX(-50%); display: flex; gap: 0.5rem; z-index: 10; }
.hero-dot { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,0.5); border: none; cursor: pointer; transition: background 0.3s ease, transform 0.3s ease; padding: 0; }
.hero-dot.active { background: var(--color-white); transform: scale(1.25); }
@keyframes heroFadeUp { to { opacity: 1; transform: translateY(0); } }

/* ============================================================
   QUICK INFO BAR
   ============================================================ */
.quick-info { background: var(--color-primary); color: var(--color-white); padding: 1.5rem 0; }
.quick-info-grid { display: grid; grid-template-columns: 1fr; gap: 1.25rem; text-align: center; }
.quick-info-item { display: flex; flex-direction: column; align-items: center; gap: 0.35rem; }
.quick-info-label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.12em; color: rgba(255,255,255,0.6); font-weight: 600; }
.quick-info-value { font-size: 1rem; font-weight: 600; }
.quick-info-value a { color: var(--color-white); }
.quick-info-value a:hover { color: var(--color-accent-light); }
@media (min-width: 640px) { .quick-info-grid { grid-template-columns: repeat(3, 1fr); } }

/* ============================================================
   SECTIONS
   ============================================================ */
.section { padding: 3.5rem 0; }
.section--alt { background: var(--color-white); }
.section--dark { background: var(--color-primary); color: var(--color-white); }
.section--dark h2, .section--dark h3 { color: var(--color-white); }
.section-header { text-align: center; margin-bottom: 2.5rem; }
.section-header h2 { margin-bottom: 0.5rem; }
.section-label { display: inline-block; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.15em; font-weight: 700; color: var(--color-accent); margin-bottom: 0.5rem; }
.section-desc { color: var(--color-text-light); max-width: 650px; margin: 0 auto; font-size: 1.05rem; }

/* Service Times */
.times-grid { display: grid; grid-template-columns: 1fr; gap: 1.5rem; }
.time-card { background: var(--color-white); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 1.75rem; text-align: center; transition: box-shadow 0.3s ease, transform 0.3s ease; }
.time-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.time-card-title { font-family: var(--font-heading); font-size: 1.35rem; font-weight: 700; color: var(--color-primary); margin-bottom: 1rem; }
.time-row { display: flex; justify-content: space-between; padding: 0.4rem 0; border-bottom: 1px solid var(--color-warm-gray); font-size: 1rem; }
.time-row:last-child { border-bottom: none; }
.time-row .day { color: var(--color-text-light); }
.time-row .time { font-weight: 600; color: var(--color-primary); }
@media (min-width: 640px) { .times-grid { grid-template-columns: repeat(2, 1fr); } }

/* Welcome / CTA */
.welcome-content { max-width: 720px; margin: 0 auto; text-align: center; }
.welcome-content p { font-size: 1.05rem; color: var(--color-text-light); margin-bottom: 1rem; }
.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.75rem 1.75rem; border-radius: var(--radius-sm); font-weight: 600; font-size: 0.95rem; font-family: var(--font-body); border: none; cursor: pointer; transition: background 0.25s ease, transform 0.2s ease; text-decoration: none; }
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--color-accent); color: var(--color-white); }
.btn--primary:hover { background: var(--color-accent-light); color: var(--color-white); }
.btn--outline { background: transparent; border: 2px solid var(--color-primary); color: var(--color-primary); }
.btn--outline:hover { background: var(--color-primary); color: var(--color-white); }
.btn--outline-light { background: transparent; border: 2px solid rgba(255,255,255,0.7); color: var(--color-white); }
.btn--outline-light:hover { background: rgba(255,255,255,0.15); color: var(--color-white); }
.cta-buttons { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin-top: 1.5rem; }

/* Cards */
.card-grid { display: grid; grid-template-columns: 1fr; gap: 1.5rem; }
.card { background: var(--color-white); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 1.75rem; transition: box-shadow 0.3s ease, transform 0.3s ease; }
.card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.card h3 { font-size: 1.2rem; margin-bottom: 0.75rem; }
.card p { font-size: 1rem; color: var(--color-text-light); line-height: 1.65; }
@media (min-width: 640px) { .card-grid--2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .card-grid--3 { grid-template-columns: repeat(3, 1fr); } }

/* Leadership */
.leadership-category { margin-bottom: 2rem; }
.leadership-category h3 { font-size: 1.15rem; margin-bottom: 1rem; padding-bottom: 0.5rem; border-bottom: 2px solid var(--color-accent); display: inline-block; }
.leadership-names { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.leadership-name { background: var(--color-white); border: 1px solid var(--color-border); border-radius: var(--radius-sm); padding: 0.6rem 1.25rem; font-size: 1rem; font-weight: 600; color: var(--color-primary); transition: box-shadow 0.2s ease; }
.leadership-name:hover { box-shadow: var(--shadow-sm); }

/* About page blocks */
.about-block { max-width: 800px; margin: 0 auto 3rem; }
.about-block h2 { margin-bottom: 1rem; position: relative; padding-bottom: 0.75rem; }
.about-block h2::after { content: ''; position: absolute; bottom: 0; left: 0; width: 50px; height: 3px; background: var(--color-accent); border-radius: 2px; }
.about-block p, .about-block li { font-size: 1rem; color: var(--color-text-light); line-height: 1.8; }
.about-block ul { margin: 1rem 0; padding-left: 1.5rem; }
.about-block ul li { position: relative; padding-left: 0.75rem; margin-bottom: 0.5rem; }
.about-block ul li::before { content: ''; position: absolute; left: -0.75rem; top: 0.55em; width: 6px; height: 6px; background: var(--color-accent); border-radius: 50%; }

/* Map */
.map-container { border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-md); margin-top: 1.5rem; }
.map-container iframe { width: 100%; height: 300px; border: none; }
@media (min-width: 768px) { .map-container iframe { height: 400px; } }

/* Schedule Table */
.schedule-table-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; margin-top: 1.5rem; }
.schedule-table { width: 100%; border-collapse: collapse; font-size: 0.95rem; min-width: 500px; }
.schedule-table th { background: var(--color-primary); color: var(--color-white); padding: 0.75rem 1rem; text-align: left; font-weight: 600; font-size: 0.88rem; text-transform: uppercase; letter-spacing: 0.06em; }
.schedule-table td { padding: 0.65rem 1rem; border-bottom: 1px solid var(--color-border); vertical-align: top; }
.schedule-table tr:hover td { background: var(--color-warm-gray); }
.schedule-table a { color: var(--color-accent); font-weight: 600; }

/* Media Placeholder */
.media-placeholder { text-align: center; padding: 4rem 2rem; background: var(--color-white); border: 2px dashed var(--color-border); border-radius: var(--radius-lg); max-width: 700px; margin: 0 auto; }
.media-placeholder h3 { margin-bottom: 0.5rem; }
.media-placeholder p { color: var(--color-text-light); font-size: 1rem; }

/* TV Schedule */
.tv-schedule-card { background: var(--color-white); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 1.25rem 1.5rem; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 0.5rem; }
.tv-market { font-weight: 700; color: var(--color-primary); font-size: 1.05rem; }
.tv-station { font-size: 0.95rem; color: var(--color-text-light); }
.tv-time { font-size: 0.95rem; font-weight: 600; color: var(--color-accent); }

/* Resource Link Card */
.resource-link-card { display: flex; align-items: center; gap: 1rem; background: var(--color-white); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 1.25rem 1.5rem; transition: box-shadow 0.3s ease, transform 0.3s ease; }
.resource-link-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.resource-link-card h3 { font-size: 1.1rem; margin-bottom: 0.2rem; }
.resource-link-card p { font-size: 0.92rem; color: var(--color-text-light); margin: 0; }

/* PTP Highlight */
.ptp-highlight { text-align: center; max-width: 700px; margin: 0 auto; }
.ptp-highlight p { font-size: 1.05rem; color: var(--color-text-light); margin-bottom: 1.5rem; }

/* Footer */
.site-footer { background: var(--color-primary); color: rgba(255,255,255,0.8); padding: 3rem 0 1.5rem; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; margin-bottom: 2rem; }
.footer-col h4 { font-family: var(--font-heading); font-size: 1.1rem; color: var(--color-white); margin-bottom: 1rem; }
.footer-col p, .footer-col a { font-size: 0.95rem; color: rgba(255,255,255,0.7); line-height: 1.8; }
.footer-col a:hover { color: var(--color-accent-light); }
.footer-links { display: flex; flex-direction: column; gap: 0.25rem; }
.footer-links a { padding: 0.15rem 0; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.15); padding-top: 1.5rem; text-align: center; font-size: 0.88rem; color: rgba(255,255,255,0.45); }
@media (min-width: 640px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .footer-grid { grid-template-columns: repeat(3, 1fr); } }

/* Page Banner (inner pages) */
.page-banner { margin-top: var(--header-height); background: var(--color-primary); padding: 3rem 0; text-align: center; }
.page-banner h1 { color: var(--color-white); margin-bottom: 0.5rem; }
.page-banner p { color: rgba(255,255,255,0.7); font-size: 1rem; max-width: 600px; margin: 0 auto; }

/* Utility */
.text-center { text-align: center; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* Print */
@media print { .site-header, .hero, .site-footer, .nav-toggle, .btn { display: none; } body { font-size: 12pt; color: #000; background: #fff; } .page-banner { margin-top: 0; background: #fff; } .page-banner h1 { color: #000; } .reveal { opacity: 1 !important; transform: none !important; } }
