/*
Theme Name: ApexStair
Theme URI: https://apexstair.ir
Author: yousef pouraminian
Author URI: https://sitralweb.com
Description: قالب اختصاصی برای ApexStair - طراحی و اجرای پله و نرده در شمال ایران
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: apexstair
*/

/* ===== RESET & VARIABLES ===== */
:root {
    --primary: #f5b400;
    --primary-dark: #d99a00;
    --primary-light: #ffd54f;
    --secondary: #1a1a1a;
    --text: #2a2a2a;
    --text-light: #777;
    --bg-light: #fffdf5;
    --white: #ffffff;
    --border: #f0e6c8;
    --font: 'Vazirmatn', sans-serif;
    --shadow: 0 5px 20px rgba(245, 180, 0, 0.15);
    --radius: 10px;

    --apex-gold: #f5b400;
    --apex-gold-light: #ffd54f;
    --apex-gold-dark: #d99a00;
    --apex-dark: #0c0c0c;
    --apex-dark-2: #141414;
    --apex-line: rgba(255, 255, 255, 0.08);
    --apex-header-h: 76px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font);
    color: var(--text);
    line-height: 1.9;
    direction: rtl;
    background-color: var(--white);
}

a { text-decoration: none; color: inherit; transition: all 0.3s; }
a:hover { color: var(--primary); }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4, h5, h6 { font-weight: 700; line-height: 1.4; color: var(--secondary); }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.section-padding { padding: 80px 0; }

.section-title { text-align: center; margin-bottom: 50px; }
.section-title h2 { font-size: 2.5rem; color: var(--secondary); margin-bottom: 10px; position: relative; display: inline-block; }
.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -15px;
    right: 50%;
    transform: translateX(50%);
    width: 80px;
    height: 3px;
    background: var(--primary);
}
.section-title p { color: var(--text-light); font-size: 1.1rem; margin-top: 25px; }

.btn {
    display: inline-block;
    padding: 12px 32px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50px;
    font-weight: 700;
    margin-top: 20px;
    border: 2px solid var(--primary);
    transition: all 0.3s;
    cursor: pointer;
}
.btn:hover { background: transparent; color: var(--primary); }
.btn-outline { background: transparent; color: var(--white); border-color: var(--white); }
.btn-outline:hover { background: var(--white); color: var(--secondary); }
.btn-sm { padding: 8px 22px; font-size: 0.9rem; margin-top: 10px; }

/* ===== HEADER (inner pages) ===== */
.site-header {
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header-inner { display: flex; justify-content: space-between; align-items: center; padding: 15px 0; }
.logo img { max-height: 60px; }
.main-nav ul { display: flex; gap: 25px; }
.main-nav a { font-weight: 600; color: var(--secondary); padding: 5px 0; position: relative; }
.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s;
}
.main-nav a:hover::after { width: 100%; }
.header-contact { display: flex; align-items: center; gap: 15px; }
.header-contact .phone { font-weight: 700; color: var(--secondary); direction: ltr; }

/* ===== HERO (inner pages) ===== */
.hero {
    height: 85vh;
    min-height: 600px;
    background: #333 center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    position: relative;
}
.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.75), rgba(0,0,0,0.5));
}
.hero-content { position: relative; z-index: 2; max-width: 850px; padding: 0 20px; }
.hero h1 { font-size: 3.5rem; margin-bottom: 20px; color: var(--white); text-shadow: 2px 2px 8px rgba(0,0,0,0.5); }
.hero p { font-size: 1.3rem; margin-bottom: 30px; }
.hero .btn { margin: 5px; }

/* ===== SERVICES GRID ===== */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; }
.service-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
}
.service-card:hover { transform: translateY(-10px); box-shadow: 0 15px 35px rgba(0,0,0,0.12); }
.service-card img { width: 100%; height: 240px; object-fit: cover; background: #eee; }
.service-card-content { padding: 25px; text-align: center; flex: 1; display: flex; flex-direction: column; }
.service-card-content h3 { font-size: 1.4rem; margin-bottom: 15px; color: var(--secondary); }
.service-card-content p { color: var(--text-light); flex: 1; margin-bottom: 15px; }

/* ===== PORTFOLIO GRID ===== */
.portfolio-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 25px; }
.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    height: 320px;
    background: #ddd;
    display: block;
}
.portfolio-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s; }
.portfolio-item:hover img { transform: scale(1.1); }
.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.85), transparent 60%);
    padding: 30px 20px 20px;
    color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}
.portfolio-overlay h3 { color: var(--white); font-size: 1.3rem; margin-bottom: 5px; }
.portfolio-overlay span { color: var(--primary); font-size: 0.9rem; }

/* ===== WHY US ===== */
.why-us { background: var(--bg-light); }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 30px; text-align: center; }
.feature-box { padding: 30px 20px; background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); transition: transform 0.3s; }
.feature-box:hover { transform: translateY(-5px); }
.feature-box i { font-size: 2.5rem; color: var(--primary); margin-bottom: 20px; }
.feature-box h4 { font-size: 1.15rem; margin-bottom: 10px; }
.feature-box p { color: var(--text-light); font-size: 0.95rem; }

/* ===== SINGLE POST ===== */
.single-header { padding: 60px 0 30px; background: var(--bg-light); text-align: center; }
.single-header h1 { font-size: 2.5rem; margin-bottom: 15px; }
.single-meta { color: var(--text-light); font-size: 0.95rem; }
.single-meta span { margin: 0 10px; }
.single-content { padding: 60px 0; }
.single-content .featured-image { margin-bottom: 40px; border-radius: var(--radius); overflow: hidden; }
.single-content .content-body { font-size: 1.1rem; text-align: justify; }
.single-content .content-body p { margin-bottom: 20px; }
.single-content .content-body h2, .single-content .content-body h3 { margin: 30px 0 15px; }
.single-content .content-body img { border-radius: var(--radius); margin: 20px 0; }

