/* OnDemandTechHelp Complete Services Overview CSS - Child Theme Integration */

/* Main Container */
.all-services-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 60px 20px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

/* Header Section */
.services-overview-header {
    text-align: center;
    margin-bottom: 80px;
    padding: 50px 20px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
}

.services-overview-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
}

.services-overview-header h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    color: #1e293b;
    margin: 0 0 20px 0;
    letter-spacing: -0.02em;
}

.services-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.25rem);
    color: #64748b;
    margin: 0;
    font-weight: 500;
    line-height: 1.5;
}

/* Services Grid */
.all-services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    margin-bottom: 80px;
}

/* Service Category Cards - Equal Height */
.service-category-card {
    background: white;
    border-radius: 20px;
    padding: 0;
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 400px; /* Ensures equal height */
}

.service-category-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
    border-color: #e2e8f0;
}

/* Category Header - Clickable */
.category-header {
    padding: 30px 30px 20px 30px;
    text-align: center;
    position: relative;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    cursor: pointer;
    transition: background 0.3s ease;
    flex-shrink: 0;
}

.category-header:hover {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
}

.category-header:focus {
    outline: 2px solid #1e293b;
    outline-offset: 2px;
}

.category-icon {
    font-size: 3rem;
    margin-bottom: 15px;
    display: block;
}

.category-header h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 10px 0;
    line-height: 1.2;
}

.category-price {
    display: inline-block;
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    color: white;
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    margin: 10px 0;
}

/* Dropdown Indicator */
.dropdown-indicator {
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #64748b;
    font-size: 0.9rem;
}

.dropdown-arrow {
    font-size: 1rem;
    transition: transform 0.3s ease;
    color: #1e293b;
    font-weight: bold;
}

.dropdown-text {
    font-weight: 500;
}

/* Category Description */
.category-description {
    padding: 0 30px 20px 30px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    flex-shrink: 0;
}

.category-description p {
    color: #475569;
    line-height: 1.6;
    margin: 0;
    font-size: 1rem;
    text-align: center;
    font-style: italic;
}

/* Sub-Services - Hidden by Default */
.sub-services {
    padding: 30px;
    flex-grow: 1;
    display: none;
    background: white;
}

.sub-services[style*="block"] {
    display: block !important;
}

.sub-service-item {
    padding: 20px;
    margin-bottom: 15px;
    background: #f8fafc;
    border-radius: 12px;
    border-left: 4px solid #1e293b;
    transition: all 0.3s ease;
}

.sub-service-item:last-child {
    margin-bottom: 0;
}

.sub-service-item:hover {
    background: #f1f5f9;
    transform: translateX(5px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.sub-service-item h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sub-service-item p {
    color: #64748b;
    line-height: 1.5;
    margin: 0;
    font-size: 0.9rem;
}

/* Category CTA - Always at Bottom */
.category-cta {
    padding: 20px 30px 30px 30px;
    margin-top: auto; /* Pushes to bottom */
    flex-shrink: 0;
}

.category-button {
    display: block;
    width: 100%;
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    color: white;
    text-decoration: none;
    padding: 15px 25px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(30, 41, 59, 0.3);
}

.category-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(30, 41, 59, 0.4);
    text-decoration: none;
    color: white;
}

/* Bottom CTA Section */
.services-bottom-cta {
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    border-radius: 20px;
    padding: 50px 40px;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.services-bottom-cta::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    pointer-events: none;
}

.services-bottom-cta h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    margin: 0 0 15px 0;
    position: relative;
    z-index: 1;
}

.services-bottom-cta p {
    font-size: 1.1rem;
    margin: 0 0 30px 0;
    color: #e2e8f0;
    position: relative;
    z-index: 1;
}

.bottom-cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.emergency-call-btn,
.request-service-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 18px 35px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    text-decoration: none;
    transition: all 0.3s ease;
    letter-spacing: 0.025em;
}

.emergency-call-btn {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(5, 150, 105, 0.3);
}

.emergency-call-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(5, 150, 105, 0.4);
    text-decoration: none;
    color: white;
}
.call-icon {
    font-size: 1.2rem;
    margin-right: 10px;
}

.request-service-btn {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.request-service-btn:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    color: white;
}

/* Responsive Design */
@media (max-width: 768px) {
    .all-services-container {
        padding: 40px 15px;
    }

    .services-overview-header {
        margin-bottom: 60px;
        padding: 40px 20px;
    }

    .all-services-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        margin-bottom: 60px;
    }

    .service-category-card {
        min-height: 350px; /* Smaller min-height on mobile */
    }

    .category-header {
        padding: 25px 20px 15px 20px;
    }

    .category-header h2 {
        font-size: 1.25rem;
    }

    .category-description {
        padding: 0 20px 15px 20px;
    }

    .sub-services {
        padding: 20px;
    }

    .sub-service-item {
        padding: 15px;
        margin-bottom: 12px;
    }

    .sub-service-item h4 {
        font-size: 0.95rem;
    }

    .sub-service-item p {
        font-size: 0.85rem;
    }

    .category-cta {
        padding: 15px 20px 20px 20px;
    }

    .services-bottom-cta {
        padding: 30px 20px;
    }

    .bottom-cta-buttons {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .emergency-call-btn,
    .request-service-btn {
        width: 100%;
        max-width: 300px;
        padding: 16px 30px;
    }
}

