/**
 * Service Provider Directory - Frontend Styles
 */

/* Reset & Base */
.spd-directory-wrapper {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 40px;
    position: relative;
    color: #333;
    line-height: 1.6;
}

.spd-directory-wrapper * {
    box-sizing: border-box;
}

/* Header Section */
.spd-header {
    text-align: center;
    margin-bottom: 35px;
}

.spd-title {
    font-size: 2.75rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 12px;
    line-height: 1.2;
}

.spd-subtitle {
    font-size: 1.05rem;
    color: #666;
    margin: 0;
}

/* Search Section */
.spd-search-section {
    margin-bottom: 25px;
}

.spd-search-bar {
    display: flex;
    align-items: center;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 50px;
    padding: 8px 8px 8px 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    max-width: 700px;
    margin: 0 auto;
}

.spd-search-icon {
    width: 20px;
    height: 20px;
    color: #999;
    flex-shrink: 0;
}

.spd-search-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 10px 15px;
    font-size: 0.95rem;
    background: transparent;
}

.spd-search-input::placeholder {
    color: #999;
}

.spd-search-btn {
    background: #00B894;
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 12px 28px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.spd-search-btn:hover {
    background: #00A085;
}

/* Stats */
.spd-stats {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 25px;
    margin-bottom: 25px;
    padding: 0 20px;
}

.spd-stat {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    color: #555;
}

.spd-stat svg {
    width: 18px;
    height: 18px;
    color: #00B894;
}

/* Filters */
.spd-filters {
    margin-bottom: 25px;
}

.spd-filter-group {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.spd-filter-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #555;
    min-width: 90px;
}

.spd-filter-label svg {
    width: 16px;
    height: 16px;
}

.spd-filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.spd-filter-btn {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    padding: 6px 16px;
    font-size: 0.85rem;
    color: #555;
    cursor: pointer;
    transition: all 0.2s;
}

.spd-filter-btn:hover {
    border-color: #00B894;
    color: #00B894;
}

.spd-filter-btn.active {
    background: #00B894;
    border-color: #00B894;
    color: #fff;
}

/* Results Section */
.spd-results-section {
    position: relative;
    min-height: 200px;
}

.spd-results-count {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 20px;
}

.spd-providers-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.spd-no-results {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    background: #f9f9f9;
    border-radius: 12px;
}

/* Provider Card */
.spd-provider-card {
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    padding: 28px 30px;
    transition: box-shadow 0.2s, border-color 0.2s;
}

.spd-provider-card:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border-color: #d0d0d0;
}

.spd-card-main {
    display: flex;
    gap: 24px;
}

/* Card Icon */
.spd-card-icon {
    width: 70px;
    height: 70px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.spd-card-icon svg {
    width: 32px;
    height: 32px;
}

.spd-card-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Card Content */
.spd-card-content {
    flex: 1;
    min-width: 0;
}

.spd-card-header {
    margin-bottom: 2px;
}

.spd-card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    line-height: 1.3;
}

.spd-verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #E8F8F5;
    border: 1px solid #00B894;
    color: #00B894;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 5px 12px;
    border-radius: 20px;
}

.spd-verified-badge svg {
    width: 14px;
    height: 14px;
}

.spd-card-category {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 6px;
}

.spd-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 12px;
}

.spd-meta-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.spd-meta-item svg {
    width: 15px;
    height: 15px;
    color: #777;
}

.spd-meta-divider {
    color: #999;
}

.spd-meta-projects {
    color: #666;
}

.spd-card-description {
    font-size: 0.95rem;
    color: #444;
    margin: 0 0 14px;
    line-height: 1.5;
}

/* Services Tags */
.spd-card-services {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
    padding-bottom: 18px;
    border-bottom: 1px solid #eee;
}

.spd-service-tag {
    background: #f5f5f5;
    color: #444;
    font-size: 0.85rem;
    padding: 6px 14px;
    border-radius: 6px;
    font-weight: 400;
}

/* Contact Info */
.spd-card-contact {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    font-size: 0.9rem;
    color: #555;
}

.spd-contact-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.spd-contact-item svg {
    width: 16px;
    height: 16px;
    color: #777;
}

/* Card Actions */
.spd-card-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: space-between;
    min-width: 160px;
    padding-left: 20px;
}

/* Badge */
.spd-badge {
    text-align: center;
    padding: 10px 16px;
    border-radius: 8px;
    color: #fff;
    min-width: 100px;
}

.spd-badge-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
}

.spd-badge-reviews {
    display: block;
    font-size: 0.75rem;
    opacity: 0.9;
    margin-top: 2px;
}

/* Rating */
.spd-rating {
    text-align: right;
}

.spd-rating-main {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 4px;
}

.spd-rating-star {
    color: #F5A623;
    font-size: 1.4rem;
}

.spd-rating-value {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a1a1a;
}

.spd-rating-reviews {
    display: block;
    font-size: 0.8rem;
    color: #888;
    margin-top: 2px;
}

