/* Gemeinsame SVG-Icons und weiche Übergänge für EXTERN-Buttons. */
:root { --extern-motion: 260ms cubic-bezier(.22, 1, .36, 1); }

body a.home-button, body a.services-button, body a.extern-button,
body a.history-end__button, body a.legio-button, body a.uvi-button,
body a.smoke-button, body a.locations-final-cta__button,
body a.location-detail__button, body a.extern-footer__contact-button,
body a.billing-final-cta__button, body a.meters-final-cta__button,
body a.energy-final-cta__button, body a.uvi-final-cta__button,
body a.smoke-final-cta__button, body a.legio-final-cta__button,
body a.extern-error__button, body .billing-hero__actions > a,
body .meters-hero__actions > a, body .energy-hero__actions > a,
body .smoke-hero__actions > a, body .legio-hero__actions > a,
body .uvi-hero__actions > a {
    transition: transform var(--extern-motion), background-color var(--extern-motion),
        color var(--extern-motion), border-color var(--extern-motion),
        box-shadow var(--extern-motion) !important;
}

body a.home-button > span[aria-hidden="true"],
body a.extern-button > span[aria-hidden="true"],
body a.history-end__button > span[aria-hidden="true"],
body a.legio-button > span[aria-hidden="true"],
body a.uvi-button > span[aria-hidden="true"],
body a.smoke-button > span[aria-hidden="true"],
body a.locations-final-cta__button > span[aria-hidden="true"],
body a.location-detail__button > span[aria-hidden="true"],
body a.extern-footer__contact-button > span[aria-hidden="true"],
body a.billing-final-cta__button > span[aria-hidden="true"],
body a.meters-final-cta__button > span[aria-hidden="true"],
body a.energy-final-cta__button > span[aria-hidden="true"],
body a.uvi-final-cta__button > span[aria-hidden="true"],
body a.smoke-final-cta__button > span[aria-hidden="true"],
body a.legio-final-cta__button > span[aria-hidden="true"],
body button.locations-button > span[aria-hidden="true"],
body .services-button--secondary > span {
    position: relative;
    display: inline-block;
    flex: 0 0 14px;
    width: 14px;
    height: 14px;
    overflow: hidden;
    font-size: 0 !important;
    line-height: 0 !important;
    transition: transform var(--extern-motion);
}

body a.home-button > span[aria-hidden="true"]::before,
body a.extern-button > span[aria-hidden="true"]::before,
body a.history-end__button > span[aria-hidden="true"]::before,
body a.legio-button > span[aria-hidden="true"]::before,
body a.uvi-button > span[aria-hidden="true"]::before,
body a.smoke-button > span[aria-hidden="true"]::before,
body a.locations-final-cta__button > span[aria-hidden="true"]::before,
body a.location-detail__button > span[aria-hidden="true"]::before,
body a.extern-footer__contact-button > span[aria-hidden="true"]::before,
body a.billing-final-cta__button > span[aria-hidden="true"]::before,
body a.meters-final-cta__button > span[aria-hidden="true"]::before,
body a.energy-final-cta__button > span[aria-hidden="true"]::before,
body a.uvi-final-cta__button > span[aria-hidden="true"]::before,
body a.smoke-final-cta__button > span[aria-hidden="true"]::before,
body a.legio-final-cta__button > span[aria-hidden="true"]::before,
body button.locations-button > span[aria-hidden="true"]::before,
body .services-button--secondary > span::before {
    content: "";
    position: absolute;
    inset: 0;
    display: block;
    background: currentColor;
    -webkit-mask: url("../images/icons/arrow-right.svg") center / contain no-repeat;
    mask: url("../images/icons/arrow-right.svg") center / contain no-repeat;
}

/* Der erste Leistungsbutton führt nach unten, der zweite nach rechts. */
body .services-button--primary > span {
    position: relative;
    display: inline-block;
    flex: 0 0 14px;
    width: 14px;
    height: 14px;
    overflow: hidden;
    font-size: 0 !important;
    line-height: 0 !important;
    transition: transform var(--extern-motion);
}
body .services-button--primary > span::before {
    content: "";
    position: absolute;
    inset: 0;
    background: currentColor;
    -webkit-mask: url("../images/icons/arrow-right.svg") center / contain no-repeat;
    mask: url("../images/icons/arrow-right.svg") center / contain no-repeat;
}

body .hero-cta-icon {
    display: inline-block !important;
    width: 14px !important;
    height: 14px !important;
    object-fit: contain;
    transition: transform var(--extern-motion);
}
body .billing-hero__actions > a,
body .meters-hero__actions > a,
body .energy-hero__actions > a,
body .smoke-hero__actions > a,
body .legio-hero__actions > a,
body .uvi-hero__actions > a {
    transition: transform var(--extern-motion), box-shadow var(--extern-motion), background-color var(--extern-motion), color var(--extern-motion);
}
body .billing-hero__actions > a:hover .hero-cta-icon,
body .meters-hero__actions > a:hover .hero-cta-icon,
body .energy-hero__actions > a:hover .hero-cta-icon,
body .smoke-hero__actions > a:hover .hero-cta-icon,
body .legio-hero__actions > a:hover .hero-cta-icon,
body .uvi-hero__actions > a:hover .hero-cta-icon { transform: translateX(3px); }

