﻿:root {
    --bg: #f6f8fa;
    --card: #ffffff;
    --accent: #429c81;
    --muted: #6b7280;
    --radius: 12px;
    --white: #fff;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body, html {
    height: 100%;
    width: 100%;
    font-family: sans-serif;
    background: var(--accent);
    color: #111827;
}

body {
    display: flex;
    align-items: flex-start; /* از بالا شروع شود */
    justify-content: center; /* مرکز افقی */
    min-height: 100vh;
    padding: 40px 16px; /* فاصله از بالای صفحه */
    background: var(--accent);
    overflow-y: auto; /* وقتی فرم طولانی شد اسکرول فعال باشد */
}

.card {
    background: var(--card);
    border-radius: var(--radius);
    padding: 28px 24px;
    box-shadow: 0 6px 30px rgba(0,0,0,0.08);
    width: 100%;
    max-width: 380px;
    text-align: center;
    margin: 0 auto; /* مرکز افقی */
}


/* کارت فرم */
form {
    background: var(--card);
    border-radius: var(--radius);
    padding: 28px 24px;
    box-shadow: 0 6px 30px rgba(0,0,0,0.08);
    width: 100%;
    max-width: 380px;
    text-align: center;
    position: relative;
}

/* لوگوی بالا */
.logowhite {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 28px;
    margin: 0 auto 16px;
    box-shadow: 0 4px 14px rgba(11,102,255,0.3);
}

/* تیتر فرم */
h1.btn-bg {
    margin-bottom: 24px;
    font-size: 20px;
}

/* فیلدها */
.field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 14px;
}

label {
    font-size: 14px;
}

input, select, textarea {
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    font-size: 15px;
    outline: none;
    width: 100%;
}

    input:focus, select:focus, textarea:focus {
        border-color: var(--accent);
        box-shadow: 0 0 0 3px rgba(11,102,255,0.15);
    }

/* دکمه */
button {
    margin-top: 8px;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: var(--accent);
    color: #fff;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    width: 100%;
}

    button:active {
        transform: translateY(1px);
    }

/* لینک‌ها */
.links {
    margin-top: 12px;
    display: flex;
    justify-content: space-between;
    font-size: 13px;
}

    .links a {
        color: var(--accent);
        text-decoration: none;
    }

/* پیام خطا */
.alert {
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 16px;
    text-align: center;
    font-weight: 500;
}

    .alert.error {
        background: #f87171;
        color: #7f1d1d;
        box-shadow: 0 4px 12px rgba(248, 113, 113, 0.3);
    }

/* loader */
#loader {
    display: flex;
    justify-content: center;
    align-items: center;
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(233,249,243,1) 18%, rgba(170,236,212,1) 45%, #34a886 75%, #127759 100%);
    box-shadow: 0 8px 24px rgba(18,119,89,0.14);
    z-index: 9999;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

    #loader.hidden {
        opacity: 0;
        visibility: hidden;
    }

    #loader > div.logo {
        background-color: transparent !important;
    }

.logo img {
    /*width: 70%;*/
    height: auto;
    animation: blink 0.3s infinite alternate;
}

@keyframes blink {
    from {
        opacity: 1;
    }

    to {
        opacity: 0.2;
    }
}

/* ستاره ضروری */
.star::after {
    content: " *";
    color: red;
    font-weight: bold;
    margin-right: 2px;
}

/* جهت متن لور/ریچ */
.ltr {
    direction: ltr !important;
}
label{
    direction:rtl;
    text-align:right;
}

.alert.info {
    background: #D1FAE5; /* سبز خیلی روشن برای زمینه */
    color: #065F46; /* سبز تیره برای متن */
    box-shadow: 0 4px 12px rgba(6, 95, 70, 0.2);
    border-radius: 8px;
    padding: 12px 16px;
    font-size: 14px;
    margin-bottom: 16px;
    text-align: center;
    font-weight: 500;
}

.mgbt10{
    margin-bottom:20px !important;
}
