/*
Theme Name:  My World Ambassadors — Spectra One
Template:    spectra-one
Description: MWA branded child theme for Spectra One. Warm, welcoming palette with tan header, cream body, and teal accents.
Version:     1.4.4
Author:      My World Ambassadors
Author URI:  https://myworldambassadors.com
*/

/*
  ── HOW THIS THEME WORKS ────────────────────────────────────────
  Fonts and colors are controlled in two places:

  1. SITE EDITOR  (Appearance → Editor → click the ◑ Styles icon)
     Change fonts, heading sizes, and colors here — no zip upload needed.
     This is the right place for day-to-day tweaks.

  2. THIS FILE  (style.css)
     Controls buttons, spacing, and layout things the Site Editor can't do.
     Also holds the brand color tokens (:root section below).
     Requires a new zip upload to take effect.

  To change which Google Font loads → also update functions.php.
  ────────────────────────────────────────────────────────────────
*/

/* ── Brand color tokens ──────────────────────────────────────── */
/* Change a hex value here to update it across all CSS in this file.
   Colors also need to be updated in theme.json palette to show in
   the Site Editor color picker. */
:root {
  --mwa-cream:        #f8f4ef;
  --mwa-cream-dark:   #f0e8de;
  --mwa-white:        #ffffff;

  --mwa-tan:          #c8956a;   /* eyebrow labels, header accent */
  --mwa-tan-dark:     #a87852;
  --mwa-tan-light:    #e8c9a8;

  --mwa-teal:         #2d7d72;   /* primary CTA buttons, links */
  --mwa-teal-dark:    #235f57;
  --mwa-teal-light:   #a8d5cf;
  --mwa-mint:         #ceeac8;   /* light CTA section background */

  --mwa-charcoal:     #2d3436;   /* headings */
  --mwa-muted:        #6b7280;   /* body paragraphs */

  --mwa-navy:         #0B1E33;   /* Deep navy background */
  --mwa-navy-mid:     #16213e;
  --mwa-navy-light:   #2d2d52;

  --mwa-gold:         #D4AF37;   /* Gold accent */
  --mwa-gold-dark:    #a8883c;
  --mwa-gold-light:   #e8d5a3;
  --mwa-light-gray:   #C7D2E0;   /* Light gray body text */
}

/* ── Base body ───────────────────────────────────────────────── */
body {
  background-color: var(--mwa-cream);
  color: var(--mwa-charcoal);
  font-family: 'Inter', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ── Headings ────────────────────────────────────────────────── */
/* Font family and size are controlled by theme.json and the Site Editor.
   Do NOT set font-family or font-weight here — it would block Global Styles
   changes from taking effect (CSS specificity beats :root :where() output).
   Only set color here as a fallback. */
h1, h2, h3, h4,
.wp-block-heading {
  color: var(--mwa-charcoal);
}

/* H5/H6 are functional labels — keep as Inter bold regardless of heading font choice */
h5, h6 {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 700;
  color: var(--mwa-charcoal);
}

/* ── Body text ───────────────────────────────────────────────── */
/* Paragraphs use the softer muted gray for comfortable reading */
.wp-block-post-content p,
.wp-block-post-content .wp-block-paragraph,
.wp-block-post-date,
.wp-block-post-terms,
.wp-block-post-author__name,
.entry-meta,
.posted-on {
  color: var(--mwa-muted);
}

/* ── Links ───────────────────────────────────────────────────── */
a { color: var(--mwa-teal); text-decoration: none; }
a:hover { color: var(--mwa-teal-dark); }

/* ── Buttons ─────────────────────────────────────────────────── */
.wp-block-button__link,
.wp-element-button {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 600;
  letter-spacing: 0.04em;
  border-radius: 100px;
  padding: 0.75rem 2rem;
  transition: all 0.2s ease;
}

/* Teal fill (primary) */
.wp-block-button.is-style-fill .wp-block-button__link {
  background: var(--mwa-teal);
  color: var(--mwa-white);
  border: none;
}
.wp-block-button.is-style-fill .wp-block-button__link:hover {
  background: var(--mwa-teal-dark);
  color: var(--mwa-white);
}

/* Outline */
.wp-block-button.is-style-outline .wp-block-button__link {
  border-color: var(--mwa-charcoal);
  color: var(--mwa-charcoal);
}
.wp-block-button.is-style-outline .wp-block-button__link:hover {
  background: var(--mwa-charcoal);
  color: var(--mwa-white);
}

/* Tan/warm variant */
.is-style-mwa-tan .wp-block-button__link {
  background: var(--mwa-tan);
  color: var(--mwa-white);
  border: none;
}
.is-style-mwa-tan .wp-block-button__link:hover {
  background: var(--mwa-tan-dark);
  color: var(--mwa-white);
}

/* ── Header — structural only, colors via Site Editor ──────────── */
.wp-block-navigation .wp-block-navigation__container {
  gap: clamp(0.5rem, 2vw, 1.5rem);
}
.wp-block-navigation .wp-block-button,
.wp-block-navigation .wp-block-navigation-item .wp-block-button {
  margin-left: 1rem;
}

/* ── Footer ──────────────────────────────────────────────────── */
/* Layout structure, spacing, typography sizes, and interactive styles.
   Colors are linked to the theme.json palette to ensure FSE site editor settings work. */

.wp-block-group.has-background.has-mwa-navy-background-color {
  padding-top: 50px !important;
  padding-bottom: 50px !important;
}

.mwa-footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 40px;
}