/* Slider controls and card links use the theme SVGs, not CSS-drawn triangles. */
body .home-service-card__arrow,
body .location-card__arrow,
body #services-prev,
body #services-next,
body .locations-carousel__arrow {
    font-size: 0 !important;
    line-height: 0 !important;
}
body .home-service-card__arrow::before,
body .location-card__arrow::before,
body #services-prev::before,
body #services-next::before,
body .locations-carousel__arrow::before {
    content: "";
    display: block;
    width: 16px;
    height: 16px;
    background: currentColor;
    -webkit-mask: url("../images/icons/arrow-right.svg") center / contain no-repeat;
    mask: url("../images/icons/arrow-right.svg") center / contain no-repeat;
    transition: transform var(--extern-motion);
}
body #services-prev::before,
body .locations-carousel__arrow--left::before { transform: rotate(180deg); }
body .home-service-card:hover .home-service-card__arrow::before,
body .location-card:hover .location-card__arrow::before,
body a.home-button:hover > span::before,
body a.extern-button:hover > span::before,
body a.history-end__button:hover > span::before,
body a.legio-button:hover > span::before,
body a.uvi-button:hover > span::before,
body a.smoke-button:hover > span::before,
body a.locations-final-cta__button:hover > span::before,
body a.location-detail__button:hover > span::before,
body a.extern-footer__contact-button:hover > span::before,
body a.billing-final-cta__button:hover > span::before,
body a.meters-final-cta__button:hover > span::before,
body a.energy-final-cta__button:hover > span::before,
body a.uvi-final-cta__button:hover > span::before,
body a.smoke-final-cta__button:hover > span::before,
body a.legio-final-cta__button:hover > span::before,
body button.locations-button:hover > span::before,
body .services-button--secondary:hover > span::before { transform: translateX(3px); }
body .services-button--primary:hover > span::before { transform: translateY(3px); }
body .locations-carousel__arrow:hover::before,
body #services-prev:hover::before,
body #services-next:hover::before { transform: translateX(2px); }
body .locations-carousel__arrow--left:hover::before,
body #services-prev:hover::before { transform: rotate(180deg) translateX(2px); }

/* Wohn-CTA wie die roten Anfrage-Buttons; auf der rechten Textkante ausrichten. */
body .locations-final-cta__button {
    align-self: flex-end;
    min-height: 50px !important;
    margin: 24px 0 0 auto !important;
    padding: 0 24px !important;
    gap: 16px !important;
    border: 1px solid var(--color-primary) !important;
    border-radius: 999px !important;
    background: var(--color-primary) !important;
    color: var(--palette-paper) !important;
    font-family: "Inter", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    transition: transform var(--extern-motion), box-shadow var(--extern-motion), background-color var(--extern-motion) !important;
}
body .locations-final-cta__button:hover {
    transform: translateY(-2px);
    background: var(--palette-ink) !important;
    border-color: var(--palette-ink) !important;
    box-shadow: 0 10px 26px var(--palette-value-d7d8a6c85b);
}
@media (max-width: 760px) {
    body .locations-final-cta__button { width: fit-content !important; max-width: 100%; }
}

/* Fußnotenpfeil: das vorhandene arrow-up.svg wird in footer.css gemaskt. */
body .extern-footer__backtop-circle { font-size: 0 !important; line-height: 0 !important; }

/* Footer-Links sitzen über der fixierten App-Leiste. */
body .extern-footer__bottom {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(0, 760px);
    align-items: start;
    gap: 18px 32px;
    padding-bottom: 88px;
}
body .extern-footer__copyright { justify-self: start; }
body .extern-footer__legal {
    width: min(100%, 760px);
    justify-self: end;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px 24px;
}
@media (max-width: 900px) {
    body .extern-footer__bottom {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        padding-bottom: max(110px, calc(80px + env(safe-area-inset-bottom)));
    }
    body .extern-footer__legal { align-self: flex-end; justify-content: flex-end; text-align: right; }
}

@media (prefers-reduced-motion: reduce) {
    body a.home-button > span, body a.extern-button > span,
    body a.history-end__button > span, body a.legio-button > span,
    body a.uvi-button > span, body a.smoke-button > span,
    body a.locations-final-cta__button > span,
    body a.extern-footer__contact-button > span,
    body .hero-cta-icon, body .home-service-card__arrow::before,
    body .location-card__arrow::before, body #services-prev::before,
    body #services-next::before, body .locations-carousel__arrow::before {
        transition-duration: 0.01ms !important;
    }
}
