:root {
    --hw-navy: #101a31;
    --hw-blue: #2563eb;
    --hw-soft: #f5f8ff;
    --hw-border: #e7ebf3;
    --hw-text: #172033;
    --hw-muted: #718096
}

body.portfolio-page {
    background: #fff;
    color: var(--hw-text);
    font-family: IRANYekanX, Arial, sans-serif
}

.portfolio-page a {
    text-decoration: none
}

.portfolio-hero {
    margin-top: 80px;
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 82% 48%, rgba(37, 99, 235, .065) 0, rgba(37, 99, 235, 0) 30%),
        linear-gradient(120deg, #f7f9fc 0%, #fff 58%, #f3f7ff 100%);
    border-bottom: 1px solid #edf0f5
}

.portfolio-hero:before {
    content: "";
    position: absolute;
    width: 520px;
    height: 520px;
    border-radius: 50%;
    border: 1px solid rgba(37, 99, 235, .08);
    left: -280px;
    top: -300px
}

.portfolio-hero-glow {
    position: absolute;
    width: 360px;
    height: 360px;
    border-radius: 50%;
    background: rgba(37, 99, 235, .045);
    right: 12%;
    bottom: -280px;
    filter: blur(18px)
}

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: #2563eb;
    background: rgba(255,255,255,.82);
    border: 1px solid #dce7fb;
    padding: 8px 13px;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 800;
    box-shadow: 0 7px 22px rgba(37,99,235,.06)
}

.hero-eyebrow-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #2563eb;
    box-shadow: 0 0 0 5px rgba(37,99,235,.09)
}

.portfolio-hero h1 {
    font-size: clamp(2.15rem, 4.3vw, 3.55rem);
    font-weight: 900;
    letter-spacing: -.8px;
    margin: 18px 0 13px;
    color: #111b35;
    line-height: 1.35
}

.portfolio-hero h1 span {
    color: #2563eb;
    position: relative;
    white-space: nowrap
}

.portfolio-hero h1 span:after {
    content: "";
    position: absolute;
    right: 0;
    left: 0;
    bottom: 1px;
    height: 7px;
    background: rgba(37,99,235,.10);
    border-radius: 10px;
    z-index: -1
}

.portfolio-hero p {
    max-width: 690px;
    color: #69758b;
    font-size: .98rem;
    line-height: 2.15;
    margin-bottom: 15px
}

.hero-note {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #65718a;
    font-size: .72rem;
    font-weight: 700
}

.hero-note i {
    color: #16a36a;
    font-size: 17px
}

.hero-stat {
    width: 175px;
    height: 175px;
    border: 1px solid #dfe8fb;
    background: rgba(255, 255, 255, .82);
    border-radius: 38px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 18px 50px rgba(37, 99, 235, .09);
    transform: rotate(2deg)
}

.hero-stat strong {
    font-size: 2.9rem;
    color: #2563eb;
    line-height: 1
}

.hero-stat span {
    font-size: .78rem;
    color: #69758b;
    margin-top: 9px
}

.hero-stat small {
    font-size: .62rem;
    color: #a0a9b8;
    margin-top: 8px
}

.min-vh-30 {
    min-height: 290px
}

.portfolio-hero h1 {
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 900;
    margin: 14px 0 12px;
    color: #111b35
}

.portfolio-hero p {
    max-width: 700px;
    color: #69758b;
    font-size: 1rem;
    line-height: 2
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--hw-blue);
    background: #eaf1ff;
    border: 1px solid #dbe7ff;
    padding: 7px 13px;
    border-radius: 999px;
    font-size: .78rem;
    font-weight: 700
}

.hero-stat {
    width: 160px;
    height: 160px;
    border: 1px solid #dfe8fb;
    background: rgba(255, 255, 255, .75);
    border-radius: 35px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 15px 45px rgba(37, 99, 235, .08)
}

.hero-stat strong {
    font-size: 2.7rem;
    color: var(--hw-blue);
    line-height: 1
}

.hero-stat span {
    font-size: .78rem;
    color: #69758b;
    margin-top: 8px
}

.breadcrumb-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 18px 0;
    color: #7d8798;
    font-size: .78rem
}

.breadcrumb-wrap a {
    color: #34415c
}

.breadcrumb-wrap i {
    font-size: 16px
}

.portfolio-content {
    background: #fff;
    overflow: visible !important
}

.portfolio-content .container {
    overflow: visible !important
}

.portfolio-content>.container>.row {
    align-items: flex-start !important;
    overflow: visible !important
}

.portfolio-content>.container>.row>aside {
    align-self: flex-start !important;
    position: sticky !important;
    top: 105px !important;
    height: max-content !important;
    overflow: visible !important
}

.portfolio-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    align-items: center;
    margin-bottom: 28px;
    padding: 5px 0
}

.filter-list {
    display: flex;
    gap: 9px;
    flex-wrap: wrap
}

.filter-btn {
    border: 1px solid var(--hw-border);
    background: #fff;
    color: #536078;
    padding: 10px 16px;
    border-radius: 999px;
    font-family: inherit;
    font-size: .78rem;
    cursor: pointer;
    transition: .2s
}

