    :root {
        --control-point-size: 12px;
        --primary-color: #4a6fa5;
        --secondary-color: #6b8cc7;
        --accent-color: #334e77;
        --text-color: #333333;
        --background-light: #f8f9fa;
        --background-medium: #e9ecef;
        --border-color: #dee2e6;
        --success-color: #28a745;
        --danger-color: #dc3545;
        --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    * {
        box-sizing: border-box;
        margin: 0;
        padding: 0;
    }

    body {
        font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
        background-color: var(--background-light);
        color: var(--text-color);
        min-height: 100vh;
        line-height: 1.6;
        transition: all 0.3s ease;
    }

    .edit-mode .canvas-container {
        cursor: crosshair;
    }
.zoom-controls .switch-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: 0.5rem;
}

.zoom-controls .switch-container label {
    font-size: 0.8rem;
    white-space: nowrap;
}

.zoom-controls .switch {
    margin-left: 0.5rem;
}
    .container {
        display: flex;
        flex-direction: row;
        width: 100%;
        height: 100vh;
        overflow: hidden;
    }

    /* Menu latéral */
    .sidebar {
        width: 320px;
        background-color: white;
        padding: 1.5rem;
        box-shadow: var(--shadow);
        overflow-y: auto;
        z-index: 100;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .sidebar-title {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        margin-bottom: 1.5rem;
        font-size: 1.5rem;
        color: var(--primary-color);
    }

    .sidebar-title svg {
        height: 24px;
        width: 24px;
    }

    /* Zone principale de contenu */
    .content {
        flex-grow: 1;
        padding: 1.5rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        overflow-y: auto;
        background-color: var(--background-light);
    }

    .content-header {
        width: 100%;
        text-align: center;
        margin-bottom: 1rem;
    }

.canvas-container {
    position: relative;
    max-width: 100%;
    margin: 0 auto;
    background-color: white;
    border-radius: 8px;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease;
    width: fit-content; /* S'assure que le conteneur ne s'étire pas */
	overflow: visible; /* Permet aux éléments positionnés absolument de dépasser */
}

    canvas {
        display: block;
        cursor: grab;
        max-width: 100%;
        max-height: 70vh;
        border-radius: 8px;
    }

    /* Contrôles de zoom */
    .zoom-controls {
        display: flex;
        gap: 0.5rem;
        justify-content: center;
        margin: 1rem 0;
    }

    /* Sections de la barre latérale */
    .sidebar-section {
        background-color: var(--background-light);
        border-radius: 8px;
        padding: 1rem;
        margin-bottom: 1.5rem;
    }

    .sidebar-section h3 {
        font-size: 1.1rem;
        margin-bottom: 1rem;
        color: var(--primary-color);
        border-bottom: 2px solid var(--secondary-color);
        padding-bottom: 0.5rem;
    }

    /* File input styling */
    .file-input-container {
        position: relative;
        width: 100%;
        margin-bottom: 1rem;
    }

    .file-input-label {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        width: 100%;
        padding: 0.75rem;
        background-color: var(--secondary-color);
        color: white;
        border-radius: 6px;
        cursor: pointer;
        transition: background-color 0.2s;
        font-weight: 500;
    }

    .file-input-label:hover {
        background-color: var(--accent-color);
    }

    .file-input {
        position: absolute;
        width: 0.1px;
        height: 0.1px;
        opacity: 0;
        overflow: hidden;
        z-index: -1;
    }

    /* Input groups */
    .input-group {
        display: flex;
        flex-direction: column;
        margin-bottom: 1rem;
    }

    .input-group-row {
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

    .input-group label {
        font-weight: 500;
        margin-bottom: 0.25rem;
    }

    .input-group input[type="number"],
    .input-group input[type="range"],
    .input-group input[type="color"] {
        width: 100%;
        padding: 0.5rem;
        border: 1px solid var(--border-color);
        border-radius: 4px;
        transition: border-color 0.2s;
    }

    .input-group input[type="color"] {
        height: 40px;
        cursor: pointer;
    }

    .input-group input[type="number"]:focus,
    .input-group input[type="range"]:focus {
        outline: none;
        border-color: var(--secondary-color);
    }

    .range-container {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        width: 100%;
    }

    .range-container input[type="range"] {
        flex-grow: 1;
        height: 6px;
        appearance: none;
        background: var(--border-color);
        border-radius: 3px;
        outline: none;
    }

    .range-container input[type="range"]::-webkit-slider-thumb {
        appearance: none;
        width: 16px;
        height: 16px;
        border-radius: 50%;
        background: var(--primary-color);
        cursor: pointer;
    }

    .range-container input[type="number"] {
        width: 70px;
        text-align: center;
    }

    /* Toggle switch */
    .switch-container {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 1rem;
    }

    .switch {
        position: relative;
        display: inline-block;
        width: 50px;
        height: 26px;
    }

    .switch input {
        opacity: 0;
        width: 0;
        height: 0;
    }

    .slider {
        position: absolute;
        cursor: pointer;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: var(--border-color);
        transition: .4s;
        border-radius: 34px;
    }

    .slider:before {
        position: absolute;
        content: "";
        height: 18px;
        width: 18px;
        left: 4px;
        bottom: 4px;
        background-color: white;
        transition: .4s;
        border-radius: 50%;
    }

    input:checked + .slider {
        background-color: var(--primary-color);
    }

    input:focus + .slider {
        box-shadow: 0 0 1px var(--primary-color);
    }

    input:checked + .slider:before {
        transform: translateX(24px);
    }

    /* Buttons */
    .btn {
        display: inline-block;
        font-weight: 500;
        text-align: center;
        vertical-align: middle;
        user-select: none;
        padding: 0.5rem 1rem;
        font-size: 1rem;
        line-height: 1.5;
        border-radius: 6px;
        transition: all 0.2s;
        cursor: pointer;
        margin-bottom: 0.5rem;
        width: 100%;
        border: none;
        color: white;
    }

    .btn-primary {
        background-color: var(--primary-color);
    }

    .btn-primary:hover {
        background-color: var(--accent-color);
    }

    .btn-secondary {
        background-color: var(--secondary-color);
    }

    .btn-secondary:hover {
        background-color: var(--accent-color);
    }

    .btn-danger {
        background-color: var(--danger-color);
    }

    .btn-danger:hover {
        background-color: #bd2a36;
    }

    .btn-icon {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
    }

    .zoom-btn {
        padding: 0.5rem;
        background-color: var(--background-medium);
        border: 1px solid var(--border-color);
        border-radius: 4px;
        cursor: pointer;
        transition: all 0.2s;
    }

    .zoom-btn:hover {
        background-color: var(--border-color);
    }

    /* Progress bar */
    .progress-container {
        margin: 1.5rem 0;
    }

    .progress-bar-container {
        width: 100%;
        height: 10px;
        background-color: var(--background-medium);
        border-radius: 5px;
        overflow: hidden;
        margin: 0.5rem 0;
    }

    .progress-bar {
        width: 0%;
        height: 100%;
        background-color: var(--success-color);
        border-radius: 5px;
        transition: width 0.3s ease;
    }

    .progress-text {
        font-size: 0.9rem;
        font-weight: 500;
        text-align: center;
    }

    /* Hamburger menu pour mobile */
    .menu-toggle {
        display: none;
        position: fixed;
        top: 1rem;
        left: 1rem;
        z-index: 200;
        background-color: var(--primary-color);
        color: white;
        border: none;
        border-radius: 4px;
        padding: 0.5rem;
        cursor: pointer;
    }

    /* Styles spécifiques mobile */
    [data-touch-friendly] .file-input-label {
        user-select: none;
        -webkit-tap-highlight-color: transparent;
        border: 2px solid var(--primary-color);
    }

    [data-mobile-menu] .file-input-label span {
        pointer-events: none;
    }

    /* Media queries pour responsive design */
    @media (max-width: 992px) {
        .container {
            flex-direction: column;
            height: auto;
        }
        
        .sidebar {
            width: 100%;
            max-height: 300px;
            order: 2;
        }
        
        .content {
            order: 1;
            padding: 1rem;
            height: auto;
            min-height: 60vh;
        }
    }

    @media (max-width: 768px) {
        .menu-toggle {
            display: block;
        }
        
        .sidebar {
            position: fixed;
            top: 0;
            left: 0;
            height: 100vh;
            max-height: none;
            transform: translateX(-100%);
            width: 85%;
            padding: 1rem;
            z-index: 200;
        }
        
        .sidebar.active {
            transform: translateX(0);
        }
        
        .content {
            padding-top: 4rem;
        }
        
        .overlay {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-color: rgba(0, 0, 0, 0.5);
            z-index: 150;
        }
        
        .overlay.active {
            display: block;
        }

        .file-input-label {
            padding: 1.2rem;
            font-size: 1rem;
            touch-action: manipulation;
            min-height: 50px;
        }

        .btn {
            min-height: 48px;
            font-size: 0.95rem;
            padding: 0.8rem 1rem;
        }

        .input-group input[type="number"],
        .input-group input[type="range"],
        .input-group input[type="color"] {
            font-size: 1rem;
            padding: 0.6rem;
        }
    }

    @media (max-width: 480px) {
        .sidebar {
            width: 100%;
        }

        .menu-toggle {
            top: 0.5rem;
            left: 0.5rem;
            padding: 0.4rem;
        }
        
        .sidebar-title {
            font-size: 1.2rem;
        }
        
        .sidebar-section h3 {
            font-size: 1rem;
        }

        .file-input-label {
            padding: 1rem;
            flex-direction: column;
            text-align: center;
        }

        .zoom-controls {
            flex-wrap: wrap;
            gap: 0.3rem;
        }

        .zoom-btn {
            padding: 0.8rem;
            min-width: 50px;
        }

        .input-group-row {
            flex-direction: column;
            align-items: stretch;
        }
        
        .range-container {
            flex-direction: column;
            align-items: stretch;
        }
        
        .range-container input[type="number"] {
            width: 100%;
        }
    }

    .control-point {
        display: inline-block;
        width: 12px;
        height: 12px;
        background: #ff4444;
        border-radius: 50%;
        position: absolute;
        transform: translate(-50%, -50%);
        pointer-events: all;
    }
	.lien-externe {
  color: #0066cc;
  text-decoration: underline;
}

.lien-externe:hover {
  text-decoration: none;
}

/* Styles pour les boutons démo à droite */
.demo-buttons-container {
    position: absolute;
    right: -120px; /* Déplace le conteneur à droite du canvas */
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 10;
}

.demo-btn {
    padding: 8px 12px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: background-color 0.2s;
}

.demo-btn:hover {
    background-color: var(--accent-color);
}
.demo-buttons-container-left {
    position: absolute;
    left: -120px; /* Déplace le conteneur à gauche du canvas */
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 10;
}