/*
Theme Name:   Blankets Consulting Group
Theme URI:    https://blanketsconsulting.com/
Author:       Blankets Consulting Group
Author URI:   https://blanketsconsulting.com/
Description:  Classic WordPress theme for Blankets Consulting Group — enterprise-grade fractional executive leadership firm in Rochester, MN. Ports the v3 static site design system (DM Serif Display + Plus Jakarta Sans, navy/blue/teal palette) into a maintainable theme with block patterns for every marketing section.
Version:      1.0.0
Requires at least: 6.2
Tested up to: 6.7
Requires PHP: 7.4
License:      GPL-2.0-or-later
License URI:  https://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  blankets
Tags:         business, consulting, professional, block-patterns, custom-menu, custom-logo, translation-ready
*/

/*
 * NOTE: The full design system lives in assets/css/main.css (enqueued by inc/enqueue.php).
 * This file exists for the WordPress theme header and for small overrides only.
 */

/* =============================================================
   WORDPRESS INTEGRATION LAYER
   Maps core block output onto the Blankets design system.
   The design system itself lives in assets/css/main.css.
============================================================= */

/* --- Block wrappers must not fight the section rhythm ------- */
.entry-content > .wp-block-group,
.entry-content > section { margin-top: 0; margin-bottom: 0; }

.bcg-page-content > .wp-block-group.container,
.bcg-page-content > .wp-block-group.alignfull { max-width: none; }

.wp-block-group.container { max-width: var(--max-w); margin-left: auto; margin-right: auto; padding-left: 24px; padding-right: 24px; }

