 
    #map {
      height: 100%;
    }
   
    #floating-panel {
      position: absolute;
      top: 10px;
      left: 25%;
      z-index: 5;
      background-color: #fff;
      padding: 5px;
      border: 1px solid #999;
      text-align: center;
      font: 12px / 20px 'Helvetica Neue', Arial, Helvetica, sans-serif;
      line-height: 30px;
      padding-left: 10px;
    }
    #floating-panel {
      background-color: #fff;
      border: 1px solid #999;
      left: 25%;
      padding: 5px;
      position: absolute;
      top: 10px;
      z-index: 5;
    }
      
 

      #map .mapboxgl-popup-content
      {
        background: #ffffff;
        font-weight: 300;
          font-size: 14px;
          overflow: hidden;
          color: #000000;
          width: 262px !important;
          max-width: calc(100vw - 32px) !important;
          border-radius:0.75rem;
      }

       #map .mapboxgl-popup-content h3{    
        /*text-transform: uppercase;    */
        text-align: center;    
        margin-top: 5px;    
        color: #000000;
        font-size: 16px
        }

    
        #map .mapboxgl-popup-content .data_block{
        text-align: center;
        }
        #map .mapboxgl-popup-content img{  
        max-width: 100%;   
        margin: auto;  
        display: block;
        }
        #map .mapboxgl-popup-content .data_block .left,#map .mapboxgl-popup-content .data_block .center, #map .mapboxgl-popup-content .data_block .right{   
        display: inline-block;    
        width: 49%;    
        font-size: 14px;    
        margin: 0px auto;
        }
        
        /*btn css*/
        #map .mapboxgl-popup-content .data_block_btn{
        text-align: center;
        }
        
        #map .mapboxgl-popup-content .data_block_btn .left{   
        display: inline-block;    
        width: 28%;    
        font-size: 9px;    
        }
        
        #map .mapboxgl-popup-content .data_block_btn .right{   
        display: inline-block;    
        width: 70%;    
        font-size: 14px;  
        }
        
        #map .mapboxgl-popup-content a.btn_view_more_head {
            border: 1px solid #83a4a4;
            color: #ffffff;
             padding: 8px; 
            display: block;
            max-width: 215px;
            text-align: center;
            margin: 0 auto 9px auto;   
            /* font-weight: 400; */
            font-size: 8px;
            background: #3276B1;
            border-radius:0.75rem;
        }
        
      
        
        
        #map .mapboxgl-popup-content .data_block  label{      
        margin-right: 10px;    
        font-weight: 600;    
        display: inline-block;
        color:#000;
        }
        #map .mapboxgl-popup-content .data_block .left img{     
        width: 12px;     
        margin-right: 5px;    
        display: inline-block;
        }
        #map .mapboxgl-popup-content .data_block .right img{    
        width: 16px;    
        margin-right: 5px;    
        display: inline-block;
        }
        #map .mapboxgl-popup-content p{  

            line-height: 12px;
    text-align: justify;
    font-size: 10px;
        } 
        .mapboxgl-popup-anchor-top .mapboxgl-popup-tip
        {
              border-bottom-color: #000 !important;
        }
        #map .mapboxgl-popup-content a.btn_view_more {   
         border: 1px solid #83a4a4;   
         color: #83a4a4;   
         padding: 8px;    
         display: block;   
         max-width: 130px;   
         text-align: center;   
         margin: 15px auto 9px 117px;    
         font-weight: 400;    
         font-size: 16px;
         text-decoration: none;
         }
         #map .mapboxgl-popup-content a.btn_view_more:hover {    
         background: #83a4a4;    
         color: #000 !important;
         }
        #map .mapboxgl-popup-content a.btn_view_more {
        border: 1px solid #83a4a4;    
        color: #ffffff;    
        padding: 8px;    
        display: block;    
        max-width: 215px;    
        text-align: center;    
        margin: 0 auto 9px auto;    
        font-weight: 400;    
        font-size: 16px;
        background:#000000;
        }
        #map .mapboxgl-popup-content a.btn_view_more:hover {    
        background: #000000;    
        color: #ffffff !important;
        }
        /* Hide Mapbox's native close button — replaced by .popup-map-close inside content */
        #map .mapboxgl-popup-close-button,
        #map .mapboxgl-popup-content .mapboxgl-popup-close-button
        { display: none !important; }

        /* Custom close button inside popup content — FEAT-041 */
        .popup-map-close {
          position: absolute;
          top: 6px;
          right: 6px;
          z-index: 10;
          background: rgba(0,0,0,0.55);
          border: none;
          border-radius: 50%;
          width: 28px;
          height: 28px;
          display: flex;
          align-items: center;
          justify-content: center;
          font-size: 13px;
          color: #fff;
          cursor: pointer;
          line-height: 1;
          padding: 0;
          touch-action: manipulation;
        }
        .popup-map-close:hover { background: rgba(0,0,0,0.8); }
        
        .mapboxgl-ctrl-top-left, .mapboxgl-ctrl-top-right, .mapboxgl-ctrl-bottom-left, .mapboxgl-ctrl-bottom-right {
            position: absolute;
            pointer-events: none;
            z-index: 2;
            margin-top: 76px;
        }

        /* Lift bottom controls above the ticker bar (48px) + safe gap */
        .mapboxgl-ctrl-bottom-right,
        .mapboxgl-ctrl-bottom-left {
            margin-bottom: 56px;
        }

        .fusion-sticky-header-wrapper{
        height: auto !important;
        }
        .fusion-header{
        display: none;
        }
        
        .fullscreen {
          width: 100%;
          height: 100%;
        }
        
        /*new style*/
        /* Base styles */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar-brand img {
  width: 60%;
}

.navbar-toggler {
  display: none; /* Hide by default */
}

.collapse {
  display: flex;
  justify-content: flex-end;
}

/* Mapbox container styles */
.mapbox-container {
  position: relative;
  height: 100vh; /* Adjust as needed */
}

.search-bar-container {
    position: absolute;
    top: 32px;
    z-index: 1000;
    display: flex;
    width: 100%;
    left: 0;
    right:0;
    margin:0 auto;
}
.search-panel {
    max-width: 600px;
    margin: 0 auto;
    background: linear-gradient(90deg, rgba(217, 217, 217, 0.5) 0%, rgba(115, 115, 115, 0.5) 100%);
    padding: 8px;
    border-radius: 9px;
    backdrop-filter: blur(20px);
}
.width100percent{width:100%;}
.width70percent{width:70%;}
.mapboxgl-ctrl-top-right{bottom: 110px !important;
    right: 10px !important;}

@media (max-width: 767px){
    /* Hide native Mapbox zoom — replaced by #mobile-zoom-controls (position:fixed) */
    .mapboxgl-ctrl-top-right { display: none !important; }
}

/* Mobile custom zoom control — position:fixed so it stacks with other fixed buttons */
#mobile-zoom-controls {
    display: none; /* hidden on desktop — desktop uses native Mapbox control */
}
@media (max-width: 767px) {
    #mobile-zoom-controls {
        display: flex;
        flex-direction: column;
        position: fixed;
        bottom: calc(179px + env(safe-area-inset-bottom, 0px));
        right: 6px;
        z-index: 400;
        background: rgba(10, 10, 14, 0.88);
        border: 1px solid rgba(255, 255, 255, 0.18);
        border-radius: 8px;
        overflow: hidden;
        backdrop-filter: blur(10px);
    }
    #mzoom-in, #mzoom-out {
        background: none;
        border: none;
        color: rgba(255, 255, 255, 0.85);
        width: 36px;
        height: 29px;
        font-size: 20px;
        line-height: 1;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        touch-action: manipulation;
    }
    #mzoom-in { border-bottom: 1px solid rgba(255, 255, 255, 0.15); }
    #mzoom-in:active, #mzoom-out:active { background: rgba(255, 255, 255, 0.1); }
}

