/*
Theme Name: Continuity Mobile
Theme URI: https://mattgraphy.design
Author: Mattgraphy
Author URI: https://mattgraphy.design
Description: A custom responsive WordPress theme for Continuity Mobile with a video hero, Customizer controls, and a polished one-page healthcare layout.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: continuity-mobile
Tags: custom-logo, custom-menu, featured-images, one-column, accessibility-ready, custom-colors
*/

:root {
  --cm-primary: #6d57a5;
  --cm-primary-dark: #544085;
  --cm-secondary: #8a78c6;
  --cm-accent: #efe9fb;
  --cm-bg: #ffffff;
  --cm-surface: #f7f4fc;
  --cm-text: #2e2a3d;
  --cm-muted: #726d84;
  --cm-border: rgba(84, 64, 133, 0.14);
  --cm-overlay: rgba(63, 42, 112, 0.62);
  --cm-shadow: 0 18px 48px rgba(52, 34, 92, 0.12);
  --cm-radius: 22px;
  --cm-container: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
  color: var(--cm-text);
  background: var(--cm-bg);
  line-height: 1.65;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--cm-primary-dark); }
button, input, textarea { font: inherit; }

.cm-container {
  width: min(var(--cm-container), calc(100% - 40px));
  margin: 0 auto;
}

.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute !important;
  width: 1px;
  word-wrap: normal !important;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--cm-border);
}

.header-inner {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.site-branding img {
  max-height: 62px;
  width: auto;
}

.site-title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--cm-primary-dark);
}

.site-description {
  margin: 4px 0 0;
  color: var(--cm-muted);
  font-size: .95rem;
}

.main-navigation ul {
  display: flex;
  list-style: none;
  gap: 28px;
  padding: 0;
  margin: 0;
  align-items: center;
}

.main-navigation a {
  font-weight: 700;
  font-size: 0.98rem;
}

.menu-toggle {
  display: none;
  border: 1px solid var(--cm-border);
  background: #fff;
  color: var(--cm-primary-dark);
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 700;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: min(100svh, 900px);
  display: flex;
  align-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--cm-primary-dark), var(--cm-primary));
}

.hero-media,
.hero-fallback {
  position: absolute;
  inset: 0;
}

.hero-video,
.hero-fallback img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(70, 45, 125, 0.78), rgba(109, 87, 165, 0.48));
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 120px 0 100px;
  width: min(760px, 100%);
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border: 1px solid rgba(255,255,255,.28);
  background: rgba(255,255,255,.08);
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.hero h1 {
  font-size: clamp(2.7rem, 5vw, 5.15rem);
  line-height: 1.02;
  margin: 22px 0 16px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero p {
  font-size: clamp(1.05rem, 1.8vw, 1.22rem);
  color: rgba(255,255,255,.92);
  margin: 0 0 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.cm-button,
input.wpcf7-submit,
button,
.wp-block-button__link {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 16px 24px;
  min-height: 56px;
  border-radius: 14px;
  border: 0;
  font-weight: 800;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.cm-button:hover,
input.wpcf7-submit:hover,
.wp-block-button__link:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(40, 28, 72, 0.18);
}

.cm-button-primary,
input.wpcf7-submit {
  background: #fff;
  color: var(--cm-primary-dark);
}

.cm-button-secondary {
  background: rgba(255,255,255,.12);
  color: #fff;
  border: 1px solid rgba(255,255,255,.25);
}

.section {
  padding: 88px 0;
}

.section-alt {
  background: var(--cm-surface);
}

.section-header {
  max-width: 800px;
  margin: 0 auto 46px;
  text-align: center;
}

.section-header .eyebrow {
  color: var(--cm-primary);
  text-transform: uppercase;
  letter-spacing: .12em;
  font-weight: 800;
  font-size: .82rem;
  margin-bottom: 10px;
}

.section-header h2 {
  margin: 0 0 16px;
  font-size: clamp(2rem, 4vw, 3.35rem);
  line-height: 1.06;
  color: var(--cm-primary-dark);
}

.section-header p {
  margin: 0;
  font-size: 1.06rem;
  color: var(--cm-muted);
}

.about-grid,
.contact-grid,
.cta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px;
  align-items: center;
}

.about-card,
.contact-card,
.value-card,
.service-card,
.stat-card,
.cta-panel {
  background: #fff;
  border: 1px solid var(--cm-border);
  border-radius: var(--cm-radius);
  box-shadow: var(--cm-shadow);
}

.about-card {
  padding: 40px;
}

.about-card p:last-child,
.cta-panel p:last-child,
.contact-card p:last-child { margin-bottom: 0; }

.about-media img,
.service-card img {
  border-radius: var(--cm-radius);
  width: 100%;
  object-fit: cover;
}

.badge-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.badge {
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--cm-accent);
  color: var(--cm-primary-dark);
  font-size: .92rem;
  font-weight: 700;
}

