/* ==========================================================
   Medcule — Mobile & layout-stability refinements
   Loaded last on every page.
   ========================================================== */

/* ---------- Global stability (all screen sizes) ---------- */
html { overflow-x: clip; }
.hero-grid > * { min-width: 0; }
[data-count], .stat .num, .big, .badge-card .big { font-variant-numeric: tabular-nums; }

/* Panels that swap content keep the height of the tallest one → no page jumping */
.lc-panel { display: grid; }
.lc-pane { display: grid !important; grid-area: 1 / 1; visibility: hidden; opacity: 0; animation: none; }
.lc-pane.active { visibility: visible; opacity: 1; animation: fadeUp .55s var(--ease); }
.ax-panes { display: grid; }
.ax-pane { display: block !important; grid-area: 1 / 1; visibility: hidden; opacity: 0; min-height: 0; animation: none; }
.ax-pane.active { visibility: visible; opacity: 1; animation: fadeUp .5s var(--ease); }

/* Mobile menu extras (hidden on desktop) */
.nav-extra { display: none; }
.nav-overlay { display: none; }

/* ==========================================================
   Tablet & phone (≤ 960px)
   ========================================================== */
@media (max-width: 960px) {
  /* Side-sliding reveals cause sideways jitter on phones → slide up instead */
  .reveal.left:not(.in), .reveal.right:not(.in) { transform: translateY(30px); }

  /* Off-canvas menu */
  .nav-overlay { display: block; position: fixed; inset: 0; z-index: 98; background: rgba(4, 26, 56, .45); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); opacity: 0; pointer-events: none; transition: opacity .35s; }
  .nav-overlay.show { opacity: 1; pointer-events: auto; }
  body.menu-open { overflow: hidden; }
  .nav-links { padding: 96px 22px 28px; overflow-y: auto; height: 100dvh; }
  .nav-links a:not(.btn) { border-radius: 12px; }
  .nav-cta { justify-content: center; }
  .nav-extra { display: grid; gap: 4px; margin-top: auto; padding-top: 22px; border-top: 1px solid var(--line); }
  .nav-extra > a { display: flex !important; align-items: center; gap: 10px; padding: 10px 6px !important; font-size: .9rem !important; font-weight: 500 !important; color: var(--text) !important; font-family: var(--font-body) !important; }
  .nav-extra > a svg { width: 17px; height: 17px; color: var(--green); }
  .nav-social { display: flex; gap: 10px; padding: 10px 6px 0; }
  .nav-social a { width: 40px; height: 40px; padding: 0 !important; border-radius: 50% !important; display: grid !important; place-items: center; background: var(--bg-soft); color: var(--navy) !important; }
  .nav-social a::after { display: none; }
  .nav-social svg { width: 16px; height: 16px; }
  .nav-links a.active::after { display: none; }
  .nav-links a.active:not(.btn) { background: var(--bg-mint); }
}

/* ==========================================================
   Phones (≤ 640px)
   ========================================================== */
