:root {
            --primary: #6490d7;
            --primary-dark: #4b73b5;
            --primary-light: #e8f0fe;
            --accent: #ff7597;
            --accent-dark: #e05376;
            --accent-yellow: #ffd166;
            --bg-base: #f0f5fc;
            --text-dark: #2b3a55;
            --text-muted: #62728d;
            --white: #ffffff;
            --card-shadow: 0 4px 20px rgba(100, 144, 215, 0.12);
            --font-main: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
        }

        html { scroll-behavior: smooth; }

        * {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
            overflow-wrap: anywhere;
            word-break: break-word;
        }

        body {
            font-family: var(--font-main);
            background-color: var(--bg-base);
            color: var(--text-dark);
            line-height: 1.5;
            position: relative;
            overflow-x: hidden;
            -webkit-font-smoothing: antialiased;
            text-rendering: optimizeSpeed;
        }

        #pattern-bg {
            position: fixed;
            top: 0; left: 0;
            width: 100vw; height: 100vh;
            z-index: -1;
            pointer-events: none;
            opacity: 0.18;
        }

        h1, h2, h3, h4 {
            font-family: var(--font-main);
            font-weight: 800;
            letter-spacing: -0.02em;
        }

        /* Prevent grid item overflow */
        .feature-grid > *,
        .flow-grid > *,
        .profile-grid > *,
        .two-col-grid > *,
        .rules-layout > *,
        .status-grid > *,
        .tool-grid > *,
        .support-grid > * {
            min-width: 0;
        }

        /* DOCKED TOP BAR */
        header {
            position: sticky;
            top: 0;
            z-index: 1000;
            max-width: 1150px;
            margin: 0 auto;
            background: rgba(255, 255, 255, 0.97);
            border-radius: 0 0 20px 20px;
            box-shadow: 0 4px 16px rgba(100, 144, 215, 0.1);
            border: 1px solid rgba(255, 255, 255, 0.8);
            border-top: none;
            contain: layout style;
        }

        nav {
            padding: 0.75rem 1.75rem;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .logo {
            font-size: 1.7rem;
            font-weight: 800;
            color: var(--primary);
            text-decoration: none;
        }

        .nav-links {
            display: flex;
            list-style: none;
            gap: 1.5rem;
            align-items: center;
        }

        .nav-links a {
            text-decoration: none;
            color: var(--text-dark);
            font-weight: 700;
            font-size: 0.95rem;
            transition: color 0.15s ease;
        }

        .nav-links a:hover, .nav-links a.active { color: var(--primary); }

        .nav-btn-support {
            position: relative;
            background: var(--accent);
            color: var(--white) !important;
            padding: 0.45rem 1.1rem;
            border-radius: 20px;
            font-weight: 800;
            text-decoration: none;
            font-size: 0.9rem;
            transition: transform 0.2s ease, background-color 0.2s ease;
            display: inline-block;
            box-shadow: 0 4px 12px rgba(255, 117, 151, 0.3);
        }

        .nav-btn-support::after {
            content: '';
            position: absolute;
            inset: 0;
            border-radius: 20px;
            box-shadow: 0 0 16px rgba(255, 117, 151, 0.8);
            opacity: 0;
            animation: glow-pulse-perf 2s infinite alternate ease-in-out;
            pointer-events: none;
        }

        .nav-btn-support:hover {
            background: var(--accent-dark);
            transform: translateY(-2px);
        }

        @keyframes glow-pulse-perf {
            0% { opacity: 0.1; }
            100% { opacity: 0.9; }
        }

        .main-container {
            max-width: 1150px;
            margin: 2rem auto;
            padding: 2.5rem;
            background: var(--white);
            border-radius: 24px;
            box-shadow: var(--card-shadow);
            border: 1px solid rgba(255, 255, 255, 0.8);
            contain: layout style paint;
        }

        /* DEMO BANNER */
        .demo-banner {
            display: flex;
            align-items: center;
            gap: 1.25rem;
            background: linear-gradient(135deg, var(--primary-light) 0%, #fff0f5 100%);
            border: 2px solid var(--accent);
            border-radius: 18px;
            padding: 1.25rem 1.5rem;
            margin-bottom: 2.25rem;
        }

        .demo-flag {
            background: var(--accent);
            color: var(--white);
            font-weight: 800;
            font-size: 0.9rem;
            padding: 0.4rem 0.9rem;
            border-radius: 20px;
            white-space: nowrap;
        }

        .demo-banner p {
            font-size: 0.97rem;
            font-weight: 600;
            color: var(--text-dark);
            line-height: 1.6;
        }

        /* PAGE HEAD */
        .page-hero {
            padding-bottom: 3rem;
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 2.5rem;
            align-items: center;
            border-bottom: 2px solid var(--primary-light);
        }

        .page-title {
            font-size: 3rem;
            line-height: 1.12;
            margin-bottom: 1rem;
        }

        .btn-primary {
            background: var(--primary);
            color: var(--white);
            padding: 0.85rem 1.75rem;
            border-radius: 30px;
            text-decoration: none;
            font-weight: 800;
            font-size: 1.05rem;
            box-shadow: 0 4px 12px rgba(100, 144, 215, 0.25);
            transition: transform 0.2s ease, background-color 0.2s ease;
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
        }

        .btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); }

        .btn-secondary {
            background: var(--bg-base);
            color: var(--text-dark);
            border: 2px solid var(--primary-light);
            padding: 0.85rem 1.5rem;
            border-radius: 30px;
            text-decoration: none;
            font-weight: 800;
            font-size: 1rem;
            transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease;
        }

        .btn-secondary:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-2px); }

        .cta-group { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 1.5rem; }

        .hero-media { position: relative; }

        .hero-frame {
            position: relative;
            background: var(--bg-base);
            border-radius: 20px;
            padding: 0.75rem;
            border: 2px solid var(--primary-light);
            transform: rotate(1deg);
            transition: transform 0.3s ease;
        }

        .hero-frame:hover { transform: rotate(0deg) scale(1.01); }

        .main-preview-img {
            width: 100%;
            height: 380px;
            object-fit: cover;
            border-radius: 14px;
            display: block;
            background-color: var(--primary-light);
        }

        .floating-card-tag {
            position: absolute;
            background: #ffffff;
            padding: 0.75rem 1.1rem;
            border-radius: 14px;
            box-shadow: 0 4px 16px rgba(0,0,0,0.06);
            font-weight: 800;
            font-size: 0.9rem;
            color: var(--text-dark);
            border: 1px solid var(--primary-light);
            z-index: 10;
            bottom: -15px;
            left: -15px;
            transform: rotate(-3deg);
        }

        /* SHARED SECTION FURNITURE */
        .section {
            padding: 3rem 0;
            border-bottom: 2px solid var(--primary-light);
            scroll-margin-top: 90px;
        }

        .section:last-of-type { border-bottom: none; }

        .section-title { font-size: 2.2rem; color: var(--primary); margin-bottom: 0.3rem; }

        .section-desc {
            color: var(--text-muted);
            font-size: 1.05rem;
            font-weight: 600;
            max-width: 62ch;
        }

        .prose p {
            color: var(--text-muted);
            font-size: 1rem;
            line-height: 1.7;
            max-width: 68ch;
            margin-top: 1rem;
        }

        .subhead {
            font-size: 1.25rem;
            margin-top: 1.75rem;
            margin-bottom: 0.2rem;
            color: var(--text-dark);
        }

        /* TWO COLUMN SECTION (ORIGIN) */
        .two-col-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 2.5rem;
            margin-top: 1.5rem;
            align-items: flex-start;
        }

        .origin-media {
            background: var(--bg-base);
            border: 2px solid var(--primary-light);
            border-radius: 18px;
            padding: 0.75rem;
            margin-top: 0.2rem;
        }

        .origin-media img {
            width: 100%;
            height: 340px;
            object-fit: cover;
            border-radius: 12px;
            display: block;
            background: var(--primary-light);
        }

        /* SUBTLE / MINOR TAGS */
        .tag-cloud-subtle {
            list-style: none;
            display: flex;
            flex-wrap: wrap;
            gap: 0.35rem;
            justify-content: center;
            max-width: 700px;
            margin: 2.5rem auto 0 auto;
            opacity: 0.75;
        }

        .tag-subtle {
            background: var(--bg-base);
            color: var(--text-muted);
            font-weight: 600;
            font-size: 0.75rem;
            padding: 0.2rem 0.6rem;
            border-radius: 12px;
            border: 1px solid var(--primary-light);
        }

        .tag-subtle.tag-accent { background: rgba(255, 117, 151, 0.1); color: var(--accent-dark); border-color: rgba(255, 117, 151, 0.2); }
        .tag-subtle.tag-warn { background: rgba(255, 209, 102, 0.15); color: #8a6d1b; border-color: rgba(255, 209, 102, 0.3); }

        /* CHARACTER PROFILE */
        .profile-grid {
            display: grid;
            grid-template-columns: 300px 1fr;
            gap: 2rem;
            margin-top: 1.75rem;
            align-items: start;
        }

        .profile-gallery {
            display: flex;
            flex-direction: column;
            gap: 1.25rem;
        }

        .profile-portrait {
            background: var(--bg-base);
            border: 2px solid var(--primary-light);
            border-radius: 18px;
            padding: 0.75rem;
        }

        .profile-portrait img {
            width: 100%;
            height: 340px;
            object-fit: cover;
            border-radius: 12px;
            display: block;
            background: var(--primary-light);
        }

        .pull-quote {
            border-left: 4px solid var(--accent);
            background: linear-gradient(135deg, var(--primary-light) 0%, #fff0f5 100%);
            border-radius: 0 14px 14px 0;
            padding: 1.1rem 1.4rem;
            font-size: 1.05rem;
            font-weight: 700;
            margin-top: 1.5rem;
            max-width: 60ch;
        }

        .pull-quote cite {
            display: block;
            font-style: normal;
            font-weight: 700;
            font-size: 0.85rem;
            color: var(--text-muted);
            margin-top: 0.4rem;
        }

        /* FEATURES */
        .feature-grid {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 1.25rem;
            margin-top: 1.75rem;
        }

        .feature-card {
            background: var(--bg-base);
            border-radius: 18px;
            padding: 1.5rem;
            border: 2px solid var(--primary-light);
        }

        .feature-card.is-headline {
            grid-column: 1 / -1;
            background: linear-gradient(135deg, var(--primary-light) 0%, #fff0f5 100%);
            border-color: rgba(100, 144, 215, 0.25);
        }

        .feature-label {
            font-size: 0.78rem;
            font-weight: 800;
            color: var(--accent);
            margin-bottom: 0.3rem;
        }

        .feature-title { font-size: 1.3rem; margin-bottom: 0.5rem; }

        .feature-text {
            color: var(--text-muted);
            font-size: 0.95rem;
            line-height: 1.65;
            max-width: 100%;
        }

        /* FOUR-SCREEN FLOW */
        .flow-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 1.25rem;
            margin-top: 1.75rem;
        }

        .flow-card {
            background: var(--bg-base);
            border-radius: 18px;
            padding: 1.5rem 1.25rem;
            border: 2px solid var(--primary-light);
        }

        .flow-step {
            width: 44px; height: 44px;
            border-radius: 12px;
            background: var(--primary);
            color: var(--white);
            font-weight: 800;
            font-size: 1.15rem;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-bottom: 1rem;
        }

        .flow-card:nth-child(2) .flow-step { background: var(--primary-dark); }
        .flow-card:nth-child(3) .flow-step { background: var(--accent); }
        .flow-card:nth-child(4) .flow-step { background: var(--accent-yellow); color: var(--text-dark); }

        .flow-title { font-size: 1.2rem; margin-bottom: 0.5rem; }

        .flow-text { color: var(--text-muted); font-size: 0.92rem; line-height: 1.6; }

        /* RULES */
        .rules-layout {
            display: grid;
            grid-template-columns: 1.4fr 1fr;
            gap: 2rem;
            margin-top: 1.75rem;
            align-items: start;
        }

        .rules-list { list-style: none; counter-reset: rule; }

        .rules-list li {
            counter-increment: rule;
            position: relative;
            padding: 0.9rem 0 0.9rem 3rem;
            border-bottom: 1px solid var(--primary-light);
            color: var(--text-muted);
            font-size: 0.97rem;
            line-height: 1.6;
        }

        .rules-list li:last-child { border-bottom: none; }

        .rules-list li::before {
            content: counter(rule);
            position: absolute;
            left: 0; top: 0.85rem;
            width: 2rem; height: 2rem;
            border-radius: 8px;
            background: var(--primary-light);
            color: var(--primary-dark);
            font-weight: 800;
            font-size: 0.9rem;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .rules-list strong { color: var(--text-dark); }

        .rule-callout {
            background: linear-gradient(135deg, var(--primary-light) 0%, #fff0f5 100%);
            border: 2px solid rgba(100, 144, 215, 0.2);
            border-radius: 18px;
            padding: 1.75rem;
        }

        .rule-callout h3 { font-size: 1.5rem; margin-bottom: 0.6rem; }

        .rule-callout p {
            color: var(--text-muted);
            font-size: 0.95rem;
            line-height: 1.6;
            margin-bottom: 0.9rem;
        }

        .rule-callout p:last-child { margin-bottom: 0; }

        /* TOOLKIT */
        .tool-grid {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 1.25rem;
            margin-top: 1.75rem;
        }

        .tool-card {
            background: var(--bg-base);
            border-radius: 16px;
            padding: 1.4rem;
            border: 1px solid var(--primary-light);
        }

        .tool-role {
            font-size: 0.78rem;
            font-weight: 800;
            color: var(--accent);
            margin-bottom: 0.3rem;
        }

        .tool-name { font-size: 1.2rem; margin-bottom: 0.4rem; }

        .tool-desc { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

        /* DEVELOPMENT STATUS CARDS */
        .status-grid {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 1.25rem;
            margin-top: 1.75rem;
        }

        .status-card {
            background: var(--bg-base);
            border-radius: 18px;
            padding: 1.5rem;
            border: 2px solid var(--primary-light);
            display: flex;
            flex-direction: column;
            justify-content: space-between;
        }

        .status-card.is-done {
            background: linear-gradient(135deg, var(--primary-light) 0%, #f0f5fc 100%);
            border-color: rgba(100, 144, 215, 0.3);
        }

        .status-card.is-next {
            background: linear-gradient(135deg, #fff0f5 100%, #fff7f9 100%);
            border-color: var(--accent);
        }

        .status-badge {
            align-self: flex-start;
            font-size: 0.72rem;
            font-weight: 800;
            padding: 0.25rem 0.7rem;
            border-radius: 12px;
            margin-bottom: 0.75rem;
            text-transform: uppercase;
            letter-spacing: 0.05em;
        }

        .status-card.is-done .status-badge { background: var(--primary); color: var(--white); }
        .status-card.is-next .status-badge { background: var(--accent); color: var(--white); }
        .status-card:not(.is-done):not(.is-next) .status-badge { background: var(--primary-light); color: var(--primary-dark); }

        .status-title { font-size: 1.2rem; margin-bottom: 0.4rem; color: var(--text-dark); }
        .status-desc { font-size: 0.9rem; color: var(--text-muted); line-height: 1.55; }

        /* FAQ */
        .faq { margin-top: 1.5rem; }

        .faq details {
            background: var(--bg-base);
            border: 2px solid var(--primary-light);
            border-radius: 14px;
            padding: 1rem 1.25rem;
            margin-bottom: 0.75rem;
        }

        .faq summary {
            font-weight: 800;
            font-size: 1.05rem;
            cursor: pointer;
            list-style: none;
            display: flex;
            justify-content: space-between;
            gap: 1rem;
            align-items: center;
        }

        .faq summary::-webkit-details-marker { display: none; }

        .faq summary::after {
            content: '+';
            color: var(--primary);
            font-size: 1.4rem;
            line-height: 1;
        }

        .faq details[open] summary::after { content: '–'; }

        .faq details p {
            color: var(--text-muted);
            font-size: 0.95rem;
            line-height: 1.65;
            margin-top: 0.75rem;
            max-width: 150ch;
        }

        /* SUPPORT SECTION */
        .support-section {
            scroll-margin-top: 80px;
        }

        .support-box {
            background: linear-gradient(135deg, var(--primary-light) 0%, #fff0f5 100%);
            border-radius: 20px;
            padding: 2rem 2rem 1.2rem 2rem;
            border: 2px solid rgba(100, 144, 215, 0.2);
            text-align: center;
        }

        .support-grid {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 1.25rem;
            margin-top: 1.5rem;
        }

        .support-card {
            background: var(--white);
            border-radius: 16px;
            padding: 1.5rem;
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: space-between;
            border: 1.5px solid var(--primary-light);
        }

        .support-card-title {
            font-size: 1.2rem;
            color: var(--text-dark);
            margin-bottom: 0.4rem;
        }

        .support-card-desc {
            font-size: 0.88rem;
            color: var(--text-muted);
            margin-bottom: 1.2rem;
        }

        /* MINIMALIST COMPACT SOCIAL ICONS */
        .support-socials {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 1.25rem;
            margin-top: 0.85rem;
            padding: 0;
        }

        .social-icon-btn {
            background: none;
            border: none;
            box-shadow: none;
            padding: 2px;
            color: var(--text-dark);
            display: inline-flex;
            align-items: center;
            justify-content: center;
            text-decoration: none;
            transition: color 0.15s ease, transform 0.15s ease;
        }

        .social-icon-btn:hover {
            color: var(--primary);
            transform: translateY(-1px);
        }

        footer {
            text-align: center;
            padding: 2rem;
            color: var(--text-muted);
            font-weight: 600;
            font-size: 0.9rem;
        }

        a:focus-visible, summary:focus-visible {
            outline: 3px solid var(--accent);
            outline-offset: 3px;
            border-radius: 4px;
        }

        @media (prefers-reduced-motion: reduce) {
            * { animation: none !important; transition: none !important; }
            html { scroll-behavior: auto; }
        }

        @media (max-width: 960px) {
            header { border-radius: 0; }
            .main-container { padding: 1.5rem; margin: 1rem; }
            .page-hero, .two-col-grid { grid-template-columns: 1fr; text-align: center; }
            .cta-group { justify-content: center; }
            .demo-banner { flex-direction: column; text-align: center; }
            .profile-grid, .rules-layout, .feature-grid, .support-grid { grid-template-columns: 1fr; }
            .flow-grid, .tool-grid, .status-grid { grid-template-columns: 1fr 1fr; }
            .nav-links { display: none; }
            .floating-card-tag { display: none; }
        }

        @media (max-width: 560px) {
            .flow-grid, .tool-grid, .status-grid { grid-template-columns: 1fr; }
            .page-title { font-size: 2.3rem; }
        }
