/*
Theme Name: GProjectdevelop
Template: twentytwentyfive
Version: 2.0.0
Description: Visual system aligned with Instatic G-Project (dark navy, red accent, cream CTAs).
*/

:root {
  --gp-bg: #0f172a;
  --gp-bg-elevated: #13203a;
  --gp-surface: #1a2744;
  --gp-border: rgba(148, 163, 184, 0.22);
  --gp-text: #f8fafc;
  --gp-muted: #94a3b8;
  --gp-red: #b61722;
  --gp-red-bright: #ef4444;
  --gp-cream: #e8e4d9;
  --gp-cream-text: #0f172a;
  --gp-white: #ffffff;
  --gp-radius: 12px;
  --gp-font: "Sora", "Segoe UI", system-ui, sans-serif;
  --gp-mono: "IBM Plex Mono", ui-monospace, monospace;
  --gp-max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0 !important;
  background: var(--gp-bg) !important;
  color: var(--gp-text) !important;
  font-family: var(--gp-font) !important;
  line-height: 1.6;
  background-image:
    radial-gradient(rgba(148, 163, 184, 0.14) 1px, transparent 1px) !important;
  background-size: 28px 28px !important;
  background-attachment: fixed !important;
}
h1, h2, h3, h4, h5, h6 {
  font-family: var(--gp-font) !important;
  font-weight: 700 !important;
}
a { color: inherit; text-decoration: none; }
.wp-site-blocks { padding: 0 !important; }
.has-global-padding { padding-left: 0 !important; padding-right: 0 !important; }
.gp-posts .gp-post-card.has-global-padding { padding: 0 !important; }
.gp-posts .is-layout-constrained > :where(:not(.alignleft):not(.alignright):not(.alignfull)) {
  max-width: none !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* Header */
.gp-header {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(16px);
  background: rgba(15, 23, 42, 0.88);
  border-bottom: 1px solid var(--gp-border);
}
.gp-header-inner {
  max-width: var(--gp-max);
  margin: 0 auto;
  padding: 0.95rem 1.25rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.gp-logo {
  font-weight: 700; font-size: 1.15rem; letter-spacing: -0.02em;
  color: var(--gp-text) !important;
}
.gp-nav {
  display: flex; flex-wrap: wrap; gap: 1.35rem;
  list-style: none; margin: 0; padding: 0;
}
.gp-nav a {
  color: var(--gp-muted) !important;
  font-size: 0.92rem; font-weight: 500;
  padding-bottom: 0.2rem;
  border-bottom: 2px solid transparent;
}
.gp-nav a:hover,
.gp-nav .current-menu-item a,
.gp-nav a[aria-current="page"] {
  color: var(--gp-text) !important;
  border-bottom-color: var(--gp-red);
}
.gp-header-actions { display: flex; align-items: center; gap: 0.75rem; }
.gp-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  padding: 0.7rem 1.15rem;
  border-radius: 8px;
  font-weight: 600; font-size: 0.92rem;
  border: 1px solid transparent;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.gp-btn:hover { transform: translateY(-1px); }
.gp-btn-cream {
  background: var(--gp-cream);
  color: var(--gp-cream-text) !important;
}
.gp-btn-ghost {
  background: transparent;
  border-color: var(--gp-border);
  color: var(--gp-text) !important;
}
.gp-btn-outline-light {
  background: transparent;
  border-color: rgba(255,255,255,0.35);
  color: var(--gp-text) !important;
}

/* Hero home */
.gp-hero {
  max-width: var(--gp-max);
  margin: 0 auto;
  padding: 4.5rem 1.25rem 3.5rem;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 2.5rem;
  align-items: center;
  min-height: min(78vh, 680px);
}
.gp-badge {
  display: inline-block;
  background: var(--gp-red);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  margin-bottom: 1.1rem;
}
.gp-hero h1 {
  font-size: clamp(2.4rem, 5.2vw, 3.75rem) !important;
  line-height: 1.08 !important;
  letter-spacing: -0.03em;
  font-weight: 700 !important;
  margin: 0 0 1.1rem !important;
  color: var(--gp-text) !important;
  max-width: 14ch;
}
.gp-hero .lead {
  color: var(--gp-muted);
  font-size: 1.05rem;
  max-width: 42ch;
  margin: 0 0 1.75rem;
}
.gp-cta-row { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.gp-hero-visual {
  position: relative;
  min-height: 360px;
  border: 1px solid var(--gp-border);
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(182,23,34,0.18), transparent 45%),
    linear-gradient(180deg, #15213a, #0c1424);
  overflow: hidden;
}
.gp-hero-visual::before {
  content: "";
  position: absolute; inset: 18px;
  border: 1px solid rgba(148,163,184,0.18);
  border-radius: 12px;
}
.gp-hero-visual::after {
  content: "";
  position: absolute;
  width: 42%; height: 70%;
  right: 14%; top: 15%;
  background: linear-gradient(180deg, #243554, #121c31);
  border: 1px solid rgba(148,163,184,0.2);
  border-radius: 10px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.35);
}

/* Sections */
.gp-section {
  max-width: var(--gp-max);
  margin: 0 auto;
  padding: 3.25rem 1.25rem;
}
.gp-section-head { max-width: 640px; margin-bottom: 1.75rem; }
.gp-section h2 {
  font-size: clamp(1.6rem, 3vw, 2.15rem) !important;
  margin: 0 0 0.6rem !important;
  letter-spacing: -0.02em;
  color: var(--gp-text) !important;
}
.gp-section .sub { color: var(--gp-muted); margin: 0; }

.gp-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.gp-card {
  border-radius: var(--gp-radius);
  padding: 1.4rem 1.35rem;
  border: 1px solid var(--gp-border);
}
.gp-card-light {
  background: var(--gp-white);
  color: #1e293b;
  border-color: transparent;
}
.gp-card-light h3,
.gp-card-light .wp-block-heading,
.gp-page .gp-card-light h3 {
  color: #0f172a !important;
  margin: 0.65rem 0 0.45rem;
  font-size: 1.15rem;
}
.gp-card-light p { color: #334155; margin: 0; font-size: 0.95rem; }
.gp-card-light .gp-tag { color: #64748b; }
.gp-card-dark {
  background: var(--gp-bg-elevated);
  color: var(--gp-text);
}
.gp-card-dark h3 { margin: 0.65rem 0 0.45rem; font-size: 1.15rem; color: var(--gp-text) !important; }
.gp-card-dark p { color: var(--gp-muted); margin: 0; font-size: 0.95rem; }
.gp-icon {
  width: 36px; height: 36px; border-radius: 8px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--gp-red); color: #fff;
  font-family: var(--gp-mono); font-size: 0.85rem; font-weight: 700;
}
.gp-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 1rem; }
.gp-tag {
  font-size: 0.68rem; letter-spacing: 0.06em; text-transform: uppercase;
  color: #64748b; font-weight: 600;
}

.gp-why {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.gp-why article {
  padding: 1.25rem;
  border: 1px solid var(--gp-border);
  border-radius: var(--gp-radius);
  background: rgba(19, 32, 58, 0.65);
}
.gp-why h4 { margin: 0 0 0.45rem; font-size: 1.05rem; }
.gp-why p { margin: 0; color: var(--gp-muted); font-size: 0.92rem; }

.gp-cta-band {
  max-width: var(--gp-max);
  margin: 1rem auto 3rem;
  padding: 2.25rem 1.5rem;
  border-radius: 16px;
  border: 1px solid var(--gp-border);
  background:
    radial-gradient(600px 200px at 90% 0%, rgba(182,23,34,0.25), transparent 60%),
    var(--gp-bg-elevated);
  text-align: center;
}
.gp-cta-band h2 { margin: 0 0 0.6rem !important; }
.gp-cta-band p { color: var(--gp-muted); margin: 0 0 1.25rem; }

/* Page hero (services etc) */
.gp-page-hero {
  text-align: center;
  padding: 3.5rem 1.25rem 2rem;
  max-width: 760px;
  margin: 0 auto;
}
.gp-page-hero .gp-badge { background: #334155; }
.gp-page-hero h1 {
  font-size: clamp(2rem, 4vw, 3rem) !important;
  margin: 0 0 0.85rem !important;
  letter-spacing: -0.03em;
}
.gp-page-hero p { color: var(--gp-muted); margin: 0; }

.gp-page {
  max-width: var(--gp-max);
  margin: 0 auto;
  padding: 1rem 1.25rem 3.5rem;
  color: #cbd5e1;
}
.gp-page h1, .gp-page h2, .gp-page h3 { color: var(--gp-text) !important; }
.gp-page a { color: var(--gp-red-bright); text-decoration: underline; text-underline-offset: 3px; }

/* Blog filters — Stitch-inspired chips */
.gp-blog-filters,
.gproj-blog-filters {
  max-width: var(--gp-max) !important;
  margin: 0 auto 0.5rem !important;
  padding: 1.15rem 1.25rem 1.25rem !important;
  border: 1px solid var(--gp-border) !important;
  border-radius: 16px !important;
  background: rgba(19, 32, 58, 0.92) !important;
  backdrop-filter: blur(10px);
}
.gp-blog-filters__search { margin-bottom: 1rem; }
.gp-blog-filters__search-label {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0);
}
.gp-blog-filters__search-row {
  display: flex; gap: 0.6rem; flex-wrap: wrap;
}
.gp-blog-filters__search-row input[type="search"] {
  flex: 1 1 220px;
  min-height: 44px;
  padding: 0.7rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--gp-border);
  background: #0b1220;
  color: var(--gp-text);
  font: inherit;
}
.gp-blog-filters__search-row input[type="search"]::placeholder { color: #64748b; }
.gp-blog-filters__search-row input[type="search"]:focus {
  outline: none;
  border-color: rgba(239, 68, 68, 0.55);
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}
.gp-blog-filters__group { margin-top: 0.85rem; }
.gp-blog-filters__label {
  margin: 0 0 0.55rem;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
  font-weight: 600;
}
.gp-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.gp-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.42rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--gp-border);
  background: rgba(15, 23, 42, 0.7);
  color: #cbd5e1 !important;
  font-size: 0.84rem;
  font-weight: 500;
  transition: background .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}
.gp-chip:hover {
  border-color: rgba(239, 68, 68, 0.45);
  color: #fff !important;
  transform: translateY(-1px);
}
.gp-chip.is-active {
  background: rgba(182, 23, 34, 0.2);
  border-color: #ef4444;
  color: #fff !important;
}
.gp-chip--tag {
  font-family: var(--gp-mono);
  font-size: 0.78rem;
  letter-spacing: 0.01em;
}
.gp-chip__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.18);
  color: #94a3b8;
  font-size: 0.68rem;
  font-weight: 600;
}
.gp-chip.is-active .gp-chip__count {
  background: rgba(239, 68, 68, 0.25);
  color: #fecaca;
}
.gp-blog-filters__clear {
  margin: 0.9rem 0 0;
  font-size: 0.85rem;
}
.gp-blog-filters__clear a {
  color: #f87171 !important;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.gp-posts {
  max-width: var(--gp-max);
  margin: 0 auto;
  padding: 1.25rem 1.25rem 3.5rem;
}
.gp-posts .wp-block-post-template,
.gp-posts ul.wp-block-post-template {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 1.15rem !important;
}
.gp-posts .wp-block-post {
  margin: 0 !important;
}
.gp-post-card,
.wp-block-group.gp-post-card {
  height: 100%;
  background: var(--gp-bg-elevated) !important;
  border: 1px solid var(--gp-border) !important;
  border-radius: 14px !important;
  overflow: hidden;
  display: flex !important;
  flex-direction: column !important;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.gp-post-card:hover {
  border-color: rgba(239, 68, 68, 0.45) !important;
  transform: translateY(-3px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}
.gp-post-card .thumb,
.gp-post-card .wp-block-post-featured-image {
  aspect-ratio: 16/9;
  background: #1e293b;
  overflow: hidden;
  margin: 0 !important;
}
.gp-post-card .thumb img,
.gp-post-card .wp-block-post-featured-image img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.gp-post-card .body {
  padding: 1.05rem 1.1rem 1.2rem !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 0.55rem !important;
  flex: 1 !important;
}
.gp-post-card__meta { gap: 0.55rem !important; }
.gp-post-card .meta,
.gp-post-card .wp-block-post-date,
.gp-post-card .wp-block-post-terms {
  font-family: var(--gp-mono);
  font-size: 0.7rem !important;
  color: var(--gp-muted) !important;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 !important;
}
.gp-post-card .meta-cat a,
.gp-post-card .taxonomy-category a {
  color: #f87171 !important;
  font-weight: 600;
}
.gp-post-card h2,
.gp-post-card .wp-block-post-title {
  font-size: 1.08rem !important;
  line-height: 1.3 !important;
  margin: 0 !important;
}
.gp-post-card h2 a,
.gp-post-card .wp-block-post-title a { color: var(--gp-text) !important; }
.gp-post-card .wp-block-post-excerpt,
.gp-post-card .excerpt {
  color: var(--gp-muted) !important;
  font-size: 0.9rem !important;
  margin: 0 !important;
  flex: 1;
}
.gp-post-card .wp-block-post-excerpt p { margin: 0 !important; }
.gp-post-tags,
.gp-post-card .taxonomy-post_tag {
  display: flex !important;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0.15rem 0 0.25rem !important;
}
.gp-post-tags a,
.gp-post-card .taxonomy-post_tag a {
  display: inline-flex;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--gp-border);
  background: rgba(15, 23, 42, 0.55);
  color: #94a3b8 !important;
  font-size: 0.7rem !important;
  font-family: var(--gp-mono);
  text-transform: none !important;
  letter-spacing: 0 !important;
}
.gp-post-tags a:hover,
.gp-post-card .taxonomy-post_tag a:hover {
  border-color: rgba(239, 68, 68, 0.45);
  color: #fecaca !important;
}
.gp-post-card .read,
.gp-post-card .wp-block-read-more {
  color: #f87171 !important;
  font-weight: 600;
  font-size: 0.88rem;
  margin-top: auto;
}
.gp-pagination {
  margin-top: 1.75rem !important;
  gap: 0.5rem !important;
}
.gp-pagination a,
.gp-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  height: 2.25rem;
  padding: 0 0.65rem;
  border-radius: 8px;
  border: 1px solid var(--gp-border);
  color: var(--gp-muted) !important;
  background: var(--gp-bg-elevated);
}
.gp-pagination .current,
.gp-pagination .page-numbers.current {
  border-color: #ef4444;
  color: #fff !important;
  background: rgba(182, 23, 34, 0.25);
}

