﻿/* =============================================================
   Login.css  —  صفحه ورود / ثبت‌نام
   تم «نارنجی صنعتی» (Industrial Orange) هم‌خانواده با MasterPage.css
   مفهوم: کارت دو‌بخشی؛ سمت راست «کارگاه» (مشکی + متر نواری نارنجی)،
          سمت چپ فرم با دکمه‌ی فیزیکی (سایه‌ی سخت).
   ============================================================= */

@font-face {
    font-family: 'Vazir';
    src: url('/Content/fonts/Vazir-Light-FD-WOL.woff') format('woff');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Vazir';
    src: url('/Content/fonts/Vazir-FD-WOL.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Vazir';
    src: url('/Content/fonts/Vazir-Medium-FD-WOL.woff') format('woff');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Vazir';
    src: url('/Content/fonts/Vazir-Bold-FD-WOL.woff') format('woff');
    font-weight: 700 900;
    font-style: normal;
    font-display: swap;
}

/* ------------------------------------------------------------
   متغیرها + بدنه
   ------------------------------------------------------------ */
body.lg-body {
    --lg-black: #111111;
    --lg-black-2: #1c1d1f;
    --lg-orange: #F4511E;
    --lg-orange-2: #FF7043;
    --lg-orange-dark: #D84315;
    --lg-orange-soft: #FDEEE8;
    --lg-steel: #45515C;
    --lg-steel-light: #E8ECEF;
    --lg-bg: #F3F5F6;
    --lg-border: #E1E6EA;
    --lg-muted: #6c7883;
    --lg-text: #1d2329;
    --lg-error: #D32F2F;
    --lg-slant: -19deg;
    margin: 0;
    height: auto;
    min-height: 100vh;
    padding: 28px 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    direction: rtl;
    background: var(--lg-bg);
    color: var(--lg-text);
    position: relative;
    overflow-x: hidden;
    line-height: 1.7;
}

.lg-body,
.lg-body * {
    font-family: 'Vazir', Tahoma, sans-serif;
    box-sizing: border-box;
}

    .lg-body a,
    .lg-body button,
    .lg-body input {
        outline: none;
        -webkit-tap-highlight-color: transparent;
    }

        .lg-body a:focus-visible,
        .lg-body button:focus-visible {
            outline: 2px solid var(--lg-orange);
            outline-offset: 3px;
        }

/* ------------------------------------------------------------
   پس‌زمینه: شبکه‌ی نقشه‌کشی + بلوک نارنجی مورب
   ------------------------------------------------------------ */
.lg-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
    background-image: linear-gradient(rgba(17, 17, 17, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(17, 17, 17, .045) 1px, transparent 1px);
    background-size: 36px 36px;
}

    .lg-bg::before {
        content: "";
        position: absolute;
        top: -10%;
        right: -14%;
        width: 30%;
        height: 120%;
        background: linear-gradient(160deg, rgba(244, 81, 30, .13), rgba(216, 67, 21, .04));
        transform: skewX(var(--lg-slant));
    }

    .lg-bg::after {
        content: "";
        position: absolute;
        bottom: -120px;
        left: -80px;
        width: 340px;
        height: 340px;
        border-radius: 50%;
        border: 38px solid rgba(69, 81, 92, .08);
    }

/* ------------------------------------------------------------
   کارت اصلی
   ------------------------------------------------------------ */
.lg-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1000px;
    min-height: 620px;
    display: grid;
    grid-template-columns: 5fr 6fr;
    background: #fff;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 44px 90px -34px rgba(17, 17, 17, .55), 0 0 0 1px rgba(17, 17, 17, .06);
    animation: lgCard .8s cubic-bezier(.2, .8, .2, 1) both;
}

    /* نوار هشدار بالای کارت */
    .lg-card::before {
        content: "";
        position: absolute;
        top: 0;
        right: 0;
        left: 0;
        height: 7px;
        z-index: 5;
        background: repeating-linear-gradient(-45deg, var(--lg-orange) 0 12px, var(--lg-black) 12px 24px);
        background-size: 33.94px 100%;
        animation: lgHazard 1.6s linear infinite;
    }

/* ------------------------------------------------------------
   پنل برند (راست)
   ------------------------------------------------------------ */
.lg-brand {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 50px 42px 100px 50px;
    color: #fff;
    overflow: hidden;
    background: radial-gradient(circle at 85% 12%, rgba(244, 81, 30, .38), transparent 46%), linear-gradient(160deg, var(--lg-black-2), var(--lg-black));
    clip-path: none;
}

