/*
Theme Name: P&G Construction
Theme URI: https://www.pgconstructioninc.com
Author: P&G Construction, Inc.
Description: Custom block theme for P&G Construction, built from the P&G brand guide.
Version: 1.5.4
Requires at least: 6.5
Requires PHP: 8.0
Text Domain: pgc-construction
*/

/* ---------- Base ---------- */
body { -webkit-font-smoothing: antialiased; }
a { text-decoration-thickness: 1px; text-underline-offset: 3px; }
:where(a, button, input, select, textarea):focus-visible { outline: 2px solid #58b7b3; outline-offset: 2px; }

.pgc-eyebrow { font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase; color: #54575a; margin: 0; }
.pgc-tagline { font-family: "Learning Curve", "Segoe Script", cursive; font-size: 44px; line-height: 1.1; color: #58b7b3; text-transform: lowercase; margin: 0; }
.pgc-lead { font-size: 18px; color: #54575a; }

/* Buttons: uppercase tracked labels */
.wp-element-button, .wp-block-button__link { font-size: 14px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; border-radius: 4px; padding: 16px 30px; }
.wp-block-button.is-style-outline .wp-block-button__link { border: 1px solid currentColor; background: transparent; }

/* ---------- Utility bar + header ---------- */
.pgc-utility { background: #15285a; color: rgba(255,255,255,.85); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; }
.pgc-utility p { margin: 0; }
.pgc-utility a { color: #fff; text-decoration: none; }
.pgc-utility a:hover { color: #58b7b3; }
.pgc-utility .pgc-login a { color: #58b7b3; }
.pgc-header { border-bottom: 1px solid #dbd9d6; background: #fff; }
.pgc-header .wp-block-image { margin: 0; }
.pgc-header .wp-block-image img { height: 52px; width: auto; }
.pgc-header .wp-block-navigation { font-size: 12px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; }
.pgc-header .wp-block-navigation a { text-decoration: none; }
.pgc-header .wp-block-navigation a:hover { color: #58b7b3; }
.pgc-header .wp-block-button__link { font-size: 12px; padding: 13px 22px; }

/* ---------- Full-width sections: side padding ---------- */
.pgc-utility, .pgc-header, .pgc-section, .pgc-proof, .pgc-quote, .pgc-footer, .wp-block-cover.pgc-hero, main.wp-block-group:not(.pgc-home) { padding-left: 40px !important; padding-right: 40px !important; box-sizing: border-box; }
@media (max-width: 600px) { .pgc-utility, .pgc-header, .pgc-section, .pgc-proof, .pgc-quote, .pgc-footer, .wp-block-cover.pgc-hero, main.wp-block-group:not(.pgc-home) { padding-left: 20px !important; padding-right: 20px !important; } }

/* ---------- Hero ---------- */
.wp-block-cover.pgc-hero { background-color: #15285a; color: #fff; }
.wp-block-cover.pgc-hero .wp-block-cover__inner-container { max-width: 1200px; width: 100%; margin-left: auto; margin-right: auto; color: #fff !important; }
.wp-block-cover.pgc-hero .wp-block-cover__inner-container > * { margin-left: 0 !important; margin-right: 0 !important; }
.wp-block-cover.pgc-hero p:not(.pgc-tagline), .wp-block-cover.pgc-hero h1 { color: #fff !important; }
.wp-block-cover.pgc-hero .pgc-tagline { color: #58b7b3 !important; }
.wp-block-cover.pgc-hero .wp-block-button:not(.is-style-outline) .wp-block-button__link { color: #15285a !important; }
.pgc-hero h1 { color: #fff; font-size: clamp(40px, 6vw, 64px); line-height: 1.05; max-width: 820px; margin: 0; }
.pgc-hero .pgc-eyebrow { color: rgba(255,255,255,.85); }
.pgc-hero .pgc-hero-text { font-size: 18px; color: rgba(255,255,255,.9); max-width: 600px; }
.pgc-hero .wp-block-button:not(.is-style-outline) .wp-block-button__link { background: #fff; color: #15285a; }
.pgc-hero .wp-block-button.is-style-outline .wp-block-button__link { color: #fff; border-color: rgba(255,255,255,.6); }

/* ---------- Sections ---------- */
.pgc-section { padding-top: 96px; padding-bottom: 96px; }
.pgc-alt { background: #dbd9d6; }
.pgc-center { text-align: center; }
.pgc-center .pgc-lead { max-width: 620px; margin-left: auto; margin-right: auto; }

/* Service cards */
.pgc-cards { gap: 24px; margin-top: 48px; }
.pgc-card { background: #fff; border: 1px solid #dbd9d6; border-radius: 8px; box-shadow: 0 2px 6px rgba(21,40,90,.08); overflow: hidden; transition: box-shadow .2s, transform .2s; }
.pgc-card:hover { box-shadow: 0 6px 18px rgba(21,40,90,.10); transform: translateY(-2px); }
.pgc-card .pgc-card-body { padding: 28px; }
.pgc-card h3 { margin: 8px 0 12px; }
.pgc-card .pgc-card-link a { font-size: 12px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none; }
.pgc-photo { min-height: 220px; display: flex; align-items: flex-end; padding: 14px 18px; box-sizing: border-box; }
.pgc-photo p { margin: 0; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: #54575a; }
.pgc-photo.is-navy { background: #dbd9d6; }
.pgc-photo.is-teal { background: #dbd9d6; }
.pgc-photo.is-sky { background: #dbd9d6; }
.pgc-photo.is-tall { min-height: 240px; border-radius: 8px; }

/* Proof band */
.pgc-proof { background: #15285a; color: #fff; padding-top: 80px; padding-bottom: 80px; }
.pgc-proof .wp-block-column { border-top: 1px solid rgba(255,255,255,.28); padding-top: 20px; }
.pgc-stat { font-family: "TypoSlab Serif", "Bitter", Georgia, serif; font-weight: 300; font-size: 48px; line-height: 1; letter-spacing: 0.06em; margin: 0; }
.pgc-stat-label { margin: 12px 0 0; font-size: 11px; font-weight: 500; letter-spacing: 0.22em; text-transform: uppercase; color: rgba(255,255,255,.85); }

/* Process */
.pgc-steps { gap: 16px; }
.pgc-step { background: #fff; border: 1px solid #dbd9d6; border-radius: 8px; padding: 24px; }
.pgc-step-num { margin: 0; font-size: 12px; font-weight: 600; letter-spacing: 0.1em; color: #15285a; }
.pgc-step h3 { margin: 10px 0 6px; }
.pgc-step p:last-child { margin: 0; font-size: 14px; color: #54575a; }

/* Work gallery */
.pgc-work figure, .pgc-work .wp-block-group { margin: 0; }
.pgc-work-title { font-family: "TypoSlab Serif", "Bitter", Georgia, serif; font-weight: 300; font-size: 20px; letter-spacing: 0.06em; color: #15285a; margin: 12px 0 0; }
.pgc-work-meta { font-size: 14px; color: #54575a; margin: 0; }

/* Quote */
.pgc-quote { background: #58b7b3; padding-top: 72px; padding-bottom: 72px; text-align: center; }
.pgc-quote .pgc-quote-text { font-family: "TypoSlab Serif", "Bitter", Georgia, serif; font-weight: 300; font-size: 30px; line-height: 1.4; letter-spacing: 0.06em; color: #15285a; max-width: 900px; margin: 0 auto; }
.pgc-quote .pgc-quote-by { margin-top: 20px; font-size: 12px; font-weight: 500; letter-spacing: 0.22em; text-transform: uppercase; color: #15285a; }

/* Contact */
.pgc-contact-lines p { margin: 0 0 8px; }
.pgc-contact-lines a { text-decoration: none; }

/* Form plugin styling (WPForms / Contact Form 7) */
.pgc-form label, .wpforms-field-label { font-size: 12px !important; font-weight: 500 !important; letter-spacing: 0.1em; text-transform: uppercase; color: #15285a !important; }
.pgc-form input[type=text], .pgc-form input[type=email], .pgc-form input[type=tel], .pgc-form select, .pgc-form textarea { border: 1px solid #dbd9d6 !important; border-radius: 4px !important; font: inherit; font-size: 16px; }
.pgc-form button[type=submit], .pgc-form input[type=submit] { background: #15285a !important; color: #fff !important; border: 0 !important; border-radius: 4px !important; font-size: 14px !important; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; padding: 16px 32px !important; height: auto !important; }

/* ---------- Footer ---------- */
.pgc-footer { background: #15285a; color: rgba(255,255,255,.85); padding-top: 64px; padding-bottom: 40px; }
.pgc-footer a { color: #fff; text-decoration: none; }
.pgc-footer a:hover { color: #58b7b3; }
.pgc-footer .pgc-footer-name { font-family: "TypoSlab Serif", "Bitter", Georgia, serif; font-weight: 300; font-size: 22px; letter-spacing: 0.06em; color: #fff; margin: 0; }
.pgc-footer .pgc-tagline { font-size: 30px; }
.pgc-footer .pgc-mono { width: 64px; height: 64px; border-radius: 50%; background: #15285a; display: flex; align-items: center; justify-content: center; margin: 0; flex: none; }
.pgc-footer .pgc-mono img { height: 40px !important; width: auto !important; max-width: none; }
.pgc-footer-links { font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; }
.pgc-footer-links p { margin: 0 0 10px; }
.pgc-footer-links .pgc-login a { color: #58b7b3; }
.pgc-footer-legal { margin-top: 48px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.28); font-size: 13px; }
.pgc-footer-legal p { margin: 0; }

/* Interior pages */
.pgc-page-title { padding-top: 72px; padding-bottom: 24px; }

@media (max-width: 781px) {
  .pgc-section { padding-top: 64px; padding-bottom: 64px; }
  .pgc-tagline { font-size: 34px; }
}

/* ---------- 1.0.2 fixes ---------- */
.wp-site-blocks > * + * { margin-block-start: 0 !important; }
.wp-block-cover.pgc-hero.has-custom-content-position .wp-block-cover__inner-container { max-width: 1200px !important; width: 100% !important; margin-left: auto !important; margin-right: auto !important; }
.pgc-card { display: flex; flex-direction: column; }
.pgc-card .pgc-card-body { flex: 1; display: flex; flex-direction: column; }
.pgc-card .pgc-card-link { margin-top: auto !important; padding-top: 12px; }
.pgc-proof .wp-block-columns { margin-bottom: 0; }
.pgc-proof .pgc-stat { font-size: 44px; }

/* Brand-only palette: on Simplicity backgrounds keep text readable */
.pgc-alt .pgc-eyebrow, .pgc-alt .pgc-lead, .pgc-alt p { color: #15285a; }
.pgc-alt .pgc-step p:last-child { color: #54575a; }
.pgc-photo p { color: #15285a; }

/* 1.1.0: inside pages + footer mark */
.pgc-photo { background: #dbd9d6; }
.wp-block-post-content .pgc-photo.is-tall { min-height: 360px; margin: 32px 0; }
.wp-block-post-content .pgc-work .pgc-photo.is-tall, .wp-block-post-content .wp-block-column .pgc-photo.is-tall { min-height: 240px; margin: 0; }
.wp-block-post-content h2 { margin-top: 48px; font-size: 30px; }
.wp-block-post-content ul { padding-left: 1.2em; }
.wp-block-post-content li { margin-bottom: 6px; }
.wp-block-post-content li::marker { color: #d65f00; }
.pgc-footer .pgc-mono { background: #58b7b3; }

.wp-block-post-content h3 + .pgc-eyebrow { margin-top: 4px; }

/* 1.2.0: estimate form */
.pgc-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 20px; }
.pgc-form-grid p { margin: 0 0 12px; display: flex; flex-direction: column; gap: 8px; }
.pgc-form-grid .is-wide { grid-column: 1 / -1; }
.pgc-form-grid label { font-size: 12px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: #15285a; }
.pgc-form-grid input, .pgc-form-grid select, .pgc-form-grid textarea { font: inherit; font-size: 16px; color: #54575a; background: #fff; border: 1px solid #dbd9d6; border-radius: 4px; padding: 0 12px; min-height: 44px; box-sizing: border-box; width: 100%; }
.pgc-form-grid textarea { padding: 12px; resize: vertical; }
.pgc-form-grid input:focus, .pgc-form-grid select:focus, .pgc-form-grid textarea:focus { outline: none; border-color: #58b7b3; box-shadow: 0 0 0 3px rgba(88,183,179,.45); }
.pgc-form-grid button { justify-self: start; align-self: flex-start; background: #15285a; color: #fff; border: 0; border-radius: 4px; font: inherit; font-size: 14px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; padding: 17px 32px; cursor: pointer; }
.pgc-form-grid button:hover { background: #6886b8; }
.pgc-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.pgc-form-msg { padding: 20px 24px; border-radius: 8px; margin-bottom: 20px; line-height: 1.55; }
.pgc-form-msg.is-ok { background: #58b7b3; color: #15285a; }
.pgc-form-msg.is-error { background: #fff; border: 2px solid #d65f00; color: #15285a; }
@media (max-width: 600px) { .pgc-form-grid { grid-template-columns: 1fr; } }

/* 1.3.0: photos */
.pgc-card-img { margin: 0 !important; }
.pgc-card-img img { display: block; width: 100%; height: 240px; object-fit: cover; }
.pgc-work-img { margin: 0 !important; }
.pgc-work-img img { display: block; width: 100%; height: 260px; object-fit: cover; border-radius: 8px; }
.pgc-page-img { margin: 32px 0 !important; }
.pgc-page-img img { display: block; width: 100%; max-height: 520px; object-fit: cover; border-radius: 8px; }
.pgc-page-img.is-portrait img { max-height: 560px; object-position: center 40%; }
.wp-block-post-content .pgc-work { margin-top: 24px; }

/* 1.4.0: moving water in the hero */
.wp-block-cover.pgc-hero { padding-bottom: 120px !important; }
.wp-block-cover.pgc-hero .wp-block-cover__inner-container { position: static !important; }
.wp-block-cover.pgc-hero .wp-block-cover__inner-container > *:not(.pgc-water) { position: relative; z-index: 3; }
.pgc-water { position: absolute; left: 0; right: 0; bottom: 0; height: 110px; overflow: hidden; pointer-events: none; z-index: 2; margin: 0 !important; }
.pgc-wave { position: absolute; left: 0; bottom: 0; width: 200%; height: 90px; display: block; }
.pgc-w1 { opacity: .35; animation: pgc-drift 26s linear infinite; }
.pgc-w2 { opacity: .5; bottom: -8px; animation: pgc-drift 18s linear infinite reverse; }
.pgc-w3 { bottom: -18px; animation: pgc-drift 12s linear infinite; }
@keyframes pgc-drift { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.pgc-water { height: 230px; }
.pgc-boat { position: absolute; bottom: 50px; left: -90px; z-index: 3; animation: pgc-trip 36s ease-in-out infinite; }
.pgc-boat svg { display: block; animation: pgc-bob 4s ease-in-out infinite; }
.pgc-house { position: absolute; bottom: 0; left: calc(76% - 75px); display: block; }
.pgc-house-back { z-index: 1; }
.pgc-house-front { z-index: 4; }
.pgc-cradle { position: absolute; z-index: 2; left: calc(76% - 46px); width: 92px; top: 73px; bottom: 52px; border-left: 1px solid rgba(255,255,255,.7); border-right: 1px solid rgba(255,255,255,.7); border-bottom: 3px solid #dbd9d6; box-sizing: border-box; animation: pgc-lift 36s ease-in-out infinite; }
.pgc-w3 { z-index: 5; }
@keyframes pgc-trip {
  0% { left: -90px; bottom: 50px; }
  38% { left: calc(76% - 39px); bottom: 50px; }
  46% { left: calc(76% - 39px); bottom: 74px; }
  72% { left: calc(76% - 39px); bottom: 74px; }
  80% { left: calc(76% - 39px); bottom: 50px; }
  100% { left: 105%; bottom: 50px; }
}
@keyframes pgc-lift { 0%, 38% { bottom: 52px; } 46%, 72% { bottom: 76px; } 80%, 100% { bottom: 52px; } }
@keyframes pgc-bob { 0%, 100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(4px) rotate(1.5deg); } }
@keyframes pgc-cruise { from { left: -90px; } to { left: 105%; } }
@media (max-width: 900px) { .pgc-house, .pgc-cradle { display: none; } .pgc-boat { animation: pgc-cruise 30s linear infinite; } }
.pgc-glint { position: absolute; width: 14px; height: 2px; border-radius: 2px; background: #ffffff; opacity: 0; animation: pgc-glint 3.6s ease-in-out infinite; }
@keyframes pgc-glint { 0%, 100% { opacity: 0; } 50% { opacity: .8; } }
@media (prefers-reduced-motion: reduce) { .pgc-water * { animation: none !important; } .pgc-boat { left: calc(76% - 39px); bottom: 74px; } .pgc-cradle { bottom: 76px; } }

/* 1.5.0: gallery */
.pgc-gal-filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 28px; }
.pgc-gal-filters button { font: inherit; font-size: 12px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: #15285a; background: #fff; border: 1px solid #dbd9d6; border-radius: 999px; padding: 10px 18px; min-height: 44px; cursor: pointer; }
.pgc-gal-filters button:hover { border-color: #15285a; }
.pgc-gal-filters button[aria-pressed="true"] { background: #15285a; border-color: #15285a; color: #fff; }
.pgc-gal-grid { list-style: none; margin: 0; padding: 0 !important; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.pgc-gal-grid li { margin: 0 !important; }
.pgc-gal-grid li[hidden] { display: none; }
.pgc-gal-grid a { display: block; border-radius: 8px; overflow: hidden; }
.pgc-gal-grid img { display: block; width: 100%; height: 240px; object-fit: cover; transition: transform .2s; }
.pgc-gal-grid a:hover img { transform: scale(1.03); }
.pgc-lightbox { position: fixed; inset: 0; z-index: 100000; background: rgba(21,40,90,.95); display: flex; align-items: center; justify-content: center; padding: 24px; }
.pgc-lightbox[hidden] { display: none; }
.pgc-lightbox figure { margin: 0; max-width: min(1200px, 90vw); text-align: center; }
.pgc-lightbox img { max-width: 100%; max-height: 80vh; border-radius: 4px; }
.pgc-lightbox figcaption { color: #fff; margin-top: 12px; font-size: 14px; letter-spacing: 0.04em; }
.pgc-lightbox button { position: absolute; background: none; border: 0; color: #fff; font-size: 44px; line-height: 1; width: 56px; height: 56px; cursor: pointer; }
.pgc-lb-close { top: 16px; right: 16px; }
.pgc-lb-prev { left: 8px; top: 50%; transform: translateY(-50%); }
.pgc-lb-next { right: 8px; top: 50%; transform: translateY(-50%); }

.pgc-card-img img[src*="new-home"] { object-position: center 60%; }