.values-grid,
.services-grid,
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.services-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.value-card,
.stat-card {
  padding: 30px 24px;
  text-align: center;
}

.value-icon,
.stat-icon {
  width: 68px;
  height: 68px;
  border-radius: 20px;
  background: var(--cm-accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--cm-primary-dark);
  margin-bottom: 18px;
  font-size: 1.6rem;
  font-weight: 900;
}

.value-card h3,
.service-card h3,
.stat-card h3,
.contact-card h3,
.cta-panel h3 {
  margin: 0 0 10px;
  color: var(--cm-primary-dark);
  font-size: 1.35rem;
}

.value-card p,
.service-card p,
.stat-card p,
.contact-card p {
  margin: 0;
  color: var(--cm-muted);
}

.service-card {
  overflow: hidden;
}

.service-card .service-image {
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, var(--cm-secondary), var(--cm-primary));
}

.service-card .service-body {
  padding: 24px;
}

.service-card p { font-size: .98rem; }

.stats-wrap {
  background: linear-gradient(135deg, var(--cm-primary-dark), var(--cm-primary));
  border-radius: 34px;
  padding: 26px;
  color: #fff;
}

.stat-card {
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.14);
  color: #fff;
  box-shadow: none;
}

.stat-card h3,
.stat-card p,
.stat-card .stat-value,
.stat-icon { color: #fff; }
.stat-icon { background: rgba(255,255,255,.12); }
.stat-value {
  font-weight: 900;
  font-size: 2rem;
  line-height: 1;
  margin-bottom: 10px;
}

.cta-panel {
  padding: 40px;
}

.cta-strip {
  background: linear-gradient(135deg, var(--cm-primary-dark), var(--cm-primary));
  color: #fff;
  border-radius: 34px;
  padding: 38px;
}

.cta-strip h2, .cta-strip p { margin-top: 0; }
.cta-strip h2 { font-size: clamp(1.9rem, 3vw, 3rem); line-height: 1.08; }
.cta-strip p { color: rgba(255,255,255,.9); }

.contact-card {
  padding: 36px;
  height: 100%;
}

.contact-list {
  display: grid;
  gap: 18px;
  margin-top: 24px;
}

.contact-item strong {
  display: block;
  color: var(--cm-primary-dark);
  font-size: .95rem;
  margin-bottom: 4px;
}

.cf7-wrap {
  background: #fff;
  border: 1px solid var(--cm-border);
  border-radius: var(--cm-radius);
  box-shadow: var(--cm-shadow);
  padding: 32px;
}

.wpcf7-form p { margin: 0 0 18px; }
.wpcf7-form label {
  display: block;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--cm-primary-dark);
}

.wpcf7-form-control-wrap { display: block; margin-top: 8px; }
.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form textarea,
.wpcf7-form select {
  width: 100%;
  border: 1px solid var(--cm-border);
  border-radius: 14px;
  padding: 15px 16px;
  background: #fff;
  color: var(--cm-text);
}

.wpcf7-form textarea { min-height: 180px; resize: vertical; }
.wpcf7-spinner { display: none; }

.site-footer {
  background: #231d34;
  color: rgba(255,255,255,.8);
  padding: 34px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.footer-brand img {
  max-height: 52px;
  width: auto;
}

.footer-branding-text strong {
  display: block;
  color: #fff;
}

.footer-menu ul {
  display: flex;
  list-style: none;
  gap: 18px;
  margin: 0;
  padding: 0;
}

@media (max-width: 1100px) {
  .values-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .menu-toggle { display: inline-flex; }
  .main-navigation {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255,255,255,.98);
    border-bottom: 1px solid var(--cm-border);
    padding: 14px 20px 22px;
    display: none;
  }
  .main-navigation.is-open { display: block; }
  .main-navigation ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .about-grid,
  .contact-grid,
  .cta-grid,
  .services-grid,
  .values-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }
  .hero-content { padding: 110px 0 80px; }
}

@media (max-width: 640px) {
  .cm-container { width: min(var(--cm-container), calc(100% - 24px)); }
  .section { padding: 68px 0; }
  .about-card,
  .contact-card,
  .cta-panel,
  .cf7-wrap { padding: 24px; }
  .cta-strip { padding: 26px; border-radius: 24px; }
  .stats-wrap { padding: 18px; border-radius: 24px; }
  .hero-actions { flex-direction: column; }
  .cm-button, input.wpcf7-submit { width: 100%; }
  .footer-inner { align-items: flex-start; }
  .footer-menu ul { flex-direction: column; gap: 10px; }
}