.portfolio-meta-box {
    background: var(--bg-light);
    padding: 30px;
    border-radius: var(--radius);
    margin: 30px 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
}
.portfolio-meta-box .meta-item { text-align: center; }
.portfolio-meta-box .meta-item .label { display: block; color: var(--text-light); font-size: 0.9rem; margin-bottom: 5px; }
.portfolio-meta-box .meta-item .value { font-weight: 700; color: var(--secondary); font-size: 1.05rem; }

/* ===== ARCHIVE ===== */
.archive-header { background: var(--secondary); color: var(--white); padding: 60px 0; text-align: center; }
.archive-header h1 { color: var(--white); font-size: 2.3rem; margin-bottom: 10px; }
.archive-header p { color: #ccc; }
.archive-content { padding: 60px 0; }
.archive-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }

.post-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}
.post-card:hover { transform: translateY(-8px); }
.post-card img { width: 100%; height: 220px; object-fit: cover; background: #eee; }
.post-card-body { padding: 25px; flex: 1; display: flex; flex-direction: column; }
.post-card-body h3 { font-size: 1.2rem; margin-bottom: 12px; }
.post-card-body h3 a { color: var(--secondary); }
.post-card-body h3 a:hover { color: var(--primary); }
.post-card-body p { color: var(--text-light); font-size: 0.95rem; flex: 1; margin-bottom: 15px; }
.post-card-body .read-more { color: var(--primary); font-weight: 700; font-size: 0.9rem; }

.filter-buttons { text-align: center; margin-bottom: 40px; }
.filter-buttons a {
    display: inline-block;
    padding: 8px 22px;
    margin: 5px;
    border: 2px solid var(--border);
    border-radius: 50px;
    color: var(--text);
    font-size: 0.95rem;
    transition: all 0.3s;
}
.filter-buttons a:hover, .filter-buttons a.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* ===== PAGINATION ===== */
.pagination { text-align: center; margin-top: 50px; }
.pagination .page-numbers {
    display: inline-block;
    padding: 8px 16px;
    margin: 0 4px;
    border: 2px solid var(--border);
    border-radius: 6px;
    color: var(--text);
}
.pagination .page-numbers.current, .pagination .page-numbers:hover {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* ===== FOOTER (inner pages) ===== */
.site-footer { background: var(--secondary); color: #ccc; padding: 60px 0 20px; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 40px; margin-bottom: 40px; }
.footer-col h4 { color: var(--white); font-size: 1.2rem; margin-bottom: 20px; padding-bottom: 10px; border-bottom: 2px solid var(--primary); display: inline-block; }
.footer-col p, .footer-col li { margin-bottom: 10px; }
.footer-col a:hover { color: var(--primary); }
.footer-bottom { text-align: center; border-top: 1px solid #444; padding-top: 20px; font-size: 0.9rem; }

/* ===== CTA SECTION ===== */
.cta-section { background: var(--secondary); color: var(--white); text-align: center; }
.cta-section h2 { color: var(--white); }
.cta-section .phone-big { font-size: 2rem; font-weight: 800; direction: ltr; display: inline-block; margin: 15px 0; color: var(--primary); }

/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
    .hero h1 { font-size: 2.6rem; }
}
@media (max-width: 768px) {
    .header-inner { flex-direction: column; gap: 15px; }
    .main-nav ul { gap: 15px; flex-wrap: wrap; justify-content: center; }
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 1rem; }
    .section-title h2 { font-size: 1.8rem; }
    .section-padding { padding: 50px 0; }
    .single-header h1 { font-size: 1.8rem; }
}

/* ===== CONTACT CARDS ===== */
.contact-card:hover { transform: translateY(-8px); }

/* ===== FORM INPUTS ===== */
.apexstair-contact-form input:focus,
.apexstair-contact-form textarea:focus,
.apexstair-contact-form select:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.15);
}

/* ===== FAQ DETAILS ===== */
details[open] summary { color: var(--primary); margin-bottom: 10px; }
details summary::-webkit-details-marker { display: none; }
details summary::before {
    margin-left: 10px;
    color: var(--primary);
    transition: transform 0.3s;
    display: inline-block;
}
details[open] summary::before { content: '\f068'; }

/* ===== ABOUT PAGE GRID ===== */
@media (max-width: 768px) {
    .about-hero h1,
    .contact-hero h1 { font-size: 2rem !important; }
    section[style*="grid-template-columns: 1fr 1.5fr"],
    section[style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }
}

/* =========================================================
   HERO (Home)
   ========================================================= */
