/*
Theme Name: MedSyn Consulting
Theme URI: https://www.medsynconsulting.com/
Author: Mark Grier, Ph.D.
Author URI: https://www.medsynconsulting.com/
Description: Combined consulting theme with three client paths — Principal, Discovery, and Counsel — and Elementor as the page editor. Full Width and Canvas templates on every page.
Version: 1.2.1
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: medsyn-consulting
*/

:root,
html[data-theme="principal"] {
  --canvas: #f3eee4;
  --canvas-2: #e7e0d2;
  --elevated: #faf6ee;
  --ink: #1c2430;
  --muted: #4f5864;
  --subtle: #7a7468;
  --accent: #243246;
  --accent-fg: #f3eee4;
  --line: rgba(28, 36, 48, 0.14);
  --ring: #243246;
  --display: "Cormorant Garamond", "Liberation Serif", Georgia, serif;
  --body: "Source Sans 3", "Liberation Sans", ui-sans-serif, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --shadow:
    0 0 0 1px rgba(28, 36, 48, 0.08),
    0 1px 2px -1px rgba(28, 36, 48, 0.08),
    0 8px 24px -16px rgba(28, 36, 48, 0.16);
  --pad: clamp(1.25rem, 4vw, 3.5rem);
  --max: 72rem;
  --switcher-bg: #ebe4d6;
}

html[data-theme="discovery"] {
  --canvas: #0e1113;
  --canvas-2: #161b1e;
  --elevated: #1b2124;
  --ink: #e8eeeb;
  --muted: #a3b0ab;
  --subtle: #73807b;
  --accent: #8fb8ab;
  --accent-fg: #101412;
  --line: rgba(232, 238, 235, 0.12);
  --ring: #8fb8ab;
  --display: "IBM Plex Sans", "Liberation Sans", ui-sans-serif, system-ui, sans-serif;
  --body: "IBM Plex Sans", "Liberation Sans", ui-sans-serif, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --shadow: 0 0 0 1px rgba(232, 238, 235, 0.10);
  --switcher-bg: #12171a;
}

html[data-theme="counsel"] {
  --canvas: #f6f1e8;
  --canvas-2: #ebe3d4;
  --elevated: #fbf7f0;
  --ink: #1a1814;
  --muted: #534e45;
  --subtle: #857e70;
  --accent: #3c4640;
  --accent-fg: #f6f1e8;
  --line: rgba(26, 24, 20, 0.13);
  --ring: #3c4640;
  --display: "Source Serif 4", "Liberation Serif", Georgia, serif;
  --body: "Source Sans 3", "Liberation Sans", ui-sans-serif, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --shadow:
    0 0 0 1px rgba(26, 24, 20, 0.09),
    0 10px 28px -18px rgba(26, 24, 20, 0.18);
  --switcher-bg: #efe7d8;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.medsyn-body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.55;
  min-height: 100%;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
}

h1, h2, h3, h4 {
  text-wrap: balance;
  letter-spacing: -0.02em;
}

p {
  text-wrap: pretty;
}

button:not(:disabled),
[role="button"]:not(:disabled) {
  cursor: pointer;
}

::selection {
  background: color-mix(in oklab, var(--accent) 28%, transparent);
  color: var(--ink);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-fg);
  padding: 0.5rem 1rem;
  z-index: 100;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.page-pad {
  padding-inline: var(--pad);
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
}

.display {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.08;
}

.kicker {
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--subtle);
  margin: 0;
}

.surface {
  background: var(--elevated);
  box-shadow: var(--shadow);
}

.hairline {
  height: 1px;
  background: var(--line);
}

.frame {
  outline: 1px solid color-mix(in oklab, var(--ink) 12%, transparent);
  outline-offset: -1px;
  object-fit: cover;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0 1.25rem;
  border: 0;
  border-radius: 8px;
  font-family: var(--body);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  transition: opacity 0.15s ease, transform 0.15s ease, background-color 0.15s ease;
}
.btn:active {
  transform: scale(0.98);
}
.btn-primary {
  background: var(--accent);
  color: var(--accent-fg);
}
.btn-primary:hover {
  opacity: 0.92;
}
.btn-outline {
  background: transparent;
  color: var(--ink);
  box-shadow: 0 0 0 1px var(--line);
}
.btn-outline:hover {
  background: var(--canvas-2);
}
.btn-lg {
  min-height: 3rem;
  padding: 0 1.5rem;
}

/* Practice chooser */
.site-chrome {
  position: sticky;
  top: 0;
  z-index: 30;
}
.admin-bar .site-chrome {
  top: 32px;
}
.practice-bar {
  border-bottom: 1px solid var(--line);
  background: var(--switcher-bg);
}
.practice-bar-inner {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-block: 0.75rem;
}
@media (min-width: 640px) {
  .practice-bar-inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}
