/* =============================================
   Off Canvas Sidebar — Frontend Styles
   ============================================= */

/* --- Overlay --- */
.ocs-overlay {
    position: fixed;
    inset: 0;
    background: var(--ocs-overlay, rgba(0,0,0,0.5));
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
}
.ocs-overlay.ocs-active {
    opacity: 1;
    pointer-events: all;
}

/* --- Panel --- */
.ocs-panel {
    position: fixed;
    top: 0;
    bottom: 0;
    width: 300px;
    max-width: 90vw;
    z-index: 9999;
    overflow-y: auto;
    box-shadow: 0 0 30px rgba(0,0,0,0.3);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 60px 24px 24px;
    box-sizing: border-box;
}

.ocs-panel.ocs-side-right {
    right: 0;
    transform: translateX(100%);
}
.ocs-panel.ocs-side-left {
    left: 0;
    transform: translateX(-100%);
}
.ocs-panel.ocs-open {
    transform: translateX(0);
}

/* Push animation — body shifts */
body.ocs-push-right  { transition: margin-left 0.35s cubic-bezier(0.4,0,0.2,1); }
body.ocs-push-open   { margin-left: 0 !important; }

/* --- Close Button --- */
.ocs-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    color: #fff;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
    padding: 0;
}
.ocs-close:hover { opacity: 1; }

/* --- Content --- */
.ocs-content {
    color: #fff;
}
.ocs-content ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.ocs-content ul li {
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.ocs-content ul li a {
    display: block;
    padding: 14px 0;
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.2s, padding-left 0.2s;
}
.ocs-content ul li a:hover {
    color: #ccc;
    padding-left: 8px;
}

/* --- Trigger Button --- */
.ocs-trigger {
    position: fixed;
    z-index: 9997;
    background: #1a1a1a;
    color: #fff;
    border: none;
    cursor: pointer;
    border-radius: 4px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.25);
    transition: background 0.2s, transform 0.2s;
    font-size: 14px;
}
.ocs-trigger:hover { background: #333; }

/* Positions */
.ocs-pos-top-left     { top: 20px;    left: 20px;  }
.ocs-pos-top-right    { top: 20px;    right: 20px; }
.ocs-pos-middle-left  { top: 50%;     left: 20px;  transform: translateY(-50%); }
.ocs-pos-middle-right { top: 50%;     right: 20px; transform: translateY(-50%); }
.ocs-pos-bottom-left  { bottom: 20px; left: 20px;  }
.ocs-pos-bottom-right { bottom: 20px; right: 20px; }

/* Hamburger bars */
.ocs-hamburger-bar {
    display: block;
    width: 22px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Hamburger → X when open */
.ocs-trigger.ocs-trigger-open .ocs-hamburger-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.ocs-trigger.ocs-trigger-open .ocs-hamburger-bar:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
.ocs-trigger.ocs-trigger-open .ocs-hamburger-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Accessibility */
.ocs-panel:focus { outline: none; }
