 * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
        }

        :root {
            --primary: #7c3aed;
            --primary-dark: #6d28d9;
            --secondary: #f8fafc;
            --accent: #10b981;
            --accent-dark: #0da271;
            --dark: #1e293b;
            --light: #f1f5f9;
            --gray: #94a3b8;
            --gray-dark: #64748b;
            --warning: #f59e0b;
            --danger: #ef4444;
            --shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
            --radius: 12px;
            --radius-sm: 8px;
            --gradient: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
        }

        body {
            background-color: var(--secondary);
            color: var(--dark);
            line-height: 1.6;
            min-height: 100vh;
            padding: 20px;
            background-image: 
                radial-gradient(circle at 10% 20%, rgba(124, 58, 237, 0.05) 0%, transparent 20%),
                radial-gradient(circle at 90% 80%, rgba(16, 185, 129, 0.05) 0%, transparent 20%);
        }

        .container {
            max-width: 1400px;
            margin: 0 auto;
        }

        /* Header */
        .header {
            text-align: center;
            margin-bottom: 30px;
            padding: 25px;
            background: var(--gradient);
            color: white;
            border-radius: var(--radius);
            box-shadow: var(--shadow);
            position: relative;
            overflow: hidden;
        }

        .header::before {
            content: "PRO";
            position: absolute;
            top: 10px;
            right: -30px;
            background-color: var(--accent);
            color: white;
            padding: 5px 40px;
            font-weight: bold;
            transform: rotate(45deg);
            font-size: 14px;
            z-index: 2;
        }

        .header::after {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
            opacity: 0.2;
        }

        .header h1 {
            font-size: 2.8rem;
            margin-bottom: 10px;
            position: relative;
            z-index: 1;
        }

        .header p {
            font-size: 1.2rem;
            opacity: 0.95;
            max-width: 800px;
            margin: 0 auto;
            position: relative;
            z-index: 1;
        }

        /* Main Layout */
        .app-container {
            display: flex;
            flex-direction: column;
            gap: 25px;
            margin-bottom: 30px;
        }

        @media (min-width: 1200px) {
            .app-container {
                flex-direction: row;
            }
            
            .input-section, .output-section {
                flex: 1;
            }
        }

        /* Sections */
        .section {
            background-color: white;
            border-radius: var(--radius);
            padding: 25px;
            box-shadow: var(--shadow);
            transition: transform 0.3s ease;
            position: relative;
            overflow: hidden;
        }

        .section:hover {
            transform: translateY(-5px);
        }

        .section-header {
            display: flex;
            align-items: center;
            margin-bottom: 20px;
            padding-bottom: 15px;
            border-bottom: 2px solid var(--light);
        }

        .section-header i {
            background-color: var(--primary);
            color: white;
            width: 45px;
            height: 45px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-right: 15px;
            font-size: 1.2rem;
        }

        .section-header h2 {
            font-size: 1.6rem;
            color: var(--primary);
        }

        /* Textareas */
        .textarea-container {
            position: relative;
            margin-bottom: 20px;
            border-radius: var(--radius-sm);
            overflow: hidden;
            border: 2px solid var(--light);
            transition: border-color 0.3s;
        }

        .textarea-container:focus-within {
            border-color: var(--primary);
        }

        textarea {
            width: 100%;
            min-height: 250px;
            padding: 20px;
            border: none;
            font-size: 1.05rem;
            resize: vertical;
            line-height: 1.5;
            font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
        }

        textarea:focus {
            outline: none;
        }

        .char-count {
            position: absolute;
            bottom: 10px;
            right: 15px;
            background-color: rgba(255, 255, 255, 0.9);
            padding: 5px 12px;
            border-radius: 20px;
            font-size: 0.85rem;
            color: var(--gray-dark);
            font-weight: 500;
            box-shadow: 0 2px 5px rgba(0,0,0,0.1);
        }

        /* Buttons */
        .button-group {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            margin-bottom: 20px;
        }

        .btn {
            padding: 14px 24px;
            border: none;
            border-radius: var(--radius-sm);
            font-weight: 600;
            font-size: 1rem;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
        }

        .btn::after {
            content: '';
            position: absolute;
            top: 50%;
            left: 50%;
            width: 5px;
            height: 5px;
            background: rgba(255, 255, 255, 0.5);
            opacity: 0;
            border-radius: 100%;
            transform: scale(1, 1) translate(-50%);
            transform-origin: 50% 50%;
        }

        .btn:focus:not(:active)::after {
            animation: ripple 1s ease-out;
        }

        @keyframes ripple {
            0% {
                transform: scale(0, 0);
                opacity: 0.5;
            }
            100% {
                transform: scale(20, 20);
                opacity: 0;
            }
        }

        .btn-primary {
            background-color: var(--primary);
            color: white;
        }

        .btn-primary:hover {
            background-color: var(--primary-dark);
            transform: translateY(-2px);
            box-shadow: 0 7px 14px rgba(124, 58, 237, 0.2);
        }

        .btn-accent {
            background-color: var(--accent);
            color: white;
        }

        .btn-accent:hover {
            background-color: var(--accent-dark);
            transform: translateY(-2px);
            box-shadow: 0 7px 14px rgba(16, 185, 129, 0.2);
        }

        .btn-outline {
            background-color: transparent;
            color: var(--primary);
            border: 2px solid var(--primary);
        }

        .btn-outline:hover {
            background-color: var(--primary);
            color: white;
            transform: translateY(-2px);
        }

        .btn-warning {
            background-color: var(--warning);
            color: white;
        }

        .btn-warning:hover {
            opacity: 0.9;
            transform: translateY(-2px);
        }

        .btn-danger {
            background-color: var(--danger);
            color: white;
        }

        .btn-danger:hover {
            opacity: 0.9;
            transform: translateY(-2px);
        }

        /* Control Panel */
        .control-panel {
            background-color: var(--light);
            padding: 25px;
            border-radius: var(--radius);
            margin-bottom: 20px;
            box-shadow: 0 5px 10px rgba(0,0,0,0.05);
        }

        .control-header {
            display: flex;
            align-items: center;
            margin-bottom: 20px;
            color: var(--primary);
        }

        .control-header i {
            margin-right: 10px;
            font-size: 1.3rem;
        }

        .control-header h3 {
            font-size: 1.4rem;
        }

        .options-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 20px;
        }

        .option-group {
            background-color: white;
            padding: 20px;
            border-radius: var(--radius-sm);
            box-shadow: 0 3px 8px rgba(0,0,0,0.05);
        }

        .option-title {
            font-weight: 600;
            margin-bottom: 15px;
            color: var(--primary);
            display: flex;
            align-items: center;
            gap: 10px;
        }

        .option-item {
            display: flex;
            align-items: center;
            margin-bottom: 12px;
            padding: 8px 0;
        }

        .option-item:last-child {
            margin-bottom: 0;
        }

        .option-item input[type="checkbox"],
        .option-item input[type="radio"] {
            width: 20px;
            height: 20px;
            margin-right: 12px;
            accent-color: var(--primary);
            cursor: pointer;
        }

        .option-item label {
            cursor: pointer;
            font-size: 1rem;
            color: var(--dark);
        }

        /* Reference Table */
        .reference-section {
            margin-top: 30px;
        }

        .reference-table {
            width: 100%;
            border-collapse: collapse;
            margin-top: 15px;
            background-color: white;
            border-radius: var(--radius-sm);
            overflow: hidden;
            box-shadow: 0 5px 10px rgba(0,0,0,0.05);
        }

        .reference-table th {
            background-color: var(--primary);
            color: white;
            padding: 15px;
            text-align: left;
            font-weight: 600;
        }

        .reference-table td {
            padding: 12px 15px;
            border-bottom: 1px solid var(--light);
            font-family: 'Consolas', monospace;
        }

        .reference-table tr:hover {
            background-color: rgba(124, 58, 237, 0.05);
        }

        .reference-table .entity {
            color: var(--primary);
            font-weight: 600;
        }

        .reference-table .char {
            font-size: 1.3rem;
            text-align: center;
        }

        /* Stats */
        .stats {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
            gap: 15px;
            margin-top: 25px;
            padding-top: 20px;
            border-top: 1px solid var(--light);
        }

        .stat-box {
            background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
            padding: 20px;
            border-radius: var(--radius-sm);
            text-align: center;
            border: 1px solid rgba(124, 58, 237, 0.1);
        }

        .stat-value {
            font-size: 2.2rem;
            font-weight: 700;
            color: var(--primary);
            margin-bottom: 5px;
            line-height: 1;
        }

        .stat-label {
            font-size: 0.95rem;
            color: var(--gray-dark);
            font-weight: 500;
        }

        /* Preview Section */
        .preview-section {
            margin-top: 30px;
            display: none;
        }

        .preview-section.active {
            display: block;
        }

        .preview-container {
            background-color: white;
            padding: 20px;
            border-radius: var(--radius-sm);
            border: 1px solid var(--light);
            min-height: 100px;
            font-size: 1.1rem;
            line-height: 1.6;
        }

        /* Footer */
        .footer {
            text-align: center;
            margin-top: 40px;
            padding-top: 20px;
            border-top: 1px solid var(--light);
            color: var(--gray-dark);
            font-size: 0.95rem;
        }

        .footer-links {
            display: flex;
            justify-content: center;
            gap: 20px;
            margin-top: 10px;
        }

        .footer-link {
            color: var(--primary);
            text-decoration: none;
            transition: color 0.3s;
        }

        .footer-link:hover {
            color: var(--primary-dark);
            text-decoration: underline;
        }

        /* Toast Notification */
        .toast {
            position: fixed;
            bottom: 20px;
            right: 20px;
            background-color: var(--primary);
            color: white;
            padding: 18px 25px;
            border-radius: var(--radius);
            box-shadow: var(--shadow);
            transform: translateY(100px);
            opacity: 0;
            transition: all 0.5s ease;
            z-index: 1000;
            max-width: 400px;
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .toast.show {
            transform: translateY(0);
            opacity: 1;
        }

        .toast.success {
            background-color: var(--accent);
        }

        .toast.error {
            background-color: var(--danger);
        }

        .toast i {
            font-size: 1.3rem;
        }

        /* Responsive */
        @media (max-width: 768px) {
            .header h1 {
                font-size: 2.2rem;
            }
            
            .header p {
                font-size: 1rem;
            }
            
            .button-group {
                flex-direction: column;
            }
            
            .btn {
                width: 100%;
            }
            
            .options-grid {
                grid-template-columns: 1fr;
            }
            
            .stats {
                grid-template-columns: repeat(2, 1fr);
            }
            
            .reference-table {
                display: block;
                overflow-x: auto;
            }
        }

        /* Tooltip */
        .tooltip {
            position: relative;
            display: inline-block;
        }

        .tooltip .tooltip-text {
            visibility: hidden;
            width: 200px;
            background-color: var(--dark);
            color: white;
            text-align: center;
            padding: 10px;
            border-radius: var(--radius-sm);
            position: absolute;
            z-index: 1;
            bottom: 125%;
            left: 50%;
            transform: translateX(-50%);
            opacity: 0;
            transition: opacity 0.3s;
            font-size: 0.9rem;
            font-weight: normal;
        }

        .tooltip:hover .tooltip-text {
            visibility: visible;
            opacity: 1;
        }

        /* Animation */
        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(10px); }
            to { opacity: 1; transform: translateY(0); }
        }

        .fade-in {
            animation: fadeIn 0.5s ease forwards;
        }