/*
 * OptionsGEX Dual-Market Responsive Shell V1
 *
 * Presentation / navigation only.
 *
 * NSE strategy logic: untouched
 * Crypto strategy logic: untouched
 * FYERS Administration: untouched
 * Execution: untouched
 */

:root{
  --ogex-shell-bg:#071018;
  --ogex-shell-card:#0b1923;
  --ogex-shell-card-2:#102431;
  --ogex-shell-border:#234354;
  --ogex-shell-text:#e8f4fb;
  --ogex-shell-muted:#8fa9b9;
  --ogex-shell-accent:#46b8f5;
  --ogex-shell-green:#2edb93;
  --ogex-shell-orange:#f2b84b;
  --ogex-shell-red:#ff657a;
}


.ogex-dual-market-shell-v1{
  --ogex-shell-bottom-height:68px;
}


.ogex-shell-market-switch{
  display:grid;
  gap:6px;
}


.ogex-shell-market-switch-desktop{
  grid-template-columns:
    repeat(
      3,
      minmax(0,1fr)
    );

  margin:
    14px
    10px
    8px;

  padding:5px;

  border:
    1px
    solid
    var(--ogex-shell-border);

  border-radius:11px;

  background:
    #06121a;
}


.ogex-shell-domain-chip{
  min-height:38px;
  padding:7px 5px;
  border:1px solid transparent;
  border-radius:8px;
  background:transparent;
  color:var(--ogex-shell-muted);
  font-size:10px;
  font-weight:800;
  letter-spacing:.035em;
  cursor:pointer;
  transition:
    background .16s ease,
    color .16s ease,
    border-color .16s ease;
}


.ogex-shell-domain-chip:hover{
  color:var(--ogex-shell-text);
  background:#102431;
}


.ogex-shell-domain-chip.active{
  color:#effaff;
  border-color:#31769b;
  background:#12364a;
  box-shadow:
    inset 0 0 0 1px
    rgba(70,184,245,.08);
}


.ogex-shell-rail-context{
  margin:
    10px
    14px
    5px;

  color:#7bcfff;
  font-size:11px;
  font-weight:900;
  letter-spacing:.12em;
}


.ogex-shell-rail-group{
  margin:
    13px
    14px
    5px;

  padding-top:9px;

  border-top:
    1px solid
    rgba(80,126,150,.22);

  color:#698b9f;
  font-size:9px;
  font-weight:800;
  letter-spacing:.13em;
  text-transform:uppercase;
}


#appView .rail{
  overflow-y:auto;
  scrollbar-width:thin;
  scrollbar-color:
    #294a5d
    transparent;
}


#appView .rail button[data-page]{
  min-height:39px;
}


#appView .rail button[data-page="surface"]{
  font-weight:800;
}


.ogex-shell-crypto-subnav{
  display:grid;
  gap:5px;
  margin:
    3px
    9px
    14px;
  padding:
    8px;
  border:
    1px solid
    rgba(53,111,141,.36);
  border-radius:10px;
  background:
    rgba(6,20,29,.72);
}


.ogex-shell-virtual-nav{
  min-height:36px;
  padding:
    7px
    9px;
  border:
    1px solid
    transparent;
  border-radius:7px;
  background:
    transparent;
  color:
    #9fb7c5;
  text-align:left;
  font-size:11px;
  cursor:pointer;
}


.ogex-shell-virtual-nav:hover{
  border-color:
    #2a5368;
  background:
    #102634;
  color:
    #ecf9ff;
}


.ogex-shell-domain-hidden{
  display:none !important;
}


.ogex-shell-market-switch-mobile,
.ogex-shell-bottom-bar{
  display:none;
}


.ogex-shell-more-overlay{
  display:none;
  position:fixed;
  inset:0;
  z-index:25000;
  align-items:flex-end;
  justify-content:center;
  padding:
    16px
    16px
    max(
      16px,
      env(safe-area-inset-bottom)
    );
  background:
    rgba(0,7,12,.72);
  backdrop-filter:
    blur(5px);
}


.ogex-shell-more-overlay.show{
  display:flex;
}


.ogex-shell-more-sheet{
  width:min(
    620px,
    100%
  );
  max-height:
    min(
      78dvh,
      760px
    );
  overflow:hidden;
  border:
    1px solid
    #31566b;
  border-radius:
    18px
    18px
    14px
    14px;
  background:
    #081721;
  box-shadow:
    0 -20px 70px
    rgba(0,0,0,.48);
}


.ogex-shell-more-sheet > header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:
    16px
    17px
    13px;
  border-bottom:
    1px solid
    rgba(74,119,143,.28);
}


.ogex-shell-more-sheet header small{
  color:#79badc;
  font-size:10px;
  font-weight:850;
  letter-spacing:.12em;
}


.ogex-shell-more-sheet header h2{
  margin:3px 0 0;
  color:var(--ogex-shell-text);
  font-size:19px;
}


#ogexShellMoreClose{
  width:44px;
  height:44px;
  flex:0 0 44px;
  border:
    1px solid
    #36576a;
  border-radius:50%;
  background:
    #102633;
  color:#ecf9ff;
  font-size:25px;
  line-height:1;
  cursor:pointer;
}


