/* Products & Services - Immersive Cockpit Design */

/* Page Hero with Cockpit Background */
.page-hero {
    position: relative;
    height: 60vh;
    min-height: 500px;
    background-image: url('../images/products-cockpit-bg.jpg');
    background-size: cover;
    background-position: center center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-top: 80px;
}

/* Cockpit vignette effect */
.page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, transparent 25%, rgba(0,0,0,0.7) 90%, rgba(0,0,0,0.95) 100%);
    pointer-events: none;
    z-index: 1;
}

/* Subtle vibration animation */
@keyframes cockpitVibration {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(0.3px, 0.3px); }
    50% { transform: translate(-0.3px, 0.3px); }
    75% { transform: translate(0.3px, -0.3px); }
}

.page-hero {
    animation: cockpitVibration 6s ease-in-out infinite;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(26, 26, 26, 0.7) 0%,
        rgba(26, 26, 26, 0.6) 50%,
        rgba(196, 30, 58, 0.5) 100%
    );
    z-index: 2;
}

/* Logo header at top center of hero */
.products-logo-header {
    text-align: center;
    margin-bottom: 2rem;
}

.products-page-logo {
    width: 320px;
    height: auto;
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.8));
}

/* Logo fade-in animation removed */

.hero-content {
    position: relative;
    z-index: 3;
    text-align: center;
    color: var(--white);
    max-width: 900px;
    padding: 0 20px;
}

.hero-content h1 {
    font-size: 4.5rem;
    font-weight: 900;
    margin-bottom: 1rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    text-shadow: 
        0 0 20px rgba(196, 30, 58, 0.8),
        0 0 40px rgba(196, 30, 58, 0.4),
        2px 2px 4px rgba(0,0,0,0.8);
}

/* Title glow animation removed */

.hero-content p {
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: 2px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
    text-transform: uppercase;
}

/* Services Section with Cockpit Theme */
.services-section {
    padding: 5rem 0;
    background-image: url('../images/jc-aerospace-logo.png');
    background-size: 600px auto;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-color: var(--black);
    position: relative;
}

.services-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.75);
    pointer-events: none;
    z-index: 0;
}

/* Scanning grid effect */
.services-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(196, 30, 58, 0.03) 2px, rgba(196, 30, 58, 0.03) 4px);
    pointer-events: none;
    animation: scanGrid 20s linear infinite;
}

@keyframes scanGrid {
    0% { transform: translateY(0); }
    100% { transform: translateY(40px); }
}

.services-section .section-title {
    color: var(--white);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9);
    position: relative;
    z-index: 1;
}

.services-visual-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
    position: relative;
    z-index: 1;
}

/* HUD-style service cards */
.service-visual-item {
    background: rgba(26, 26, 26, 0.9);
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid rgba(196, 30, 58, 0.3);
    box-shadow: 
        0 10px 30px rgba(0,0,0,0.5),
        inset 0 0 20px rgba(196, 30, 58, 0.05);
    transition: all 0.4s ease;
    position: relative;
}

/* Corner brackets */
.service-visual-item::before,
.service-visual-item::after {
    content: '';
    position: absolute;
    width: 30px;
    height: 30px;
    border: 2px solid var(--primary-red);
    opacity: 0.5;
    transition: all 0.4s ease;
}

.service-visual-item::before {
    top: 10px;
    left: 10px;
    border-right: none;
    border-bottom: none;
}

.service-visual-item::after {
    bottom: 10px;
    right: 10px;
    border-left: none;
    border-top: none;
}

.service-visual-item:hover {
    transform: translateY(-10px);
    border-color: var(--primary-red);
    box-shadow: 
        0 20px 50px rgba(196, 30, 58, 0.4),
        inset 0 0 30px rgba(196, 30, 58, 0.1);
}

.service-visual-item:hover::before,
.service-visual-item:hover::after {
    opacity: 1;
    width: 40px;
    height: 40px;
}

.service-image-wrapper {
    width: 100%;
    height: 250px;
    overflow: hidden;
    position: relative;
}

.service-image-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(196, 30, 58, 0.2) 100%
    );
}

.service-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
    filter: brightness(0.9);
}

.service-visual-item:hover .service-image-wrapper img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.service-info {
    padding: 2rem;
}

.service-info h3 {
    font-size: 1.5rem;
    color: var(--white);
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    text-shadow: 0 0 10px rgba(196, 30, 58, 0.5);
}

.service-info p {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--light-gray);
}

/* Parts Section */
.parts-section {
    padding: 5rem 0;
    background-image: url('../images/jc-aerospace-logo.png');
    background-size: 600px auto;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-color: var(--black);
    position: relative;
}

.parts-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.75);
    pointer-events: none;
    z-index: 0;
}

.parts-section .section-title {
    color: var(--white);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9);
    position: relative;
    z-index: 1;
}

.parts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
    position: relative;
    z-index: 1;
}

/* Instrument panel style cards */
.part-card {
    background: rgba(26, 26, 26, 0.95);
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid rgba(196, 30, 58, 0.25);
    box-shadow: 
        0 5px 20px rgba(0,0,0,0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    position: relative;
}

/* Glowing edge effect */
.part-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-red), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.part-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary-red);
    box-shadow: 
        0 15px 40px rgba(196, 30, 58, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.part-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    filter: brightness(0.85);
    transition: filter 0.3s ease;
}

.part-card:hover img {
    filter: brightness(1);
}

.part-card h3 {
    font-size: 1.3rem;
    color: var(--white);
    font-weight: 700;
    padding: 1.5rem 2rem 0.5rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.part-card p {
    font-size: 1rem;
    color: var(--light-gray);
    padding: 0 2rem 1.5rem;
}

/* Responsive Design */
@media (max-width: 968px) {
    .products-page-logo {
        width: 260px;
    }

    .page-hero {
        height: 50vh;
        min-height: 400px;
        background-attachment: scroll;
        animation: none;
    }

    .hero-content h1 {
        font-size: 3rem;
    }

    .hero-content p {
        font-size: 1.2rem;
    }

    .services-visual-grid,
    .parts-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .products-page-logo {
        width: 220px;
    }

    .page-hero {
        min-height: 350px;
    }

    .hero-content h1 {
        font-size: 2.5rem;
        letter-spacing: 2px;
    }

    .hero-content p {
        font-size: 1rem;
    }

    .service-visual-item::before,
    .service-visual-item::after {
        width: 20px;
        height: 20px;
    }
}
