/* JPHB Group — shared styles. Light theme: white / light grey / light blue, navy + amber accents. */
:root {
  --navy: #23307f;
  --navy-deep: #1a2361;
  --navy-soft: #3a4aa5;
  --amber: #f6a41c;
  --amber-soft: #fce3b5;
  --ink: #1d2440;
  --muted: #5b6379;
  --bg: #ffffff;
  --bg-soft: #f5f7fb;
  --bg-tint: #ecf1f9;
  --line: #e3e8f2;
  --radius: 14px;
  --maxw: 1360px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
h1, h2, h3, .page-hero h1, .hero h1 { font-family: 'Fraunces', Georgia, serif; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--navy-soft); }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 2rem; }

/* ---------- Header ---------- */
header.site {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  max-width: var(--maxw); margin: 0 auto; padding: 0.7rem 1.5rem;
}
.brand { display: flex; align-items: center; gap: 0.8rem; font-weight: 800; font-size: 1.75rem; color: var(--ink); letter-spacing: 0.005em; white-space: nowrap; }
.brand img { width: 76px; height: 76px; object-fit: contain; }
.brand span em { font-style: normal; color: var(--navy); }
nav.links { display: flex; gap: 1rem; align-items: center; flex-wrap: nowrap; white-space: nowrap; }
nav.links a { font-size: 0.9rem; font-weight: 500; color: var(--muted); }
nav.links a:hover, nav.links a.active { color: var(--navy); }
nav.links a.cta {
  background: var(--navy); color: #fff; padding: 0.45rem 1rem; border-radius: 999px;
}
nav.links a.cta:hover { background: var(--navy-deep); }
.menu-btn { display: none; background: none; border: 0; font-size: 1.5rem; color: var(--navy); cursor: pointer; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1100px 420px at 85% -10%, rgba(246,164,28,0.14), transparent 60%),
    radial-gradient(900px 500px at -10% 20%, rgba(35,48,127,0.10), transparent 55%),
    linear-gradient(180deg, #fdfefe 0%, var(--bg-tint) 100%);
  padding: 6rem 0 5rem;
}
.hero .wrap { position: relative; z-index: 2; }
/* Floating light orbs behind hero content */
.orb {
  position: absolute; border-radius: 50%; filter: blur(46px); z-index: 1; pointer-events: none;
  opacity: 0.55;
}
.orb.o1 { width: 340px; height: 340px; background: radial-gradient(circle, rgba(246,164,28,0.45), transparent 65%); top: -80px; left: 4%; animation: drift1 16s ease-in-out infinite; }
.orb.o2 { width: 420px; height: 420px; background: radial-gradient(circle, rgba(58,74,165,0.35), transparent 65%); bottom: -140px; right: 8%; animation: drift2 20s ease-in-out infinite; }
.orb.o3 { width: 240px; height: 240px; background: radial-gradient(circle, rgba(246,164,28,0.28), transparent 60%); top: 30%; right: 34%; animation: drift3 24s ease-in-out infinite; }
@keyframes drift1 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(60px, 30px) scale(1.12); } }
@keyframes drift2 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(-70px, -40px) scale(1.08); } }
@keyframes drift3 { 0%,100% { transform: translate(0,0); } 33% { transform: translate(-40px, 40px); } 66% { transform: translate(50px, -25px); } }
/* Faint spectrum wave line across the hero */
.hero-wave { position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0.5; }
@media (prefers-reduced-motion: reduce) { .orb { animation: none; } }
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.3rem);
  font-weight: 700; letter-spacing: -0.02em; line-height: 1.15;
  max-width: 18em;
}
.hero h1 .accent { color: var(--navy); }
.hero p.lede {
  margin-top: 1.2rem; font-size: clamp(1.02rem, 2vw, 1.2rem);
  color: var(--muted); max-width: 44em;
}
.hero .actions { margin-top: 2rem; display: flex; gap: 0.9rem; flex-wrap: wrap; }
.btn {
  display: inline-block; padding: 0.7rem 1.5rem; border-radius: 999px;
  font-weight: 600; font-size: 0.95rem; border: 1.5px solid transparent;
}
.btn.primary { background: var(--navy); color: #fff; }
.btn.primary:hover { background: var(--navy-deep); color: #fff; }
.btn.ghost { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn.ghost:hover { background: var(--navy); color: #fff; }
.btn.amber { background: var(--amber); color: #2a1e04; }
.btn.amber:hover { filter: brightness(1.06); }

/* Page hero (interior pages) */
.page-hero { padding: 4rem 0 3rem; border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #fdfefe, var(--bg-soft)); }
.page-hero .kicker { text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.78rem; font-weight: 700; color: var(--amber); }
.page-hero h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 700; letter-spacing: -0.02em; margin-top: 0.4rem; }
.page-hero p { color: var(--muted); max-width: 46em; margin-top: 0.8rem; font-size: 1.05rem; }

/* ---------- Sections ---------- */
section.block { padding: 4rem 0; }
section.block.soft { background: var(--bg-soft); }
section.block.tint { background: var(--bg-tint); }
.section-head { margin-bottom: 2.2rem; }
.section-head .kicker { text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.78rem; font-weight: 700; color: var(--amber); display: inline-flex; align-items: center; gap: 0.6rem; }
.section-head .kicker::before { content: ""; width: 34px; height: 2px; background: var(--amber); border-radius: 1px; }
.section-head h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 700; letter-spacing: -0.015em; margin-top: 0.3rem; }
.section-head p { color: var(--muted); max-width: 46em; margin-top: 0.6rem; }

/* ---------- Company cards (tiny.com-style grid) ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.4rem; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: 0 18px 44px rgba(29,36,64,0.14); }
.card .visual { height: 175px; position: relative; overflow: hidden; }
.card .visual img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.card:hover .visual img { transform: scale(1.06); }
.card .visual.bg { background-size: cover; background-position: center; transition: transform 0.5s ease; }
.card .visual.darwin { background: linear-gradient(120deg, var(--navy-deep) 0%, var(--navy) 45%, var(--amber) 130%); }
.card .visual.software { background: linear-gradient(135deg, #22307e, #3a4aa5 60%, #6a7cd8); }
.card .visual.solutions { background: linear-gradient(160deg, #f6a41c 0%, #f3b95a 40%, #23307f 140%); }
.card .visual.engineering { background: linear-gradient(135deg, #39415e, #23307f 70%, #5b6379); }
.card .visual svg { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0.5; }
.card .body { padding: 1.3rem 1.4rem 1.5rem; display: flex; flex-direction: column; flex: 1; }
.card h3 { font-size: 1.12rem; font-weight: 700; letter-spacing: -0.01em; }
.card .tag { font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); margin-top: 0.15rem; }
.card p { font-size: 0.93rem; color: var(--muted); margin-top: 0.6rem; flex: 1; }
.card .go { margin-top: 1rem; font-weight: 600; font-size: 0.9rem; color: var(--navy); }
.card .go::after { content: " →"; }

/* ---------- Feature rows (Exponent-style alternating) ---------- */
.feature { display: grid; grid-template-columns: 1.05fr 1fr; gap: 3rem; align-items: center; padding: 2.6rem 0; }
.feature.flip .media { order: 2; }
.feature h3 { font-size: 1.4rem; font-weight: 700; letter-spacing: -0.01em; }
.feature p { color: var(--muted); margin-top: 0.7rem; }
.feature ul { margin: 0.8rem 0 0 1.1rem; color: var(--muted); }
.feature ul li { margin-top: 0.35rem; }
.media {
  border-radius: var(--radius); min-height: 260px; position: relative; overflow: hidden;
  border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
}
.media .ph-label {
  position: absolute; bottom: 10px; right: 14px; font-size: 0.7rem; letter-spacing: 0.08em;
  text-transform: uppercase; color: rgba(255,255,255,0.75); font-weight: 600;
}
.media.g-energy { background: linear-gradient(135deg, #1a2361, #23307f 55%, #f6a41c 140%); }
.media.g-sky { background: linear-gradient(160deg, #dbe7f7, #b9cdea 55%, #f2d9a7 130%); }
.media.g-lab { background: linear-gradient(135deg, #39415e, #5b6379 70%, #8d97b5); }
.media.g-soft { background: linear-gradient(135deg, #ecf1f9, #d7e1f3); }
.media svg { width: 62%; max-height: 82%; opacity: 0.85; }

/* ---------- Stats strip ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1.2rem; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem 1.5rem; }
.stat .num { font-size: 1.9rem; font-weight: 800; color: var(--navy); letter-spacing: -0.02em; }
.stat .lbl { font-size: 0.86rem; color: var(--muted); margin-top: 0.2rem; }

/* ---------- Lists / service grids ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.4rem; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem 1.5rem; }
.tile h4 { font-size: 1.02rem; font-weight: 700; }
.tile p { font-size: 0.9rem; color: var(--muted); margin-top: 0.45rem; }
.tile .badge { display: inline-block; font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.09em;
  background: var(--amber-soft); color: #7a5205; border-radius: 999px; padding: 0.18rem 0.6rem; margin-bottom: 0.5rem; }
.tile .badge.blue { background: #dfe6f8; color: var(--navy); }

/* ---------- Store ---------- */
.store-search { display: flex; gap: 0.6rem; max-width: 560px; margin-top: 1.4rem; }
.store-search input {
  flex: 1; padding: 0.75rem 1.1rem; border: 1.5px solid var(--line); border-radius: 10px;
  font-size: 0.95rem; font-family: inherit; background: #fff;
}
.store-search input:focus { outline: 2px solid var(--navy-soft); border-color: var(--navy-soft); }
.cat { display: flex; gap: 1rem; align-items: flex-start; }
.cat .ic { flex: 0 0 46px; height: 46px; border-radius: 10px; background: var(--bg-tint); display: flex; align-items: center; justify-content: center; color: var(--navy); font-weight: 800; }
.notice {
  border: 1.5px dashed var(--amber); background: #fffaf0; color: #6b4a08;
  padding: 1rem 1.3rem; border-radius: var(--radius); font-size: 0.95rem; margin-top: 2rem;
}

/* ---------- Footer ---------- */
footer.site {
  background: var(--navy-deep); color: #c6cdec; margin-top: 4rem;
  padding: 3rem 0 2rem; font-size: 0.9rem;
}
footer.site .cols { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; max-width: var(--maxw); margin: 0 auto; padding: 0 1.5rem; }
footer.site h5 { color: #fff; font-size: 0.95rem; margin-bottom: 0.7rem; }
footer.site a { color: #c6cdec; display: block; margin-top: 0.35rem; }
footer.site a:hover { color: var(--amber); }
footer.site .fine { border-top: 1px solid rgba(255,255,255,0.15); margin-top: 2.2rem; padding-top: 1.2rem; text-align: center; color: #8f98c4; font-size: 0.8rem; }

/* ---------- Reveal animation (subtle) ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* ---------- Photo hero (landing) ---------- */
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 3rem; align-items: center; }
.hero-img { position: relative; }
.hero-img img { width: 100%; border-radius: var(--radius); box-shadow: 0 24px 60px rgba(29,36,64,0.18); display: block; }
.hero-img::after {
  content: ""; position: absolute; inset: auto -14px -14px auto; width: 120px; height: 120px;
  background: radial-gradient(circle, rgba(246,164,28,0.35), transparent 70%); z-index: -1;
}

/* Media blocks with real images */
.media img.cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.media img.contain { width: 100%; height: 100%; object-fit: contain; background: #fff; padding: 0.6rem; }
.media.tall { min-height: 340px; }

/* Video embed */
.video-wrap { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: 0 14px 38px rgba(29,36,64,0.12); }
.video-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Full-bleed image band */
.band { position: relative; min-height: 320px; background-size: cover; background-position: center; display: flex; align-items: center; }
.band .scrim { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(26,35,97,0.82) 0%, rgba(26,35,97,0.45) 55%, rgba(26,35,97,0.2) 100%); }
.band .wrap { position: relative; z-index: 1; color: #fff; padding-top: 3rem; padding-bottom: 3rem; }
.band h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -0.015em; }
.band p { color: #dfe5f7; max-width: 40em; margin-top: 0.7rem; }

/* Modal pop-ups */
.tile.clickable { cursor: pointer; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.tile.clickable:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(29,36,64,0.10); }
.tile.clickable .go { margin-top: 0.6rem; font-weight: 600; font-size: 0.85rem; color: var(--navy); }
.tile.clickable .go::after { content: " →"; }
.modal-overlay {
  position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center;
  background: rgba(20,26,54,0.55); backdrop-filter: blur(3px); padding: 1.5rem;
  opacity: 0; pointer-events: none; transition: opacity 0.25s ease;
}
.modal-overlay.open { opacity: 1; pointer-events: auto; }
.modal {
  background: #fff; border-radius: var(--radius); max-width: 680px; width: 100%; max-height: 88vh;
  overflow-y: auto; position: relative; box-shadow: 0 30px 80px rgba(0,0,0,0.3);
  transform: translateY(14px); transition: transform 0.25s ease;
}
.modal-overlay.open .modal { transform: none; }
.modal .modal-img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.modal .modal-img.contain { object-fit: contain; background: var(--bg-tint); }
.modal .modal-body { padding: 1.5rem 1.8rem 1.8rem; }
.modal h3 { font-size: 1.3rem; letter-spacing: -0.01em; }
.modal .tag { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--amber); }
.modal p { color: var(--muted); font-size: 0.95rem; margin-top: 0.7rem; }
.modal ul { margin: 0.7rem 0 0 1.1rem; color: var(--muted); font-size: 0.93rem; }
.modal ul li { margin-top: 0.3rem; }
.modal-close {
  position: absolute; top: 10px; right: 10px; z-index: 2; width: 36px; height: 36px; border-radius: 50%;
  border: 0; background: rgba(255,255,255,0.92); color: var(--ink); font-size: 1.2rem; font-weight: 700;
  cursor: pointer; box-shadow: 0 2px 10px rgba(0,0,0,0.18);
}
.modal-close:hover { background: var(--amber); }
body.modal-open { overflow: hidden; }

/* IP portfolio list */
.ip-list { display: flex; flex-direction: column; gap: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; }
.ip-row { display: grid; grid-template-columns: 56px 1fr auto; gap: 1.1rem; align-items: center; padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--line); transition: background 0.2s ease; }
.ip-row:last-child { border-bottom: 0; }
.ip-row:hover { background: var(--bg-soft); }
.ip-row .ip-ic { width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--bg-tint); color: var(--navy); flex-shrink: 0; }
.ip-row .ip-ic svg { width: 24px; height: 24px; }
.ip-row h4 { font-size: 1rem; font-weight: 700; }
.ip-row p { font-size: 0.88rem; color: var(--muted); margin-top: 0.15rem; }
.ip-status { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; padding: 0.3rem 0.75rem; border-radius: 999px; white-space: nowrap; }
.ip-status.filed { background: #e2f3e7; color: #1e6b38; }
.ip-status.progress { background: var(--amber-soft); color: #7a5205; }
.ip-status.licensed { background: #dfe6f8; color: var(--navy); }
.ip-status.concept { background: #eee7f8; color: #5b3a8e; }
@media (max-width: 700px) { .ip-row { grid-template-columns: 46px 1fr; } .ip-row .ip-status { grid-column: 2; justify-self: start; } }

/* Sitemap */
.sitemap-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2rem; }
.sitemap-cols h4 { color: var(--navy); margin-bottom: 0.6rem; }
.sitemap-cols a { display: block; padding: 0.25rem 0; color: var(--muted); }
.sitemap-cols a:hover { color: var(--navy); }

/* ---------- Responsive ---------- */
/* Collapse nav to hamburger before links can wrap */
@media (max-width: 1240px) {
  nav.links {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: flex-start; padding: 1rem 1.5rem; gap: 0.9rem;
    white-space: normal;
  }
  nav.links.open { display: flex; }
  .menu-btn { display: block; }
}
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
  .brand { font-size: 1.3rem; }
  .brand img { width: 52px; height: 52px; }
  .feature { grid-template-columns: 1fr; gap: 1.6rem; }
  .feature.flip .media { order: 0; }
  .grid-2 { grid-template-columns: 1fr; }
  footer.site .cols { grid-template-columns: 1fr; }
}