.apex-hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 140px 0 100px;
    overflow: hidden;
    color: #fff;
}
.apex-hero__media {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 25% 20%, rgba(245,180,0,0.18), transparent 55%),
        radial-gradient(circle at 80% 80%, rgba(245,180,0,0.08), transparent 50%),
        linear-gradient(135deg, #0c0c0c 0%, #131313 60%, #0a0a0a 100%);
    z-index: 0;
}
.apex-hero__veil {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.15) 40%, rgba(0,0,0,0.8) 100%);
    z-index: 1;
}
.apex-hero__grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 80px 80px;
    z-index: 1;
    mask-image: radial-gradient(ellipse at center, #000 30%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 80%);
}
.apex-hero__content {
    position: relative;
    z-index: 2;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 28px;
    width: 100%;
}
.apex-kicker {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #bbb;
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    margin-bottom: 28px;
}
.apex-kicker span {
    display: inline-block;
    width: 36px; height: 1.5px;
    background: var(--primary);
}
.apex-hero h1 {
    font-size: clamp(2.2rem, 6vw, 5rem);
    line-height: 1.15;
    font-weight: 800;
    margin: 0 0 30px;
    letter-spacing: -0.01em;
}
.apex-hero h1 em {
    font-style: normal;
    color: var(--primary);
    display: inline-block;
}
.apex-hero__lead {
    font-size: 1.15rem;
    line-height: 2;
    color: #c8c8c8;
    max-width: 640px;
    margin-bottom: 42px;
}
.apex-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}
.apex-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: 4px;
    transition: all 0.3s;
    border: 1.5px solid transparent;
    cursor: pointer;
}
.apex-btn span { transition: transform 0.3s; }
.apex-btn:hover span { transform: translate(3px, -3px); }
.apex-btn--gold {
    background: var(--primary);
    color: #0c0c0c !important;
    border-color: var(--primary);
}
.apex-btn--gold:hover {
    background: var(--primary-light);
    border-color: var(--primary-light);
    transform: translateY(-3px);
}
.apex-btn--ghost {
    background: transparent;
    color: #fff !important;
    border-color: rgba(255,255,255,0.25);
}
.apex-btn--ghost:hover {
    border-color: var(--primary);
    color: var(--primary) !important;
    transform: translateY(-3px);
}
.apex-hero__meta {
    position: absolute;
    bottom: 40px;
    left: 0; right: 0;
    z-index: 2;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 28px;
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    letter-spacing: 0.3em;
    color: #777;
    text-transform: uppercase;
}
.apex-scroll {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    color: #999;
    font-size: 0.7rem;
    letter-spacing: 0.35em;
    writing-mode: vertical-rl;
    text-orientation: mixed;
}
.apex-scroll i {
    display: block;
    width: 1px;
    height: 50px;
    background: linear-gradient(to bottom, var(--primary), transparent);
    animation: scrollPulse 2s infinite;
}
@keyframes scrollPulse {
    0%, 100% { transform: scaleY(0.5); opacity: 0.5; }
    50% { transform: scaleY(1); opacity: 1; }
}

/* ---------------- INTRO ---------------- */
.apex-intro { background: #0c0c0c; }
.apex-intro__grid {
    display: grid;
    grid-template-columns: auto 1.2fr 1fr;
    gap: 60px;
    align-items: start;
}
.apex-intro__title h2 {
    font-size: clamp(1.6rem, 3vw, 2.6rem);
    line-height: 1.35;
    margin: 0;
}
.apex-intro__title h2 strong {
    color: var(--primary);
    font-weight: 700;
}
.apex-intro__copy p {
    color: #a8a8a8;
    font-size: 1rem;
    line-height: 2;
    margin-bottom: 20px;
}
.apex-intro__copy p strong { color: #fff; }
.apex-text-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--primary) !important;
    font-weight: 700;
    font-size: 0.95rem;
    margin-top: 10px;
    border-bottom: 1px solid transparent;
    padding-bottom: 3px;
}
.apex-text-link:hover {
    border-bottom-color: var(--primary);
    gap: 14px;
}
.apex-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-top: 80px;
    padding-top: 50px;
    border-top: 1px solid rgba(255,255,255,0.08);
}
.apex-stats > div {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.apex-stats strong {
    font-size: 2rem;
    color: var(--primary);
    font-weight: 800;
    letter-spacing: 0.05em;
}
.apex-stats span {
    color: #999;
    font-size: 0.9rem;
}

/* ---------------- SERVICES ---------------- */
.apex-services { background: #0a0a0a; }
.apex-service-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 28px;
}
.apex-service {
    background: #121212;
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.4s, border-color 0.4s, box-shadow 0.4s;
}
.apex-service:hover {
    transform: translateY(-8px);
    border-color: rgba(245,180,0,0.35);
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}
.apex-service__visual {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #1a1a1a;
}
.apex-service__visual img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.6s;
}
.apex-service:hover .apex-service__visual img { transform: scale(1.06); }
.apex-service__number {
    position: absolute;
    top: 16px;
    left: 16px;
    background: rgba(12,12,12,0.75);
    color: var(--primary);
    font-weight: 800;
    font-size: 0.8rem;
    padding: 5px 11px;
    border-radius: 3px;
    letter-spacing: 0.15em;
    backdrop-filter: blur(6px);
}
.apex-placeholder {
    display: grid;
    place-items: center;
    width: 100%; height: 100%;
    color: #555;
    font-size: 0.8rem;
    letter-spacing: 0.3em;
}
.apex-service__body {
    padding: 26px 24px 28px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    flex: 1;
}
.apex-service__eyebrow {
    font-size: 0.7rem;
    letter-spacing: 0.28em;
    color: #666;
    margin-bottom: 6px;
    display: block;
}
.apex-service__body h3 {
    font-size: 1.25rem;
    margin: 0;
    font-weight: 700;
}
.apex-service__body h3 a { color: #fff; }
.apex-service__body h3 a:hover { color: var(--primary); }
.apex-service__body p {
    color: #9a9a9a;
    font-size: 0.92rem;
    line-height: 1.9;
    flex: 1;
    margin: 0;
}
.apex-circle-link {
    align-self: flex-start;
    width: 40px; height: 40px;
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 1rem;
    transition: all 0.3s;
}
.apex-circle-link:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #0c0c0c;
    transform: rotate(-45deg);
}