@media (max-width: 980px) {
  .gp-posts .wp-block-post-template {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}
@media (max-width: 640px) {
  .gp-posts .wp-block-post-template {
    grid-template-columns: 1fr !important;
  }
}

/* Single */
.gp-single {
  max-width: 760px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}
.gp-single .featured {
  margin: 0 0 1.4rem;
  border-radius: var(--gp-radius);
  overflow: hidden;
  border: 1px solid var(--gp-border);
}
.gp-single .featured img { width: 100%; height: auto; display: block; }
.gp-single .entry-meta {
  font-family: var(--gp-mono);
  font-size: 0.75rem;
  color: var(--gp-muted);
  margin-bottom: 0.7rem;
}
.gp-single h1 {
  font-size: clamp(1.85rem, 4vw, 2.6rem) !important;
  line-height: 1.15 !important;
  margin: 0 0 1rem !important;
}
.gp-single .entry-content { color: #cbd5e1; font-size: 1.05rem; line-height: 1.75; }
.gp-single .entry-content h2,
.gp-single .entry-content h3 { color: var(--gp-text); margin-top: 2rem; }
.gp-single .entry-content a { color: var(--gp-red-bright); }
.gp-single .entry-content pre,
.gp-single .entry-content code {
  font-family: var(--gp-mono);
  background: #0b1220;
  border: 1px solid var(--gp-border);
  border-radius: 8px;
}
.gp-single .entry-content pre { padding: 1rem; overflow: auto; }
.gp-single .entry-content code { padding: 0.1rem 0.35rem; }
.gp-single .entry-content pre code { border: 0; padding: 0; }
.gp-tags-row { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 1.75rem; }
.gp-tags-row a {
  border: 1px solid var(--gp-border);
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  font-size: 0.78rem;
  color: var(--gp-muted) !important;
}
.gproj-related, .gp-related {
  margin-top: 2.5rem !important;
  padding-top: 1.4rem;
  border-top: 1px solid var(--gp-border);
}
.gproj-related h2, .gp-related h2 { font-size: 1.25rem !important; }
.gproj-related a, .gp-related a { color: var(--gp-red-bright); }

/* Footer */
.gp-footer {
  border-top: 1px solid var(--gp-border);
  background: #0a1222;
  padding: 2.75rem 1.25rem 1.5rem;
  margin-top: 2rem;
}
.gp-footer-grid {
  max-width: var(--gp-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 1.5rem;
}
.gp-footer h5 {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gp-text);
}
.gp-footer p, .gp-footer a { color: var(--gp-muted); font-size: 0.9rem; }
.gp-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.4rem; }
.gp-footer a:hover { color: var(--gp-text); }
.gp-copy {
  max-width: var(--gp-max);
  margin: 1.75rem auto 0;
  padding-top: 1rem;
  border-top: 1px solid var(--gp-border);
  color: var(--gp-muted);
  font-size: 0.82rem;
}

@media (max-width: 900px) {
  .gp-hero { grid-template-columns: 1fr; min-height: auto; }
  .gp-hero-visual { min-height: 240px; }
  .gp-cards, .gp-why, .gp-footer-grid { grid-template-columns: 1fr; }
  .gp-nav { display: none; }
}