/*
Theme Name: Theme Sleek
Description: Theme Sleek — a trimmed, sleek storefront-style theme (based on SCDev Single).
Version: 1.0
Author: SCDev
Text Domain: theme-sleek
*/

/* Page Banner Styles */
.scdev-page-banner {
    position: relative;
    width: 100%;
    min-height: 180px;
    background-size: cover;
    background-position: center;
    border-radius: 18px 18px 0 0;
    overflow: hidden;
    display: flex;
    align-items: stretch;
}
.scdev-page-banner.no-image {
    background: linear-gradient(135deg, rgba(108, 123, 237, 0.92), rgba(121, 67, 160, 0.92));
}
.scdev-page-banner-inner {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
    background: rgba(0, 0, 0, 0.4);
    color: #fff;
    text-align: center;
}
.scdev-page-banner.no-image .scdev-page-banner-inner {
    background: transparent;
}
.scdev-page-banner-inner h1.scdev-page-title {
    margin: 0;
    font-size: var(--scdev-h1-size, 34px);
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    color: #fff;
}
/* Ensure the content handles dark mode smoothly */
.scdev-single-content {
    background: transparent;
    color: inherit;
}

.scdev-page-header-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.scdev-page-tagline {
    margin: 0;
    font-size: 18px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

/* Standard WordPress image alignment classes */
.alignleft { float: left; margin-right: 1.5em; margin-bottom: 1.5em; }
.alignright { float: right; margin-left: 1.5em; margin-bottom: 1.5em; }

/* Center the notification panel on mobile */
@media (max-width: 768px) {
    .scdev-notif-panel {
        position: fixed !important;
        top: 50% !important;
        left: 50% !important;
        transform: translate(-50%, -50%) !important;
        right: auto !important;
        bottom: auto !important;
        width: 90% !important;
        max-width: 400px !important;
        max-height: 80vh !important;
        z-index: 10090 !important;
    }
}

.aligncenter { clear: both; display: block; margin-left: auto; margin-right: auto; margin-bottom: 1.5em; text-align: center; }
.aligncenter img { margin-left: auto; margin-right: auto; display: block; }
figure.wp-block-image.aligncenter { margin-left: auto; margin-right: auto; text-align: center; }
figure.wp-block-image.aligncenter img { margin: 0 auto; display: block; }

/* Prevent horizontal scroll on mobile */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        width: 100% !important;
    }
    
    * {
        max-width: 100vw !important;
        box-sizing: border-box !important;
    }

    /* Hide desktop sidebars on mobile */
    .scdev-desktop-only {
        display: none !important;
    }



    /* Mobile modal scrolling */
    #scdev-mobile-modal-left .scdev-sidebar-content,
    #scdev-mobile-modal-right .scdev-sidebar-content {
        flex: 1 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        height: 0 !important; /* forces flex child to scroll rather than expand */
    }

    .scdev-category-tabs {
        position: relative !important; 
        top: auto !important;
        left: auto !important;
        right: auto !important;
        z-index: auto !important;
        background: transparent !important;
        backdrop-filter: none !important;
        margin: 0 !important;
        padding: 10px 10px 6px !important;
        border-radius: 999px !important;
        box-shadow: none !important;
        overflow-x: auto !important;
    }

    .scdev-category-tabs::-webkit-scrollbar {
        display: none;
    }
}

/* Hide mobile elements on desktop */
@media (min-width: 769px) {
    .scdev-mobile-only,
    #scdev-mobile-circle-left,
    #scdev-mobile-circle-right,
    #scdev-mobile-modal-left,
    #scdev-mobile-modal-right {
        display: none !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/* Show mobile circles on mobile */
@media (max-width: 768px) {
    #scdev-mobile-circle-left,
    #scdev-mobile-circle-right {
        display: flex !important;
    }
}



/* Night mode – coins badge text color */
body.night-mode div[style*="background: rgba(255,184,0,0.96)"] {
    color: #f5f5f5 !important;
}


/* Mobile sidebar styles removed - now handled by sliding-sidebars.css */

@media (min-width: 769px) {
    .sidebar-mobile-toggle {
        display: none !important;
    }
}


/* Prevent sidebar panels from causing horizontal scroll when off-screen */
.scdev-sidebars-container,
.scdev-sidebar {
    overflow: hidden;
}

.scdev-single-stage,
.scdev-single-container {
    align-items: stretch;
}
.scdev-page-banner.no-image {
    background: linear-gradient(135deg, rgba(108, 123, 237, 0.92), rgba(121, 67, 160, 0.92));
}
.scdev-page-banner-inner {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
    background: rgba(0, 0, 0, 0.4);
    color: #fff;
    text-align: center;
}
.scdev-page-banner.no-image .scdev-page-banner-inner {
    background: transparent;
}
.scdev-page-banner-inner h1.scdev-page-title {
    margin: 0;
    font-size: var(--scdev-h1-size, 34px);
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    color: #fff;
}
/* Ensure the content handles dark mode smoothly */
.scdev-single-content {
    background: transparent;
    color: inherit;
}