/* View Profile Button */
.spd-view-profile-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    color: #00B894;
    border: 2px solid #00B894;
    text-decoration: none;
    padding: 12px 22px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s;
    white-space: nowrap;
}

.spd-view-profile-btn:hover {
    background: #00B894;
    color: #fff;
}

.spd-view-profile-btn:hover .spd-btn-icon {
    background: #fff;
}

.spd-view-profile-btn:hover .spd-btn-icon svg {
    stroke: #00B894;
}

.spd-btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: #00B894;
    border-radius: 50%;
    transition: all 0.2s;
}

.spd-btn-icon svg {
    width: 12px;
    height: 12px;
    stroke: #fff;
}

/* Pagination */
.spd-pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.spd-pagination a,
.spd-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 0.875rem;
    color: #555;
    text-decoration: none;
    transition: all 0.2s;
}

.spd-pagination a:hover {
    border-color: #00B894;
    color: #00B894;
}

.spd-pagination .current {
    background: #00B894;
    border-color: #00B894;
    color: #fff;
}

/* Loading */
.spd-loading {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.85);
    align-items: center;
    justify-content: center;
    z-index: 10;
    border-radius: 12px;
}

.spd-loading.active {
    display: flex;
}

.spd-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e0e0e0;
    border-top-color: #00B894;
    border-radius: 50%;
    animation: spd-spin 0.8s linear infinite;
}

@keyframes spd-spin {
    to {
        transform: rotate(360deg);
    }
}

/* CTA Section */
.spd-cta-section {
    background: #00B894;
    border-radius: 16px;
    padding: 50px 40px;
    text-align: center;
    margin-top: 50px;
}

.spd-cta-title {
    font-size: 1.75rem;
    font-weight: 600;
    color: #fff;
    margin: 0 0 10px;
}

.spd-cta-text {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 0 0 25px;
}

.spd-cta-btn {
    display: inline-block;
    background: #fff;
    color: #1a1a1a;
    text-decoration: none;
    padding: 14px 32px;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
}

.spd-cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #1a1a1a;
}

/* Responsive */
@media (max-width: 992px) {
    .spd-directory-wrapper {
        padding: 20px 25px;
    }
}

@media (max-width: 768px) {
    .spd-directory-wrapper {
        padding: 15px;
    }

    .spd-title {
        font-size: 1.75rem;
    }

    .spd-search-bar {
        flex-wrap: wrap;
        border-radius: 12px;
        padding: 12px;
    }

    .spd-search-input {
        width: 100%;
        padding: 10px 0;
    }

    .spd-search-btn {
        width: 100%;
        margin-top: 8px;
    }

    .spd-search-icon {
        display: none;
    }

    .spd-stats {
        gap: 15px;
    }

    .spd-stat {
        font-size: 0.8rem;
    }

    .spd-filter-group {
        flex-direction: column;
        align-items: flex-start;
    }

    .spd-card-main {
        flex-direction: column;
    }

    .spd-card-icon {
        width: 60px;
        height: 60px;
    }

    .spd-card-actions {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        margin-top: 20px;
        padding-top: 20px;
        padding-left: 0;
        border-top: 1px solid #eee;
        min-width: auto;
    }

    .spd-badge,
    .spd-rating {
        text-align: left;
    }

    .spd-rating-main {
        justify-content: flex-start;
    }

    .spd-card-services {
        border-bottom: none;
        padding-bottom: 0;
        margin-bottom: 14px;
    }

    .spd-cta-section {
        padding: 35px 25px;
    }

    .spd-cta-title {
        font-size: 1.4rem;
    }
}

@media (max-width: 480px) {
    .spd-filter-buttons {
        gap: 6px;
    }

    .spd-filter-btn {
        padding: 5px 12px;
        font-size: 0.8rem;
    }

    .spd-provider-card {
        padding: 20px;
    }

    .spd-card-title {
        font-size: 1.1rem;
    }

    .spd-card-services {
        gap: 8px;
    }

    .spd-service-tag {
        font-size: 0.8rem;
        padding: 5px 10px;
    }

    .spd-view-profile-btn {
        padding: 10px 18px;
        font-size: 0.85rem;
    }

    .spd-card-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

    .spd-view-profile-btn {
        justify-content: center;
    }
}

/* =====================================================
   SINGLE PROVIDER PAGE STYLES
   ===================================================== */

.spd-single-wrapper {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    max-width: 1100px;
    margin: 0 auto;
    padding: 30px 40px 60px;
    color: #333;
    line-height: 1.6;
}

.spd-single-wrapper * {
    box-sizing: border-box;
}

/* Breadcrumb */
.spd-single-breadcrumb {
    margin-bottom: 25px;
}

.spd-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #666;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.spd-back-link:hover {
    color: #00B894;
}

.spd-back-link svg {
    width: 18px;
    height: 18px;
}

