/* Service Card Component Styles */
.service-interactive-card {
    position: relative;
    transition: transform 0.3s ease;
    will-change: transform;
    backface-visibility: hidden;
}

.feature-card {
    cursor: pointer;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(226, 232, 240, 0.8);
    transform: translateY(0) translateZ(0);
    transition: all 0.3s ease;
    padding: 2rem;
    border-radius: 16px;
    background: white;
    will-change: transform, opacity;
    backface-visibility: hidden;
    contain: paint;
}

.feature-card:hover {
    transform: translateY(-8px) translateZ(0);
    border-color: rgba(225, 29, 72, 0.2);
    box-shadow: 
        0 20px 30px -10px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(225, 29, 72, 0.1);
}

.card-overlay {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    opacity: 0.7;
    transition: opacity 0.3s ease;
    will-change: opacity;
    contain: paint;
}

.feature-card:hover .card-overlay {
    opacity: 1;
}

/* Modal Base Layer */
.solutions-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #ffffff;
    z-index: 99999;
    transform: translateY(100%);
    transition: transform 0.8s cubic-bezier(0.23, 1, 0.32, 1);
    will-change: transform, opacity;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    backface-visibility: hidden;
}

.solutions-modal.active {
    transform: translateY(0);
}

.solutions-modal.closing {
    transform: translateY(100%);
}

/* Modal Content Container */
.modal-content {
    position: relative;
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 8rem 2rem;
    opacity: 1;
    transition: opacity 0.3s ease-out;
    will-change: opacity, transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.solutions-modal.closing .modal-content {
    opacity: 0;
}

/* Modal Header Animation */
.modal-header {
    opacity: 0;
    transform: translateY(30px) translateZ(0);
    transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1) 0.2s;
    will-change: transform, opacity;
    backface-visibility: hidden;
}

.solutions-modal.active .modal-header {
    opacity: 1;
    transform: translateY(0) translateZ(0);
}

/* Feature Items */
.feature-item {
    opacity: 0;
    transform: translateY(40px) translateZ(0);
    transition: opacity 0.6s ease-out, transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
    will-change: opacity, transform;
    backface-visibility: hidden;
}

/* Reset styles for subsequent openings */
.solutions-modal:not(.active) .feature-item {
    transition: none;
}

/* Close Button Animation */
.modal-close {
    position: fixed;
    top: 2rem;
    right: 2rem;
    width: 3rem;
    height: 3rem;
    background: white;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    cursor: pointer;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.8) rotate(-90deg) translateZ(0);
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    will-change: transform, opacity;
    backface-visibility: hidden;
}

/* Ensure modal close button stays visible */
.solutions-modal.active .modal-close {
    opacity: 1;
    transform: scale(1) rotate(0) translateZ(0);
}

.solutions-modal.closing .modal-close {
    opacity: 0;
    transform: scale(0.8) rotate(90deg) translateZ(0);
}

.modal-close:hover {
    transform: scale(1.1) rotate(90deg) translateZ(0);
    background: rgb(225, 29, 72);
    color: white;
    border-color: transparent;
}

/* Page Transition Effect */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity 0.4s ease-out;
    pointer-events: none;
    z-index: 99998;
    will-change: opacity;
}

.modal-backdrop.active {
    opacity: 1;
    pointer-events: auto;
}

/* Feature Grid Animation */
.modal-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    padding-bottom: 4rem; /* Add padding at bottom for scrolling */
}

.modal-grid .feature-item {
    transition-duration: 0.8s;
}

/* Ensure smooth scrolling */
.modal-open {
    overflow: hidden !important;
    width: 100%;
    height: 100%;
}

/* Feature Content Styling */
.feature-content-wrapper {
    max-height: 70vh;
    overflow-y: auto;
    padding-right: 1rem;
    /* Customize scrollbar */
    scrollbar-width: thin;
    scrollbar-color: rgba(225, 29, 72, 0.5) rgba(226, 232, 240, 0.4);
}

/* Webkit scrollbar styles */
.feature-content-wrapper::-webkit-scrollbar {
    width: 6px;
}

.feature-content-wrapper::-webkit-scrollbar-track {
    background: rgba(226, 232, 240, 0.4);
    border-radius: 3px;
}

.feature-content-wrapper::-webkit-scrollbar-thumb {
    background: rgba(225, 29, 72, 0.5);
    border-radius: 3px;
}

.feature-intro {
    font-size: 1.125rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    color: rgb(71, 85, 105);
}

.feature-subtitle {
    font-size: 1.25rem;
    font-weight: 600;
    color: rgb(15, 23, 42);
    margin: 2rem 0 1rem;
}

.feature-list {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem;
}

.feature-list li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.feature-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.75rem;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgb(225, 29, 72);
    transform: translateY(-50%);
}

