/* ========================================
   PROVIDER DETAIL PAGE SPECIFIC STYLES
   ======================================== */

/* Provider Detail Section */
.provider-detail-section {
    padding: 100px 0 60px;
    background: transparent;
    min-height: 100vh;
    position: relative;
}

.provider-detail-background-image {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: -1;
}

.provider-detail-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* Back Button */
.back-button-container {
    position: absolute;
    top: 0;
    left: -5px;
    z-index: 10;
}

.back-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: white;
    color: #ffc107;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.back-button i {
    font-size: 1rem;
}

/* Provider Detail Card */
.provider-detail-card {
    background: white;
    border-radius: 25px;
    padding: 40px;
    border: 1px solid #e8ecf0;
    position: relative;
    overflow: hidden;
}


/* Provider Header */
.provider-header {
    display: flex;
    align-items: center;
    gap: 30px;
    margin-bottom: 40px;
    margin-top: 0;
    padding-bottom: 30px;
    border-bottom: 2px solid #f8f9fa;
    position: relative;
}

.provider-logo-container {
    flex-shrink: 0;
    margin-left: 60px;
}

.provider-logo {
    width: 200px;
    height: 150px;
    background: transparent;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 12px;
}

.provider-logo-img {
    width: 180px;
    height: 150px;
    object-fit: contain;
    border-radius: 12px;
}

.provider-logo i {
    font-size: 2.5rem;
    color: white;
}

.logo-loading,
.logo-error {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border-radius: 25px;
}

.logo-loading p {
    font-size: 0.9rem;
    color: #7f8c8d;
    margin: 0;
    text-align: center;
}

.logo-error i {
    font-size: 2.5rem;
    color: #000000;
    background: rgba(118, 118, 118, 0.1);
    padding: 20px;
    border-radius: 50%;
}

.provider-info {
    flex-grow: 1;
}

.provider-name {
    font-size: 2.2rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 15px;
    line-height: 1.3;
}

.provider-description {
    font-size: 1.1rem;
    color: #7f8c8d;
    line-height: 1.6;
    margin: 0;
}

/* Product Details Section */
.product-details-section {
    margin-top: 40px;
}

.product-info-container {
    width: 100%;
}

.additional-product-container {
    width: 100%;
    margin-top: 30px;
    padding-top: 30px;
    border-top: 2px solid #e9ecef;
}

.product-info-container h3,
.additional-product-container h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.additional-product-container h3 {
    color: #2c3e50;
}

.product-name {
    font-size: 1.5rem;
    font-weight: 500;
    color: #000000;
    margin-top: 0;
    margin-bottom: 15px;
}