@media (max-width: 480px) {
    .service-category-card {
        min-height: 300px; /* Even smaller on very small screens */
    }

    .sub-service-item {
        padding: 12px;
    }

    .sub-service-item h4 {
        font-size: 0.9rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .dropdown-indicator {
        flex-direction: column;
        gap: 4px;
    }

    .dropdown-text {
        font-size: 0.8rem;
    }
}

/* Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.services-overview-header,
.service-category-card,
.services-bottom-cta {
    animation: fadeInUp 0.8s ease-out;
}

.service-category-card:nth-child(1) { animation-delay: 0.1s; }
.service-category-card:nth-child(2) { animation-delay: 0.2s; }
.service-category-card:nth-child(3) { animation-delay: 0.3s; }
.service-category-card:nth-child(4) { animation-delay: 0.4s; }
.service-category-card:nth-child(5) { animation-delay: 0.5s; }

/* Services Overlay Styles - Add to all-services-overview.css */

/* Desktop Overlay */
.services-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    animation: overlayFadeIn 0.3s ease-out;
}

@keyframes overlayFadeIn {
    from {
        opacity: 0;
        backdrop-filter: blur(0px);
    }
    to {
        opacity: 1;
        backdrop-filter: blur(5px);
    }
}

/*.services-overlay-content {
    background: white;
    border-radius: 20px;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: overlaySlideIn 0.3s ease-out;
*/
.services-overlay-content {
    background: white;
    border-radius: 20px;
    max-width: 700px; /* Reduced from 800px */
    width: 100%;
    max-height: 85vh; /* Reduced from 90vh */
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: overlaySlideIn 0.3s ease-out;
}

@keyframes overlaySlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Close Button */
.services-overlay-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #f1f5f9;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 18px;
    font-weight: bold;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.services-overlay-close:hover {
    background: #e2e8f0;
    color: #1e293b;
    transform: scale(1.1);
}

.services-overlay-close:focus {
    outline: 2px solid #1e293b;
    outline-offset: 2px;
}

/* Overlay Header */
/*.services-overlay-header {
    text-align: center;
    padding: 60px 40px 30px 40px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 20px 20px 0 0;
*/
.services-overlay-header {
    text-align: center;
    padding: 40px 30px 20px 30px; /* Reduced padding */
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 20px 20px 0 0;
}

.overlay-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    display: block;
}

.services-overlay-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 15px 0;
    line-height: 1.2;
}

.overlay-price {
    display: inline-block;
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    color: white;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    margin: 10px 0 20px 0;
}

.overlay-description {
    color: #475569;
    line-height: 1.6;
    margin: 0;
    font-size: 1.1rem;
    font-style: italic;
}

/* Overlay Services */
.services-overlay-services {
    padding: 20px 30px; /* Reduced padding */
    flex-grow: 1; /* Takes up remaining space */
}

.services-overlay-services .sub-service-item {
    padding: 15px; /* Reduced from 25px */
    margin-bottom: 12px; /* Reduced from 20px */
    background: #f8fafc;
    border-radius: 16px;
    border-left: 4px solid #1e293b;
    transition: all 0.3s ease;
}

.services-overlay-services .sub-service-item:hover {
    background: #f1f5f9;
    transform: translateX(8px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.services-overlay-services .sub-service-item h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.services-overlay-services .sub-service-item p {
    color: #64748b;
    line-height: 1.6;
    margin: 0;
    font-size: 1rem;
}

/* Overlay CTA */
.services-overlay-cta {
    padding: 20px 30px; /* Reduced padding */
    flex-shrink: 0; /* Prevents shrinking */
    text-align: center;
    background: white;
    border-radius: 0 0 20px 20px;
}

.overlay-cta-button {
    display: inline-block;
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    color: white;
    text-decoration: none;
    padding: 18px 40px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(30, 41, 59, 0.3);
    letter-spacing: 0.025em;
}

.overlay-cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(30, 41, 59, 0.4);
    text-decoration: none;
    color: white;
}

/* Mobile: Hide overlay (use dropdown instead) */
@media (max-width: 767px) {
    .services-overlay {
        display: none !important;
    }
}

/* Desktop: Update dropdown indicator text */
@media (min-width: 768px) {
    .dropdown-text {
        content: 'Click to view details';
    }

    .dropdown-text::after {
        content: ' in overlay';
        font-size: 0.8rem;
        color: #94a3b8;
    }
}

/* Responsive overlay for smaller desktops */
@media (min-width: 768px) and (max-width: 1024px) {
    .services-overlay-content {
        max-width: 90%;
        margin: 20px;
    }

    .services-overlay-header {
        padding: 50px 30px 25px 30px;
    }

    .services-overlay-services {
        padding: 30px;
    }

    .services-overlay-cta {
        padding: 25px 30px 30px 30px;
    }
}

/* Custom scrollbar for overlay content */
.services-overlay-content::-webkit-scrollbar {
    width: 8px;
}

.services-overlay-content::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.services-overlay-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.services-overlay-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}
