/* ============================================
   SENTINEL PORTFOLIO — portfolio.css
   Single stylesheet for portfolio.php
   ============================================ */

:root {
  --green-dark:  #1E5C2E;
  --green-mid:   #2F7D32;
  --green-light: #4caf50;
  --green-tint:  #e8f5ea;
  --gold:        #C9A84C;
  --white:       #ffffff;
  --gray-100:    #f5f5f3;
  --gray-200:    #e8e8e5;
  --gray-400:    #a0a09a;
  --gray-600:    #6b6b65;
  --text:        #111310;
  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   14px;
  --p-shadow:    0 1px 3px rgba(0,0,0,0.07), 0 4px 12px rgba(0,0,0,0.05);
  --p-t:         0.2s ease;
}

/* ── HERO ─────────────────────────────────────────────── */
section.portfoliohero {
  background: linear-gradient(135deg, #0f3318 0%, var(--green-dark) 50%, #142e1a 100%);
  padding: 4rem 2.5rem 0;
  position: relative;
  overflow: hidden;
  min-height: 0;
  height: auto;
  max-height: none;
  display: block;
  text-align: left;
  align-items: unset;
  justify-content: unset;
  flex-direction: unset;
  padding: 120px 40px 0;
}

/* Watermark */
section.portfoliohero::after {
  content: 'SENTINEL';
  position: absolute;
  right: -20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 180px;
  font-weight: 900;
  color: rgba(255,255,255,0.04);
  letter-spacing: 10px;
  pointer-events: none;
  user-select: none;
}


section.portfoliohero,
section.portfoliohero * {
  box-sizing: border-box;
}

section.portfoliohero {
  display: block;
}

/* The inner wrapper must not stretch to fill dead space */
.ph-inner {
  height: auto;
  min-height: 0;
}

/* Trust bar must sit flush below hero content, no gap */
.trust-bar {
  margin-top: 0;
  position: relative;
  z-index: 1;
}


.ph-inner {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  padding-bottom: 3rem;
  text-align: left;
}

.ph-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  letter-spacing: 2.5px;
  font-weight: 600;
  color: var(--green-light);
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.ph-eyebrow::before {
  content: '';
  display: block;
  width: 24px;
  height: 1.5px;
  background: var(--green-light);
}

section.portfoliohero h1 {
  font-size: clamp(36px, 5vw, 52px);
  color: #fff;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  max-width: 800px;
  text-align: left;
}

.ph-sub {
  font-size: 16px;
  color: rgba(255,255,255,0.55);
  max-width: 700px;
  line-height: 1.75;
  margin-bottom: 2rem;
  text-align: left;
}

.ph-stats {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
  text-align: left;
  padding-bottom: 50px;
}

.ph-stats .ph-stat { text-align: left; }

.ph-stat-val {
  font-size: 28px;
  font-weight: 600;
  color: var(--gold);
  line-height: 1;
  margin-bottom: 3px;
  display: block;
}

.ph-stat-label {
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
}

/* ── TRUST BAR ───────────────────────────────────────── */
.trust-bar {
  background: rgba(255,255,255,0.05);
  border-top: 1px solid rgba(255,255,255,0.07);
  display: block;
}

.trust-bar-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2.5rem;
  display: flex;
  align-items: center;
  overflow-x: auto;
  scrollbar-width: none;
  flex-wrap: nowrap;
}

.trust-bar-inner::-webkit-scrollbar { display: none; }

.tbadge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0.85rem 1.25rem;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  white-space: nowrap;
  border-right: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
}

.tbadge:last-child { border-right: none; }

.tbadge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green-light);
  flex-shrink: 0;
  display: inline-block;
}

/* ── CONTROLS ────────────────────────────────────────── */
.controls {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  position: sticky;
  top: 80px;
  z-index: 90;
  display: block;
}

.controls .tabs {
  display: flex;
  padding: 0 2.5rem;
  max-width: 1300px;
  margin: 0 auto;
  overflow-x: auto;
  scrollbar-width: none;
}

.controls .tabs::-webkit-scrollbar { display: none; }

.tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 1rem;
  height: 48px;
  font-size: 13px;
  color: var(--gray-600);
  cursor: pointer;
  border-bottom: 2.5px solid transparent;
  border-top: none;
  border-left: none;
  border-right: none;
  white-space: nowrap;
  background: none;
  font-family: inherit;
  transition: color var(--p-t);
  flex-shrink: 0;
}

.tab-btn:hover { color: var(--text); }

.tab-btn.active {
  color: var(--green-dark);
  border-bottom-color: var(--green-mid);
  font-weight: 500;
}

