/**
 * Capnis Reusable Service Hero & Breadcrumb Styles
 * Matches the About page reference hero design (monochrome obsidian dark, atmospheric glow, high-contrast typography)
 */

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .tp-header-menu > nav > ul > li > a,
body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .tp-main-menu-mobile > nav > ul > li > a {
    color: #ffffff !important;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.45);
}

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .tp-header-dropdown nav ul li.has-dropdown::after,
body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .tp-header-menu ul li.has-dropdown > a::after,
body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .tp-header-menu ul li.menu-item-has-children > a::after {
    color: #ffffff !important;
}

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .capnis-theme-toggle {
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
    background: rgba(255, 255, 255, 0.08) !important;
}

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .logo-white {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .logo-black {
    display: none !important;
}

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky).tp-header-border {
    border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
}

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .tp-btn-black .tp-btn-black-text {
    color: #ffffff !important;
}

body:has(.capnis-service-hero) #header-sticky:not(.header-sticky) .tp-btn-black .tp-btn-black-circle {
    background-color: rgba(255, 255, 255, 0.18) !important;
    color: #ffffff !important;
}

/* ── Obsidian Black Interactive Service Hero (Inspired by About Page Reference) ────────── */
.capnis-service-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding-top: clamp(140px, 13vw, 195px);
    padding-bottom: clamp(80px, 8vw, 130px);
    background-color: #000000;
    color: #ffffff;
    min-height: 640px;
    display: flex;
    align-items: center;
    border-bottom-left-radius: clamp(28px, 4vw, 54px);
    border-bottom-right-radius: clamp(28px, 4vw, 54px);
}

.capnis-service-hero .container.container-1750 {
    position: relative;
    z-index: 10;
}

/* Background Layers */
.capnis-service-hero__bg-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.capnis-service-hero__bg-layer--base {
    z-index: 0;
    background:
        radial-gradient(circle at 85% 20%, #17171a 0%, transparent 45%),
        radial-gradient(circle at 15% 85%, #141416 0%, transparent 45%),
        linear-gradient(135deg, #000000 0%, #09090b 45%, #040405 100%);
}

.capnis-service-hero__bg-layer--gradient {
    z-index: 1;
    background:
        radial-gradient(ellipse 70% 60% at 75% 35%, rgba(30, 58, 138, 0.16) 0%, transparent 65%),
        radial-gradient(ellipse 60% 50% at 20% 65%, rgba(51, 65, 85, 0.25) 0%, transparent 60%),
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.015) 0%, transparent 70%);
}

.capnis-service-hero__bg-layer--glow {
    z-index: 2;
    background:
        radial-gradient(circle 420px at 78% 38%, rgba(59, 130, 246, 0.10), transparent 70%),
        radial-gradient(circle 500px at 15% 75%, rgba(148, 163, 184, 0.06), transparent 70%);
    filter: blur(50px);
}

/* Abstract Floating Shapes */
.capnis-service-hero .capnis-hero-shape {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    z-index: 2;
}

.capnis-service-hero .capnis-hero-shape--1 {
    width: 580px;
    height: 580px;
    right: -60px;
    top: 5%;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: radial-gradient(circle, rgba(255, 255, 255, 0.025) 0%, transparent 70%);
    animation: capnisOrbFloat 14s ease-in-out infinite alternate;
}

.capnis-service-hero .capnis-hero-shape--2 {
    width: 440px;
    height: 440px;
    left: -60px;
    bottom: -30px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    background: radial-gradient(circle, rgba(255, 255, 255, 0.018) 0%, transparent 70%);
    animation: capnisOrbFloat 18s ease-in-out infinite alternate-reverse;
}

@keyframes capnisOrbFloat {
    0% { transform: translateY(0) rotate(0deg); }
    100% { transform: translateY(-24px) rotate(8deg); }
}

/* Ambient Glass Orbs */
.capnis-service-hero .capnis-ambient-orb {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
}

.capnis-service-hero .capnis-ambient-orb--bottom-left {
    bottom: -80px;
    left: -80px;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle at 35% 35%, rgba(255, 255, 255, 0.32) 0%, rgba(100, 110, 130, 0.12) 45%, rgba(0, 0, 0, 0.9) 85%);
    box-shadow: inset -10px -10px 30px rgba(0, 0, 0, 0.95), 0 0 50px rgba(0, 0, 0, 0.9);
    opacity: 0.85;
}

.capnis-service-hero .capnis-ambient-orb--top-right {
    top: -60px;
    right: -60px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle at 35% 35%, rgba(255, 255, 255, 0.22) 0%, rgba(70, 80, 100, 0.08) 45%, rgba(0, 0, 0, 0.95) 85%);
    opacity: 0.7;
}

/* Breadcrumb */
.capnis-service-hero .capnis-ref-breadcrumb {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 14px;
    font-weight: 500;
}

.capnis-service-hero .capnis-ref-breadcrumb__link {
    color: #cbd5e1;
    text-decoration: none;
    transition: color 0.2s ease;
}

.capnis-service-hero .capnis-ref-breadcrumb__link:hover {
    color: #ffffff;
}