.feature-tech {
    font-family: monospace;
    font-size: 0.9rem;
    color: rgb(100, 116, 139);
    padding: 0.75rem;
    background: rgba(248, 250, 252, 0.8);
    border-radius: 0.5rem;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

/* Adjust modal grid for 4 items */
.modal-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

@media (max-width: 1024px) {
    .modal-grid {
        grid-template-columns: 1fr;
    }
}

/* Enhanced feature item hover */
.feature-item {
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-item:hover {
    transform: translateY(-4px) translateZ(0);
    box-shadow: 0 12px 24px -8px rgba(0, 0, 0, 0.1);
}

/* Expanded state refinements */
.modal-feature.expanded .feature-content-wrapper {
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px) translateZ(0);
    }
    to {
        opacity: 1;
        transform: translateY(0) translateZ(0);
    }
}

/* Body state when modal is open - handled by JavaScript */

/* Prevent content shift */
.modal-content {
    position: relative;
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 8rem 2rem;
    opacity: 1;
    transition: opacity 0.3s ease-out;
}

/* Update service section layout */
.service-section {
    padding: 2rem 0;
}

.service-interactive-card {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
}

.feature-card {
    padding: 2.5rem;
    text-align: center;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 1rem 0;
    color: rgb(15, 23, 42);
}

.feature-card i {
    font-size: 2rem;
    color: rgb(225, 29, 72);
    will-change: transform, color;
    backface-visibility: hidden;
    transform: translateZ(0);
}

/* Grid layout helpers */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    align-items: center;
    justify-content: center;
}

@media (max-width: 768px) {
    .service-section {
        padding: 1.5rem 0;
    }
    
    .feature-card {
        padding: 2rem;
    }
}

/* Services Row Layout */
.services-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin: 0 auto;
    max-width: 100%;
}

/* Service Section Styles */
.service-section {
    padding: 1rem;
    display: flex;
    justify-content: center;
}

/* Card Styles */
.service-interactive-card {
    width: 100%;
    max-width: 380px;
}

.feature-card {
    background: white;
    border-radius: 16px;
    padding: 2.5rem 2rem;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(226, 232, 240, 0.8);
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
}

.feature-card:hover {
    transform: translateY(-8px) translateZ(0);
    border-color: rgba(225, 29, 72, 0.2);
    box-shadow: 
        0 20px 30px -10px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(225, 29, 72, 0.1);
}

.feature-card i {
    font-size: 2.5rem;
    color: rgb(225, 29, 72);
    margin-bottom: 0.5rem;
}

.feature-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: rgb(15, 23, 42);
    margin: 0;
    line-height: 1.4;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .services-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .services-row {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .service-section {
        padding: 0.5rem;
    }

    .feature-card {
        padding: 2rem 1.5rem;
    }
}

/* Ensure consistent card heights */
.service-interactive-card {
    height: 100%;
    display: flex;
}

.feature-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Card Overlay Enhancement */
.card-overlay {
    position: absolute;
    bottom: 1.5rem;
    right: 1.5rem;
    opacity: 0;
    transform: translateY(10px) translateZ(0);
    transition: all 0.3s ease;
    will-change: transform, opacity;
}

.feature-card:hover .card-overlay {
    opacity: 0.7;
    transform: translateY(0) translateZ(0);
}

/* Ensure consistent spacing */
.services-main {
    padding: 1rem 0;
}

/* Enhanced Service Card Styles */
.services-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin: 0 auto;
    max-width: 100%;
    perspective: 1000px; /* Add depth perspective for hover effects */
}

.service-section {
    padding: 1rem;
    display: flex;
    justify-content: center;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.6s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

.service-section:nth-child(1) { animation-delay: 0.1s; }
.service-section:nth-child(2) { animation-delay: 0.2s; }
.service-section:nth-child(3) { animation-delay: 0.3s; }

.feature-card {
    background: white;
    border-radius: 20px;
    padding: 3rem 2rem;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    border: 1px solid rgba(226, 232, 240, 0.8);
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.9);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg,
        rgba(225, 29, 72, 0.1) 0%,
        transparent 100%
    );
    opacity: 0;
    transition: opacity 0.4s ease;
}