.tab-count {
  font-size: 10px;
  background: var(--gray-100);
  color: var(--gray-600);
  padding: 1px 7px;
  border-radius: 20px;
  font-weight: 500;
}

.tab-btn.active .tab-count {
  background: var(--green-tint);
  color: var(--green-mid);
}

.filter-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0.6rem 2.5rem;
  max-width: 1300px;
  margin: 0 auto;
  border-top: 1px solid var(--gray-200);
  flex-wrap: wrap;
}

.filter-label {
  font-size: 11.5px;
  color: var(--gray-400);
  flex-shrink: 0;
}

.filter-pill {
  font-size: 12px;
  padding: 4px 13px;
  border: 1px solid var(--gray-200);
  border-radius: 20px;
  background: none;
  color: var(--gray-600);
  cursor: pointer;
  font-family: inherit;
  transition: all var(--p-t);
  line-height: normal;
}

.filter-pill:hover {
  border-color: var(--green-mid);
  color: var(--green-mid);
}

.filter-pill.active {
  background: var(--green-dark);
  border-color: var(--green-dark);
  color: #fff;
}

.search-wrap {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  padding: 5px 11px;
  transition: border-color var(--p-t);
  background: var(--white);
}

.search-wrap:focus-within { border-color: var(--green-mid); }

.search-wrap svg {
  width: 14px;
  height: 14px;
  stroke: var(--gray-400);
  flex-shrink: 0;
}

.search-wrap input {
  border: none;
  outline: none;
  font-size: 12.5px;
  font-family: inherit;
  color: var(--text);
  background: transparent;
  width: 150px;
  box-shadow: none;
}

.search-wrap input::placeholder { color: var(--gray-400); }

/* ── MAIN ─────────────────────────────────────────────── */
main.main {
  max-width: 1300px;
  margin: 0 auto;
  padding: 2rem 2.5rem;
}

/* Stats */
.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 2.5rem;
}

.stat-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  box-shadow: var(--p-shadow);
  text-align: left;
}

.stat-card-val {
  font-size: 26px;
  font-weight: 600;
  color: var(--green-dark);
  line-height: 1;
  margin-bottom: 4px;
  display: block;
}

.stat-card-label {
  font-size: 11.5px;
  color: var(--gray-600);
  display: block;
}

/* Section header */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.section-head h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin: 0;
}

.section-head h2::before {
  content: '';
  display: block;
  width: 20px;
  height: 2px;
  background: var(--green-mid);
  border-radius: 1px;
  flex-shrink: 0;
}

.section-sub {
  font-size: 12px;
  color: var(--gray-400);
}

hr.section-divider {
  border: none;
  border-top: 1px solid var(--gray-200);
  margin: 2.5rem 0;
}

/* ── CARD GRID ────────────────────────────────────────── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 14px;
  margin-bottom: 1rem;
}

/* ── HOVER CARD ───────────────────────────────────────── */
.hcard {
  height: 170px;
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: default;
  box-shadow: var(--p-shadow);
  display: block;
}

.hcard.hidden { display: none; }

/* FRONT */
.hcard-front {
  position: absolute;
  inset: 0;
  top: 0; left: 0; right: 0; bottom: 0;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  padding: 1rem 1rem 0.85rem;
  transition: border-color 0.2s ease;
  z-index: 1;
}

.hcard-front.anchor {
  border-color: var(--green-mid);
  border-width: 1.5px;
}

.hcard:hover .hcard-front { border-color: transparent; }

/* Logo area — fixed height box so all logos feel the same size */
.logo-area {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  overflow: hidden;
}

.logo-img {
  /* Every logo rendered inside the same 140×52 frame */
  width: 100%;
  height: 90px;
  max-width: 160px;
  object-fit: contain;
  object-position: center;
  display: block;
}

.lname {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  text-align: center;
  line-height: 1.3;
}

.lsub {
  font-size: 10.5px;
  color: var(--gray-400);
  text-align: center;
  margin-top: 3px;
}

/* Card footer */
.card-foot {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 7px;
  border-top: 1px solid var(--gray-200);
  flex-wrap: wrap;
  gap: 4px;
}

.stag {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 20px;
  background: var(--gray-100);
  color: var(--gray-600);
  font-weight: 500;
  display: inline-block;
}

.abadge {
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 20px;
  background: var(--green-tint);
  color: var(--green-mid);
  font-weight: 500;
  display: inline-block;
}

/* ── OVERLAY ─────────────────────────────────────────────
   CRITICAL: opacity:0 must win over any global styles.
   Using + z-index + pointer-events to ensure
   it stays hidden until hover.
──────────────────────────────────────────────────────── */
.hcard-over {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  background: var(--green-dark);
  border-radius: var(--radius-lg);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 6px;

  /* HIDDEN by default — these must win */
  opacity: 0;
  pointer-events: none;
  visibility: visible;

  transition: opacity 0.2s ease;
  z-index: 2;
}