.mapboxgl-ctrl-top-right .mapboxgl-ctrl {
        bottom: 0 !important;
        right: 0 !important;
        position: absolute;
    }

 .toggleweb {
        display: flex !important;
    }
    
    .togglemobile {
        display: none !important;
    }
    

/* Mobile view */
@media (max-width: 992px) {

#map .mapboxgl-popup-content h3 {
    /*text-transform: uppercase;*/
    text-align: center;
    margin-top: 5px;
    color: #000;
    font-size: 13px;
}

#map .mapboxgl-popup-content {
    background: #ffffff;
    font-weight: 300;
    /* font-size: 17px; */
    overflow: hidden;
    color: #000;
    width: 262px !important;
}


  .navbar-nav .nav-item {
    display: none; /* Hide navbar items */
  }

  .navbar-toggler {
    display: block; /* Show toggle button */
  }

  .navbar-brand {
    flex: 1; /* Ensure logo and toggle button are inline */
  }

  .navbar-brand img {
    width: 50%; /* Adjust logo size for mobile view */
  }

  /* Hide search bar and select option in navbar on mobile */
  .navbar-nav .nav-item {
    display: none;
  }

  /* Adjust search bar and select option in mapbox for mobile view */
  .search-bar-container {
        position: absolute;
        top: 32px;
        z-index: 1000;
        display: flex;
        gap: 0px;
        padding: 0px 0px;
        width: 95%;
    }

    
    .toggleweb {
        display: none !important;
    }
    
    .togglemobile {
        display: flex !important;
    }


  .selectcompanymobile {
    width: 100%; /* Full width for mobile view */
  }
}

@media (max-width: 576px) {
  .navbar-brand img {
    width: 40%; /* Adjust logo size for smaller mobile view */
  }
}


.logo_width {
    width: 64% !important; 
    display: inline-block;
}

.selectcss {
    background: linear-gradient(90deg, rgba(217, 217, 217, 0.5) 0%, rgba(115, 115, 115, 0.5) 100%);
    backdrop-filter: blur(20px);
    border-radius: 0.75rem;
    border-color:#36adad;
}

.borderradius {
    border-radius: 1.5rem;
}

.heightcss {
    height: 1.1em !important;
}

.marginleft {
    margin-left: auto !important;
}

.margintop {
    margin-top:10px
}

.marginright {
    margin-right: 1rem !important;
}

.marginleftsecond {
    margin-left: 1rem !important;
}



.menuwidth {
    max-width:1350px !important;
    left:65%;
}

.choices {
    position: relative;
    overflow: hidden;
    margin-bottom: 0px;
    border-radius: 0.75rem;
	border: 1px solid #36adad;
	box-shadow: 0 0 0 2px #36adad;
	font-size: 14px;
	font-family: 'Helvetica Neue', Arial, Helvetica, sans-serif;
    background: linear-gradient(90deg, rgba(60, 60, 60, 0.75) 0%, rgba(25, 25, 25, 0.75) 100%);
    backdrop-filter: blur(20px);
}

/* Ensure inner container doesn't override the gradient */
.choices__inner {
    background: transparent !important;
}

/* Selected value (closed state) */
.choices__inner .choices__list--single .choices__item {
    color: #fff;
}

/* Selected option (open dropdown) */
.choices__list--dropdown .choices__item--selectable.is-selected,
.choices__list[aria-expanded] .choices__item--selectable.is-selected {
    color: #fff;
}

.is-flipped .choices__list--dropdown, .is-flipped .choices__list[aria-expanded] {
    top: 0 !important;
    bottom: 100%;
    margin-top: 0;
    margin-bottom: -1px;
    border-radius: 0.75rem;
	height:300px !important;
}



.choices__list--dropdown, .choices__list[aria-expanded] {
    /*visibility: hidden;*/
    z-index: 1;
    position: absolute;
    width: 100%;
    background: linear-gradient(90deg, rgba(60, 60, 60, 0.85) 0%, rgba(25, 25, 25, 0.85) 100%);
    backdrop-filter: blur(20px);
    border: 1px solid #ddd;
    top: 100%;
    margin-top: -36px !important;
    border-radius: 0.75rem;
    overflow: hidden;
    word-break: break-all;
    will-change: visibility;
    color: #fff; /* default text color in dropdown */
}

/* Dropdown items text color */
.choices__list--dropdown .choices__item,
.choices__list[aria-expanded] .choices__item {
    color: #fff;
}

/* Highlighted (hover/keyboard) item */
.choices__list--dropdown .choices__item--selectable.is-highlighted,
.choices__list[aria-expanded] .choices__item--selectable.is-highlighted {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

/* Search input inside open dropdown */
.choices[data-type*=select-one] .choices__input {
    color: #fff;
}

.choices[data-type*=select-one] .choices__input::placeholder {
    color: rgba(255, 255, 255, 0.85);
}
.choices[data-type*=select-one] .choices__input {
    display: block;
    width: 100%;
    padding-left: 11px !important;
    border-bottom: 1px solid #ddd;
    background-color: #fff;
    margin: 0;
}

.choices__list--dropdown .choices__item--selectable[data-select-text], .choices__list[aria-expanded] .choices__item--selectable[data-select-text] {
    font-size:14px;
    font-family:'Helvetica Neue', Arial, Helvetica, sans-serif;
   
}

.is-open .choices__inner {
   border-radius: 0.75rem;
}

.is-focused .choices__inner, .is-open .choices__inner {
    box-shadow: 0 0 0 2px #36adad;
}

.mapboxgl-ctrl-top-right .mapboxgl-ctrl-group {
    display:flex /* Change from column to row */
}

.mapboxgl-ctrl-group button {
    margin-right: 4px; /* Optional: Add some spacing between buttons */
}

.nav-link {
    display: block;
    padding: 0.1rem 2rem;
    transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out;
}

.nav.nav-pills {
    background: rgba(0, 0, 0, 0);
    border-radius: 0.75rem;
    position: absolute;
    width: 180px;
    height: 25px;
	border:1px solid #2f466d;
	z-index:1000;
	bottom: 25px;
    right: 10px;
}

/* Desktop: move day/night pills to right of searchbox (top-right) */
@media (min-width: 992px) {
    #tabs-pricing {
        position: absolute;
        top: 32px;
        right: 10px;
        bottom: auto;
        left: auto;
    }
}
@media (max-width:767px){
    .nav.nav-pills {
        position: fixed !important;
        bottom: calc(100px + env(safe-area-inset-bottom, 0px)) !important;
        right: 10px !important;
        left: auto !important;
    }
}
.nav.nav-pills .nav-link {
    z-index: 3;
    color: #ffffff;
    border-radius: 0.5rem;
    background-color: inherit;
}

.nav.nav-pills .nav-link.active {
    animation: 0.2s ease;
    box-shadow: 0px 1px 5px 1px #ddd;
    background-color: #fff !important;
    color: #000;
}

.nav.nav-pills .nav-link:hover:not(.active) {
    color: #ffffff;
}



.widthMap {
    width: 100%;
    height: auto;
    margin-top:-14px;
}

.compLogo {
    width:20%;
    margin-bottom:20px
}

.analyze-action {
  position: fixed;
  left: 30px;
  top: 140px;
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  border-radius: 5px;
  padding: 2px;
  cursor: pointer;
  z-index: 1001;
}