/* Sections built from core/group -------------------------------- */
.bcg-section        { padding: 100px 0; background: #fff; }
.bcg-section-light  { padding: 100px 0; background: var(--light-bg); }
.bcg-section-navy   { padding: 100px 0; background: var(--navy); color: rgba(255,255,255,0.9); }
.bcg-section-navy h2,
.bcg-section-navy h3 { color: #fff; }
.bcg-section-tight  { padding: 64px 0; background: #fff; }
@media (max-width: 768px) {
  .bcg-section, .bcg-section-light, .bcg-section-navy { padding: 64px 0; }
}

/* Core buttons wearing the design-system button styles ---------- */
.wp-block-button.is-style-bcg-primary   > .wp-block-button__link,
.wp-block-button.is-style-bcg-outline   > .wp-block-button__link,
.wp-block-button.is-style-bcg-white     > .wp-block-button__link,
.wp-block-button.is-style-bcg-secondary > .wp-block-button__link {
  display: inline-block;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  padding: 15px 30px;
  border-radius: var(--radius-btn);
  line-height: 1.2;
  text-decoration: none;
  transition: background 0.2s, color 0.2s, transform 0.15s, border-color 0.2s;
}
.wp-block-button.is-style-bcg-primary > .wp-block-button__link { background: var(--teal); color: #fff; border: none; }
.wp-block-button.is-style-bcg-primary > .wp-block-button__link:hover { background: var(--teal-hover); transform: translateY(-1px); }

.wp-block-button.is-style-bcg-outline > .wp-block-button__link { background: transparent; color: #fff; border: 2px solid #fff; }
.wp-block-button.is-style-bcg-outline > .wp-block-button__link:hover { background: #fff; color: var(--navy); transform: translateY(-1px); }

.wp-block-button.is-style-bcg-white > .wp-block-button__link { background: #fff; color: var(--navy); border: none; font-weight: 700; }
.wp-block-button.is-style-bcg-white > .wp-block-button__link:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(0,0,0,0.18); }

.wp-block-button.is-style-bcg-secondary > .wp-block-button__link { background: transparent; color: var(--navy); border: 2px solid var(--navy); }
.wp-block-button.is-style-bcg-secondary > .wp-block-button__link:hover { background: var(--navy); color: #fff; }

.wp-block-buttons { display: flex; flex-wrap: wrap; gap: 16px; }
.wp-block-button { display: block; }

@media (max-width: 560px) {
  .hero-buttons.wp-block-buttons { flex-direction: column; align-items: stretch; }
  .hero-buttons .wp-block-button__link { display: block; text-align: center; }
}

/* Card / grid helpers when authored as core groups --------------- */
.wp-block-group.service-card,
.wp-block-group.method-step,
.wp-block-group.outcome-card,
.wp-block-group.principle,
.wp-block-group.path-step { height: 100%; }

.wp-block-columns.cards-grid { gap: 24px; }

/* Media inside heroes ------------------------------------------- */
.hero-media .wp-block-image { margin: 0; }
.hero-media .wp-block-image img { border-radius: 12px; }

/* --- Forms ------------------------------------------------------ */
.bcg-form-slot { max-width: 640px; margin: 0 auto; }
.bcg-form-title { font-family: 'DM Serif Display', serif; font-size: 26px; color: var(--navy); margin-bottom: 20px; text-align: center; }
.bcg-form-note { margin-top: 20px; font-size: 14px; color: var(--muted); text-align: center; }
.bcg-form-fallback { text-align: center; margin-top: 24px; font-size: 15px; color: var(--muted); }
.bcg-form-fallback a { color: var(--blue); font-weight: 600; }

.bcg-form-placeholder {
  border: 2px dashed rgba(46,117,182,0.5);
  border-radius: var(--radius-card);
  background: var(--light-bg);
  padding: 28px;
  text-align: left;
}
.bcg-form-placeholder-label {
  font-size: 11px; font-weight: 700; letter-spacing: 1.8px; text-transform: uppercase;
  color: #fff; background: var(--navy); display: inline-block; padding: 6px 12px;
  border-radius: 4px; margin-bottom: 12px;
}
.bcg-form-placeholder p { font-size: 15px; color: var(--body); margin-bottom: 10px; }
.bcg-form-placeholder code { display: block; font-size: 13px; background: #fff; border: 1px solid rgba(0,0,0,0.1); border-radius: 6px; padding: 10px 12px; color: var(--navy); }

/* Baseline field styling so plugin-rendered forms inherit the brand */
.bcg-form-slot input[type="text"],
.bcg-form-slot input[type="email"],
.bcg-form-slot input[type="tel"],
.bcg-form-slot input[type="url"],
.bcg-form-slot input[type="number"],
.bcg-form-slot input[type="search"],
.bcg-form-slot select,
.bcg-form-slot textarea,
.bcg-form input[type="search"] {
  width: 100%;
  margin-top: 6px;
  padding: 13px 14px;
  border: 1px solid rgba(0,0,0,0.18);
  border-radius: var(--radius-btn);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 15px;
  color: var(--body);
  background: #fff;
}
.bcg-form-slot textarea { resize: vertical; min-height: 140px; }
.bcg-form-slot label { display: block; font-size: 14px; font-weight: 600; color: var(--navy); margin-bottom: 16px; }
.bcg-form-slot button[type="submit"],
.bcg-form-slot input[type="submit"] {
  display: inline-block; background: var(--teal); color: #fff; padding: 15px 30px;
  border: none; border-radius: var(--radius-btn); font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 15px; font-weight: 600; cursor: pointer; transition: background 0.2s, transform 0.15s;
}
.bcg-form-slot button[type="submit"]:hover,
.bcg-form-slot input[type="submit"]:hover { background: var(--teal-hover); transform: translateY(-1px); }

.bcg-form.search-form { display: flex; gap: 12px; max-width: 520px; margin: 0 auto; align-items: stretch; }
.bcg-form.search-form .bcg-field { flex: 1; }
.bcg-search-form { margin: 32px 0; }

/* --- Blog / Insights -------------------------------------------- */
.bcg-archive { padding: 80px 0 100px; background: var(--light-bg); }
.bcg-post-grid { align-items: stretch; }
.bcg-post-card .card-title { font-size: 20px; line-height: 1.35; margin-bottom: 10px; }
.bcg-post-card .card-title a { color: var(--navy); }
.bcg-post-card .card-title a:hover { color: var(--blue); }
.bcg-post-card-image { display: block; margin: -36px -36px 24px; border-radius: var(--radius-card) var(--radius-card) 0 0; overflow: hidden; }
.bcg-post-card-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bcg-empty { text-align: center; font-size: 17px; color: var(--muted); padding: 48px 0; }

.bcg-single { padding: 72px 0 96px; background: #fff; }
.bcg-article-body { max-width: 760px; margin: 0 auto; }
.bcg-article-image { margin: 0 0 32px; }
.bcg-article-image img { width: 100%; border-radius: 12px; }
.entry-meta { font-size: 14px; color: var(--muted); margin-bottom: 24px; }
.entry-meta a { color: var(--blue); font-weight: 600; }

.bcg-article-body .entry-content h2 { font-size: 30px; margin: 40px 0 16px; }
.bcg-article-body .entry-content h3 { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 21px; font-weight: 700; color: var(--navy); margin: 32px 0 12px; }
.bcg-article-body .entry-content p { font-size: 17px; line-height: 1.8; color: #444; margin-bottom: 20px; }
.bcg-article-body .entry-content ul,
.bcg-article-body .entry-content ol { margin: 0 0 20px 22px; font-size: 17px; line-height: 1.8; color: #444; }
.bcg-article-body .entry-content li { margin-bottom: 8px; }
.bcg-article-body .entry-content a { color: var(--blue); font-weight: 600; text-decoration: underline; }
.bcg-article-body .entry-content blockquote {
  border-left: 4px solid var(--teal); padding: 8px 0 8px 24px; margin: 32px 0;
  font-size: 19px; line-height: 1.7; color: var(--navy);
}
.bcg-article-body .entry-content img { border-radius: 8px; }

.bcg-post-nav { display: flex; justify-content: space-between; gap: 24px; margin-top: 56px; padding-top: 32px; border-top: 1px solid rgba(0,0,0,0.08); font-size: 15px; font-weight: 600; }
.bcg-post-nav a { color: var(--blue); }
.bcg-post-nav .nav-label { display: block; font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); font-weight: 700; margin-bottom: 4px; }

.wp-block-post-comments-form, .bcg-comments { max-width: 760px; margin: 56px auto 0; }
.bcg-comments-title { font-family: 'DM Serif Display', serif; font-size: 26px; color: var(--navy); margin-bottom: 20px; }
.comment-list { list-style: none; margin: 0 0 40px; padding: 0; }
.comment-list li { padding: 20px 0; border-bottom: 1px solid rgba(0,0,0,0.06); }

.pagination, .navigation.pagination { margin-top: 56px; text-align: center; }
.pagination .page-numbers {
  display: inline-block; min-width: 40px; padding: 9px 12px; margin: 0 4px;
  border-radius: var(--radius-btn); background: #fff; color: var(--navy);
  font-size: 14px; font-weight: 600; box-shadow: var(--shadow);
}
.pagination .page-numbers.current { background: var(--navy); color: #fff; }
.pagination .page-numbers:hover { background: var(--teal); color: #fff; }

/* --- Narrow document template ----------------------------------- */
.bcg-doc { padding: 72px 0 96px; background: #fff; }
.prose-doc { max-width: 760px; margin: 0 auto; }
.prose-doc h2 { font-size: 28px; margin: 36px 0 14px; }
.prose-doc h3 { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 19px; font-weight: 700; color: var(--navy); margin: 28px 0 10px; }
.prose-doc p, .prose-doc li { font-size: 16px; line-height: 1.8; color: #444; margin-bottom: 16px; }
.prose-doc ul, .prose-doc ol { margin-left: 22px; }
.prose-doc a { color: var(--blue); font-weight: 600; text-decoration: underline; }

/* --- Accessibility ---------------------------------------------- */
.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;
  width: 1px; word-wrap: normal !important;
}
.screen-reader-text:focus {
  background-color: #fff; clip: auto !important; clip-path: none;
  color: var(--navy); display: block; font-size: 15px; height: auto;
  left: 5px; line-height: normal; padding: 15px 23px 14px; text-decoration: none;
  top: 5px; width: auto; z-index: 100000;
}

/* --- Admin bar / editor niceties -------------------------------- */
.footer-widgets { margin-bottom: 20px; }
.footer-widgets .footer-col-title { margin-top: 0; }

/* --- Pattern helper utilities ----------------------------------- */
/* Home hero, addressable by class as well as #hero (safe when a page
   ever carries more than one hero). */
.bcg-hero-home { background: var(--navy); padding: 56px 0 60px; position: relative; overflow: hidden; }
.bcg-hero-home::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at 70% 50%, rgba(46,117,182,0.15) 0%, transparent 60%),
              radial-gradient(ellipse at 10% 80%, rgba(77,175,168,0.08) 0%, transparent 50%);
}
@media (max-width: 768px) { .bcg-hero-home { padding: 64px 0 56px; } }

.hero-inner.is-single { grid-template-columns: 1fr; }
.hero-content.is-wide { max-width: 760px; }
.hero-sub.is-wide { max-width: 640px; }

/* Card links wrapped in a paragraph by the block editor. */
.card-link-wrap { margin-top: auto; margin-bottom: 0; }
.card-link-wrap .card-link { margin-top: 0; }

/* Heading-tag versions of what were <div>s in the static build. */
h3.card-title, h3.method-name, h3.path-step-title, h3.outcome-title { font-family: 'Plus Jakarta Sans', sans-serif; }
p.tier-label, p.method-num, p.stat-number, p.path-step-num, p.outcome-client,
p.testimonial-author, p.testimonial-role, p.fm-partner, p.tl-label,
p.card-eyebrow, p.svc-detail-eyebrow, p.page-hero-eyebrow, p.hero-eyebrow { margin-bottom: 0; }
p.tier-label { margin-bottom: 24px; }
p.method-num, p.path-step-num, p.stat-number { margin-bottom: 8px; }
