/* ============================================================
   مؤسسة بن الحرجي – Company Profile Section
   Follows the main.css theme patterns exactly
   ============================================================ */


/* --- Service Area Cards (7 fields) --- */
.harji-service-card {
    position: relative;
    background: hsl(var(--white));
    border-radius: 10px;
    padding: 28px 22px 22px;
    height: 100%;
    transition: 0.4s ease;
    box-shadow: var(--box-shadow);
    overflow: hidden;
    border: 1px solid hsl(var(--base)/0.06);
}

.harji-service-card__number {
    position: absolute;
    top: 12px;
    left: 16px;
    font-size: 2.8rem;
    font-weight: 900;
    line-height: 1;
    color: hsl(var(--base)/0.06);
    transition: 0.4s ease;
    pointer-events: none;
}

[dir="rtl"] .harji-service-card__number {
    left: unset;
    right: 16px;
}

.harji-service-card__icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: hsl(var(--base)/0.08);
    color: var(--title-col);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 16px;
    border: 2px solid hsl(var(--base)/0.12);
    transition: 0.4s ease;
}

.harji-service-card__body h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--title-col);
    margin-bottom: 8px;
    transition: 0.4s ease;
}

.harji-service-card__body p {
    font-size: 0.85rem;
    color: rgba(var(--dark-text), 0.65);
    line-height: 1.7;
    margin-bottom: 0;
    transition: 0.4s ease;
}

.harji-service-card::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--title-col);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s ease;
}

[dir="rtl"] .harji-service-card::after {
    transform-origin: left;
}

.harji-service-card:hover {
    background: var(--title-col);
    border-color: var(--title-col);
    transform: translateY(-4px);
    box-shadow: 0px 20px 40px rgba(0, 72, 120, 0.15);
}

.harji-service-card:hover::after {
    transform: scaleX(1);
}

.harji-service-card:hover .harji-service-card__number {
    color: rgba(255, 255, 255, 0.15);
}

.harji-service-card:hover .harji-service-card__icon {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.3);
}

.harji-service-card:hover .harji-service-card__body h3 {
    color: #fff;
}

.harji-service-card:hover .harji-service-card__body p {
    color: rgba(255, 255, 255, 0.8);
}

/* Highlight variant (solar energy) */
.harji-service-card--highlight {
    border: 2px solid #be1d2c;
}

.harji-service-card--highlight::after {
    background: #be1d2c;
}

.harji-service-card--highlight .harji-service-card__icon {
    background: rgba(190, 29, 44, 0.1);
    color: #be1d2c;
    border-color: rgba(190, 29, 44, 0.2);
}

.harji-service-card--highlight:hover {
    background: linear-gradient(135deg, #be1d2c 0%, #8b0000 100%);
    border-color: #be1d2c;
}

.harji-service-card--highlight:hover .harji-service-card__icon {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.3);
}


/* --- Equipment Scroll (mobile-first horizontal scroll, desktop grid) --- */
.harji-equip-scroll {
    margin-top: 12px;
    -webkit-overflow-scrolling: touch;
}

.harji-equip-scroll__track {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 4px;
}

.harji-equip-scroll__track::-webkit-scrollbar {
    display: none;
}

.harji-equip-card {
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 18px 14px;
    min-width: 110px;
    flex-shrink: 0;
    text-align: center;
    transition: 0.4s ease;
}

.harji-equip-card:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
}

.harji-equip-card__icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    border: 2px solid rgba(255, 255, 255, 0.15);
    transition: 0.4s ease;
}

.harji-equip-card:hover .harji-equip-card__icon {
    background: #fff;
    color: var(--title-col);
    border-color: #fff;
}

.harji-equip-card span {
    font-size: 0.78rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.3;
    white-space: nowrap;
    transition: 0.4s ease;
}

.harji-equip-card:hover span {
    color: #fff;
}


/* --- Tags (for project cards & table) --- */
.harji-tag {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px 0px 20px;
    white-space: nowrap;
    background: hsl(var(--base)/0.1);
    color: var(--title-col);
}

