/* TWK PREMIUM LIGHT MARKET BACKDROP - visual only */
:root{--twk-p-green:#075d35;--twk-p-green2:#0b8a50;--twk-p-gold:#d9ad38;--twk-p-cream:#f7f8ef}
html,body{min-height:100%;}
body{position:relative;background:linear-gradient(135deg,#fbfcf8 0%,#f0f7ee 52%,#fffaf0 100%) !important;}
body::before{content:"";position:fixed;inset:0;z-index:-1;pointer-events:none;background-image:url('assets/twk-bull-bear-premium.png');background-repeat:no-repeat;background-position:center top;background-size:cover;opacity:.085;filter:saturate(.9) contrast(.95);}
body::after{content:"";position:fixed;inset:0;z-index:-1;pointer-events:none;background:linear-gradient(180deg,rgba(255,255,255,.28),rgba(255,255,255,.54));}
header,footer,.sidebar,.panel,.card,.summary,.feature,.twk-card,.twk-notify,.right,.main{position:relative;z-index:1;}
.sidebar,.panel,.summary,.card,.feature,.twk-card,.twk-notify{box-shadow:0 14px 34px rgba(11,76,45,.10),0 3px 10px rgba(11,76,45,.045)!important;backdrop-filter:blur(7px);}
.sidebar:hover,.panel:hover,.summary:hover,.card:hover,.feature:hover{transform:translateY(-4px) translateZ(7px);box-shadow:0 22px 48px rgba(11,76,45,.14)!important;}
.side-link{transition:transform .22s ease,box-shadow .22s ease,background .22s ease;}
.side-link:hover{transform:translateX(3px) translateZ(5px);box-shadow:0 10px 24px rgba(11,76,45,.10);}
/* Dashboard hero: preserve the banner ratio; never stretch/fill the unused area. */
.twk-hero-final{min-height:0!important;height:auto!important;padding:0!important;background:transparent!important;overflow:visible!important;}
.twk-hero-image-wrap{width:100%!important;height:auto!important;min-height:0!important;background:#fff!important;overflow:hidden!important;border-radius:22px!important;}
.twk-hero-image{display:block!important;width:100%!important;height:auto!important;max-height:none!important;object-fit:contain!important;object-position:center!important;border-radius:22px!important;}
.twk-hero-overlay{display:none!important;}
@media(max-width:820px){.twk-hero-image{width:100%!important;height:auto!important;object-fit:contain!important}.twk-hero-image-wrap{border-radius:18px!important}}
/* TWK FINAL LIGHT BULL/BEAR BACKDROP — visible on every page */
html{background:#f7faf5!important;}
body{background:linear-gradient(135deg,#fbfcf8 0%,#f1f8ef 52%,#fffaf0 100%)!important;position:relative;isolation:isolate;}
body::before{content:""!important;position:fixed!important;inset:0!important;z-index:0!important;pointer-events:none!important;background:url('assets/twk-bull-bear-background.png') center center/cover no-repeat!important;opacity:.48!important;filter:saturate(.92)!important;}
body::after{content:""!important;position:fixed!important;inset:0!important;z-index:0!important;pointer-events:none!important;background:linear-gradient(180deg,rgba(255,255,255,.14),rgba(255,255,255,.30))!important;}
body>*{position:relative;z-index:1;}
.twk-hero-final{margin-bottom:16px!important;}
.twk-hero-image-wrap{background:#fff!important;}

/* TWK final UI polish: soft background + perfectly aligned summary buttons */
body{background:linear-gradient(135deg,#f7faf7 0%,#eef6f0 52%,#fffaf0 100%)!important;}
body::after{background:linear-gradient(180deg,rgba(255,255,255,.18),rgba(255,255,255,.34))!important;}
.cards{align-items:stretch!important;}
.cards .summary{display:flex!important;flex-direction:column!important;min-height:178px!important;box-sizing:border-box!important;}
.cards .summary .btn{margin-top:auto!important;min-height:36px!important;box-sizing:border-box!important;white-space:nowrap!important;}
.cards .summary .sub{min-height:16px!important;}
@media(max-width:1200px){.cards .summary{min-height:178px!important;}}
@media(max-width:520px){.cards .summary{min-height:178px!important;}}

/* TWK member status + mobile Home routing */
.twk-membership-status{display:flex;align-items:center;justify-content:space-between;gap:18px;margin:0 0 20px;padding:18px 20px;border:1px solid #d9ad38;border-radius:16px;background:rgba(255,253,245,.96);box-shadow:0 10px 26px rgba(11,76,45,.10)}
.twk-membership-status.pending{border-color:#d9ad38}.twk-membership-status.active{border-color:#15915a;background:#f3fff8}.twk-membership-status.expired{border-color:#c62828;background:#fff5f5}
.twk-membership-label{font-size:12px;font-weight:800;letter-spacing:2px;color:#52675c}.twk-membership-value{font-size:22px;font-weight:900;color:#b3261e;margin-top:3px}.twk-membership-status.active .twk-membership-value{color:#087a35}.twk-membership-status.expired .twk-membership-value{color:#b3261e}.twk-membership-action{font-size:13px;font-weight:700;color:#30473b;margin-top:5px}
.twk-member-status-popup{position:fixed;left:50%;top:50%;transform:translate(-50%,-50%);width:min(520px,calc(100vw - 32px));z-index:99999;padding:24px;border-radius:20px;background:#fff;box-shadow:0 24px 70px rgba(0,0,0,.28);border:2px solid #d9ad38;text-align:center}.twk-member-status-popup.expired{border-color:#c62828}.twk-status-close{position:absolute;right:10px;top:8px;border:0;background:transparent;font-size:28px;line-height:1;color:#52675c;cursor:pointer}.twk-status-kicker{font-size:12px;font-weight:900;letter-spacing:2px;color:#52675c}.twk-status-title{font-size:26px;font-weight:900;color:#b3261e;margin:8px 0}.twk-member-status-popup.pending .twk-status-title{color:#b3261e}.twk-member-status-popup.expired .twk-status-title{color:#b3261e}.twk-status-action{font-size:14px;font-weight:700;color:#30473b;margin-bottom:18px}
@media(max-width:600px){.twk-membership-status{align-items:flex-start;flex-direction:column}.twk-membership-status .btn{width:100%;text-align:center;box-sizing:border-box}.twk-membership-value{font-size:20px}.twk-member-status-popup{padding:22px 18px}}


/* TWK FINAL MOBILE MENU + MEMBER HEADER FIX */
@media(max-width:980px){
  body.twk-member .twk-header,body.twk-admin .twk-header{position:sticky!important;top:0!important;height:72px!important;min-height:72px!important;padding:7px 10px!important;z-index:10000!important;}
  .twk-menu-btn{display:flex!important;align-items:center!important;justify-content:center!important;width:46px!important;height:46px!important;flex:0 0 46px!important;position:relative!important;z-index:10003!important;pointer-events:auto!important;font-size:26px!important;line-height:1!important;}
  .twk-brand-wrap{gap:10px!important;min-width:0!important;}
  .twk-brand{min-width:0!important;}
  .twk-brand .brand{width:50px!important;height:50px!important;}
  .twk-brand span{display:none!important;}
  .twk-top-nav{display:none!important;}
  .twk-header-right{margin-left:auto!important;min-width:0!important;}
  .twk-user-badge{display:grid!important;width:38px!important;height:38px!important;}
  .twk-head-logout{display:none!important;}
  body.twk-member .twk-sidebar,body.twk-admin .twk-sidebar{top:72px!important;bottom:0!important;width:min(285px,82vw)!important;transform:translateX(-110%)!important;transition:transform .22s ease!important;z-index:10002!important;}
  body.twk-member .twk-sidebar.open,body.twk-admin .twk-sidebar.open{transform:translateX(0)!important;}
  .twk-sidebar-backdrop{position:fixed!important;inset:72px 0 0!important;display:none!important;z-index:10001!important;background:rgba(0,25,15,.34)!important;backdrop-filter:blur(2px)!important;}
  .twk-sidebar-backdrop.show{display:block!important;}
  body.twk-menu-open{overflow:hidden!important;}
  body.twk-member .twk-main,body.twk-admin .twk-main{margin-left:0!important;}
}
@media(max-width:560px){
  body.twk-member .twk-header,body.twk-admin .twk-header{padding:7px 9px!important;}
  .twk-menu-btn{width:44px!important;height:44px!important;flex-basis:44px!important;}
  .twk-brand .brand{width:48px!important;height:48px!important;}
}


.twk-stat-value.twk-status-pending{color:#b3261e!important}.twk-stat-value.twk-status-pending small{color:#b3261e!important;display:block;font-size:11px;font-weight:800;margin-top:5px}

/* =========================================================
   TWK MASTER HEADER / MOBILE SHELL — FINAL CONSOLIDATED FIX
   One common shell for all member/admin pages.
   ========================================================= */
.twk-header .twk-brand .brand{width:54px!important;height:54px!important;max-width:54px!important;max-height:54px!important;object-fit:contain!important;border-radius:50%!important;display:block!important;flex:0 0 54px!important}
.twk-header .twk-menu-btn{flex:0 0 38px!important;box-sizing:border-box!important;pointer-events:auto!important}
.twk-sidebar{box-sizing:border-box!important;overflow-x:hidden!important}
.twk-sidebar-backdrop{pointer-events:auto!important}
@media(max-width:980px){
  .twk-header{height:70px!important;min-height:70px!important;width:100%!important;box-sizing:border-box!important;padding:7px 10px!important;overflow:hidden!important}
  .twk-menu-btn{display:flex!important;align-items:center!important;justify-content:center!important;width:46px!important;height:46px!important;flex:0 0 46px!important;font-size:25px!important;line-height:1!important;cursor:pointer!important;pointer-events:auto!important;position:relative!important;z-index:10003!important}
  .twk-header .twk-brand .brand{width:48px!important;height:48px!important;max-width:48px!important;max-height:48px!important;flex-basis:48px!important}
  .twk-brand-wrap{min-width:0!important;gap:8px!important}
  .twk-header-right{margin-left:auto!important;min-width:0!important}
  .twk-top-nav{display:none!important}
  .twk-head-logout{display:none!important}
  .twk-sidebar{top:70px!important;bottom:0!important;width:min(285px,84vw)!important;transform:translateX(-110%)!important;transition:transform .22s ease!important;z-index:10002!important;background:#fff!important;overflow-y:auto!important;overflow-x:hidden!important}
  .twk-sidebar.open{transform:translateX(0)!important}
  .twk-sidebar-backdrop{position:fixed!important;inset:70px 0 0!important;display:none!important;z-index:10001!important;background:rgba(0,25,15,.34)!important;backdrop-filter:blur(2px)!important}
  .twk-sidebar-backdrop.show{display:block!important}
  .twk-main{margin-left:0!important;min-height:calc(100vh - 70px)!important;width:100%!important;max-width:100%!important;box-sizing:border-box!important}
  .twk-main-inner{width:calc(100% - 18px)!important;max-width:100%!important;box-sizing:border-box!important;margin:0 auto!important}
  .twk-layout-bar{top:70px!important;max-width:100%!important;overflow:hidden!important}
}
@media(max-width:600px){
  .twk-header{padding:7px 8px!important}
  .twk-menu-btn{width:44px!important;height:44px!important;flex-basis:44px!important;font-size:24px!important}
  .twk-header .twk-brand .brand{width:44px!important;height:44px!important;max-width:44px!important;max-height:44px!important;flex-basis:44px!important}
  .twk-user-badge{width:36px!important;height:36px!important;flex:0 0 36px!important}
  .twk-layout-inner{width:calc(100% - 12px)!important;max-width:100%!important}
  .twk-layout-controls{max-width:100%!important;overflow-x:auto!important}
  .twk-main-inner>.section{max-width:100%!important;overflow-x:hidden!important}
  .twk-main-inner>.section img{max-width:100%;height:auto}
}