@media (max-width: 640px) {
  body { font-size: 15.5px; }
  .section { padding: 60px 0; }
  .section-head { margin-bottom: 34px; }
  .section-head p { font-size: 1rem; color: var(--muted); margin-top: 12px; }
  h2 { font-size: 2.15rem; line-height: 1.12; letter-spacing: -.025em; font-weight: 800; }
  .eyebrow { font-size: .7rem; letter-spacing: .12em; padding: 6px 12px; margin-bottom: 14px; }
  .btn { padding: 14px 22px; font-size: .92rem; }
  .split { gap: 44px; }

  /* Header */
  .nav { height: 70px; }
  .brand img { height: 38px; }
  .burger { width: 44px; height: 44px; }
  .burger span:nth-child(1) { top: 15px; } .burger span:nth-child(2) { top: 21px; } .burger span:nth-child(3) { top: 27px; }

  /* ---------- HOME HERO ---------- */
  .hero-x { padding: 34px 0 96px; text-align: left; }
  .hero-x .hero-grid { gap: 0; }
  .hero-x .eyebrow { font-size: .64rem; letter-spacing: .1em; }
  .hero-x h1 { font-size: 2.6rem; line-height: 1.1; letter-spacing: -.025em; margin-bottom: 18px; }
  .rotator { height: 1.24em; }

  .hero-lead { font-size: 1rem; line-height: 1.65; margin: 0 0 26px; }
  .hero-x .hero-actions { display: flex; }
  .hero-x .hero-actions .btn { padding: 14px 10px; font-size: .88rem; }
  .hero-badges { justify-content: flex-start; gap: 6px; margin-top: 20px; }
  .hero-badges span { font-size: .72rem; padding: 6px 10px; gap: 5px; }
  .hero-badges svg { width: 13px; height: 13px; }

  .hv { max-width: 330px; margin: 34px auto 0; }
  .hv-glow { filter: blur(40px); }
  .hv-core { inset: 25%; }
  .px-1, .px-2, .px-4 { display: none; }
  .px-3 { left: 0; right: 0; bottom: -2%; display: flex; justify-content: center; transform: none !important; }
  .px-3 .glass { padding: 9px 14px 9px 9px; }
  .px-3 .glass small { display: block; font-size: .7rem; }
  .px-3 .ring-prog { width: 42px; height: 42px; }
  .hv-node { width: 40px; height: 40px; margin: -20px 0 0 -20px; }
  .hv-node-in svg { width: 18px; height: 18px; }
  .hv-node-in::after { display: none; }

  /* Stats strip */
  .stats { margin-top: -60px; }
  .stats-card { padding: 22px 8px; row-gap: 22px; border-radius: 22px; }
  .stat { padding: 4px 8px; }
  .stat .st-ic { width: 38px; height: 38px; margin-bottom: 10px; border-radius: 11px; }
  .stat .st-ic svg { width: 18px; height: 18px; }
  .stat .num { font-size: 1.75rem; }
  .stat p { font-size: .8rem; margin-top: 6px; line-height: 1.35; }


  /* Home services cards */
  .svc-card { padding: 26px 22px 24px; border-radius: 22px; transform: none !important; }
  .svc-top { margin-bottom: 18px; }
  .svc-ic { width: 54px; height: 54px; border-radius: 15px; }
  .svc-ic svg { width: 26px; height: 26px; }
  .svc-num { font-size: 2.8rem; }
  .svc-card h3 { font-size: 1.3rem; }
  .svc-card p { font-size: .92rem; }
  .svc-tags { margin: 14px 0 20px; }
  .svc-foot { margin-top: 26px; flex-direction: column; gap: 12px; text-align: center; }

  /* Who we are */
  .ax-visual { height: 370px; gap: 10px; grid-template-columns: 1.15fr 1fr; }
  .ax-main { border-radius: 22px; }
  .dna { gap: 9px; }
  .dna span { width: 96px; }
  .dna span::before, .dna span::after { width: 11px; height: 11px; margin-top: -5.5px; }
  .dna span::before { left: -5px; } .dna span::after { right: -5px; }
  .ax-cap { display: none; }
  .ax-cap strong { font-size: .9rem; }
  .ax-cap small { font-size: .72rem; }
  .ax-tile { padding: 14px; border-radius: 18px; }
  .ax-tile .t-k { font-size: .6rem; letter-spacing: .1em; }
  .ax-tile h4 { font-size: .9rem; max-width: 100%; }
  .ax-flask svg.flask { width: 54px; height: 66px; right: 8px; bottom: 6px; }
  .ax-learn .big { font-size: 1.45rem; }
  .ax-learn small { font-size: .7rem; }
  .mini-bars { height: 38px; left: 14px; right: 14px; bottom: 12px; gap: 5px; }
  .rot-badge { width: 80px; height: 80px; left: 53.5%; }
  .rot-badge .core { width: 34px; height: 34px; }
  .rot-badge .core svg { width: 17px; height: 17px; }
  .ax-exp { left: 6px; bottom: -16px; padding: 10px 14px; border-radius: 14px; gap: 8px; }
  .ax-exp .big { font-size: 1.4rem; }
  .ax-exp small { font-size: .68rem; max-width: 88px; }
  .ax-chip { left: 6px; top: -16px; font-size: .7rem; padding: 7px 12px; }
  .ax .split > .reveal.right { margin-top: 8px; }
  .ax-tabs { display: flex; width: 100%; margin: 22px 0 18px; }
  .ax-tabs button { flex: 1; padding: 10px 4px; font-size: .8rem; white-space: nowrap; }
  .promise-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .promise-grid div { padding: 14px 8px; }
  .promise-grid .icon-box { width: 38px; height: 38px; }
  .promise-grid strong { font-size: .84rem; }
  .promise-grid small { font-size: .7rem; line-height: 1.3; display: block; }
  .bar-row { margin-bottom: 14px; }
  .bar-row .lbl { font-size: .86rem; }
  .ax-actions { gap: 16px; margin-top: 24px; }

  .lc-panel { border-radius: 22px; }
  .lc-pane { padding: 24px 20px; gap: 20px; }
  .lc-pane .big-n { font-size: 2.6rem; }
  .lc-pane h3 { font-size: 1.3rem; }
  .lc-doms a { padding: 12px; gap: 12px; }
  .lc-doms .di { width: 38px; height: 38px; }
  .lc-doms strong { font-size: .9rem; }
  .lc-doms span { font-size: .78rem; }

  /* Bento: compact 2-column */
  .bento { grid-template-columns: 1fr 1fr; gap: 12px; grid-auto-rows: auto; }
  .b-big, .b-wide, .b-green { grid-column: span 2 !important; grid-row: auto !important; }
  .bento > div { padding: 20px; border-radius: 20px; }
  .bento .icon-box { width: 44px; height: 44px; border-radius: 12px; }
  .bento .icon-box svg { width: 22px; height: 22px; }
  .bento > div:not(.b-big):not(.b-wide):not(.b-green) h3 { font-size: .96rem; margin: 12px 0 6px; }
  .bento > div:not(.b-big):not(.b-wide):not(.b-green) p { font-size: .82rem; line-height: 1.5; }
  .b-big h3 { font-size: 1.45rem; }
  .b-big p { font-size: .92rem; }
  .b-big .b-stats { margin-top: 22px; }
  .b-green { gap: 16px; }
  .b-green .btn { width: 100%; }
  .agency-row span { padding: 6px 11px; font-size: .76rem; }

  /* Internship spotlight */
  .intern-x { text-align: left; }
  .intern-x .perks-inline { gap: 8px; margin: 20px 0 24px; }
  .intern-x .perks-inline span { font-size: .78rem; padding: 7px 12px; }
  .intern-x .hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .intern-x .hero-actions .btn { padding: 14px 10px; }
  .dom-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .dom-card { flex-direction: column; align-items: flex-start; padding: 16px; gap: 10px; }
  .dom-card > svg { display: none; }
  .dom-card .di { width: 40px; height: 40px; }
  .dom-card strong { font-size: .88rem; line-height: 1.3; }
  .dom-card small { font-size: .72rem; }

  /* Blog cards */
  .blog-head { margin-bottom: 30px; }
  .blog-head { flex-direction: column; align-items: flex-start; gap: 18px; }
  .blog-head .btn { padding: 11px 18px; font-size: .86rem; }
  .post-body { padding: 20px 20px 22px; }
  .post-body h3 { font-size: 1.06rem; }

  /* ---------- Inner page hero ---------- */
  .page-hero { padding: 50px 0 96px; }
  .page-hero h1 { font-size: 2.45rem; line-height: 1.1; letter-spacing: -.025em; font-weight: 800; }
  .page-hero p { font-size: 1rem; }
  .page-hero .hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .page-hero .hero-actions .btn { padding: 14px 10px; }
  .wave { height: 40px; }

  /* Process steps: 2 × 2 */
  .steps { grid-template-columns: 1fr 1fr; gap: 28px 14px; }
  .step-circle { width: 60px; height: 60px; font-size: 1.1rem; margin-bottom: 14px; }
  .step h3 { font-size: .98rem; }
  .step p { font-size: .84rem; line-height: 1.5; }

  /* Generic cards */
  .card { padding: 24px 22px; }
  .perk { padding: 20px; gap: 14px; }
  .perk .icon-box { width: 46px; height: 46px; }
  .mvv-card { padding: 30px 26px; }

  /* About: stats + team */
  .grid.g-4:has(.team-card) { grid-template-columns: 1fr 1fr; gap: 14px; }
  .team-photo .initials { font-size: 2rem; }
  .team-body { padding: 14px 10px 16px; }
  .team-body h3 { font-size: .95rem; }
  .team-body small { font-size: .76rem; }
  .team-social { opacity: 1; transform: translate(-50%, 0); bottom: 10px; }
  .team-social a { width: 30px; height: 30px; }
  .tl-card { padding: 22px; }
  .badge-card { padding: 14px 18px; bottom: -22px; right: 10px; }
  .badge-card .big { font-size: 1.7rem; }

  /* Services page */
  #overview { grid-template-columns: 1fr 1fr; gap: 12px; }
  #overview .card { padding: 18px 16px; }
  #overview .card p, #overview .card-num, #overview .card-link { display: none; }
  #overview .icon-box { width: 46px; height: 46px; margin-bottom: 12px; border-radius: 12px; }
  #overview .icon-box svg { width: 22px; height: 22px; }
  #overview h3 { font-size: .92rem; margin: 0; }
  .panel-head h3 { font-size: 1.45rem; }
  .panel-head .ph-ic svg { width: 110px; height: 110px; }
  .panel-body .btn { width: 100%; white-space: normal; text-align: center; }

  /* Internship page */
  .program-top { padding: 24px 22px 20px; }
  .program-body { padding: 20px 22px 24px; }
  .toggle { width: 100%; display: flex; }
  .toggle button { flex: 1; padding: 10px 6px; }
  .split .grid.g-2 { grid-template-columns: 1fr 1fr; gap: 12px; }
  .split .grid.g-2 .card { padding: 18px 12px; }
  .split .grid.g-2 h3 { font-size: 1.3rem; }
  .split .grid.g-2 p { font-size: .82rem; }

  /* Contact page */
  section.stats .grid.g-4 { grid-template-columns: 1fr 1fr; gap: 12px; }
  section.stats .grid.g-4 .card { padding: 18px 12px; }
  section.stats .grid.g-4 .icon-box { width: 44px; height: 44px; margin-bottom: 10px; }
  section.stats .grid.g-4 h3 { font-size: .92rem; margin-bottom: 4px; }
  section.stats .grid.g-4 p { font-size: .76rem; overflow-wrap: normal; }
  .info-card { padding: 18px; gap: 14px; }
  .info-card:hover { transform: none; }
  .form-card { padding: 26px 18px; border-radius: 22px; }
  .form-card h2 { font-size: 1.45rem; }
  .map-wrap { height: 300px; }
  .hours { padding: 22px; }

  /* FAQ, testimonials, CTA */
  .faq-q { padding: 18px; font-size: .96rem; }
  .faq-a p { padding: 0 18px 20px; font-size: .93rem; }
  .testi-card { padding: 30px 20px; }
  .cta { padding: 34px 24px; text-align: left; }
  .cta-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .cta-actions .btn { width: 100%; }

  /* Footer: links side by side */
  .footer { padding-top: 56px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 34px 20px; }
  .footer-grid > div:first-child, .footer-grid > div:last-child { grid-column: 1 / -1; }
  .footer h4 { margin-bottom: 16px; }
  .footer ul { gap: 10px; }
  .footer ul a { font-size: .9rem; }
  .footer-bottom { margin-top: 40px; flex-direction: column; align-items: center; text-align: center; gap: 10px; }
  .to-top { right: 16px; bottom: 16px; width: 46px; height: 46px; }

  /* Blog article */
  .article-hero h1 { font-size: 2.05rem; }
  .article-meta { gap: 14px; font-size: .84rem; }
  .article-cover { margin-top: -80px; border-radius: 20px; }
  .article-wrap { margin-top: 36px; gap: 36px; }
  .prose h2 { font-size: 1.3rem; margin: 30px 0 12px; }
  .newsletter-box { padding: 28px 22px; border-radius: 22px; }
}