/* ---------------- WORK / PORTFOLIO ---------------- */
.apex-work { background: #0c0c0c; }
.apex-projects {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-auto-rows: 240px;
    gap: 18px;
}
.apex-project {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 8px;
    background: #161616;
    grid-column: span 3;
    grid-row: span 2;
}
.apex-project--1 { grid-column: span 3; grid-row: span 2; }
.apex-project--2 { grid-column: span 3; grid-row: span 2; }
.apex-project--3 { grid-column: span 2; grid-row: span 2; }
.apex-project--4 { grid-column: span 2; grid-row: span 2; }
.apex-project--5 { grid-column: span 2; grid-row: span 2; }
.apex-project--6 { grid-column: span 6; grid-row: span 3; }

.apex-project img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.8s;
}
.apex-project:hover img { transform: scale(1.08); }
.apex-project__shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.15) 50%, transparent 100%);
    transition: background 0.4s;
}
.apex-project__info {
    position: absolute;
    left: 24px; right: 24px; bottom: 24px;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    align-items: center;
    color: #fff;
    gap: 4px 12px;
}
.apex-project__info small {
    grid-column: 1;
    font-size: 0.72rem;
    letter-spacing: 0.25em;
    color: var(--primary);
    text-transform: uppercase;
}
.apex-project__info strong {
    grid-column: 1;
    font-size: 1.15rem;
    font-weight: 700;
}
.apex-project__info i {
    grid-column: 2;
    grid-row: 1 / span 2;
    font-style: normal;
    width: 42px; height: 42px;
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    display: grid;
    place-items: center;
    transition: all 0.3s;
}
.apex-project:hover .apex-project__info i {
    background: var(--primary);
    border-color: var(--primary);
    color: #0c0c0c;
    transform: rotate(-45deg);
}

/* ---------------- PROCESS ---------------- */
.apex-process {
    background: #0a0a0a;
    border-top: 1px solid rgba(255,255,255,0.05);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.apex-process__grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 30px 60px;
    align-items: start;
}
.apex-process__grid > div:nth-child(2) h2 {
    font-size: clamp(1.7rem, 3vw, 2.6rem);
    margin: 0;
    line-height: 1.35;
}
.apex-process__grid > div:nth-child(2) h2 em {
    font-style: normal;
    color: var(--primary);
}
.apex-process__steps {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-top: 40px;
}
.apex-process__steps > div {
    padding-top: 28px;
    position: relative;
}
.apex-process__steps span {
    display: block;
    font-size: 0.8rem;
    color: var(--primary);
    letter-spacing: 0.2em;
    margin-bottom: 14px;
    font-weight: 700;
}
.apex-process__steps h3 {
    font-size: 1.15rem;
    margin: 0 0 10px;
    font-weight: 700;
}
.apex-process__steps p {
    color: #9a9a9a;
    font-size: 0.92rem;
    line-height: 1.9;
    margin: 0;
}

/* ---------------- CONTACT ---------------- */
.apex-contact {
    background:
        radial-gradient(circle at 20% 30%, rgba(245,180,0,0.12), transparent 55%),
        radial-gradient(circle at 85% 80%, rgba(245,180,0,0.08), transparent 50%),
        #0c0c0c;
    text-align: center;
    overflow: hidden;
}
.apex-contact__texture {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
}
.apex-contact__inner { position: relative; z-index: 1; }
.apex-contact__inner h2 {
    font-size: clamp(2rem, 5vw, 4rem);
    line-height: 1.2;
    margin: 20px 0 25px;
    font-weight: 800;
}
.apex-contact__inner h2 em {
    font-style: normal;
    color: var(--primary);
}
.apex-contact__lead {
    color: #b0b0b0;
    font-size: 1.1rem;
    max-width: 560px;
    margin: 0 auto 50px;
    line-height: 2;
    text-align: center;
}
.apex-contact__actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 22px;
    margin-bottom: 60px;
}
.apex-contact__phone {
    font-size: 1.8rem;
    font-weight: 800;
    color: #fff !important;
    letter-spacing: 0.05em;
    direction: ltr;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s;
}
.apex-contact__phone:hover {
    color: var(--primary) !important;
    border-bottom-color: var(--primary);
}
.apex-contact__details {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px 40px;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.08);
    color: #888;
    font-size: 0.9rem;
}
.apex-contact__details span { position: relative; }
.apex-contact__details span:not(:last-child)::after {
    content: '·';
    position: absolute;
    left: -22px;
    color: #444;
}