.filter-btn span {
    font-size: .65rem;
    margin-right: 3px;
    color: #98a2b3
}

.filter-btn:hover {
    border-color: #cbd8f5;
    transform: translateY(-1px)
}

.filter-btn.active {
    background: var(--hw-navy);
    border-color: var(--hw-navy);
    color: #fff;
    box-shadow: 0 8px 20px rgba(16, 26, 49, .15)
}

.filter-btn.active span {
    color: #dbe4ff
}

.portfolio-sort {
    align-items: center;
    gap: 8px;
    color: #8892a5;
    font-size: .75rem;
    white-space: nowrap
}

.portfolio-sort strong {
    color: #27334b
}

.project-card {
    display: block;
    background: #fff;
    border: 1px solid var(--hw-border);
    border-radius: 18px;
    overflow: hidden;
    height: 100%;
    box-shadow: 0 7px 25px rgba(18, 28, 55, .045);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 45px rgba(18, 28, 55, .11);
    border-color: #d8e2f7
}

.project-media {
    height: 210px;
    position: relative;
    overflow: hidden;
    background: #edf2fb
}

.project-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
    transition: transform .45s ease;
}

.project-card:hover .project-media img {
    transform: scale(1.045)
}

.project-favorite {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .88);
    color: #65718a;
    box-shadow: 0 5px 15px rgba(0, 0, 0, .08);
    font-size: 17px
}

.project-category {
    position: absolute;
    bottom: 12px;
    right: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    background: #edf4ff;
    color: #2563eb;
    font-size: .67rem;
    font-weight: 700
}

.category-green {
    background: #eafaf2;
    color: #15935a
}

.category-blue {
    background: #edf5ff;
    color: #2764c7
}

.category-pink {
    background: #fff0fb;
    color: #d044a8
}

.category-purple {
    background: #f1edff;
    color: #7656d9
}

.category-orange {
    background: #fff5e9;
    color: #d47a16
}

.project-body {
    padding: 17px 17px 19px
}

.project-body h2 {
    font-size: 1rem;
    font-weight: 800;
    color: #18233a;
    margin: 0 0 9px
}

.project-body p {
    font-size: .72rem;
    line-height: 1.9;
    color: #7a8497;
    margin: 0 0 16px;
    min-height: 43px
}

.project-link {
    font-size: .7rem;
    font-weight: 800;
    color: var(--hw-blue);
    display: flex;
    align-items: center;
    gap: 5px
}

.project-link i {
    font-size: 16px;
    transition: transform .2s
}

.project-card:hover .project-link i {
    transform: translateX(-3px)
}

.portfolio-pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 38px
}

.portfolio-pagination a {
    width: 38px;
    height: 38px;
    border: 1px solid var(--hw-border);
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #637087;
    font-size: .78rem;
    background: #fff
}

.portfolio-pagination a.active {
    background: var(--hw-navy);
    color: #fff;
    border-color: var(--hw-navy);
    box-shadow: 0 7px 18px rgba(16, 26, 49, .14)
}

.portfolio-content aside {
    align-self: flex-start !important
}

.portfolio-sidebar {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 105px !important;
    height: max-content !important;
    align-self: flex-start !important;
    z-index: 10
}

.side-card {
    border: 1px solid var(--hw-border);
    border-radius: 18px;
    background: #fff;
    padding: 20px;
    margin-bottom: 18px;
    box-shadow: 0 7px 25px rgba(18, 28, 55, .035)
}

