/* Variables */
:root {
    --wpomnix-primary-color: #3BA0F9
}

/* Container panel */
.omnixrp-panel {
    --omnixrp-header-height: 70px;
    --omnixrp-panel-top-offset: calc(var(--wp-admin--admin-bar--height, 0px) + 20px);
    position: fixed;
    bottom: 0;
    width: calc(100vw - 40px);
    max-width: calc(100vw - 40px);
    left: 50%;
    transform: translateX(-50%);
    height: calc(100vh - var(--omnixrp-panel-top-offset, 20px));
    max-height: 100vh;
    border-radius: 8px 8px 0 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
    z-index: 999999;
    display: none;
    overflow: hidden;
}

/* Header (draggable) */
.omnixrp-panel .omnixrp-panel-header {
    padding: 10px 20px;
    background: #042984;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    height: var(--omnixrp-header-height);
}

.omnixrp-panel .omnixrp-panel-title {
    font-size: 1rem;
    font-weight: 600;
}

.omnixrp-panel .omnixrp-panel-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    width: 35px;
}

.omnixrp-panel .omnixrp-url-input {
    width: 180px;
    font-size: 11px;
    padding: 2px 4px;
}

/* Tabs */
.omnixrp-panel .omnixrp-panel-tabs {
    display: flex;
    gap: 8px;
    padding: 6px 8px;
    flex-wrap: wrap;
}

.omnixrp-panel .omnixrp-tab-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    border: 0;
    border-radius: 4px;
    height: 50px;
    width: 50px;
    background-color: rgba(0,0,0,0.25);
    color: #fff;
}

.omnixrp-panel .omnixrp-tab-btn.is-active {
    box-shadow: inset 0 0 0 1px #fff;
}

.omnixrp-panel .omnixrp-close {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background-color: #d12222;
    color: #fff;
    border: 0;
    position: absolute;
    right: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

/* Body / iframe */
.omnixrp-panel .omnixrp-panel-body {
    background: #f1f1f1;
    height: 100%;
}

.omnixrp-panel .omnixrp-frame-wrapper {
    margin: 0 auto;
    height: 100%;
    border-radius: 0;
    overflow: hidden;
}

#omnixrp-frame {
    border: 0;
    width: 100%;
    height: calc(100% - var(--omnixrp-header-height));
    background: #fff;
}

/* Responsive toggler */
.omnixrp-responsive-toggler{
    position: fixed;
    bottom: 20px;
    left: 0;
    color: #fff;
    z-index: 1040;
    cursor: pointer;
    background-color: var(--wpomnix-primary-color);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 10px;
    border-radius: 0 99px 99px 0;
    transform: translateX(calc(-100% + 70px));
    transition: transform 0.6s ease-in-out;
    box-shadow: -1px 0px 30px -9px rgba(0,0,0,0.75);
    -webkit-box-shadow: -1px 0px 30px -9px rgba(0,0,0,0.75);
    -moz-box-shadow: -1px 0px 30px -9px rgba(0,0,0,0.75);
}

body.omnixrp-scroll-disabled .omnixrp-responsive-toggler{
    z-index: 1099;
}

.omnixrp-responsive-toggler:hover{
    transform: translateX(0);
}

.omnixrp-responsive-toggler .toggler-area{
    display: flex;
    justify-content: center;
    align-items: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #18609f;
    overflow: hidden;
    box-shadow: -4px 5px 16px 3px rgba(255,255,255,0.5);
    -webkit-box-shadow: -4px 5px 16px 3px rgba(255,255,255,0.5);
    -moz-box-shadow: -4px 5px 16px 3px rgba(255,255,255,0.5);
}

.omnixrp-responsive-toggler .toggler-area .responsive-icon{
    width: 100%;
    height: 100%;
}

/* helper css */
.omnixrp-tooltip {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.omnixrp-tooltip .tooltiptext {
    visibility: hidden;
    position: absolute;
    background-color: #555;
    color: #fff;
    text-align: center;
    padding: 5px 10px;
    border-radius: 6px;
    z-index: 1;
    opacity: 0;
    transition: opacity .6s;
}

.omnixrp-tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

.omnixrp-tooltip .tooltip-bottom {
    top: calc(100% + 7px);
    left: 50%;
    transform: translateX(-50%);
}

.omnixrp-tooltip .tooltip-bottom::after {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: transparent transparent #555 transparent;
}

.omnixrp-scroll-disabled {
	overflow-y: hidden;
}

.omnixrp-scroll-disabled::before {
	content: '';
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1090;
}

html:has(body.omnixrp-scroll-disabled){
    overflow: unset;
    overflow-y: hidden;
}

@media screen and (max-width: 480px) {
    .omnixrp-panel .omnixrp-panel-header{
        justify-content: center !important;
    }
	.omnixrp-panel .omnixrp-panel-title{
        display: none !important;
    }
    .omnixrp-panel .omnixrp-panel-actions{
        width: auto;
    }
}