/* ---------------- HOME FOOTER ---------------- */
.apex-home-footer {
    background: #060606;
    color: #999;
    border-top: 1px solid rgba(255,255,255,0.05);
}
.apex-home-footer__top { padding: 80px 0 50px; }
.apex-home-footer__grid {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 28px;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 50px;
}
.apex-home-brand--footer { margin-bottom: 22px; }
.apex-home-footer__brand p {
    color: #888;
    font-size: 0.92rem;
    line-height: 2;
    margin-bottom: 22px;
    max-width: 340px;
}
.apex-home-footer__tel {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--primary) !important;
    font-weight: 800;
    font-size: 1.15rem;
    direction: ltr;
}
.apex-home-footer__eyebrow {
    display: block;
    font-size: 0.75rem;
    letter-spacing: 0.28em;
    color: #666;
    text-transform: uppercase;
    margin-bottom: 20px;
    font-weight: 600;
}
.apex-home-footer__links { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.apex-home-footer__links a {
    color: #bbb;
    font-size: 0.92rem;
    transition: color 0.3s, padding-right 0.3s;
    display: inline-block;
}
.apex-home-footer__links a:hover {
    color: var(--primary);
    padding-right: 6px;
}
.apex-home-footer__location {
    color: #bbb;
    font-size: 0.92rem;
    line-height: 2;
    margin-bottom: 10px;
}
.apex-home-footer__address {
    color: #777;
    font-size: 0.88rem;
}
.apex-home-footer__bottom {
    max-width: 1240px;
    margin: 0 auto;
    padding: 24px 28px;
    border-top: 1px solid rgba(255,255,255,0.06);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.82rem;
    color: #666;
}
.apex-home-footer__bottom a { color: var(--primary) !important; }
.apex-home-footer__bottom a:hover { color: var(--primary-light) !important; }

/* Skip link */
.apex-skip {
    position: absolute;
    top: -100px;
    right: 20px;
    background: var(--primary);
    color: #0c0c0c;
    padding: 10px 18px;
    border-radius: 4px;
    z-index: 9999;
    font-weight: 700;
}
.apex-skip:focus { top: 20px; }

/* ---------------- RESPONSIVE (HOME) ---------------- */
@media (max-width: 1024px) {
    .apex-intro__grid { grid-template-columns: 1fr; gap: 30px; }
    .apex-section-head { grid-template-columns: 1fr; gap: 24px; }
    .apex-section-head > p { justify-self: start; max-width: none; }
    .apex-home-footer__grid { grid-template-columns: 1fr 1fr; gap: 40px; }
    .apex-process__grid { grid-template-columns: 1fr; }
    .apex-process__steps { grid-template-columns: repeat(2, 1fr); }
    .apex-stats { grid-template-columns: repeat(2, 1fr); gap: 30px; }

    .apex-home-nav { display: none; }
    .apex-mobile-menu { display: block; }
    .apex-home-header__actions { display: none; }
}

@media (max-width: 768px) {
    .apex-section { padding: 70px 0; }
    .apex-home-header { padding: 12px 0; }
    .apex-home-brand__text small { display: none; }
    .apex-hero { min-height: auto; padding: 130px 0 80px; }
    .apex-hero__meta { font-size: 0.65rem; letter-spacing: 0.2em; }
    .apex-hero__meta span:nth-child(2) { display: none; }
    .apex-scroll { display: none; }
    .apex-hero__actions { flex-direction: column; align-items: stretch; }
    .apex-btn { justify-content: center; }
    .apex-projects {
        grid-template-columns: 1fr;
        grid-auto-rows: 260px;
    }
    .apex-project,
    .apex-project--1, .apex-project--2,
    .apex-project--3, .apex-project--4,
    .apex-project--5, .apex-project--6 {
        grid-column: span 1;
        grid-row: span 1;
    }
    .apex-process__steps { grid-template-columns: 1fr; gap: 24px; }
    .apex-stats { grid-template-columns: 1fr 1fr; }
    .apex-stats strong { font-size: 1.5rem; }
    .apex-contact__details {
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }
    .apex-contact__details span::after { display: none; }
    .apex-home-footer__grid { grid-template-columns: 1fr; gap: 34px; }
    .apex-home-footer__bottom { flex-direction: column; text-align: center; }
    .apex-section-index { font-size: 0.75rem; }
}

@media (max-width: 480px) {
    .apex-container { padding: 0 18px; }
    .apex-hero__content { padding: 0 18px; }
    .apex-hero__meta { padding: 0 18px; }
    .apex-home-header__inner { padding: 0 18px; }
    .apex-home-footer__grid { padding: 0 18px; }
    .apex-home-footer__bottom { padding: 20px 18px; }
}

/* ==========================================================================
   ★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★
   APEX HEADER & MENU — ماژول یکپارچه (دسکتاپ + موبایل + زیرمنو)
   ★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★
   ========================================================================== */

:root {
    --apex-gold: #f5b400;
    --apex-gold-light: #ffd54f;
    --apex-gold-dark: #d99a00;
    --apex-dark: #0c0c0c;
    --apex-dark-2: #141414;
    --apex-line: rgba(255, 255, 255, 0.08);
    --apex-header-h: 76px;
}

/* ---------- شِل هدر ---------- */
.apex-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 999;
    background: rgba(12, 12, 12, 0.85);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--apex-line);
    transition: background 0.3s;
}
.archive-header , .about-hero , .contact-hero , .single-header{
    margin-top: var(--apex-header-h);
}
.apex-header.is-scrolled { background: rgba(12, 12, 12, 0.97); }
.apex-header__inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 28px;
    height: var(--apex-header-h);
    display: flex;
    align-items: center;
    gap: 28px;
}

/* ---------- برند ---------- */
.apex-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}
.apex-brand__mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    overflow: hidden;
    background: rgba(245, 180, 0, 0.08);
    border: 1px solid rgba(245, 180, 0, 0.25);
}
.apex-brand__mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.apex-brand__text {
    display: flex; align-items: baseline; gap: 4px;
    line-height: 1; white-space: nowrap;
}
.apex-brand__text strong { font-weight: 800; font-size: 1.15rem; color: #fff; }
.apex-brand__text small {
    font-size: 0.6rem; letter-spacing: 0.22em;
    color: #777; align-self: center;
}

/* ---------- ناوبری دسکتاپ ---------- */
.apex-nav__list {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
    margin: 0; padding: 0;
}
.apex-nav__list > li { position: relative; }

.apex-nav__list > li > a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    color: #ccc !important;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 6px;
    transition: color 0.25s, background 0.25s;
}
.apex-nav__list > li > a:hover,
.apex-nav__list > li > a:focus-visible {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.05);
}
.apex-nav__list > li.current-menu-item > a,
.apex-nav__list > li.current-menu-ancestor > a {
    color: var(--apex-gold) !important;
}

.apex-nav__list > li.menu-item-has-children > a::after {
    content: '';
    width: 6px; height: 6px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform 0.3s;
}
.apex-nav__list > li.menu-item-has-children.is-open > a::after {
    transform: rotate(-135deg) translateY(-2px);
}

.apex-nav__list .sub-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 230px;
    background: var(--apex-dark-2);
    border: 1px solid var(--apex-line);
    border-radius: 10px;
    padding: 8px;
    list-style: none;
    margin: 0;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
    z-index: 20;
    /* فاصله از آیتم والد با padding ایجاد می‌شود، نه margin */
    padding-top: 12px;
}