.side-cta {
    background: linear-gradient(145deg, #f3f7ff, #fff);
    border-color: #dce7fb
}

.side-icon {
    width: 43px;
    height: 43px;
    border-radius: 13px;
    background: #eaf1ff;
    color: var(--hw-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 15px
}

.side-card h3 {
    font-size: .95rem;
    font-weight: 800;
    margin: 0 0 9px;
    color: #18233a
}

.side-card p {
    font-size: .72rem;
    line-height: 1.9;
    color: #7a8497;
    margin: 0 0 17px
}

.side-card .btn {
    font-size: .7rem;
    padding: 11px
}

.side-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 13px
}

.side-title i {
    color: #77849a;
    font-size: 18px
}

.side-category {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 0;
    border-bottom: 1px solid #f0f2f6;
    color: #65718a;
    font-size: .75rem
}

.side-category:last-child {
    border-bottom: 0
}

.side-category b {
    font-size: .67rem;
    min-width: 28px;
    height: 25px;
    border-radius: 8px;
    background: #f5f7fb;
    color: #8792a5;
    display: flex;
    align-items: center;
    justify-content: center
}

.side-category.active {
    color: var(--hw-blue);
    font-weight: 800
}

.side-category.active b {
    background: #eaf1ff;
    color: var(--hw-blue)
}

.side-stat {
    display: grid;
    grid-template-columns: 22px 1fr auto;
    align-items: center;
    gap: 7px;
    padding: 11px 0;
    border-bottom: 1px solid #f0f2f6;
    font-size: .7rem;
    color: #69758b
}

.side-stat:last-child {
    border-bottom: 0
}

.side-stat i {
    color: #73809a;
    font-size: 16px
}

.side-stat strong {
    color: #1b2841
}

.side-testimonial {
    background: linear-gradient(145deg, #12203d, #1c315a);
    border-radius: 18px;
    color: #fff;
    padding: 22px;
    box-shadow: 0 15px 35px rgba(16, 26, 49, .16)
}

.side-testimonial i {
    font-size: 26px;
    color: #bcd0ff
}

.side-testimonial p {
    font-size: .75rem;
    line-height: 2;
    margin: 10px 0 12px;
    color: #edf2ff
}

.side-testimonial span {
    font-size: .7rem;
    color: #b9c7e4;
    font-weight: 700
}

.portfolio-bottom-cta {
    padding: 20px 0 70px
}

.bottom-cta-card {
    border-radius: 22px;
    padding: 34px 38px;
    background: linear-gradient(110deg, #f0f5ff, #fafcff);
    border: 1px solid #e0e8f8;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px
}

.bottom-cta-card span {
    font-size: .72rem;
    color: var(--hw-blue);
    font-weight: 800
}

.bottom-cta-card h2 {
    font-size: 1.35rem;
    margin: 7px 0 5px;
    color: #18233a;
    font-weight: 900
}

.bottom-cta-card p {
    font-size: .75rem;
    color: #788399;
    margin: 0
}

.bottom-cta-card .btn {
    font-size: .75rem;
    padding: 12px 20px;
    white-space: nowrap
}

.portfolio-footer {
    background: #111b31;
    color: #aeb9ce;
    padding: 58px 0 20px
}

.footer-logo {
    height: 42px;
    filter: brightness(0) invert(1);
    margin-bottom: 17px
}

.portfolio-footer p {
    font-size: .72rem;
    line-height: 2;
    margin: 0 0 13px
}

.portfolio-footer h4 {
    color: #fff;
    font-size: .82rem;
    margin: 0 0 18px;
    font-weight: 800
}

.portfolio-footer a {
    display: block;
    color: #aeb9ce;
    font-size: .7rem;
    margin: 0 0 12px
}

.socials {
    display: flex;
    gap: 8px;
    margin-top: 16px
}

.socials a {
    width: 34px;
    height: 34px;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    color: #dbe4f5
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .08);
    margin-top: 35px;
    padding-top: 18px;
    display: flex;
    justify-content: space-between;
    gap: 15px;
    font-size: .63rem;
    color: #7e8ba4
}

@media(max-width:991px) {
    .portfolio-content>.container>.row>aside,
    .portfolio-sidebar {
        position: static !important;
        top: auto !important
    }

    .portfolio-toolbar {
        align-items: flex-start
    }

    .bottom-cta-card {
        flex-direction: column;
        align-items: flex-start
    }
}

@media(max-width:575px) {
    .portfolio-hero h1 {
        font-size: 2rem
    }

    .hero-eyebrow {
        font-size: .68rem;
        padding: 7px 11px
    }

    .portfolio-hero p {
        font-size: .82rem
    }

    .project-media {
        height: 205px
    }

    .portfolio-toolbar {
        margin-bottom: 20px
    }

    .filter-btn {
        padding: 8px 12px;
        font-size: .7rem
    }

    .bottom-cta-card {
        padding: 26px 22px
    }

    .bottom-cta-card h2 {
        font-size: 1.1rem
    }

    .footer-bottom {
        flex-direction: column
    }

    .portfolio-content {
        padding-top: 35px !important
    }

    .side-card {
        padding: 17px
    }
}

/* Portfolio starts directly under the original HavinWeb navbar.
   The navbar background is intentionally handled by the original theme.js
   exactly like aboutus.html: transparent at the top, white on scroll. */
body.portfolio-page .portfolio-content {
    padding-top: 115px !important;
}

@media (max-width: 991.98px) {
    body.portfolio-page .portfolio-content {
        padding-top: 95px !important;
    }
}


.project-clean-intro {
    padding-top: 28px;
    padding-bottom: 28px
}

.project-clean-intro .project-breadcrumb {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 11px;
    color: #7d8798;
    margin-bottom: 24px
}

.project-clean-intro .project-breadcrumb a {
    color: #68758a;
    text-decoration: none
}

.project-clean-intro .project-breadcrumb i {
    font-size: 16px;
    color: #9aa4b4
}

.project-clean-intro .project-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: #eef4ff;
    color: #2868f0;
    border-radius: 999px;
    padding: 7px 14px;
    font-size: 11px;
    font-weight: 700;
    margin-bottom: 13px
}

.project-clean-intro h1 {
    font-size: 20px;
    font-weight: 900;
    color: #14213d;
    margin: 0 0 12px;
}

.project-clean-intro p {
    font-size: 14px;
    line-height: 2;
    color: #687386;
    margin: 0;
    max-width: 760px
}