/* ═══════════════════════════════════════════════════════════════════
   Shalfa CPT Manager — Shared Front-end CSS  v2.0.0
   Applied on all scpt-single-* / archive / homepage / legal pages.
   ═══════════════════════════════════════════════════════════════════ */

/* ── Global reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
img { max-width: 100%; height: auto; }

/* ── CRITICAL: Force FontAwesome icons visible in BOTH LTR & RTL ─ */
/* Many themes reset font-family on <i> — this overrides that.     */
i[class*="fa-"],
[class*=" fa-"],
.fas, .far, .fab, .fal, .fat, .fa-solid,
.fa-regular, .fa-brands {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
    font-style:  normal !important;
    font-weight: 900;                /* solid = 900, regular = 400 */
    display:     inline-block;
    -webkit-font-smoothing: antialiased;
    text-rendering: auto;
}
.far, .fa-regular { font-weight: 400 !important; }
.fab, .fa-brands  { font-weight: 400 !important; }

/* RTL: icons pointing right → flip arrow direction, but NOT icon glyphs */
[dir="rtl"] .scpt-btn i.fa-arrow-right,
[dir="rtl"] .scpt-read-more i.fa-arrow-right,
[dir="rtl"] .ind-card__cta i.fa-arrow-right,
[dir="rtl"] .hp-ind-card__link i.fa-arrow-right,
[dir="rtl"] .hp-btn i.fa-arrow-right,
[dir="rtl"] .hp-read-more i.fa-arrow-right,
[dir="rtl"] .hp-career-row i.fa-arrow-right {
    transform: scaleX(-1);
}
/* Never flip icon glyphs themselves */
[dir="rtl"] .scpt-service-card__icon i,
[dir="rtl"] .scpt-industry-card__icon i,
[dir="rtl"] .ind-hero__icon i,
[dir="rtl"] .ind-card__icon i,
[dir="rtl"] .hp-ind-card__icon i,
[dir="rtl"] .hp-svc-card__icon i,
[dir="rtl"] .hp-hero-card__icon i,
[dir="rtl"] .ind-cta-card i {
    transform: none !important;
}

