@font-face {
    font-family: 'Adelia';
    src: url('../fonts/Adelia.woff2') format('woff2'),
         url('../fonts/Adelia.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Muthiara';
    src: url('../fonts/Muthiara.woff2') format('woff2'),
         url('../fonts/Muthiara.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Avenue de Madison';
    src: url('../fonts/Avenue-de-Madison.woff2') format('woff2'),
         url('../fonts/Avenue-de-Madison.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}

html, body {
    margin: 0;
    padding: 0;
    overflow: hidden; /* Evitar scroll en la página principal */
    font-family: sans-serif;
}

#mp-editor-container {
    height: 100vh;
    height: -webkit-fill-available; /* Compatibilidad con Safari en iOS */
}

#canvas-container {
    overflow: hidden; 
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
}

canvas {
    border: 1px solid #d1d5db;
    background-color: #fff;
    cursor: default;
    max-width: none; 
    max-height: none;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    border-radius: 0.25rem;
    display: block;
    flex-shrink: 0;
}

#close-editor-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background-color: rgba(255, 255, 255, 0.85);
    color: #374151;
    border: 1px solid #d1d5db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 28px;
    font-weight: bold;
    font-family: sans-serif;
    line-height: 38px;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
}

#close-editor-btn:hover {
    background-color: #ffffff;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

#view-controls button {
    opacity: 0.9;
    transition: opacity 0.2s ease-in-out;
}

#view-controls button:hover {
    opacity: 1;
}

#zoom-in-btn, #zoom-out-btn {
    transition: background-color 0.1s ease-in-out, transform 0.1s ease-in-out;
}

#zoom-in-btn:active, #zoom-out-btn:active {
    background-color: #d1d5db;
    transform: scale(0.95);
}

#emoji-picker {
    display: none;
    grid-template-columns: repeat(auto-fill, minmax(30px, 1fr));
    gap: 8px;
    padding: 10px;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-top: 1rem;
}

.emoji-btn {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 2px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.emoji-btn:hover {
    background-color: #e5e7eb;
}

@media (min-width: 1024px) {
    html, body {
        width: 100vw !important;
        height: 100vh !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
    }

    #mp-editor-container {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        max-width: none !important;
        z-index: 9999 !important;
    }

    #canvas-container {
        width: 100% !important;
        height: 100% !important;
        max-width: none !important;
        max-height: none !important;
    }

    canvas {
        max-width: none !important;
        max-height: none !important;
        transform: none !important;
        transform-origin: top left !important;
    }
}