/* 
    Document   : crowder.css (Modernized)
    Created on : Jun 22, 2012, 5:25:37 PM
    Updated    : Modern design with enhanced tooltips
    Author     : todd
    Description:
        Modern styling for PDF viewer with beautiful tooltips and buttons
*/

#status2 {
  width: 100px;
}

#info {
  position: absolute;
  bottom: 0;
  height: 20px;
  background-color: white;
  width: 100%;
  display: none;
}

/* Modern PDF Buttons */
/* PDF Button styles */
button.divit {
  position: absolute;
  background: rgba(255, 20, 147, 0.9);
  color: white;
  border: none;
  border-radius: 2px;
  padding: 3px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 91, 150, 0.2);
  white-space: nowrap;
}

button.divit:hover {
  background: rgba(255, 20, 147, 1);
  z-index: 100;
}

button.divit.btn-assigned {
  background: rgba(0, 91, 150, 0.9);
}

button.divit.btn-assigned:hover {
  background: rgba(0, 91, 150, 1);
}

/* Button Icons */
button.divit .btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  font-size: 16px;
  font-weight: bold;
}

/* Toolbar Buttons */
.toolbarButton.saveButtons::before {
  display: inline-block;
  content: url(images/save.png);
}

.toolbarButton.deleteButton::before {
  display: inline-block;
  content: url(images/delete.png);
}

.toolbarButton#sidebarToggle2::before {
  display: inline-block;
  content: url(images/toolbarButton-sidebarToggle.png);
}

#viewer {
  font: 13px/100% Verdana, Arial, Helvetica, sans-serif;
}

/* General Button Styles */
button {
  outline: none;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  font-size: 10px;
  padding: .10em .25em;
  line-height: 10px;
  border: 1px solid #03396c;
  -webkit-border-radius: 2px;
  -moz-border-radius: 2px;
  border-radius: 2px;
  -webkit-box-shadow: 1px 1px 2px rgba(0, 0, 0, .3);
  -moz-box-shadow: 1px 1px 2px rgba(0, 0, 0, .3);
  box-shadow: 1px 1px 2px rgba(0, 0, 0, .3);
  color: black;
  -webkit-appearance: none;
}

button::-moz-focus-inner {
  padding: 0;
  border: 0
}

/* PDF View Button States */
.pdfview .btn-selected {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%) !important;
  box-shadow: 0 6px 20px rgba(245, 87, 108, 0.4) !important;
  border: none !important;
}

.pdfview .btn-ordered {
  border: 2px solid #ffd700 !important;
  box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.2) !important;
}

.pdfview .btn-assigned {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%) !important;
  border: none !important;
}

/* PDF Editing Overrides */
.pdfedit .btn-selected {
  border: 2px solid #f5576c !important;
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%) !important;
}

.pdfedit .btn-assigned {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%) !important;
  border: none !important;
}

/* Label and Show/Hide Controls */
#labelButton {
  width: 5em;
}

#showHideButtons {
  margin-top: 9px;
  margin-right: 12px;
  color: #ccc;
  font-size: 11px;
  width: 10em;
}

#showHideButtons img {
  vertical-align: middle;
}

#showHideButtons input {
  vertical-align: middle;
  margin-top: 0px;
  margin-bottom: 0px;
}

#editButtonLabel {
  margin-right: 12px;
  margin-top: 8px;
}

#editButtonLabel img {
  vertical-align: middle;
  border: none;
}

/* ================================================
   MODERN TOOLTIP STYLES
   ================================================ */

/* Old Tooltip (Hidden - Replaced by Modern) */
.tooltip {
  display: none !important;
  visibility: hidden !important;
}

