:root {
            --bg: #030712;
            --text-main: #f9fafb;
            --text-muted: #9ca3af;
            --primary: #3b82f6;
            --primary-glow: rgba(59, 130, 246, 0.5);
            --secondary: #8b5cf6;
            --surface: rgba(31, 41, 55, 0.4);
            --surface-border: rgba(255, 255, 255, 0.08);
        }

        * { box-sizing: border-box; margin: 0; padding: 0; }
        html { scroll-behavior: smooth; scroll-padding-top: 100px; }

        body {
            font-family: 'Plus Jakarta Sans', sans-serif;
            background-color: var(--bg);
            color: var(--text-main);
            line-height: 1.6;
            overflow-x: hidden;
            text-wrap: pretty;
        }

        h1, h2, h3, h4, h5, h6 {
            text-wrap: balance;
        }

        .bg-glow {
            position: fixed;
            top: 0; left: 0; width: 100vw; height: 100vh;
            background: 
                radial-gradient(circle at 15% 50%, rgba(96, 165, 250, 0.18) 0%, transparent 50%),
                radial-gradient(circle at 85% 30%, rgba(139, 92, 246, 0.18) 0%, transparent 50%),
                radial-gradient(circle at 50% 80%, rgba(236, 72, 153, 0.1) 0%, transparent 50%);
            z-index: -1; filter: blur(50px);
            animation: meshGlow 15s ease-in-out infinite alternate;
        }
        @keyframes meshGlow {
            0% { transform: scale(1) rotate(0deg); }
            50% { transform: scale(1.2) rotate(3deg); }
            100% { transform: scale(1) rotate(-3deg); }
        }


        .container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

        nav { display: flex; justify-content: space-between; align-items: center; padding: 24px 0; }
        .logo { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.5px; background: linear-gradient(to right, #fff, #9ca3af); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
        .lang-toggle { background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); color: #a1a1aa; padding: 6px 14px; border-radius: 20px; text-decoration: none; font-size: 0.8rem; font-weight: 600; display: flex; align-items: center; gap: 6px; transition: all 0.2s ease; }
        .lang-toggle:hover { background: rgba(255, 255, 255, 0.1); color: #fff; border-color: rgba(255,255,255,0.3); }
        .lang-toggle.en-active { color: #60a5fa; border-color: rgba(96, 165, 250, 0.4); background: rgba(96, 165, 250, 0.05); }

        .hero { text-align: center; padding: 100px 0 60px; animation: fadeInDown 1s ease-out; }
        .hero-badge {
            display: inline-flex; align-items: center; justify-content: center;
            background: rgba(255, 255, 255, 0.03);
            border: 1px solid rgba(255, 255, 255, 0.1);
            box-shadow: inset 0 0 20px rgba(192, 132, 252, 0.05), 0 0 20px rgba(96, 165, 250, 0.15);
            color: #e2e8f0;
            padding: 8px 24px;
            border-radius: 100px;
            font-size: 0.95rem;
            font-weight: 500;
            margin-bottom: 28px;
            backdrop-filter: blur(10px);
            letter-spacing: 0.5px;
        }
        .hero h1 { font-size: 4rem; font-weight: 800; line-height: 1.1; margin-bottom: 24px; letter-spacing: -2px; }
        .hero h1 span { background: linear-gradient(135deg, #60a5fa, #c084fc); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
        .hero p { font-size: 1.25rem; color: var(--text-muted); max-width: 650px; margin: 0 auto 40px; }

        .cta-group { display: flex; gap: 16px; justify-content: center; }
        .btn-primary { 
            position: relative; 
            background: 
                linear-gradient(115deg, transparent 30%, rgba(255,255,255,0.5) 50%, transparent 70%) 200% 0 / 200% 100% no-repeat,
                linear-gradient(135deg, #2563eb, #7c3aed); 
            color: #fff; padding: 16px 32px; border-radius: 100px; text-decoration: none; font-weight: 800; font-size: 1.1rem; text-transform: uppercase; letter-spacing: 1px; border: none; cursor: pointer; transition: transform 0.2s, box-shadow 0.2s; 
            box-shadow: 0 0 12px rgba(139, 92, 246, 0.3); z-index: 1; display: inline-block;
            animation: shineBtn 6s infinite;
        }
        @keyframes shineBtn {
            0%, 80% { background-position: 200% 0, 0 0; }
            100% { background-position: -200% 0, 0 0; }
        }
        .btn-primary::before {
            content: ''; position: absolute; top: -3px; left: -3px; right: -3px; bottom: -3px; z-index: -1;
            background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ec4899, #3b82f6); background-size: 300%;
            border-radius: 104px; opacity: 0.6; animation: glowingBtn 3s linear infinite; filter: blur(6px);
        }
        .btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(139, 92, 246, 0.5); }
        @keyframes glowingBtn { 0% { background-position: 300% 0; } 100% { background-position: 0% 0; } }
        .btn-secondary { background: var(--surface); color: #fff; padding: 16px 32px; border-radius: 100px; text-decoration: none; font-weight: 600; font-size: 1.1rem; border: 1px solid var(--surface-border); transition: all 0.2s; }
        .btn-secondary:hover { background: rgba(255, 255, 255, 0.1); }

        .metrics { display: flex; justify-content: center; gap: 80px; padding: 60px 0; border-top: 1px solid var(--surface-border); border-bottom: 1px solid var(--surface-border); margin: 60px 0; }
        .metric-item { text-align: center; }
        .metric-number { font-size: 3rem; font-weight: 800; background: linear-gradient(to right, #fff, #9ca3af); -webkit-background-clip: text; -webkit-text-fill-color: transparent; margin-bottom: 8px; }
        .metric-label { color: var(--primary); font-weight: 600; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; }

        .features { padding: 80px 24px; max-width: 1200px; margin: 0 auto; }
        .section-header { text-align: center; margin-bottom: 60px; }
        .section-header h2 { font-size: 2.5rem; font-weight: 800; margin-bottom: 16px; }
        
        .feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
        .feature-card { 
            background: rgba(255, 255, 255, 0.03); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
            border: 1px solid rgba(255, 255, 255, 0.05); border-top-color: rgba(255, 255, 255, 0.2); border-left-color: rgba(255, 255, 255, 0.15); box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
            padding: 40px 32px; border-radius: 24px; transition: transform 0.3s, box-shadow 0.3s; display: flex; flex-direction: column; align-items: center; text-align: center; 
        }
        .feature-card:hover { transform: translateY(-5px); border-color: rgba(96, 165, 250, 0.4); box-shadow: inset 1px 1px 0 rgba(255, 255, 255, 0.2), 0 15px 40px rgba(0, 0, 0, 0.4); }
        .feature-icon { width: 56px; height: 56px; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 16px; display: flex; align-items: center; justify-content: center; margin-bottom: 24px; }
        .feature-card h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 16px; }
        .feature-card p { color: var(--text-muted); font-size: 0.95rem; line-height: 1.6; }

        /* UI Mockup Styles */
        .moho-window {
            width: 760px;
            background: rgba(43, 43, 43, 0.65);
            backdrop-filter: blur(16px);
            -webkit-backdrop-filter: blur(16px);
            border: 1px solid rgba(255, 255, 255, 0.12);
            border-radius: 8px;
            font-family: 'Segoe UI', Tahoma, sans-serif;
            color: #cccccc;
            margin: 40px auto 80px;
            box-shadow: 0 30px 60px rgba(0,0,0,0.5), 0 0 20px rgba(96, 165, 250, 0.1);
            overflow: hidden;
            text-align: left;
            font-size: 13px;
            user-select: none;
        }

        .moho-titlebar { background: rgba(255, 255, 255, 0.85); color: #000; padding: 5px 10px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
        .moho-content { padding: 20px; }
        .moho-quick-access { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; flex-wrap: wrap; }
        .moho-btn { background-color: #1c1c1c; border: 1px solid #111; color: #ccc; padding: 5px 12px; border-radius: 2px; cursor: pointer; display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; box-shadow: inset 1px 1px 0 rgba(255,255,255,0.05); }
        .moho-btn:hover { background-color: #3a3a3a; }
        
        .moho-divider { height: 2px; background-color: #1a1a1a; border-bottom: 1px solid #3d3d3d; margin: 20px 0; }
        .moho-panels { display: flex; }
        .moho-col-left { flex: 1; padding-right: 40px; border-right: 2px solid #1a1a1a; position: relative; }
        .moho-col-left::after { content: ''; position: absolute; top: 0; right: -2px; width: 1px; height: 100%; background-color: #3d3d3d; }
        .moho-col-right { flex: 1; padding-left: 40px; }
        .moho-section-title { text-align: center; font-size: 11px; letter-spacing: 1px; color: #999; margin-bottom: 25px; }

        .moho-dropdown {
            width: 100%; background-color: #1c1c1c; border: 1px solid #111; color: #ccc; padding: 5px 8px; margin-bottom: 18px; border-radius: 2px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; position: relative;
        }
        .moho-dropdown span.text { flex: 1; text-align: center; }
        .moho-select-real { position: absolute; top: 0; left: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }

        .dpad-container { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-bottom: 18px; }
        .dpad-row { display: flex; gap: 6px; }
        .dpad-btn { width: 30px; height: 30px; background-color: #1c1c1c; border: 1px solid #111; display: flex; justify-content: center; align-items: center; border-radius: 2px; cursor: pointer; transition: 0.1s; user-select: none; }
        .dpad-btn:hover { background-color: #333; }
        .dpad-btn.active { background-color: #4cc2c2; color: #000; border-color: #4cc2c2; }

        .moho-checkboxes { display: flex; justify-content: space-between; margin-top: 25px; padding: 0 10px; }
        .moho-check { display: flex; align-items: center; gap: 6px; font-size: 12px; cursor: pointer; }
        .moho-check input { accent-color: #4cc2c2; }

        .timing-grid { display: grid; grid-template-columns: 80px 1fr 60px; gap: 15px 10px; align-items: center; }
        .timing-input { background-color: #222; border: 1px solid #111; color: #4cc2c2; padding: 4px 6px; border-radius: 2px; width: 100%; box-sizing: border-box; font-size: 12px; outline: none; font-family: inherit; }
        .timing-input:focus { border-color: #4cc2c2; }
        .timing-input.gray { color: #888; }
        .timing-input::-webkit-outer-spin-button, .timing-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
        .timing-input[type=number] { -moz-appearance: textfield; }
        .moho-slider { -webkit-appearance: none; width: 100%; height: 4px; background: #181818; outline: none; border-radius: 2px; }
        .moho-slider::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 14px; height: 14px; border-radius: 50%; background: #333; border: 2px solid #111; cursor: pointer; }

        /* Custom Moho Dropdown */
        .moho-custom-menu {
            position: absolute; top: calc(100% + 2px); left: 0; width: 100%;
            background-color: #1e1e1e; border: 1px solid #111; box-shadow: 2px 5px 15px rgba(0,0,0,0.5);
            z-index: 1000; max-height: 400px; overflow-y: auto;
            display: none; flex-direction: column; border-radius: 3px;
        }
        .moho-custom-menu.show { display: flex; }
        .moho-custom-menu::-webkit-scrollbar { width: 8px; }
        .moho-custom-menu::-webkit-scrollbar-track { background: #1a1a1a; }
        .moho-custom-menu::-webkit-scrollbar-thumb { background: #444; border-radius: 4px; }
        
        .moho-menu-optgroup {
            display: flex; align-items: center; color: #888; font-size: 11px; padding: 12px 10px 4px;
        }
        .moho-menu-optgroup::before, .moho-menu-optgroup::after {
            content: ''; flex: 1; border-bottom: 1px solid #444; margin: 0 5px;
        }
        .moho-menu-option {
            padding: 6px 10px 6px 25px; color: #ccc; font-size: 13px; cursor: pointer; position: relative;
        }
        .moho-menu-option:hover { background-color: #2a2a2a; color: #fff; }
        .moho-menu-option.selected { background-color: #0d6efd; color: #fff; }
        .moho-menu-option.selected::before {
            content: '✔'; position: absolute; left: 8px;
        }
        @keyframes fadeInDown { from { opacity: 0; transform: translateY(-30px); } to { opacity: 1; transform: translateY(0); } }
    
        .sticky-nav {
            position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
            background: rgba(3, 7, 18, 0.75); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
            border-bottom: 1px solid rgba(255, 255, 255, 0.05); padding: 16px 0; transition: all 0.3s ease;
        }
        .fade-in { opacity: 0; transform: translateY(40px); transition: opacity 0.8s ease-out, transform 0.8s ease-out; }
        .fade-in.visible { opacity: 1; transform: translateY(0); }
        .preset-item {
            background: rgba(255, 255, 255, 0.03);
            padding: 18px;
            border-radius: 14px;
            border: 1px solid rgba(255, 255, 255, 0.08);
            transition: all 0.3s ease;
            cursor: default;
            display: flex;
            flex-direction: column;
            gap: 8px;
        }
        .preset-item:hover {
            transform: translateY(-4px);
            background: rgba(255, 255, 255, 0.06);
            border-color: rgba(96, 165, 250, 0.4);
            box-shadow: 0 10px 20px rgba(0,0,0,0.2);
        }
        .preset-title {
            font-weight: 700;
            color: #f3f4f6;
            font-size: 1.05rem;
        }
        .preset-desc {
            color: #9ca3af;
            font-size: 0.9rem;
            line-height: 1.5;
        }
    
        /* Custom Scrollbar */
        ::-webkit-scrollbar { width: 10px; }
        ::-webkit-scrollbar-track { background: #030712; border-left: 1px solid rgba(255,255,255,0.05); }
        ::-webkit-scrollbar-thumb { background: rgba(96, 165, 250, 0.3); border-radius: 10px; border: 2px solid #030712; }
        ::-webkit-scrollbar-thumb:hover { background: rgba(96, 165, 250, 0.6); }

        /* Mobile Responsive */
        @media (max-width: 768px) {
            nav { padding: 15px 20px !important; flex-wrap: wrap; justify-content: center !important; gap: 15px; }
            nav .logo { margin-bottom: 10px; }
            nav div:nth-child(2) { position: static !important; transform: none !important; width: 100%; justify-content: center; margin-bottom: 15px; font-size: 0.85rem; gap: 20px !important; }
            
            .hero { padding: 60px 20px !important; }
            .hero h1 { font-size: 2.5rem !important; }
            
            .metrics { flex-direction: column; gap: 40px !important; }
            .feature-grid { grid-template-columns: 1fr !important; }
            
            .moho-window {
                width: 95vw !important;
                margin: 40px auto !important;
            }
            .moho-content { padding: 14px !important; }
            .moho-panels { flex-direction: column; }
            .moho-col-left { padding-right: 0 !important; padding-bottom: 20px; border-right: none !important; border-bottom: 2px solid #1a1a1a; }
            .moho-col-left::after { display: none; }
            .moho-col-right { padding-left: 0 !important; padding-top: 20px; }

            .catalog-grid { grid-template-columns: 1fr !important; }

            /* Cho control co giãn theo container thay vì giữ width cố định của bản desktop */
            .moho-quick-access { gap: 8px !important; }
            .moho-btn { padding: 5px 9px !important; font-size: 12px !important; }
            .dpad-container { transform: scale(0.92); }
            .timing-grid { grid-template-columns: 68px 1fr 46px !important; gap: 10px 6px !important; }
            .timing-input { font-size: 11px !important; padding: 4px 4px !important; }
        }

        /* Mobile nhỏ: siết thêm padding/font để không tràn ngang dưới 380px */
        @media (max-width: 480px) {
            .moho-content { padding: 10px !important; }
            .moho-titlebar { font-size: 11px !important; padding: 4px 8px !important; }
            .moho-section-title { font-size: 10px !important; margin-bottom: 16px !important; }
            .moho-dropdown { padding: 4px 6px !important; margin-bottom: 12px !important; font-size: 12px !important; }
            .moho-quick-access { flex-wrap: wrap; }
            .moho-quick-access span { width: 100%; margin-bottom: 4px; }
            .moho-btn { flex: 1 1 auto; justify-content: center; padding: 6px 6px !important; font-size: 11px !important; }
            .dpad-container { transform: scale(0.85); margin-bottom: 8px !important; }
            .dpad-btn { width: 26px; height: 26px; }
            .timing-grid { grid-template-columns: 56px 1fr 40px !important; gap: 8px 5px !important; }
            .timing-input { font-size: 10px !important; }
            .moho-checkboxes { flex-direction: column; gap: 8px; padding: 0 !important; }
        }
/* Enhancements */
.preset-item { transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); }
.preset-item:hover { transform: translateY(-5px) scale(1.02); box-shadow: 0 15px 30px rgba(59, 130, 246, 0.2); }
.feature-card { transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); }
.btn-primary { transition: all 0.3s ease; }

/* Phase 2 Enhancements */
::selection {
    background: rgba(96, 165, 250, 0.3);
    color: #fff;
    text-shadow: 0 0 5px rgba(255,255,255,0.5);
}

.animated-gradient-text {
    background: linear-gradient(to right, #60a5fa, #c084fc, #f472b6, #60a5fa);
    background-size: 300% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: flowGradient 6s ease infinite;
}

@keyframes flowGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.floating-mockup {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

/* Cursor Glow */
.cursor-glow {
    position: fixed;
    top: 0; left: 0;
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(96, 165, 250, 0.15), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%);
    transition: opacity 0.3s ease;
    opacity: 0;
}