.ogex-shell-more-body{
  display:grid;
  gap:7px;
  max-height:
    calc(78dvh - 78px);
  overflow-y:auto;
  padding:
    12px
    13px
    16px;
}


.ogex-shell-more-item{
  width:100%;
  min-height:48px;
  padding:
    11px
    13px;
  border:
    1px solid
    #294b5e;
  border-radius:10px;
  background:
    #0c202c;
  color:#e5f3fa;
  font-size:13px;
  font-weight:700;
  text-align:left;
  cursor:pointer;
}


.ogex-shell-more-item:hover{
  border-color:#4e98bd;
  background:#123044;
}


.ogex-shell-more-note{
  display:grid;
  gap:5px;
  margin-top:5px;
  padding:12px 13px;
  border:
    1px dashed
    #31576b;
  border-radius:10px;
  background:
    rgba(13,37,51,.48);
}


.ogex-shell-more-note strong{
  color:#bdeaff;
  font-size:12px;
}


.ogex-shell-more-note span{
  color:#8eaaba;
  font-size:11px;
  line-height:1.45;
}


.ogex-shell-sheet-open{
  overflow:hidden;
}


.ogex-shell-focus-flash{
  animation:
    ogexShellFocusFlash
    .85s ease;
}


@keyframes ogexShellFocusFlash{
  0%{
    box-shadow:
      0 0 0 0
      rgba(70,184,245,.7);
  }

  40%{
    box-shadow:
      0 0 0 3px
      rgba(70,184,245,.36);
  }

  100%{
    box-shadow:
      0 0 0 0
      rgba(70,184,245,0);
  }
}


/*
 * Crypto/System must not inherit the global
 * NSE snapshot summary strip.
 */
html[data-ogex-domain="crypto"] #assetTabs,
html[data-ogex-domain="crypto"] #summaryCards,
html[data-ogex-domain="system"] #assetTabs,
html[data-ogex-domain="system"] #summaryCards{
  display:none !important;
}


/*
 * Mobile shell.
 */
@media(max-width:900px){

  html,
  body{
    max-width:100%;
    overflow-x:hidden;
  }


  #appView.shell:not(.hidden){
    display:block !important;
    width:100%;
    min-width:0;
  }


  #appView > .rail{
    display:none !important;
  }


  #appView > main{
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box;
    padding-bottom:
      calc(
        var(--ogex-shell-bottom-height)
        + 18px
        + env(safe-area-inset-bottom)
      );
    overflow-x:clip;
  }


  #appView .page,
  #appView .panel,
  #appView .grid{
    min-width:0;
    max-width:100%;
  }


  .ogex-shell-market-switch-mobile{
    display:grid;
    grid-template-columns:
      repeat(
        3,
        minmax(0,1fr)
      );
    position:sticky;
    top:0;
    z-index:16000;
    gap:5px;
    margin:0;
    padding:
      8px
      9px;
    border-bottom:
      1px solid
      #244353;
    background:
      rgba(4,15,22,.96);
    backdrop-filter:
      blur(10px);
  }


  .ogex-shell-market-switch-mobile
  .ogex-shell-domain-chip{
    min-height:42px;
    font-size:10px;
  }


  #appView .topbar{
    position:relative;
    z-index:2;
  }


  .ogex-shell-bottom-bar{
    display:grid;
    grid-template-columns:
      repeat(
        4,
        minmax(0,1fr)
      );
    position:fixed;
    left:8px;
    right:8px;
    bottom:
      max(
        8px,
        env(safe-area-inset-bottom)
      );
    z-index:17000;
    min-height:
      var(--ogex-shell-bottom-height);
    gap:5px;
    padding:6px;
    border:
      1px solid
      #31576b;
    border-radius:15px;
    background:
      rgba(6,20,29,.97);
    box-shadow:
      0 12px 40px
      rgba(0,0,0,.44);
    backdrop-filter:
      blur(11px);
  }


  .ogex-shell-bottom-button{
    min-width:0;
    min-height:52px;
    padding:
      7px
      4px;
    border:
      1px solid
      transparent;
    border-radius:10px;
    background:
      transparent;
    color:#91acbc;
    font-size:11px;
    font-weight:800;
    cursor:pointer;
  }


  .ogex-shell-bottom-button.active{
    color:#effaff;
    border-color:#357798;
    background:#113348;
  }


  .ogex-shell-more-overlay{
    padding:
      10px
      8px
      calc(
        var(--ogex-shell-bottom-height)
        + 16px
        + env(safe-area-inset-bottom)
      );
  }


  .ogex-shell-more-sheet{
    width:100%;
    border-radius:
      18px
      18px
      12px
      12px;
  }
}


@media(max-width:540px){

  .ogex-shell-market-switch-mobile{
    padding:
      7px
      6px;
  }


  .ogex-shell-market-switch-mobile
  .ogex-shell-domain-chip{
    padding:
      5px
      3px;
    font-size:9px;
    letter-spacing:.015em;
  }


  .ogex-shell-bottom-bar{
    left:5px;
    right:5px;
    gap:3px;
    padding:5px;
  }


  .ogex-shell-bottom-button{
    font-size:10px;
  }


  .ogex-shell-more-body{
    padding:
      10px;
  }
}