/* Modern Tooltip Container */
.modern-tooltip {
  position: absolute;
  width: 280px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  z-index: 10000;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.modern-tooltip::after {
  content: '';
  position: absolute;
  background: transparent;
  z-index: -1;
}

/* Create invisible bridge between button and tooltip */
.modern-tooltip.tooltip-top::after {
  bottom: 100%;
  left: 0;
  right: 0;
  height: 20px;
}

.modern-tooltip.tooltip-bottom::after {
  top: 100%;
  left: 0;
  right: 0;
  height: 20px;
}

.modern-tooltip.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

/* Tooltip Arrow */
.modern-tooltip::before {
  content: '';
  position: absolute;
  width: 0;
  height: 0;
  border-style: solid;
  z-index: 1;
}

.modern-tooltip.tooltip-top::before {
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  border-width: 8px 8px 0 8px;
  border-color: white transparent transparent transparent;
}

.modern-tooltip.tooltip-bottom::before {
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  border-width: 0 8px 8px 8px;
  border-color: transparent transparent white transparent;
}

.modern-tooltip.tooltip-left::before {
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  border-width: 8px 0 8px 8px;
  border-color: transparent transparent transparent white;
}

.modern-tooltip.tooltip-right::before {
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  border-width: 8px 8px 8px 0;
  border-color: transparent white transparent transparent;
}

/* Tooltip Product Image */
.tooltip-image {
  width: 100%;
  height: 140px;
  overflow: hidden;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.1) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 10px;
  box-sizing: border-box;
}

.tooltip-image::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  /* background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.1) 100%); */
}

.tooltip-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  mix-blend-mode: multiply;
}

/* Tooltip Content */
.tooltip-content {
  padding: 16px;
}

/* Tooltip Header */
.tooltip-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
  span {
    padding: 2px 6px;
    border-radius: 20px;
    background: #f2d936 ;
    text-transform: none;
  }
}

/* SKU Badge */
.tooltip-sku {
  display: inline-block;
  color: #000;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Product Title */
.tooltip-title {
  font-size: 16px;
  font-weight: 700;
  color: #212529;
  margin: 0 0 0px 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  a { 
    color: rgba(0, 91, 150, 1);
    text-decoration: none;
    &:hover {
      text-decoration: underline;
    }
  }
}

/* Price Display */
.tooltip-price {
  font-size: 20px;
  font-weight: 700;
  color: #000;
  margin-bottom: 10px;
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.tooltip-price::before {
  font-size: 16px;
  font-weight: 600;
}

/* Add to Cart Button in Tooltip */
.tooltip-add-cart {
  /* width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  background: #005b96;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  font-family: inherit; */
  opacity: 1;
  position: relative;
  margin: auto;
  width: 100%;
  background: transparent;
  border: 1px solid #005b96;
  color: #005b96;
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  /* flex-direction: row-reverse; */
  justify-content: center;
  gap: 2px;
  transition: 0.5s;
  line-height: 1;
  padding: 6px 12px;
  transition: 0.3s;
  border-radius: 5px;
}


.tooltip-add-cart:hover::after{
  transform: translateX(10px);
  transition: 0.3s;
}

.tooltip-add-cart::after{
  content:'»';
  font-size: 24px; 
  font-weight: 400;
  transition: 0.3s;
  margin: -2px 0px 0px;
}
.tooltip-add-cart:disabled::after {
  display: none;
}

.tooltip-add-cart:hover {
  /* transform: translateY(-2px); */
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
  background: #005b96;
  color: #fff;
}

.tooltip-add-cart:active {
  transform: translateY(0);
}

.tooltip-add-cart:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* Success State */
.tooltip-add-cart.success {
  background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
}

.tooltip-add-cart.success:hover {
  background: linear-gradient(135deg, #38ef7d 0%, #11998e 100%);
}

/* Loading Spinner */
.loader-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Cart Icon SVG in Button */
.tooltip-add-cart svg {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
}

/* Responsive Tooltip */
@media (max-width: 768px) {
  .modern-tooltip {
    width: 260px;
  }
  
  .tooltip-image {
    height: 140px;
  }
  
  .tooltip-title {
    font-size: 15px;
  }
  
  .tooltip-price {
    font-size: 18px;
  }
}

/* Enhanced Focus States */
button.divit:focus-visible {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

.tooltip-add-cart:focus-visible {
  outline: 2px solid #764ba2;
  outline-offset: 2px;
}

/* Smooth Transitions */
* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Selection Color */
::selection {
  background-color: #667eea;
  color: white;
}

::-moz-selection {
  background-color: #667eea;
  color: white;
}