/* =================================================================== */
/* 1. تعریف فونت‌ها */
/* =================================================================== */
@font-face {
    font-family: 'BYekan';
    src: url('../fonts/BYekan.eot');
    src: url('../fonts/BYekan.eot?#iefix') format('embedded-opentype'),
         url('../fonts/BYekan.woff') format('woff'),
         url('../fonts/BYekan.ttf') format('truetype');
    font-weight: normal;
}

@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn-Regular.woff2') format('woff2'); 
    /* اگر فونت وزیر لوکال دارید، مسیر آن را جایگزین کنید */
}

@font-face {
    font-family: 'FontAwesome';
    src: url('../fonts/fontawesome-webfont.woff?v=4.7.0') format('woff');
    font-weight: normal;
}

.fa {
    display: inline-block;
    font: normal normal normal 14px/1 FontAwesome;
}

/* =================================================================== */
/* 2. تنظیمات کلی و ریست */
/* =================================================================== */
* {
    box-sizing: border-box;
}

body {
    background-color: #fdfcf5; /* کرم ملایم */
    color: #444;
    font-family: 'BYekan', 'Vazirmatn', sans-serif;
    margin: 0;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    line-height: 1.6;
}

/* =================================================================== */
/* 3. کادر اصلی فرم */
/* =================================================================== */
.container {
    background-color: #ffffff;
    width: 100%;
    max-width: 450px;
    border-radius: 20px; /* گوشه‌های گرد کادر اصلی */
    box-shadow: 0 10px 30px rgba(107, 142, 35, 0.15); /* سایه سبز طبیعی */
    border: 1px solid #f0ebd8;
    overflow: hidden;
}

/* هدر سبز رنگ */
.form-header {
    background: linear-gradient(135deg, #7FA99B, #556b2f); /* گرادینت سبز */
    color: #fff;
    padding: 25px 20px;
    text-align: center;
    border-bottom: 4px solid #eae2c6;
}

.form-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: bold;
}

.form-body {
    padding: 30px 25px;
}

/* =================================================================== */
/* 4. استایل اینپوت‌ها (اصلاح گوشه‌ها) */
/* =================================================================== */
label {
    color: #556b2f;
    font-weight: bold;
    font-size: 13px;
    margin-bottom: 8px;
    display: block;
}

/* استایل پایه تمام ورودی‌ها */
input[type="text"], 
input[type="password"], 
input[type="tel"], 
input[type="number"] {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 20px;
    border: 2px solid #e6e6e6;
    border-radius: 12px; /* گوشه‌های کاملاً گرد و نرم */
    background-color: #fafafa;
    font-family: 'Vazirmatn', 'BYekan', sans-serif;
    font-size: 14px;
    transition: all 0.3s ease;
    outline: none;
    -webkit-appearance: none; /* حذف استایل پیش‌فرض موبایل */
}

/* حالت فوکوس (زمانی که کلیک می‌شود) */
input:focus {
    border-color: #8fbc8f; /* سبز ملایم */
    background-color: #fff;
    box-shadow: 0 4px 10px rgba(143, 188, 143, 0.15);
}

/* --- اصلاح ویژه برای اینپوت ایمیل (چسبیده به دامین) --- */
.email-container {
    display: flex;
    direction: ltr; /* چپ‌چین اجباری برای انگلیسی */
    margin-bottom: 20px;
}

.email-container input {
    margin-bottom: 0;
    border-radius: 12px 0 0 12px !important; /* فقط سمت چپ گرد شود */
    border-right: none; /* خط راست حذف شود تا به بج بچسبد */
}

.domain-badge {
    background: #eae6da;
    color: #555;
    padding: 0 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e6e6e6;
    border-left: none;
    border-radius: 0 12px 12px 0; /* فقط سمت راست گرد شود */
    font-family: 'Vazirmatn', monospace;
    font-size: 14px;
    white-space: nowrap;
}

/* استایل فیلد رمز عبور */
.password-wrapper {
    position: relative;
    margin-bottom: 20px;
}

.password-wrapper input {
    margin-bottom: 0;
    padding-left: 45px; /* جا برای آیکون چشم */
}

.toggle-password {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #88a088;
    font-size: 18px;
    z-index: 10;
}

/* =================================================================== */
/* 5. استایل کارت‌های انتخاب پلن */
/* =================================================================== */
.section-title {
    font-size: 15px;
    border-bottom: 1px dashed #ccc;
    padding-bottom: 8px;
    margin-bottom: 15px;
    color: #333;
}

.plan-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.plan-card {
    background: #fff;
    border: 2px solid #f0f0f0;
    border-radius: 12px;
    padding: 10px;
    width: 48%; /* دو ستون در دسکتاپ */
    cursor: pointer;
    transition: all 0.2s;
    text-align: right;
    position: relative;
}

.plan-card:hover {
    border-color: #8fbc8f;
    background-color: #f9fff9;
}

.plan-card.active {
    border-color: #556b2f;
    background-color: #f0f7e6; /* سبز خیلی روشن */
    box-shadow: 0 3px 8px rgba(85, 107, 47, 0.2);
}

.plan-card input { display: none; }

.plan-title {
    font-weight: bold;
    display: block;
    font-size: 12px;
    color: #333;
    margin-bottom: 4px;
}

.plan-price {
    font-size: 11px;
    color: #556b2f;
    font-weight: bold;
}

/* =================================================================== */
/* 6. دکمه‌ها و باکس‌های دیگر */
/* =================================================================== */
.duration-box {
    background: #fdfdf5;
    border: 1px dashed #dcd0b0;
    padding: 12px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 13px;
}

.total-price-box {
    background: #556b2f;
    color: #fff;
    padding: 12px;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 25px;
    font-weight: bold;
    font-size: 16px;
    box-shadow: 0 4px 10px rgba(85, 107, 47, 0.2);
}

.btn-submit {
    width: 100%;
    padding: 14px;
    background: linear-gradient(to right, #6b8e23, #556b2f);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    box-shadow: 0 5px 15px rgba(107, 142, 35, 0.3);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(107, 142, 35, 0.4);
}

.alert {
    padding: 12px;
    background-color: #ffe6e6;
    color: #cc0000;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #ffcccc;
    text-align: center;
    font-size: 13px;
}

/* کلاس کمکی برای چپ‌چین کردن اعداد */
.ltr-input {
    direction: ltr !important;
    text-align: left !important;
    letter-spacing: 1px;
    font-weight: bold;
}
.ltr-input::placeholder {
    text-align: right;
    direction: rtl;
    font-weight: normal;
    letter-spacing: 0;
}

.back-link {
    display: block;
    text-align: center;
    margin-top: 15px;
    color: #777;
    text-decoration: none;
    font-size: 13px;
}

/* حالت موبایل */
@media screen and (max-width: 600px) {
    .plan-card { width: 100%; }
    .container { 
        border-radius: 0; 
        box-shadow: none; 
        border: none; 
        max-width: 100%;
    }
    body { padding: 0; background: #fff; }
}