.mwa-footer-col {
  display: flex;
  flex-direction: column;
  position: relative;
}

/* Subtle vertical divider lines */
.mwa-footer-col:not(:last-child)::after {
  content: '';
  position: absolute;
  right: -20px;
  top: 0;
  bottom: 0;
  width: 1px;
  background-color: rgba(255, 255, 255, 0.15);
}

.mwa-footer-brand {
  align-items: flex-start;
}

.mwa-footer-logo {
  max-height: 48px;
  width: auto;
  margin-bottom: 20px;
  display: block;
}

.mwa-footer-tagline {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  color: var(--mwa-light-gray);
  margin-bottom: 24px;
}

/* Social icons */
.mwa-footer-social {
  display: flex;
  gap: 16px;
  align-items: center;
}

.mwa-footer-social a {
  color: var(--mwa-white) !important;
  font-size: 20px;
  transition: color 0.3s ease, transform 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.mwa-footer-social a:hover {
  color: var(--mwa-gold) !important;
  transform: translateY(-2px);
}

.mwa-footer-social svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
  transition: fill 0.3s ease;
}

/* Column Headings */
.mwa-footer-col h3 {
  color: var(--mwa-white) !important;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 18px !important;
  font-weight: 700 !important;
  letter-spacing: 0.05em;
  margin-top: 0;
  margin-bottom: 24px !important;
  text-transform: uppercase;
}

/* Column Links & Lists */
.mwa-footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mwa-footer-col ul li a {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 16px;
  color: var(--mwa-white) !important;
  transition: color 0.3s ease, padding-left 0.3s ease;
  display: inline-block;
}

.mwa-footer-col ul li a:hover {
  color: var(--mwa-gold) !important;
  padding-left: 4px;
}

/* Column 4: Stay Connected Description */
.mwa-footer-subscribe p {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  color: var(--mwa-light-gray);
  margin-bottom: 20px;
}

/* Subscribe Form */
.mwa-subscribe-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.mwa-subscribe-form input[type="email"] {
  height: 48px;
  padding: 0 16px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background-color: rgba(255, 255, 255, 0.05);
  color: var(--mwa-white) !important;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 15px;
  transition: border-color 0.3s ease, background-color 0.3s ease;
  width: 100%;
  box-sizing: border-box;
}

.mwa-subscribe-form input[type="email"]::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.mwa-subscribe-form input[type="email"]:focus {
  border-color: var(--mwa-gold);
  background-color: rgba(255, 255, 255, 0.1);
  outline: none;
}

.mwa-subscribe-form button {
  height: 48px;
  background-color: var(--mwa-gold) !important;
  color: var(--mwa-white) !important;
  border: none;
  border-radius: 8px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.mwa-subscribe-form button:hover {
  background-color: var(--mwa-gold-dark) !important;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.3);
}

.mwa-subscribe-form button:active {
  transform: scale(0.98);
}

/* Divider Line */
.mwa-footer-divider {
  border: 0;
  height: 1px;
  background-color: rgba(255, 255, 255, 0.15);
  margin: 30px 0 0 0;
  width: 100%;
}

/* Bottom Bar */
.mwa-footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 60px;
  max-width: 1200px;
  margin: 0 auto;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14px;
  color: var(--mwa-light-gray);
}

.mwa-footer-bottom a {
  color: var(--mwa-light-gray) !important;
  transition: color 0.3s ease;
}

