/* API Drone - Services Styles (Modern Dark Theme) */

/* --- Service Hero --- */
.service-hero {
    position: relative;
    height: 70vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    color: var(--color-white);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    margin-top: 0;
    padding-top: var(--header-height);
}

.service-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
            rgba(0, 0, 0, 0.4) 0%,
            rgba(0, 0, 0, 0.2) 40%,
            rgba(0, 0, 0, 0.95) 100%);
    z-index: 1;
}

.service-hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    text-align: center;
    margin: 0 auto;
}

.service-hero h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.service-hero p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* --- Service Hub Cards (Glassmorphism) --- */
.service-card-hub {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: rgba(26, 31, 41, 0.6);
    /* Match product card */
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    overflow: hidden;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease, border-color 0.4s ease;
    text-decoration: none;
    color: var(--color-white);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.service-card-hub:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    border-color: var(--color-accent);
    background: rgba(26, 31, 41, 0.8);
}

.hub-img-wrapper {
    height: 240px;
    overflow: hidden;
    position: relative;
}

.hub-img-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, 0.6) 100%);
}

.hub-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.service-card-hub:hover .hub-img-wrapper img {
    transform: scale(1.1);
}

.hub-content {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.hub-icon {
    font-size: 2.5rem;
    color: var(--color-accent);
    margin-bottom: 1.5rem;
    background: rgba(230, 57, 70, 0.1);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    transition: 0.3s;
}

.service-card-hub:hover .hub-icon {
    background: var(--color-accent);
    color: white;
    transform: rotate(-5deg);
}

.hub-content h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.hub-content p {
    color: var(--color-gray-400);
    margin-bottom: 1.5rem;
    line-height: 1.6;
    font-size: 0.95rem;
}

.btn-link {
    margin-top: auto;
    color: var(--color-accent);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: 0.3s;
}

.btn-link:hover {
    color: #ff8a8a;
    /* Lighter accent */
    transform: translateX(5px);
}

/* --- Section Global --- */
.service-section {
    padding: 6rem 0;
    position: relative;
}

.section-title-center {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--color-white);
}

.section-subtitle {
    text-align: center;
    color: var(--color-gray-400);
    margin-bottom: 4rem;
    font-size: 1.1rem;
}

/* --- Tech Specs Table (Used in Detail Pages) --- */
.tech-specs-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.tech-specs-header {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem 2rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    font-size: 0.9rem;
    text-transform: uppercase;
    color: var(--color-white);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tech-spec-item {
    display: flex;
    justify-content: space-between;
    padding: 1.25rem 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background 0.2s ease;
}

.tech-spec-item:hover {
    background: rgba(255, 255, 255, 0.02);
}

.tech-spec-item:last-child {
    border-bottom: none;
}

.spec-label {
    font-weight: 600;
    color: var(--color-gray-400);
    font-size: 0.95rem;
}

.spec-value {
    color: var(--color-accent);
    text-align: right;
    font-family: 'Consolas', monospace;
    font-weight: 700;
}

/* --- Responsive --- */
@media (max-width: 991px) {
    .service-hero h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .service-hero {
        height: auto;
        padding-bottom: 4rem;
        min-height: auto;
    }

    .hub-img-wrapper {
        height: 200px;
    }
}

/* =========================================
   Photogrammetry Specific Styles
   ========================================= */

/* Hero Slider & Animation */
.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero-slider .splide__track,
.hero-slider .splide__list {
    height: 100%;
}

.splide__slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(to right, rgba(255, 200, 0, 0.1) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 200, 0, 0.1) 1px, transparent 1px);
    background-size: 60px 60px;
    animation: gridPulse 3s ease-in-out infinite;
    z-index: 1;
    pointer-events: none;
}

@keyframes gridPulse {

    0%,
    100% {
        opacity: 0.3;
        background-size: 60px 60px;
    }

    50% {
        opacity: 0.6;
        background-size: 55px 55px;
    }
}

.camera-focus {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    border: 2px solid rgba(255, 200, 0, 0.6);
    border-radius: 50%;
    animation: focusPulse 2s ease-in-out infinite;
    z-index: 2;
    pointer-events: none;
}

.camera-focus::before,
.camera-focus::after {
    content: '';
    position: absolute;
    background: rgba(255, 200, 0, 0.6);
}

.camera-focus::before {
    top: 50%;
    left: -20px;
    width: 15px;
    height: 2px;
}

.camera-focus::after {
    top: -20px;
    left: 50%;
    width: 2px;
    height: 15px;
}

@keyframes focusPulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.6;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.1);
        opacity: 1;
    }
}

/* Output Cards (Glassmorphism Grid) */
.output-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.output-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 2rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    height: 100%;
}

.output-card:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-5px);
    border-color: rgba(255, 200, 0, 0.3);
    /* Yellow/Gold Accent for Photogrammetry */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.output-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 200, 0, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: #ffc800;
}

.output-title {
    font-size: 1.25rem;
    color: white;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.output-desc {
    color: var(--color-gray-400);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* Tech Specs Section (Dark) */
.specs-section {
    background: #0b0d11;
    /* Very dark bg */
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: white;
}

.specs-img-wrapper {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    height: 100%;
    min-height: 400px;
}

.specs-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}


/* Badge Accent */
.badge-accent-yellow {
    border-color: #ffc800 !important;
    color: #ffc800 !important;
    margin-bottom: 1rem;
    display: inline-flex;
    background: rgba(255, 200, 0, 0.1);
}

/* =========================================
   SERVICES MOBILE RESPONSIVENESS (Non-Destructive)
   ========================================= */
@media (max-width: 768px) {

    /* Hero */
    .service-hero h1 {
        font-size: 2.25rem !important;
    }

    .service-hero p {
        font-size: 1rem !important;
        padding: 0 1rem !important;
    }

    .scene-3d {
        min-height: 50vh !important;
    }

    /* Sub Sections */
    .service-section {
        padding: 4rem 1rem !important;
    }

    .section-title-center {
        font-size: 2rem !important;
    }

    /* Tech Specs Formatted slightly smaller */
    .tech-spec-item {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 0.5rem !important;
    }

    .spec-value {
        text-align: left !important;
        font-size: 0.9rem !important;
    }

    /* Grids */
    .output-grid {
        grid-template-columns: 1fr !important;
    }

    .specs-img-wrapper {
        min-height: 250px !important;
        margin-bottom: 2rem !important;
    }
}