/* ===========================
   ZEWED SIZE GUIDE POPUP
=========================== */

#zscs-size-guide-popup{
    position:fixed;
    inset:0;
    display:none;
    z-index:999999;
}

#zscs-size-guide-popup.active{
    display:block;
}

.zscs-popup-overlay{
    position:absolute;
    inset:0;
    background:rgba(0,0,0,.65);
    backdrop-filter:blur(4px);
}

.zscs-popup-box{

    position:absolute;

    top:50%;
    left:50%;

    transform:translate(-50%,-50%);

    width:95%;
    max-width:820px;

    max-height:90vh;

    overflow:hidden;

    background:#ffffff;

    border-radius:20px;

    box-shadow:0 30px 80px rgba(0,0,0,.30);

    animation:zscsPopup .25s ease;

}

@keyframes zscsPopup{

    from{

        opacity:0;
        transform:translate(-50%,-46%);

    }

    to{

        opacity:1;
        transform:translate(-50%,-50%);

    }

}

/* ===========================
   HEADER
=========================== */

.zscs-popup-header{

    display:flex;

    align-items:center;

    justify-content:space-between;

    padding:24px 30px;

    border-bottom:1px solid #ececec;

    background:#fff;

}

.zscs-popup-header h2{

    margin:0;

    font-size:24px;

    font-weight:700;

    color:#111;

    letter-spacing:.3px;

}

.zscs-popup-close{

    width:42px;

    height:42px;

    border:none;

    background:#f6f6f6;

    border-radius:50%;

    cursor:pointer;

    font-size:24px;

    transition:.25s;

}

.zscs-popup-close:hover{

    background:#111;

    color:#fff;

}

/* ===========================
   TAB BAR
=========================== */

.zscs-popup-tabs{

    display:flex;

    background:#fff;

    border-bottom:1px solid #ececec;

}

.zscs-popup-tabs button{

    flex:1;

    height:58px;

    border:none;

    background:#fff;

    cursor:pointer;

    font-size:15px;

    font-weight:600;

    transition:.25s;

}

.zscs-popup-tabs button:hover{

    background:#f7f7f7;

}

.zscs-popup-tabs button.active{

    background:#111;

    color:#fff;

}

/* ===========================
   CONTENT
=========================== */

.zscs-popup-content{

    background:#fff;

    padding:30px;

    overflow-y:auto;

    max-height:65vh;

}

.zscs-tab{

    display:none;

}

.zscs-tab.active{

    display:block;

}
/* ===========================
   UNIT TOGGLE
=========================== */

.zscs-unit-toggle{

    display:flex;
    justify-content:flex-end;
    gap:8px;
    margin-bottom:24px;

}

.zscs-unit-toggle button{

    min-width:70px;
    height:38px;

    border:1px solid #ddd;
    border-radius:999px;

    background:#fff;
    color:#111;

    cursor:pointer;

    font-size:13px;
    font-weight:600;

    transition:.25s;

}

.zscs-unit-toggle button:hover{

    border-color:#111;

}

.zscs-unit-toggle button.active{

    background:#111;
    color:#fff;
    border-color:#111;

}


/* ===========================
   SIZE TABLE
=========================== */

.zscs-size-table{

    width:100%;

    border-collapse:collapse;

    background:#fff;

}

.zscs-size-table thead{

    background:#111;

}

.zscs-size-table thead th{

    color:#fff;

    padding:16px;

    text-align:center;

    font-size:14px;

    font-weight:600;

}

.zscs-size-table tbody td{

    padding:16px;

    text-align:center;

    font-size:14px;

    border-bottom:1px solid #efefef;

}

.zscs-size-table tbody tr{

    transition:.2s;

}

.zscs-size-table tbody tr:hover{

    background:#fafafa;

}

.zscs-size-table tbody td:first-child{

    font-weight:700;

    color:#111;

}

.zscs-size-table tbody tr:last-child td{

    border-bottom:none;

}


/* Zebra Rows */

.zscs-size-table tbody tr:nth-child(even){

    background:#fcfcfc;

}


/* Rounded Header */

.zscs-size-table thead th:first-child{

    border-top-left-radius:12px;

}

.zscs-size-table thead th:last-child{

    border-top-right-radius:12px;

}
/* ===========================
   HOW TO MEASURE
=========================== */

.zscs-measure{

    display:flex;
    justify-content:center;
    align-items:center;

}

.zscs-measure img{

    width:100%;
    max-width:900px;
    height:auto;
    display:block;
    border-radius:12px;

}


/* ===========================
   FIND MY SIZE
=========================== */

.zscs-find-size{

    max-width:420px;

    margin:auto;

    display:flex;

    flex-direction:column;

    gap:18px;

}

