:root {
    --primary-color: #5f27cd;
    --primary-light: #341f97;
    --bale-color: #00a884;
    --dark-color: #222f3e;
    --light-bg: #f8f9fa;
    --border-color: #e2e8f0;
    --text-muted: #576574;
    --container-max: 1100px;
}

* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Vazirmatn', sans-serif; }
html { -webkit-text-size-adjust: 100%; }
body { background-color: var(--light-bg); color: var(--dark-color); line-height: 1.8; overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }

/* ---------- هدر مشترک ---------- */
header { background-color: #ffffff; box-shadow: 0 2px 10px rgba(0,0,0,0.05); position: sticky; top: 0; z-index: 1000; }
.nav-container { max-width: var(--container-max); margin: 0 auto; display: flex; justify-content: space-between; align-items: center; padding: 15px 20px; gap: 12px; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 10px; font-size: 22px; font-weight: bold; color: var(--primary-color); }
.logo-mark { width: 35px; height: 35px; background-color: var(--primary-color); border-radius: 6px; display: flex; align-items: center; justify-content: center; color: white; font-weight: bold; }
.nav-links { display: flex; list-style: none; gap: 20px; font-weight: 500; }
.nav-links a { transition: color 0.3s; padding: 4px 2px; }
.nav-links a:hover, .nav-links a.active { color: var(--primary-color); font-weight: bold; }

.header-btns { display: flex; gap: 10px; }
.btn-cta { background-color: var(--primary-color); color: white; padding: 8px 16px; border-radius: 8px; font-weight: bold; font-size: 14px; transition: background 0.3s; display: inline-block; }
.btn-cta:hover { background-color: var(--primary-light); }
.btn-bale { background-color: var(--bale-color); color: white; padding: 8px 16px; border-radius: 8px; font-weight: bold; font-size: 14px; transition: opacity 0.3s; display: inline-block; }
.btn-bale:hover { opacity: 0.9; }

/* دکمه همبرگر موبایل */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 6px; color: var(--primary-color); }
.nav-toggle span { display: block; width: 26px; height: 3px; background: var(--primary-color); border-radius: 2px; margin: 5px 0; transition: 0.3s; }