/* ── Shared Grid ────────────────────────────────────────────────── */
.scpt-grid { display: grid; gap: 24px; }
.scpt-grid-1 { grid-template-columns: 1fr; }
.scpt-grid-2 { grid-template-columns: repeat(2, 1fr); }
.scpt-grid-3 { grid-template-columns: repeat(3, 1fr); }
.scpt-grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1024px) { .scpt-grid-4 { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 768px)  { .scpt-grid-3, .scpt-grid-2 { grid-template-columns: 1fr; } }
@media (max-width: 480px)  { .scpt-grid-4 { grid-template-columns: 1fr; } }

/* ── Shared Buttons ─────────────────────────────────────────────── */
.scpt-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: .9rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    border: 2px solid transparent;
    transition: background .2s, color .2s, border-color .2s, transform .15s;
    white-space: nowrap;
}
.scpt-btn:hover { transform: translateY(-1px); }
.scpt-btn-primary   { background: #1a6b3a; color: #fff; border-color: #1a6b3a; }
.scpt-btn-primary:hover { background: #145230; border-color: #145230; color: #fff; }
.scpt-btn-outline   { background: transparent; color: #1a6b3a; border-color: #1a6b3a; }
.scpt-btn-outline:hover { background: #1a6b3a; color: #fff; }
.scpt-btn-gold      { background: #d4af37; color: #1a1a1a; border-color: #d4af37; }
.scpt-btn-gold:hover { background: #b8962e; }
.scpt-btn-sm        { padding: 6px 14px; font-size: .82rem; }

/* ── Shared Badge ───────────────────────────────────────────────── */
.scpt-badge {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 14px;
    font-size: .78rem;
    font-weight: 700;
    background: #e8f4ee;
    color: #1a6b3a;
}

/* ── Status badge ───────────────────────────────────────────────── */
.scpt-status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 14px;
    font-size: .78rem;
    font-weight: 700;
    color: #fff;
}

/* ── Service Card (shortcode) ───────────────────────────────────── */
.scpt-service-card {
    background: #fff;
    border-radius: 14px;
    padding: 28px;
    box-shadow: 0 2px 16px rgba(0,0,0,.07);
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform .25s, box-shadow .25s;
}
.scpt-service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 28px rgba(0,0,0,.1);
}
.scpt-service-card__icon {
    width: 60px; height: 60px;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; color: #fff;
    flex-shrink: 0;
}
.scpt-service-card__title { font-size: 1.05rem; font-weight: 700; margin: 0; }
.scpt-service-card__title a { color: #111827; text-decoration: none; }
.scpt-service-card__title a:hover { color: #1a6b3a; }
.scpt-service-card__excerpt { font-size: .88rem; color: #555; line-height: 1.6; margin: 0; flex: 1; }
.scpt-service-card__stat {
    background: #f0f7f2; padding: 8px 12px;
    border-radius: 8px; font-size: .82rem;
}

/* ── Industry Card (shortcode) ──────────────────────────────────── */
.scpt-industry-card {
    background: #fff;
    border-radius: 14px;
    padding: 28px;
    box-shadow: 0 2px 16px rgba(0,0,0,.07);
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform .25s, box-shadow .25s;
}
.scpt-industry-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 28px rgba(0,0,0,.1);
    border-color: #1a6b3a;
}
.scpt-industry-card__icon {
    width: 60px; height: 60px;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; color: #fff;
    flex-shrink: 0;
}
.scpt-industry-card__title { font-size: 1.05rem; font-weight: 700; margin: 0; }
.scpt-industry-card__title a { color: #111827; text-decoration: none; }
.scpt-industry-card__title a:hover { color: #1a6b3a; }
.scpt-industry-card__excerpt { font-size: .88rem; color: #555; line-height: 1.6; margin: 0; flex: 1; }
.scpt-industry-card__stat {
    background: #f0f7f2; padding: 8px 12px;
    border-radius: 8px; font-size: .82rem;
}

/* ── Project Card (shortcode) ───────────────────────────────────── */
.scpt-project-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 2px 14px rgba(0,0,0,.07);
    border: 1px solid #e2e8f0;
    transition: transform .25s, box-shadow .25s;
}
.scpt-project-card:hover { transform: translateY(-4px); box-shadow: 0 10px 32px rgba(0,0,0,.1); }
.scpt-project-card__img { height: 190px; overflow: hidden; position: relative; }
.scpt-project-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.scpt-project-card:hover .scpt-project-card__img img { transform: scale(1.04); }
.scpt-project-card__body { padding: 18px; }
.scpt-project-card__meta {
    display: flex; flex-wrap: wrap; gap: 6px;
    font-size: .78rem; color: #6b7280; margin: 6px 0 12px;
}
.scpt-project-card__meta span { display: flex; align-items: center; gap: 4px; }

/* ── Career Row (shortcode) ─────────────────────────────────────── */
.scpt-careers-list { display: flex; flex-direction: column; gap: 12px; }
.scpt-career-row {
    background: #fff;
    border-radius: 12px;
    padding: 18px 22px;
    box-shadow: 0 2px 10px rgba(0,0,0,.06);
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    transition: border-color .2s, box-shadow .2s;
}
.scpt-career-row:hover { border-color: #1a6b3a; box-shadow: 0 4px 18px rgba(26,107,58,.1); }
.scpt-career-row__info { flex: 1; min-width: 220px; }
.scpt-career-row__title { font-size: 1rem; font-weight: 700; margin: 0 0 6px; }
.scpt-career-row__title a { color: #111827; text-decoration: none; }
.scpt-career-row__title a:hover { color: #1a6b3a; }
.scpt-career-row__meta { display: flex; flex-wrap: wrap; gap: 10px; font-size: .78rem; color: #6b7280; }
.scpt-career-row__meta span { display: flex; align-items: center; gap: 4px; }
.scpt-career-row__actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* ── News Card (shortcode) ──────────────────────────────────────── */
.scpt-news-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,.07);
    border: 1px solid #e5e7eb;
    transition: transform .25s, box-shadow .25s;
    display: flex; flex-direction: column;
}
.scpt-news-card:hover { transform: translateY(-4px); box-shadow: 0 8px 28px rgba(0,0,0,.1); }
.scpt-news-card--featured { border-top: 4px solid #d4af37; }
.scpt-news-card__img { height: 190px; overflow: hidden; position: relative; }
.scpt-news-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.scpt-news-card:hover .scpt-news-card__img img { transform: scale(1.04); }
.scpt-featured-star {
    position: absolute; top: 10px; left: 10px;
    background: #d4af37; color: #1a1a1a;
    padding: 3px 10px; border-radius: 4px;
    font-size: .72rem; font-weight: 700;
}
[dir="rtl"] .scpt-featured-star { left: auto; right: 10px; }
.scpt-news-card__body { padding: 18px; display: flex; flex-direction: column; flex: 1; }
.scpt-news-card__meta {
    display: flex; align-items: center; gap: 8px;
    margin-bottom: 8px; flex-wrap: wrap; font-size: .75rem; color: #9ca3af;
}
.scpt-news-card__cat {
    background: #e8f4ee; color: #1a6b3a;
    padding: 2px 8px; border-radius: 4px; font-weight: 700;
    text-decoration: none;
}
.scpt-news-card__title { font-size: 1rem; font-weight: 700; margin: 0 0 8px; line-height: 1.4; }
.scpt-news-card__title a { color: #111827; text-decoration: none; }
.scpt-news-card__title a:hover { color: #1a6b3a; }
.scpt-news-card__excerpt { font-size: .85rem; color: #6b7280; line-height: 1.6; margin: 0 0 14px; flex: 1; }
.scpt-news-card__footer {
    display: flex; align-items: center; justify-content: space-between;
    padding-top: 10px; border-top: 1px solid #f3f4f6; margin-top: auto;
}
.scpt-news-card__author { font-size: .75rem; color: #9ca3af; display: flex; align-items: center; gap: 4px; }
.scpt-read-more {
    font-size: .8rem; font-weight: 700; color: #1a6b3a;
    text-decoration: none; display: flex; align-items: center; gap: 4px;
}

/* ── RTL shortcode overrides ────────────────────────────────────── */
[dir="rtl"] .scpt-service-card,
[dir="rtl"] .scpt-industry-card,
[dir="rtl"] .scpt-project-card__body,
[dir="rtl"] .scpt-career-row,
[dir="rtl"] .scpt-news-card__body {
    direction: rtl;
    text-align: right;
}
[dir="rtl"] .scpt-career-row__meta,
[dir="rtl"] .scpt-project-card__meta { direction: rtl; }

/* ── Archive hero shared ────────────────────────────────────────── */
.scpt-arch-hero {
    padding: 64px 24px;
    text-align: center;
    color: #fff;
    position: relative;
    overflow: hidden;
}
.scpt-arch-hero h1 { font-size: clamp(1.8rem,4vw,3rem); font-weight: 800; margin: 0 0 12px; }
.scpt-arch-hero p  { font-size: 1rem; opacity: .82; max-width: 580px; margin: 0 auto; line-height: 1.7; }

/* ── Pagination ─────────────────────────────────────────────────── */
.scpt-pagination,
.nav-links { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; padding: 40px 0; }
.scpt-pagination a,
.scpt-pagination span,
.nav-links .page-numbers {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 38px; height: 38px; border-radius: 8px;
    font-size: .88rem; font-weight: 600;
    border: 2px solid #e2e8f0; color: #333; text-decoration: none;
    transition: .2s;
}
.scpt-pagination a:hover,
.nav-links .page-numbers:hover { border-color: #1a6b3a; color: #1a6b3a; }
.scpt-pagination .current,
.nav-links .page-numbers.current { background: #1a6b3a; border-color: #1a6b3a; color: #fff; }

/* ── Utility ────────────────────────────────────────────────────── */
.scpt-text-center { text-align: center; }
.scpt-mt-sm { margin-top: 16px; }
.scpt-mt-md { margin-top: 32px; }
.scpt-container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ── Legal page shared styles ───────────────────────────────────── */
.scpt-legal-hero {
    background: linear-gradient(135deg, #0d3d20, #1a6b3a);
    padding: 72px 24px;
    text-align: center;
    color: #fff;
}
.scpt-legal-hero h1 { font-size: clamp(2rem,4vw,3rem); font-weight: 800; margin: 0 0 14px; }
.scpt-legal-hero p  { font-size: 1rem; opacity: .82; max-width: 560px; margin: 0 auto; line-height: 1.7; }
.scpt-legal-body {
    max-width: 860px; margin: 60px auto; padding: 0 24px 80px;
    font-size: .97rem; color: #2d2d2d; line-height: 1.85;
}
.scpt-legal-body h2 {
    font-size: 1.25rem; font-weight: 800; color: #1a6b3a;
    margin: 40px 0 14px; padding-bottom: 8px;
    border-bottom: 2px solid #c6dfd1;
}
.scpt-legal-body h3 { font-size: 1.05rem; font-weight: 700; color: #333; margin: 28px 0 10px; }
.scpt-legal-body p  { margin: 0 0 14px; }
.scpt-legal-body ul,
.scpt-legal-body ol { margin: 0 0 16px; padding-left: 24px; }
[dir="rtl"] .scpt-legal-body ul,
[dir="rtl"] .scpt-legal-body ol { padding-left: 0; padding-right: 24px; }
.scpt-legal-body li { margin-bottom: 6px; }
.scpt-legal-body a  { color: #1a6b3a; text-decoration: underline; }
.scpt-legal-last-updated {
    display: inline-block; background: #e8f4ee; color: #1a6b3a;
    padding: 4px 14px; border-radius: 20px; font-size: .78rem; font-weight: 700;
    margin-bottom: 32px;
}
[dir="rtl"] .scpt-legal-body { direction: rtl; text-align: right; }
