        body {
            font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
            margin: 0; display: flex; flex-direction: column; height: 100vh;
            background-color: #f0f2f5;
        }

        #toolbar {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white; padding: 12px 20px;
            display: flex; align-items: center; gap: 15px;
            box-shadow: 0 4px 6px rgba(0,0,0,0.1); z-index: 10;
        }

        h1 { margin: 0; font-size: 1.2rem; margin-right: auto; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }

        button {
            padding: 10px 20px; border: none; border-radius: 25px; cursor: pointer;
            font-weight: bold; font-size: 0.9rem; transition: transform 0.2s, box-shadow 0.2s;
            display: flex; align-items: center; gap: 5px;
        }
        button:hover { transform: translateY(-2px); box-shadow: 0 5px 10px rgba(0,0,0,0.2); }
        
        .btn-save { background-color: #f1c40f; color: #333; }
        .btn-load { background-color: #e67e22; color: white; }
        .btn-compile { background-color: #00cec9; color: #2d3436; }

        #blocklyDiv { flex-grow: 1; width: 100%; }
        #fileInput { display: none; }

        #back_btn
        {background-color: red;
        color: white;}




        /* Contêiner da Tela de Carregamento (Fundo Escuro) */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Fundo preto semi-transparente para focar no carregamento */
    background-color: rgba(18, 18, 30, 0.95); 
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.6s ease-out;
}

/* Contêiner do Spinner de Blocos */
.block-spinner {
    width: 40px;
    height: 40px;
    position: relative;
    /* Faz o contêiner girar */
    transform: rotate(45deg); 
    animation: rotate-parent 1.8s infinite linear;
}

/* Estilo para cada um dos quatro blocos internos */
.block-spinner div {
    width: 50%;
    height: 50%;
    position: absolute;
    /* Aplica um pequeno delay na animação de cada bloco */
    animation: bounce 1.8s infinite ease-in-out; 
}

/* Posicionamento e cores vibrantes dos blocos */
.block-spinner div:nth-child(1) {
    top: 0;
    left: 0;
    background-color: #FF5733; /* Vermelho-laranja */
}

.block-spinner div:nth-child(2) {
    top: 0;
    right: 0;
    background-color: #33FF57; /* Verde brilhante */
    animation-delay: 0.3s;
}

.block-spinner div:nth-child(3) {
    bottom: 0;
    left: 0;
    background-color: #3357FF; /* Azul intenso */
    animation-delay: 0.6s;
}

.block-spinner div:nth-child(4) {
    bottom: 0;
    right: 0;
    background-color: #FF33A1; /* Rosa choque */
    animation-delay: 0.9s;
}

/* Animação que faz o contêiner principal girar lentamente */
@keyframes rotate-parent {
    0% { transform: rotate(45deg); }
    100% { transform: rotate(405deg); }
}

/* Animação que faz cada bloco individualmente crescer e encolher */
@keyframes bounce {
    0%, 100% { transform: scale(1.0); }
    50% { transform: scale(1.2); } /* Aumenta um pouco no meio */
}

/* Classe de JS para esconder a tela */
.loaded {
    opacity: 0 !important;
    visibility: hidden;
}