.company-action {
  position: fixed;
  left: 30px;
  top: 180px;
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  border-radius: 5px;
  padding: 2px;
  cursor: pointer;
  z-index: 1001;
}

.watchlist-action {
  position: fixed;
  left: 30px;
  top: 220px;
  background: transparent;
  border-radius: 5px;
  padding: 2px;
  cursor: pointer;
  z-index: 1001;
}
.watchlist-action svg {
  transition: stroke 0.2s ease, fill 0.2s ease;
  display: block;
}
.watchlist-action.active svg {
  stroke: #36adad;
}

.company-action img {
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.company-action.active img {
  background: rgba(200, 200, 200, 0.95);
  border-radius: 50%;
  padding: 6px; /* increase hit area and create circular background */
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.analyze-action img {
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.analyze-action.active img {
  background: rgba(200, 200, 200, 0.95);
  border-radius: 50%;
  padding: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* Background wrapper that visually includes analyze/company/watchlist action buttons */
.actions-bg {
  position: fixed;
  left: 25px;
  top: 120px;
  width: 45px;
  height: 155px;
  background: rgba(115, 115, 115, 0.85);
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  z-index: 1000;
}

.view-action {
    position: absolute;
    right: 0;
    top: 90px;
    background: white;
    padding: 5px 10px;
    border-top-left-radius: 20px;
    border-bottom-left-radius: 20px;
    width: 40px;                  /* collapsed width (enough for chevron) */
    overflow: hidden;             /* hides the text */
    white-space: nowrap;
    cursor: pointer;
    transition: width 0.3s ease;  /* smooth expand */
    z-index: 9999;
  }
  
  .view-action svg {
    flex-shrink: 0;               /* keep SVG always visible */
  }
  
  .view-action p {
    margin: 0;
    margin-left: 8px;
    opacity: 0;                   /* hidden initially */
    transition: opacity 0.2s ease;
  }
  
  .view-action:hover {
    width: 120px;                 /* expanded width */
  }
  
  .view-action:hover p {
    opacity: 1;                   /* fade in text */
  }
  
  .btn-toggle-overview {
    border-radius: 20px;
    width: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 25px;
  }
.overview-container {
    position: absolute;
    left: 100px;
    top: 120px;
    background: linear-gradient(270deg, rgba(28, 28, 28, 0.95) 0%, rgba(18, 18, 18, 0.95) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 5px;
    border-radius: 9px;
    width: 720px;
    max-width: 720px;
    max-height: 700px;
    overflow: hidden;
    z-index: 500;  /* below Bootstrap modal (1055) so modal renders on top */
}

.overview-scroll-body {
    overflow-y: auto;
    max-height: 490px;
}

.time-to-buy-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.ttb-icon {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: white;
    flex-shrink: 0;
}
.ttb-text {
    color: #4f8ef7;
    font-size: 13px;
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 2px;
}
.time-to-buy-btn:hover .ttb-text { color: #7ab3ff; }

.company-types-container {
    position: absolute;
    left: 100px;
    top: 120px;
    background: linear-gradient(90deg, rgba(217, 217, 217, 0.5) 0%, rgba(115, 115, 115, 0.5) 100%);
    padding: 5px;
    border-radius: 9px;
    max-width: 450px;
    max-height: 700px;
    overflow-y: auto;   /* BUG-009 fix: same panel, same fix */
    backdrop-filter: blur(20px);
    z-index: 500;  /* below Bootstrap modal (1055) so modal renders on top */
}

.overview-items thead {
  color: white;
  border: none;
  font-size: 15px;
}

.change-view {
  padding-left: 5px;
}

.leader-content th, .leader-content tr, .leader-content td {
  border: none;
}

/* FEAT-014: clickable overview rows */
.overview-row { transition: background 0.15s ease; }
.overview-row:hover { background: rgba(255,255,255,0.07) !important; }


.overview-actions {
    margin: auto;
    gap: 2px;
    flex-wrap: nowrap;
}

.overview-actions button {
    background: transparent;
    color: white;
    border: 1px solid white;
    font-size: 9px;
    padding: 4px 2px;
    white-space: nowrap;
    min-width: 0;
}

.overview-items{
    margin: auto;
    padding: 3px;
}



.overview-items span {
  font-size: 15px;
}

.overview-items p {
  margin-bottom: 0;
  font-size: 12px;
}

@media (max-width: 992px) {
    
    .togglecss {
        top: 553px;
        flex-wrap: nowrap;
        margin-bottom: 61px;
        left: -95px;
    }  
    
    .widthMap {
       width: 100%;
       height:auto;
       margin-top:10px;
    }
    
    .compLogo {
        width:50%;
        margin-bottom:20px
    }
   
}

/* Ensure background stays behind buttons on mobile and aligns with their responsive positions */
@media (max-width: 768px) {
  .actions-bg {
    left: 5px;
    top: 30px;
    width: 45px;
    height: 145px;
  }
}

/* .btnModalClose removed — replaced by .ai-modal-close in tab bar */


.mapboxgl-ctrl-top-right .mapboxgl-ctrl {
    margin: 468px 10px 0 0;
    float: right;
}

.togglecss {
   
    bottom: 20px;
    right: 10px;
}

/* Notebooks and smaller desktops (1024px - 1280px) */
@media only screen and (min-width: 1024px) and (max-width: 1280px) {
   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
       margin: 470px 10px 0 0;  /* Adjust positioning */
    }
    
    .togglecss {
    	top: 551px;
    	left: 80px;
    }
}

/* Desktops (1281px - 1440px) */
@media only screen and (min-width: 1281px) and (max-width: 1440px) {
   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
       margin: 460px 10px 0 0;  /* Adjust positioning */
    }
    
    .togglecss {
        top: 551px;
        left: 80px;
    }
}

/* Large desktops (1441px and above) */
@media only screen and (min-width: 1441px) {
   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
       margin: 468px 10px 0 0;  /* Adjust positioning */
    }
    
    .togglecss {
    	top: 515px;
    	left: -95px;
    }
}

/*@media only screen and (max-width: 480px) {*/
  /* Styles for small smartphones */
/*   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {*/
/*       margin: 370px 10px 0 0;*/
/*        float: right;*/
/*    } */
    
/*    .togglecss {*/
/*    	top: 455px;*/
/*    	flex-wrap: nowrap;*/
/*    	margin-bottom: 61px;*/
/*    	left: -95px;*/
/*    }*/
/*}*/

/*@media only screen and (max-width: 768px) {*/
  /* Your mobile styles go here */
  
/*   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {*/
/*       margin: 430px 10px 0 0;*/
/*        float: right;*/
/*    } */
    
/*    .togglecss {*/
/*    	top: 515px;*/
/*    	flex-wrap: nowrap;*/
/*    	margin-bottom: 61px;*/
/*    	left: -95px;*/
/*    }*/
/*}*/

/*@media only screen and (min-width: 481px) and (max-width: 768px) {*/
  /* Styles for medium and large smartphones */
/*   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {*/
/*       margin: 370px 10px 0 0;*/
/*        float: right;*/
/*    } */
    
/*    .togglecss {*/
/*    	top: 455px;*/
/*    	flex-wrap: nowrap;*/
/*    	margin-bottom: 61px;*/
/*    	left: -95px;*/
/*    }*/
/*}*/

/*@media only screen and (min-width: 768px) and (max-width: 1024px) {*/
  /* Styles for medium and large smartphones */
/*   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {*/
/*       margin: 430px 10px 0 0;*/
/*        float: right;*/
/*    } */
    
/*    .togglecss {*/
/*    	top: 509px;*/
/*    	flex-wrap: nowrap;*/
/*    	margin-bottom: 61px;*/
/*    	left: -95px;*/
/*    }*/
/*}*/
.leader-content {
  font-size: 15px;
}
/* Small smartphones (max-width: 480px) */
@media only screen and (max-width: 480px) {
   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
       margin: 0;
    }

    .togglecss {
    	top: 551px;
    	left: -95px;
    }

    .leader-content {
      font-size: 12px;
    }
    .overview-items span {
      font-size: 12px;
    }

    .overview-items thead {
      font-size: 12px;
    }
}



/* Mobile devices up to 768px */
@media only screen and (max-width: 768px) {
   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
       margin: 0;
    }
    
    .togglecss {
    	top: 551px;
    	left: -95px;
    }

    .analyze-action {
      left: 10px;
      top: 45px;
    }

    .company-action {
      left: 10px;
      top: 85px;
    }

    .watchlist-action {
      left: 10px;
      top: 125px;
    }

    .overview-container {
      top: 130px;
      width: calc(100vw - 16px);
      max-width: calc(100vw - 16px);
      left: 8px;
      right: 8px;
      overflow-y: scroll;
      margin: auto;
    }

    .overview-actions {
      flex-wrap: wrap;
      gap: 4px;
    }

    .overview-actions button {
      font-size: 11px;
      padding: 7px 4px;
      flex: 1 1 22%;
      background: rgba(255,255,255,0.08);
      border: 1px solid rgba(255,255,255,0.35);
      border-radius: 6px;
    }

    .overview-actions button.btn-outline-primary {
      background: rgba(255,255,255,0.18);
      border-color: white;
    }
}

.table > :not(caption) > * > * {
  padding: 0.2rem 0;
}

.mapboxgl-popup-anchor-bottom {
  z-index: 101;
}


/* Medium tablets (481px to 768px) */
@media only screen and (min-width: 481px) and (max-width: 768px) {
   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
       margin: 449px 10px 0 0;
    } 
    
    .togglecss {
    	top: 530px;
    	left: -95px;
    }
}

