.fsr-gate-ask-ai-wrap {
    margin: 0 0 36px;
    max-width: 850px;
    font-family: var(--article-ui);
}

.fsr-gate-ask-ai-wrap .fsr-gate-ask-ai__trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 18px 22px;
    border: 1px solid #84929e;
    border-inline-start: 3px solid #e1e7ec;
    border-radius: 14px;
    background: #20262d linear-gradient(115deg,#0c1015 0%,#242d37 16%,#53606d 25%,#252e38 34%,#151b22 72%,#0b0f14 100%);
    box-shadow: inset 0 1px 0 #ffffff5c,inset 0 -1px 0 #0009;
    color: #f1f4f6;
    cursor: pointer;
    list-style: none;
    text-decoration: none;
}

.fsr-gate-ask-ai > summary::-webkit-details-marker { display: none; }
.fsr-gate-ask-ai__title { display: block; font: 400 24px/1.2 var(--article-display); }
.fsr-gate-ask-ai__description { display: block; margin-top: 5px; color: #d5dde3; font-size: 14px; line-height: 1.6; }
.fsr-gate-ask-ai__open {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 46px;
    padding: 10px 16px;
    border: 1px solid #84929e;
    border-radius: 10px;
    background: #172029 linear-gradient(160deg,#3c4855,#172029);
    font-size: 14px;
    font-weight: 600;
}

.fsr-gate-ask-ai__trigger:hover .fsr-gate-ask-ai__open { background: #303d4b; }
.fsr-gate-ask-ai-wrap :is(summary, a):focus-visible { outline: 2px solid var(--article-accent); outline-offset: 3px; }
.fsr-gate-ask-ai[open] .fsr-gate-ask-ai__open span { transform: rotate(90deg); }

@media (min-width: 64rem) {
    main#article > article:has(> .fsr-gate-outline) > .fsr-gate-ask-ai-wrap { grid-column: 1 / -1; }
    main#article > article > .fsr-gate-ask-ai-wrap + .fsr-gate-outline { grid-row: 4; }
}

@media (max-width: 600px) {
    .fsr-gate-ask-ai-wrap .fsr-gate-ask-ai__trigger { align-items: stretch; flex-direction: column; gap: 12px; padding: 16px; }
}

@media print {
    .fsr-gate-ask-ai-wrap { display: none; }
}

.fsr-gate-with-header > .fsr-gate-site-header {
    border-bottom-color: #33483e18;
}

@media (prefers-color-scheme: dark) {
    .fsr-gate-with-header > .fsr-gate-site-header { border-bottom-color: #c8d5c814; }
}

.fsr-gate-site-header .fsr-gate-wordmark,
.fsr-gate-site-header .fsr-gate-header-nav > a { text-decoration: none; }

.fsr-gate-site-header .fsr-gate-header-inner { min-height: 92px; }

.fsr-gate-with-header .fsr-gate-article-hero h1 {
    max-width: 850px;
    font-size: clamp(36px, 4.2vw, 62px);
    line-height: 1.08;
    letter-spacing: -.045em;
    text-wrap: balance;
}

.fsr-gate-with-header .fsr-gate-article-meta {
    color: var(--fsr-gate-muted);
    font-size: 12px;
    line-height: 1.8;
}

.fsr-gate-ask-ai-wrap .fsr-gate-ai-opener { width: 100%; text-align: start; }
.fsr-gate-ask-ai-wrap .fsr-gate-ai-opener:focus-visible,
.fsr-gate-ai-drawer :is(a, button, summary):focus-visible,
.fsr-gate-ai-launch:focus-visible { outline: 2px solid #b8e2d4; outline-offset: 3px; }
.fsr-gate-ai-fallback { display: none; }

.fsr-gate-ai-launch, .fsr-gate-ai-drawer {
    color: #f1f4f6;
    border: 1px solid #84929e;
    color-scheme: dark;
    --fsr-ai-metal: linear-gradient(115deg,#0c1015 0%,#242d37 16%,#53606d 25%,#252e38 34%,#151b22 72%,#0b0f14 100%);
}

.fsr-gate-ai-launch {
    position: fixed;
    z-index: 50;
    inset: auto max(24px,env(safe-area-inset-right)) calc(22px + env(safe-area-inset-bottom)) auto;
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 64px;
    padding: 13px 20px;
    border-radius: 16px;
    background: #20262d var(--fsr-ai-metal);
    box-shadow: inset 0 1px 0 #ffffff70,inset 0 -1px 0 #000b,0 10px 32px #0006;
    text-align: start;
    font-family: var(--article-ui);
}
.fsr-gate-ai-launch strong, .fsr-gate-ai-launch small { display: block; }
.fsr-gate-ai-launch strong { font-size: 17px; }
.fsr-gate-ai-launch small { font-size: 11px; margin-top: 3px; }

.fsr-gate-ai-drawer {
    position: fixed;
    inset: auto max(24px,env(safe-area-inset-right)) calc(102px + env(safe-area-inset-bottom)) auto;
    width: min(420px,calc(100vw - 32px));
    max-height: min(680px,calc(100dvh - 124px));
    margin: 0;
    padding: 0;
    overflow: auto;
    overscroll-behavior: contain;
    border-radius: 18px;
    background: #20262d;
    box-shadow: inset 0 1px 0 #ffffff5c,0 18px 56px #0008;
}

.fsr-gate-ai-drawer .fsr-gate-ai-drawer__header {
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 18px;
    border-bottom: 1px solid #84929e;
    background: #20262d var(--fsr-ai-metal);
}

.fsr-gate-ai-drawer__header h2 { margin: 0; color: #f1f4f6; font: 400 28px/1.2 var(--article-display); }
.fsr-gate-ai-close {
    display: grid;
    flex: 0 0 44px;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid #84929e;
    border-radius: 50%;
    background: #2a3037;
    color: #f1f4f6;
    font: 400 24px/1 var(--article-ui);
}
.fsr-gate-ai-drawer.entry-content .fsr-mg-dispatch {
    width: auto;
    max-width: none;
    margin: 12px;
    padding: 16px 12px;
    background: transparent;
    color: #f1f4f6;
    --fsr-mg-graphite: #f1f4f6;
    --fsr-mg-muted: #d5dde3;
}
.fsr-gate-ai-drawer.entry-content .fsr-mg-dispatch__list { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
.fsr-gate-ai-drawer.entry-content .fsr-mg-dispatch__route {
    min-height: 66px;
    padding: 12px 10px;
    border-radius: 8px;
    color: #f1f4f6;
    background: #2a3037 linear-gradient(160deg,#38424d,#252c34 55%,#1d232a);
    box-shadow: inset 0 0 0 1px #84929e,inset 0 2px 0 #ffffff18;
}
.fsr-gate-ai-drawer.entry-content .fsr-mg-dispatch__route:is(:hover,:focus-visible) { background: #363f49; }
.fsr-gate-ai-drawer.entry-content .fsr-mg-dispatch__hint { color: #d5dde3; }
.fsr-gate-ai-drawer.entry-content :is(.fsr-mg-dispatch__note,.fsr-mg-dispatch__twin) { color: #d5dde3; overflow-wrap: anywhere; }

@media (max-width: 600px) {
    .fsr-gate-site-header .fsr-gate-header-inner { min-height: 78px; }
    .fsr-gate-site-header .fsr-gate-wordmark { font-size: 20px; }
    .fsr-gate-ai-launch { inset: auto 14px calc(14px + env(safe-area-inset-bottom)) auto; min-height: 56px; padding: 10px 15px; }
    .fsr-gate-ai-drawer { inset: auto 10px calc(82px + env(safe-area-inset-bottom)) auto; width: calc(100vw - 20px); max-height: calc(100dvh - 94px); }
}
@supports not selector(:popover-open) {
    .fsr-gate-ask-ai-wrap .fsr-gate-ai-opener, .fsr-gate-ai-launch, .fsr-gate-ai-close { display: none; }
    .fsr-gate-ai-fallback { display: inline-block; }
    .fsr-gate-ai-drawer { position: static; width: 100%; max-height: none; margin: 16px 0; }
}
@media print {
    .fsr-gate-ai-launch, .fsr-gate-ai-drawer { display: none !important; }
}