.lg-gear {
    position: absolute;
    top: -90px;
    left: -70px;
    width: 300px;
    height: 300px;
    opacity: .14;
    animation: lgSpin 48s linear infinite;
    pointer-events: none;
}

    .lg-gear circle {
        fill: none;
        stroke: #fff;
    }

.lg-logo {
    position: relative;
    display: block;
    width: 92px;
    height: 92px;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 0 0 3px var(--lg-orange), 0 20px 34px -14px rgba(244, 81, 30, .7);
    transition: transform .3s cubic-bezier(.3, 1.4, .5, 1), box-shadow .3s ease;
}

    .lg-logo:hover {
        transform: rotate(-4deg) scale(1.06);
        box-shadow: 0 0 0 3px var(--lg-orange-2), 0 26px 40px -14px rgba(244, 81, 30, .85);
    }

    .lg-logo img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.lg-brand h2 {
    margin: 30px 0 12px;
    color: #fff;
    font-size: 26px;
    font-weight: 800;
    line-height: 1.8;
}

.lg-brand p {
    margin: 0 0 28px;
    max-width: 340px;
    color: rgba(255, 255, 255, .62);
    font-size: 13.5px;
    line-height: 2.1;
}

.lg-feats {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

    .lg-feats li {
        display: flex;
        align-items: center;
        gap: 14px;
        font-size: 13.5px;
        font-weight: 500;
        color: rgba(255, 255, 255, .9);
        transition: transform .25s ease;
    }

        .lg-feats li:hover {
            transform: translateX(-8px);
        }

.lg-feat-ico {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--lg-orange-2);
    background: rgba(244, 81, 30, .15);
    border: 1px solid rgba(244, 81, 30, .45);
    transition: background .25s ease, color .25s ease, transform .25s ease;
}

    .lg-feat-ico svg {
        width: 19px;
        height: 19px;
    }

.lg-feats li:hover .lg-feat-ico {
    background: var(--lg-orange);
    color: #fff;
    transform: rotate(-6deg);
}

/* متر نواری: لحظه‌ی خاص صفحه (هنگام بارگذاری باز می‌شود) */
.lg-ruler {
    position: absolute;
    right: 0;
    left: 0;
    bottom: 0;
    height: 58px;
    background-color: var(--lg-orange);
    background-image: linear-gradient(90deg, var(--lg-black) 2px, transparent 2px), linear-gradient(90deg, var(--lg-black) 2px, transparent 2px), linear-gradient(90deg, var(--lg-black) 3px, transparent 3px);
    background-size: 10px 12px, 50px 24px, 100px 38px;
    background-repeat: repeat-x;
    background-position: right top;
    box-shadow: 0 -4px 0 var(--lg-black);
    animation: lgTape 1.3s cubic-bezier(.2, .8, .2, 1) .35s both;
}

    .lg-ruler::after {
        content: "";
        position: absolute;
        top: -4px;
        bottom: 0;
        right: 0;
        width: 14px;
        background: var(--lg-black);
    }

/* ------------------------------------------------------------
   پنل فرم (چپ)
   ------------------------------------------------------------ */
.lg-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 56px 52px 40px 46px;
    background: #fff;
}

.lg-back {
    position: absolute;
    top: 26px;
    left: 24px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px 6px 10px;
    border-radius: 999px;
    background: var(--lg-steel-light);
    color: var(--lg-steel);
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    transition: background .2s ease, color .2s ease, transform .2s ease;
}

    .lg-back svg {
        width: 14px;
        height: 14px;
        transition: transform .2s ease;
    }

    .lg-back:hover {
        background: var(--lg-orange);
        color: #fff;
        text-decoration: none;
    }

        .lg-back:hover svg {
            transform: translateX(-3px);
        }

.lg-form {
    display: block;
    margin: 0;
    animation: lgForm .45s cubic-bezier(.2, .8, .2, 1) both;
}

.lg-head {
    margin-bottom: 28px;
}

.lg-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 8px;
    color: var(--lg-black);
    font-size: 25px;
    font-weight: 800;
    line-height: 1.6;
}



.lg-sub,
.lg-form .tit {
    margin: 0;
    color: var(--lg-muted);
    font-size: 13px;
    line-height: 2;
}

.lg-form .tit {
    margin-bottom: 20px;
}

/* ------------------------------------------------------------
   فیلدها (کلاس‌های box-text / error توسط JS صفحه استفاده می‌شوند)
   ------------------------------------------------------------ */
.box-text.lg-field {
    position: relative;
    display: block;
    margin: 0 0 18px;
    float: none;
    width: 100%;
}