/* Tablets and smaller laptops (769px to 1024px) */
@media only screen and (min-width: 769px) and (max-width: 1024px) {
   .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
       margin: 468px 10px 0 0;
    } 
    
    .togglecss {
    	top: 551px;
    	left: 80px;
    }
}

.mapboxgl-popup {
  z-index: 101 !important;
}

/* Force search input to have grey background matching overview panel */
.choices[data-type*=select-one] .choices__input {
    background: rgba(217, 217, 217, 0.5) !important;
    backdrop-filter: blur(20px);
    color: #fff;
}

.center-center{
  align-items: center;
  justify-content: center;
  display: flex
}

/* ── FEAT-018: Ticker Tape ───────────────────────────────────────────────── */
#ticker-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 200;
    height: 48px;
    background: rgba(10, 10, 14, 0.94);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    overflow: hidden;
    display: flex;
    align-items: center;
}

#ticker-track {
    display: flex;
    animation: ticker-scroll 648s linear infinite;
    -webkit-animation: ticker-scroll 648s linear infinite;
    white-space: nowrap;
    will-change: transform;
}

#ticker-track:hover {
    animation-play-state: paused;
    -webkit-animation-play-state: paused;
}

@keyframes ticker-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}
@-webkit-keyframes ticker-scroll {
    from { -webkit-transform: translateX(0); }
    to   { -webkit-transform: translateX(-50%); }
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0 18px;
    font-size: 20px;
    font-family: 'Open Sans', monospace, sans-serif;
    cursor: pointer;
    white-space: nowrap;
    border-right: 1px solid rgba(255, 255, 255, 0.07);
    transition: background 0.15s;
    height: 48px;
}

.ticker-item:hover {
    background: rgba(255, 255, 255, 0.06);
}

.ticker-sym {
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.02em;
}

.ticker-price {
    color: #b0b0b0;
}

.ticker-chg.up   { color: #00e676; }
.ticker-chg.down { color: #ff5252; }
.ticker-chg.flat { color: #888; }

/* ── BUG-002 FIX / FEAT-012: CSS pulse marker — bigger, replaces unreliable GIF ── */
.pulse-marker {
    position: relative;
    width: 32px;        /* FEAT-012: was 20px */
    height: 32px;       /* FEAT-012: was 20px */
    cursor: pointer;
}

.pulse-marker .pulse-dot {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 18px;        /* FEAT-012: was 14px */
    height: 18px;       /* FEAT-012: was 14px */
    background: #0077aa;
    border-radius: 50%;
    z-index: 2;
    box-shadow: 0 0 0 3px rgba(0, 119, 170, 0.4);
}

.pulse-marker .pulse-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 18px;        /* FEAT-012: was 14px */
    height: 18px;       /* FEAT-012: was 14px */
    border-radius: 50%;
    background: rgba(255, 200, 0, 0.6);
    animation: pulse-expand 1.8s ease-out infinite;
}

.pulse-marker .pulse-ring:nth-child(2) {
    animation-delay: 0.6s;
}

.pulse-marker .pulse-ring:nth-child(3) {
    animation-delay: 1.2s;
}

@keyframes pulse-expand {
    0%   { width: 18px; height: 18px; opacity: 0.8; }  /* FEAT-012: was 14px */
    100% { width: 72px; height: 72px; opacity: 0; }    /* FEAT-012: was 56px */
}

/* Ticker on mobile — smaller font, tighter padding, match bar height */
@media (max-width: 767px) {
    #ticker-bar  { height: 36px; }
    #ticker-track { height: 36px; }
    .ticker-item { padding: 0 10px; gap: 4px; height: 36px; }
    .ticker-sym  { font-size: 11px; }
    .ticker-price { font-size: 10px; }
    .ticker-chg  { font-size: 10px; }
}

/* ── FEAT-008: How to Use button ─────────────────────────────────────────── */
#how-to-use-btn {
    position: fixed;
    bottom: 162px;         /* above ticker bar (48px) + zoom controls (~100px) + 14px gap */
    right: 16px;
    z-index: 201;
    background: rgba(10, 10, 14, 0.88);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 24px;
    padding: 7px 14px;
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    color: #ffffff;
    font-size: 13px;
    font-family: 'Open Sans', sans-serif;
    font-weight: 600;
    transition: background 0.2s, border-color 0.2s;
    user-select: none;
}

#how-to-use-btn:hover {
    background: rgba(0, 150, 80, 0.55);
    border-color: rgba(0, 230, 118, 0.6);
}

#how-to-use-btn .btn-icon {
    font-size: 14px;
    line-height: 1;
}

/* On mobile, collapse to icon-only and lift above ticker bar (36px) */
@media (max-width: 767px) {
    #how-to-use-btn {
        bottom: calc(133px + env(safe-area-inset-bottom, 0px));
        padding: 8px 11px;
    }
    #how-to-use-btn .btn-label {
        display: none;
    }
}

/* How to Use modal dark theme */
#howToUseModal .modal-content {
    background: #0f0f14;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.12);
}

#howToUseModal .modal-header {
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

#howToUseModal .modal-title {
    font-weight: 700;
    font-size: 1.1rem;
}

#how-to-use-video-wrap {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    overflow: hidden;
}

#how-to-use-video-wrap iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: 0;
}

#how-to-use-placeholder .guide-step {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    font-size: 14px;
    color: #ccc;
}

#how-to-use-placeholder .guide-step:last-child {
    border-bottom: none;
}

#how-to-use-placeholder .step-num {
    background: rgba(0, 230, 118, 0.15);
    color: #00e676;
    border-radius: 50%;
    width: 28px; height: 28px;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700;
    font-size: 13px;
    flex-shrink: 0;
}