/* پل نامرئی بین آیتم اصلی و زیرمنو */
.apex-nav__list > li.menu-item-has-children > .sub-menu::before {
    content: '';
    position: absolute;
    top: -12px;
    left: 0;
    right: 0;
    height: 12px;
    background: transparent;
}

.apex-nav__list > li:hover > .sub-menu,
.apex-nav__list > li:focus-within > .sub-menu,
.apex-nav__list > li.is-open > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.apex-nav__list .sub-menu li { position: relative; }

.apex-nav__list .sub-menu a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 6px 14px!important;
    color: #ddd !important;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 6px;
    white-space: nowrap;
    transition: background 0.2s, color 0.2s, padding 0.2s;
}
.apex-nav__list .sub-menu a:hover,
.apex-nav__list .sub-menu a:focus-visible {
    background: rgba(245, 180, 0, 0.12);
    color: var(--apex-gold) !important;
    padding-inline-start: 18px;
}

/* ---------- زیرمنوهای چندسطحی (سطح 3 به بعد) ---------- */
.apex-nav__list .sub-menu .sub-menu {
    top: -8px !important;
    right: 100% !important;
    margin-right: 0 !important;
    padding-top: 8px !important;
    padding-right: 6px !important; /* پل سمت راست به جای margin */
}

/* پل نامرئی سمت راست زیرمنوی عمقی */
.apex-nav__list .sub-menu li.menu-item-has-children > .sub-menu::before {
    content: '';
    position: absolute;
    top: 0;
    right: -12px;
    width: 12px;
    height: 100%;
    background: transparent;
}

/* نمایش زیرمنوهای چندسطحی در دسکتاپ */
.apex-nav__list .sub-menu li > .sub-menu {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(6px);
    z-index: 30 !important;
}
.apex-nav__list .sub-menu li:hover > .sub-menu,
.apex-nav__list .sub-menu li:focus-within > .sub-menu,
.apex-nav__list .sub-menu li.is-open > .sub-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.apex-nav__list .sub-menu li.menu-item-has-children > a {
    position: relative;
    padding-left: 28px;
}
.apex-nav__list .sub-menu li.menu-item-has-children > a::after {
    content: '';
    position: absolute;
    left: 12px;
    top: 50%;
    width: 6px;
    height: 6px;
    border-left: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: translateY(-50%) rotate(45deg);
}

/* ---------- اکشن‌های دسکتاپ ---------- */
.apex-header__actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
    margin-inline-start: auto;
}
.apex-header__phone {
    color: #ddd !important;
    font-size: 0.9rem;
    font-weight: 600;
    direction: ltr;
    text-decoration: none;
    transition: color 0.25s;
}
.apex-header__phone:hover { color: var(--apex-gold) !important; }

.apex-header__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--apex-gold);
    color: #0c0c0c !important;
    font-weight: 700;
    font-size: 0.88rem;
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.25s, transform 0.25s;
}
.apex-header__cta:hover {
    background: var(--apex-gold-light);
    transform: translateY(-2px);
}
.apex-header__cta svg {
    width: 14px; height: 14px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    transition: transform 0.3s;
}
.apex-header__cta:hover svg { transform: translate(3px, -3px); }

/* ---------- دکمه همبرگری ---------- */
.apex-burger {
    display: none;
    width: 44px; height: 44px;
    background: transparent;
    border: 1px solid var(--apex-line);
    border-radius: 8px;
    cursor: pointer;
    padding: 0;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    transition: border-color 0.25s, background 0.25s;
    -webkit-tap-highlight-color: transparent;
}
.apex-burger:hover {
    border-color: rgba(245, 180, 0, 0.5);
    background: rgba(245, 180, 0, 0.06);
}
.apex-burger span {
    display: block;
    width: 20px; height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}