.capnis-service-hero .capnis-ref-breadcrumb__dot {
    color: #ffffff;
    font-size: 16px;
    opacity: 0.85;
    user-select: none;
}

.capnis-service-hero .capnis-ref-breadcrumb__current {
    color: #ffffff;
    font-weight: 600;
}

/* Eyebrow badge / bar */
.capnis-service-hero .capnis-ref-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 14px;
}

.capnis-service-hero .capnis-ref-eyebrow__bar {
    display: inline-block;
    width: 34px;
    height: 3px;
    background: #ffffff;
    border-radius: 99px;
}

.capnis-service-hero .capnis-ref-eyebrow__text {
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.25em;
    text-transform: uppercase;
}

/* Main Title */
.capnis-service-hero .capnis-ref-title {
    font-size: clamp(2.4rem, 4.8vw, 4.5rem);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.03em;
    color: #ffffff !important;
    text-transform: uppercase;
    text-shadow: 0 10px 40px rgba(0, 0, 0, 0.7);
    word-break: break-word;
    overflow-wrap: break-word;
}

/* Description / Lead */
.capnis-service-hero .capnis-ref-desc {
    color: rgba(235, 240, 248, 0.88);
    font-size: clamp(15px, 1.15vw, 18px);
    line-height: 1.65;
    max-width: 560px;
    font-weight: 400;
    margin-bottom: 0;
}

/* Actions */
.capnis-service-hero .capnis-ref-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.capnis-service-hero .capnis-ref-btn {
    display: inline-flex;
    align-items: center;
    gap: 16px;
    padding: 10px 12px 10px 28px;
    background: #ffffff;
    color: #000000 !important;
    border-radius: 9999px;
    text-decoration: none;
    font-size: 16px;
    font-weight: 700;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 10px 35px rgba(255, 255, 255, 0.18), 0 5px 15px rgba(0, 0, 0, 0.5);
}

.capnis-service-hero .capnis-ref-btn:hover {
    transform: translateY(-2px) scale(1.02);
    background: #f4f4f5;
    color: #000000 !important;
    box-shadow: 0 16px 45px rgba(255, 255, 255, 0.3), 0 8px 25px rgba(0, 0, 0, 0.6);
}

.capnis-service-hero .capnis-ref-btn__icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #000000;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.35s ease;
}

.capnis-service-hero .capnis-ref-btn:hover .capnis-ref-btn__icon {
    transform: rotate(45deg);
}

/* Right Stage: 3D Stage, Orbits, Badges, Showcase Frame */
.capnis-service-hero .capnis-ref-hero-stage {
    position: relative;
    perspective: 1400px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 480px;
    width: 100%;
    padding: 30px 0;
}

.capnis-service-hero .capnis-ref-orbit-svg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 125%;
    height: 125%;
    max-width: 820px;
    pointer-events: none;
    z-index: 2;
    opacity: 0.9;
}

.capnis-service-hero .capnis-ref-node {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 0 10px #ffffff, 0 0 20px rgba(255, 255, 255, 0.8);
    z-index: 3;
    pointer-events: none;
}

.capnis-service-hero .capnis-ref-node--1 { top: 14%; left: 34%; animation: capnisRefPulse 3s ease-in-out infinite; }
.capnis-service-hero .capnis-ref-node--2 { top: 48%; left: 4%; animation: capnisRefPulse 3.5s ease-in-out infinite 0.8s; }
.capnis-service-hero .capnis-ref-node--3 { bottom: 23%; left: 18%; animation: capnisRefPulse 4s ease-in-out infinite 1.5s; }
.capnis-service-hero .capnis-ref-node--4 { bottom: 12%; right: 20%; animation: capnisRefPulse 3.2s ease-in-out infinite 0.4s; }

@keyframes capnisRefPulse {
    0%, 100% { opacity: 0.6; transform: scale(0.9); }
    50% { opacity: 1; transform: scale(1.3); }
}

.capnis-service-hero .capnis-ref-orb-badge {
    position: absolute;
    z-index: 10;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.capnis-service-hero .capnis-ref-orb-badge--send {
    top: 5%;
    right: 2%;
    width: 54px;
    height: 54px;
    background: rgba(35, 38, 48, 0.7);
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.6), 0 0 20px rgba(255, 255, 255, 0.2);
    animation: capnisRefSendFloat 5s ease-in-out infinite alternate;
}

@keyframes capnisRefSendFloat {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-6px, -8px, 0); }
}

.capnis-service-hero .capnis-ref-orb-badge--chart {
    top: 50%;
    left: -2%;
    width: 44px;
    height: 44px;
    background: rgba(24, 26, 34, 0.7);
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5), 0 0 15px rgba(255, 255, 255, 0.15);
    animation: capnisRefChartFloat 5.5s ease-in-out infinite alternate-reverse;
}

@keyframes capnisRefChartFloat {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-5px, 8px, 0); }
}

.capnis-service-hero .capnis-ref-card-container {
    position: relative;
    z-index: 5;
    width: 100%;
    max-width: 520px;
    animation: capnisRefCardFloat 7s ease-in-out infinite alternate;
}