/* ---------- هیرو ---------- */
.hero { background: linear-gradient(135deg, #5f27cd 0%, #341f97 100%); color: white; text-align: center; padding: 70px 20px; }
.hero-inner { max-width: 800px; margin: 0 auto; }
.hero h1 { font-size: clamp(22px, 4.5vw, 32px); margin-bottom: 15px; line-height: 1.5; }
.hero p { font-size: clamp(14px, 2.4vw, 17px); opacity: 0.9; }

/* ---------- لایه و کارت‌ها ---------- */
.container { max-width: var(--container-max); margin: 40px auto; padding: 0 20px; min-height: calc(100vh - 400px); width: 100%; }
.card { background: white; border-radius: 12px; padding: 35px; box-shadow: 0 4px 15px rgba(0,0,0,0.04); margin-bottom: 30px; }
.section-title { text-align: center; margin-bottom: 35px; }
.section-title h2, h1.page-title { font-size: clamp(20px, 3.6vw, 26px); color: var(--primary-color); display: inline-block; }
.section-title h2::after, h1.page-title::after { content: ''; display: block; width: 50%; height: 3px; background-color: var(--primary-color); margin: 8px auto 0; border-radius: 2px; }

/* ---------- کارت ویژگی‌ها + تصویر ---------- */
.feature-card { background: white; border-radius: 12px; padding: 30px; margin-bottom: 40px; box-shadow: 0 4px 15px rgba(0,0,0,0.04); }
.feature-text h3 { color: var(--primary-color); margin-bottom: 12px; font-size: clamp(18px, 3vw, 22px); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.feature-text p { color: var(--text-muted); font-size: 15px; margin-bottom: 15px; text-align: justify; }
.feature-text ul { padding-right: 20px; color: var(--dark-color); font-size: 14px; margin-bottom: 25px; }
.feature-text li { margin-bottom: 6px; }

/* قاب تصویر - کلید اصلی رفع مشکل تصاویر بزرگ */
.img-placeholder-full {
    background-color: #f1f3f5;
    border: 2px dashed #cbd5e1;
    border-radius: 8px;
    width: 100%;
    /* نسبت تصویر ثابت برای جلوگیری از خراب شدن layout؛ با تغییر سایز صفحه، قاب هم‌شکل باقی می‌ماند */
    aspect-ratio: 16 / 9;
    max-height: 520px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: var(--text-muted);
    text-align: center;
    padding: 20px;
    margin-top: 15px;
    overflow: hidden;
    position: relative;
}
/* وقتی تصویر واقعی داخل قاب قرار می‌گیرد، استایل placeholder حذف می‌شود */
.img-placeholder-full.has-image {
    background-color: #ffffff;
    border-style: solid;
    border-color: var(--border-color);
    padding: 0;
    aspect-ratio: auto;
    max-height: 600px;
}
.img-placeholder-full.has-image .ph-icon,
.img-placeholder-full.has-image .ph-title { display: none; }
.img-placeholder-full img {
    width: 100%;
    height: 100%;
    max-height: 600px;
    object-fit: contain;       /* تصویر بزرگ، بدون برش، در قاب جا می‌گیرد */
    object-position: center;
    display: block;
}
.ph-icon { font-size: 48px; margin-bottom: 10px; }
.ph-title { font-size: 14px; line-height: 1.8; }

/* ---------- فرم تماس ---------- */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; margin-top: 20px; }
input, textarea { width: 100%; padding: 12px; margin-bottom: 15px; border: 1px solid var(--border-color); border-radius: 8px; outline: none; font-family: inherit; font-size: 14px; }
input:focus, textarea:focus { border-color: var(--primary-color); }
.btn-submit { background: var(--primary-color); color: white; border: none; padding: 12px; border-radius: 8px; width: 100%; font-weight: bold; cursor: pointer; transition: 0.3s; font-family: inherit; font-size: 14px; }
.btn-submit:hover { opacity: 0.9; }

/* ---------- کارت تعرفه ---------- */
.pricing { text-align: center; }
.pricing .muted { color: var(--text-muted); margin-bottom: 15px; }
.pricing .price-title { color: var(--primary-color); font-size: clamp(16px, 2.8vw, 20px); margin-bottom: 20px; }
.pricing-btns { display: flex; gap: 10px; justify-content: center; margin-top: 20px; flex-wrap: wrap; }

/* ---------- فوتر ---------- */
footer { background-color: var(--dark-color); color: white; padding: 40px 20px 20px; margin-top: 60px; }
.footer-container { max-width: var(--container-max); margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 30px; padding-bottom: 30px; border-bottom: 1px solid #334155; }
.footer-col h4 { margin-bottom: 15px; color: #a5b4fc; font-size: 16px; }
.footer-col p { margin-bottom: 8px; font-size: 14px; color: #cbd5e1; }
.enamad-box { background-color: white; padding: 15px; border-radius: 8px; text-align: center; min-height: 100px; display: flex; align-items: center; justify-content: center; color: var(--dark-color); }
.copyright { text-align: center; padding-top: 20px; font-size: 14px; color: #94a3b8; }

/* ===================== ریسپانسیو ===================== */

/* تبلت */
@media (max-width: 992px) {
    .container { max-width: 95%; }
    .feature-card { padding: 25px; }
    .card { padding: 25px; }
}

/* موبایل بزرگ */
@media (max-width: 768px) {
    .nav-container { flex-direction: row; justify-content: space-between; padding: 12px 16px; }
    .nav-links { display: none; }
    .header-btns { display: none; }
    .nav-toggle { display: block; }

    /* حالت باز شدن منو در موبایل */
    header.menu-open .nav-links,
    header.menu-open .header-btns {
        display: flex;
        flex-direction: column;
        width: 100%;
        align-items: stretch;
        gap: 8px;
        padding: 12px 0 4px;
    }
    header.menu-open .nav-container { flex-direction: column; align-items: stretch; gap: 6px; }
    header.menu-open .nav-links a { padding: 8px 4px; border-bottom: 1px solid var(--border-color); }
    header.menu-open .header-btns .btn-cta,
    header.menu-open .header-btns .btn-bale { text-align: center; padding: 12px; font-size: 15px; }

    .hero { padding: 50px 16px; }
    .container { margin: 25px auto; padding: 0 14px; }
    .feature-card, .card { padding: 20px; margin-bottom: 25px; }
    .feature-text ul { padding-right: 18px; }
    .img-placeholder-full { aspect-ratio: 4 / 3; min-height: 220px; }
    .img-placeholder-full.has-image { max-height: 450px; }
    .img-placeholder-full img { max-height: 450px; }
    .ph-icon { font-size: 36px; }
    .ph-title { font-size: 13px; }
    .pricing-btns { flex-direction: column; }
    .pricing-btns .btn-cta,
    .pricing-btns .btn-bale { width: 100%; }
}

/* موبایل کوچک */
@media (max-width: 480px) {
    .logo { font-size: 18px; }
    .logo-mark { width: 30px; height: 30px; font-size: 14px; }
    .hero { padding: 40px 14px; }
    .feature-text h3 { font-size: 17px; }
    .feature-text p, .feature-text li { font-size: 14px; }
    .img-placeholder-full { aspect-ratio: 1 / 1; min-height: 200px; }
    .img-placeholder-full.has-image { max-height: 380px; }
    .img-placeholder-full img { max-height: 380px; }
    .copyright { font-size: 12px; }
}