.harji-tag--light {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.harji-tag--partner {
    background: rgba(var(--secondary-color), 0.15);
    color: #b45309;
}

.harji-tag--mil {
    background: rgba(var(--success-color), 0.1);
    color: #277a2a;
}

.harji-tag--gov {
    background: hsl(var(--base)/0.1);
    color: var(--title-col);
}

.harji-tag--intl {
    background: rgba(var(--error-color), 0.08);
    color: #be1d2c;
}

.harji-tag--port {
    background: rgba(var(--accent-color), 0.08);
    color: #3a6de5;
}

.harji-tag--pvt {
    background: rgba(var(--secondary-color), 0.1);
    color: #b45309;
}


/* --- Project Cards --- */
.harji-project-card {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    background: hsl(var(--white));
    box-shadow: var(--box-shadow);
    border-radius: 10px;
    padding: 24px 22px;
    height: 100%;
    transition: 0.4s ease;
    border: 1px solid hsl(var(--base)/0.06);
    position: relative;
    overflow: hidden;
}

.harji-project-card::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 4px;
    height: 100%;
    background: var(--title-col);
    border-radius: 0 10px 10px 0;
    transition: width 0.4s ease;
}

[dir="rtl"] .harji-project-card::before {
    right: unset;
    left: 0;
    border-radius: 10px 0 0 10px;
}

.harji-project-card:hover {
    background: var(--title-col);
    border-color: var(--title-col);
    transform: translateY(-4px);
    box-shadow: 0px 20px 40px rgba(0, 72, 120, 0.15);
}

.harji-project-card:hover::before {
    width: 0;
}

.harji-project-card:hover h3,
.harji-project-card:hover .title {
    color: #fff !important;
}

.harji-project-card:hover p,
.harji-project-card:hover .content-color {
    color: rgba(255, 255, 255, 0.8) !important;
}

.harji-project-card:hover .harji-project-card__icon-wrap {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.3);
}

.harji-project-card:hover .harji-tag:not(.harji-tag--light) {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.harji-project-card__icon-wrap {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 50%;
    background: hsl(var(--base)/0.08);
    color: var(--title-col);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    border: 2px solid hsl(var(--base)/0.12);
    transition: 0.4s ease;
}

.harji-project-card__body {
    flex: 1;
    min-width: 0;
}

.harji-project-card__body h3 {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.5;
    transition: color 0.4s ease;
}

.harji-project-card__body p {
    font-size: 0.85rem;
    line-height: 1.6;
    transition: color 0.4s ease;
}

/* Featured (dark) variant */
.harji-project-card--featured {
    border: none !important;
}

.harji-project-card--featured::before {
    background: #be1d2c;
}

.harji-project-card--featured .harji-project-card__icon-wrap {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.harji-project-card--featured:hover {
    background: linear-gradient(135deg, #004878 0%, #001a33 100%) !important;
}

.harji-project-card--featured:hover .harji-project-card__icon-wrap {
    background: rgba(255, 255, 255, 0.2);
}


/* --- Quality Pillars (inside section-bg2) --- */
.harji-quality-pillar {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 30px 0px 30px;
    padding: 30px 20px;
    transition: 0.4s ease;
}

.harji-quality-pillar:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-4px);
    box-shadow: 0px 20px 30px rgba(0, 0, 0, 0.2);
}

.harji-quality-pillar__icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    margin: 0 auto 14px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: 0.4s ease;
}

.harji-quality-pillar:hover .harji-quality-pillar__icon {
    background: #fff;
    color: var(--title-col);
    border-color: #fff;
}

/* --- Safety Notice --- */
.harji-safety-notice {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--border-radius-sm);
    padding: 18px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

/* --- Table Number Column --- */
.harji-table-num {
    font-weight: 800;
    color: #be1d2c;
    font-size: 0.88rem;
    width: 40px;
}

/* --- Table Row Styles --- */
.harji-profile-section .table tbody tr {
    transition: 0.3s ease;
}