.mwa-footer-bottom a:hover {
  color: var(--mwa-gold) !important;
}

.mwa-footer-bottom .mwa-divider-span {
  margin: 0 8px;
  color: rgba(255, 255, 255, 0.15);
}

/* Responsive Media Queries */
@media (max-width: 992px) {
  .mwa-footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
  }
  .mwa-footer-col:nth-child(2)::after {
    display: none;
  }
}

@media (max-width: 768px) {
  .wp-block-group.has-background.has-mwa-navy-background-color {
    padding-top: 40px !important;
    padding-bottom: 30px !important;
  }
  .mwa-footer-grid {
    grid-template-columns: 1fr;
    gap: 35px;
    padding-bottom: 30px;
  }
  .mwa-footer-col:not(:last-child)::after {
    display: none;
  }
  .mwa-footer-col {
    align-items: center;
    text-align: center;
  }
  .mwa-footer-social {
    justify-content: center;
  }
  .mwa-footer-bottom {
    flex-direction: column;
    justify-content: center;
    gap: 12px;
    height: auto;
    padding: 20px 0;
  }
  .mwa-subscribe-form {
    max-width: 320px;
    margin: 0 auto;
  }
}

/* ── Section label (uppercase eyebrow tag above headings) ───── */
.mwa-label {
  display: block;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--mwa-tan);
  margin-bottom: 0.75rem;
}

/* ── Hero section ────────────────────────────────────────────── */
.mwa-hero {
  min-height: 90vh;
  background: linear-gradient(160deg, var(--mwa-cream) 0%, var(--mwa-cream-dark) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6rem 2rem;
  position: relative;
  overflow: hidden;
}
.mwa-hero::before {
  content: '';
  position: absolute;
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(200,149,106,0.12) 0%, transparent 65%);
  top: -150px; right: -150px;
  pointer-events: none;
}
.mwa-hero::after {
  content: '';
  position: absolute;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(45,125,114,0.08) 0%, transparent 65%);
  bottom: -100px; left: -100px;
  pointer-events: none;
}
.mwa-hero-inner { position: relative; z-index: 1; max-width: 860px; margin: 0 auto; }
.mwa-hero h1 {
  font-size: clamp(2.2rem, 5vw, 4rem);
  color: var(--mwa-charcoal);
  line-height: 1.15;
  margin-bottom: 1.5rem;
}
.mwa-hero p {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--mwa-muted);
  line-height: 1.7;
  max-width: 600px;
  margin: 0 auto 2.5rem;
}

/* ── Colored section utilities ───────────────────────────────── */
.mwa-section-tan {
  background: linear-gradient(135deg, var(--mwa-tan) 0%, var(--mwa-tan-dark) 100%);
  color: var(--mwa-white);
  padding: 5rem 2rem;
  text-align: center;
}
.mwa-section-tan h2,
.mwa-section-tan h3 { color: var(--mwa-white); }

.mwa-section-teal {
  background: var(--mwa-teal);
  color: var(--mwa-white);
  padding: 5rem 2rem;
}
.mwa-section-teal h2,
.mwa-section-teal h3 { color: var(--mwa-white); }
.mwa-section-teal .mwa-label { color: var(--mwa-tan-light); }

.mwa-section-navy {
  background: var(--mwa-navy);
  color: rgba(248,244,239,0.85);
  padding: 5rem 2rem;
}
.mwa-section-navy h2,
.mwa-section-navy h3 { color: var(--mwa-tan-light); }

/* ── Ambassador card ─────────────────────────────────────────── */
.mwa-ambassador-card {
  background: var(--mwa-white);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(200,149,106,0.2);
  transition: box-shadow 0.25s ease, transform 0.2s ease;
}
.mwa-ambassador-card:hover {
  box-shadow: 0 12px 40px rgba(45,52,54,0.1);
  transform: translateY(-4px);
}

/* ── Section header utility ──────────────────────────────────── */
.mwa-section-header { text-align: center; margin-bottom: 3rem; }
.mwa-section-header h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-top: 0.5rem;
  color: var(--mwa-charcoal);
}
.mwa-section-header p {
  color: var(--mwa-muted);
  max-width: 560px;
  margin: 1rem auto 0;
  line-height: 1.7;
}

/* ── Block editor background color helpers ───────────────────── */
/* When a dark palette color is used as a block background,
   flip the text to a light color automatically */
