/*
Theme Name: Terran Geospatial
Theme URI: https://www.terrangis.com
Description: Twenty Twenty-Five child theme for Terran Geospatial. Styles live in theme.json and styles/*.json.
Author: Terran Geospatial
Template: twentytwentyfive
Version: 0.1.0
Requires at least: 6.7
Text Domain: terran
*/

/* Icons: Lucide (ISC, assets/icons/LICENSE-lucide.txt) drawn as CSS masks so they take the palette color.
   Use an empty Group block with classes: terran-icon terran-icon--<name>  (optional: is-small, is-highlight) */
.terran-icon{display:block;width:44px;height:44px;flex:none;margin:0 0 1rem;background-color:var(--wp--preset--color--accent-1);-webkit-mask:var(--terran-icon) center/contain no-repeat;mask:var(--terran-icon) center/contain no-repeat}
.terran-icon.is-small{width:22px;height:22px;margin:0}
.terran-icon.is-highlight{background-color:var(--wp--preset--color--accent-2)}
.terran-icon--badge-check{--terran-icon:url(assets/icons/badge-check.svg)}
.terran-icon--building-2{--terran-icon:url(assets/icons/building-2.svg)}
.terran-icon--clipboard-check{--terran-icon:url(assets/icons/clipboard-check.svg)}
.terran-icon--code-xml{--terran-icon:url(assets/icons/code-xml.svg)}
.terran-icon--compass{--terran-icon:url(assets/icons/compass.svg)}
.terran-icon--database{--terran-icon:url(assets/icons/database.svg)}
.terran-icon--graduation-cap{--terran-icon:url(assets/icons/graduation-cap.svg)}
.terran-icon--landmark{--terran-icon:url(assets/icons/landmark.svg)}
.terran-icon--layers{--terran-icon:url(assets/icons/layers.svg)}
.terran-icon--layout-dashboard{--terran-icon:url(assets/icons/layout-dashboard.svg)}
.terran-icon--life-buoy{--terran-icon:url(assets/icons/life-buoy.svg)}
.terran-icon--mail{--terran-icon:url(assets/icons/mail.svg)}
.terran-icon--map{--terran-icon:url(assets/icons/map.svg)}
.terran-icon--map-pin{--terran-icon:url(assets/icons/map-pin.svg)}
.terran-icon--phone{--terran-icon:url(assets/icons/phone.svg)}
.terran-icon--printer{--terran-icon:url(assets/icons/printer.svg)}
.terran-icon--route{--terran-icon:url(assets/icons/route.svg)}
.terran-icon--shield{--terran-icon:url(assets/icons/shield.svg)}
.terran-icon--smartphone{--terran-icon:url(assets/icons/smartphone.svg)}
.terran-icon--messages-square{--terran-icon:url(assets/icons/messages-square.svg)}
.terran-icon--wrench{--terran-icon:url(assets/icons/wrench.svg)}
.terran-icon--waypoints{--terran-icon:url(assets/icons/waypoints.svg)}