.feature-card:hover {
    transform: translateY(-12px) scale(1.02);
    border-color: rgba(225, 29, 72, 0.2);
    box-shadow: 
        0 20px 40px -10px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(225, 29, 72, 0.1),
        0 0 0 4px rgba(225, 29, 72, 0.05);
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-card i {
    font-size: 3rem;
    color: rgb(225, 29, 72);
    transition: all 0.4s ease;
    position: relative;
}

.feature-card:hover i {
    transform: scale(1.1) translateY(-5px);
    color: rgb(190, 18, 60);
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: rgb(15, 23, 42);
    margin: 0;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.feature-card:hover h3 {
    color: rgb(225, 29, 72);
}

/* Enhanced Card Overlay */
.card-overlay {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    opacity: 0;
    transform: translateY(10px) scale(0.8);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.feature-card:hover .card-overlay {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.card-overlay i {
    font-size: 1.5rem;
    color: rgb(225, 29, 72);
    background: white;
    padding: 0.5rem;
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

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

/* Responsive Enhancements */
@media (max-width: 1280px) {
    .services-row {
        gap: 2rem;
    }
    
    .feature-card {
        padding: 2.5rem 1.5rem;
    }
}

@media (max-width: 1024px) {
    .services-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .services-row {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .service-section {
        padding: 0.5rem;
    }

    .feature-card {
        padding: 2rem;
    }
    
    .feature-card:hover {
        transform: translateY(-8px) scale(1.01);
    }
}

/* Touch Device Optimizations */
@media (hover: none) {
    .feature-card {
        transform: none !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }
    
    .card-overlay {
        opacity: 1;
        transform: none;
    }
} 

/* Scope service card styles specifically */
.services-main {
    padding: 1rem 0;
    background: #ffffff;
}

.services-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin: 0 auto;
    max-width: 100%;
    perspective: 1000px;
}

/* Service Section Styles - Scoped */
.services-main .service-section {
    padding: 1rem;
    display: flex;
    justify-content: center;
    opacity: 0;
    transform: translateY(30px);
    animation: servicesFadeInUp 0.6s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

/* Rename animations to avoid conflicts */
@keyframes servicesFadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.services-main .service-section:nth-child(1) { animation-delay: 0.1s; }
.services-main .service-section:nth-child(2) { animation-delay: 0.2s; }
.services-main .service-section:nth-child(3) { animation-delay: 0.3s; }

/* Service Card Specific Styles */
.services-main .feature-card {
    background: white;
    border-radius: 20px;
    padding: 3rem 2rem;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    border: 1px solid rgba(226, 232, 240, 0.8);
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.9);
}

/* Ensure these styles don't affect home page */
.services-main .service-interactive-card {
    width: 100%;
    max-width: 380px;
    height: 100%;
    display: flex;
}

/* Modal styles remain the same */
.solutions-modal {
    /* ... existing modal styles ... */
}

/* Responsive styles specifically for services */
@media (max-width: 1280px) {
    .services-main .services-row {
        gap: 2rem;
    }
    
    .services-main .feature-card {
        padding: 2.5rem 1.5rem;
    }
}

@media (max-width: 1024px) {
    .services-main .services-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .services-main .services-row {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .services-main .service-section {
        padding: 0.5rem;
    }

    .services-main .feature-card {
        padding: 2rem;
    }
} 

/* Topic List Styles */
.topics-list {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.topic-item {
    border: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 12px;
    margin-bottom: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.topic-item:hover {
    border-color: rgba(225, 29, 72, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.topic-header {
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    background: white;
}

.topic-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: rgb(15, 23, 42);
    margin: 0;
}

.topic-header i {
    color: rgb(225, 29, 72);
    transition: transform 0.3s ease;
}

.topic-item.active .topic-header i {
    transform: rotate(180deg);
}

.topic-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    background: rgba(248, 250, 252, 0.8);
}

.topic-item.active .topic-content {
    max-height: 500px;
    padding: 1.5rem;
    border-top: 1px solid rgba(226, 232, 240, 0.8);
}

.topic-content p {
    margin: 0;
    color: rgb(71, 85, 105);
    line-height: 1.6;
} 

/* Update Category Grid Layout */
.categories-grid {
    display: flex;
    flex-direction: column;
    max-width: 800px;  /* Reduced from 1200px for single column */
    margin: 0 auto;
    padding: 3rem 2rem;
}

.category-section {
    margin-bottom: 3rem;
}

.category-title {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
}

.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-item {
    border-left: none;  /* Remove left border */
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.3);  /* Subtle bottom separator */
}

.category-item:last-child {
    border-bottom: none;  /* Remove border from last item */
}

.category-item-header {
    font-size: 1.375rem;
    padding: 0.375rem 0;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

/* Remove the line animation and simplify hover state */
.category-item-header::after {
    display: none;
}

/* Active state styling */
.category-item.active .category-item-header {
    color: rgb(225, 29, 72);
}

/* Description styling */
.category-item-description {
    font-size: 1.125rem;
    line-height: 1.5;
    max-height: 0;
    overflow: hidden;
    padding: 0;
    margin-top: 0;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-item.active .category-item-description {
    max-height: 200px;
    padding: 0.75rem 0;
    opacity: 1;
    transform: translateY(0);
}

/* Hover state refinements */
.category-item:hover .category-item-header {
    color: rgb(225, 29, 72);
    transform: translateX(8px);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .categories-grid {
        padding: 2rem 1rem;
    }

    .category-section {
        margin-bottom: 3rem;
    }

    .category-title {
        font-size: 1rem;
        margin-bottom: 2rem;
    }

    .category-item-header {
        font-size: 1.125rem;
    }

    .category-item-description {
        font-size: 0.9375rem;
    }
} 

/* Service Overview Styles */
.service-overview {
    max-width: 800px;
    margin: 0 auto 4rem;
    padding: 0 2rem;
    text-align: left;
}

.overview-text {
    font-size: 1.5rem;
    line-height: 1.5;
    color: rgb(71, 85, 105);
    font-weight: 300;
    letter-spacing: -0.01em;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .service-overview {
        margin-bottom: 3rem;
        padding: 0 1rem;
    }

    .overview-text {
        font-size: 1.25rem;
    }
} 