/* --- Product Detail View (Drogasil Style) --- */

.product-detail-view {
    background-color: #f8f9fa;
    /* Light gray background for page */
    padding: 1.5rem 0;
}

.product-detail-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.breadcrumb {
    font-size: 0.825rem;
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.breadcrumb span {
    cursor: pointer;
}

.breadcrumb span:hover {
    text-decoration: underline;
    color: var(--primary-color);
}

/* 3-Column Layout */
.product-detail-layout {
    display: grid;
    grid-template-columns: 350px 1fr 340px;
    /* Fixed Image, Fluid Info, Fixed BuyBox */
    gap: 2rem;
    align-items: start;
    margin-bottom: 3rem;
}

/* Col 1: Image */
.detail-image-card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.detail-image-card img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* Col 2: Info */
.detail-col-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.detail-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    line-height: 1.3;
}

.detail-subtitle {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.detail-seller {
    font-size: 0.875rem;
    color: #4b5563;
    margin-bottom: 1.5rem;
}

.detail-benefits h3 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.detail-benefits ul {
    list-style: disc;
    padding-left: 1.25rem;
    color: #4b5563;
    font-size: 0.9rem;
    line-height: 1.6;
}

/* Col 3: Buy Box */
.detail-col-buybox {
    position: sticky;
    top: 160px;
    /* Offset for header */
}

.buy-box-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid #e5e7eb;
}

.buy-box-price-row {
    margin-bottom: 1.5rem;
}

.buy-box-price {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-color);
    display: block;
}

.buy-box-payment-info {
    font-size: 0.825rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.buy-box-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.buy-button-primary {
    background-color: var(--primary-color);
    /* Multmais Blue */
    color: white;
    width: 100%;
    padding: 0.875rem;
    border-radius: 6px;
    border: none;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 0.2s;
}

.buy-button-primary:hover {
    opacity: 0.9;
}

.buy-button-secondary {
    background-color: #8fc30f;
    /* WhatsApp Green */
    color: white;
    width: 100%;
    padding: 0.75rem;
    border-radius: 6px;
    border: none;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.buy-button-secondary:hover {
    background-color: #1faf58;
}

.buy-box-delivery-preview {
    border-top: 1px solid #e5e7eb;
    padding-top: 1rem;
}

.delivery-label {
    font-size: 0.875rem;
    font-weight: 600;
    display: block;
    margin-bottom: 0.5rem;
}

.delivery-input-fake {
    background-color: #f3f4f6;
    border-radius: 4px;
    padding: 0.75rem;
    color: #9ca3af;
    font-size: 0.875rem;
    cursor: not-allowed;
}

/* Full Description */
.detail-full-description {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}

.detail-full-description h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 0.5rem;
}

.description-content ul {
    list-style: disc;
    padding-left: 1.5rem;
    line-height: 1.6;
}

/* Responsive */
@media (max-width: 1024px) {
    .product-detail-layout {
        grid-template-columns: 1fr 340px;
        /* Image+Info | BuyBox */
    }

    .detail-col-image {
        grid-column: 1 / -1;
        justify-self: center;
        max-width: 400px;
    }

    .detail-col-info {
        grid-column: 1 / 2;
    }

    .detail-col-buybox {
        grid-column: 2 / 3;
        grid-row: 2 / 3;
        /* Move next to info if space permits, else adjust */
    }
}

@media (max-width: 768px) {
    .product-detail-layout {
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
    }

    .detail-col-image,
    .detail-col-info,
    .detail-col-buybox {
        width: 100%;
        max-width: none;
        grid-column: auto;
    }

    .buy-button-primary {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        border-radius: 0;
        z-index: 1000;
        padding: 1.25rem;
        box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.1);
    }

    .buy-box-actions {
        margin-bottom: 0;
        /* Adjust for fixed button */
    }

    body {
        padding-bottom: 80px;
        /* Space for fixed button */
    }
}

/* --- Modal & Delivery Styles --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(2px);
}

.modal-overlay.open {
    display: flex;
}

.delivery-options {
    display: grid;
    gap: 1rem;
    margin-top: 1rem;
}

.delivery-option-btn {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid #e5e7eb;
    background: #fff;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    width: 100%;
    text-align: left;
    color: #374151;
}

.delivery-option-btn:hover {
    border-color: var(--primary-color);
    background: #eff6ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.delivery-option-btn svg {
    color: var(--primary-color);
    flex-shrink: 0;
}

.delivery-result {
    margin-top: 1rem;
    padding: 1rem;
    background: #f9fafb;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    text-align: left;
}

.btn-continue {
    background: var(--primary-color);
    color: white;
    width: 100%;
    padding: 0.75rem;
    border-radius: 6px;
    margin-top: 1rem;
    border: none;
    font-weight: 600;
    cursor: pointer;
}

.btn-continue:hover {
    opacity: 0.9;
}

.btn-link-small {
    background: none;
    border: none;
    color: #666;
    font-size: 0.8rem;
    text-decoration: underline;
    margin-top: 0.5rem;
    cursor: pointer;
    display: block;
    width: 100%;
}

.location-status {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: #666;
    text-align: center;
}

.alert-box {
    background: #eff6ff;
    color: var(--primary-color);
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}