/* Very small phones (≤ 360px) */
@media (max-width: 360px) {
  .hero-x h1 { font-size: 2.3rem; }
  .hero-x .hero-actions, .intern-x .hero-actions, .page-hero .hero-actions { grid-template-columns: 1fr; }
  .promise-grid small { display: none; }
  .ax-tabs button { font-size: .74rem; }
}

/* ==========================================================
   Phones: simple static layout — no sliding, no auto-rotating content
   ========================================================== */
@media (max-width: 640px) {
  /* Fade in only (no movement) */
  .reveal:not(.in), .reveal.left:not(.in), .reveal.right:not(.in), .reveal.zoom:not(.in) { transform: none !important; }

  /* Scrolling keyword strip removed on phones */
  .ticker { display: none; }

  /* Lifecycle: all 5 stages listed one below another */
  .lc-intro { display: none; }
  .lc-track, .lc-timer { display: none !important; }
  .lc-panel { display: grid; gap: 14px; background: none; border: 0; box-shadow: none; border-radius: 0; overflow: visible; }
  .lc-pane { grid-area: auto !important; visibility: visible !important; opacity: 1 !important; animation: none !important;
    background: linear-gradient(135deg, #ffffff, #eef6fe); border: 1px solid rgba(30,136,229,.16); border-radius: 20px; padding: 22px 18px !important; gap: 16px !important; }
  .lc-pane .big-n { font-size: 2rem; }
  .lc-pane h3 { font-size: 1.15rem; margin: 4px 0 8px; }
  .lc-pane p { font-size: .9rem; }
  .lc-pane h5 { margin-bottom: 10px; }
  .lc-doms { gap: 8px; }
  .lc-doms a:hover { transform: none; }
  .lc-doms span { display: none; }

  /* Testimonials: stacked, no slider */
  .testi-slides { display: grid; gap: 14px; transform: none !important; }
  .testi { min-width: 0; padding: 0; }
  .testi-nav { display: none; }
  .testi-card { padding: 26px 20px; }
  .testi-card .quote { width: 36px; height: 36px; margin-bottom: 8px; }
  .testi-card p { font-size: .96rem; margin-bottom: 16px; }

  /* Services page tabs: simple 2-column buttons instead of a sideways-scrolling row */
  .tab-list { display: grid !important; grid-template-columns: 1fr 1fr; overflow: visible !important; gap: 8px; padding: 0 !important; }
  .tab-btn { width: 100% !important; justify-content: center; text-align: center; padding: 12px 8px !important; font-size: .82rem !important; min-height: 48px; }
  .tab-btn .tb-ic { display: none; }

  /* Consistent card alignment */
  .svc-card, .post-card, .program { width: 100%; }
}

/* ==========================================================
   Typography hierarchy (all sizes): balanced headline wrapping
   ========================================================== */
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }

/* Phones: clear type scale — H1 ≈ 42px · H2 ≈ 34px · H3 ≈ 19–21px · body 15.5px */
@media (max-width: 640px) {
  .hero-x h1 { font-weight: 800; }
  h3 { font-size: 1.2rem; letter-spacing: -.01em; }
  .card h3, .perk h3, .program-top h3, .post-body h3, .lc-pane h3, .tl-card h3 { font-size: 1.2rem; }
  .mvv-card h3 { font-size: 1.4rem; }
  .step h3 { font-size: 1.02rem; }
  .bento > div:not(.b-big):not(.b-wide):not(.b-green) h3 { font-size: 1.02rem; }
  .b-big h3 { font-size: 1.6rem; line-height: 1.15; }
  .form-card h2, .newsletter-box h2 { font-size: 1.6rem; }
  .cta h2 { font-size: 1.75rem; }
  .panel-head h3 { font-size: 1.6rem; }
  .section-head { margin-bottom: 30px; }
  .eyebrow + h2, .eyebrow + h1 { margin-top: 2px; }
  /* Body copy that follows a section heading */
  .split p, .ax p, .intern-x p { font-size: 1rem; line-height: 1.7; }
}
@media (max-width: 360px) {
  h2 { font-size: 1.9rem; }
  .page-hero h1 { font-size: 2.15rem; }
}
@media (max-width: 640px) {
  #overview .card { padding: 16px 12px; }
  #overview h3 { font-size: .86rem; line-height: 1.3; hyphens: auto; -webkit-hyphens: auto; overflow-wrap: break-word; }
}

/* ==========================================================
   Phones: strong heading / body differentiation
   Size + weight + colour contrast + accent bar + breathing room
   ========================================================== */
@media (max-width: 640px) {
  :root { --head-ink: #071a3d; --body-ink: #5b6b82; }

  /* Headings: darkest navy, heaviest weight, larger */
  h1, h2, h3, h4 { color: var(--head-ink); }
  h2 { font-size: 2.3rem; line-height: 1.1; font-weight: 800; letter-spacing: -.03em; margin-bottom: 0; }
  .section-head h2, .split h2, .ax h2, .blog-head h2 { position: relative; padding-bottom: 18px; margin-bottom: 18px; }

  /* Accent bar under section headings — a clear visual anchor */
  .section-head h2::after, .split h2::after, .ax h2::after, .blog-head h2::after {
    content: ""; position: absolute; left: 0; bottom: 0; width: 56px; height: 4px; border-radius: 4px;
    background: linear-gradient(90deg, var(--blue), var(--green));
  }
  .section-head.text-center h2::after { left: 50%; transform: translateX(-50%); }
  .intern-x h2::after, .sf-sec h2::after, .page-hero h2::after { background: linear-gradient(90deg, #7ee2ad, #fff); }

  /* Body copy: lighter grey, slightly smaller, relaxed — clearly secondary */
  body, p, li { color: var(--body-ink); }
  .section-head p, .split p, .ax p { font-size: .97rem; line-height: 1.72; color: var(--body-ink); margin-top: 0; }
  .card p, .perk p, .svc-card p, .post-body p, .program-body li, .lc-pane p, .bento p, .tl-card p, .faq-a p { font-size: .92rem; color: var(--body-ink); line-height: 1.65; }

  /* Card titles: heavier & darker than their text */
  h3 { font-weight: 800; letter-spacing: -.015em; }
  .card h3, .perk h3, .svc-card h3, .post-body h3, .lc-pane h3, .tl-card h3, .program-top h3, .step h3, .bento h3 { margin-bottom: 8px; }

  /* Keep light-on-dark areas readable */
  .page-hero h1, .page-hero h2, .intern-x h2, .cta h2, .mvv-card h3, .b-big h3, .b-green h3, .panel-head h3, .program-top h3, .side-cta h4, .footer h4 { color: #fff; }
  .page-hero p { color: #d6e4f7; }
  .intern-x p, .footer p, .footer li { color: #b9cbe6; }
  .mvv-card p, .b-big p, .panel-head p { color: rgba(255,255,255,.86); }
  .b-green p { color: #e0f8ec; }
  .cta p, .side-cta p { color: #d6e4f7; }
  .check-list li, .lc-doms strong, .dom-card strong, .faq-q, .testi-card p { color: var(--head-ink); }
  .testi-card p { font-weight: 500; }

  /* Breathing room between sections' header block and content */
  .section-head { margin-bottom: 34px; }
  .eyebrow { margin-bottom: 16px; }
}
@media (max-width: 360px) {
  h2 { font-size: 2rem; }
}
@media (max-width: 640px) { .article-hero h1 { font-size: 2rem !important; overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto; } }
@media (max-width: 360px) { .article-hero h1 { font-size: 1.8rem !important; } }

/* ---------- Bullet points (replacing long paragraphs) ---------- */
.check-list.on-dark { margin: 18px 0 0; gap: 12px; position: relative; }
.check-list.on-dark li { color: #e6eefa !important; font-size: .98rem; font-weight: 500; }
.check-list li { line-height: 1.5; }
@media (max-width: 640px) {
  .check-list { gap: 12px; margin: 20px 0 26px; }
  .check-list li { font-size: .96rem; }
}

/* ==========================================================
   Phones: open, airy headings (looks right even if the web font
   can't load and the phone falls back to its system font)
   ========================================================== */
:root { --font-head: "Montserrat", "Segoe UI", Roboto, "Helvetica Neue", Arial, system-ui, sans-serif; --font-body: "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, system-ui, sans-serif; }
@media (max-width: 640px) {
  h1, h2, h3, .hero-x h1, .page-hero h1 { letter-spacing: -.005em !important; }
  h2 { line-height: 1.18 !important; }

  /* Hero: more breathing room so it never looks squeezed */
  .hero-x { padding: 46px 0 104px; }
  .hero-x .eyebrow { margin-bottom: 22px; }
  .hero-x h1 { line-height: 1.16 !important; margin-bottom: 22px; }
  .rotator { height: 1.3em; }
  .hero-lead { font-size: 1.05rem; line-height: 1.75; margin-bottom: 32px; }
  .hero-x .hero-actions .btn { padding: 16px 26px; font-size: .95rem; }
}

/* ==========================================================
   Consistent, responsive section headings (all screen sizes)
   Every homepage H2 is 23–26 characters. Fluid size + a width
   cap measured in "em" means each one always wraps into the
   same two balanced lines — on phones, tablets and desktop.
   ========================================================== */
h2 { font-size: clamp(2rem, 1.2rem + 3vw, 3rem); line-height: 1.15; }
.section-head h2, .split h2, .ax h2, .blog-head h2, .intern-x h2 { max-width: 11em; }
.section-head.text-center h2 { margin-inline: auto; }

/* Hero title scales smoothly too */
.hero-x h1 { font-size: clamp(2.2rem, 1.4rem + 3.4vw, 3.6rem); }

@media (max-width: 640px) {
  h2 { font-size: clamp(1.85rem, 9.6vw, 2.6rem) !important; }
  .hero-x h1 { font-size: clamp(2.1rem, 10.6vw, 3rem) !important; }
  .page-hero h1 { font-size: clamp(2rem, 10vw, 2.8rem) !important; }
}

/* ==========================================================
   All section headings left-aligned (every page, every size)
   ========================================================== */
.section-head.text-center { text-align: left; margin-left: 0; margin-right: auto; }
.section-head.text-center h2, .section-head.text-center p { margin-left: 0 !important; margin-right: auto !important; }
.section-head.text-center h2::after { left: 0 !important; transform: none !important; }
@media (min-width: 641px) {
  .section-head h2 { position: relative; padding-bottom: 18px; margin-bottom: 18px; }
  .section-head h2::after { content: ""; position: absolute; left: 0; bottom: 0; width: 56px; height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--blue), var(--green)); }
}

/* ==========================================================
   Collaborative network & certifications
   ========================================================== */
.trust-panel {
  border-radius: 28px; padding: clamp(28px, 4vw, 52px);
  background: linear-gradient(135deg, #e8f3fd 0%, #eef7fd 55%, #eaf8f1 100%);
  border: 1px solid rgba(30,136,229,.14);
}
.trust-panel .section-head, .trust-certs .section-head { margin-bottom: 30px; }
.trust-certs { margin-top: clamp(50px, 7vw, 80px); }
.logo-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 20px; }
.certs-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 230px)); }
.logo-tile {
  aspect-ratio: 1 / 1; background: #fff; border-radius: 20px; border: 1px solid #e6eef7;
  box-shadow: 0 8px 22px rgba(11,58,120,.06);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  padding: 18px 12px; text-align: center;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .3s;
}
.logo-tile:hover { transform: translateY(-6px); box-shadow: 0 20px 40px rgba(11,58,120,.14); border-color: rgba(30,136,229,.3); }
.logo-tile img { max-width: 78%; max-height: 64%; object-fit: contain; }
.logo-tile .lt-ic {
  width: 58px; height: 58px; border-radius: 16px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #2aa6f2 0%, #1e6fd0 45%, #0b3a78 100%);
  box-shadow: 0 10px 22px rgba(30,111,208,.28);
}
.certs-grid .logo-tile .lt-ic { background: linear-gradient(135deg, #8cc63f, #12b76a 55%, #0e9f5c); box-shadow: 0 10px 22px rgba(18,183,106,.28); }
.logo-tile .lt-ic svg { width: 28px; height: 28px; }
.logo-tile strong { font-family: var(--font-head); font-weight: 800; color: var(--ink); font-size: .95rem; line-height: 1.25; }
.logo-tile small { color: var(--muted); font-size: .78rem; line-height: 1.3; margin-top: -4px; }

@media (max-width: 1080px) { .logo-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) {
  .trust-panel { border-radius: 22px; padding: 26px 16px; }
  .logo-grid, .certs-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .logo-tile { border-radius: 16px; padding: 12px 6px; gap: 8px; }
  .logo-tile .lt-ic { width: 42px; height: 42px; border-radius: 12px; }
  .logo-tile .lt-ic svg { width: 21px; height: 21px; }
  .logo-tile strong { font-size: .76rem; }
  .logo-tile small { font-size: .64rem; }
  .logo-tile:hover { transform: none; }
}

/* ==========================================================
   Inner-page hero v2 — light split layout (text + visual card)
   ========================================================== */
.page-hero.ph2 {
  color: var(--ink); overflow: hidden;
  padding: clamp(48px, 7vw, 90px) 0 clamp(60px, 8vw, 100px);
  background:
    radial-gradient(800px 480px at 88% 10%, rgba(14,165,233,.16), transparent 60%),
    radial-gradient(640px 420px at -5% 100%, rgba(18,183,106,.13), transparent 60%),
    linear-gradient(180deg, #f5f9ff 0%, #ffffff 100%);
}
.page-hero.ph2::before, .page-hero.ph2::after { display: none; }
.ph-bg { position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(11,58,120,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(11,58,120,.045) 1px, transparent 1px);
  background-size: 52px 52px;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 70% 40%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 70% at 70% 40%, #000 20%, transparent 75%); }
.ph-grid { position: relative; z-index: 2; display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(40px, 6vw, 80px); align-items: center; }
.ph-grid > * { min-width: 0; }
.ph2 .crumbs { color: var(--muted); font-size: .88rem; margin-bottom: 18px; }
.ph2 .crumbs a { color: var(--blue); font-weight: 500; }
.ph2 .crumbs a:hover { color: var(--navy); }
.ph2 .eyebrow { background: rgba(18,183,106,.1) !important; color: var(--green-600) !important; }
.ph2 h1 { color: #071a3d !important; font-size: clamp(2.3rem, 1.4rem + 3.2vw, 3.6rem) !important; line-height: 1.12; max-width: 11em; letter-spacing: -.02em; }
.ph2 p { color: var(--text) !important; font-size: 1.12rem; margin-top: 18px; max-width: 34em; }
.ph2 .hero-actions { margin-top: 30px; display: flex; gap: 12px; flex-wrap: wrap; }

/* Visual card */
.ph-visual { position: relative; max-width: 500px; width: 100%; margin-left: auto; padding: 24px 0; }
.phv-card {
  position: relative; aspect-ratio: 5 / 4; border-radius: 32px; overflow: hidden;
  background: radial-gradient(circle at 25% 18%, #3fa2f2 0%, #1a5fbf 38%, #0b3a78 72%, #06244d 100%);
  box-shadow: 0 34px 70px rgba(11,58,120,.28); display: grid; place-items: center;
}
.phv-dots { position: absolute; inset: 0; opacity: .16; background-image: radial-gradient(#fff 1.3px, transparent 1.3px); background-size: 20px 20px; }
.phv-ring { position: absolute; border-radius: 50%; border: 2px dashed rgba(255,255,255,.18); }
.phv-ring.r1 { width: 72%; aspect-ratio: 1; }
.phv-ring.r2 { width: 46%; aspect-ratio: 1; border-style: solid; border-color: rgba(126,226,173,.3); }
.phv-card::after { content: ""; position: absolute; width: 60%; aspect-ratio: 1; border-radius: 50%; right: -18%; bottom: -24%; background: radial-gradient(circle, rgba(18,183,106,.5), transparent 65%); }
.phv-icon { position: relative; z-index: 1; width: 34%; aspect-ratio: 1; border-radius: 30%; display: grid; place-items: center; color: #fff;
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.3); backdrop-filter: blur(8px); box-shadow: inset 0 1px 0 rgba(255,255,255,.35); }
.phv-icon svg { width: 46%; height: 46%; }
.phv-grid { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; width: 62%; }
.phv-grid span { aspect-ratio: 1; border-radius: 18px; display: grid; place-items: center; color: #fff; background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.25); backdrop-filter: blur(6px); }
.phv-grid span:nth-child(2n) { background: rgba(126,226,173,.22); }
.phv-grid svg { width: 44%; height: 44%; }

/* Info chips around the card */
.phv-chip { position: absolute; z-index: 3; display: flex; align-items: center; gap: 12px; padding: 12px 16px 12px 12px; border-radius: 16px;
  background: rgba(255,255,255,.95); border: 1px solid #e6eef7; box-shadow: 0 18px 40px rgba(11,58,120,.16); min-width: 0; max-width: 250px; }
.phv-chip .ci { width: 42px; height: 42px; flex-shrink: 0; border-radius: 12px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #2aa6f2, #0b3a78); }
.phv-chip.c2 .ci { background: linear-gradient(135deg, #8cc63f, #12b76a); }
.phv-chip .ci svg { width: 20px; height: 20px; }
.phv-chip strong { display: block; font-family: var(--font-head); font-weight: 800; font-size: .92rem; color: #071a3d; line-height: 1.2; }
.phv-chip small { display: block; font-size: .78rem; color: var(--muted); line-height: 1.3; }
.phv-chip.c1 { top: 4%; left: -12%; }
.phv-chip.c2 { top: 44%; right: -8%; }
.phv-chip.c3 { bottom: 2%; left: 4%; }

/* Contact quick-cards sit just under the hero */
.page-hero.ph2 + .stats { margin-top: -30px !important; }

/* Article page hero uses the same light look (text only) */
.article-hero.page-hero { color: var(--ink); background: linear-gradient(180deg, #f5f9ff 0%, #ffffff 100%); }
.article-hero.page-hero::before, .article-hero.page-hero::after, .article-hero .hero-pattern { display: none; }
.article-hero h1 { color: #071a3d !important; }
.article-hero .crumbs { color: var(--muted); } .article-hero .crumbs a { color: var(--blue); }
.article-hero .eyebrow { background: rgba(18,183,106,.1) !important; color: var(--green-600) !important; }
.article-hero .article-meta { color: var(--muted); }
.article-hero .article-meta svg { color: var(--green); }

@media (max-width: 960px) {
  .ph-grid { grid-template-columns: 1fr; gap: 34px; }
  .ph-visual { margin: 0 auto; max-width: 460px; }
}
@media (max-width: 640px) {
  .page-hero.ph2 { padding: 34px 0 56px; }
  .ph2 h1 { font-size: clamp(2.05rem, 10vw, 2.8rem) !important; line-height: 1.14 !important; }
  .ph2 p { font-size: 1.02rem; margin-top: 14px; }
  .ph2 .hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .ph2 .hero-actions .btn { padding: 14px 10px; }
  .ph-visual { padding: 18px 0 30px; max-width: 100%; }
  .phv-card { aspect-ratio: 16 / 12; border-radius: 24px; }
  .phv-chip { padding: 9px 12px 9px 9px; gap: 9px; border-radius: 13px; max-width: 64%; }
  .phv-chip .ci { width: 34px; height: 34px; border-radius: 10px; }
  .phv-chip .ci svg { width: 17px; height: 17px; }
  .phv-chip strong { font-size: .8rem; }
  .phv-chip small { font-size: .68rem; }
  .phv-chip.c1 { top: 2%; left: 6px; }
  .phv-chip.c2 { top: auto; bottom: 26%; right: 6px; }
  .phv-chip.c3 { bottom: 4%; }
  .phv-chip.c3 { bottom: 4%; left: 6px; }
  .page-hero.ph2 + .stats { margin-top: 0 !important; }
}

/* ==========================================================
   Internship apply panel (Google Form links) + contact quick cards
   ========================================================== */
.apply-panel {
  border-radius: 28px; padding: clamp(28px, 4vw, 52px);
  background: linear-gradient(135deg, #e8f3fd 0%, #eef7fd 55%, #eaf8f1 100%);
  border: 1px solid rgba(30,136,229,.14);
}
.apply-panel .section-head { margin-bottom: 30px; }
.apply-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.apply-btn {
  display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 18px;
  background: #fff; border: 1px solid #e3ecf6; box-shadow: 0 6px 18px rgba(11,58,120,.06);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .3s;
}
.apply-btn:hover { transform: translateY(-4px); border-color: var(--green); box-shadow: 0 18px 36px rgba(11,58,120,.14); }
.apply-btn .di { width: 44px; height: 44px; flex-shrink: 0; border-radius: 12px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #2aa6f2, #0b3a78); }
.apply-btn .di svg { width: 22px; height: 22px; }
.apply-btn strong { font-family: var(--font-head); font-weight: 800; color: #071a3d; font-size: .98rem; line-height: 1.25; flex: 1; min-width: 0; }
.apply-btn > svg { width: 20px; height: 20px; color: var(--green-600); flex-shrink: 0; transition: transform .3s var(--ease); }
.apply-btn:hover > svg { transform: translateX(4px); }
.apply-note { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 24px; font-size: .95rem; color: var(--text); }
.apply-note svg { width: 18px; height: 18px; color: var(--green); }
.apply-note a { color: var(--blue); font-weight: 600; }
.program-body .btn-primary { margin-top: auto; width: 100%; }

@media (max-width: 960px) { .apply-list { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) {
  .apply-panel { border-radius: 22px; padding: 26px 16px; }
  .apply-list { grid-template-columns: 1fr; gap: 10px; }
  .apply-btn { padding: 13px 14px; }
  .apply-btn .di { width: 38px; height: 38px; }
  .quick-cards { grid-template-columns: repeat(3, 1fr) !important; gap: 8px !important; }
  .quick-cards .card { padding: 16px 8px; }
  .quick-cards .icon-box { width: 40px; height: 40px; margin-bottom: 8px; border-radius: 11px; }
  .quick-cards .icon-box svg { width: 20px; height: 20px; }
  .quick-cards h3 { font-size: .84rem !important; margin-bottom: 4px; }
  .quick-cards p { font-size: .7rem; line-height: 1.35; overflow-wrap: normal; }
}

/* ==========================================================
   Inner-page hero: layered brand wave at the bottom
   (replaces the single plain white curve)
   ========================================================== */
.page-hero .wave.wave-layered { height: clamp(60px, 7vw, 100px); bottom: -1px; }
.page-hero { padding-bottom: clamp(110px, 12vw, 160px); }
@media (max-width: 640px) {
  .page-hero .wave.wave-layered { height: 56px; }
  .page-hero { padding-bottom: 96px; }
}

/* ==========================================================
   Inner-page hero: compact height
   ========================================================== */
.page-hero { padding: clamp(40px, 5vw, 64px) 0 clamp(70px, 7vw, 96px) !important; }
.page-hero .crumbs { margin-bottom: 14px; }
.page-hero .eyebrow { margin-bottom: 12px; }
.page-hero h1 { font-size: clamp(1.9rem, 1.3rem + 1.9vw, 2.75rem) !important; line-height: 1.15 !important; max-width: 900px; }
.page-hero p { margin-top: 10px; font-size: 1.02rem; }
.page-hero .hero-actions { margin-top: 22px !important; }
.page-hero .wave.wave-layered { height: clamp(34px, 4vw, 56px) !important; }
@media (max-width: 640px) {
  .page-hero { padding: 30px 0 60px !important; }
  .page-hero h1 { font-size: 1.75rem !important; }
  .page-hero p { font-size: .95rem; }
  .page-hero .wave.wave-layered { height: 32px !important; }
  .page-hero .hero-actions .btn { padding: 12px 10px; }
}

/* ==========================================================
   Inner-page PHOTO banner
   Photo per page: assets/banners/<page>.jpg  (about, services,
   internship, blog, contact). Without a photo it shows plain navy.
   ========================================================== */
.page-hero.photo-hero {
  --hero-img: none;
  position: relative; color: #fff; overflow: hidden;
  padding: clamp(56px, 7vw, 96px) 0 clamp(56px, 7vw, 96px) !important;
  background-color: #0b2a57;
  background-image:
    linear-gradient(90deg, rgba(6,26,56,.94) 0%, rgba(8,38,84,.86) 42%, rgba(11,58,120,.55) 100%),
    var(--hero-img);
  background-size: cover; background-position: center;
  border-bottom: 4px solid var(--green);
}
.page-hero.photo-hero::before, .page-hero.photo-hero::after { display: none !important; }
.photo-hero .container { position: relative; z-index: 2; }
.photo-hero .crumbs { font-size: .85rem; letter-spacing: .02em; color: rgba(255,255,255,.7); margin-bottom: 16px; }
.photo-hero .crumbs a { color: rgba(255,255,255,.85); }
.photo-hero .crumbs a:hover { color: #fff; }
.photo-hero h1 { color: #fff !important; font-size: clamp(2rem, 1.3rem + 2vw, 2.9rem) !important; line-height: 1.15 !important; letter-spacing: -.01em !important; max-width: 820px; font-weight: 800; }
.photo-hero p { color: rgba(255,255,255,.85) !important; font-size: 1.08rem; margin-top: 14px; max-width: 640px; }
.photo-hero .hero-actions { margin-top: 26px !important; }
.photo-hero .btn-ghost { border-color: rgba(255,255,255,.55); }

@media (max-width: 640px) {
  .page-hero.photo-hero { padding: 40px 0 44px !important;
    background-image: linear-gradient(180deg, rgba(6,26,56,.9) 0%, rgba(8,38,84,.86) 100%), var(--hero-img); }
  .photo-hero h1 { font-size: 1.8rem !important; }
  .photo-hero p { font-size: .98rem; }
}

/* Partner / certification tiles: never wider than their panel */
.logo-grid > * { min-width: 0; }
@media (max-width: 640px) {
  .logo-grid, .certs-grid { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; gap: 8px !important; }
  .logo-tile { aspect-ratio: auto; min-height: 104px; padding: 12px 4px; }
  .logo-tile strong { font-size: .72rem; overflow-wrap: anywhere; }
  .logo-tile small { font-size: .6rem; }
}

/* ---------- Logo (no tagline / TM): wider mark, so slightly shorter ---------- */
.brand img { height: 38px !important; width: auto; }
.footer-logo img { height: 32px !important; }
@media (max-width: 640px) { .brand img { height: 30px !important; } }

/* ==========================================================
   Very small phones (≤ 360px) — final alignment fixes
   ========================================================== */
@media (max-width: 360px) {
  .jr-dot { width: 36px !important; height: 36px !important; }
  .jr-dot svg { width: 16px !important; height: 16px !important; }
  .jr-line { top: 17px !important; }
  .quick-cards { grid-template-columns: 1fr !important; }
  .bento { grid-template-columns: 1fr !important; }
  .bento > div { grid-column: auto !important; }
  .page-hero .hero-actions { display: grid !important; grid-template-columns: 1fr !important; }
  .tab-btn { font-size: .8rem !important; overflow-wrap: anywhere; hyphens: auto; -webkit-hyphens: auto; }
}
@media (max-width: 360px) {
  .end-actions { grid-template-columns: 1fr !important; }
  .panel-head h3 { font-size: 1.35rem !important; overflow-wrap: anywhere; }
}
