/* Combined Profile Display */

/* Container */
.pdp-container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0;
    box-sizing: border-box;
}

/* Instagram Container Specific Styles */
.pdp-instagram-container .pdp-instagram-grid {
    display: flex;
    flex-wrap: wrap; /* Allow wrapping for multiple rows */
    justify-content: space-between;
    gap: 20px;
}

/* Instagram Profile Box */
.pdp-instagram-container .pdp-instagram-profile-box {
    position: relative;
    background-size: cover;
    background-position: center;
    border: 1px solid #ddd;
    flex: 0 0 calc((100% - 40px) / 3); /* Three boxes per row with 20px gaps */
    height: 400px;
    box-sizing: border-box;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    border-radius: 10px !important;
    overflow: hidden;
}

/* General Profile Display Container Specific Styles */
.pdp-general-container .pdp-general-grid {
    display: flex;
    flex-wrap: wrap; /* Allow wrapping for multiple rows */
    justify-content: space-between;
    gap: 20px;
}

/* General Profile Box */
.pdp-general-container .pdp-general-profile-box {
    position: relative;
    background-size: cover;
    background-position: center;
    border: 1px solid #ddd;
    flex: 0 0 calc((100% - 40px) / 3); /* Three boxes per row with 20px gaps */
    height: 400px;
    box-sizing: border-box;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    border-radius: 10px !important;
    overflow: hidden;
}

/* Overlay */
.pdp-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 35%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
    border-radius: inherit;
    z-index: 1;
}

/* Content */
.pdp-content {
    position: relative;
    z-index: 2;
    padding: 15px;
}

/* Profile Name */
.pdp-profile-name {
    margin: 0;
    margin-bottom: 5px !important;
}

.pdp-profile-name a {
    font-size: 18px !important;
    font-weight: 600 !important;
    color: white !important;
    text-decoration: none !important;
}

/* Profile Stats */
.pdp-instagram-container .pdp-profile-stats,
.pdp-general-container .pdp-profile-stats {
    font-size: 16px !important;
    margin-bottom: 5px !important;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Stat Items */
.pdp-stat-item {
    display: flex;
    align-items: center;
    gap: 2px;
}

.pdp-heart-stat-item {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* Icons */
.pdp-icon {
    width: 1.5em !important;
    height: 1.5em !important;
    fill: none !important;
    stroke: currentColor !important;
    vertical-align: middle !important;
}

/* Count */
.pdp-count {
    font-size: 1em !important;
    color: white !important;
}

/* Profile Button */
.pdp-profile-button {
    display: inline-block;
    background-color: #00AFF0 !important;
    color: white !important;
    text-decoration: none !important;
    border-radius: 5px !important;
    padding: 10px 15px !important;
    margin-top: 1px;
    font-size: 16px;
    font-weight: 600 !important;
    opacity: 1 !important;
    transition: none !important;
}

.pdp-profile-button:hover {
    background-color: #00AFF0 !important;
    color: white !important;
    text-decoration: none !important;
    opacity: 1 !important;
}

/* Pagination */
.pdp-pagination {
    margin-top: 30px !important;
    text-align: center !important;
}

.pdp-pagination ul {
    list-style: none;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    margin: 0;
}

.pdp-pagination li {
    margin: 0 5px;
}

.pdp-pagination a,
.pdp-pagination .current,
.pdp-pagination .disabled {
    width: 43px;
    height: 43px;
    line-height: 43px;
    padding: 0;
    text-align: center;
    display: inline-block;
    box-sizing: border-box;
    font-size: 18px;
    color: black;
    background: none;
    border: 1px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
}

.pdp-pagination .current {
    color: #00AFF0;
    font-weight: bold;
    background-color: #f0f0f0;
}

.pdp-pagination .disabled {
    color: #ccc;
    cursor: not-allowed;
    background-color: #f9f9f9;
}

.pdp-pagination a:hover {
    background-color: #e0e0e0;
    color: #00AFF0;
}

.pdp-pagination .dots {
    font-size: 18px;
    color: black;
    margin: 0 5px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    /* Instagram Profile Box remains 3 per row */
    .pdp-instagram-container .pdp-instagram-profile-box,
    .pdp-general-container .pdp-general-profile-box {
        flex: 0 0 calc((100% - 40px) / 3); /* Maintain three per row */
    }
}

@media (max-width: 768px) {
    /* Instagram Profile adjusts to two per row */
    .pdp-instagram-container .pdp-instagram-profile-box,
    .pdp-general-container .pdp-general-profile-box {
        flex: 0 0 calc((100% - 20px) / 2); /* Two per row */
    }
}

@media (max-width: 480px) {
    /* Instagram Profile adjusts to one per row */
    .pdp-instagram-container .pdp-instagram-grid,
    .pdp-general-container .pdp-general-grid {
        justify-content: center;
    }

    .pdp-instagram-container .pdp-instagram-profile-box,
    .pdp-general-container .pdp-general-profile-box {
        flex: 0 0 100%; /* One per row */
        margin: 10px 0;
    }
}
