/* Popup base (hidden by default) */
.wdrb-modal {
    display: none; /* keep hidden initially */
    opacity: 0;
    pointer-events: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
    transition: opacity 0.1s ease-in-out;
    z-index: 9999;
}

/* When active */
.wdrb-modal.active {
    display: flex;
    opacity: 1;
    pointer-events: auto;
}

/* Card animation */
.wdrb-card {
    background: #fff;
    border-radius: 12px;
    max-width: 600px;
    width: 100%;
    transform: translateY(-30px);
    opacity: 0;
    transition: all 0.1s ease;
}

/* Animate card on active */
.wdrb-modal.active .wdrb-card {
    transform: translateY(0);
    opacity: 1;
}


.wdrb-head {
    padding: 18px 22px;
    border-bottom: 1px solid #eee;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.wdrb-body {
    padding: 12px 25px;
}
.button.wdrb {
    background: #111827;
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 10px 14px;
    cursor: pointer;
}
.wdrb-price {
    font-weight: 700;
}
.wdrb-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}
.wdrb-row {
    display: flex;
    gap: 14px;
    align-items: center;
    margin: 10px 0;
}

/* for popup diamond details*/

.wdrb-custom-details .elementor-icon-box-wrapper {
    display: flex;
    align-items: center;
}

.wdrb-custom-details .elementor-icon-box-icon {
    margin-right: 15px; /* Adjust spacing between icon and text */
}

.wdrb-custom-details .elementor-icon-box-content {
    flex-grow: 1; /* Allows content to take up the remaining space */
}

/* Sets a fixed size for the icon container for both diamond and ring details */
.wdrb-custom-details .elementor-icon-box-icon span.elementor-icon {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 55px !important; /* Adjust this value to your desired size */
    height: 55px !important; /* Adjust this value to your desired size */
    flex-shrink: 0 !important; /* Prevents the container from shrinking */
}

/* Forces the images to fit perfectly inside the container */
.wdrb-custom-details .elementor-icon-box-icon img.wdrb-icon-image {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important; /* Ensures the GIF isn't stretched */
        border: 1px solid #456D72;
    border-radius: 50%;
}

.wdrb-card {
  position: relative;
  z-index: 1;
  background: #fff; /* your card background (unchanged) */
  border-radius: 16px; /* adjust as you like */
  padding: 20px;
  overflow: hidden;
}

/* Gradient border only */
.wdrb-card::before {
  content: "";
  position: absolute;
  inset: 0;
  padding: 3px; /* thickness of border */
  border-radius: inherit;
  background: linear-gradient(
    270deg,
    #ff0080,
    #7928ca,
    #2afadf,
    #ff0080
  );
  background-size: 300% 300%;
  animation: gradientBorder 6s ease infinite;
  -webkit-mask: 
    linear-gradient(#fff 0 0) content-box, 
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  z-index: -1;
}

@keyframes gradientBorder {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}



.elementor-icon-box-title span {
    font-weight: bold;
    font-size: 15px;
    font-style: normal;
    text-transform: capitalize;
}

.elementor-icon-box-description {
    font-size: 12px;
    color: #7b7b7b;
    line-height: 1.5;
}
/* =========================== */
/* === Navigation and Steps === */
/* =========================== */
.wdrb-steps {
    display: none; /* Original style, but grouped here for context */
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}
.wdrb-step {
    flex: 1;
    text-align: center;
    padding: 10px;
    border-radius: 10px;
    background: #f5f7fb;
    border: 1px solid transparent;
}
.wdrb-step.active {
    background: #e6f3ff;
    border-color: #b7dcff;
}


/* ========================= */
/* === Option and Grid Styles === */
/* ========================= */
.wdrb-grid {
    display: flex;
    gap: 12px;
    width: 300px;
    margin: 0 auto 4px auto;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}
.wdrb-option {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 12px;
    cursor: pointer;
    user-select: none;
    flex: 1;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}
.wdrb-option input[type="radio"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    display: none;
}
.wdrb-option.selected {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px #3b82f6;
}
.wdrb-grid-boxes {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 10px;
    margin-bottom: 10px;
}
.wdrb-option-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    cursor: pointer;
}
.wdrb-option-box {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    text-align: center;
    padding: 12px;
    cursor: pointer;
    width: 100%;
    transition: border-color .2s, box-shadow .2s;
    display: flex;
    justify-content: center;
    align-items: center;
}
.wdrb-option-box:hover {
    border-color: #9ca3af;
}
.wdrb-option-box span {
    display: block;
    font-size: 22px;
    font-weight: 700;
}
.wdrb-option-label {
    margin-top: 8px;
    font-size: 0.9em;
    color: #666;
    text-align: center;
}
.wdrb-option.selected,
.wdrb-option-group.selected .wdrb-option-box {
    border-color: #ffffff;
    background: #dcffe44f;
    box-shadow: 4px 0px 13px 2px #cbcbcb !important;
    transition: box-shadow 0.4s ease, transform 0.4s ease;
}
.wdrb-option-box.wdrb-size-option.selected {
    background: #eefff4;
    border: 2px solid #bbffd4;
    box-shadow: 0 6px 14px rgb(94 109 100 / 20%);
    transition: background .2s, border-color .2s, box-shadow .2s;
}