/* In-page anchors (home → Services deep links) land below the sticky header */
.wp-site-blocks [id]{scroll-margin-top:110px}
/* "How we work" process strip (Services): numbered badges on a dotted connector, white step cards */
.terran-steps{position:relative;gap:1.5rem!important;grid-template-columns:repeat(4,minmax(0,1fr))!important}
@media (max-width:1000px){.terran-steps{grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media (max-width:600px){.terran-steps{grid-template-columns:1fr!important}}
.terran-steps::before{content:"";position:absolute;left:3rem;right:3rem;top:3.1rem;height:2px;z-index:0;
  background:repeating-linear-gradient(90deg,var(--wp--preset--color--accent-2) 0 8px,transparent 8px 16px);opacity:.7}
.terran-step{position:relative;z-index:1;background:#fff;border-radius:16px;padding:1.75rem 1.5rem 1.5rem;box-shadow:0 1px 2px rgba(14,42,53,.06),0 8px 24px rgba(14,42,53,.06);transition:transform .2s,box-shadow .2s}
.terran-step:hover{transform:translateY(-3px);box-shadow:0 2px 4px rgba(14,42,53,.08),0 14px 32px rgba(14,42,53,.1)}
.terran-step .terran-step-num{width:3rem;height:3rem;border-radius:50%;margin:0 0 1.1rem!important;display:flex;align-items:center;justify-content:center;
  background:var(--wp--preset--color--accent-1);color:#fff;font-weight:800;font-size:1rem;box-shadow:0 0 0 6px #fff}
.terran-step .terran-step-icon{position:absolute;top:1.6rem;right:1.4rem;width:28px;height:28px;margin:0;background-color:var(--wp--preset--color--accent-2);opacity:.85}
.terran-step h3{margin:0 0 .5rem!important;font-size:1.3rem}
.terran-step p{margin:0}
.terran-step .terran-step-tag{display:inline-block;margin-top:1rem!important;padding:.3rem .75rem;border-radius:999px;font-size:.8rem;font-weight:700;
  color:var(--wp--preset--color--accent-1);background:color-mix(in srgb,var(--wp--preset--color--accent-2) 14%,transparent)}
@media (max-width:1000px){.terran-steps::before{display:none}}
@media (prefers-reduced-motion:reduce){.terran-step{transition:none}.terran-step:hover{transform:none}}
/* Experience case studies: white cards on warm sections, image beside detail, technology chips */
.terran-jumps{display:flex;flex-wrap:wrap;gap:.6rem;justify-content:center;margin:0}
.terran-jumps .terran-jump{padding:.5rem 1rem;border-radius:999px;background:#fff;border:1px solid color-mix(in srgb,var(--wp--preset--color--accent-1) 25%,transparent);
  color:var(--wp--preset--color--accent-1);font-weight:700;font-size:.9rem;text-decoration:none}
.terran-jumps .terran-jump:hover{background:var(--wp--preset--color--accent-1);color:#fff}
.terran-case{background:#fff;border-radius:18px;padding:2rem;margin-top:2rem!important;box-shadow:0 1px 2px rgba(14,42,53,.05),0 10px 28px rgba(14,42,53,.06)}
.terran-case .wp-block-columns{gap:2.5rem!important;margin:0}
.terran-case .terran-case-media img{width:100%;aspect-ratio:16/10;object-fit:cover;border-radius:12px}
.terran-case .terran-case-media.terran-illustration img{object-fit:contain;background:var(--wp--preset--color--accent-5)}
.terran-case .terran-case-media + .terran-case-media{margin-top:1.25rem!important}
.terran-case h3{margin:.25rem 0 .75rem!important;font-size:1.45rem}
.terran-case h4{margin:1.25rem 0 .4rem!important;font-size:.78rem;text-transform:uppercase;letter-spacing:.1em;color:var(--wp--preset--color--accent-1)}
.terran-case ul{margin:0;padding-left:1.1rem}
.terran-case li{margin:.3rem 0;font-size:.97rem;line-height:1.55}
.terran-case h4 + ul li::marker{color:var(--wp--preset--color--accent-2)}
.terran-case .terran-chips{margin-top:1.25rem!important;line-height:2.1}
.terran-chip{display:inline-block;padding:.2rem .65rem;margin:0 .35rem 0 0;border-radius:999px;background:var(--wp--preset--color--accent-5);font-size:.78rem;font-weight:700;color:var(--wp--preset--color--contrast);line-height:1.6}
@media (max-width:781px){.terran-case{padding:1.25rem}.terran-case .wp-block-columns{flex-direction:column}.terran-case .wp-block-column:has(.terran-case-media){order:-1}}
/* Cards */
.terran-card{border:1px solid var(--wp--preset--color--accent-6);border-radius:8px;transition:border-color .2s,transform .2s}
.terran-card:hover{border-color:var(--wp--preset--color--accent-2);transform:translateY(-2px)}
/* Services "Apps" row: titles a step smaller so "Dashboards & web apps" stays on one line */
.terran-app-cards h3{font-size:1.25rem}

/* Logos: swap rules live in theme.json styles.css (inline, so never stale): color logo on light, white logo in .is-dark */

/* Sticky header */
header.wp-block-template-part{position:sticky;top:var(--wp-admin--admin-bar--height,0);z-index:100}

/* Hero: USGS 3DEP contours of the Lake Arrowhead area (assets/images/hero-contours.svg), slow drift */
.terran-hero{position:relative;overflow:hidden;isolation:isolate}
.terran-hero::before{content:"";position:absolute;inset:-6%;z-index:-1;background:url(assets/images/hero-contours.svg) center/cover no-repeat;animation:terran-drift 70s ease-in-out infinite alternate}
.terran-hero::after{content:"";position:absolute;inset:0;z-index:-1;background:linear-gradient(90deg,var(--wp--preset--color--deep) 0%,transparent 75%);opacity:.6}
@keyframes terran-drift{from{transform:translate3d(0,0,0) scale(1)}to{transform:translate3d(-3%,2%,0) scale(1.07)}}

/* Photos */
.terran-photo img{width:100%;aspect-ratio:16/10;object-fit:cover;border-radius:8px;display:block}
.terran-photo.is-tall img{aspect-ratio:4/5}

/* Stats row */
.terran-stat-value{white-space:nowrap;font-size:clamp(1.8rem,4vw,3rem);font-weight:700;line-height:1;letter-spacing:-0.02em;color:var(--wp--preset--color--accent-1);margin-bottom:.4rem}
.terran-stat-label{color:var(--wp--preset--color--accent-4);font-size:.95rem;margin-top:0}

/* Scroll reveal (CSS only; skipped where unsupported or when visitors reduce motion) */
@supports (animation-timeline: view()){
	@media (prefers-reduced-motion: no-preference){
		.terran-reveal{animation:terran-rise linear both;animation-timeline:view();animation-range:entry 0% entry 40%}
	}
}
@keyframes terran-rise{from{opacity:0;transform:translateY(24px)}to{opacity:1;transform:none}}

@media (prefers-reduced-motion: reduce){.terran-hero::before{animation:none}}

/* Dark band with shaded-terrain photo under a deep tint */
.terran-bg-terrain{background-image:linear-gradient(color-mix(in srgb,var(--wp--preset--color--deep) 88%,transparent),color-mix(in srgb,var(--wp--preset--color--deep) 88%,transparent)),url(assets/images/photos/shaded-terrain.webp);background-size:cover;background-position:center}

/* Full-width bands meet the footer with no gap */
.wp-site-blocks > footer{margin-block-start:0}

/* Footer certification badge (our own mark, not a state seal) */
.terran-cert{margin-top:1rem}
.terran-cert span{display:inline-flex;align-items:center;gap:.5rem;padding:.4rem .75rem;border:1px solid currentColor;border-radius:999px;font-size:.8rem;line-height:1.3}
.terran-cert span::before{content:"";flex:none;width:18px;height:18px;background-color:var(--wp--preset--color--accent-2);-webkit-mask:url(assets/icons/badge-check.svg) center/contain no-repeat;mask:url(assets/icons/badge-check.svg) center/contain no-repeat}

/* Header on small screens */
header .wp-block-button__link{white-space:nowrap}
@media (max-width:600px){header .terran-logo img{width:150px!important}}

/* Story carousel (assets/js/terran.js adds the nav) */
.terran-carousel{display:flex;flex-wrap:nowrap;gap:0;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;scroll-behavior:smooth}
.terran-carousel::-webkit-scrollbar{display:none}
.terran-carousel > .terran-slide{flex:0 0 100%;scroll-snap-align:start;margin:0!important}
.terran-carousel .terran-photo img{aspect-ratio:16/10}
/* Carousel image lightbox (assets/js/terran.js) */
.terran-zoomable{position:relative}
.terran-zoomable img{cursor:zoom-in}
.terran-zoomable::after{content:"";position:absolute;right:12px;bottom:12px;width:34px;height:34px;border-radius:50%;pointer-events:none;opacity:.85;transition:opacity .2s,transform .2s;
  background:rgba(20,24,38,.72) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7'/%3E%3C/svg%3E") center/16px no-repeat}
.terran-zoomable:hover::after,.terran-zoomable:focus-within::after{opacity:1;transform:scale(1.08)}
.terran-zoomable img:focus-visible{outline:3px solid var(--wp--preset--color--accent-2);outline-offset:3px}
.terran-lightbox{border:0;padding:0;background:transparent;max-width:96vw;max-height:94vh;overflow:visible}
.terran-lightbox::backdrop{background:rgba(10,14,24,.86)}
.terran-lightbox img{display:block;width:min(1400px,94vw);height:auto;max-height:88vh;object-fit:contain;border-radius:14px;box-shadow:0 20px 60px rgba(0,0,0,.45)}
.terran-lightbox-close{position:absolute;top:-14px;right:-14px;width:40px;height:40px;border-radius:50%;border:0;cursor:pointer;font-size:26px;line-height:40px;color:#14233A;background:#fff;box-shadow:0 4px 14px rgba(0,0,0,.3)}
@media (prefers-reduced-motion:reduce){.terran-zoomable::after{transition:none}}
.terran-carousel-nav{display:flex;justify-content:center;align-items:center;gap:.6rem;margin-top:1.5rem}
.terran-carousel-nav button{cursor:pointer;border:0;background:none;color:var(--wp--preset--color--accent-1);font:inherit}
.terran-prev,.terran-next{width:40px;height:40px;border-radius:50%;border:1px solid var(--wp--preset--color--accent-6)!important;font-size:1.2rem!important;line-height:1}
.terran-prev::before{content:"←"}.terran-next::before{content:"→"}
.terran-dot{width:10px;height:10px;padding:0;border-radius:50%;background:var(--wp--preset--color--accent-6)!important}
.terran-dot[aria-current="true"]{background:var(--wp--preset--color--accent-1)!important}
.terran-slide-label{text-transform:uppercase;letter-spacing:.12em;font-size:.8rem;font-weight:600;color:var(--wp--preset--color--accent-1)}
.terran-slide-result{border-left:3px solid var(--wp--preset--color--accent-2);padding-left:1rem;font-weight:600}

/* Generated SVG illustrations (assets/images/illustrations, scripts/make_illustrations.py): never crop */
.terran-photo.terran-illustration img{object-fit:contain;aspect-ratio:16/10;border-radius:12px}
.terran-photo.terran-illustration.is-portrait img{aspect-ratio:auto;height:auto;max-width:520px;margin:0 auto;border-radius:18px}
/* Integrations: center the portrait diagram against the longer text column */
.wp-block-columns:has(img[src*="integrations-hub"]) > .wp-block-column{align-self:center}
.terran-card .terran-illustration{margin:0 0 1.25rem}

/* Dark band over the Lake Arrowhead photo (About; Joe's photo) */
.terran-bg-lake{background-image:linear-gradient(90deg,color-mix(in srgb,var(--wp--preset--color--deep) 88%,transparent) 0%,color-mix(in srgb,var(--wp--preset--color--deep) 45%,transparent) 100%),url(assets/images/photos/lake-arrowhead.webp);background-size:cover;background-position:center 55%}


/* "Delivered for" client-type row (home) */
.terran-trust-label{text-transform:uppercase;letter-spacing:.12em;font-size:.75rem;font-weight:600;color:var(--wp--preset--color--accent-4);margin-bottom:.75rem!important}
.terran-trust{gap:.5rem 2rem;border-top:1px solid var(--wp--preset--color--accent-6);border-bottom:1px solid var(--wp--preset--color--accent-6);padding:1.1rem 0}
.terran-trust-item{margin:0!important;font-weight:700;font-size:1.05rem;color:var(--wp--preset--color--accent-3);letter-spacing:-0.01em}

/* Contact form (Fluent Forms) in theme colors */
.fluentform .ff-el-input--label label{font-weight:600;color:var(--wp--preset--color--contrast)}
.fluentform .ff-el-form-control{border:1px solid var(--wp--preset--color--accent-6);border-radius:6px;padding:.7rem .8rem;font:inherit;background:var(--wp--preset--color--base)}
.fluentform .ff-el-form-control:focus{border-color:var(--wp--preset--color--accent-1);box-shadow:0 0 0 3px color-mix(in srgb,var(--wp--preset--color--accent-1) 20%,transparent)}
.fluentform .ff-btn-submit{background:var(--wp--preset--color--accent-1)!important;color:var(--wp--preset--color--base)!important;border:0;border-radius:4px;padding:.8rem 1.6rem;font-weight:600}
.fluentform .ff-btn-submit:hover{background:var(--wp--preset--color--accent-3)!important;color:var(--wp--preset--color--inverse)!important}
:not(.is-layout-grid) > .terran-card + .terran-card{margin-top:1.5rem}
.fluentform .ff-el-group{margin-bottom:1.1rem}
.fluentform .ff-el-form-control,.fluentform select.ff-el-form-control,.fluentform textarea.ff-el-form-control{width:100%;max-width:none;box-sizing:border-box;display:block}
.fluentform textarea.ff-el-form-control{min-height:9rem;resize:vertical}
.fluentform .ff-el-input--label{margin-bottom:.35rem}

/* Cards in a grid row share one height */
.wp-block-group.is-layout-grid{align-items:stretch}
.is-layout-grid > .terran-card{height:100%;box-sizing:border-box}