.apex-burger--dark span { background: #1a1a1a; }
.apex-burger.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.apex-burger.is-active span:nth-child(2) { opacity: 0; }
.apex-burger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ==========================================================================
   MOBILE DRAWER
   ========================================================================== */
.apex-mobile {
    position: fixed !important;
    inset: 0 !important;
    z-index: 100000 !important;
    pointer-events: none;
    visibility: hidden;
}
.apex-mobile.is-open {
    pointer-events: auto !important;
    visibility: visible !important;
}

.apex-mobile__backdrop {
    position: absolute !important;
    inset: 0 !important;
    background: rgba(0, 0, 0, 0.7) !important;
    opacity: 0;
    transition: opacity 0.3s;
    cursor: pointer;
}
.apex-mobile.is-open .apex-mobile__backdrop { opacity: 1; }

.apex-mobile__panel {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    height: 100% !important;
    width: min(380px, 88vw) !important;
    background: #0f0f0f !important;
    display: flex !important;
    flex-direction: column !important;
    transform: translateX(100%);
    transition: transform 0.35s ease;
    overflow: hidden !important;
}
.apex-mobile.is-open .apex-mobile__panel { transform: translateX(0) !important; }

.apex-mobile__head {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 18px 20px !important;
    border-bottom: 1px solid rgba(255,255,255,0.08) !important;
    flex-shrink: 0 !important;
}
.apex-mobile__close {
    width: 40px !important;
    height: 40px !important;
    display: grid !important;
    place-items: center !important;
    background: transparent !important;
    border: 1px solid rgba(255,255,255,0.15) !important;
    border-radius: 8px !important;
    color: #fff !important;
    cursor: pointer !important;
    padding: 0 !important;
}
.apex-mobile__close svg {
    width: 18px !important;
    height: 18px !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    fill: none !important;
}

.apex-mobile__nav {
    flex: 1 !important;
    overflow-y: auto !important;
    padding: 12px !important;
}

/* ---------- لیست منوی موبایل ---------- */
.apex-mobile__list,
ul.apex-mobile__list {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
}
.apex-mobile__list li,
.apex-mobile__list ul li {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}
.apex-mobile__list > li {
    position: relative !important;
}

.apex-mobile__list > li > a {
    display: block !important;
    padding: 14px 16px !important;
    padding-left: 60px !important;
    color: #e6e6e6 !important;
    font-size: 1rem !important;
    font-weight: 500 !important;
    text-align: right !important;
    text-decoration: none !important;
    border-radius: 8px !important;
    transition: background 0.2s, color 0.2s;
}
.apex-mobile__list > li > a:hover {
    background: rgba(245, 180, 0, 0.12) !important;
    color: #f5b400 !important;
}

/* ---------- زیرمنو ---------- */
.apex-mobile__list .sub-menu,
.apex-mobile__list ul.sub-menu {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    max-height: 0 !important;
    overflow: hidden !important;
    transition: max-height 0.4s ease !important;
    background: transparent !important;
    position: static !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    box-shadow: none !important;
    border: none !important;
    width: auto !important;
    min-width: 0 !important;
}
.apex-mobile__list li.is-open > .sub-menu,
.apex-mobile__list li.is-open > ul.sub-menu {
    max-height: 1000px !important;
}

.apex-mobile__list .sub-menu a,
.apex-mobile__list ul.sub-menu a {
    display: block !important;
    padding: 12px 16px 12px 24px !important;
    color: #bbb !important;
    font-size: 0.9rem !important;
    text-align: right !important;
    text-decoration: none !important;
    border-right: 2px solid rgba(245, 180, 0, 0.3) !important;
    margin: 2px 12px 2px 0 !important;
    border-radius: 0 6px 6px 0 !important;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.apex-mobile__list .sub-menu a:hover,
.apex-mobile__list ul.sub-menu a:hover {
    background: rgba(245, 180, 0, 0.1) !important;
    color: #f5b400 !important;
    border-right-color: #f5b400 !important;
}

/* ---------- دکمه زیرمنو ---------- */
.apex-mobile__list .submenu-toggle {
    position: absolute !important;
    top: 8px !important;
    left: 8px !important;
    right: auto !important;
    width: 38px !important;
    height: 38px !important;
    display: grid !important;
    place-items: center !important;
    background: rgba(255,255,255,0.06) !important;
    border: 1px solid rgba(255,255,255,0.15) !important;
    border-radius: 8px !important;
    color: #fff !important;
    cursor: pointer !important;
    padding: 0 !important;
    z-index: 5 !important;
}
.apex-mobile__list .submenu-toggle svg {
    width: 14px !important;
    height: 14px !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    fill: none !important;
    transition: transform 0.3s !important;
}
.apex-mobile__list li.is-open > .submenu-toggle {
    background: #f5b400 !important;
    border-color: #f5b400 !important;
    color: #0c0c0c !important;
}
.apex-mobile__list li.is-open > .submenu-toggle svg {
    transform: rotate(180deg) !important;
}

/* ---------- فوتر منو ---------- */
.apex-mobile__foot {
    padding: 16px 20px !important;
    border-top: 1px solid rgba(255,255,255,0.08) !important;
    background: rgba(0,0,0,0.3) !important;
    flex-shrink: 0 !important;
}
.apex-mobile__call {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    padding: 14px !important;
    background: #f5b400 !important;
    color: #0c0c0c !important;
    font-weight: 800 !important;
    font-size: 1rem !important;
    text-decoration: none !important;
    border-radius: 8px !important;
}
.apex-mobile__call svg {
    width: 16px !important;
    height: 16px !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    fill: none !important;
}

body.apex-menu-open { overflow: hidden !important; }

/* ---------- رسپانسیو ---------- */
@media (max-width: 1024px) {
    .apex-nav,
    .apex-header__actions { display: none !important; }

    .apex-burger {
        display: flex !important;
        margin-inline-start: auto !important;
    }
}

@media (min-width: 1025px) {
    .apex-mobile { display: none !important; }
}

/* ==========================================================================
   APEX MOBILE MENU FIX — final overrides
   Keeps the drawer and its WordPress menu above page content and visible.
   ========================================================================== */
.apex-header { z-index: 100000 !important; }
.apex-header__inner { position: relative; }
.apex-burger { position: relative; z-index: 100002 !important; }
.apex-mobile {
    display: block !important;
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100dvh !important;
    z-index: 100001 !important;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}
.apex-mobile.is-open {
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}
.apex-mobile__backdrop {
    position: absolute !important;
    inset: 0 !important;
    z-index: 0 !important;
}
.apex-mobile__panel {
    position: absolute !important;
    z-index: 1 !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    height: 100% !important;
    max-height: 100dvh !important;
    width: min(390px, 90vw) !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
    background: #0f0f0f !important;
    color: #fff !important;
    visibility: visible !important;
}
.apex-mobile__nav {
    display: block !important;
    flex: 1 1 auto !important;
    min-height: 0 !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    padding: 12px 14px 24px !important;
}
.apex-mobile__nav > ul,
.apex-mobile__list,
ul.apex-mobile__list {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    visibility: visible !important;
    opacity: 1 !important;
    overflow: visible !important;
    position: static !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}
.apex-mobile__list > li,
.apex-mobile__list li {
    display: block !important;
    position: relative !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    list-style: none !important;
}
.apex-mobile__list > li > a {
    display: block !important;
    min-height: 48px;
    color: #f2f2f2 !important;
    visibility: visible !important;
    opacity: 1 !important;
}
.apex-mobile__list .sub-menu,
.apex-mobile__list ul.sub-menu {
    display: block !important;
    position: static !important;
    float: none !important;
    width: 100% !important;
    max-height: 0 !important;
    height: auto !important;
    overflow: hidden !important;
    visibility: visible !important;
    opacity: 1 !important;
    transform: none !important;
    margin: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
}
.apex-mobile__list li.is-open > .sub-menu,
.apex-mobile__list li.is-open > ul.sub-menu {
    max-height: 2000px !important;
    padding-bottom: 8px !important;
}
.apex-mobile__list .sub-menu li,
.apex-mobile__list .sub-menu a {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}
.apex-mobile__head,
.apex-mobile__foot { position: relative; z-index: 2; }
body.apex-menu-open {
    overflow: hidden !important;
    touch-action: none;
}
@media (min-width: 1025px) {
    .apex-mobile { display: none !important; }
}
@media (max-width: 1024px) {
    .apex-nav,
    .apex-header__actions { display: none !important; }
    .apex-burger { display: flex !important; }
}

/* ==========================================================================
   APEX SOCIAL ICONS — رنگی به‌صورت پیش‌فرض
   ========================================================================== */
.apex-socials {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 22px;
    flex-wrap: wrap;
}

/* ---- استایل پایه ---- */
.apex-social {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #fff !important;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    border: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease, filter 0.3s ease;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}

.apex-social svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
    stroke-width: 1.7;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.3s ease;
    position: relative;
    z-index: 1;
}

/* درخشش ملایم روی آیکون */
.apex-social::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255,255,255,0.25), rgba(255,255,255,0) 55%);
    opacity: 0.6;
    pointer-events: none;
    transition: opacity 0.3s;
}

