/* Dimanusa-specific tweaks on top of Aleric */
.tp-input {
    display: block;
    width: 100%;
    border: 1px solid rgba(3, 3, 3, 0.12);
    border-radius: 12px;
    padding: 14px 18px;
    font-family: inherit;
    font-size: 16px;
    background: #fff;
}

.tp-input:focus {
    outline: 2px solid rgba(3, 3, 3, 0.2);
    outline-offset: 1px;
}

.rich-text {
    font-size: 18px;
    line-height: 1.7;
    color: #4a4a4a;
}

.rich-text h2,
.rich-text h3,
.rich-text h4 {
    color: #030303;
    margin: 1.5rem 0 0.75rem;
}

.rich-text p {
    margin-bottom: 1rem;
}

.rich-text ul,
.rich-text ol {
    margin: 0 0 1rem 1.25rem;
}

.rich-text img {
    max-width: 100%;
    height: auto;
}

/* Keep primary nav on one row (Aleric IT header has ~5 items) */
.dimanusa-nav-list {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 0;
    padding: 0;
    white-space: nowrap;
}

.tp-main-menu-it > nav > ul.dimanusa-nav-list > li {
    margin: 0 !important;
}

.tp-main-menu-it > nav > ul.dimanusa-nav-list > li > a {
    padding-left: 14px !important;
    padding-right: 14px !important;
    font-size: 14px !important;
    letter-spacing: 0.02em;
}

@media (min-width: 1400px) {
    .tp-main-menu-it > nav > ul.dimanusa-nav-list > li > a {
        padding-left: 18px !important;
        padding-right: 18px !important;
        font-size: 15px !important;
    }
}

/* Preserve logo aspect ratio — Aleric sets width via [data-width], which
   squashes wide logos when combined with a height limit. */
.tp-header-logo img,
.tp-header-logo picture,
.tp-offcanvas-logo img,
.tp-offcanvas-logo picture,
.tp-footer-logo img,
.tp-footer-logo picture {
    display: inline-block;
    max-width: 150px;
}

.tp-header-logo img,
.tp-offcanvas-logo img,
.tp-footer-logo img {
    width: auto !important;
    height: auto !important;
    max-height: 48px;
    object-fit: contain;
}

/* Landing/list portfolio cards — don't use .tp-portfolio-it-wrap (594px top pad) */
.dimanusa-portfolio-card .tp-portfolio-sa-thumb {
    overflow: hidden;
    border-radius: 16px;
    background: #f3f4f2;
    aspect-ratio: 4 / 3;
}

.dimanusa-portfolio-card .tp-portfolio-sa-thumb picture,
.dimanusa-portfolio-card .tp-portfolio-sa-thumb img {
    width: 100%;
    height: 100%;
    display: block;
}

.dimanusa-portfolio-card .tp-portfolio-sa-thumb img {
    object-fit: cover;
    transition: transform 0.4s ease;
}

.dimanusa-portfolio-card:hover .tp-portfolio-sa-thumb img {
    transform: scale(1.04);
}

.dimanusa-portfolio-card .tp-portfolio-sa-content {
    padding-top: 4px;
}

/* service-details-style banners / process images with AppImg <picture> */
.tp-about-me-banner picture,
.tp-service-process-img picture {
    display: block;
    width: 100%;
    height: 100%;
}

.tp-about-me-banner img,
.tp-service-process-img img {
    width: 100%;
    display: block;
}

.tp-service-details-content ul li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
}

.tp-service-details-content ul li i {
    margin-top: 4px;
    color: #030303;
}

.tp-service-details-content ul li p {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
}

/* Partner logo strip */
.dimanusa-partner-logo {
    min-height: 88px;
    padding: 12px;
    filter: grayscale(1);
    opacity: 0.85;
    transition: filter 0.25s ease, opacity 0.25s ease;
}

.dimanusa-partner-logo:hover {
    filter: grayscale(0);
    opacity: 1;
}

/* Project Info sidebar — keep value readable on light Aleric card */
.tp-portfolio-details-shedule ul li {
    justify-content: space-between;
    gap: 12px;
    align-items: baseline;
}

.tp-portfolio-details-shedule ul li span {
    color: var(--tp-common-black-4, #6b6b6b);
    font-weight: 500;
}

.tp-portfolio-details-shedule ul li b,
.tp-portfolio-details-shedule ul li a {
    flex: 1;
    text-align: right;
    font-weight: 600;
    color: var(--tp-common-black-1, #030303);
    word-break: break-word;
}

.tp-portfolio-details-shedule ul li a:hover {
    text-decoration: underline;
}

/* Service card hover cover */
.tp-service-item-bg picture,
.tp-service-item-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.tp-service-item:hover .tp-service-item-title a,
.tp-service-item:hover h4 a,
.tp-service-item:hover p {
    color: #fff;
    position: relative;
    z-index: 2;
}

.tp-service-item:hover .tp-service-item-bg {
    z-index: 0;
}

.tp-service-item:hover .d-flex,
.tp-service-item:hover h4,
.tp-service-item:hover p,
.tp-service-item:hover .tp-btn,
.tp-service-item:hover a.tp-btn {
    position: relative;
    z-index: 2;
}

.tp-service-item:hover .tp-service-item-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
}

/* Soften header offset on inner pages */
.tp-service-hero-spacing {
    padding-top: 160px;
}

@media (max-width: 991px) {
    .tp-service-hero-spacing {
        padding-top: 120px;
    }

    .tp-service-hero-right {
        margin-top: 0 !important;
    }
}
