/* =====================================================================
   Video - Title Card (prefix: .aftc, pop-up: .aftc-pop)
   Full width video band: the looping background clip plays almost clear and the copy sits on a navy
   grid card, with the play button as a tab on the card's edge. On phones the clip stacks above the
   card with the tab on the join. Playing opens the main video in a full-screen pop-up player that
   grows out of the card.
   Options (classes on the section):
     aftc--card-left | aftc--card-right                 which side the card sits on (768px and up)
     aftc--tint-light | --tint-standard | --tint-dark   how dark the tint over the clip is
     aftc--grid                                         44px grid lines on the card
     aftc--focus-center | --focus-left | --focus-right  which part of the clip stays in view
     aftc--no-media                                     no clip or poster: navy gradient instead
     aftc--no-foot                                      no View all videos link and no phone number
   State (set by module.js): .is-armed, .is-in, .is-done (entrance), .is-live (clip playing),
     .is-hot (tab or footage hovered), .is-lifted (pop-up opening from the card) on the section;
     .is-open, .is-loading on .aftc-pop; html.aftc-lock while the pop-up is open
   Uses the theme's CSS variables with AirFreight.com values as fallbacks.
   Assumes the theme's html { font-size: 62.5% } (1rem = 10px). Square corners, no drop shadows.
   ===================================================================== */