.scdev-page-header-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.scdev-page-tagline {
    margin: 0;
    font-size: 18px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

/* Standard WordPress image alignment classes */
.alignleft { float: left; margin-right: 1.5em; margin-bottom: 1.5em; }
.alignright { float: right; margin-left: 1.5em; margin-bottom: 1.5em; }
.aligncenter { clear: both; display: block; margin-left: auto; margin-right: auto; margin-bottom: 1.5em; text-align: center; }
.aligncenter img { margin-left: auto; margin-right: auto; display: block; }
figure.wp-block-image.aligncenter { margin-left: auto; margin-right: auto; text-align: center; }
figure.wp-block-image.aligncenter img { margin: 0 auto; display: block; }

/* Prevent horizontal scroll on mobile */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        width: 100% !important;
    }
    
    * {
        max-width: 100vw !important;
        box-sizing: border-box !important;
    }

    /* Hide desktop sidebars on mobile */
    .scdev-desktop-only {
        display: none !important;
    }



    /* Mobile modal scrolling */
    #scdev-mobile-modal-left .scdev-sidebar-content,
    #scdev-mobile-modal-right .scdev-sidebar-content {
        flex: 1 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        height: 0 !important; /* forces flex child to scroll rather than expand */
    }

 .scdev-category-tabs {
        position: relative !important; 
        top: auto !important;
        left: auto !important;
        right: auto !important;
        z-index: auto !important;
        background: transparent !important;
        backdrop-filter: none !important;
        margin: 0 !important;
        padding: 10px 10px 6px !important;
        border-radius: 999px !important;
        box-shadow: none !important;
        overflow-x: auto !important;
    }

    .scdev-category-tabs::-webkit-scrollbar {
        display: none;
    }
}

/* Hide mobile elements on desktop */
@media (min-width: 769px) {
    .scdev-mobile-only,
    #scdev-mobile-circle-left,
    #scdev-mobile-circle-right,
    #scdev-mobile-modal-left,
    #scdev-mobile-modal-right {
        display: none !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/* Show mobile circles on mobile */
@media (max-width: 768px) {
    #scdev-mobile-circle-left,
    #scdev-mobile-circle-right {
        display: flex !important;
    }
}



/* Night mode – coins badge text color */
body.night-mode div[style*="background: rgba(255,184,0,0.96)"] {
    color: #f5f5f5 !important;
}


/* Mobile sidebar styles removed - now handled by sliding-sidebars.css */

@media (min-width: 769px) {
    .sidebar-mobile-toggle {
        display: none !important;
    }
}


/* Prevent sidebar panels from causing horizontal scroll when off-screen */
.scdev-sidebars-container,
.scdev-sidebar {
    overflow: hidden;
}

.scdev-single-stage,
.scdev-single-container {
    overflow-x: visible; /* allow full-bleed children to escape container */
    max-width: 1900px;
    margin: 0 auto;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Full-bleed hero and banner: extend to the viewport edges and center inner content */
.scdev-page-banner,
.scdev-category-hero {
    width: 100%;
    max-width: 100%;
    position: relative;
    left: 0;
    transform: none;
    border-radius: 0;
    box-sizing: border-box;
}

.scdev-page-banner-inner,
.scdev-category-hero-inner {
    max-width: 1900px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

/* Mobile Notification Bell and Primary Nav Styling */
@media (max-width: 768px) {
    /* Ensure launcher flex layout */
    .scdev-primary-nav-launcher {
        display: flex;
        align-items: center;
        gap: 8px;
    }
    /* Show bell on mobile and position it at top left */
    #scdev-notif-wrap {
        display: block !important;
        bottom: auto !important;
        top: 10px !important;
        left: 10px !important;
        right: auto !important;
        position: fixed !important;
        margin: 0 !important;
    }
    #scdev-notif-bell {
        width: 40px !important;
        height: 40px !important;
    }
}
@media (min-width: 769px) {
    #scdev-notif-wrap {
        display: none !important;
    }
}
/* Hide all nav elements on the login page */
.page-template-page-login .scdev-primary-nav-shell,
.page-template-page-login .scdev-classic-nav-wrapper,
.page-template-page-login #fnv2-shell,
.page-template-page-login .scdev-footer-nav-wrapper,
.page-template-page-login .scdev-top-right-controls,
.page-template-page-login #mnv2-shell,
.page-template-page-login #scdev-notif-wrap,
.page-template-page-login .scdev-global-back-btn {
    display: none !important;
}