/* ── FEAT-013: Floating newsletter button ────────────────────────────────── */
#newsletter-btn {
    position: fixed;
    bottom: 218px;       /* above how-to-use-btn (162px) + btn height (~40px) + gap */
    right: 16px;
    z-index: 201;
    background: rgba(10, 10, 14, 0.88);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 24px;
    padding: 7px 14px;
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    color: #ffffff;
    font-size: 13px;
    font-family: 'Open Sans', sans-serif;
    font-weight: 600;
    transition: background 0.2s, border-color 0.2s;
    user-select: none;
}

#newsletter-btn:hover {
    background: rgba(0, 80, 180, 0.55);
    border-color: rgba(80, 160, 255, 0.6);
}

/* On mobile, collapse to icon-only and lift above ticker bar (36px) */
@media (max-width: 767px) {
    #newsletter-btn {
        bottom: calc(133px + env(safe-area-inset-bottom, 0px));
        right: 60px;
        padding: 8px 11px;
    }
    #newsletter-btn .btn-label {
        display: none;
    }
}

/* ── FEAT-013: Subscribe modal (dark theme) ──────────────────────────────── */
#subscribeModal .modal-content {
    background: #0f0f14;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 12px;
}

#subscribeModal .modal-header {
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

#subscribeModal .modal-title {
    font-weight: 700;
    font-size: 1.1rem;
}

#subscribeModal .form-control {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    border-radius: 8px;
}

#subscribeModal .form-control::placeholder {
    color: rgba(255,255,255,0.4);
}

#subscribeModal .form-control:focus {
    background: rgba(255,255,255,0.12);
    border-color: rgba(80,160,255,0.6);
    color: #fff;
    box-shadow: 0 0 0 2px rgba(80,160,255,0.2);
}

#subscribe-modal-feedback {
    font-size: 13px;
    min-height: 20px;
    margin-top: 8px;
}

#subscribe-modal-feedback.success { color: #00e676; }
#subscribe-modal-feedback.error   { color: #ff5252; }

/* Footer form inline feedback */
#subscribe-footer-feedback {
    font-size: 13px;
    min-height: 20px;
    margin-top: 8px;
    text-align: center;
}

#subscribe-footer-feedback.success { color: #00e676; }
#subscribe-footer-feedback.error   { color: #ff5252; }
/* ── FEAT-028: Scroll-down indicator ─────────────────────────────────────────
   Bouncing chevron fixed at bottom-centre above the ticker bar. Always
   visible — clicking scrolls smoothly to the About section.
   z-index 300 sits above ticker (200) and floating buttons (201).           */
#scroll-controls {
    position: fixed;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 400;
    display: flex;
    flex-direction: row;
    align-items: center;
    background: rgba(10, 10, 14, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 22px;
    backdrop-filter: blur(8px);
    overflow: hidden;
}
#scroll-up-btn,
#scroll-down-btn {
    background: none;
    border: none;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0.85;
    transition: opacity 0.2s ease, background 0.15s ease;
    padding: 0;
}
#scroll-up-btn:hover,
#scroll-down-btn:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.1);
}
#scroll-up-btn svg,
#scroll-down-btn svg {
    width: 20px;
    height: 20px;
    stroke: rgba(255, 255, 255, 0.9);
    stroke-width: 2.5;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    pointer-events: none;
}
#scroll-divider {
    width: 1px;
    height: 22px;
    background: rgba(255, 255, 255, 0.2);
}
@media (max-width: 992px) {
    #scroll-controls { bottom: calc(130px + env(safe-area-inset-bottom, 0px)) !important; }
}

/* ── Map legend chip — bottom-left, always visible ───────────────────────────
   Shows Up / Down / Flat color keys. Fixed so it doesn't scroll with page.   */
#map-legend {
    position: fixed;
    bottom: 70px;
    left: 14px;
    z-index: 300;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    background: rgba(10, 10, 14, 0.62);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    backdrop-filter: blur(8px);
    font-size: 11px;
    color: rgba(255, 255, 255, 0.8);
    pointer-events: none;
    white-space: nowrap;
}
.legend-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.legend-sep {
    color: rgba(255, 255, 255, 0.3);
    font-size: 10px;
}

/* ── Data freshness chip — above legend ──────────────────────────────────────
   Shows "Data as of HH:MM UTC" once update_timestamp is known.               */
#data-freshness {
    position: fixed;
    bottom: 104px;
    left: 14px;
    z-index: 300;
    padding: 4px 10px;
    background: rgba(10, 10, 14, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    backdrop-filter: blur(8px);
    font-size: 10px;
    color: rgba(255, 255, 255, 0.55);
    pointer-events: none;
    white-space: nowrap;
}
@media (max-width: 992px) {
    #map-legend    { bottom: 24px; left: 10px; }
    #data-freshness { bottom: 58px; left: 10px; }
}


/* ── Subscribe card — override framework hot-pink to medium charcoal ─────────
   bg-gradient-primary default is #cb0c9f (hot pink). Override to a medium
   charcoal that reads as "dark card" but is visually distinct from the pure-
   black site background. Gradient was too dark at #42424a→#191919; lightened
   to ~#636370→#36363f so it matches the reference screenshot gray tone.      */
.card.bg-gradient-primary {
    background-image: linear-gradient(195deg, #636370 0%, #36363f 100%) !important;
    background-color: #36363f !important;
}

/* ── FEAT-007: Copy link button in company card header ───────────────────────
   Small inline icon button next to company name. Shares shareable URL.      */
.copy-link-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 6px;
    padding: 3px 6px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s ease, background 0.2s ease;
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}
.copy-link-btn:hover { opacity: 1; background: rgba(255,255,255,0.1); }
.copy-link-btn svg {
    width: 14px;
    height: 14px;
    stroke: rgba(255,255,255,0.85);
    stroke-width: 2;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    pointer-events: none;
}

/* ── FEAT-007: Copy link toast notification ──────────────────────────────────
   Brief confirmation that appears after copying. Auto-dismisses after 2.2s.  */
#copy-toast {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: rgba(30, 30, 36, 0.92);
    border: 1px solid rgba(255,255,255,0.18);
    color: #fff;
    padding: 8px 18px;
    border-radius: 20px;
    font-size: 13px;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
    backdrop-filter: blur(8px);
    white-space: nowrap;
}
#copy-toast.visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ── Company count badge — shows below search bar after data loads ───────────
   "Tracking 247 companies" — social proof, subtle.                          */
#company-count-badge {
    align-self: center;
    flex-shrink: 0;
    margin-left: 20px;
    font-size: 0.72rem;
    color: rgba(255,255,255,0.35);
    letter-spacing: 0.04em;
    white-space: nowrap;
    pointer-events: none;
    user-select: none;
}

/* ── Subscribe modal: visible close X button ────────────────────────────────
   Replaces Bootstrap btn-close-white which was invisible on dark modal bg.  */
.modal-close-x {
    background: transparent;
    border: none;
    padding: 4px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s ease;
    line-height: 0;
    margin-left: auto;
}
.modal-close-x:hover { opacity: 1; }
.modal-close-x svg {
    width: 20px;
    height: 20px;
    stroke: #fff;
    stroke-width: 2.5;
    fill: none;
    stroke-linecap: round;
    pointer-events: none;
}

/* ── Map loading overlay ─────────────────────────────────────────────────────
   Covers the viewport while /filtered_data fetches and map initialises.
   JS fades it out once map.on('load') fires.                               */