/* =============================== */
/* === Live Output and Display === */
/* =============================== */
.wdrb-live-output {
    display: flex;
    justify-content: space-around;
    align-items: center;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 20px;
    text-align: center;
    margin-top: 20px;
}
.wdrb-live-output .wdrb-live-item {
    flex: 1;
}
.wdrb-live-output .wdrb-live-price,
.wdrb-live-output .wdrb-live-carat {
    font-size: 2em;
    font-weight: 600;
    color: #1a202c;
    line-height: 1.2;
}
.wdrb-live-output .wdrb-live-item + .wdrb-live-item {
    border-left: 1px solid #e2e8f0;
}
.wdrb-live-output .wdrb-description {
    font-size: 0.8em;
    color: #6b7280;
    font-weight: 400;
    display: block;
    margin-top: 5px;
}
.wdrb-carat-out-val {
    font-weight: 600;
}
.wdrb-price-adj {
    font-size: 12px;
    color: #6b7280;
}
.wdrb-field-label {
    font-weight: 600;
    font-size: 17px;
    margin-bottom: 10px;
}

/* ==================== */
/* === Slider Styles === */
/* ==================== */
.wdrb-slider-container {
    position: relative;
    width: 100%;
    margin-top: 40px;
}
input.wdrb-field.wdrb-range {
    border-color: white;
    width: 100%;
}
.wdrb-carat-tooltip {
    position: absolute;
    top: -42px;
    background-color: #a2e0dc00;
    color: #1f2937;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 1em;
    font-weight: 600;
    transform: translateX(-50%);
    white-space: nowrap;
    z-index: 10;
    pointer-events: none;
    transition: left 0.1s ease-out;
    border: 1px solid #7ad4cc;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
.wdrb-carat-tooltip::after {
    content: "";
    position: absolute;
    bottom: -17px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 8px;
    border-style: solid;
    border-color: #71b8b2 transparent transparent transparent;
}
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    cursor: pointer;
}
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 15px;
    height: 15px;
    background: #4a90e2;
    cursor: pointer;
    border-radius: 50%;
    margin-top: -2px;
    border: none;
}
input[type="range"]::-moz-range-thumb {
    width: 15px;
    height: 15px;
    background: #4a90e2;
    cursor: pointer;
    border-radius: 50%;
    border: none;
}
input[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 8px;
    background: #e5e7eb;
    border-radius: 4px;
}
input[type="range"]::-moz-range-track {
    width: 100%;
    height: 8px;
    background: #e5e7eb;
    border-radius: 4px;
}

/* ============================ */
/* === Legacy/Placeholder Styles === */
/* ============================ */
.wdrb-shapes-grid, .wdrb-metals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 10px;
    margin-bottom: 20px;
}
.wdrb-shape-option, .wdrb-metal-option {
    cursor: pointer;
    padding: 10px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    text-align: center;
}
.wdrb-shape-option.selected, .wdrb-metal-option.selected {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px #3b82f6;
}
.wdrb-shape-option img {
    max-width: 100%;
    height: auto;
}
.wdrb-metal-option .color-swatch {
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: inline-block;
    border: 1px solid #e5e7eb;
}



@media (max-width: 768px) {
  .wdrb-grid-boxes {
    margin-bottom: 8px;
  }
  .wdrb-card {
    max-width: 365px;
    border-radius: 6px;
  }
  
  .wdrb-live-output {
    padding: 8px;
    margin-top: 8px;
  }

  .wdrb-live-output .wdrb-live-price,
  .wdrb-live-output .wdrb-live-carat {
    font-size: 18px; /* Reduce font size for smaller screens */
  }

  .wdrb-live-output .wdrb-description {
    font-size: 11px;
    margin-top: 4px;
  }
  .wdrb-grid{
      margin: 0 auto 10px auto;
  }

  .wdrb-option-box {
    padding: 8px;
  }

  .wdrb-option-label {
    margin-top: 6px;
    font-size: 10px;
    
  }
  .wdrb-field-label {
    font-weight: 600;
    font-size: 17px;
    margin-bottom: 10px;
}

  .wdrb-head {
    padding: 10px 16px;
    font-size: 14px;
    text-align: center; /* Optional: helps on mobile layout */
  }
}

@media (max-width: 480px) {
  .wdrb-live-output .wdrb-live-price,
  .wdrb-live-output .wdrb-live-carat {
    font-size: 16px;
  }

  .wdrb-live-output .wdrb-description {
    font-size: 10px;
  }

  .wdrb-head {
    padding: 8px 12px;
    font-size: 13px;
  }
}

.elementor-widget-container.wdrb-custom-details {
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.elementor-icon-box-title {
    font-size: 16px;
    font-style: italic;
    text-transform: uppercase;
    color: #333;
    font-weight: 500;
    margin-bottom: 5px;
}

.elementor-icon-box-title span {
    font-weight: bold;
    font-style: normal;
}

.elementor-icon-box-description {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* This targets the total price display on the product page */
.woocommerce-price-amount {
    font-size: 20px;
    font-weight: bold;
    color: #2a2a2a;
}