.has-mwa-tan-background-color      { color: var(--mwa-white); }
.has-mwa-teal-background-color     { color: var(--mwa-white); }
.has-mwa-navy-background-color     { color: var(--mwa-tan-light); }
.has-mwa-charcoal-background-color { color: var(--mwa-cream); }

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 768px) {
  .mwa-hero { min-height: 80vh; padding: 4rem 1.5rem; }
}

/* ─── Inline Image & Embed Constraints ────────────────────────── */
.wp-block-post-content img,
.entry-content img,
.post-content img,
.wp-block-image img,
img,
iframe,
video,
.ql-video {
  max-width: 100% !important;
  box-sizing: border-box;
}

.wp-block-post-content img,
.entry-content img,
.post-content img,
.wp-block-image img,
img {
  height: auto !important;
}

/* ── Premium UI Enhancements ────────────────────────────────── */

/* Card Hover Lift & Soft Drop Shadows */
/* Targeting Gutenberg Columns which serve as the grid cards */
.wp-block-columns .wp-block-column {
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s ease, border-color 0.3s ease;
  will-change: transform, box-shadow;
}

.wp-block-columns .wp-block-column:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(45, 52, 54, 0.08);
  border-color: rgba(200, 149, 106, 0.4) !important;
}

/* Form Input Styling & Soft Glow Focus */
#mwa-apply-form input[type="text"],
#mwa-apply-form input[type="email"],
#mwa-apply-form input[type="tel"],
#mwa-apply-form select,
#mwa-apply-form textarea {
  background-color: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--mwa-white);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  transition: all 0.3s ease;
}

#mwa-apply-form input[type="text"]:focus,
#mwa-apply-form input[type="email"]:focus,
#mwa-apply-form input[type="tel"]:focus,
#mwa-apply-form select:focus,
#mwa-apply-form textarea:focus {
  background-color: rgba(255, 255, 255, 0.08);
  border-color: var(--mwa-tan-light);
  box-shadow: 0 0 12px rgba(232, 201, 168, 0.25);
  outline: none;
}

/* Primary CTA Hover Enhancements */
.wp-block-button__link,
.wp-element-button {
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), background-color 0.25s ease, box-shadow 0.25s ease;
}

.wp-block-button__link:hover,
.wp-element-button:hover {
  transform: scale(1.03);
  box-shadow: 0 8px 20px rgba(45, 125, 114, 0.2);
}

/* Submit button alignment with brand signature gold */
.mwa-submit-btn,
#mwa-submit-btn {
  background: linear-gradient(135deg, var(--mwa-tan) 0%, var(--mwa-tan-dark) 100%) !important;
  color: var(--mwa-white) !important;
  border: none !important;
  font-weight: 700 !important;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 1rem 2.5rem !important;
  border-radius: 100px !important;
  transition: all 0.3s ease !important;
  box-shadow: 0 4px 15px rgba(200, 149, 106, 0.3) !important;
  cursor: pointer;
}

.mwa-submit-btn:hover,
#mwa-submit-btn:hover {
  background: linear-gradient(135deg, var(--mwa-tan-dark) 0%, var(--mwa-tan) 100%) !important;
  transform: translateY(-2px) scale(1.02) !important;
  box-shadow: 0 8px 25px rgba(200, 149, 106, 0.45) !important;
}

/* Header "Want to Join?" button active styling */
.is-style-swt-button-inverse .wp-block-button__link,
a.wp-block-button__link[href*="#apply"] {
  background-color: var(--mwa-white) !important;
  color: var(--mwa-teal) !important;
  border: 1px solid var(--mwa-teal) !important;
}

.is-style-swt-button-inverse .wp-block-button__link:hover,
a.wp-block-button__link[href*="#apply"]:hover {
  background-color: var(--mwa-teal) !important;
  color: var(--mwa-white) !important;
  box-shadow: 0 6px 15px rgba(45, 125, 114, 0.15) !important;
}

/* ─── Single Post / Article Styling Fixes (CSMW Match) ────────── */
/* Hide the default theme post title banner and featured image to prevent duplicates */
.single-mwa_article .swt-block-post-banner-group,
.single-mwa_article .swt-block-featured-image,
.single-mwa_article .wp-block-post-featured-image {
  display: none !important;
}

/* Set page background to match the warm cream of CSMW virtual pages */
body.single-mwa_article {
  background-color: #fbf8f3 !important;
}

/* Hide default theme author block and separator at the bottom of single article pages */
.single-mwa_article .wp-block-post-author,
.single-mwa_article .wp-block-separator {
  display: none !important;
}

