/**
 * Service Manager Plugin Styles
 * Frontend styling for service archive, single service, and shortcode
 */

/* ==========================================================================
   Service Archive Styles
   ========================================================================== */

.service-archive-container {
    padding: 40px 0;
}

.service-archive-container .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.service-archive-container .page-header {
    text-align: center;
    margin-bottom: 40px;
}

.service-archive-container .page-title {
    font-size: 2.5em;
    margin-bottom: 15px;
    color: var(--sm-secondary-color, #333);
}

.service-archive-container .archive-description {
    font-size: 1.1em;
    color: var(--sm-text-color, #666);
    max-width: 600px;
    margin: 0 auto;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    margin-bottom: 40px;
}

.service-item {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    padding: 20px !important;
}

.service-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.service-thumbnail {
    position: relative;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.service-thumbnail a {
    display: block;
    overflow: hidden !important;
    border-radius: 10px;
}

.service-thumbnail img {
    width: 100%;
    transition: transform 0.3s ease;
    border-radius: 10px;
}

.service-item:hover .service-thumbnail img {
    transform: scale(1.05);
}

.service-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.service-title {
    margin: 0 0 12px 0;
    font-size: 1.3em;
    font-weight: 700;
    line-height: 1.3;
}

.service-title a {
    color: var(--sm-secondary-color, #2c3e50);
    text-decoration: none;
    transition: color 0.3s ease;
}

.service-title a:hover {
    color: var(--sm-primary-color, #3498db);
}

.service-short-description,
.service-excerpt {
    margin-bottom: 20px;
    color: var(--sm-text-color, #7f8c8d);
    line-height: 1.5;
    font-size: 0.95em;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-align: justify;
}

.service-meta {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.featured-badge {
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.service-actions {
    margin-left: auto;
}

.read-more-btn {
    display: inline-block;
    background: #3498db;
    color: white;
    padding: 12px 24px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9em;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.read-more-btn:hover {
    background: #2980b9;
    color: white;
    transform: translateY(-1px);
}

/* No Services Found */
.no-services-found {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.no-services-found h2 {
    margin-bottom: 15px;
    color: #333;
}

/* Pagination */
.services-pagination {
    text-align: center;
    margin-top: 40px;
}

.services-pagination .nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.services-pagination a,
.services-pagination .current {
    display: inline-block;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s ease;
}

.services-pagination a:hover,
.services-pagination .current {
    background: #007cba;
    color: white;
    border-color: #007cba;
}

/* ==========================================================================
   Single Service Page Styles
   ========================================================================== */

.single-service-page {
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Back Navigation */
.back-navigation {
    padding: 24px 0;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #6c757d;
    text-decoration: none;
    font-size: 0.95em;
    font-weight: 500;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: #3498db;
}

.back-link svg {
    transition: transform 0.3s ease;
}

.back-link:hover svg {
    transform: translateX(-2px);
}

/* Service Hero Section */
.service-hero {
    padding: 48px 0;
}

.service-hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.service-info {
    animation: fadeIn 0.6s ease-out;
}

.service-badge-title {
    margin-bottom: 16px;
}

.service-badge {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 0.9em;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.service-badge svg {
    width: 20px;
    height: 20px;
}

.service-details .service-title {
    font-size: 3.2em;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--sm-secondary-color, #2c3e50);
    line-height: 1.2;
}

.service-subtitle {
    font-size: 1.2em;
    color: var(--sm-text-color, #7f8c8d);
    line-height: 1.6;
    margin-bottom: 24px;
}

.hero-cta {
    margin-top: 24px;
    margin-bottom: 32px;
}

.hero-cta-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 1em;
    padding: 14px 28px;
}

.hero-cta-button svg {
    transition: transform 0.3s ease;
}

.hero-cta-button:hover svg {
    transform: translateX(4px);
}

.service-image {
    animation: slideUp 0.8s ease-out;
}

.service-featured-img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Service Details Section */
.service-details {
    padding: 64px 0;
}

.service-description-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    animation: fadeIn 0.6s ease-out;
}

.card-header {
    background: #f8f9fa;
    padding: 24px 32px;
    border-bottom: 1px solid #e9ecef;
}

.card-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5em;
    font-weight: 600;
    color: var(--sm-secondary-color, #2c3e50);
    margin: 0;
}

.card-title svg {
    color: #3498db;
}

.card-content {
    padding: 32px;
}

.service-description {
    font-size: 1.1em;
    line-height: 1.7;
    color: #495057;
}

.service-description p {
    margin-bottom: 20px;
}

.service-description h2,
.service-description h3,
.service-description h4 {
    margin-top: 32px;
    margin-bottom: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.service-description ul,
.service-description ol {
    margin-bottom: 20px;
    padding-left: 30px;
}

.service-description li {
    margin-bottom: 8px;
}

/* CTA Section */
.service-cta {
    padding: 80px 0;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.service-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0.1;
}

.cta-content {
    position: relative;
    z-index: 1;
}

.cta-title,
.cta-text h3 {
    font-size: 2.5em;
    font-weight: 700;
    margin-bottom: 24px;
    color: white;
}

.cta-description,
.cta-text p {
    font-size: 1.2em;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 32px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 16px 32px;
    font-size: 1.1em;
    font-weight: 600;
    text-decoration: none;
    border-radius: 30px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.btn-primary {
    background: var(--sm-primary-color, #3498db);
    color: white;
}

.btn-primary:hover {
    background: var(--sm-primary-dark, #2980b9);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.cta-button svg {
    transition: transform 0.3s ease;
}

.cta-button:hover svg {
    transform: translateX(4px);
}

/* Related Services */
.related-services {
    padding: 64px 0;
    background: white;
}

.related-title {
    text-align: center;
    font-size: 2em;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 48px;
}

.related-services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
}

.related-service-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.related-service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.related-service-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.related-service-content {
    padding: 24px;
}

.related-service-title {
    margin: 0 0 12px 0;
    font-size: 1.3em;
    font-weight: 600;
    line-height: 1.3;
}

.related-service-title a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.related-service-title a:hover {
    color: #3498db;
}

.related-service-excerpt {
    color: #7f8c8d;
    margin-bottom: 16px;
    line-height: 1.5;
}

.related-service-link {
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9em;
}

.related-service-link:hover {
    text-decoration: underline;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   Featured Services Shortcode Styles
   ========================================================================== */

.featured-services-grid {
    display: grid;
    gap: 25px;
    margin-bottom: 30px;
}

.featured-services-grid.columns-1 {
    grid-template-columns: 1fr;
}

.featured-services-grid.columns-2 {
    grid-template-columns: repeat(2, 1fr);
}

.featured-services-grid.columns-3 {
    grid-template-columns: repeat(3, 1fr);
}

.featured-services-grid.columns-4 {
    grid-template-columns: repeat(4, 1fr);
}

.featured-service-item {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.featured-service-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.featured-service-item .service-image {
    position: relative;
    overflow: hidden;
    height: 220px;
}

.featured-service-item .service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.featured-service-item:hover .service-image img {
    transform: scale(1.05);
}

.featured-service-item .service-content {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.featured-service-item .service-title {
    margin: 0 0 12px 0;
    font-size: 1.3em;
    font-weight: 700;
    line-height: 1.3;
}

.featured-service-item .service-title a {
    color: var(--sm-secondary-color, #2c3e50);
    text-decoration: none;
    transition: color 0.3s ease;
}

.featured-service-item .service-title a:hover {
    color: var(--sm-primary-color, #3498db);
}

.featured-service-item .service-short-description {
    color: var(--sm-text-color, #7f8c8d);
    margin-bottom: 20px;
    line-height: 1.5;
    font-size: 0.95em;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.featured-service-item .service-meta {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.featured-service-item .service-actions {
    margin-left: auto;
}

.featured-service-item .service-read-more {
    display: inline-block;
    background: #3498db;
    color: white;
    padding: 12px 24px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9em;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.featured-service-item .service-read-more:hover {
    background: #2980b9;
    color: white;
    transform: translateY(-1px);
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 968px) {
    .service-hero-content {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .service-image {
        order: -1;
    }

    .service-featured-img {
        height: 300px;
    }

    .service-title {
        font-size: 2.4em;
    }

    .cta-title {
        font-size: 2em;
    }

    .related-services-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .service-hero {
        padding: 32px 0;
    }

    .service-title {
        font-size: 2em;
    }

    .service-subtitle {
        font-size: 1.1em;
    }

    .service-details {
        padding: 48px 0;
    }

    .card-header {
        padding: 20px 24px;
    }

    .card-content {
        padding: 24px;
    }

    .service-cta {
        padding: 60px 0;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 280px;
    }

    .related-services {
        padding: 48px 0;
    }

    .related-services-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* Featured services responsive - tablet */
    .featured-services-grid.columns-3,
    .featured-services-grid.columns-4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .featured-services-grid.columns-2 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {

    .service-archive-container .container,
    .single-service-container .container {
        padding: 0 15px;
    }

    .services-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .service-content,
    .featured-service-item .service-content,
    .related-service-content {
        padding: 20px;
    }

    .service-text-content {
        padding: 25px 20px;
    }

    .service-image-content {
        padding: 20px;
        min-height: 250px;
    }

    .single-service .service-title {
        font-size: 1.8em;
    }

    .service-archive-container .page-title {
        font-size: 1.8em;
    }

    /* Featured services responsive - mobile */
    .featured-services-grid.columns-2,
    .featured-services-grid.columns-3,
    .featured-services-grid.columns-4 {
        grid-template-columns: 1fr;
    }
}