/* Main Content Container */
.spd-single-content {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

/* Header Section */
.spd-single-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 35px;
    background: linear-gradient(135deg, #f8fffe 0%, #f0f9f7 100%);
    border-bottom: 1px solid #e8f5f2;
}

.spd-single-header-main {
    display: flex;
    gap: 25px;
    flex: 1;
}

.spd-single-avatar {
    width: 100px;
    height: 100px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.spd-single-avatar svg {
    width: 45px;
    height: 45px;
}

.spd-single-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.spd-single-title-area {
    flex: 1;
}

.spd-single-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 8px;
}

.spd-single-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    line-height: 1.2;
}

.spd-single-verified {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #E8F8F5;
    color: #00B894;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 25px;
}

.spd-single-verified svg {
    width: 16px;
    height: 16px;
}

.spd-single-category {
    display: inline-block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.spd-single-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.spd-single-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: #666;
}

.spd-single-meta-item svg {
    width: 16px;
    height: 16px;
    color: #888;
}

/* Header Side - Rating/Badge */
.spd-single-header-side {
    flex-shrink: 0;
}

.spd-single-badge {
    text-align: center;
    padding: 12px 20px;
    border-radius: 12px;
    color: #fff;
}

.spd-single-badge-label {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
}

.spd-single-badge-reviews {
    display: block;
    font-size: 0.8rem;
    opacity: 0.9;
    margin-top: 2px;
}

.spd-single-rating {
    text-align: center;
}

.spd-single-rating-stars {
    font-size: 1.5rem;
    letter-spacing: 2px;
    margin-bottom: 5px;
}

.spd-single-rating-stars .star {
    color: #e0e0e0;
}

.spd-single-rating-stars .star.filled {
    color: #F5A623;
}

.spd-single-rating-stars .star.half {
    color: #F5A623;
}

.spd-single-rating-value {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1a1a;
}

.spd-single-rating-count {
    display: block;
    font-size: 0.8rem;
    color: #888;
}

/* Sections */
.spd-single-section {
    padding: 30px 35px;
    border-bottom: 1px solid #f0f0f0;
}

.spd-single-section:last-of-type {
    border-bottom: none;
}

.spd-single-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.15rem;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 18px;
}

.spd-single-section-title svg {
    width: 22px;
    height: 22px;
    color: #00B894;
}

.spd-single-section-content p {
    font-size: 0.95rem;
    color: #555;
    margin: 0;
    line-height: 1.7;
}

/* Services Tags */
.spd-single-services {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.spd-single-service-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 2px solid;
    padding: 10px 18px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 500;
}

.spd-single-service-tag svg {
    width: 16px;
    height: 16px;
}

/* Contact Grid */
.spd-single-contact-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.spd-single-contact-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px;
    background: #f9fafb;
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
}

a.spd-single-contact-card:hover {
    background: #f0f4f3;
    transform: translateY(-2px);
}

.spd-contact-card-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.spd-contact-card-icon svg {
    width: 24px;
    height: 24px;
}

.spd-contact-card-content {
    min-width: 0;
}

.spd-contact-card-label {
    display: block;
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 2px;
}

.spd-contact-card-value {
    display: block;
    font-size: 0.95rem;
    font-weight: 500;
    color: #1a1a1a;
    word-break: break-word;
}

/* CTA Buttons */
.spd-single-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 25px 35px 35px;
    justify-content: center;
}

.spd-single-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
}

.spd-single-cta-btn svg {
    width: 18px;
    height: 18px;
}

.spd-cta-phone {
    background: #00B894;
    color: #fff;
}

.spd-cta-phone:hover {
    background: #00A085;
    color: #fff;
}

.spd-cta-email {
    background: #0984E3;
    color: #fff;
}

.spd-cta-email:hover {
    background: #0770c2;
    color: #fff;
}

.spd-cta-website {
    background: #6C5CE7;
    color: #fff;
}

.spd-cta-website:hover {
    background: #5b4bc4;
    color: #fff;
}

/* Single Page Responsive */
@media (max-width: 992px) {
    .spd-single-wrapper {
        padding: 25px 25px 40px;
    }
}

@media (max-width: 768px) {
    .spd-single-wrapper {
        padding: 20px 15px 40px;
    }

    .spd-single-header {
        flex-direction: column;
        gap: 20px;
        padding: 25px;
    }

    .spd-single-header-main {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .spd-single-avatar {
        width: 80px;
        height: 80px;
    }

    .spd-single-title-row {
        justify-content: center;
    }

    .spd-single-title {
        font-size: 1.4rem;
    }

    .spd-single-meta {
        justify-content: center;
    }

    .spd-single-header-side {
        width: 100%;
    }

    .spd-single-badge,
    .spd-single-rating {
        text-align: center;
    }

    .spd-single-section {
        padding: 25px 20px;
    }

    .spd-single-contact-grid {
        grid-template-columns: 1fr;
    }

    .spd-single-cta {
        padding: 20px;
        flex-direction: column;
    }

    .spd-single-cta-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .spd-single-services {
        gap: 8px;
    }

    .spd-single-service-tag {
        padding: 8px 14px;
        font-size: 0.85rem;
    }

    .spd-single-section-title {
        font-size: 1rem;
    }
}