/* Revealed on hover */
.hcard:hover .hcard-over {
  opacity: 1;
  pointer-events: auto;
}

/* Revealed on tap (mobile) */
.hcard.tapped .hcard-over {
  opacity: 1;
  pointer-events: auto;
}

.over-name {
  font-size: 12.5px;
  font-weight: 600;
  color: #fff;
  line-height: 1.3;
  display: block;
}

.over-desc {
  font-size: 11px;
  color: rgba(255,255,255,0.65);
  line-height: 1.55;
  flex: 1;
  overflow: hidden;
  display: block;
}

.over-locs {
  font-size: 10px;
  color: rgba(255,255,255,0.4);
  line-height: 1.5;
  display: block;
}

.over-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: auto;
}

.otag {
  font-size: 9.5px;
  padding: 2px 7px;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.7);
  display: inline-block;
  background: transparent;
}

.otag.s {
  background: rgba(95,201,106,0.15);
  border-color: rgba(95,201,106,0.35);
  color: var(--green-light);
}

/* ── NO RESULTS ──────────────────────────────────────── */
.no-results {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--gray-400);
  display: none;
}

.no-results svg {
  width: 36px;
  height: 36px;
  stroke: var(--gray-200);
  display: block;
  margin: 0 auto 12px;
}

.no-results p { font-size: 13px; }

/* ── SECTOR GRID ─────────────────────────────────────── */
.sector-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 2.5rem;
}

.sc {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 1rem 1.1rem;
  box-shadow: var(--p-shadow);
  text-align: left;
}

.sc-icon {
  width: 34px;
  height: 34px;
  background: var(--green-tint);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}

.sc-icon svg {
  width: 18px;
  height: 18px;
  stroke: var(--green-mid);
  fill: none;
}

.sc-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 3px;
  display: block;
}

.sc-list {
  font-size: 11px;
  color: var(--gray-400);
  margin-bottom: 10px;
  line-height: 1.5;
  display: block;
}

.bar-bg {
  height: 3px;
  background: var(--gray-200);
  border-radius: 2px;
}

.bar {
  height: 3px;
  background: var(--green-mid);
  border-radius: 2px;
}

/* ── QUOTE STRIP ─────────────────────────────────────── */
.quote-strip {
  background: var(--green-dark);
  border-radius: var(--radius-lg);
  padding: 1.75rem 2rem;
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  margin-bottom: 2rem;
}

.qmark {
  font-size: 64px;
  color: var(--green-light);
  line-height: 0.7;
  flex-shrink: 0;
  margin-top: 6px;
}

.qtext {
  font-size: 14px;
  color: rgba(255,255,255,0.8);
  line-height: 1.7;
  font-style: italic;
  margin-bottom: 8px;
  display: block;
}

.qattr {
  font-size: 11.5px;
  color: rgba(255,255,255,0.35);
  display: block;
}

/* ── CTA STRIP ───────────────────────────────────────── */
.cta-strip {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  box-shadow: var(--p-shadow);
  border: 1px solid var(--gray-200);
  margin-bottom: 2rem;
  flex-wrap: wrap;
  text-align: left;
}

.cta-strip h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.cta-strip p {
  font-size: 12.5px;
  color: var(--gray-600);
  margin: 0;
}

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--green-dark);
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  padding: 11px 22px;
  border-radius: var(--radius-md);
  white-space: nowrap;
  font-family: inherit;
  border: none;
  cursor: pointer;
  transition: background var(--p-t);
  text-decoration: none;
}

.cta-btn:hover { background: var(--green-mid); color: #fff; }

.cta-btn svg {
  width: 14px;
  height: 14px;
  stroke: #fff;
}

/* ── RESPONSIVE ──────────────────────────────────────── */
@media (max-width: 900px) {
  section.portfoliohero { padding: 2.5rem 1.25rem 0; }
  section.portfoliohero::before { display: none; }
  main.main { padding: 1.5rem 1.25rem; }
  .controls .tabs, .filter-row { padding-left: 1.25rem; padding-right: 1.25rem; }
  .trust-bar-inner { padding: 0 1.25rem; }
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .sector-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .stats-row { grid-template-columns: 1fr 1fr; }
  .sector-grid { grid-template-columns: 1fr 1fr; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .search-wrap input { width: 100px; }
  .cta-strip { flex-direction: column; }
  .quote-strip { flex-direction: column; gap: 0; }
  .qmark { font-size: 48px; }
}