.aftc, .aftc-pop {
  --aftc-navy: #00305A; --aftc-deep: #00243F; --aftc-ink: #00172B;
  --aftc-blue: var(--primary-color, #0092D6); --aftc-blue-2: var(--secondary-color, #006EB8); --aftc-mid: #007BCF;
  --aftc-ice: #01B0FF; --aftc-sky: #8CD8FF; --aftc-pale: #BFE7FF;
  --aftc-text: #E6F2FB; --aftc-hair: rgba(255, 255, 255, .18);
  --aftc-display: var(--secondary-font-family, 'Jost', sans-serif);
  --aftc-body: var(--primary-font-family, 'Raleway', sans-serif);
  --aftc-gridlines: linear-gradient(rgba(255,255,255,.055) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.055) 1px, transparent 1px);
  --aftc-grad: linear-gradient(115deg, #00305A 0%, #00518F 42.5%, #006EB8 100%);
  /* the easing set: Out for reveals and hover moves, In-out for wipes that play on their own,
     Swift for anything a click sets off, Standard for colour and opacity, Rise for text fading up */
  --aftc-out: cubic-bezier(.16, 1, .3, 1);
  --aftc-inout: cubic-bezier(.76, 0, .24, 1);
  --aftc-swift: cubic-bezier(.3, 0, 0, 1);
  --aftc-std: cubic-bezier(.4, 0, .2, 1);
  --aftc-rise: cubic-bezier(.22, .61, .36, 1);
}
.aftc {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  overflow: clip;
  /* never wider than the screen: HubSpot's flex rows let a module's minimum width push the column open */
  width: 100%;
  min-width: 0;
  max-width: 100vw;
  /* the theme pads every <section>; this one runs edge to edge */
  padding: 0;
  margin: 0;
  color: #fff;
  font-family: var(--aftc-body);
  font-weight: 500;
  font-size: 1.6rem;
  line-height: 1.7;
  text-align: left;
}
.aftc *, .aftc *::before, .aftc *::after,
.aftc-pop, .aftc-pop *, .aftc-pop *::before, .aftc-pop *::after { box-sizing: border-box; }
.aftc p, .aftc-pop p { margin: 0; }
/* theme button and link styles are reset so every control starts clean */
.aftc button, .aftc-pop button {
  -webkit-appearance: none; appearance: none;
  margin: 0; padding: 0; border: 0; border-radius: 0; box-shadow: none; text-shadow: none;
  background: none; color: inherit; font: inherit; letter-spacing: inherit; text-transform: none;
  line-height: inherit; width: auto; height: auto; min-width: 0; min-height: 0; cursor: pointer;
}
.aftc a, .aftc-pop a {
  color: inherit; font-family: inherit; font-weight: inherit; font-size: inherit; line-height: inherit;
  letter-spacing: inherit; text-transform: inherit; text-align: inherit; text-decoration: none; transition: none;
}
.aftc :focus-visible, .aftc-pop :focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

/* ---- Background: poster image with the looping clip on top (module.js starts the clip) ---- */
.aftc .aftc__media { position: absolute; inset: 0; z-index: -1; overflow: hidden; background-color: var(--aftc-deep); }
.aftc--no-media .aftc__media { background-image: var(--aftc-gridlines), var(--aftc-grad); background-size: 44px 44px, 44px 44px, 100% 100%; }
.aftc .aftc__pic { position: absolute; inset: 0; transition: transform 1.4s var(--aftc-out); }
.aftc .aftc__poster, .aftc .aftc__clip { position: absolute; inset: 0; display: block; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: 50% 50%; }
.aftc--focus-left .aftc__poster, .aftc--focus-left .aftc__clip { object-position: 0 50%; }
.aftc--focus-right .aftc__poster, .aftc--focus-right .aftc__clip { object-position: 100% 50%; }
.aftc .aftc__clip { opacity: 0; transition: opacity .8s var(--aftc-std); }
.aftc.is-live .aftc__clip { opacity: 1; }
.aftc.is-hot .aftc__pic { transform: scale(1.035); }
.aftc .aftc__c { width: min(var(--container-width, 1180px), 100% - 4rem); margin-inline: auto; }

/* ---- Shared parts: eyebrow, title, pulse dot, text link, phone ---- */
.aftc .aftc__eyebrow { display: flex; align-items: center; gap: 1.44rem; margin: 0; font-family: var(--aftc-display); font-weight: 700; font-size: 1.5rem; line-height: 1.4; letter-spacing: 3px; text-transform: uppercase; color: #fff; }
.aftc .aftc__eyebrow::before { content: ""; flex: none; width: 1.98rem; height: 3px; background: currentColor; transform-origin: left; }
.aftc .aftc__eyebrow span { display: block; }
.aftc .aftc__title { margin: 0; padding: 0; font-family: var(--aftc-display); font-weight: 700; letter-spacing: -.015em; text-transform: none; color: #fff; text-wrap: balance; }
.aftc .aftc__title em { font-style: normal; font-weight: inherit; color: var(--aftc-pale); }
/* module.js wraps each rendered line of the title so it can animate on its own */
.aftc .aftc__ln { display: block; overflow: hidden; padding-bottom: .12em; margin-bottom: -.12em; }
.aftc .aftc__ln-i { display: block; }
.aftc .aftc__w { display: inline-block; }

.aftc .aftc__dot { flex: none; display: block; width: .9rem; height: .9rem; border-radius: 50%; background: var(--aftc-pale); animation: aftc-pulse 2s infinite; }
@keyframes aftc-pulse { 0% { box-shadow: 0 0 0 0 rgba(191,231,255,.7); } 70% { box-shadow: 0 0 0 9px rgba(191,231,255,0); } 100% { box-shadow: 0 0 0 0 rgba(191,231,255,0); } }

.aftc .aftc__link, .aftc-pop .aftc__link { display: inline-flex; align-items: center; gap: 1rem; padding: 0 0 .5rem; font-family: var(--aftc-display); font-weight: 600; font-size: 1.4rem; line-height: 1.3; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; color: #fff; cursor: pointer;
  background: linear-gradient(currentColor, currentColor) no-repeat 0 100% / 0 2px; transition: background-size .45s var(--aftc-out); }
.aftc .aftc__link svg, .aftc-pop .aftc__link svg { display: block; flex: none; width: 1.6rem; height: 1.2rem; fill: currentColor; transition: transform .35s var(--aftc-out); }
.aftc .aftc__link:hover, .aftc .aftc__link:focus, .aftc-pop .aftc__link:hover, .aftc-pop .aftc__link:focus { color: #fff; background-size: 100% 2px; }
.aftc .aftc__link:hover svg, .aftc .aftc__link:focus svg, .aftc-pop .aftc__link:hover svg, .aftc-pop .aftc__link:focus svg { transform: translateX(4px); }

.aftc .aftc__call, .aftc-pop .aftc__call { display: inline-flex; align-items: center; gap: 1rem; font-family: var(--aftc-display); font-style: normal; font-weight: 600; font-size: 1.9rem; line-height: 1; letter-spacing: .08em; white-space: nowrap; color: #fff; cursor: pointer; transition: color .2s var(--aftc-std); }
.aftc .aftc__call svg, .aftc-pop .aftc__call svg { display: block; flex: none; width: 1.8rem; height: 1.8rem; fill: currentColor; transform-origin: 50% 60%; }
.aftc .aftc__call:hover, .aftc .aftc__call:focus, .aftc-pop .aftc__call:hover, .aftc-pop .aftc__call:focus { color: var(--aftc-pale); }
.aftc .aftc__call:hover svg, .aftc-pop .aftc__call:hover svg { animation: aftc-ring .6s var(--aftc-std); }
@keyframes aftc-ring { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-14deg); } 40% { transform: rotate(11deg); } 60% { transform: rotate(-7deg); } 80% { transform: rotate(4deg); } }

/* ---- Entrance: everything sits in its final state by default. .is-armed hides the animated parts
   until module.js adds .is-in (a third of the section in view), which plays each part once. ---- */
.aftc.is-armed:not(.is-in) [data-a], .aftc.is-armed:not(.is-in) .aftc__ln-i, .aftc.is-armed:not(.is-in) .js-aftc-split:not(.is-split) { opacity: 0; }
.aftc.is-done .aftc__ln-i { animation: none !important; }
@keyframes aftc-push { from { transform: scale(var(--s, 1.08)) translateX(var(--x, 0)); } to { transform: none; } }
@keyframes aftc-draw { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes aftc-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes aftc-fade-y { from { opacity: 0; transform: translateY(var(--y, 1.6rem)); } to { opacity: 1; transform: none; } }

/* ---- Light tint: the clip plays almost clear, because the copy sits on its own card ---- */
.aftc { --c1: .5; --c2: .1; --c3: .42; display: flex; align-items: center; min-height: clamp(56rem, 46vw, 72rem); background-color: var(--aftc-deep); }
.aftc--tint-light { --c1: .28; --c2: .04; --c3: .24; }
.aftc--tint-dark { --c1: .68; --c2: .3; --c3: .56; }
.aftc--has-video .aftc__media { cursor: pointer; }
.aftc .aftc__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,36,63,var(--c1)) 0%, rgba(0,36,63,var(--c2)) 56%, rgba(0,36,63,0) 100%), linear-gradient(0deg, rgba(0,36,63,var(--c3)) 0%, rgba(0,36,63,0) 40%); transition: opacity .6s var(--aftc-std); }
.aftc--no-media .aftc__media::after { display: none; }
.aftc.is-hot .aftc__media::after { opacity: .55; }

/* ---- Card ---- */
.aftc .aftc__in { padding-block: 7.2rem; pointer-events: none; }
.aftc .aftc__card { position: relative; width: min(52rem, 100%); pointer-events: auto; }
.aftc .aftc__panel { position: relative; padding: 4.8rem 4.8rem 0; background-color: var(--aftc-navy); background-image: var(--aftc-grad); }
.aftc--grid .aftc__panel { background-image: var(--aftc-gridlines), var(--aftc-grad); background-size: 44px 44px, 44px 44px, 100% 100%; }
.aftc .aftc__panel > * { transition: opacity .3s var(--aftc-std) .1s; }
/* while the pop-up opens from the card, the card's own text steps aside */
.aftc.is-lifted .aftc__panel > * { opacity: 0; transition: opacity .12s linear; }
.aftc .aftc__panel::before { content: ""; position: absolute; inset: 0 0 auto; height: 4px; background: var(--aftc-ice); transform-origin: left; }
.aftc .aftc__title { margin-top: 1.6rem; font-size: clamp(3.2rem, 3.5vw, 4.6rem); line-height: 1.1; }
.aftc .aftc__title:first-child { margin-top: 0; }
.aftc .aftc__desc { margin-top: 1.8rem; font-family: var(--aftc-body); font-weight: 500; font-size: 1.8rem; line-height: 1.75; color: var(--aftc-text); }
.aftc .aftc__foot { position: relative; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.2rem 2.4rem; min-height: 7.6rem; margin: 3.6rem -4.8rem 0; padding: 1.8rem 4.8rem; }
.aftc .aftc__foot::before { content: ""; position: absolute; inset: 0 0 auto; height: 1px; background: var(--aftc-hair); transform-origin: left; }
.aftc .aftc__foot .aftc__link { padding-block: .5rem; }
.aftc--no-foot .aftc__panel { padding-bottom: 4.8rem; }

/* ---- Play tab on the card's edge, reaching out over the footage ---- */
.aftc .aftc__tab-clip { position: absolute; left: 100%; top: 50%; transform: translateY(-50%); overflow: hidden; }
.aftc .aftc__tab { display: flex; align-items: stretch; height: 8.8rem; color: #fff; text-align: left; }
.aftc .aftc__tab-ico { flex: none; display: grid; place-items: center; width: 8.8rem; background: var(--aftc-blue); transition: background .3s var(--aftc-std); }
.aftc .aftc__tab-ico svg { display: block; width: 2.3rem; height: 2.6rem; margin-left: .4rem; fill: #fff; transition: transform .45s var(--aftc-out); }
.aftc .aftc__tab-txt { position: relative; isolation: isolate; overflow: hidden; display: flex; flex-direction: column; justify-content: center; gap: .7rem; padding: 0 3.2rem 0 2.4rem; background: rgba(0,36,63,.82); white-space: nowrap; }
.aftc .aftc__tab-txt::before { content: ""; position: absolute; inset: 0; z-index: -1; background: #fff; transform: scaleX(0); transform-origin: left; transition: transform .5s var(--aftc-out); }
.aftc .aftc__tab-txt b { font-family: var(--aftc-display); font-weight: 600; font-size: 1.5rem; line-height: 1; letter-spacing: .12em; text-transform: uppercase; color: #fff; transition: color .3s var(--aftc-std); }
.aftc .aftc__tab-txt i { font-family: var(--aftc-display); font-style: normal; font-weight: 500; font-size: 1.3rem; line-height: 1; letter-spacing: .1em; text-transform: uppercase; color: var(--aftc-sky); font-variant-numeric: tabular-nums; transition: color .3s var(--aftc-std); }
/* hovering the tab or the footage: white wipes across the label, the tint lifts and the clip pushes in */
.aftc.is-hot .aftc__tab-ico { background: var(--aftc-blue-2); }
.aftc.is-hot .aftc__tab-ico svg { transform: translateX(3px) scale(1.08); }
.aftc.is-hot .aftc__tab-txt::before { transform: scaleX(1); }
.aftc.is-hot .aftc__tab-txt b { color: var(--aftc-navy); }
.aftc.is-hot .aftc__tab-txt i { color: var(--aftc-blue-2); }
.aftc .aftc__tab:active .aftc__tab-ico svg { transform: scale(.94); }

/* ---- Entrance ---- */
@keyframes aftc-fade-x { from { opacity: 0; transform: translateX(-1rem); } to { opacity: 1; transform: none; } }
@keyframes aftc-line { from { transform: translateY(112%); } to { transform: none; } }
@keyframes aftc-wipe { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes aftc-wipe-r { from { clip-path: inset(0 0 0 100%); } to { clip-path: inset(0 0 0 0); } }
@keyframes aftc-slide-x { from { transform: translateX(-101%); } to { transform: none; } }
@keyframes aftc-slide-r { from { transform: translateX(101%); } to { transform: none; } }
.aftc.is-in .aftc__pic { --s: 1.12; --x: -3%; animation: aftc-push 1.7s var(--aftc-out) backwards; }
.aftc.is-in .aftc__panel { animation: aftc-wipe .9s var(--aftc-inout) .15s backwards; }
.aftc.is-in .aftc__panel::before { animation: aftc-draw .7s var(--aftc-out) .65s backwards; }
.aftc.is-in .aftc__eyebrow::before { animation: aftc-draw .5s var(--aftc-out) .56s backwards; }
.aftc.is-in .aftc__eyebrow span { animation: aftc-fade-x .6s var(--aftc-out) .62s backwards; }
.aftc.is-in .aftc__ln-i { animation: aftc-line .85s var(--aftc-out) calc(.68s + var(--i, 0) * 80ms) backwards; }
.aftc.is-in .aftc__desc { animation: aftc-fade-y .8s var(--aftc-rise) .88s backwards; }
.aftc.is-in .aftc__foot::before { animation: aftc-draw .7s var(--aftc-out) .98s backwards; }
.aftc.is-in .aftc__foot > * { animation: aftc-fade .6s var(--aftc-rise) 1.08s backwards; }
.aftc.is-in .aftc__tab { animation: aftc-slide-x .8s var(--aftc-out) 1s backwards; }

/* ---- Card on the right (desktop and tablet): everything mirrors ---- */
@media (min-width: 768px) {
  .aftc--card-right .aftc__media::after { background: linear-gradient(270deg, rgba(0,36,63,var(--c1)) 0%, rgba(0,36,63,var(--c2)) 56%, rgba(0,36,63,0) 100%), linear-gradient(0deg, rgba(0,36,63,var(--c3)) 0%, rgba(0,36,63,0) 40%); }
  .aftc--card-right .aftc__card { margin-left: auto; }
  .aftc--card-right .aftc__tab-clip { left: auto; right: 100%; }
  .aftc--card-right .aftc__tab { flex-direction: row-reverse; }
  .aftc--card-right .aftc__tab-txt { padding: 0 2.4rem 0 3.2rem; }
  .aftc--card-right .aftc__tab-txt::before { transform-origin: right; }
  .aftc--card-right.is-in .aftc__pic { --x: 3%; }
  .aftc--card-right.is-in .aftc__panel { animation-name: aftc-wipe-r; }
  .aftc--card-right.is-in .aftc__tab { animation-name: aftc-slide-r; }
}

@media (max-width: 991px) {
  .aftc .aftc__card { width: min(46rem, 100% - 8.8rem); }
  .aftc .aftc__panel { padding: 4rem 4rem 0; }
  .aftc .aftc__foot { margin-inline: -4rem; padding-inline: 4rem; }
  .aftc--no-foot .aftc__panel { padding-bottom: 4rem; }
  .aftc .aftc__tab-txt { display: none; }
}
@media (max-width: 767px) {
  /* the clip sits on top at 16:11 and the card below it, with the play tab straddling the join */
  .aftc { flex-direction: column; align-items: stretch; min-height: 0; }
  .aftc .aftc__media { position: relative; inset: auto; z-index: 0; flex: none; aspect-ratio: 16 / 11; }
  .aftc .aftc__media::after { background: linear-gradient(0deg, rgba(0,36,63,var(--c1)) 0%, rgba(0,36,63,0) 46%); }
  .aftc .aftc__in { width: 100%; padding-block: 0; }
  .aftc .aftc__card { width: 100%; }
  .aftc .aftc__panel { padding: 6.8rem 2rem 0; }
  .aftc--no-video .aftc__panel { padding-top: 4rem; }
  .aftc .aftc__foot { margin: 3rem -2rem 0; padding: 1.8rem 2rem; min-height: 7rem; }
  .aftc--no-foot .aftc__panel { padding-bottom: 4rem; }
  .aftc .aftc__title { font-size: clamp(3rem, 8.6vw, 3.8rem); }
  .aftc .aftc__desc { font-size: 1.6rem; line-height: 1.7; }
  .aftc .aftc__tab-clip { left: 2rem; top: 0; }
  .aftc .aftc__tab { height: 7.2rem; }
  .aftc .aftc__tab-ico { width: 7.2rem; }
  .aftc .aftc__tab-ico svg { width: 2rem; height: 2.2rem; }
  .aftc .aftc__tab-txt { display: flex; padding: 0 2.4rem 0 1.8rem; background: var(--aftc-deep); }
  .aftc .aftc__tab-txt b { font-size: 1.4rem; }
}
/* no clip and no poster: a flat navy ground, so the gradient card still stands apart */
.aftc--no-media .aftc__media { background-image: var(--aftc-gridlines); background-size: 44px 44px; }

/* =====================================================================
   Pop-up player (.aftc-pop). module.js moves it to the end of <body>, so its rules do not sit
   under .aftc. Near-black navy with the 44px grid, the video name at the top left, a white square
   close button and the video as large as the screen allows. An end screen follows the video.
   ===================================================================== */
html.aftc-lock, html.aftc-lock body { overflow: hidden; }
.aftc-pop { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center;
  padding: calc(2.4rem + env(safe-area-inset-top, 0px)) max(3.2rem, env(safe-area-inset-right, 0px)) calc(2.4rem + env(safe-area-inset-bottom, 0px)) max(3.2rem, env(safe-area-inset-left, 0px));
  overflow: hidden; overscroll-behavior: contain;
  color: #fff; font-family: var(--aftc-body); font-weight: 500; font-size: 1.6rem; line-height: 1.7; text-align: left; }
.aftc-pop[hidden] { display: none; }
.aftc-pop .aftc-pop__bg { position: fixed; inset: 0; cursor: pointer; }
.aftc-pop .aftc-pop__bg i { position: absolute; inset: 0; display: block; background-color: #00162A; background-image: linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px); background-size: 44px 44px; }

.aftc-pop .aftc-pop__dialog { position: relative; width: min(150rem, 100%, (100vh - 15rem) * 16 / 9); }
@supports (height: 100dvh) { .aftc-pop .aftc-pop__dialog { width: min(150rem, 100%, (100dvh - 15rem) * 16 / 9); } }
.aftc-pop .aftc-pop__top { display: flex; align-items: center; justify-content: space-between; gap: 2rem; margin-bottom: 1.4rem; opacity: 0; transform: translateY(-1.2rem); transition: opacity .18s var(--aftc-std), transform .18s var(--aftc-std); }
.aftc-pop .aftc-pop__title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--aftc-display); font-weight: 600; font-size: 1.5rem; line-height: 1.3; letter-spacing: .1em; text-transform: uppercase; color: #fff; }
.aftc-pop .aftc-pop__close { flex: none; display: grid; place-items: center; width: 4.4rem; height: 4.4rem; background: #fff; color: var(--aftc-blue-2); transition: background .2s var(--aftc-std), color .2s var(--aftc-std); }
.aftc-pop .aftc-pop__close svg { display: block; width: 1.6rem; height: 1.6rem; stroke: currentColor; stroke-width: 2.2; fill: none; transition: transform .45s var(--aftc-out); }
.aftc-pop .aftc-pop__close:hover { background: var(--aftc-blue); color: #fff; }
.aftc-pop .aftc-pop__close:hover svg { transform: rotate(90deg); }
.aftc-pop .aftc-pop__stage { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #000; opacity: 0; transform: scale(.965); transition: opacity .18s var(--aftc-std), transform .18s var(--aftc-std); }
.aftc-pop .aftc-pop__stage video, .aftc-pop .aftc-pop__stage iframe { position: absolute; inset: 0; display: block; width: 100%; height: 100%; max-width: none; border: 0; background: #000; }
.aftc-pop .aftc-pop__stage video { object-fit: contain; }
/* loading: a short ice bar runs along the bottom of the video */
.aftc-pop .aftc-pop__stage::after { content: ""; position: absolute; left: 0; bottom: 0; z-index: 1; width: 30%; height: 4px; background: var(--aftc-ice); opacity: 0; pointer-events: none; }
.aftc-pop.is-loading .aftc-pop__stage::after { opacity: 1; animation: aftc-load 1.1s var(--aftc-std) infinite; }
@keyframes aftc-load { from { transform: translateX(-100%); } to { transform: translateX(340%); } }
/* content waits (--in) for the backdrop, then the title bar drops in and the video scales up */
.aftc-pop.is-open .aftc-pop__top { opacity: 1; transform: none; transition: opacity .45s var(--aftc-out) var(--in), transform .6s var(--aftc-out) var(--in); }
.aftc-pop.is-open .aftc-pop__stage { opacity: 1; transform: none; transition: opacity .4s var(--aftc-std) calc(var(--in) + 60ms), transform .7s var(--aftc-out) calc(var(--in) + 60ms); }

/* end screen */
.aftc-pop .aftc-pop__end { position: absolute; inset: 0; z-index: 2; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2.8rem; padding: 2rem; text-align: center; background: rgba(0,22,42,.94); animation: aftc-fade .4s var(--aftc-std); }
.aftc-pop .aftc-pop__end[hidden] { display: none; }
.aftc-pop .aftc-pop__end-k { font-family: var(--aftc-display); font-weight: 600; font-size: clamp(2.2rem, 3vw, 3.4rem); line-height: 1.15; color: #fff; }
.aftc-pop .aftc-pop__end-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1.6rem 3.2rem; }
.aftc-pop .aftc-pop__again { display: inline-flex; align-items: center; gap: 1.2rem; height: 5.6rem; padding: 0 2.6rem; background: var(--aftc-blue); color: #fff; font-family: var(--aftc-display); font-weight: 600; font-size: 1.4rem; line-height: 1; letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; transition: background .2s var(--aftc-std); }
.aftc-pop .aftc-pop__again:hover { background: var(--aftc-blue-2); }
.aftc-pop .aftc-pop__again svg { display: block; width: 1.6rem; height: 1.6rem; fill: none; stroke: currentColor; stroke-width: 2; }

/* Opening: card expand. The backdrop grows from the card's own outline (module.js sets --ct, --cr,
   --cb and --cl to the card's edges) until it fills the screen, then the card's gradient darkens. */
.aftc-pop { --in: .4s; }
.aftc-pop .aftc-pop__bg { clip-path: inset(var(--ct, 0px) var(--cr, 0px) var(--cb, 0px) var(--cl, 0px)); opacity: 0; transition: clip-path .5s var(--aftc-swift), opacity .16s linear .46s; }
.aftc-pop.is-open .aftc-pop__bg { clip-path: inset(0 0 0 0); opacity: 1; transition: opacity .14s linear, clip-path .66s var(--aftc-swift) .06s; }
.aftc-pop .aftc-pop__bg::after { content: ""; position: absolute; inset: 0; opacity: 1; pointer-events: none; background-image: var(--aftc-gridlines), var(--aftc-grad); background-size: 44px 44px, 44px 44px, 100% 100%; transition: opacity .3s linear .1s; }
.aftc-pop.is-open .aftc-pop__bg::after { opacity: 0; transition: opacity .5s var(--aftc-std) .3s; }

@media (max-width: 640px) {
  .aftc-pop { padding-inline: 0; }
  .aftc-pop .aftc-pop__top { padding: 0 1.2rem 0 1.6rem; }
  .aftc-pop .aftc-pop__title { font-size: 1.3rem; white-space: normal; }
  .aftc-pop .aftc-pop__end { gap: 1.4rem; }
  .aftc-pop .aftc-pop__end-k { font-size: 2rem; }
  .aftc-pop .aftc-pop__again { height: 4.8rem; }
}

@media (prefers-reduced-motion: reduce) {
  .aftc.is-in *, .aftc.is-in *::before, .aftc.is-in *::after { animation: none !important; }
  .aftc .aftc__dot { animation: none; }
  .aftc *, .aftc *::before, .aftc *::after, .aftc-pop *, .aftc-pop *::before, .aftc-pop *::after { transition-duration: .01s !important; transition-delay: 0s !important; }
  .aftc-pop .aftc-pop__seam { display: none; }
}
