/* 때 건너기 (/grammar/infinitive/cross.jsp, 2026-10-18). js/ps2-infinitive-cross.js 가 만드는 화면. 로비 · 한 판(강 캔버스 + 안내) · 결과 */
#main .gi .fe { min-width: 0; --fe-ink: #0f172a; --fe-mute: #64748b; --fe-line: #e2e8f0; --fe-accent: #2563eb; margin: 0 0 28px; }
#main .gi .fe .fe-view[hidden] { display: none; }

/* 로비 */
#main .gi .fe .fe-hero { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 22px; align-items: center; padding: 22px; border-radius: 22px; color: #fff;
    background: radial-gradient(120% 90% at 50% 100%, #0369a1 0%, #082f49 58%, #04121f 100%); box-shadow: 0 30px 60px -36px rgba(2, 6, 23, .9); overflow: hidden; }
#main .gi .fe .fe-hero__art { position: relative; height: 240px; border-radius: 16px; overflow: hidden; background: #7cc95f; }
#main .gi .fe .fe-hero__bank { position: absolute; left: 0; right: 0; height: 34%; background: repeating-linear-gradient(90deg, #86d36a 0 12.5%, #7cc95f 12.5% 25%); }
#main .gi .fe .fe-hero__bank.b1 { bottom: 0; }
#main .gi .fe .fe-hero__bank.b2 { top: 0; }
#main .gi .fe .fe-hero__river { position: absolute; left: 0; right: 0; top: 34%; height: 32%; overflow: hidden; background: linear-gradient(#38bdf8, #0ea5e9);
    box-shadow: inset 0 3px 0 #5aa845, inset 0 -3px 0 #5aa845; }
#main .gi .fe .fe-hero__river::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(100deg, transparent 0 34px, rgba(255, 255, 255, .25) 34px 40px, transparent 40px 70px); animation: fe-flow 2.4s linear infinite; }
@keyframes fe-flow { to { background-position: 70px 0; } }
#main .gi .fe .fe-hero__river i { position: absolute; top: 18%; height: 64%; display: grid; place-items: center; padding: 0 16px; border-radius: 999px; font-style: normal; font-weight: 800; font-size: 13px; color: var(--fe-ink); white-space: nowrap;
    background: linear-gradient(#b7793f, #8b5a2b 55%, #5c3a1a); box-shadow: 0 6px 10px -6px rgba(2, 6, 23, .6); animation: fe-log 7.5s linear infinite; }
#main .gi .fe .fe-hero__river i::before { content: ""; position: absolute; inset: 22% 10px; border-radius: 8px; background: rgba(255, 255, 255, .95); z-index: -1; }
#main .gi .fe .fe-hero__river i { isolation: isolate; }
#main .gi .fe .fe-hero__river i.l1 { animation-delay: 0s; }
#main .gi .fe .fe-hero__river i.l2 { animation-delay: -2.5s; }
#main .gi .fe .fe-hero__river i.l3 { animation-delay: -5s; }
#main .gi .fe .fe-hero__river i.is-ok::before { animation: fe-ok 7.5s linear infinite; animation-delay: -2.5s; }
@keyframes fe-log { from { left: -32%; } to { left: 102%; } }
@keyframes fe-ok { 0%, 38% { background: rgba(255, 255, 255, .95); } 44%, 62% { background: #bbf7d0; box-shadow: 0 0 0 2px #16a34a; } 68%, 100% { background: rgba(255, 255, 255, .95); } }
#main .gi .fe .fe-hero__chick { position: absolute; left: calc(50% - 15px); bottom: 10%; width: 30px; height: 28px; border-radius: 6px; background: linear-gradient(#fde68a 0 38%, #facc15 38%);
    box-shadow: inset 0 -3px 0 rgba(161, 98, 7, .35); animation: fe-hop 1.6s ease-in-out infinite; }
#main .gi .fe .fe-hero__chick::before { content: ""; position: absolute; left: 7px; top: 12px; width: 4px; height: 4px; background: #0f172a; box-shadow: 12px 0 0 #0f172a; }
#main .gi .fe .fe-hero__chick::after { content: ""; position: absolute; left: 12px; top: 18px; width: 6px; height: 4px; background: #f97316; }
@keyframes fe-hop { 0%, 60%, 100% { transform: translateY(0) scale(1, 1); } 70% { transform: translateY(0) scale(1.1, .9); } 80% { transform: translateY(-16px) scale(.92, 1.1); } 90% { transform: translateY(0) scale(1.08, .92); } }
#main .gi .fe .fe-hero__line { position: absolute; left: 0; right: 0; top: 8px; text-align: center; font-weight: 800; font-size: 13.5px; color: #14532d; text-shadow: 0 1px 0 rgba(255, 255, 255, .5); }
#main .gi .fe .fe-hero__line u { text-decoration: none; padding: 0 6px; border-radius: 6px; background: rgba(255, 255, 255, .75); color: #a16207; }
#main .gi .fe .fe-hero__txt h2 { margin: 0 0 8px; font-size: clamp(20px, 2.6vw, 26px); line-height: 1.35; letter-spacing: -0.02em; color: #fff; }
#main .gi .fe .fe-hero__txt p { margin: 0 0 12px; font-size: 15px; line-height: 1.7; color: rgba(255, 255, 255, .84); }
#main .gi .fe .fe-how { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 13.5px; color: rgba(255, 255, 255, .86); }
#main .gi .fe .fe-how kbd, #main .gi .fe .fe-tip kbd { display: inline-block; min-width: 22px; padding: 1px 7px; border-radius: 6px; border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.12);
    font-weight: 700; font-size: 12px; line-height: 1.6; font-family: inherit; color: #fff; text-align: center; }
#main .gi .fe .fe-levels { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; margin: 16px 0 10px; }
#main .gi .fe .fe-level { display: grid; align-content: start; gap: 8px; padding: 16px; border: 1px solid var(--fe-line); border-radius: 16px; background: #fff; box-shadow: 0 10px 24px rgba(15, 23, 42, .06); }
#main .gi .fe .fe-level.is-locked { opacity: .62; }
#main .gi .fe .fe-level h3 { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin: 0; font-size: 16px; }
#main .gi .fe .fe-level h3 i { font-style: normal; color: #f59e0b; letter-spacing: 1px; font-size: 14px; }
#main .gi .fe .fe-level p { margin: 0; font-size: 13.5px; line-height: 1.6; color: var(--fe-mute); }
#main .gi .fe .fe-level__meta { display: flex; gap: 8px; flex-wrap: wrap; font-size: 12.5px; color: var(--fe-mute); }
#main .gi .fe .fe-level__box { padding: 0 8px; border-radius: 999px; background: #fef3c7; color: #92400e; font-weight: 700; }
#main .gi .fe .fe-level .gi-btn { justify-self: start; }
#main .gi .fe .fe-foot { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; font-size: 13px; color: var(--fe-mute); }
#main .gi .fe .fe-tool { padding: 6px 12px; border: 1px solid var(--fe-line); border-radius: 999px; background: #fff; font-weight: 700; font-size: 13px; line-height: 1.4; font-family: inherit; color: var(--fe-ink); cursor: pointer; }

/* 한 판 */
#main .gi .fe .fe-stage { display: grid; gap: 10px; }
#main .gi .fe .fe-top { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; font-size: 14px; color: var(--fe-mute); }
#main .gi .fe .fe-top b { font-size: 18px; color: var(--fe-ink); font-variant-numeric: tabular-nums; display: inline-block; }
#main .gi .fe .fe-top b.is-pop { animation: fe-pop .45s ease; }
@keyframes fe-pop { 30% { transform: scale(1.35); color: #16a34a; } }
#main .gi .fe .fe-combo.is-hot b { color: #ea580c; }
#main .gi .fe .fe-combo.is-hot::after { content: " 🔥"; }
#main .gi .fe .fe-hearts i { font-style: normal; color: #ef4444; font-size: 18px; margin-right: 2px; }
#main .gi .fe .fe-hearts i.is-off { color: #cbd5e1; }
#main .gi .fe .fe-timingn { padding: 1px 9px; border-radius: 999px; background: #fef9c3; color: #a16207; font-weight: 800; font-variant-numeric: tabular-nums; }
#main .gi .fe .fe-wave { margin-left: auto; font-weight: 700; }
#main .gi .fe .fe-q { min-height: 74px; padding: 12px 16px; border-radius: 16px; background: #0f172a; color: #fff; text-align: center; }
#main .gi .fe .fe-sent { margin: 0; font-weight: 800; font-size: clamp(17px, 2.4vw, 23px); line-height: 1.45; font-family: inherit; letter-spacing: -0.01em; }
#main .gi .fe .fe-sent mark { display: inline-block; min-width: 86px; padding: 0 10px; border-radius: 8px; background: rgba(255,255,255,.14); color: #fde68a; border: 1px dashed rgba(253, 230, 138, .6); }
#main .gi .fe .fe-sent mark.is-ok { background: #16a34a; color: #fff; border-style: solid; border-color: #16a34a; }
#main .gi .fe .fe-ko { display: block; margin-top: 4px; font-size: 14px; color: rgba(255,255,255,.78); }
#main .gi .fe .fe-ko--hint { color: rgba(255,255,255,.5); }
#main .gi .fe .fe-ko--why { color: #86efac; font-weight: 700; }
#main .gi .fe .fe-world-wrap { position: relative; display: grid; justify-items: center; }
#main .gi .fe .fe-world { display: block; width: 100%; border-radius: 18px; touch-action: none; cursor: pointer; box-shadow: 0 30px 60px -30px rgba(2, 6, 23, .6); user-select: none; -webkit-user-select: none; }
#main .gi .fe .fe-overlay { position: absolute; inset: 0; display: grid; place-items: center; padding: 12px; background: rgba(2, 6, 23, .45); border-radius: 18px; backdrop-filter: blur(2px); }
#main .gi .fe .fe-overlay[hidden] { display: none; }
#main .gi .fe .fe-card { max-height: 100%; overflow-y: auto; width: min(560px, 100%); padding: 16px 18px; border-radius: 16px; background: #fff; color: var(--fe-ink); box-shadow: 0 30px 60px -20px rgba(2, 6, 23, .8); animation: fe-card .25s ease; }
@keyframes fe-card { from { transform: translateY(14px); opacity: 0; } }
#main .gi .fe .fe-card .fe-sent, #main .gi .fe .fe-wrong .fe-sent { color: var(--fe-ink); font-size: 18px; text-align: left; }
#main .gi .fe .fe-card .fe-sent mark { background: #e2e8f0; color: var(--fe-ink); border-color: #cbd5e1; }
#main .gi .fe .fe-card .fe-sent mark.is-ok, #main .gi .fe .fe-wrong .fe-sent mark.is-ok { background: #16a34a; color: #fff; border-color: #16a34a; }
#main .gi .fe .fe-card__tag { display: inline-block; margin-bottom: 6px; padding: 2px 10px; border-radius: 999px; background: #fee2e2; color: #b91c1c; font-size: 12.5px; font-weight: 800; }
#main .gi .fe .fe-card__ko { margin: 4px 0 0; font-size: 14px; color: var(--fe-mute); }
#main .gi .fe .fe-card__why { margin: 8px 0 0; padding: 10px 12px; border-radius: 10px; background: #f0fdf4; color: #14532d; font-size: 15px; line-height: 1.6; font-weight: 600; }
#main .gi .fe .fe-card__mine { margin: 8px 0 0; font-size: 13.5px; color: #b91c1c; }
#main .gi .fe .fe-card__row { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; }
#main .gi .fe .fe-card__link { font-size: 13.5px; font-weight: 700; color: var(--fe-accent); }
#main .gi .fe .fe-ctl { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: stretch; }
#main .gi .fe .fe-ctl__lanes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
#main .gi .fe .fe-ctl__lanes button { position: relative; display: grid; place-items: center; min-height: 52px; padding: 4px 8px; border: 1px solid var(--fe-line); border-top: 4px solid #a16207; border-radius: 12px; background: #fff;
    font-weight: 700; font-size: 15px; line-height: 1.3; font-family: inherit; color: var(--fe-ink); text-align: center; cursor: pointer; touch-action: manipulation; overflow-wrap: anywhere; }
#main .gi .fe .fe-ctl__lanes button small { position: absolute; left: 6px; top: 4px; font-size: 10.5px; font-weight: 800; color: var(--fe-mute); }
#main .gi .fe .fe-ctl__lanes button:active { background: #f1f5f9; }
#main .gi .fe .fe-ctl__lanes button.is-wait { border-color: #f59e0b; box-shadow: 0 0 0 3px rgba(245, 158, 11, .35); animation: fe-wait .8s ease-in-out infinite; }
#main .gi .fe .fe-ctl__lanes button.is-wait::after { content: "통나무를 기다리는 중"; position: absolute; bottom: 3px; left: 0; right: 0; font-size: 10px; font-weight: 800; color: #b45309; }
@keyframes fe-wait { 50% { background: #fef3c7; } }
#main .gi .fe .fe-ctl__pad { display: grid; grid-template-columns: 44px 76px 44px; gap: 6px; }
#main .gi .fe .fe-ctl__move, #main .gi .fe .fe-ctl__hop { min-height: 52px; border: 0; border-radius: 12px; font-weight: 800; font-size: 15px; line-height: 1.2; font-family: inherit; cursor: pointer; touch-action: manipulation; user-select: none; -webkit-user-select: none; }
#main .gi .fe .fe-ctl__move { background: #e2e8f0; color: var(--fe-ink); }
#main .gi .fe .fe-ctl__hop { background: linear-gradient(135deg, #38bdf8, #0284c7); color: #fff; box-shadow: 0 8px 18px -8px rgba(2, 132, 199, .8); }
#main .gi .fe .fe-ctl__hop:active, #main .gi .fe .fe-ctl__move:active { transform: translateY(1px); filter: brightness(.95); }
#main .gi .fe .fe-tip { margin: 0; font-size: 12.5px; color: var(--fe-mute); text-align: center; }
#main .gi .fe .fe-tip kbd { border-color: var(--fe-line); background: #f1f5f9; color: var(--fe-ink); }

/* 결과 */
#main .gi .fe .fe-result__head { padding: 22px; border-radius: 20px; color: #fff; text-align: center; background: linear-gradient(135deg, #0f172a, #1e293b); }
#main .gi .fe .fe-result__head.is-win { background: radial-gradient(120% 100% at 50% 0, #0369a1 0%, #082f49 70%); }
#main .gi .fe .fe-result__tag { display: inline-block; padding: 3px 12px; border-radius: 999px; background: rgba(255,255,255,.14); font-size: 13px; font-weight: 800; }
#main .gi .fe .fe-result__score { margin: 8px 0 0; }
#main .gi .fe .fe-result__score b { font-size: clamp(44px, 7vw, 64px); font-weight: 900; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
#main .gi .fe .fe-result__score small { margin-left: 4px; font-size: 16px; color: rgba(255,255,255,.7); }
#main .gi .fe .fe-result__stars { font-size: 26px; color: #fbbf24; letter-spacing: 3px; }
#main .gi .fe .fe-result__best { display: inline-block; margin: 8px 0 0; padding: 3px 12px; border-radius: 999px; background: rgba(255,255,255,.1); font-size: 13.5px; font-weight: 800; color: rgba(255,255,255,.85); }
#main .gi .fe .fe-result__best.is-new { background: linear-gradient(135deg, #f59e0b, #ea580c); color: #fff; box-shadow: 0 0 22px rgba(245, 158, 11, .55); animation: fe-best 1.6s ease-in-out infinite; }
@keyframes fe-best { 50% { transform: scale(1.06); } }
#main .gi .fe .fe-result__row { display: grid; grid-template-columns: repeat(auto-fit, minmax(92px, 1fr)); gap: 8px; margin-top: 14px; }
#main .gi .fe .fe-result__row div { padding: 8px; border-radius: 12px; background: rgba(255,255,255,.08); }
#main .gi .fe .fe-result__row small { display: block; font-size: 12px; color: rgba(255,255,255,.7); }
#main .gi .fe .fe-result__row b { font-size: 18px; }
#main .gi .fe .fe-result__note { margin: 12px 0 0; font-size: 14px; color: #fde68a; }
#main .gi .fe .fe-result__sec { margin-top: 18px; }
#main .gi .fe .fe-result__sec h3 { margin: 0 0 8px; font-size: 17px; }
#main .gi .fe .fe-wrong { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
#main .gi .fe .fe-wrong li { display: grid; gap: 4px; padding: 12px 14px; border: 1px solid var(--fe-line); border-left: 4px solid #ef4444; border-radius: 12px; background: #fff; }
#main .gi .fe .fe-wrong .fe-sent { font-size: 16px; }
#main .gi .fe .fe-wrong__ko { font-size: 13.5px; color: var(--fe-mute); }
#main .gi .fe .fe-wrong__why { font-size: 14px; color: #14532d; font-weight: 600; }
#main .gi .fe .fe-wrong__link { justify-self: start; font-size: 13px; font-weight: 700; color: var(--fe-accent); }
#main .gi .fe .fe-skills { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 14px; }
#main .gi .fe .fe-skills li { display: flex; justify-content: space-between; gap: 10px; padding: 8px 12px; border-radius: 10px; background: #f1f5f9; }
#main .gi .fe .fe-skills b { color: var(--fe-ink); }
#main .gi .fe .fe-result__cta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }

@media (max-width: 760px) {
    #main .gi .fe .fe-hero { padding: 16px; }
    #main .gi .fe .fe-hero__art { height: 210px; }
    #main .gi .fe .fe-ctl { grid-template-columns: 1fr; }
    #main .gi .fe .fe-ctl__pad { grid-template-columns: 1fr 1.6fr 1fr; }
    #main .gi .fe .fe-ctl__lanes button { font-size: 13px; padding: 4px; }
    #main .gi .fe .fe-card { padding: 12px 14px; }
    #main .gi .fe .fe-card .fe-sent { font-size: 16px; }
    #main .gi .fe .fe-card__why { font-size: 14px; padding: 8px 10px; }
    #main .gi .fe .fe-tip { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    #main .gi .fe .fe-hero__river::before, #main .gi .fe .fe-hero__river i, #main .gi .fe .fe-hero__river i::before, #main .gi .fe .fe-hero__chick, #main .gi .fe .fe-result__best { animation: none; }
}