.lg-field input {
    display: block;
    width: 100%;
    height: 58px;
    margin: 0;
    padding: 0 70px 0 50px;
    border: 2px solid var(--lg-border);
    border-radius: 12px;
    background: #fff;
    color: var(--lg-black);
    font-size: 15px;
    font-weight: 500;
    box-shadow: none;
    text-align: right;
    transition: border-color .2s ease, box-shadow .25s ease;
}

    .lg-field input:hover {
        border-color: #c9d1d8;
    }

    .lg-field input:focus {
        border-color: var(--lg-orange);
        box-shadow: 0 0 0 5px rgba(244, 81, 30, .13);
    }

    .lg-field input::placeholder {
        color: transparent;
    }

/* آیکون داخل فیلد: با فوکوس، نارنجی می‌شود */
.lg-ico {
    position: absolute;
    top: 2px;
    right: 2px;
    bottom: 2px;
    width: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px 0 0 10px;
    background: transparent;
    color: var(--lg-orange);
    transition: background .25s ease, color .25s ease;
    pointer-events: none;
}

    .lg-ico svg {
        width: 20px;
        height: 20px;
    }

.lg-field:focus-within .lg-ico {
    color: var(--lg-orange-dark);
}

/* لیبل شناور */
.lg-field label {
    position: absolute;
    top: 50%;
    right: 70px;
    margin: 0;
    padding: 0 6px;
    background: #fff;
    color: var(--lg-muted);
    font-size: 14px;
    font-weight: 400;
    line-height: 1.4;
    max-width: calc(100% - 100px);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transform: translateY(-50%);
    transform-origin: right center;
    pointer-events: none;
    transition: top .2s ease, transform .2s ease, color .2s ease;
}

.lg-field input:focus + label,
.lg-field input:not(:placeholder-shown) + label {
    top: 0;
    transform: translateY(-50%) scale(.84);
    color: var(--lg-orange-dark);
    font-weight: 700;
}

/* دکمه‌ی نمایش رمز */
.lg-eye {
    position: absolute;
    top: 50%;
    left: 10px;
    width: 38px;
    height: 38px;
    margin-top: -19px;
    padding: 0;
    border: none;
    border-radius: 10px;
    background: transparent;
    color: var(--lg-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s ease, color .2s ease;
}

    .lg-eye svg {
        width: 20px;
        height: 20px;
    }

    .lg-eye .lg-eye-off {
        display: none;
    }

    .lg-eye.is-on .lg-eye-on {
        display: none;
    }

    .lg-eye.is-on .lg-eye-off {
        display: block;
    }

    .lg-eye:hover {
        background: var(--lg-orange-soft);
        color: var(--lg-orange-dark);
    }

/* حالت خطا */
.lg-field.error input {
    border-color: var(--lg-error);
    box-shadow: 0 0 0 5px rgba(211, 47, 47, .10);
}

.lg-field.error .lg-ico {
    color: var(--lg-error);
}

.lg-field.error label {
    color: var(--lg-error);
}

.lg-field.error {
    animation: lgShake .4s ease;
}

.lg-err {
    display: none;
    margin: -4px 0 18px;
    padding: 10px 14px;
    border-radius: 10px;
    border-right: 4px solid var(--lg-error);
    background: rgba(211, 47, 47, .07);
    color: var(--lg-error);
    font-size: 12.5px;
    font-weight: 500;
    line-height: 1.9;
}

    .lg-err:empty {
        display: none !important;
    }

/* ------------------------------------------------------------
   دکمه‌ی اصلی: «فیزیکی» با سایه‌ی سخت
   ------------------------------------------------------------ */
.box-btn {
    margin: 4px 0 0;
}

    .box-btn .lg-btn {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        width: 100%;
        height: 58px;
        border: none;
        border-radius: 12px;
        overflow: hidden;
        background: var(--lg-orange);
        color: #fff;
        font-size: 16px;
        font-weight: 800;
        cursor: pointer;
        box-shadow: 0 6px 0 var(--lg-orange-dark), 0 18px 26px -12px rgba(244, 81, 30, .7);
        transform: translateY(0);
        transition: transform .15s ease, box-shadow .15s ease, background .2s ease;
    }

        .box-btn .lg-btn svg {
            width: 20px;
            height: 20px;
            transition: transform .25s ease;
        }

        /* برق عبوری روی دکمه */
        .box-btn .lg-btn::after {
            content: "";
            position: absolute;
            top: 0;
            bottom: 0;
            right: -60%;
            width: 40%;
            background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .38), transparent);
            transform: skewX(var(--lg-slant));
            transition: right .6s ease;
        }

        .box-btn .lg-btn:hover {
            background: var(--lg-orange-2);
            transform: translateY(-2px);
            box-shadow: 0 8px 0 var(--lg-orange-dark), 0 24px 32px -12px rgba(244, 81, 30, .75);
        }

            .box-btn .lg-btn:hover::after {
                right: 130%;
            }

            .box-btn .lg-btn:hover svg {
                transform: translateX(-4px);
            }

        .box-btn .lg-btn:active {
            transform: translateY(5px);
            box-shadow: 0 1px 0 var(--lg-orange-dark), 0 6px 10px -6px rgba(244, 81, 30, .6);
        }