#map-loading {
    position: fixed;
    top: 0; right: 0; bottom: 0; left: 0;
    z-index: 2000;
    background: #0a0a0a;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    transition: opacity 0.4s ease;
}
#map-loading.fade-out {
    opacity: 0;
    pointer-events: none;
}
#map-loading .loader-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255,255,255,0.12);
    border-top-color: #00e5ff;
    border-radius: 50%;
    animation: rhm-spin 0.8s linear infinite;
}
#map-loading p {
    color: rgba(255,255,255,0.45);
    font-size: 13px;
    margin: 0;
    letter-spacing: 0.05em;
}
@keyframes rhm-spin {
    to { transform: rotate(360deg); }
}

/* ── Map error overlay ───────────────────────────────────────────────────── */
#map-error {
    position: fixed;
    top: 0; right: 0; bottom: 0; left: 0;
    z-index: 2000;
    background: #0a0a0a;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: #fff;
    text-align: center;
    padding: 24px;
}
#map-error h4 { color: #ff5252; margin: 0; font-size: 1.1rem; }
#map-error p  { color: rgba(255,255,255,0.5); font-size: 13px; margin: 0; }
#map-error button {
    margin-top: 8px;
    padding: 8px 20px;
    border: 1px solid rgba(255,255,255,0.25);
    background: transparent;
    color: #fff;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
}
#map-error button:hover { background: rgba(255,255,255,0.1); }

/* ── Company card price chip ─────────────────────────────────────────────────
   Shows $price and +/- change at the top of the company detail modal.         */
.price-chip-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    margin-top: 2px;
}
.price-chip-price {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
}
.price-chip {
    font-size: 13px;
    font-weight: 600;
    padding: 2px 9px;
    border-radius: 12px;
    letter-spacing: 0.02em;
}
.price-chip-up   { background: #e6f9ec; color: #15803d; }
.price-chip-dn   { background: #fde8e8; color: #b91c1c; }
.price-chip-flat { background: #f0f0f0; color: #555; }

/* ── Company card skeleton loader ────────────────────────────────────────────
   Shown immediately when user clicks a marker, dismissed once data arrives.  */
@keyframes sk-shimmer {
    0%   { background-position: -600px 0; }
    100% { background-position:  600px 0; }
}
.skeleton-modal-body {
    padding: 4px 0 8px;
}
.sk-logo, .sk-line, .sk-map {
    background: linear-gradient(90deg, rgba(255,255,255,0.06) 25%, rgba(255,255,255,0.12) 50%, rgba(255,255,255,0.06) 75%);
    background-size: 600px 100%;
    animation: sk-shimmer 1.4s infinite linear;
    border-radius: 6px;
}
.sk-logo  { width: 80px; height: 48px; margin-bottom: 14px; }
.sk-line  { height: 14px; margin-bottom: 10px; border-radius: 4px; }
.sk-line-70 { width: 70%; }
.sk-line-40 { width: 40%; }
.sk-line-90 { width: 90%; }
.sk-line-80 { width: 80%; }
.sk-map   { width: 100%; height: 150px; margin-top: 16px; border-radius: 8px; }

/* ── Company type count badges ────────────────────────────────────────────── */
.type-count-badge {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255,255,255,0.5);
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
    padding: 1px 7px;
    min-width: 28px;
    text-align: center;
    line-height: 1.6;
}

/* ── Company types panel form-check spacing ───────────────────────────────── */
#type-items .form-check {
    padding-right: 4px;
    margin-bottom: 4px;
}

/* ── FEAT-002: Watchlist — heart button in company modal ─────────────────────
   Sits next to the copy-link button in the modal header. Modal bg is white so
   border and stroke use dark tones, not white.                               */
.fav-btn {
    background: transparent;
    border: 1px solid rgba(0,0,0,0.25);
    border-radius: 8px;
    padding: 5px 9px;
    cursor: pointer;
    opacity: 0.75;
    transition: opacity 0.2s ease, background 0.2s ease, border-color 0.2s ease;
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}
.fav-btn:hover { opacity: 1; background: rgba(0,0,0,0.06); border-color: rgba(0,0,0,0.45); }
.fav-btn svg {
    width: 18px;
    height: 18px;
    stroke: rgba(0,0,0,0.6);
    stroke-width: 2;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    pointer-events: none;
    transition: fill 0.15s ease, stroke 0.15s ease;
}
.fav-btn.fav-active { opacity: 1; border-color: #e74c3c; }
.fav-btn.fav-active svg { fill: #e74c3c; stroke: #e74c3c; }

/* ── Custom inline company search (replaces Choices.js) ─────────────────────
   The .width70percent wrapper is position:relative so the results div
   can be absolute-positioned below the input.                               */
.width70percent { position: relative; }

#company-search-input {
    display: block;
    width: 100%;
    min-height: 44px;
    background: linear-gradient(90deg, rgba(217,217,217,0.5) 0%, rgba(115,115,115,0.5) 100%);
    backdrop-filter: blur(20px);
    border-radius: 0.75rem;
    border: 1.5px solid #36adad;
    color: #fff;
    font-size: 15px;
    padding: 10px 16px;
    outline: none;
    box-sizing: border-box;
    font-family: inherit;
}
#company-search-input::placeholder { color: rgba(255,255,255,0.55); }
#company-search-input:focus {
    border-color: #4dcfcf;
    box-shadow: 0 0 0 3px rgba(54,173,173,0.22);
}

#company-search-results {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: rgba(12,12,12,0.97);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(54,173,173,0.4);
    border-radius: 0.75rem;
    max-height: 320px;
    overflow-y: auto;
    z-index: 1100;
    display: none;
    box-shadow: 0 8px 32px rgba(0,0,0,0.45);
}
#company-search-results .csr-item {
    padding: 9px 16px;
    font-size: 14px;
    color: rgba(255,255,255,0.82);
    cursor: pointer;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: background 0.1s;
}
#company-search-results .csr-item:last-child { border-bottom: none; }
#company-search-results .csr-item:hover,
#company-search-results .csr-item.csr-active {
    background: rgba(54,173,173,0.18);
    color: #fff;
}
#company-search-results .csr-empty {
    padding: 14px 16px;
    color: rgba(255,255,255,0.38);
    font-size: 13px;
    text-align: center;
}

/* ── AI INTELLIGENCE TAB — FEAT-AI-001 ───────────────────────────────────── */

/* Tab bar inside modal */
.ai-modal-tab-bar {
    display: flex;
    align-items: center;
    gap: 0;
    border-bottom: 1px solid rgba(0,0,0,0.1);
    margin: -16px -16px 18px -16px;
    padding: 0 8px 0 16px;
    background: #f8f9fa;
    border-radius: 4px 4px 0 0;
}

/* Draggable modal — grab cursor on non-interactive areas */
.modal-dialog[style*="translate"] { will-change: transform; }
.modal .modal-content { cursor: grab; }
.modal .modal-content button,
.modal .modal-content input,
.modal .modal-content textarea,
.modal .modal-content a,
.modal .modal-content select { cursor: pointer; }

/* Persistent X — sits on modal-content, survives content swaps */
.modal-x-close {
    position: absolute;
    top: 10px;
    right: 12px;
    z-index: 20;
    background: rgba(0,0,0,0.06);
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: rgba(0,0,0,0.5);
    cursor: pointer;
    line-height: 1;
    transition: background 0.15s, color 0.15s;
}
.modal-x-close:hover {
    background: rgba(0,0,0,0.12);
    color: rgba(0,0,0,0.8);
}