/* Login page — bottom padding so content clears the fixed PWA bar */
.page-template-page-login .scdev-single-content {
    padding-bottom: 80px !important;
}

/* Global — ensure bottom content is never hidden behind fixed mobile buttons */
.scdev-single-content {
    padding-bottom: 80px;
}

/* Scrollable comments list */
.scdev-comments-list-wrap {
    max-height: min(420px, 55vh);
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 4px;
    margin-bottom: 16px;
    scrollbar-width: thin;
    scrollbar-color: rgba(0,0,0,0.2) transparent;
}
.scdev-comments-list-wrap .scdev-comment-list {
    margin: 0;
    padding: 0;
}
.scdev-comments-list-wrap::-webkit-scrollbar { width: 4px; }
.scdev-comments-list-wrap::-webkit-scrollbar-track { background: transparent; }
.scdev-comments-list-wrap::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.2); border-radius: 2px; }
.page-template-page-login .wp-block-button__link,
.page-template-page-login .wp-block-buttons .wp-block-button__link {
    margin-top: 10px !important;
    transform: none !important;
    transition: background-color 0.2s ease, color 0.2s ease, opacity 0.2s ease !important;
}
.page-template-page-login .wp-block-button__link:hover {
    transform: none !important;
}
@media (max-width: 768px) {
    .pcl-tabs-bar {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        transform: none !important;
        width: 100% !important;
        max-width: 100% !important;
        z-index: auto !important;
        margin-top: 0 !important;
        box-shadow: none !important;
    }
    .pcl-feed-wrap {
        padding-top: 0 !important;
    }
}