.practice-prompt {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--subtle);
}
.practice-prompt-sub {
  margin: 0.25rem 0 0;
  font-size: 0.7rem;
  color: var(--subtle);
}
.practice-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.25rem;
  padding: 0.25rem;
  border-radius: 8px;
  box-shadow: 0 0 0 1px var(--line);
}
@media (min-width: 640px) {
  .practice-tabs {
    display: flex;
  }
}
.practice-tab {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 2.75rem;
  padding: 0.5rem 0.75rem;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--ink);
  font-family: var(--body);
  text-decoration: none;
  text-align: left;
}
.practice-tab:hover {
  background: var(--elevated);
}
.practice-tab.is-active {
  background: var(--ink);
  color: var(--canvas);
}
.practice-tab-label {
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.1;
}
.practice-tab-short {
  display: none;
  margin-top: 0.2rem;
  font-size: 0.6875rem;
  line-height: 1.2;
  opacity: 0.75;
}
@media (min-width: 640px) {
  .practice-tab {
    min-width: 9.5rem;
    min-height: 3.5rem;
    padding: 0.6rem 1rem;
  }
  .practice-tab-short { display: block; }
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--line);
  background: color-mix(in oklab, var(--canvas) 90%, transparent);
  backdrop-filter: blur(8px);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: 4rem;
}
.brand {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  text-decoration: none;
}
.brand-name {
  font-family: var(--display);
  font-size: 1.5rem;
  letter-spacing: -0.03em;
  line-height: 1;
}
.brand-practice {
  display: none;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--subtle);
}
.nav-desktop {
  display: none;
  align-items: center;
  gap: 1.75rem;
}
.nav-desktop ul {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.nav-desktop a {
  text-decoration: none;
  font-size: 0.875rem;
  color: var(--muted);
}
.nav-desktop a:hover,
.nav-desktop a.current-menu-item,
.nav-desktop .current-menu-item > a,
.nav-desktop a[aria-current="page"] {
  color: var(--ink);
}
.menu-toggle {
  width: 2.75rem;
  height: 2.75rem;
  border: 0;
  background: transparent;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.nav-mobile {
  display: none;
  border-top: 1px solid var(--line);
  padding-bottom: 1.5rem;
}
.nav-mobile.is-open {
  display: block;
}
.nav-mobile a {
  display: flex;
  align-items: center;
  min-height: 3rem;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}
.nav-mobile .btn {
  width: 100%;
  margin-top: 1rem;
}

@media (min-width: 1024px) {
  .brand-practice { display: inline; }
  .nav-desktop { display: flex; }
  .menu-toggle { display: none; }
  .nav-mobile { display: none !important; }
}

/* Hero */
.hero {
  display: grid;
  gap: 2.5rem;
  align-items: center;
  padding-block: 4rem;
}
.hero h1 {
  margin: 1.25rem 0 0;
  font-size: clamp(2.6rem, 6vw, 4.25rem);
}
.hero .deck {
  margin: 1.5rem 0 0;
  max-width: 36rem;
  font-size: 1.125rem;
  color: var(--muted);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}
.hero-image {
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: 14px;
}
@media (min-width: 1024px) {
  .hero {
    grid-template-columns: 1.05fr 0.95fr;
    padding-block: 6rem;
  }
  .hero-image { aspect-ratio: 5 / 6; }
}

.hero-discovery {
  display: grid;
  background: var(--canvas);
  padding: 0;
}
.hero-discovery .hero-copy {
  padding: 4rem var(--pad);
}
.hero-discovery .hero-image {
  width: 100%;
  height: 16rem;
  aspect-ratio: auto;
  border-radius: 0;
}
@media (min-width: 1024px) {
  .hero-discovery {
    grid-template-columns: 1.05fr 0.95fr;
    min-height: 78vh;
  }
  .hero-discovery .hero-copy {
    display: flex;
    align-items: end;
    justify-content: end;
    padding-block: 5rem;
  }
  .hero-discovery .hero-copy-inner { width: 100%; max-width: 36rem; }
  .hero-discovery .hero-image {
    height: 100%;
    min-height: 78vh;
    object-fit: cover;
  }
}

.hero-counsel {
  display: block;
  max-width: 56rem;
  margin-inline: auto;
  text-align: center;
  padding-block: 4rem;
}
.hero-counsel .deck {
  margin-inline: auto;
}
.hero-counsel .hero-actions {
  justify-content: center;
}
.hero-counsel .hero-image {
  margin-top: 3.5rem;
  aspect-ratio: 16 / 8;
  border-radius: 8px;
}

/* Proof */
.proof {
  border-block: 1px solid var(--line);
  background: var(--canvas-2);
}
.proof-grid {
  display: grid;
  gap: 2rem;
  padding-block: 2.5rem;
}
.proof-value {
  margin: 0;
  font-size: clamp(2.25rem, 4vw, 3rem);
}
.proof-label {
  margin: 0.5rem 0 0;
  max-width: 18ch;
  font-size: 0.875rem;
  color: var(--muted);
}
@media (min-width: 640px) {
  .proof-grid { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1024px) {
  .proof-grid { grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
}

/* Sections */
.section {
  padding-block: 5rem;
}
.section-head {
  display: grid;
  gap: 2rem;
}
@media (min-width: 1024px) {
  .section-head {
    grid-template-columns: 1.1fr 1fr;
    align-items: end;
  }
}
.section h2.display,
.page-hero h1 {
  margin: 1rem 0 0;
  font-size: clamp(2.2rem, 4vw, 3.4rem);
}
.muted { color: var(--muted); }
.cards-3 {
  display: grid;
  gap: 1rem;
  margin-top: 3rem;
}
@media (min-width: 768px) {
  .cards-3 { grid-template-columns: repeat(3, 1fr); }
}
.card {
  display: flex;
  flex-direction: column;
  border-radius: 14px;
  padding: 1.5rem;
}
.card h3 {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 500;
}
.card p {
  margin: 0.75rem 0 0;
  flex: 1;
  font-size: 0.875rem;
  line-height: 1.65;
  color: var(--muted);
}
.card-link {
  margin-top: 1.5rem;
  font-size: 0.875rem;
  text-decoration: none;
}
.card-link:hover { text-decoration: underline; }

.band {
  background: var(--canvas-2);
}
.split {
  display: grid;
  gap: 3rem;
  align-items: center;
}
@media (min-width: 1024px) {
  .split { grid-template-columns: 1fr 1fr; }
}
.split img {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 14px;
}
.impact-list {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
}
.impact-list li {
  border-left: 2px solid var(--accent);
  padding: 0.35rem 0 0.35rem 1rem;
  margin-bottom: 0.75rem;
  font-size: 0.875rem;
}

.row-between {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
@media (min-width: 640px) {
  .row-between {
    flex-direction: row;
    align-items: end;
    justify-content: space-between;
  }
}

.timeline {
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
  border-block: 1px solid var(--line);
}
.timeline li {
  display: grid;
  gap: 0.5rem;
  padding-block: 1.5rem;
  border-bottom: 1px solid var(--line);
}
.timeline li:last-child { border-bottom: 0; }
.timeline .when {
  margin: 0;
  font-size: 0.875rem;
  color: var(--subtle);
}
.timeline h3,
.timeline .role {
  margin: 0;
  font-weight: 500;
}
.timeline p {
  margin: 0.5rem 0 0;
  max-width: 48rem;
  font-size: 0.875rem;
  color: var(--muted);
}
@media (min-width: 640px) {
  .timeline li {
    grid-template-columns: 11rem 1fr;
    gap: 2rem;
  }
}
@media (min-width: 768px) {
  .timeline.full li { grid-template-columns: 13rem 1fr; gap: 2.5rem; padding-block: 2rem; }
}

.cite-list {
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
}
.cite-list li {
  margin: 0 0 1.25rem;
  max-width: 56rem;
  font-size: 0.975rem;
  line-height: 1.65;
}
.cite-list a { text-decoration: none; }
.cite-list a:hover { text-decoration: underline; }

.cta-box {
  border-radius: 14px;
  padding: 3rem 1.5rem;
}
@media (min-width: 640px) {
  .cta-box { padding: 3rem; }
}
.cta-box h2 {
  margin: 1rem 0 0;
  max-width: 40rem;
  font-size: clamp(2rem, 4vw, 3rem);
}
.cta-box p { margin: 1rem 0 0; max-width: 36rem; }
.cta-box .hero-actions { margin-top: 2rem; }

/* Inner pages */
.page-hero {
  padding-top: 4rem;
  padding-bottom: 0;
}
.page-hero h1 {
  max-width: 48rem;
  font-size: clamp(2.4rem, 5vw, 3.75rem);
}
.page-hero .lede {
  margin: 1.5rem 0 0;
  max-width: 40rem;
  font-size: 1.125rem;
  color: var(--muted);
}

.service-grid {
  display: grid;
  gap: 1rem;
  margin-top: 4rem;
}
@media (min-width: 768px) {
  .service-grid { grid-template-columns: 1fr 1fr; }
}
.service-card {
  border-radius: 14px;
  padding: 1.75rem;
}
.service-card h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 500;
}
.service-card > p {
  margin: 0.75rem 0 0;
  font-size: 0.875rem;
  line-height: 1.65;
  color: var(--muted);
}
.service-card ul {
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 0;
}
.service-card li {
  border-left: 1px solid var(--accent);
  padding-left: 0.75rem;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1.25rem 0 0;
  padding: 0;
  list-style: none;
}
.chip-row li {
  border-radius: 8px;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  box-shadow: 0 0 0 1px var(--line);
}

.impact-grid {
  display: grid;
  gap: 0.75rem;
  margin-top: 3rem;
  padding: 0;
  list-style: none;
}
@media (min-width: 640px) {
  .impact-grid { grid-template-columns: 1fr 1fr; }
}
.impact-grid li {
  border-radius: 8px;
  padding: 1rem 1.25rem;
  font-size: 0.875rem;
  line-height: 1.6;
}

.edu-grid {
  display: grid;
  gap: 3rem;
  margin-top: 4rem;
}
@media (min-width: 768px) {
  .edu-grid { grid-template-columns: 1fr 1fr; }
}
.edu-grid ul {
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 0;
}
.edu-grid li { margin-bottom: 1rem; }
.edu-grid p { margin: 0; }

.narrow { max-width: 56rem; margin-inline: auto; }
.section-label {
  margin: 0;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--subtle);
}

/* Contact */
.contact-grid {
  display: grid;
  gap: 3.5rem;
  padding-block: 4rem;
}
@media (min-width: 1024px) {
  .contact-grid { grid-template-columns: 0.9fr 1.1fr; }
}
.contact-grid h1 {
  margin: 1rem 0 0;
  font-size: clamp(2.4rem, 4vw, 3rem);
}
.contact-dl {
  margin: 2.5rem 0 0;
}
.contact-dl div { margin-bottom: 1.25rem; }
.contact-dl dt {
  font-size: 0.875rem;
  color: var(--subtle);
}
.contact-dl dd { margin: 0.15rem 0 0; }
.contact-dl a { text-decoration: none; }
.contact-dl a:hover { text-decoration: underline; }

.form-card {
  border-radius: 14px;
  padding: 1.5rem;
}
@media (min-width: 640px) {
  .form-card { padding: 2rem; }
}
.form-field {
  display: grid;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}
.form-field label {
  font-size: 0.875rem;
  font-weight: 500;
}
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.65rem 0.85rem;
  border: 0;
  border-radius: 8px;
  background: var(--elevated);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1rem;
  box-shadow: 0 0 0 1px var(--line);
}
.form-field textarea {
  min-height: 9rem;
  resize: vertical;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: 2px solid var(--ring);
  outline-offset: 1px;
}
.honeypot {
  position: absolute;
  left: -9999px;
  height: 0;
  overflow: hidden;
}
.form-note {
  margin: 0.75rem 0 0;
  font-size: 0.75rem;
  color: var(--subtle);
}
.notice {
  margin: 0 0 1rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-size: 0.875rem;
}
.notice-ok { background: var(--canvas-2); }
.notice-err { background: #f3e4e1; }

/* Footer */
.site-footer {
  margin-top: 2rem;
  border-top: 1px solid var(--line);
}
.footer-grid {
  display: grid;
  gap: 2.5rem;
  padding-block: 3.5rem;
}
@media (min-width: 640px) {
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
}
.footer-name {
  margin: 0;
  font-family: var(--display);
  font-size: 1.5rem;
}
.footer-grid a {
  display: block;
  margin-top: 0.35rem;
  text-decoration: none;
  font-size: 0.875rem;
}
.footer-grid a:hover { text-decoration: underline; }
.footer-meta {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding-block: 1.5rem;
  font-size: 0.75rem;
  color: var(--subtle);
}
@media (min-width: 640px) {
  .footer-meta {
    flex-direction: row;
    justify-content: space-between;
  }
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Elementor */
body.elementor-page main#content,
body.medsyn-elementor main#content,
.page-template-template-elementor-fullwidth main#content,
.page-template-template-elementor-canvas main#content {
  padding: 0;
  max-width: none;
}
body.elementor-page .elementor,
body.medsyn-elementor .elementor {
  width: 100%;
}
.elementor-section.elementor-section-boxed > .elementor-container {
  max-width: 72rem;
}
.elementor-widget-text-editor,
.elementor-widget-heading .elementor-heading-title {
  color: inherit;
}
body.elementor-editor-active .practice-bar {
  pointer-events: auto;
}