/* X close button — lives in tab bar, always visible */
.ai-modal-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 18px;
    color: rgba(0,0,0,0.6);
    cursor: pointer;
    padding: 6px 10px;
    line-height: 1;
    border-radius: 4px;
    transition: color 0.15s, background 0.15s;
    flex-shrink: 0;
    touch-action: manipulation;
}
.ai-modal-close:hover {
    color: rgba(0,0,0,0.9);
    background: rgba(0,0,0,0.06);
}
.auth-modal-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 16px;
    color: rgba(255,255,255,0.5);
    cursor: pointer;
    padding: 6px 8px;
    line-height: 1;
    border-radius: 4px;
    transition: color 0.15s, background 0.15s;
    flex-shrink: 0;
}
.auth-modal-close:hover { color: rgba(255,255,255,0.95); background: rgba(255,255,255,0.08); }
.ai-tab-btn {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 12px 18px 10px;
    font-size: 13px;
    font-weight: 500;
    color: rgba(0,0,0,0.45);
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.ai-tab-btn:hover { color: rgba(0,0,0,0.75); }
.ai-tab-btn.active {
    color: #1a1a2e;
    border-bottom-color: #1a1a2e;
}
.ai-tab-label-short { display: none; }
@media (max-width: 480px) {
    .modal-x-close { display: none !important; }
    .ai-tab-label-full { display: none; }
    .ai-tab-label-short { display: inline; }
    .ai-tab-btn { padding: 12px 12px 10px; font-size: 12px; }
}
.ai-pro-badge {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.06em;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    color: #1a1a2e;
    padding: 2px 5px;
    border-radius: 3px;
    vertical-align: middle;
    line-height: 1;
}

/* Tab panes */
.ai-tab-pane { display: none; }
.ai-tab-pane--active { display: block; }

/* ── Premium gate ─────────────────────────────────────────────────────────── */
.ai-gate {
    text-align: center;
    padding: 40px 24px 36px;
}
.ai-gate-icon {
    font-size: 36px;
    margin-bottom: 12px;
    line-height: 1;
    opacity: 0.9;
}
.ai-gate-title {
    font-size: 17px;
    font-weight: 600;
    color: #1a1a2e;
    margin: 0 0 8px;
}
.ai-gate-desc {
    font-size: 13px;
    color: rgba(0,0,0,0.52);
    max-width: 380px;
    margin: 0 auto 22px;
    line-height: 1.55;
}
.ai-gate-form {
    display: flex;
    gap: 8px;
    max-width: 340px;
    margin: 0 auto 10px;
}
.ai-code-input {
    flex: 1;
    border: 1px solid rgba(0,0,0,0.18);
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 13px;
    outline: none;
    transition: border-color 0.15s;
}
.ai-code-input:focus { border-color: #1a1a2e; }
.ai-code-btn {
    background: #1a1a2e;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.15s;
    white-space: nowrap;
}
.ai-code-btn:hover { opacity: 0.85; }
.ai-code-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.ai-code-error {
    font-size: 12px;
    color: #c0392b;
    margin: 6px 0 0;
}

/* ── Analysis panel ───────────────────────────────────────────────────────── */
.ai-panel {
    padding: 4px 4px 12px;
    min-height: 180px;
}
.ai-panel-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}
.ai-panel-title {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(0,0,0,0.4);
}
.ai-panel-badge {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.08em;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    color: #1a1a2e;
    padding: 2px 5px;
    border-radius: 3px;
}

/* Swarm agent status row */
.ai-agents-row {
    display: flex;
    gap: 20px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}
.ai-agent {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: rgba(0,0,0,0.4);
    transition: color 0.3s;
}
.ai-agent--running { color: rgba(0,0,0,0.65); }
.ai-agent--done    { color: rgba(20,160,80,0.85); }
.ai-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(0,0,0,0.18);
    display: inline-block;
    flex-shrink: 0;
    transition: background 0.3s;
}
.ai-agent--pending .ai-dot { background: rgba(0,0,0,0.14); }
.ai-agent--running .ai-dot {
    background: #f7971e;
    animation: ai-pulse 0.9s ease-in-out infinite;
}
.ai-agent--done .ai-dot { background: rgba(20,160,80,0.85); }

@keyframes ai-pulse {
    0%, 100% { transform: scale(1);   opacity: 1; }
    50%       { transform: scale(1.5); opacity: 0.6; }
}

/* Synthesis indicator */
.ai-synth-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    font-size: 12px;
    color: rgba(0,0,0,0.5);
    font-style: italic;
}
.ai-synth-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    animation: ai-pulse 0.7s ease-in-out infinite;
    flex-shrink: 0;
}

/* Streaming output */
.ai-output {
    font-size: 14px;
    line-height: 1.65;
    color: #1a1a2e;
    min-height: 60px;
    white-space: pre-wrap;
    word-break: break-word;
}
.ai-output--cached {
    opacity: 0.88;
}
.ai-cursor {
    display: inline-block;
    width: 2px;
    height: 1.1em;
    background: #1a1a2e;
    vertical-align: text-bottom;
    margin-left: 1px;
    animation: ai-blink 0.7s step-end infinite;
}
@keyframes ai-blink {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0; }
}

/* Sentiment pill */
.ai-sentiment-pill {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.1em;
    padding: 3px 9px;
    border-radius: 20px;
    margin-bottom: 12px;
}
.ai-sent--bull    { background: rgba(20,160,80,0.12);  color: rgba(20,130,60,0.95); }
.ai-sent--bear    { background: rgba(210,40,40,0.10);  color: rgba(190,30,30,0.95); }
.ai-sent--neutral { background: rgba(0,0,0,0.06);      color: rgba(0,0,0,0.5); }

