/* Container panel */
.rtda-rvp-panel {
    --rtda-rvp-header-height: 70px;
    --rtda-rvp-panel-top-offset: calc(var(--wp-admin--admin-bar--height, 0px) + 80px);
    position: fixed;
    bottom: 0;
    width: calc(100vw - 100px);
    max-width: calc(100vw - 100px);
    left: 50%;
    transform: translateX(-50%);
    height: calc(100vh - var(--rtda-rvp-panel-top-offset, 80px));
    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) */
.rtda-rvp-panel .rvp-panel-header {
    padding: 10px 20px;
    background: #23282d;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    height: var(--rtda-rvp-header-height);
}

.rtda-rvp-panel .rvp-panel-title {
    font-size: 1rem;
    font-weight: 600;
}

.rtda-rvp-panel .rvp-panel-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.rtda-rvp-panel .rvp-url-input {
    width: 180px;
    font-size: 11px;
    padding: 2px 4px;
}

/* Tabs */
.rtda-rvp-panel .rvp-panel-tabs {
    display: flex;
    gap: 4px;
    padding: 6px 8px;
    flex-wrap: wrap;
}

.rtda-rvp-panel .rvp-tab-btn {
    border-radius: 0;
    font-size: 11px;
    line-height: 1.4;
    border: 0;
    border-radius: 4px;
    height: 40px;
    width: 40px;
    background-color: rgba(0,0,0,0.25);
    color: #fff;
}

.rtda-rvp-panel .rvp-tab-btn.is-active {
    box-shadow: inset 0 0 0 1px #fff;
}

.rtda-rvp-panel .rvp-close {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background-color: red;
    color: #fff;
    border: 0;
    position: absolute;
    right: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Body / iframe */
.rtda-rvp-panel .rvp-panel-body {
    background: #f1f1f1;
    height: 100%;
}

.rtda-rvp-panel .rvp-frame-wrapper {
    margin: 0 auto;
    height: 100%;
    border-radius: 0;
    overflow: hidden;
}

#rvp-frame {
    border: 0;
    width: 100%;
    height: calc(100% - var(--rtda-rvp-header-height));
    background: #fff;
}

/* Collapsed */
.rvp-panel.rvp-panel-collapsed .rvp-panel-body,
.rvp-panel.rvp-panel-collapsed .rvp-panel-tabs {
    display: none;
}

/* Responsive toggler */
.rtda-responsive-toggler{
    position: fixed;
    top: calc(var(--wp-admin--admin-bar--height, 0px) + 20px);
    right: 20px;
    color: #000;
    z-index: 1040;
    cursor: pointer;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #9cee69;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

body.rvp-scroll-disabled .rtda-responsive-toggler{
    z-index: 1099;
}

/* helper css */
.rtda-tooltip {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.rtda-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;
}

.rtda-tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

.rtda-tooltip .tooltip-bottom {
    top: calc(100% + 7px);
    left: 50%;
    transform: translateX(-50%);
}

.rtda-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;
}

.rvp-scroll-disabled {
	overflow-y: hidden;
}

.rvp-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.rvp-scroll-disabled){
    overflow: unset;
    overflow-y: hidden;
}

@media screen and (max-width: 991px) {
   .rtda-responsive-toggler {
    	bottom: 20px;
    	left: 15px;
        top: initial;
	}
}

@media screen and (max-width: 480px) {
    .rtda-rvp-panel .rvp-panel-header{
        justify-content: center !important;
    }
	.rtda-rvp-panel .rvp-panel-title{
        display: none !important;
    }
}