/* جداکننده «یا» */
.lg-or {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 26px 0 16px;
    color: var(--lg-muted);
    font-size: 12px;
}

    .lg-or::before,
    .lg-or::after {
        content: "";
        flex: 1;
        height: 1px;
        background: var(--lg-border);
    }

/* دکمه/لینک ثانویه */
.lg-link,
.link-other a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    height: 48px;
    border: 2px solid var(--lg-border);
    border-radius: 12px;
    background: #fff;
    color: var(--lg-steel);
    font-size: 13.5px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: border-color .2s ease, background .2s ease, color .2s ease, transform .2s ease;
}

    .lg-link svg {
        width: 18px;
        height: 18px;
    }

    .lg-link:hover,
    .link-other a:hover {
        border-color: var(--lg-orange);
        background: var(--lg-orange-soft);
        color: var(--lg-orange-dark);
        text-decoration: none;
        transform: translateY(-2px);
    }

.link-other {
    margin-top: 18px;
}

    .link-other div {
        display: block;
    }

/* متن قوانین */
.box-gh {
    margin-top: 22px;
    color: var(--lg-muted);
    font-size: 11.5px;
    line-height: 2.1;
    text-align: center;
}

    .box-gh span {
        font-size: inherit;
    }

    .box-gh a {
        position: relative;
        margin: 0 3px;
        color: var(--lg-orange-dark);
        font-weight: 700;
        text-decoration: none;
        cursor: pointer;
    }

        .box-gh a::after {
            content: "";
            position: absolute;
            right: 0;
            left: 0;
            bottom: -1px;
            height: 2px;
            background: var(--lg-orange);
            transform: scaleX(0);
            transform-origin: right center;
            transition: transform .25s ease;
        }

        .box-gh a:hover {
            color: var(--lg-orange-dark);
            text-decoration: none;
        }

            .box-gh a:hover::after {
                transform: scaleX(1);
            }

/* ------------------------------------------------------------
   انیمیشن‌ها
   ------------------------------------------------------------ */
@keyframes lgCard {
    from {
        opacity: 0;
        transform: translateY(26px) scale(.985);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes lgTape {
    from {
        clip-path: inset(0 0 0 100%);
    }

    to {
        clip-path: inset(0 0 0 0);
    }
}

@keyframes lgHazard {
    to {
        background-position: -33.94px 0;
    }
}

@keyframes lgSpin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes lgForm {
    from {
        opacity: 0;
        transform: translateX(-18px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes lgShake {
    0%, 100% {
        transform: translateX(0);
    }

    20% {
        transform: translateX(-7px);
    }

    40% {
        transform: translateX(6px);
    }

    60% {
        transform: translateX(-4px);
    }

    80% {
        transform: translateX(3px);
    }
}

/* ------------------------------------------------------------
   ریسپانسیو
   ------------------------------------------------------------ */
@media (max-width: 900px) {
    .lg-card {
        grid-template-columns: 1fr;
        min-height: 0;
        max-width: 520px;
    }

    .lg-brand {
        clip-path: none;
        flex-direction: row;
        align-items: center;
        gap: 16px;
        padding: 30px 26px 74px;
    }

        .lg-brand p,
        .lg-feats {
            display: none;
        }

        .lg-brand h2 {
            margin: 0;
            font-size: 17px;
            line-height: 1.9;
        }

    .lg-logo {
        width: 68px;
        height: 68px;
        border-radius: 17px;
        flex: 0 0 auto;
    }

    .lg-ruler {
        height: 46px;
    }

    .lg-panel {
        padding: 56px 26px 32px;
    }

    .lg-back {
        top: 18px;
        left: 18px;
    }

    .lg-bg::before {
        width: 70%;
        right: -30%;
    }
}

@media (max-width: 420px) {
    body.lg-body {
        padding: 14px 10px;
    }

    .lg-title {
        font-size: 21px;
    }

    .lg-field input {
        height: 54px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .lg-card,
    .lg-card::before,
    .lg-ruler,
    .lg-gear,
    .lg-form,
    .lg-field.error {
        animation: none !important;
    }

    .lg-body * {
        transition: none !important;
    }
}