.zscs-find-size input,
.zscs-find-size select{

    width:100%;

    height:50px;

    border:1px solid #ddd;

    border-radius:12px;

    padding:0 16px;

    font-size:15px;

    transition:.25s;

    background:#fff;

}

.zscs-find-size input:focus,
.zscs-find-size select:focus{

    outline:none;

    border-color:#111;

}

.zscs-find-btn{

    height:52px;

    border:none;

    border-radius:12px;

    background:#111;

    color:#fff;

    font-size:15px;

    font-weight:600;

    cursor:pointer;

    transition:.25s;

}

.zscs-find-btn:hover{

    transform:translateY(-2px);

    box-shadow:0 12px 25px rgba(0,0,0,.18);

}


/* ===========================
   RESULT CARD
=========================== */

.zscs-result{

    margin-top:24px;

    padding:24px;

    border-radius:16px;

    background:#fafafa;

    text-align:center;

    display:none;

}

.zscs-result.active{

    display:block;

}

.zscs-result h3{

    margin:0;

    font-size:34px;

    font-weight:700;

    color:#111;

}

.zscs-result p{

    margin-top:10px;

    color:#666;

    font-size:15px;

}

.zscs-confidence{

    display:inline-block;

    margin-top:12px;

    padding:8px 16px;

    border-radius:999px;

    background:#111;

    color:#fff;

    font-size:13px;

    font-weight:600;

}
/* ==========================================
   MOBILE RESPONSIVE
========================================== */

@media (max-width:768px){

    .zscs-popup-box{

        width:96%;
        max-height:94vh;
        border-radius:18px;

    }

    .zscs-popup-header{

        padding:20px;

    }

    .zscs-popup-header h2{

        font-size:20px;

    }

    .zscs-popup-content{

        padding:20px;

        max-height:68vh;

    }

    .zscs-popup-tabs{

        overflow-x:auto;
        white-space:nowrap;

    }

    .zscs-popup-tabs button{

        min-width:180px;

    }

    .zscs-size-table{

        min-width:650px;

    }

    .zscs-measure{

        flex-direction:column;

        align-items:flex-start;

    }

    .zscs-measure img{

        width:100%;

        max-width:300px;

        margin:auto;

    }

}

@media (max-width:480px){

    .zscs-popup-header{

        padding:16px;

    }

    .zscs-popup-content{

        padding:16px;

    }

    .zscs-unit-toggle{

        justify-content:center;

    }

    .zscs-find-btn{

        width:100%;

    }

}


/* ==========================================
   SCROLLBAR
========================================== */

.zscs-popup-content::-webkit-scrollbar{

    width:8px;

}

.zscs-popup-content::-webkit-scrollbar-track{

    background:#f3f3f3;

}

.zscs-popup-content::-webkit-scrollbar-thumb{

    background:#bcbcbc;
    border-radius:20px;

}

.zscs-popup-content::-webkit-scrollbar-thumb:hover{

    background:#888;

}


/* ==========================================
   TRANSITIONS
========================================== */

.zscs-popup *,
.zscs-popup *:before,
.zscs-popup *:after{

    box-sizing:border-box;

}

.zscs-popup button,
.zscs-popup input,
.zscs-popup select{

    transition:.25s ease;

}

.zscs-popup table{

    border-spacing:0;

}


/* ==========================================
   PREMIUM FINISH
========================================== */

.zscs-popup-box{

    border:1px solid #ececec;

}

.zscs-popup-header{

    background:#ffffff;

}

.zscs-popup-tabs{

    position:sticky;

    top:0;

    z-index:20;

}

.zscs-size-table{

    border-radius:14px;

    overflow:hidden;

}
/* ==========================================
   MOBILE IMPROVEMENTS v2
========================================== */

@media (max-width:768px){

    /* Popup */
    .zscs-popup-box{
        width:98%;
        max-width:98%;
        border-radius:16px;
    }

    .zscs-popup-header{
        padding:18px;
    }

    .zscs-popup-header h2{
        font-size:18px;
    }

    /* Tabs */
    .zscs-popup-tabs{
        display:grid;
        grid-template-columns:repeat(3,1fr);
        overflow:hidden;
    }

    .zscs-popup-tabs button{
        min-width:unset;
        font-size:13px;
        padding:14px 6px;
    }

    /* Table */
    .zscs-tab#chart{
        overflow-x:auto;
    }

    .zscs-size-table{
        min-width:620px;
    }

    /* Better inputs */
    .zscs-find-size input,
    .zscs-find-size select{
        height:54px;
        font-size:16px;
    }

    .zscs-find-btn{
        height:56px;
        font-size:16px;
    }

}