.harji-profile-section .table tbody tr:hover {
    background: hsl(var(--base)/0.04);
}


/* ============================
   Responsive – Mobile First
   ============================ */

/* Extra small – phones (≤480px) */
@media (max-width: 480px) {
    .harji-service-card {
        padding: 22px 16px 16px;
    }

    .harji-service-card__number {
        font-size: 2rem;
    }

    .harji-service-card__icon {
        width: 42px;
        height: 42px;
        font-size: 1rem;
        margin-bottom: 12px;
    }

    .harji-service-card__body h3 {
        font-size: 0.92rem;
    }

    .harji-service-card__body p {
        font-size: 0.8rem;
    }

    .harji-project-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 18px 16px;
        gap: 12px;
    }

    .harji-project-card__body .d-flex {
        justify-content: center;
    }

    .harji-project-card__body h3 {
        font-size: 0.92rem;
    }

    .harji-equip-card {
        min-width: 90px;
        padding: 14px 10px;
    }

    .harji-equip-card__icon {
        width: 38px;
        height: 38px;
        font-size: 0.95rem;
    }

    .harji-equip-card span {
        font-size: 0.7rem;
    }
}

/* Small – phones landscape / small tablets (≤768px) */
@media (max-width: 768px) {
    .harji-project-card {
        padding: 18px 16px;
        gap: 14px;
    }

    .harji-project-card__icon-wrap {
        width: 46px;
        height: 46px;
        min-width: 46px;
        font-size: 1.1rem;
    }

    .harji-project-card__body h3 {
        font-size: 0.95rem;
    }

    /* Equipment: 2 items visible at once on small screens */
    .harji-equip-scroll__track {
        gap: 10px;
    }

    .harji-equip-card {
        min-width: 100px;
        padding: 16px 12px;
    }
}

/* Medium+ tablets & desktop – switch equipment to grid */
@media (min-width: 769px) {
    .harji-equip-scroll__track {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        overflow-x: visible;
        scroll-snap-type: none;
    }

    .harji-equip-card {
        min-width: unset;
        flex-shrink: unset;
    }
}

/* Large desktop – more columns */
@media (min-width: 1200px) {
    .harji-equip-scroll__track {
        grid-template-columns: repeat(8, 1fr);
    }
}

/* --- Inline SVG icons inside the project card wrap --- */
.harji-project-card__icon-wrap .harji-icon {
    width: 26px;
    height: 26px;
    display: block;
    color: inherit;
    fill: currentColor;
    transition: color 0.4s ease, fill 0.4s ease;
}

/* --- Inline SVG icons inside the equipment card icon --- */
.harji-equip-card__icon .harji-icon {
    width: 20px;
    height: 20px;
    display: block;
    color: inherit;
    fill: currentColor;
    transition: color 0.4s ease, fill 0.4s ease;
}

/* --- Inline SVG icons inside the service (work area) card icon --- */
.harji-service-card__icon .harji-icon {
    width: 24px;
    height: 24px;
    display: block;
    color: inherit;
    fill: currentColor;
    transition: color 0.4s ease, fill 0.4s ease;
}

/* --- Inline SVG icons inside the experience (partner) card icon --- */
.experience__icon .harji-icon {
    width: 30px;
    height: 30px;
    display: block;
    color: inherit;
    fill: currentColor;
}

/* --- Inline SVG icons for section headings inside company profile --- */
.hsec-icon {
    width: 30px;
    height: 30px;
    display: inline-block;
    vertical-align: middle;
    fill: #be1d2c;
    margin-inline-end: 8px;
    flex-shrink: 0;
}
.py-80 .hsec-icon,
.section-bg2 .hsec-icon {
    fill: #fff;
}

/* --- Inline SVG icons inside quality pillar icon wrap --- */
.harji-quality-pillar__icon .harji-icon {
    width: 32px;
    height: 32px;
    display: block;
    color: inherit;
    fill: currentColor;
}