.apex-social:hover {
    transform: translateY(-4px) scale(1.05);
    filter: brightness(1.12);
}
.apex-social:hover svg { transform: scale(1.12); }
.apex-social:hover::after { opacity: 0.9; }

/* ---- اینستاگرام (گرادیانت رسمی) ---- */
.apex-social--instagram {
    background: linear-gradient(135deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    box-shadow: 0 6px 18px rgba(220, 39, 67, 0.4);
}
.apex-social--instagram:hover {
    box-shadow: 0 12px 28px rgba(220, 39, 67, 0.55);
}

/* ---- تلگرام ---- */
.apex-social--telegram {
    background: linear-gradient(135deg, #2aabee 0%, #229ed9 100%);
    box-shadow: 0 6px 18px rgba(42, 171, 238, 0.4);
}
.apex-social--telegram:hover {
    box-shadow: 0 12px 28px rgba(42, 171, 238, 0.55);
}

/* ---- واتساپ ---- */
.apex-social--whatsapp {
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    box-shadow: 0 6px 18px rgba(37, 211, 102, 0.4);
}
.apex-social--whatsapp:hover {
    box-shadow: 0 12px 28px rgba(37, 211, 102, 0.55);
}

/* focus برای دسترس‌پذیری */
.apex-social:focus-visible {
    outline: 2px solid var(--apex-gold, #f5b400);
    outline-offset: 3px;
}

/* ---- ریسپانسیو ---- */
@media (max-width: 768px) {
    .apex-socials {
        gap: 8px;
        margin-top: 18px;
        justify-content: flex-start;
    }
    .apex-social {
        width: 40px;
        height: 40px;
        border-radius: 10px;
    }
    .apex-social svg {
        width: 20px;
        height: 20px;
    }
}

/* =========================================================
   FOOTER LATEST POSTS — آخرین مقالات در فوتر
   ========================================================= */
.apex-home-footer__posts {
    gap: 4px !important;
    margin-bottom: 18px;
    padding: 0;
    list-style: none;
}

.apex-footer-post {
    position: relative;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: border-color 0.3s;
}
.apex-footer-post:last-child {
    border-bottom: none;
}

.apex-footer-post__link {
    display: flex !important;
    align-items: center;
    gap: 10px;
    padding: 10px 0 !important;
    color: #bbb !important;
    font-size: 0.88rem !important;
    line-height: 1.7;
    text-decoration: none;
    transition: color 0.3s, padding-right 0.3s;
    border-bottom: none !important;
}

.apex-footer-post__link:hover {
    color: var(--primary) !important;
    padding-right: 6px !important;
}

.apex-footer-post__arrow {
    display: grid;
    place-items: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(245,180,0,0.1);
    border: 1px solid rgba(245,180,0,0.2);
    flex-shrink: 0;
    transition: all 0.3s;
}
.apex-footer-post__arrow svg {
    width: 10px;
    height: 10px;
    stroke: var(--primary);
    stroke-width: 2.2;
    fill: none;
    transition: transform 0.3s;
}
.apex-footer-post__link:hover .apex-footer-post__arrow {
    background: var(--primary);
    border-color: var(--primary);
}
.apex-footer-post__link:hover .apex-footer-post__arrow svg {
    stroke: #0c0c0c;
    transform: rotate(-45deg);
}

.apex-footer-post__title {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
}

.apex-footer-post--empty {
    color: #666;
    font-size: 0.85rem;
    padding: 10px 0;
    border-bottom: none !important;
}

/* دکمه «همه مقالات» */
.apex-footer-posts-more {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    color: var(--primary) !important;
    font-weight: 700;
    font-size: 0.85rem !important;
    text-decoration: none;
    padding: 0 !important;
    transition: gap 0.3s;
}
.apex-footer-posts-more svg {
    width: 12px;
    height: 12px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    transition: transform 0.3s;
}
.apex-footer-posts-more:hover {
    gap: 10px;
    color: var(--primary-light) !important;
}
.apex-footer-posts-more:hover svg {
    transform: translate(3px, -3px);
}

/* ---------- ریسپانسیو ---------- */
@media (max-width: 768px) {
    .apex-home-footer__posts {
        align-items: center;
    }
    .apex-footer-post__link {
        justify-content: center;
        text-align: center;
        padding: 12px 0 !important;
    }
    .apex-footer-post__title {
        text-align: right;
    }
    .apex-footer-posts-more {
        justify-content: center;
    }
}