/* Sitewide header: utility bar, sticky main bar, mega menus, mobile drawer. */
:root { --ph-h: 78px; --ph-navy: #07182f; --ph-ink: #0b1b30; --ph-muted: #5a6b80; --ph-line: #e1e8ef; --ph-soft: #f4f8fb; --ph-blue: #0878d1; --ph-orange: #f36b21; }

.ph-icon { width: 20px; height: 20px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ph-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Utility bar */
.ph-top { background: #04101f; color: #b9cadb; font-size: .8rem; }
.ph-top-in { width: min(calc(100% - 40px), 1240px); min-height: 38px; margin-inline: auto; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.ph-top p { display: flex; align-items: center; gap: 8px; margin: 0; }
.ph-top .ph-icon { width: 15px; height: 15px; color: #ff9b5e; }
.ph-top-links { display: flex; align-items: center; gap: 22px; }
.ph-top a { display: inline-flex; align-items: center; gap: 7px; color: #e6eef6; font-weight: 700; text-decoration: none; }
.ph-top a:hover { color: #fff; text-decoration: underline; }
.ph-top .ph-badge { padding: 3px 9px; border-radius: 999px; background: rgba(243,107,33,.16); color: #ffb27f; }

/* Main bar */
.ph-header { position: sticky; top: 0; z-index: 1000; background: rgba(255,255,255,.98); border-bottom: 1px solid var(--ph-line); transition: box-shadow .2s ease; }
.ph-header.is-scrolled { box-shadow: 0 10px 30px rgba(6,20,38,.08); }
.ph-bar { width: min(calc(100% - 40px), 1240px); height: var(--ph-h); margin-inline: auto; display: flex; align-items: center; gap: 28px; }
.ph-logo { display: inline-flex; align-items: center; gap: 11px; color: var(--ph-ink); text-decoration: none; flex: 0 0 auto; }
.ph-logo img { width: 42px; height: 42px; object-fit: contain; }
.ph-logo strong { display: block; font: 800 1.02rem/1.1 "Avenir Next", Inter, system-ui, sans-serif; letter-spacing: -.02em; }
.ph-logo small { display: block; margin-top: 4px; color: #6a7a8e; font-size: .66rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }

.ph-nav { margin-left: auto; }
.ph-menu { display: flex; align-items: center; gap: 2px; margin: 0; padding: 0; list-style: none; }
.ph-menu > li { position: static; }
.ph-trigger, .ph-link { height: 44px; display: inline-flex; align-items: center; gap: 6px; padding: 0 13px; border: 0; border-radius: 9px; background: none; color: #22364d; font: 750 .9rem/1 Inter, system-ui, sans-serif; text-decoration: none; cursor: pointer; white-space: nowrap; }
.ph-trigger .ph-icon { width: 16px; height: 16px; transition: transform .2s ease; }
.ph-trigger:hover, .ph-link:hover, .is-open > .ph-trigger { color: var(--ph-blue); background: #eef6fd; }
.is-open > .ph-trigger .ph-icon { transform: rotate(180deg); }
.ph-link[aria-current="page"], .ph-trigger.is-current { color: var(--ph-blue); box-shadow: inset 0 -2px 0 var(--ph-blue); border-radius: 0; }

.ph-actions { display: flex; align-items: center; gap: 10px; }
.ph-cta { min-height: 46px; display: inline-flex; align-items: center; gap: 8px; padding: 0 18px; border-radius: 11px; background: var(--ph-orange); color: #fff; font: 850 .88rem/1 Inter, system-ui, sans-serif; text-decoration: none; box-shadow: 0 10px 24px rgba(243,107,33,.25); transition: background .18s ease, transform .18s ease; }
.ph-cta:hover { background: #dc5512; transform: translateY(-1px); }
.ph-cta .ph-icon { width: 17px; height: 17px; }
.ph-burger { display: none; width: 46px; height: 46px; place-items: center; border: 1px solid var(--ph-line); border-radius: 11px; background: #fff; color: var(--ph-ink); cursor: pointer; }
.ph-burger .ph-close { display: none; }
.ph-burger[aria-expanded="true"] .ph-open { display: none; }
.ph-burger[aria-expanded="true"] .ph-close { display: block; }

/* Mega panels */
.ph-panel { position: absolute; left: 0; right: 0; top: 100%; border-top: 1px solid var(--ph-line); background: #fff; box-shadow: 0 30px 60px rgba(6,20,38,.14); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .18s ease, transform .18s ease, visibility .18s; }
.is-open > .ph-panel { opacity: 1; visibility: visible; transform: none; }
.ph-mega { width: min(calc(100% - 40px), 1240px); margin-inline: auto; padding: 30px 0; display: grid; grid-template-columns: repeat(3, 1fr) 300px; gap: 28px; }
.ph-mega.cols-2 { grid-template-columns: repeat(2, 1fr) 300px; }
.ph-col h3 { margin: 0 0 10px; padding: 0 12px; color: #7b8899; font: 900 .7rem/1 Inter, system-ui, sans-serif; letter-spacing: .14em; text-transform: uppercase; }
.ph-col ul { margin: 0; padding: 0; list-style: none; }
.ph-item { display: flex; gap: 13px; padding: 11px 12px; border-radius: 12px; color: var(--ph-ink); text-decoration: none; transition: background .15s ease; }
.ph-item:hover, .ph-item:focus-visible { background: var(--ph-soft); }
.ph-item > .ph-icon { width: 38px; height: 38px; padding: 9px; border-radius: 10px; background: #edf5fc; color: var(--ph-blue); }
.ph-item:hover > .ph-icon { background: var(--ph-blue); color: #fff; }
.ph-item strong { display: block; font-size: .92rem; line-height: 1.3; }
.ph-item small { display: block; margin-top: 2px; color: var(--ph-muted); font-size: .8rem; line-height: 1.4; }
.ph-chips { display: flex; flex-wrap: wrap; gap: 7px; padding: 4px 12px; }
.ph-chips a { padding: 7px 12px; border: 1px solid var(--ph-line); border-radius: 999px; color: #2b405a; font-size: .82rem; font-weight: 750; text-decoration: none; }
.ph-chips a:hover { border-color: var(--ph-blue); color: var(--ph-blue); }
.ph-feature { display: flex; flex-direction: column; padding: 24px; border-radius: 18px; color: #fff; background: radial-gradient(circle at 85% 10%, rgba(21,148,232,.4), transparent 45%), linear-gradient(150deg, #07182f, #0c3a63); }
.ph-feature span { color: #ffb27f; font-size: .7rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; }
.ph-feature strong { margin: 10px 0 8px; font: 800 1.2rem/1.25 "Avenir Next", Inter, sans-serif; }
.ph-feature p { margin: 0 0 18px; color: #c4d4e3; font-size: .86rem; line-height: 1.5; }
.ph-feature ul { margin: 0 0 18px; padding: 0; list-style: none; color: #dbe7f2; font-size: .82rem; }
.ph-feature li { padding: 4px 0; }
.ph-feature li::before { content: "✓"; margin-right: 8px; color: #6be3aa; font-weight: 900; }
.ph-feature a { margin-top: auto; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border-radius: 10px; background: var(--ph-orange); color: #fff; font-weight: 850; font-size: .86rem; text-decoration: none; }
.ph-feature a:hover { background: #dc5512; }
.ph-panel-foot { border-top: 1px solid var(--ph-line); background: var(--ph-soft); }
.ph-panel-foot div { width: min(calc(100% - 40px), 1240px); margin-inline: auto; min-height: 52px; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: var(--ph-muted); font-size: .84rem; }
.ph-panel-foot a { display: inline-flex; align-items: center; gap: 6px; color: var(--ph-blue); font-weight: 850; text-decoration: none; }
.ph-panel-foot .ph-icon { width: 16px; height: 16px; }
.ph-drawer-foot { display: none; }

.ph-header :focus-visible { outline: 3px solid #ffb27f; outline-offset: 2px; }

@media (max-width: 1180px) {
  .ph-mega { grid-template-columns: repeat(3, 1fr); }
  .ph-mega.cols-2 { grid-template-columns: repeat(2, 1fr); }
  .ph-feature { display: none; }
}

/* Mobile drawer */
@media (max-width: 1180px) {
  :root { --ph-h: 68px; }
  .ph-top-links .ph-hide-sm { display: none; }
  .ph-burger { display: grid; }
  .ph-nav { position: fixed; z-index: 999; top: var(--ph-top, var(--ph-h)); left: 0; right: 0; bottom: 0; margin: 0; overflow-y: auto; background: #fff; transform: translateX(100%); visibility: hidden; transition: transform .25s ease, visibility .25s; }
  .ph-nav.is-open { transform: none; visibility: visible; }
  .ph-menu { flex-direction: column; align-items: stretch; gap: 0; padding: 8px 20px; }
  .ph-menu > li { border-bottom: 1px solid var(--ph-line); }
  .ph-trigger, .ph-link { width: 100%; height: 58px; justify-content: space-between; padding: 0 4px; border-radius: 0; font-size: 1.02rem; }
  .ph-trigger:hover, .ph-link:hover, .is-open > .ph-trigger { background: none; }
  .ph-link[aria-current="page"] { box-shadow: none; }
  .ph-panel { position: static; display: none; border: 0; box-shadow: none; opacity: 1; visibility: visible; transform: none; transition: none; }
  .is-open > .ph-panel { display: block; }
  .ph-mega, .ph-mega.cols-2 { width: 100%; grid-template-columns: 1fr; gap: 18px; padding: 4px 0 18px; }
  .ph-item { padding: 9px 4px; }
  .ph-chips { padding: 4px; }
  .ph-panel-foot { background: none; border: 0; }
  .ph-panel-foot div { width: 100%; padding: 0 4px 18px; min-height: 0; }
  .ph-panel-foot span { display: none; }
  .ph-drawer-foot { display: grid; gap: 10px; padding: 20px; }
  .ph-drawer-foot a { min-height: 50px; display: flex; align-items: center; justify-content: center; gap: 8px; border-radius: 11px; font-weight: 850; text-decoration: none; }
  .ph-drawer-foot .ph-cta { box-shadow: none; }
  .ph-drawer-foot .ph-ghost { border: 1px solid var(--ph-line); color: var(--ph-ink); }
  body.ph-lock { overflow: hidden; }
  body.ph-lock .mobile-cta { display: none; }
}
@media (max-width: 560px) {
  .ph-top-in, .ph-bar { width: calc(100% - 32px); }
  .ph-top-in { justify-content: center; }
  .ph-top p { display: none; }
  .ph-bar { gap: 12px; }
  .ph-actions .ph-cta { padding: 0 13px; font-size: .82rem; }
  .ph-actions .ph-cta .ph-icon, .ph-logo small { display: none; }
}
@media (max-width: 380px) { .ph-actions .ph-cta { display: none; } }
@media (prefers-reduced-motion: reduce) { .ph-header *, .ph-nav { transition: none !important; } }
