/* ════════════════════════════════════════
   SHARED COMPONENTS
   – aviation hero treatment (photo + tint + flight-path motif)
   – WhatsApp floating button
   – Career-navigator quiz modal
   – photo strips, gallery captions, featured blog card, stat bars
════════════════════════════════════════ */

/* Fallback so content is never hidden when JS is unavailable */
html:not(.js) [data-reveal],
html:not(.js) .hero-reveal, html:not(.js) .journey-reveal, html:not(.js) .fcta-reveal { opacity: 1 !important; transform: none !important; }

:focus-visible { outline: 2px solid #ff7b71; outline-offset: 3px; border-radius: 2px; }

/* ── Aviation hero treatment for inner pages ── */
.pg-hero, .pc-hero, .prog-ov-hero { isolation: isolate; }
.pg-hero::after, .pc-hero::after, .prog-ov-hero::after {
  content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: linear-gradient(135deg, rgba(8,15,58,0.92) 0%, rgba(8,15,58,0.74) 55%, rgba(74,13,143,0.62) 100%);
}
.pc-hero::after {
  background: linear-gradient(100deg, rgba(8,15,58,0.95) 0%, rgba(8,15,58,0.82) 45%, rgba(8,15,58,0.5) 100%);
}
.pg-hero::before, .pc-hero::before, .prog-ov-hero::before {
  content: ''; position: absolute; z-index: 1; pointer-events: none;
  right: 0; bottom: 0; width: min(920px, 96%); aspect-ratio: 900 / 420;
  background: var(--motif, var(--motif-arc)) no-repeat right bottom / contain;
  opacity: 0.55;
}
.pc-hero::before { width: min(760px, 70%); opacity: 0.5; }
.m-arc { --motif: var(--motif-arc); }
.m-runway { --motif: var(--motif-runway); }
.m-globe { --motif: var(--motif-globe); }
.m-tower { --motif: var(--motif-tower); }
.pg-hero-bg, .pc-hero-bg, .prog-ov-hero-bg { z-index: -1; }
.prog-ov-hero-bg { opacity: 1; }
.pg-hero-sub, .pc-subtitle, .prog-ov-sub { text-shadow: 0 1px 12px rgba(8,15,58,0.5); }

/* Breadcrumb links a bit brighter now that the photo shows through */
.pc-breadcrumb, .pc-breadcrumb a { color: rgba(255,255,255,0.6); }

/* ── Section watermark logo (journey / final cta) ── */
.journey-wrap { position: relative; overflow: hidden; }
.journey-wrap::before {
  content: ''; position: absolute; left: 50%; top: 4rem; transform: translateX(-50%);
  width: min(720px, 90vw); aspect-ratio: 600 / 426;
  background: url('../assets/logos/mcas-mark-white.png') no-repeat center / contain;
  opacity: 0.035; pointer-events: none;
}
.journey-inner { position: relative; }

/* ── WhatsApp floating button ── */
.wa-float {
  position: fixed; z-index: 990;
  right: max(18px, env(safe-area-inset-right)); bottom: max(18px, env(safe-area-inset-bottom));
  display: flex; align-items: center; gap: 10px;
  background: #25d366; color: #fff; border-radius: 999px;
  height: 58px; padding: 0 17px;
  box-shadow: 0 8px 28px rgba(37,211,102,0.45), 0 2px 8px rgba(0,0,0,0.25);
  transition: transform 0.2s, background 0.2s;
}
.wa-float:hover { background: #1db954; transform: translateY(-3px); }
.wa-float svg { width: 26px; height: 26px; flex-shrink: 0; }
.wa-float-label {
  font-family: var(--sans); font-size: 13.5px; font-weight: 700; letter-spacing: 0.01em;
  max-width: 0; overflow: hidden; white-space: nowrap; opacity: 0;
  transition: max-width 0.35s var(--ease), opacity 0.25s;
}
.wa-float:hover .wa-float-label, .wa-float:focus-visible .wa-float-label { max-width: 140px; opacity: 1; }
.wa-float::before {
  content: ''; position: absolute; inset: 0; border-radius: inherit;
  border: 2px solid #25d366; animation: waPulse 2.6s ease-out infinite; pointer-events: none;
}
@keyframes waPulse { 0% { transform: scale(1); opacity: 0.7; } 100% { transform: scale(1.5); opacity: 0; } }

/* ── Quiz modal ── */
.quiz-modal {
  position: fixed; inset: 0; z-index: 1500;
  display: none; align-items: center; justify-content: center; padding: 1rem;
  background: rgba(5,10,38,0.82); backdrop-filter: blur(6px);
}
.quiz-modal.open { display: flex; }
.quiz-box {
  position: relative; width: 100%; max-width: 560px; max-height: calc(100dvh - 2rem); overflow-y: auto;
  background: var(--navy-deep); color: var(--white);
  border: 1px solid rgba(255,255,255,0.14); border-radius: 18px; padding: 2.25rem;
  box-shadow: 0 40px 100px rgba(0,0,0,0.6);
}
.quiz-close {
  position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.08); color: var(--white); border: 0; cursor: pointer; font-size: 22px; line-height: 1;
}
.quiz-close:hover { background: rgba(255,255,255,0.16); }
.quiz-progress { display: flex; gap: 6px; margin-bottom: 1.5rem; padding-right: 2.5rem; }
.quiz-progress i { flex: 1; height: 3px; border-radius: 2px; background: rgba(255,255,255,0.15); }
.quiz-progress i.on { background: var(--red); }
.quiz-q { font-family: var(--f-head); font-size: 28px; font-weight: 700; text-transform: uppercase; line-height: 1.1; margin-bottom: 1.25rem; }
.quiz-opts { display: flex; flex-direction: column; gap: 10px; }
.quiz-opt {
  text-align: left; cursor: pointer; font-family: var(--f-body); font-size: 14px; color: var(--white);
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.16); border-radius: 10px;
  padding: 14px 16px; transition: background 0.2s, border-color 0.2s, transform 0.15s;
}
.quiz-opt:hover { background: rgba(232,62,49,0.18); border-color: var(--red); transform: translateX(3px); }
.quiz-back { margin-top: 1.25rem; background: none; border: 0; color: rgba(255,255,255,0.55); font-size: 12.5px; cursor: pointer; padding: 6px 0; }
.quiz-back:hover { color: var(--white); }
.quiz-result-tag { font-family: var(--mono); font-size: 10.5px; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: #ff7b71; margin-bottom: 0.75rem; }
.quiz-result-title { font-family: var(--f-display); font-size: 28px; font-weight: 800; line-height: 1.15; margin-bottom: 0.75rem; }
.quiz-result-body { font-size: 14px; font-weight: 300; line-height: 1.75; color: rgba(255,255,255,0.7); margin-bottom: 1.5rem; }
.quiz-result-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.quiz-result-btns a {
  display: inline-flex; align-items: center; gap: 8px; padding: 13px 22px; border-radius: 6px;
  font-size: 12.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
}
.quiz-result-btns .q-primary { background: var(--red); color: var(--white); }
.quiz-result-btns .q-wa { background: #25d366; color: var(--white); }
.hero-quiz-btn { border: 0; cursor: pointer; font-family: inherit; }

/* ── Photo strip (about page) ── */
.photo-strip { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 14px; }
.photo-strip figure { position: relative; border-radius: 16px; overflow: hidden; background: var(--navy-dark); min-height: 300px; }
.photo-strip img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--r); }
.photo-strip figure:hover img { transform: scale(1.05); }
.photo-strip figcaption, .gallery-item figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 2.5rem 1.1rem 0.9rem;
  background: linear-gradient(to top, rgba(8,15,56,0.9), transparent);
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.1em; color: rgba(255,255,255,0.85);
}
.gallery-grid.single { grid-template-rows: 220px; }
.gallery-item figcaption { transform: translateY(100%); transition: transform 0.35s var(--ease); }
.gallery-item:hover figcaption, .gallery-item:focus-within figcaption { transform: none; }

