.chaos-clone-page {
    background: #0e0f1f;
    color: #e8edff;
}

.chaos-clone-page .site-header {
    color: var(--text-dark);
}

.chaos-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(3rem, 7vw, 5.6rem) 0 clamp(2.2rem, 5vw, 4rem);
    text-align: center;
    background:
        radial-gradient(circle at 24% 10%, rgba(124, 247, 255, 0.16), transparent 27rem),
        radial-gradient(circle at 82% 75%, rgba(190, 128, 255, 0.16), transparent 24rem),
        linear-gradient(#111329, #0e0f1f);
}

.chaos-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.32;
    background-image:
        linear-gradient(rgba(114, 125, 169, 0.22) 1px, transparent 1px),
        linear-gradient(90deg, rgba(114, 125, 169, 0.22) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(to bottom, #000, transparent 92%);
}

.chaos-hero .container {
    position: relative;
    z-index: 1;
    max-width: 900px;
}

.chaos-kicker {
    margin-bottom: 0.7rem;
    color: #7cf7ff;
    font: 800 0.78rem/1.2 'Space Grotesk', sans-serif;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.chaos-hero h1 {
    margin-bottom: 0.8rem;
    color: #fff;
    font: 900 clamp(3rem, 8vw, 6rem)/0.95 'Space Grotesk', sans-serif;
    letter-spacing: -0.055em;
    text-shadow: 0 0 35px rgba(124, 247, 255, 0.15);
}

.chaos-hero p:last-child {
    max-width: 700px;
    margin: 0 auto;
    color: #aeb8da;
    font-size: clamp(1rem, 2.2vw, 1.23rem);
}

.chaos-game-section {
    padding: 0 0 clamp(3.5rem, 7vw, 6rem);
}

.chaos-game-container {
    max-width: 1240px;
}

.chaos-game-shell {
    overflow: hidden;
    border: 1px solid #4b5279;
    border-radius: 18px;
    background: #080914;
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.48), 0 0 0 6px rgba(124, 247, 255, 0.035);
}

.chaos-toolbar {
    min-height: 54px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.55rem 0.75rem 0.55rem 1rem;
    border-bottom: 1px solid #333956;
    background: #171a30;
    font-family: 'Space Grotesk', sans-serif;
}

.chaos-toolbar p {
    margin: 0;
    color: #aeb8da;
    font-size: 0.82rem;
}

.chaos-toolbar-actions {
    display: flex;
    gap: 0.55rem;
}

.chaos-toolbar button {
    padding: 0.56rem 0.85rem;
    border: 1px solid #596286;
    border-radius: 8px;
    background: #252a48;
    color: #f3f6ff;
    cursor: pointer;
    font: 700 0.78rem/1 'Space Grotesk', sans-serif;
    transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.chaos-toolbar button:hover {
    border-color: #7cf7ff;
    background: #303757;
    transform: translateY(-1px);
}

.chaos-toolbar button:focus-visible {
    outline: 3px solid rgba(124, 247, 255, 0.45);
    outline-offset: 2px;
}

.chaos-viewport {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #0e0f1f;
}

.chaos-viewport iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #0e0f1f;
    touch-action: none;
}

.chaos-game-shell:fullscreen,
.chaos-game-shell:-webkit-full-screen {
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    border: 0;
    border-radius: 0;
}

.chaos-game-shell:fullscreen .chaos-viewport,
.chaos-game-shell:-webkit-full-screen .chaos-viewport {
    flex: 1;
    min-height: 0;
    aspect-ratio: auto;
}

.chaos-focus-note {
    margin: 0.85rem 0 0;
    color: #7f8aae;
    text-align: center;
    font-size: 0.88rem;
}

.chaos-guide-section {
    padding: clamp(3.8rem, 8vw, 7rem) 0;
    color: #252a44;
    background: #eef2fa;
}

.chaos-guide-heading {
    max-width: 680px;
    margin-bottom: 2.2rem;
}

.chaos-guide-heading h2 {
    margin-bottom: 0.7rem;
    color: #171a30;
    font: 800 clamp(2rem, 4.5vw, 3.25rem)/1.05 'Space Grotesk', sans-serif;
    letter-spacing: -0.035em;
}

.chaos-guide-heading > p:last-child {
    color: #5e6685;
    font-size: 1.05rem;
}

.chaos-guide-grid,
.chaos-details-grid {
    display: grid;
    gap: 1.25rem;
}

.chaos-guide-grid {
    grid-template-columns: repeat(3, 1fr);
    margin-bottom: 1.25rem;
}

.chaos-guide-grid article,
.chaos-detail-card {
    border: 1px solid #d6dceb;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 14px 38px rgba(32, 39, 72, 0.08);
}

.chaos-guide-grid article {
    padding: 1.5rem;
}

.chaos-guide-number {
    display: inline-grid;
    width: 2.35rem;
    height: 2.35rem;
    place-items: center;
    margin-bottom: 1.2rem;
    border-radius: 10px;
    background: #171a30;
    color: #7cf7ff;
    font: 800 0.77rem/1 'Space Grotesk', sans-serif;
}

.chaos-guide-grid h3,
.chaos-detail-card h3 {
    margin-bottom: 0.55rem;
    color: #202540;
    font: 800 1.18rem/1.2 'Space Grotesk', sans-serif;
}

.chaos-guide-grid p {
    margin: 0;
    color: #636b88;
    font-size: 0.94rem;
}

.chaos-details-grid {
    grid-template-columns: 0.95fr 1.05fr;
}

.chaos-detail-card {
    padding: 1.6rem;
}

.chaos-controls {
    margin: 0;
}

.chaos-controls div {
    display: grid;
    grid-template-columns: 9rem 1fr;
    gap: 1rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid #e7eaf2;
}

.chaos-controls div:last-child {
    border-bottom: 0;
}

.chaos-controls dt {
    color: #69718c;
    font-weight: 600;
}

.chaos-controls dd {
    margin: 0;
    color: #292f4e;
    font-weight: 700;
}

.chaos-clone-page kbd {
    display: inline-block;
    min-width: 1.7em;
    padding: 0.13rem 0.38rem;
    border: 1px solid #c8cee0;
    border-bottom-width: 3px;
    border-radius: 5px;
    background: #f7f9fd;
    color: #303653;
    font: 700 0.78em/1.3 'Space Grotesk', sans-serif;
    text-align: center;
}

.chaos-tip-card ul {
    margin: 0;
    padding-left: 1.2rem;
    color: #5e6683;
}

.chaos-tip-card li + li {
    margin-top: 0.65rem;
}

@media (max-width: 780px) {
    .chaos-guide-grid,
    .chaos-details-grid {
        grid-template-columns: 1fr;
    }

    .chaos-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .chaos-toolbar-actions,
    .chaos-toolbar button {
        width: 100%;
    }

    .chaos-toolbar button {
        min-height: 42px;
    }

	.chaos-viewport {
		aspect-ratio: 4 / 3;
	}
}

@media (max-width: 520px) {
    .chaos-hero {
        padding-top: 2.7rem;
    }

    .chaos-game-container {
        padding: 0 10px;
    }

    .chaos-game-shell {
        border-radius: 10px;
    }

    .chaos-toolbar-actions {
        flex-direction: column;
    }

    .chaos-controls div {
        grid-template-columns: 1fr;
        gap: 0.15rem;
    }
}