.product-details-box {
    background: #fff9ed;
    border-radius: 15px;
    padding: 25px;
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.product-detail-item {
    display: flex;
    margin-bottom: 15px;
    align-items: flex-start;
}

.product-detail-item.full-width {
    flex-direction: column;
    gap: 8px;
}

.detail-value {
    color: #333333;
    line-height: 1.6;
    font-size: 1rem;
}

.product-name {
    font-size: 1.5rem;
    font-weight: 500;
    color: #000000;
    margin-top: 0;
    margin-bottom: 15px;
}









/* Responsive Design */
@media (max-width: 768px) {
    .provider-detail-section {
        padding: 80px 0 40px;
    }

    .provider-detail-container {
        padding: 0 15px;
    }

    .provider-detail-card {
        padding: 30px 25px;
    }

    .provider-header {
        flex-direction: column;
        text-align: center;
        gap: 20px;
        margin-bottom: 30px;
        padding-bottom: 25px;
    }

    .provider-logo-container {
        margin-left: 0;
    }

    .provider-logo {
        width: 100px;
        height: 140px;
        padding: 8px;
    }

    .provider-logo-img {
        width: 120px;
        height: 120px;
    }

    .provider-logo i {
        font-size: 2rem;
    }

    .logo-loading p {
        font-size: 0.8rem;
    }

    .logo-error i {
        font-size: 2rem;
    }

    .provider-name {
        font-size: 1.8rem;
    }

    .provider-description {
        font-size: 1rem;
    }

    .product-details-section {
        flex-direction: column;
        gap: 30px;
        margin-top: 30px;
    }



    .back-button {
        padding: 10px 18px;
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .provider-detail-card {
        padding: 25px 20px;
    }

    .provider-name {
        font-size: 1.5rem;
    }

    .provider-description {
        font-size: 0.95rem;
    }

    .product-details-section {
        flex-direction: column;
        gap: 25px;
        margin-top: 25px;
    }

    .product-details-box {
        padding: 15px;
        /* MOBILE FIX: Limit height to prevent long text from hiding registration button */
        max-height: 200px;
        overflow-y: auto;
        overflow-x: hidden;
    }
    
    .detail-value {
        word-wrap: break-word;
        white-space: normal;
        overflow-wrap: break-word;
        hyphens: auto;
        line-height: 1.6;
    }
    
    /* Custom scrollbar for mobile */
    .product-details-box::-webkit-scrollbar {
        width: 6px;
    }
    
    .product-details-box::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 3px;
    }
    
    .product-details-box::-webkit-scrollbar-thumb {
        background: #ffc107;
        border-radius: 3px;
    }
    
    .product-details-box::-webkit-scrollbar-thumb:hover {
        background: #ffb300;
    }

    .product-name {
        font-size: 1rem;
        margin-top: 0;
        margin-bottom: 12px;
    }

    .product-name {
        font-size: 0.9rem;
        margin-top: 0;
        margin-bottom: 10px;
    }

    .detail-value {
        font-size: 0.9rem;
    }


    .provider-logo {
        width: 120px;
        height: 100px;
        padding: 8px;
    }

    .provider-logo-img {
        width: 100px;
        height: 100px;
    }

    .provider-logo i {
        font-size: 1.8rem;
    }

    .logo-loading p {
        font-size: 0.7rem;
    }

    .logo-error i {
        font-size: 1.8rem;
    }


    .back-button {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
}

/* ============================================================
   REGISTRATION SECTION STYLES
   ============================================================
   This section is controlled by localStorage 'selectedUserType'
   - Shows button only when user comes from d-voucher-index.html
   - Button navigates to appropriate form based on stored selection
   - To modify: see provider-detail-script.js setupRegistrationButtons()
   ============================================================ */

/* Registration Section Styles */
.registration-section {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
    padding: 0;
}

.registration-single-button {
    display: flex;
}

/* Simple registration button styles */
.simple-registration-btn {
    background: linear-gradient(135deg, #ffc107, #ffb300);
    color: #333;
    border: none;
    border-radius: 25px;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Prompt', sans-serif;
    white-space: nowrap;
}



/* Registration Section Layout */
.registration-section {
    display: flex;
    flex-direction: row;
    gap: 20px;
    align-items: center;
    margin-top: 10px;
}

.product-selection-container {
    flex: 1;
    display: flex;
    margin-top: 0;
    margin-bottom: 0;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.product-selector-box {
    flex: 1.6;
    min-width: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 80px;
    padding: 15px 20px;
}

.product-dropdown {
    width: 100%;
    height: 44px !important;
    padding: 12px 15px;
    border: 2px solid rgba(255, 193, 7, 0.3);
    border-radius: 10px;
    background: #ffffff;
    color: #333;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    height: 44px !important;
    min-height: 44px !important;
    box-sizing: border-box;
}

.product-dropdown:focus {
    outline: none;
    border-color: rgba(255, 193, 7, 0.6);
    box-shadow: 0 0 10px rgba(255, 193, 7, 0.2);
}

.product-dropdown:hover {
    border-color: rgba(255, 193, 7, 0.5);
}

.product-price-box {
    flex: 1.2;
    min-width: 250px;
    max-width: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 80px;
    padding: 15px 20px;
}

.price-display {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 2px solid rgba(255, 193, 7, 0.4);
    border-radius: 10px;
    padding: 12px 15px;
    text-align: center;
    font-size: 1.1rem;
    color: #333;
    height: 44px !important;
    min-height: 44px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.registration-single-button {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 200px;
    height: auto;
}

.registration-single-button .simple-registration-btn {
    height: auto !important;
    width: 100%;
    min-height: 50px;
    padding: 15px 25px;
}

/* Mobile responsive for registration section */
@media (max-width: 768px) {
    .registration-section {
        flex-direction: column;
    }
    
    .product-selection-container {
        flex-direction: column;
        gap: 5px;
        width: 100%;
    }
    
    .product-selector-box,
    .product-price-box {
        min-width: auto;
        width: 100%;
        flex: none;
        margin-bottom: -20px;
    }
    
    .registration-single-button {
        min-width: auto;
    }
    
    .simple-registration-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}