/* Footer */
.ai-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 18px;
    padding-top: 12px;
    border-top: 1px solid rgba(0,0,0,0.07);
}
.ai-footer-label {
    font-size: 11px;
    color: rgba(0,0,0,0.35);
}
.ai-refresh-btn {
    font-size: 11px;
    background: none;
    border: 1px solid rgba(0,0,0,0.15);
    border-radius: 5px;
    padding: 4px 10px;
    color: rgba(0,0,0,0.5);
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.ai-refresh-btn:hover {
    background: rgba(0,0,0,0.05);
    color: rgba(0,0,0,0.75);
}
/* ── END AI INTELLIGENCE TAB ─────────────────────────────────────────────── */

/* ── AUTH BUTTON + MODAL — FEAT-002/003/004 ────────────────────────────────── */
.auth-action {
    position: fixed;
    bottom: 274px;  /* above newsletter-btn (218px + ~40px height + 16px gap) */
    right: 16px;
    z-index: 500;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(30,30,30,0.82);
    border: 1px solid rgba(255,255,255,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.35);
    transition: background 0.15s;
}
.auth-action:hover { background: rgba(50,50,50,0.92); }

@media (max-width: 767px) {
    .auth-action {
        bottom: calc(133px + env(safe-area-inset-bottom, 0px));
        right: 104px;
    }
}

/* Company detail modal — push below status bar / notch on mobile */
@media (max-width: 767px) {
    [id^="exploreModal"] .modal-dialog {
        margin-top: calc(env(safe-area-inset-top, 44px) + 12px) !important;
    }
}

.auth-modal-content {
    background: #1a1a2e;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    overflow: hidden;
    color: #fff;
}
.auth-modal-tab-bar {
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.05);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    padding: 0 8px 0 4px;
    min-height: 44px;
}
.auth-tab-btn {
    background: none;
    border: none;
    color: rgba(255,255,255,0.5);
    font-size: 13px;
    font-weight: 500;
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
}
.auth-tab-btn.active {
    color: #fff;
    border-bottom-color: #36adad;
}
.auth-modal-body {
    padding: 20px 20px 24px;
}
.auth-pane { display: none; flex-direction: column; gap: 12px; }
.auth-pane--active { display: flex; }
.auth-pane-label {
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    margin: 0 0 4px;
    line-height: 1.5;
}
.auth-input {
    width: 100%;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.07);
    color: #fff;
    font-size: 14px;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.15s;
}
.auth-input::placeholder { color: rgba(255,255,255,0.3); }
.auth-input:focus { border-color: #36adad; }
.auth-submit-btn {
    width: 100%;
    padding: 11px;
    border-radius: 8px;
    border: none;
    background: #36adad;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}
.auth-submit-btn:hover { background: #2e9595; }
.auth-logout-btn { background: rgba(255,80,80,0.75); }
.auth-logout-btn:hover { background: rgba(255,80,80,0.95); }
.auth-msg { font-size: 12px; min-height: 18px; text-align: center; }
.auth-msg--ok  { color: #4ade80; }
.auth-msg--err { color: #f87171; }
.auth-loggedin-email {
    text-align: center;
    font-size: 13px;
    color: rgba(255,255,255,0.6);
    padding: 8px 0 16px;
    word-break: break-all;
}

/* ── COMMUNITY TAB — FEAT-003/004 ──────────────────────────────────────────── */
.community-panel { padding: 16px 4px 8px; }
.community-loading { text-align:center; color:rgba(0,0,0,0.4); padding:32px 0; font-size:13px; }
.comm-section { margin-bottom: 20px; }
.comm-section-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(0,0,0,0.4);
    margin-bottom: 10px;
}
.comm-auth-hint {
    font-size: 12px;
    color: rgba(0,0,0,0.4);
    margin: 8px 0 0;
}
.comm-login-link {
    background: none;
    border: none;
    color: #36adad;
    cursor: pointer;
    font-size: 12px;
    padding: 0;
    text-decoration: underline;
}
.comm-empty { font-size: 13px; color: rgba(0,0,0,0.4); margin: 0; }

/* Sentiment vote buttons */
.sent-bar-row { display: flex; gap: 8px; }
.sent-vote-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 10px 6px;
    border-radius: 8px;
    border: 2px solid transparent;
    background: rgba(0,0,0,0.04);
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    font-family: inherit;
}
.sent-vote-btn:hover { background: rgba(0,0,0,0.08); }
.sent-vote--bullish.sent-vote--active { border-color: #22c55e; background: rgba(34,197,94,0.1); }
.sent-vote--neutral.sent-vote--active { border-color: #94a3b8; background: rgba(148,163,184,0.1); }
.sent-vote--bearish.sent-vote--active { border-color: #f87171; background: rgba(248,113,113,0.1); }
.sent-vote-icon { font-size: 16px; }
.sent-vote--bullish .sent-vote-icon { color: #22c55e; }
.sent-vote--neutral .sent-vote-icon { color: #94a3b8; }
.sent-vote--bearish .sent-vote-icon { color: #f87171; }
.sent-vote-label { font-size: 11px; font-weight: 600; color: rgba(0,0,0,0.6); }
.sent-vote-count { font-size: 13px; font-weight: 700; color: rgba(0,0,0,0.75); }
.sent-totals { font-size: 11px; color: rgba(0,0,0,0.4); margin-top: 8px; text-align: center; }

/* Comments */
.comments-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 12px; max-height: 240px; overflow-y: auto; }
.comment-item {
    padding: 10px 12px;
    background: rgba(0,0,0,0.04);
    border-radius: 8px;
    border-left: 3px solid #36adad;
}
.comment-body { font-size: 13px; color: rgba(0,0,0,0.8); line-height: 1.5; word-break: break-word; }
.comment-meta { font-size: 11px; color: rgba(0,0,0,0.35); margin-top: 4px; display: flex; align-items: center; gap: 6px; }
.comment-delete-btn {
    background: none;
    border: none;
    padding: 0 2px;
    font-size: 10px;
    color: rgba(0,0,0,0.25);
    cursor: pointer;
    line-height: 1;
    transition: color 0.15s;
}
.comment-delete-btn:hover { color: #e53935; }
.comment-form { display: flex; flex-direction: column; gap: 8px; }
.comment-textarea {
    width: 100%;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid rgba(0,0,0,0.15);
    background: rgba(0,0,0,0.03);
    font-size: 13px;
    color: rgba(0,0,0,0.8);
    resize: vertical;
    font-family: inherit;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.15s;
}
.comment-textarea:focus { border-color: #36adad; }
.comment-submit-btn {
    padding: 8px 20px;
    border-radius: 8px;
    border: none;
    background: #36adad;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}
.comment-submit-btn:hover { background: #2e9595; }
/* ── END AUTH + COMMUNITY ────────────────────────────────────────────────────── */

/* ── FEAT-044: FLOATING COMPANY CARDS ───────────────────────────────────────── */
.rhm-float-card {
  position: fixed;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.22), 0 2px 8px rgba(0,0,0,0.10);
  border-top: 3px solid #3276B1;
  width: 264px;
  max-height: 88vh;
  overflow-y: auto;
  padding: 6px 14px 14px;
  cursor: default;
  -webkit-user-select: none;
  user-select: none;
  transition: box-shadow 0.15s;
}
.rhm-float-card:hover { box-shadow: 0 12px 40px rgba(0,0,0,0.28), 0 2px 8px rgba(0,0,0,0.12); }

/* Hide the content-area X inside floating cards — grip bar has its own X */
.rhm-float-card .popup-map-close { display: none !important; }

/* X button in the grip bar — right side */
.rhm-float-card-x {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.55);
  border: none;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: #fff;
  cursor: pointer;
  padding: 0;
  line-height: 1;
}
.rhm-float-card-x:hover { background: rgba(0,0,0,0.8); }

/* Drag handle pill at top of each card */
.rhm-float-card-grip {
  position: relative;
  width: 100%;
  height: 24px;
  cursor: grab;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}
.rhm-float-card-grip::before {
  content: '';
  display: block;
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: #ddd;
}
.rhm-float-card-grip:active { cursor: grabbing; }

/* Inner content styles — mirrors #map .mapboxgl-popup-content rules */
.rhm-float-card h3 {
  text-align: center;
  margin-top: 5px;
  color: #000;
  font-size: 16px;
}
.rhm-float-card p {
  line-height: 1.5;
  text-align: justify;
  font-size: 13px;
}
.rhm-float-card .data_block { text-align: center; }
.rhm-float-card .data_block .left,
.rhm-float-card .data_block .right {
  display: inline-block;
  width: 49%;
  font-size: 14px;
  margin: 0 auto;
}
.rhm-float-card .data_block label {
  margin-right: 10px;
  font-weight: 600;
  display: inline-block;
  color: #000;
}
.rhm-float-card .data_block .left img {
  width: 12px;
  margin-right: 5px;
  display: inline-block;
}
.rhm-float-card .data_block .right img {
  width: 16px;
  margin-right: 5px;
  display: inline-block;
}
.rhm-float-card img { max-width: 100%; margin: auto; display: block; }
.rhm-float-card a.btn_view_more_head {
  border: 1px solid #83a4a4;
  color: #fff;
  padding: 8px;
  display: block;
  max-width: 215px;
  text-align: center;
  margin: 0 auto 9px auto;
  font-size: 12px;
  background: #3276B1;
  border-radius: 0.75rem;
  text-decoration: none;
}
.rhm-float-card a.btn_view_more_head:hover { background: #255d8e; }

/* Mobile: constrain width, float near bottom */
@media (max-width: 767px) {
  .rhm-float-card {
    width: calc(100vw - 32px);
    max-height: 60vh;
  }
}
/* ── END FEAT-044 ────────────────────────────────────────────────────────────── */