/* Hide desktop hamburger and mobile launchers on desktop, but allow the primary modal launcher */
@media (min-width: 769px) {
    .scdev-classic-mobile-toggle,
    .scdev-footer-mobile-toggle,
    .scdev-mobile-only,
    #scdev-mobile-circle-left,
    #scdev-mobile-circle-right,
    #scdev-mobile-modal-left,
    #scdev-mobile-modal-right {
        display: none !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/* Strip stray editor-saved background-colors from post content */
.scdev-post-content p[style],
.scdev-post-content span[style],
.scdev-post-content div[style],
.scdev-post-content li[style],
.scdev-post-content h1[style],
.scdev-post-content h2[style],
.scdev-post-content h3[style],
.scdev-post-content h4[style],
.scdev-post-content h5[style],
.scdev-post-content h6[style] {
    background-color: transparent !important;
    background: transparent !important;
}
/* Exception: keep intentional highlight classes */
.scdev-post-content .highlight-yellow { background-color: #ffeb3b !important; }
.scdev-post-content .highlight-blue   { background-color: #03a9f4 !important; }

/* Hide only the floating FCommerce blue cart button; keep the header/nav cart icon visible. */
#fc-floating-cart {
    display: none !important;
}

/* ── Picollage → Theme Bridge ──────────────────────────────────────
   Remap PCL CSS variables to the theme's variables so Picollage
   automatically inherits brand colors, fonts and typography from
   the Customizer without touching the plugin files.
   ------------------------------------------------------------------ */

:root {
    /* PCL brand colors now follow the theme's button color */
    --pcl-primary:    var(--scdev-btn-bg,    #667eea);
    --pcl-primary-dk: var(--scdev-btn-bg-hover, #764ba2);
    /* PCL accent keeps its own warm tone but can be overridden */
    --pcl-accent:     var(--scdev-btn-bg,    #667eea);
}

/* Ensure no default body margin interferes with full-bleed bands */
html, body {
    margin: 0;
    padding: 0;
}

/* Ensure main content areas have no side gutters */
.scdev-single-content,
.scdev-single-stage,
.scdev-single-container,
.scdev-single-inner {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Remove unintended left margin on category tabs and grids */
.scdev-category-tabs,
.scdev-category-grid {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* High-specificity override to ensure the topbar stretches fully to the viewport edges */
.scdev-home-topbar {
    position: relative !important;
    left: 0 !important;
    transform: none !important;
    width: 100% !important;
    max-width: 100% !important;
}

/* Sticky navigation that sits below the topbar and pins to top when scrolled */
.scdev-sticky-nav {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 99999 !important;
    width: 100% !important;
    background: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

.scdev-sticky-nav-inner {
    max-width: 1900px;
    margin: 0 auto;
    padding: 0 24px; /* keep horizontal padding, remove vertical */
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Topbar simple menu between header and hero */
.scdev-topbar-nav { width: 100%; }
.scdev-top-menu { list-style: none; margin: 0; padding: 10px 0; display: flex; gap: 28px; align-items: center; justify-content: flex-start; }
.scdev-top-menu li { margin: 0; }
.scdev-top-menu a { color: #ffffff; text-decoration: none; padding: 8px 12px; border-radius: 8px; font-weight: 700; }
.scdev-top-menu a:hover { background: rgba(255,255,255,0.06); }

@media (max-width: 900px) {
    .scdev-top-menu { gap: 14px; padding: 8px 0; }
}

.scdev-home-topbar > p {
    margin: 0;
    padding: 8px 12px;
    text-align: center;
    color: #fff;
}

/* Base wrapper — font family and size from theme */
.pcl-wrap, .pcl-feed-wrap, .pcl-view-wrap,
.pcl-modal, .pcl-confirm-box,
.pcl-wallet-wrap, .pcl-earnings-wrap,
.pcl-photos-wrap, .pcl-my-list {
    font-family: var(--scdev-font-family, inherit);
    font-size:   var(--scdev-font-size,   16px);
    color: inherit;
}

/* ── H1 equivalent: Page / gallery title ── */
.pcl-view-title, .pcl-photos-heading {
    font-family:  var(--scdev-font-family, inherit);
    font-size:    var(--scdev-h1-size,  32px);
    font-weight:  var(--scdev-h1-weight, 700);
    color: inherit;
}

/* ── H2 equivalent: Section headings / modal titles ── */
.pcl-confirm-title, .pcl-wp-title,
.pcl-my-title, .pcl-pcl-upload-title {
    font-family:  var(--scdev-font-family, inherit);
    font-size:    var(--scdev-h2-size,  28px);
    font-weight:  var(--scdev-h2-weight, 700);
    color: inherit;
}

/* ── H3 equivalent: Card group headings ── */
.pcl-photos-heading, .pcl-str-info-title {
    font-family:  var(--scdev-font-family, inherit);
    font-size:    var(--scdev-h3-size,  24px);
    font-weight:  var(--scdev-h3-weight, 600);
    color: inherit;
}

/* ── H4 equivalent: Card titles, item names ── */
.pcl-card-title, .pcl-my-title,
.pcl-package-card h3, .pcl-slider-name,
.pcl-stat-val {
    font-family:  var(--scdev-font-family, inherit);
    font-size:    var(--scdev-h4-size,  20px);
    font-weight:  var(--scdev-h4-weight, 600);
    color: inherit;
}

/* ── H5 equivalent: Body text, descriptions, form labels, general content ── */
.pcl-card-desc, .pcl-description,
.pcl-field label, .pcl-gate-inner p,
.pcl-str-perk, .pcl-balance-bar,
.pcl-photos-hint, .pcl-tip-result,
.pcl-table td, .pcl-pcl-wd-row,
.pcl-view-meta, .pcl-lock-overlay,
.pcl-author-bar {
    font-family: var(--scdev-font-family, inherit);
    font-size:   var(--scdev-h5-size,   18px);
    font-weight: 400;
    color: inherit;
}

/* ── H6 equivalent: Meta, timestamps, counts, secondary info ── */
.pcl-card-meta, .pcl-card-footer,
.pcl-my-meta, .pcl-stat-label,
.pcl-slider-count, .pcl-cat-tag,
.pcl-pcl-cat-tag, .pcl-pcl-wp-note,
.pcl-cat, .pcl-pcl-back {
    font-family: var(--scdev-font-family, inherit);
    font-size:   var(--scdev-h6-size,   16px);
    font-weight: 400;
    color: inherit;
    opacity: 0.7;
}

/* Primary action buttons follow theme button variables */
.pcl-submit-btn, .pcl-add-btn, .pcl-upload-btn,
.pcl-pkg-cta, .pcl-btn-primary, .pcl-confirm-ok {
    background-color: var(--scdev-btn-bg,    rgba(102,126,234,0)) !important;
    color:            var(--scdev-btn-color, #333333) !important;
    font-family:      var(--scdev-font-family, inherit) !important;
    font-size:        var(--scdev-h5-size, 16px) !important;
    border:           var(--scdev-btn-border-width, 1px) solid var(--scdev-btn-border-color, #333333) !important;
    border-radius:    var(--scdev-btn-radius, 6px) !important;
}
.pcl-submit-btn:hover, .pcl-add-btn:hover, .pcl-upload-btn:hover,
.pcl-pkg-cta:hover, .pcl-btn-primary:hover, .pcl-confirm-ok:hover {
    background-color: var(--scdev-btn-bg-hover,    #667eea) !important;
    color:            var(--scdev-btn-color-hover, #333333) !important;
}

/* Post feed modal background adapts to color scheme */
[data-color-scheme="dark"] .pcl-modal,
[data-color-scheme="dark"] .pcl-confirm-box {
    background: #1a1a2e;
    color: #f0f0f0;
    border-color: rgba(255,255,255,0.1);
}
[data-color-scheme="light"] .pcl-modal,
[data-color-scheme="light"] .pcl-confirm-box {
    background: #ffffff;
    color: inherit;
}
