/**
 * Extended Warranty Styles
 */

.extended-warranty-container {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
}

.extended-warranty-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 10px 0;
    color: #333;
}

.extended-warranty-description {
    font-size: 14px;
    color: #666;
    margin: 0 0 15px 0;
}

.warranty-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.warranty-option {
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    padding: 12px 15px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.warranty-option:hover {
    border-color: #007bff;
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.1);
}

.warranty-option.selected {
    border-color: #007bff;
    background: #f0f8ff;
}

.warranty-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin: 0;
    width: 100%;
}

.warranty-radio {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.warranty-checkmark {
    position: relative;
    height: 20px;
    width: 20px;
    background-color: #fff;
    border: 2px solid #ccc;
    border-radius: 50%;
    margin-right: 12px;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.warranty-radio:checked ~ .warranty-checkmark {
    background-color: #007bff;
    border-color: #007bff;
}

.warranty-checkmark:after {
    content: "";
    position: absolute;
    display: none;
    top: 3px;
    left: 3px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: white;
}

.warranty-radio:checked ~ .warranty-checkmark:after {
    display: block;
}

.warranty-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    font-size: 14px;
}

.warranty-text strong {
    color: #333;
    font-weight: 600;
}

.warranty-price {
    color: #007bff;
    font-weight: 600;
    font-size: 14px;
    margin-left: 10px;
}

.warranty-option.no-warranty .warranty-price {
    color: #666;
    font-weight: 400;
    font-size: 13px;
}

/* Responsive design */
@media (max-width: 768px) {
    .extended-warranty-container {
        padding: 15px;
        margin: 15px 0;
    }

    .extended-warranty-title {
        font-size: 16px;
    }

    .warranty-text {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }

    .warranty-price {
        margin-left: 0;
    }
}

/* Animation for selection */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 123, 255, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(0, 123, 255, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(0, 123, 255, 0);
    }
}

.warranty-option.selected {
    animation: pulse 0.5s;
}


.toggle-group {
    display: inline-flex;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    justify-content: space-evenly;
    flex-direction: row;
    width: 100%;
}

.toggle-btn {
    border: 2px solid #ccc;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
    height: 90px;
    justify-content: center;
    display: flex;
    flex: 1;
}

.toggle-btn input {
  display: none;
}

.toggle-btn .text {
  display: flex;
  flex-direction: column;
  gap: 4px;
      font-size: 10px;
    align-items: center;
    justify-content: center;
}

.toggle-btn strong {
  font-size: 16px;
}

.toggle-btn span {
  font-size: 13px;
  color: #666;
}

/* Active state */
.toggle-btn input:checked + .text {
  color: white;
}

.toggle-btn input:checked {
  outline: none;
}

.toggle-btn input:checked ~ .text {
  background-color: #1e163d;
}

.toggle-btn:has(input:checked) {
  background-color: #1e163d;
  border-color: #1e163d;
  color: white;
}

.toggle-btn:has(input:checked) span {
  color: #ddd;
}

.product-extended-warranty{
    border: 1px solid black;
    border-radius: 25px;
    padding: 10px;
    margin-bottom:15px;
}

.extended-warranty-title::before{
    content: "";
    display: inline-block;
    width: 30px;
    height: 30px;
    background-image: url('../img/shield.svg');
    background-size: contain;
    background-repeat: no-repeat;
    margin-right: 8px;
    display: inline-flex;
    vertical-align: middle;
}

.extended-duration{
    font-size:12px;
    font-weight: bold;
}