@keyframes capnisRefCardFloat {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(0, -8px, 0); }
}

.capnis-service-hero .capnis-ref-card-frame {
    position: relative;
    border-radius: 28px;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.45);
    box-shadow: 
        0 30px 80px rgba(0, 0, 0, 0.95),
        0 0 45px rgba(255, 255, 255, 0.12),
        inset 0 0 30px rgba(255, 255, 255, 0.1);
    transform: rotate(-1.5deg);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease;
    background: #0c0d11;
}

.capnis-service-hero .capnis-ref-card-container:hover .capnis-ref-card-frame {
    transform: rotate(0deg) scale(1.02);
    box-shadow: 
        0 40px 100px rgba(0, 0, 1),
        0 0 60px rgba(255, 255, 255, 0.2),
        inset 0 0 35px rgba(255, 255, 255, 0.2);
}

.capnis-service-hero .capnis-ref-card-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    aspect-ratio: 4/3;
    transform: scale(1.02);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.capnis-service-hero .capnis-ref-card-container:hover .capnis-ref-card-img {
    transform: scale(1.05);
}

.capnis-service-hero .capnis-ref-card-glare {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0) 50%);
    mix-blend-mode: overlay;
}

/* Floating Glass Badges */
.capnis-service-hero .capnis-ref-badge {
    position: absolute;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 14px;
    pointer-events: auto;
    cursor: default;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.capnis-service-hero .capnis-ref-badge--expert {
    top: 5px;
    left: -35px;
    background: rgba(22, 24, 30, 0.88);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 18px;
    padding: 13px 20px;
    min-width: 260px;
    max-width: 290px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.8), 0 0 25px rgba(255, 255, 255, 0.08);
    animation: capnisRefBadge1Float 6s ease-in-out infinite alternate;
}

@keyframes capnisRefBadge1Float {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-6px, -8px, 0); }
}

.capnis-service-hero .capnis-ref-badge--solutions {
    bottom: -15px;
    right: -25px;
    background: rgba(22, 24, 30, 0.88);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 18px;
    padding: 13px 20px;
    min-width: 260px;
    max-width: 300px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.8), 0 0 25px rgba(255, 255, 255, 0.08);
    animation: capnisRefBadge2Float 6.5s ease-in-out infinite alternate-reverse;
}

@keyframes capnisRefBadge2Float {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(6px, 8px, 0); }
}

.capnis-service-hero .capnis-ref-badge--linkable {
    cursor: pointer;
    text-decoration: none;
}

.capnis-service-hero .capnis-ref-badge--linkable:hover {
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 24px 55px rgba(0, 0, 0, 0.9), 0 0 35px rgba(255, 255, 255, 0.18);
}

.capnis-service-hero .capnis-ref-badge__link-inner {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: inherit;
    width: 100%;
}

.capnis-service-hero .capnis-ref-badge__icon {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
}

.capnis-service-hero .capnis-ref-badge__content {
    display: flex;
    flex-direction: column;
}

.capnis-service-hero .capnis-ref-badge__title {
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 2px;
    line-height: 1.2;
}

.capnis-service-hero .capnis-ref-badge__sub {
    color: rgba(255, 255, 255, 0.68);
    font-size: 11px;
    font-weight: 500;
    margin-bottom: 0;
    line-height: 1.3;
}

/* Responsive adjustments */
@media (max-width: 1199px) {
    .capnis-service-hero {
        padding-top: 140px;
        min-height: auto;
    }
    .capnis-service-hero .capnis-ref-title {
        font-size: clamp(2rem, 4.5vw, 3.5rem);
    }
    .capnis-service-hero .capnis-ref-hero-stage {
        min-height: 420px;
        margin-top: 40px;
    }
    .capnis-service-hero .capnis-ref-badge--expert {
        left: 0;
    }
    .capnis-service-hero .capnis-ref-badge--solutions {
        right: 0;
    }
}

@media (max-width: 767px) {
    .capnis-service-hero {
        padding-top: 120px;
        padding-bottom: 60px;
    }
    .capnis-service-hero .capnis-ref-title {
        font-size: clamp(1.8rem, 6.5vw, 2.6rem);
        line-height: 1.1;
    }
    .capnis-service-hero .capnis-ref-breadcrumb {
        font-size: 12px;
        gap: 6px;
    }
    .capnis-service-hero .capnis-ref-eyebrow {
        gap: 10px;
    }
    .capnis-service-hero .capnis-ref-eyebrow__bar {
        width: 24px;
    }
    .capnis-service-hero .capnis-ref-eyebrow__text {
        font-size: 12px;
    }
    .capnis-service-hero .capnis-ref-hero-stage {
        min-height: 340px;
        padding: 20px 0;
    }
    .capnis-service-hero .capnis-ref-badge {
        position: relative;
        top: auto;
        left: auto;
        right: auto;
        bottom: auto;
        margin-top: 15px;
        min-width: 100%;
        max-width: 100%;
        animation: none;
    }
    .capnis-service-hero .capnis-ref-card-container {
        animation: none;
    }
}
