/* 
Theme Name: Pura kaSaka Child Theme
Theme URI: https://github.com/elementor/hello-theme/
Description: Where dreams grow wild!
Author: Pura kaSaka
Author URI: https://shop.purakasaka.com/
Template: hello-elementor
Version: 1.0.1
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
*/

/*
    Add your custom styles here
*/






/*
    Botones animación
*/
 .wrapper {
    padding: 1.5rem 0;
    -webkit-filter: url('#goo');
            filter: url('#goo');
}
.button {
    display: inline-block;
    text-align: center;
    background: var(--color);
    color: var(--bg) !important;
    font-weight: bold;
    padding: 1.18em 1.32em 1.03em;
    line-height: 1;
    border-radius: 100px 10px 100px 100px;
    position: relative;
    min-width: 8.23em;
    text-decoration: none;
    font-family: var(--font);
    font-size: var(--e-global-typography-accent-font-size);
        text-transform: var(--e-global-typography-38c3bec-text-transform);
    font-weight: var(--e-global-typography-accent-font-weight);
    line-height: var(--e-global-typography-accent-line-height);
    letter-spacing: var(--e-global-typography-accent-letter-spacing);
}

.button:before,
.button:after {
    width: 4.4em;
    height: 2.95em;
    position: absolute;
    content: "";
    display: inline-block;
    background: var(--color);
    border-radius: 50%;
    -webkit-transition: -webkit-transform 1s ease;
    transition: -webkit-transform 1s ease;
    transition: transform 1s ease;
    transition: transform 1s ease, -webkit-transform 1s ease;
    -webkit-transform: scale(0);
            transform: scale(0);
    z-index: -1;
}

.button:before {
    top: -25%;
    left: 20%;
}

.button:after {
    bottom: -25%;
    right: 20%;
}

.button:hover:before,
.button:hover:after {
    -webkit-transform: none;
            transform: none;
}



/* Estilos para todos los campos de texto del formulario */
.wc-block-components-form .wc-block-components-text-input input[type="email"],
.wc-block-components-form .wc-block-components-text-input input[type="number"],
.wc-block-components-form .wc-block-components-text-input input[type="tel"],
.wc-block-components-form .wc-block-components-text-input input[type="text"],
.wc-block-components-form .wc-block-components-text-input input[type="url"],
.wc-block-components-text-input input[type="email"],
.wc-block-components-text-input input[type="number"],
.wc-block-components-text-input input[type="tel"],
.wc-block-components-text-input input[type="text"],
.wc-block-components-text-input input[type="url"] {
    color: var(--e-global-color-c5975f0) !important;
    background: var(--e-global-color-primary) !important;
    border: 0px !important;
    border-radius: 10px !important;
}

/* Estilos al activar (focus) los campos de texto */
.wc-block-components-form .wc-block-components-text-input input[type="email"]:focus,
.wc-block-components-form .wc-block-components-text-input input[type="number"]:focus,
.wc-block-components-form .wc-block-components-text-input input[type="tel"]:focus,
.wc-block-components-form .wc-block-components-text-input input[type="text"]:focus,
.wc-block-components-form .wc-block-components-text-input input[type="url"]:focus,
.wc-block-components-text-input input[type="email"]:focus,
.wc-block-components-text-input input[type="number"]:focus,
.wc-block-components-text-input input[type="tel"]:focus,
.wc-block-components-text-input input[type="text"]:focus,
.wc-block-components-text-input input[type="url"]:focus {
    background: var(--e-global-color-36f8d28) !important;
    color: var(--e-global-color-8b999cb) !important;
    border: 0px !important;
}

/* Estilos para el área de texto (notas del pedido) */
.wc-block-components-textarea {
    color: var(--e-global-color-c5975f0) !important;
    background: var(--e-global-color-primary) !important;
    border: 0px !important;
    border-radius: 10px !important;
}

/* Estilos al activar el área de texto */
.wc-block-components-textarea:focus {
    background: var(--e-global-color-36f8d28) !important;
    color: var(--e-global-color-8b999cb) !important;
    border: 0px !important;
}

/* Estilos para los campos desplegables (combobox) */
.wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input,
.wc-block-components-form .wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input {
    color: var(--e-global-color-c5975f0) !important;
    background: var(--e-global-color-primary) !important;
    border: 0px !important;
    border-radius: 10px !important;
}

/* Estilos al activar los campos desplegables */
.wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input:focus,
.wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input[aria-expanded="true"],
.wc-block-components-form .wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input:focus,
.wc-block-components-form .wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input[aria-expanded="true"] {
    background: var(--e-global-color-36f8d28) !important;
    color: var(--e-global-color-8b999cb) !important;
    border: 0px !important;
}

/* Estilos para las sugerencias del combobox */
.wc-block-components-combobox .wc-block-components-combobox-control .components-form-token-field__suggestions-list,
.wc-block-components-form .wc-block-components-combobox .wc-block-components-combobox-control .components-form-token-field__suggestions-list {
    color: var(--e-global-color-c5975f0) !important;
    background: var(--e-global-color-primary) !important;
    border: 0px !important;
}

/* Estilos para las sugerencias seleccionadas o destacadas */
.wc-block-components-combobox .wc-block-components-combobox-control .components-form-token-field__suggestions-list .components-form-token-field__suggestion.is-selected,
.wc-block-components-form .wc-block-components-combobox .wc-block-components-combobox-control .components-form-token-field__suggestions-list .components-form-token-field__suggestion.is-selected,
.wc-block-components-combobox .wc-block-components-combobox-control .components-form-token-field__suggestions-list .components-form-token-field__suggestion.is-highlighted,
.wc-block-components-form .wc-block-components-combobox .wc-block-components-combobox-control .components-form-token-field__suggestions-list .components-form-token-field__suggestion.is-highlighted {
    background: var(--e-global-color-36f8d28) !important;
    color: var(--e-global-color-8b999cb) !important;
}



/* app */
/* Gallinga App - Add Gallinga User UID to WooCommerce Order Meta */
add_action('woocommerce_checkout_update_order_meta', 'gallinga_app_add_user_uid_to_order_meta');
function gallinga_app_add_user_uid_to_order_meta($order_id) {
    if (isset($_GET['gallinga_user_uid'])) {
        // Esto guarda el UID del usuario de Gallinga como una "etiqueta" en el pedido general.
        update_post_meta($order_id, '_gallinga_user_uid', sanitize_text_field($_GET['gallinga_user_uid']));
    }
    if (isset($_GET['gallinga_user_email'])) {
         update_post_meta($order_id, '_gallinga_user_email', sanitize_email($_GET['gallinga_user_email']));
    }
}