/* ── Featured news card ── */
.blog-card.featured { grid-column: 1 / -1; display: grid; grid-template-columns: 1.15fr 1fr; }
.blog-card.featured .blog-img { height: 100%; min-height: 320px; }
.blog-card.featured .blog-body { padding: 2.5rem; display: flex; flex-direction: column; justify-content: center; }
.blog-card.featured .blog-title { font-size: 28px; }
.blog-tag-new {
  display: inline-block; background: var(--red); color: var(--white); border-radius: 20px; padding: 3px 10px; margin-left: 8px;
  font-size: 9px; letter-spacing: 0.14em;
}

/* ── Stat bars (were inline styles) ── */
.statbar { background: var(--red); padding: 1.5rem 4rem; }
.statbar-in { max-width: 1200px; margin: 0 auto; display: flex; justify-content: space-around; flex-wrap: wrap; gap: 1rem; }

/* ── EightD partnership gallery (news / life) ── */
.mou-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.mou-grid figure { position: relative; border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--navy-dark); }
.mou-grid figure:first-child { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
.mou-grid img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--r); }
.mou-grid figure:hover img { transform: scale(1.05); }
:root {
  --motif-arc: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 900 420' fill='none' stroke='white' stroke-width='2'><path d='M30 380 C260 40 620 10 830 110' stroke-dasharray='3 11' stroke-linecap='round' opacity='.6'/><path d='M100 410 C340 160 650 100 885 205' stroke-dasharray='2 10' stroke-linecap='round' opacity='.28'/><circle cx='30' cy='380' r='7' fill='white' stroke='none' opacity='.55'/><g transform='translate(800 82) rotate(24) scale(1.5)' fill='white' stroke='none' opacity='.8'><path d='M0 20 Q2 17 8 17 L26 17 L14 4 L19 4 L38 17 L40 18 Q42 20 40 22 L38 23 L19 36 L14 36 L26 23 L8 23 Q2 23 0 20 Z'/></g></svg>");
  --motif-runway: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 900 420' fill='none' stroke='white' stroke-width='2'><path d='M40 420 L425 80 M860 420 L475 80' opacity='.5'/><path d='M450 420 L450 90' stroke-dasharray='22 20' opacity='.45'/><path d='M170 330 H730 M270 240 H630 M345 170 H555' opacity='.22'/><g transform='translate(424 8) rotate(-90 20 20) scale(1.1)' fill='white' stroke='none' opacity='.8'><path d='M0 20 Q2 17 8 17 L26 17 L14 4 L19 4 L38 17 L40 18 Q42 20 40 22 L38 23 L19 36 L14 36 L26 23 L8 23 Q2 23 0 20 Z'/></g></svg>");
  --motif-globe: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 900 420' fill='none' stroke='white' stroke-width='2'><circle cx='450' cy='220' r='190' opacity='.45'/><ellipse cx='450' cy='220' rx='75' ry='190' opacity='.3'/><ellipse cx='450' cy='220' rx='150' ry='190' opacity='.2'/><path d='M260 220 H640 M285 140 H615 M285 300 H615' opacity='.25'/><path d='M180 330 C300 120 520 60 740 150' stroke-dasharray='3 11' stroke-linecap='round' opacity='.7'/><g transform='translate(712 128) rotate(22) scale(1.3)' fill='white' stroke='none' opacity='.85'><path d='M0 20 Q2 17 8 17 L26 17 L14 4 L19 4 L38 17 L40 18 Q42 20 40 22 L38 23 L19 36 L14 36 L26 23 L8 23 Q2 23 0 20 Z'/></g></svg>");
  --motif-tower: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 900 420' fill='none' stroke='white' stroke-width='2'><path d='M0 385 H900' opacity='.4'/><path d='M560 385 V190 L548 190 L548 160 L616 160 L616 190 L604 190 V385' opacity='.55'/><path d='M540 160 L560 135 H604 L624 160' opacity='.55'/><path d='M582 135 V105' opacity='.55'/><path d='M60 300 C250 250 420 210 520 110' stroke-dasharray='3 11' stroke-linecap='round' opacity='.5'/><g transform='translate(160 90) rotate(-8) scale(1.4)' fill='white' stroke='none' opacity='.75'><path d='M0 20 Q2 17 8 17 L26 17 L14 4 L19 4 L38 17 L40 18 Q42 20 40 22 L38 23 L19 36 L14 36 L26 23 L8 23 Q2 23 0 20 Z'/></g><path d='M60 95 H150' stroke-dasharray='2 9' opacity='.3'/></svg>");
}
