/* ===== MTOXSOCIAL CORE THEME ===== */
        :root {
            --bg-body: #f8fafc;
            --bg-card: #ffffff;
            --text-main: #1f2937;
            --text-muted: #64748b;
            --primary: #FF6534;
            --primary-hover: #e55520;
            --border: #e2e8f0;
            --radius-lg: 16px;
            --radius-sm: 8px;
            --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
            --ease: cubic-bezier(0.4, 0, 0.2, 1);
        }

        * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Poppins', sans-serif; }
        html, body { width: 100%; overflow-x: hidden; position: relative; }
        body { background-color: var(--bg-body); color: var(--text-main); line-height: 1.6; display: flex; flex-direction: column; min-height: 100vh; }
        a { text-decoration: none; color: inherit; }

        .announcement-bar {
            position: fixed; top: 0; left: 0; width: 100%; height: 30px;
            background: linear-gradient(90deg, var(--primary) 0%, #ff8c66 100%);
            color: #ffffff; display: flex; justify-content: center; align-items: center;
            padding: 0 5%; z-index: 1002; font-size: 12px; font-weight: 500;
            box-shadow: 0 2px 10px rgba(255, 101, 52, 0.2); transition: transform 0.3s ease;
        }
        .announcement-bar .badge { background: rgba(255, 255, 255, 0.25); padding: 2px 8px; border-radius: 12px; font-size: 10px; font-weight: 700; text-transform: uppercase; margin-right: 10px; letter-spacing: 0.5px; }
        .announcement-bar p { margin: 0; display: flex; align-items: center; }

        nav {
            position: fixed; top: 30px; width: 100%; background: rgba(255, 255, 255, 0.9);
            backdrop-filter: blur(12px); border-bottom: 1px solid var(--border);
            padding: 15px 5%; display: flex; justify-content: space-between; align-items: center;
            z-index: 1000; box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03); transition: top 0.3s ease;
        }
        .logo { font-size: 24px; font-weight: 700; color: var(--text-main); text-decoration: none; display: flex; align-items: center; gap: 10px; letter-spacing: -0.5px; }
        .logo img { height: 38px; }

        .nav-links { display: flex; align-items: center; margin-left: auto; }
        .nav-links a { text-decoration: none; color: var(--text-main); font-weight: 500; margin-left: 30px; transition: all 0.3s; display: flex; align-items: center; gap: 8px; }
        .nav-links a:hover { color: var(--primary); }
        .nav-links .close-btn, .nav-links .menu-header { display: none; }

        .hamburger { display: none; background: none; border: none; font-size: 24px; color: var(--text-main); cursor: pointer; transition: color 0.3s; margin-left: 20px; }
        .hamburger:hover { color: var(--primary); }
        .menu-overlay { display: none; }

        /* ===== TOOLS DROPDOWN ===== */
        .tools-dropdown { position: relative; display: inline-block; margin-left: 30px; }
        .tools-dropdown > a { margin-left: 0 !important; cursor: pointer; }
        .tools-dropdown > a i { font-size: 12px; margin-left: 6px; color: var(--text-muted); transition: transform 0.3s ease; }
        .tools-dropdown:hover > a i { transform: rotate(180deg); }
        .tools-dropdown-content {
            display: none; position: absolute; top: 100%; left: 0; background: #ffffff;
            min-width: 230px; box-shadow: 0 12px 40px rgba(0,0,0,0.12); border-radius: 12px;
            border: 1px solid var(--border); padding: 8px 0; z-index: 1006; margin-top: 8px;
        }
        .tools-dropdown-content a {
            display: block; padding: 10px 20px; font-size: 14px; font-weight: 500; color: var(--text-main);
            margin: 0 !important; border-bottom: 1px solid rgba(226, 232, 240, 0.5); transition: all 0.2s ease;
        }
        .tools-dropdown-content a:last-child { border-bottom: none; }
        .tools-dropdown-content a:hover { background: rgba(255, 101, 52, 0.06); color: var(--primary); padding-left: 26px; }
        .tools-dropdown:hover .tools-dropdown-content { display: block; }

        /* ===== MOBILE TOOLS ===== */
        .mobile-tools-wrapper { display: none; align-items: center; margin-left: auto; gap: 12px; }
        .mobile-tools-btn {
            display: flex; align-items: center; gap: 6px; background: var(--primary); color: #fff;
            border: none; padding: 8px 14px; border-radius: 30px; font-size: 13px; font-weight: 600;
            cursor: pointer; transition: all 0.2s ease; -webkit-tap-highlight-color: transparent;
            box-shadow: 0 4px 12px rgba(255, 101, 52, 0.25); white-space: nowrap;
        }
        .mobile-tools-btn:active { transform: scale(0.94); background: var(--primary-hover); }
        .mobile-tools-btn i { font-size: 12px; transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); pointer-events: none; }
        .mobile-tools-btn.open i { transform: rotate(180deg); }

        .mobile-tools-dropdown {
            position: fixed; top: 75px; left: 5%; right: 5%; background: #ffffff; border-radius: 16px;
            box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15); padding: 8px 0; z-index: 1007;
            max-height: 0; overflow: hidden; transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease, transform 0.3s ease;
            opacity: 0; transform: translateY(-10px) scale(0.96); border: 1px solid var(--border); pointer-events: none;
        }
        .mobile-tools-dropdown.open {
            max-height: 600px; opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; overflow-y: auto;
        }
        .mobile-tools-dropdown a {
            display: block; padding: 14px 20px; font-size: 15px; font-weight: 500; color: var(--text-main);
            border-bottom: 1px solid rgba(226, 232, 240, 0.6); transition: all 0.2s ease;
        }
        .mobile-tools-dropdown a:last-child { border-bottom: none; }
        .mobile-tools-dropdown a:active { background: rgba(255, 101, 52, 0.08); color: var(--primary); padding-left: 26px; }

        /* ===== HERO & HEADER ===== */
        .hero-tool {
            display: grid;
            align-items: center;
            gap: 20px;
            max-width: 1200px;
            margin: 0 auto;
            padding: 130px 5% 40px;
        }

        .hero-title { grid-area: title; }
        .hero-desc { grid-area: desc; }
        .hero-title h1 {
            font-size: clamp(34px, 4.5vw, 46px);
            font-weight: 800;
            margin: 0;
            color: var(--text-main);
            line-height: 1.3;
        }
        
        .hero-desc p {
            font-size: 18px; 
            color: var(--text-muted); 
            line-height: 1.6;
            margin: 0;
        }

        .heading-underline {
            position: absolute;
            bottom: -6px;
            left: 0;
            width: 100%;
            height: 14px;
            z-index: -1;
        }

        @media (min-width: 769px) {
            .hero-tool {
                grid-template-columns: 1fr;
                grid-template-areas: "title" "desc";
                text-align: center;
                align-content: center;
                row-gap: 20px;
                padding-top: 150px;
            }
            .hero-title { align-self: center; }
            .hero-desc { align-self: center; max-width: 800px; margin: 0 auto; }
            .hero-desc p { max-width: 100%; }
        }

        @media (max-width: 768px) {
            .hero-tool {
                grid-template-columns: 1fr;
                grid-template-areas: "title" "desc";
                text-align: center;
                gap: 30px;
                padding-top: 120px;
            }
            .hero-desc p { max-width: 100%; margin: 0 auto; }
        }

        .content-section { padding: 20px 5% 80px; max-width: 1300px; margin: 0 auto; width: 100%; }

        /* ===== SHARE TOOL CONTAINER ===== */
        .share-tool-container {
            background: #fff;
            border-radius: 12px;
            padding: 15px;
            margin-bottom: 20px;
            text-align: center;
            border: 1px solid var(--border);
            box-shadow: 0 4px 15px rgba(0,0,0,0.02);
            width: 100%;
        }
        .share-tool-container p {
            font-size: 14px;
            font-weight: 600;
            margin-bottom: 12px;
            color: var(--text-main);
        }
        .share-flex {
            display: flex;
            justify-content: center;
            gap: 10px;
            flex-wrap: wrap;
        }
        .share-icon-btn {
            width: 35px;
            height: 35px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            text-decoration: none;
            transition: transform 0.2s ease, opacity 0.2s ease;
            font-size: 16px;
        }
        .share-icon-btn:hover {
            transform: translateY(-3px);
            opacity: 0.9;
        }
        .fb-btn { background-color: #1877F2; }
        .tw-btn { background-color: #000000; }
        .wa-btn { background-color: #25D366; }
        .ln-btn { background-color: #0A66C2; }
        .pt-btn { background-color: #E60023; }

        /* ===== WORKSPACE ===== */
        .workspace {
            display: grid;
            grid-template-columns: minmax(0, 400px) minmax(0, 1fr);
            gap: 30px;
            align-items: start;
            max-width: 1100px;
            margin: 0 auto;
        }

        /* Control Panel */
        .control-panel {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: var(--radius-lg);
            padding: 30px;
            box-shadow: 0 8px 30px rgba(0,0,0,0.04);
            display: flex;
            flex-direction: column;
            gap: 25px;
        }

        .field-group { display: flex; flex-direction: column; gap: 8px; }
        .field-group label { font-size: 14px; font-weight: 600; color: var(--text-main); display: flex; justify-content: space-between; }
        
        input[type="text"], select {
            width: 100%; padding: 14px; background: var(--bg-body); border: 1px solid var(--border);
            border-radius: var(--radius-sm); color: var(--text-main); font-size: 15px; transition: all 0.3s ease; outline: none; font-family: 'Poppins', sans-serif;
        }
        input[type="text"]:focus, select:focus { border-color: var(--primary); box-shadow: 0 4px 15px rgba(255, 101, 52, 0.1); background: var(--bg-card); }
        input[type="text"] { font-weight: 600; font-size: 18px; }

        .segmented-control {
            display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden;
        }
        .segmented-control input { position: absolute; opacity: 0; pointer-events: none; }
        .segmented-control label {
            display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
            padding: 12px 4px; font-size: 13px; font-weight: 500; color: var(--text-main); cursor: pointer;
            border-right: 1px solid var(--border); transition: background 0.2s;
        }
        .segmented-control label:last-of-type { border-right: 0; }
        .segmented-control input:checked + label { background: rgba(255, 101, 52, 0.1); color: var(--primary); font-weight: 600; }
        .segmented-control .ico { border: 2px solid currentColor; display: block; border-radius: 2px; }

        .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
        .checkbox-row { display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: 15px; font-weight: 500; color: var(--text-main); }
        .checkbox-row input { width: 20px; height: 20px; accent-color: var(--primary); cursor: pointer; }

        /* ===== CUSTOM COLOR PICKER ===== */
        .color-picker-container {
            display: flex;
            flex-direction: column;
            gap: 10px;
            background: var(--bg-body);
            padding: 15px;
            border-radius: var(--radius-sm);
            border: 1px solid var(--border);
        }
        .color-preset-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(30px, 1fr));
            gap: 8px;
        }
        .color-swatch-btn {
            width: 100%;
            aspect-ratio: 1;
            border-radius: 50%;
            border: 2px solid transparent;
            cursor: pointer;
            transition: transform 0.2s, box-shadow 0.2s;
            position: relative;
        }
        .color-swatch-btn:hover {
            transform: scale(1.1);
        }
        .color-swatch-btn.active {
            box-shadow: 0 0 0 2px var(--bg-card), 0 0 0 4px var(--primary);
            transform: scale(1.1);
        }
        .custom-color-wrapper {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-top: 5px;
            padding-top: 10px;
            border-top: 1px solid var(--border);
        }
        .custom-color-wrapper span {
            font-size: 13px;
            font-weight: 500;
            color: var(--text-muted);
        }
        .custom-color-wrapper input[type="color"] {
            width: 30px;
            height: 30px;
            padding: 0;
            border: none;
            border-radius: 50%;
            cursor: pointer;
            background: transparent;
            overflow: hidden;
        }
        .custom-color-wrapper input[type="color"]::-webkit-color-swatch-wrapper {
            padding: 0;
        }
        .custom-color-wrapper input[type="color"]::-webkit-color-swatch {
            border: 1px solid var(--border);
            border-radius: 50%;
        }

        /* ===== ACTIONS & RESULT ===== */
        .actions { display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
        button.btn-primary {
            background: var(--primary); color: white; padding: 16px; border-radius: var(--radius-sm);
            font-weight: 600; font-size: 18px; cursor: pointer; transition: 0.3s; border: none; width: 100%;
            display: flex; align-items: center; justify-content: center; gap: 10px; box-shadow: 0 4px 15px rgba(255, 101, 52, 0.2);
        }
        button.btn-primary:hover:not(:disabled) { background: var(--primary-hover); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(255, 101, 52, 0.3); }
        button:disabled { opacity: 0.6; cursor: not-allowed; }

        /* Right Panel / Result Area */
        .preview-panel {
            display: flex;
            flex-direction: column;
            gap: 20px;
            min-width: 0;
        }

        .video-container {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: var(--radius-lg);
            padding: 30px;
            box-shadow: 0 8px 30px rgba(0,0,0,0.04);
            min-height: 400px;
            justify-content: center;
            position: relative;
            overflow: hidden;
            display: flex;
            flex-direction: column;
        }

        .empty-state {
            text-align: center;
            color: var(--text-muted);
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 15px;
        }
        .empty-state i {
            font-size: 48px;
            color: var(--border);
        }
        .empty-state p {
            font-size: 16px;
            font-weight: 500;
        }

        .result-card {
            display: flex;
            flex-direction: column;
            gap: 15px;
            animation: fadeIn 0.5s ease;
            width: 100%;
        }
        @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
        .result-card h2 { font-size: 22px; color: var(--text-main); font-weight: 700; text-align: center; }
        .result-card video { width: 100%; max-height: 55vh; border-radius: var(--radius-sm); background: #000; outline: none; box-shadow: 0 4px 15px rgba(0,0,0,0.1); }
        .result-actions { display: flex; gap: 15px; align-items: center; justify-content: center; flex-wrap: wrap; margin-top: 10px; }
        .result-actions button { flex: 1; min-width: 200px; }

        /* Loading Overlay */
        .loading-overlay {
            position: fixed;
            top: 0; left: 0; width: 100%; height: 100vh;
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(5px);
            z-index: 9999;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            gap: 20px;
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.3s ease;
        }
        .loading-overlay.active {
            opacity: 1;
            pointer-events: auto;
        }
        .spinner {
            width: 50px;
            height: 50px;
            border: 5px solid var(--border);
            border-top-color: var(--primary);
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }
        @keyframes spin { to { transform: rotate(360deg); } }
        .loading-text {
            font-size: 16px;
            font-weight: 600;
            color: var(--text-main);
        }
        .loading-subtext {
            font-size: 14px;
            color: var(--text-muted);
        }

        /* Hidden canvas for processing */
        #cv { display: none; }

        /* ===== SEO & CONTENT SECTIONS ===== */
        .section-header { text-align: center; margin-bottom: 50px; }
        .section-header h2 { font-size: 32px; font-weight: 700; color: var(--text-main); margin-bottom: 15px; }
        .section-header p { font-size: 16px; color: var(--text-muted); max-width: 700px; margin: 0 auto; }

        .seo-split {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 50px;
            align-items: center;
            margin-bottom: 40px;
        }
        
        /* Updated to perfectly hold the 1:1 video */
        .seo-video {
            width: 100%;
            aspect-ratio: 1 / 1;
            border-radius: var(--radius-lg);
            overflow: hidden;
            background: #111110;
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0 8px 30px rgba(0,0,0,0.1);
        }
        .seo-video video {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
            outline: none;
        }

        .seo-content h2 { font-size: 28px; margin-bottom: 18px; color: var(--text-main); font-weight: 700; line-height: 1.3; }
        .seo-content p { font-size: 16px; color: var(--text-muted); margin-bottom: 15px; line-height: 1.7; }

        .features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 25px; margin-bottom: 60px; }
        .feature-box {
            background: var(--bg-card); padding: 35px 25px; border-radius: 20px; text-align: center;
            border: 1px solid var(--border); box-shadow: 0 4px 15px rgba(0,0,0,0.02); transition: transform 0.3s ease;
        }
        .feature-box:hover { transform: translateY(-5px); border-color: var(--primary); }
        .step-number {
            width: 40px; height: 40px; background: var(--primary); color: white; border-radius: 50%;
            display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 700; margin: 0 auto 20px;
        }
        .feature-box h3 { font-size: 18px; margin-bottom: 12px; color: var(--text-main); font-weight: 600; }
        .feature-box p { font-size: 14px; color: var(--text-muted); }

        .why-grid {
            display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 25px; margin-bottom: 60px;
        }
        .why-card {
            background: var(--bg-card); padding: 30px; border-radius: 16px;
            border: 1px solid var(--border); box-shadow: 0 4px 15px rgba(0,0,0,0.02); text-align: left;
            transition: all 0.3s;
        }
        .why-card:hover { border-color: var(--primary); box-shadow: 0 8px 25px rgba(0,0,0,0.04); transform: translateY(-2px); }
        .why-card h3 { font-size: 20px; color: var(--text-main); margin-bottom: 12px; font-weight: 700; }
        .why-card p { font-size: 15px; color: var(--text-muted); line-height: 1.6; }

        .faq-container { max-width: 800px; margin: 0 auto; }
        .faq-item { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; margin-bottom: 15px; overflow: hidden; transition: all 0.3s; }
        .faq-item:hover { border-color: var(--primary); }
        .faq-question { padding: 20px 25px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; font-weight: 600; color: var(--text-main); font-size: 16px; }
        .faq-question i { color: var(--primary); transition: transform 0.3s ease; }
        .faq-answer { padding: 0 25px; max-height: 0; overflow: hidden; transition: max-height 0.3s ease, padding 0.3s ease; color: var(--text-muted); font-size: 15px; line-height: 1.7; }
        .faq-item.active .faq-answer { padding: 0 25px 20px; max-height: 300px; }
        .faq-item.active .faq-question i { transform: rotate(180deg); }

        /* ===== FOOTER ===== */
        footer { background-color: #ffffff; border-top: 1px solid var(--border); padding: 60px 5% 20px; box-shadow: 0 -4px 20px rgba(0,0,0,0.02); margin-top: auto; }
        .footer-top { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 1.5fr 2fr; gap: 50px; margin-bottom: 50px; }
        .footer-brand .footer-logo { font-size: 24px; font-weight: 700; color: var(--text-main); text-decoration: none; display: flex; align-items: center; gap: 10px; margin-bottom: 15px; }
        .footer-brand .footer-logo img { height: 38px; }
        .footer-desc { color: var(--text-muted); font-size: 15px; line-height: 1.6; margin-bottom: 25px; max-width: 380px; }
        .footer-nav { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
        .footer-col h4 { color: var(--text-main); font-size: 17px; font-weight: 600; margin-bottom: 20px; }
        .footer-col a { display: block; color: var(--text-muted); text-decoration: none; font-size: 15px; margin-bottom: 12px; transition: all 0.3s ease; }
        .footer-col a:hover { color: var(--primary); transform: translateX(4px); }
        .footer-bottom { max-width: 1200px; margin: 0 auto; text-align: center; color: var(--text-muted); font-size: 14px; padding-top: 25px; border-top: 1px solid var(--border); }

        /* ===== RESPONSIVE DESIGN ===== */
        @media (max-width: 900px) {
            .workspace { grid-template-columns: 1fr; gap: 25px; }
            .control-panel { order: 1; }
            .preview-panel { order: 2; }
            
            .footer-top { grid-template-columns: 1fr; gap: 40px; }
            .footer-nav { grid-template-columns: repeat(2, 1fr); }
            .seo-split { grid-template-columns: 1fr; gap: 30px; text-align: center; }
            .video-container { min-height: 300px; padding: 20px; }
            .seo-video { max-width: 500px; margin: 0 auto; }
        }

        @media (max-width: 768px) {
            .announcement-bar { font-size: 11px; }
            .hamburger { display: block; margin-left: 0; }
            .mobile-tools-wrapper { display: flex !important; }
            .tools-dropdown { display: none !important; }
            .nav-links {
                position: fixed; top: 0; left: -300px; width: 280px; height: 100vh; background-color: #ffffff;
                flex-direction: column; align-items: flex-start; padding: 25px; box-shadow: 4px 0 20px rgba(0,0,0,0.1);
                transition: left 0.4s cubic-bezier(0.175, 0.885, 0.32, 1); z-index: 1005; margin-left: 0;
                overflow-y: auto;
            }
            .nav-links.active { left: 0; }
            .nav-links .menu-header { display: flex; justify-content: space-between; align-items: center; width: 100%; font-size: 20px; font-weight: 700; margin-bottom: 20px; padding-bottom: 15px; border-bottom: 1px solid var(--border); }
            .nav-links .close-btn { display: block; background: none; border: none; font-size: 24px; color: var(--text-muted); cursor: pointer; padding: 5px; }
            .nav-links > a { margin: 0 0 18px 0; font-size: 18px; width: 100%; }
            .menu-overlay { display: block; position: fixed; top: 0; left: 0; width: 100%; height: 100vh; background: rgba(0,0,0,0.5); backdrop-filter: blur(3px); z-index: 1004; opacity: 0; visibility: hidden; transition: all 0.3s ease; }
            .menu-overlay.active { opacity: 1; visibility: visible; }
            .mobile-tools-dropdown { top: 75px; }
            
            .hero-tool { padding-top: 110px; }
            .hero-title h1 { font-size: 28px; }
            .hero-desc p { font-size: 15px; }
            
            .control-panel { padding: 20px; }
            .result-actions { flex-direction: column; align-items: stretch; }
            .result-actions button { width: 100%; }
        }
        
        @media (max-width: 480px) {
            .footer-nav { grid-template-columns: 1fr; gap: 25px; }
            .mobile-tools-btn { font-size: 12px; padding: 6px 12px; }
            .mobile-tools-dropdown { top: 68px; left: 4%; right: 4%; }
            .row-2 { grid-template-columns: 1fr; }
        }