.engineering-page {
    color: #d9d9d9;
    background: #222;
    overflow: hidden;
}

.engineering-shell {
    width: min(1170px, calc(100% - 32px));
    margin: 0 auto;
}

.engineering-hero {
    min-height: 498px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background-image: url('../img/specialization/engineering_automation/automation-hero.webp');
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.engineering-hero__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .58);
}

.engineering-hero__content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 112px;
    padding-bottom: 48px;
    text-align: center;
    box-sizing: border-box;
}

.engineering-eyebrow,
.engineering-kicker {
    margin: 0 0 12px;
    color: #8b89ff;
    font-family: "Medium";
    font-size: 11px;
    line-height: 16px;
    letter-spacing: 1.5px;
}

.engineering-hero h1 {
    max-width: 760px;
    margin: 0;
    color: #d9d9d9;
    font-family: "Medium";
    font-size: 24px;
    font-weight: 400;
    line-height: 34px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.engineering-hero__lead {
    max-width: 790px;
    margin: 18px 0 0;
    color: #d9d9d9;
    font-family: "Light";
    font-size: 15px;
    line-height: 23px;
    letter-spacing: .6px;
}

.engineering-primary-button {
    min-width: 176px;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 22px;
    padding: 0 20px;
    border-radius: 2px;
    color: #fff;
    background: linear-gradient(45deg, #5e5be6 0%, #4e4cbf 65%);
    font-family: "Light";
    font-size: 12px;
    line-height: 18px;
    letter-spacing: .9px;
    text-decoration: none;
    text-transform: uppercase;
    box-sizing: border-box;
    transition: transform .2s ease, filter .2s ease;
}

.engineering-primary-button:hover,
.engineering-primary-button:focus-visible {
    transform: translateY(-2px);
    filter: brightness(1.08);
    outline: none;
}

.engineering-section {
    padding: 92px 0;
}

.engineering-services,
.engineering-equipment {
    background: #222;
}

.engineering-section__heading {
    max-width: 820px;
    margin-bottom: 42px;
}

.engineering-section__heading h2,
.engineering-cta h2 {
    margin: 0;
    color: #f4f4f4;
    font-family: "Regular";
    font-size: clamp(30px, 3.3vw, 44px);
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: .2px;
}

.engineering-section__heading > p:last-child {
    margin: 20px 0 0;
    color: #bdbdbd;
    font-family: "Light";
    font-size: 17px;
    line-height: 27px;
    letter-spacing: .35px;
}

.engineering-service-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

.engineering-service-card {
    min-height: 292px;
    padding: 26px 24px;
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 4px;
    background: linear-gradient(180deg, #2a2a2a 0%, #252525 100%);
    box-sizing: border-box;
    transition: transform .2s ease, border-color .2s ease;
}

.engineering-service-card:hover {
    transform: translateY(-4px);
    border-color: rgba(94, 91, 230, .66);
}

.engineering-icon {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 22px;
    border-radius: 10px;
    color: #8b89ff;
    background: rgba(94, 91, 230, .12);
}

.engineering-icon svg {
    width: 30px;
    height: 30px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.engineering-service-card h3,
.engineering-equipment-card h3,
.engineering-process-list h3 {
    margin: 0;
    color: #f0f0f0;
    font-family: "Medium";
    font-size: 18px;
    font-weight: 400;
    line-height: 24px;
    letter-spacing: .3px;
}

.engineering-service-card p,
.engineering-process-list p {
    margin: 14px 0 0;
    color: #bdbdbd;
    font-family: "Light";
    font-size: 15px;
    line-height: 23px;
    letter-spacing: .25px;
}

.engineering-process {
    background: linear-gradient(135deg, #242440 0%, #29293f 48%, #232323 100%);
}

.engineering-process-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0;
    margin: 0;
    padding: 0;
    border-top: 1px solid rgba(255,255,255,.14);
}

.engineering-process-list li {
    position: relative;
    min-height: 260px;
    padding: 28px 22px 22px;
    border-right: 1px solid rgba(255,255,255,.12);
    box-sizing: border-box;
}

.engineering-process-list li:last-child {
    border-right: 0;
}

.engineering-process-list li > span {
    display: block;
    margin-bottom: 38px;
    color: #8b89ff;
    font-family: "Heavy";
    font-size: 34px;
    line-height: 1;
    letter-spacing: 1px;
}

.engineering-equipment-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.engineering-equipment-card {
    padding: 30px 30px 28px;
    border-left: 3px solid #5e5be6;
    background: #292929;
    box-sizing: border-box;
}

.engineering-equipment-card ul {
    margin: 20px 0 0;
    padding: 0;
    list-style: none;
}

.engineering-equipment-card li {
    position: relative;
    margin-top: 11px;
    padding-left: 20px;
    color: #c7c7c7;
    font-family: "Light";
    font-size: 15px;
    line-height: 23px;
    letter-spacing: .25px;
}

.engineering-equipment-card li::before {
    content: '';
    width: 6px;
    height: 6px;
    position: absolute;
    left: 0;
    top: 9px;
    border-radius: 50%;
    background: #6e6bea;
}

.engineering-brands {
    margin-top: 36px;
    padding: 24px 26px;
    border: 1px solid rgba(255,255,255,.08);
    background: #252525;
}

.engineering-brands > p {
    margin: 0 0 16px;
    color: #d9d9d9;
    font-family: "Medium";
    font-size: 16px;
    line-height: 22px;
}

.engineering-brand-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.engineering-brand-list span {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 15px;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
    color: #e2e2e2;
    background: rgba(255,255,255,.035);
    font-family: "Light";
    font-size: 14px;
    letter-spacing: .4px;
}

.engineering-cta {
    padding: 66px 0;
    background: #191919;
}

.engineering-cta__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 42px;
}

.engineering-cta__inner > div {
    max-width: 780px;
}

.engineering-cta .engineering-primary-button {
    flex: 0 0 auto;
    margin-top: 0;
}

@media (max-width: 1050px) {
    .engineering-service-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .engineering-process-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1px;
        background: rgba(255,255,255,.1);
        border: 0;
    }

    .engineering-process-list li {
        min-height: 230px;
        border: 0;
        background: #29293b;
    }

    .engineering-process-list li:last-child {
        grid-column: 1 / -1;
        min-height: auto;
    }
}

@media (max-width: 700px) {
    .engineering-shell {
        width: min(100% - 32px, 1170px);
    }

    .engineering-hero {
        min-height: 520px;
        background-position: 62% center;
        background-attachment: scroll;
    }

    .engineering-hero__overlay {
        background: rgba(0, 0, 0, .64);
    }

    .engineering-hero__content {
        padding-top: 96px;
        padding-bottom: 42px;
    }

    .engineering-hero h1 {
        max-width: 560px;
        font-size: 21px;
        line-height: 30px;
    }

    .engineering-hero__lead {
        max-width: 560px;
        margin-top: 16px;
        font-size: 14px;
        line-height: 22px;
    }

    .engineering-primary-button {
        min-width: 164px;
        min-height: 40px;
        margin-top: 20px;
        padding: 0 18px;
        font-size: 11px;
    }

    .engineering-section {
        padding: 68px 0;
    }

    .engineering-service-grid,
    .engineering-equipment-grid,
    .engineering-process-list {
        grid-template-columns: 1fr;
    }

    .engineering-service-card {
        min-height: 0;
    }

    .engineering-process-list li,
    .engineering-process-list li:last-child {
        min-height: 0;
        grid-column: auto;
    }

    .engineering-process-list li > span {
        margin-bottom: 22px;
    }

    .engineering-equipment-card {
        padding: 26px 22px 24px;
    }

    .engineering-cta__inner {
        align-items: flex-start;
        flex-direction: column;
    }

    .engineering-cta .engineering-primary-button {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .engineering-service-card,
    .engineering-primary-button {
        transition: none;
    }
}


/* Interactive power-flow illustration */
.power-demo-section {
    padding: 38px 0 14px;
    background: #222;
}

.power-demo {
    width: min(1170px, 100%);
    height: 232px;
    position: relative;
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .09);
    border-radius: 5px;
    background:
        radial-gradient(circle at 86% 52%, rgba(94, 91, 230, .11), transparent 23%),
        linear-gradient(135deg, #28282d 0%, #202126 55%, #191a1e 100%);
    box-shadow: 0 18px 42px rgba(0, 0, 0, .22);
    box-sizing: border-box;
    isolation: isolate;
}

.power-demo::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: .28;
    background-image:
        linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
    background-size: 32px 32px;
    mask-image: linear-gradient(to right, rgba(0,0,0,.8), transparent 78%);
}

.power-demo__copy {
    position: absolute;
    z-index: 8;
    top: 20px;
    left: 24px;
    max-width: 310px;
    pointer-events: none;
}

.power-demo__eyebrow {
    margin: 0 0 5px;
    color: #8b89ff;
    font-family: "Medium";
    font-size: 9px;
    line-height: 13px;
    letter-spacing: 1.35px;
}

.power-demo__copy h2 {
    margin: 0;
    color: #f2f2f2;
    font-family: "Regular";
    font-size: 20px;
    font-weight: 400;
    line-height: 26px;
    letter-spacing: .35px;
    text-transform: uppercase;
}

.power-demo__status {
    position: absolute;
    z-index: 8;
    top: 22px;
    right: 23px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 27px;
    padding: 0 11px;
    border: 1px solid rgba(255,255,255,.09);
    border-radius: 14px;
    color: #9ea0a8;
    background: rgba(13,14,17,.55);
    font-family: "Medium";
    font-size: 9px;
    line-height: 13px;
    letter-spacing: 1px;
    transition: color .28s ease, border-color .28s ease, background .28s ease;
}

.power-demo__status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #686a71;
    box-shadow: 0 0 0 3px rgba(104,106,113,.12);
    transition: background .28s ease, box-shadow .28s ease;
}

.power-demo__scene,
.power-demo__wires,
.power-demo__plant,
.power-demo__tower,
.power-demo__bulb,
.power-demo__toggle {
    position: absolute;
}

.power-demo__scene {
    inset: 0;
}

.power-demo__scene::after {
    content: '';
    position: absolute;
    z-index: 1;
    left: 0;
    right: 0;
    bottom: 17px;
    height: 1px;
    background: linear-gradient(90deg, transparent 2%, rgba(255,255,255,.12) 12%, rgba(255,255,255,.12) 88%, transparent 98%);
}

.power-demo__plant {
    z-index: 3;
    left: 2.2%;
    bottom: 16px;
    width: 28%;
    max-height: 158px;
    overflow: visible;
}

.power-demo__chimney { fill: #33343a; stroke: #55575f; stroke-width: 2; }
.power-demo__roof { fill: #303137; stroke: #5e5be6; stroke-width: 2; }
.power-demo__building { stroke: #44464e; stroke-width: 2; }
.power-demo__window { fill: #4b4c53; transition: fill .3s ease, filter .3s ease; }
.power-demo__door { fill: #17181c; stroke: #50525a; stroke-width: 2; }
.power-demo__generator-ring { fill: #1c1d21; stroke: #60626d; stroke-width: 4; transition: stroke .3s ease; }
.power-demo__rotor { fill: #666873; transform-box: view-box; transform-origin: 218px 92px; animation: power-demo-rotor 6s linear infinite; transition: fill .3s ease; }
.power-demo__rotor-core { fill: #202126; stroke: #858792; stroke-width: 2; }
.power-demo__ground-line { fill: none; stroke: #4e5058; stroke-width: 3; stroke-linecap: round; }
.power-demo__plant-bolt { fill: #5e5be6; opacity: .38; transition: opacity .3s ease, filter .3s ease; }
.power-demo__smoke { fill: #777982; opacity: .13; transform-box: view-box; animation: power-demo-smoke 3.8s ease-in-out infinite; }
.power-demo__smoke--two { animation-delay: -1.7s; }

.power-demo__wires {
    z-index: 2;
    left: 24%;
    right: 11%;
    top: 87px;
    width: 65%;
    height: 64px;
    overflow: visible;
}

.power-demo__wire-base {
    fill: none;
    stroke: #63656d;
    stroke-width: 5;
    vector-effect: non-scaling-stroke;
}

.power-demo__wire-base--lower { opacity: .52; }

.power-demo__current {
    fill: none;
    stroke: #f5cf52;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-dasharray: 12 24;
    vector-effect: non-scaling-stroke;
    opacity: 0;
    filter: drop-shadow(0 0 5px rgba(245, 207, 82, .9));
    animation: power-demo-current .82s linear infinite;
    transition: opacity .25s ease;
}

.power-demo__current--lower { animation-delay: -.4s; }

.power-demo__tower {
    z-index: 4;
    bottom: 17px;
    width: 8.2%;
    max-height: 148px;
    fill: none;
    stroke: #777983;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: drop-shadow(0 5px 4px rgba(0,0,0,.2));
}

.power-demo__tower--one { left: 35%; }
.power-demo__tower--two { left: 52%; transform: scale(.82); transform-origin: bottom center; opacity: .72; }

.power-demo__bulb {
    z-index: 5;
    right: 1.7%;
    bottom: 22px;
    width: 12.5%;
    max-height: 154px;
    overflow: visible;
}

.power-demo__bulb-rays {
    fill: none;
    stroke: #f5cf52;
    stroke-width: 4;
    stroke-linecap: round;
    opacity: 0;
    transform-box: view-box;
    transform-origin: 60px 66px;
    transition: opacity .28s ease;
    animation: none;
}

.power-demo__bulb-glow {
    fill: #f5cf52;
    opacity: 0;
    filter: blur(13px);
    transition: opacity .32s ease;
}

.power-demo__bulb-glass {
    fill: #28292f;
    stroke: #787a84;
    stroke-width: 4;
    transition: fill .3s ease, stroke .3s ease, filter .3s ease;
}

.power-demo__filament,
.power-demo__bulb-base {
    fill: none;
    stroke: #747680;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: stroke .3s ease, filter .3s ease;
}

.power-demo__toggle {
    z-index: 7;
    right: 14.3%;
    bottom: 24px;
    width: 12.5%;
    height: 150px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 12px;
    color: inherit;
    background: transparent;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.power-demo__toggle svg {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.power-demo__toggle::after {
    content: '';
    position: absolute;
    inset: 9px 10px;
    border: 1px solid transparent;
    border-radius: 12px;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.power-demo__toggle:hover::after,
.power-demo__toggle:focus-visible::after {
    border-color: rgba(139,137,255,.72);
    box-shadow: 0 0 0 4px rgba(94,91,230,.12);
}

.power-demo__toggle:focus-visible { outline: none; }
.power-demo__switch-plate { fill: #24252a; stroke: #565862; stroke-width: 3; }
.power-demo__switch-contact { fill: #17181c; stroke: #7b7d87; stroke-width: 3; }
.power-demo__switch-bridge { fill: none; stroke: #3b3c43; stroke-width: 5; stroke-linecap: round; }
.power-demo__lever { transform-box: view-box; transform-origin: 38px 105px; transform: rotate(-35deg); transition: transform .38s cubic-bezier(.22,.88,.36,1.2); }
.power-demo__lever-hub { fill: #4e4f57; stroke: #aaaab2; stroke-width: 2; }
.power-demo__lever-arm { fill: none; stroke: #c5c6cc; stroke-width: 7; stroke-linecap: round; }
.power-demo__lever-handle { fill: #5e5be6; stroke: #9b99ff; stroke-width: 3; filter: drop-shadow(0 3px 4px rgba(0,0,0,.35)); }
.power-demo__switch-led { fill: #53545b; transition: fill .3s ease, filter .3s ease; }
.power-demo__switch-led-rays { fill: none; stroke: #f5cf52; stroke-width: 3; stroke-linecap: round; opacity: 0; transition: opacity .3s ease; }

.power-demo.is-on .power-demo__status {
    color: #f7dc75;
    border-color: rgba(245,207,82,.26);
    background: rgba(50,43,18,.46);
}

.power-demo.is-on .power-demo__status-dot {
    background: #f5cf52;
    box-shadow: 0 0 0 3px rgba(245,207,82,.14), 0 0 13px rgba(245,207,82,.82);
}

.power-demo.is-on .power-demo__current { opacity: 1; }
.power-demo.is-on .power-demo__lever { transform: rotate(0deg); }
.power-demo.is-on .power-demo__switch-led { fill: #f5cf52; filter: drop-shadow(0 0 7px rgba(245,207,82,.95)); }
.power-demo.is-on .power-demo__switch-led-rays { opacity: .82; }
.power-demo.is-on .power-demo__bulb-rays { opacity: .9; animation: power-demo-rays 1.8s ease-in-out infinite; }
.power-demo.is-on .power-demo__bulb-glow { opacity: .4; }
.power-demo.is-on .power-demo__bulb-glass { fill: #f3cf56; stroke: #ffeaa0; filter: drop-shadow(0 0 14px rgba(245,207,82,.82)); }
.power-demo.is-on .power-demo__filament { stroke: #fff4c3; filter: drop-shadow(0 0 3px #fff); }
.power-demo.is-on .power-demo__bulb-base { stroke: #b4b5bd; }
.power-demo.is-on .power-demo__window { fill: #e3bd48; filter: drop-shadow(0 0 5px rgba(227,189,72,.52)); }
.power-demo.is-on .power-demo__generator-ring { stroke: #8b89ff; }
.power-demo.is-on .power-demo__rotor { fill: #8b89ff; animation-duration: 1.15s; }
.power-demo.is-on .power-demo__plant-bolt { opacity: 1; filter: drop-shadow(0 0 5px rgba(94,91,230,.9)); animation: power-demo-bolt 1.2s ease-in-out infinite; }
.power-demo.is-on .power-demo__smoke { opacity: .24; animation-duration: 2.7s; }

@keyframes power-demo-current {
    to { stroke-dashoffset: -36; }
}

@keyframes power-demo-rotor {
    to { transform: rotate(360deg); }
}

@keyframes power-demo-smoke {
    0%, 100% { transform: translateY(4px) scale(.92); opacity: .08; }
    50% { transform: translateY(-5px) scale(1.05); opacity: .2; }
}

@keyframes power-demo-rays {
    0%, 100% { transform: scale(.94); opacity: .55; }
    50% { transform: scale(1.04); opacity: 1; }
}

@keyframes power-demo-bolt {
    0%, 100% { opacity: .62; }
    50% { opacity: 1; }
}

@media (max-width: 700px) {
    .power-demo-section { padding: 28px 0 4px; }
    .power-demo { height: 218px; }
    .power-demo__copy { top: 16px; left: 17px; max-width: 205px; }
    .power-demo__eyebrow { font-size: 8px; letter-spacing: 1px; }
    .power-demo__copy h2 { font-size: 15px; line-height: 20px; }
    .power-demo__status { top: auto; right: 14px; bottom: 10px; min-height: 23px; padding: 0 8px; font-size: 8px; }
    .power-demo__plant { left: -1%; bottom: 20px; width: 31%; }
    .power-demo__wires { left: 25%; right: 9%; top: 92px; width: 66%; height: 54px; }
    .power-demo__tower { width: 9.5%; bottom: 25px; }
    .power-demo__tower--one { left: 34%; }
    .power-demo__tower--two { left: 51%; }
    .power-demo__toggle { right: 13%; bottom: 31px; width: 14.5%; height: 132px; }
    .power-demo__bulb { right: .5%; bottom: 31px; width: 14%; }
}

@media (max-width: 430px) {
    .power-demo { height: 204px; }
    .power-demo__copy { max-width: 175px; }
    .power-demo__copy h2 { font-size: 13px; line-height: 18px; }
    .power-demo__plant { width: 34%; bottom: 23px; }
    .power-demo__tower--two { display: none; }
    .power-demo__tower--one { left: 40%; width: 10.5%; }
    .power-demo__wires { left: 27%; top: 89px; width: 64%; }
    .power-demo__toggle { right: 14%; width: 16%; height: 122px; bottom: 36px; }
    .power-demo__bulb { right: 0; width: 15.5%; bottom: 39px; }
}

@media (prefers-reduced-motion: reduce) {
    .power-demo__rotor,
    .power-demo__smoke,
    .power-demo__current,
    .power-demo__bulb-rays,
    .power-demo__plant-bolt {
        animation: none !important;
    }
}
