/* ----------------------------- */
/*          فونت‌ها             */
/* ----------------------------- */

@font-face {
    font-family: "BBadr";
    src: url("../fonts/BBadr.woff") format("truetype");
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: "Doran";
    src: url("../fonts/Doran-Bold.woff") format("truetype");
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: "Nazanin";
    src: url("../fonts/B Nazanin.woff") format("truetype");
    font-weight: normal;
    font-style: normal;
}


html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;      /* قطع اسکرول */
    overscroll-behavior: none; /* جلوگیری از کش‌آمدن */
}


/* ----------------------------- */
/*          عمومی                */
/* ----------------------------- */
* {
    box-sizing: border-box;
}

body {
    background-color: #000;
    margin: 0;
    font-family: "BBadr";
    direction: rtl;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    justify-content: center;
    align-items: center;
}

#back {
    filter: blur(2px);
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    max-width: 450px;
    width: 100%;
    object-fit: fill;
    height: 100%;
    z-index: -1;
}

/* ----------------------------- */
/*          هدر و فوتر           */
/* ----------------------------- */
header,
footer {
    font-family: "Doran";
    width: 100%;
    max-width: 420px;
    margin: auto;
    color: #ebd1b6;
    text-align: center;
    padding: 20px 16px;
    font-size: 20px;
}

header {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 420px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 2px solid #ebd1b6;
    background: transparent;
    z-index: 10;
    height: 90px;
}

.l1 {
    font-size: 16px;
}

header span {
    margin-left: 10px;
}

footer {
    justify-content: center;
    text-align: center;
    font-size: 16px;
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 420px;
    display: flex;
    align-items: center;
    padding: 8px 0;
    border-top: 2px solid #ebd1b6;
    background: transparent;
    z-index: 10;
    height: 70px;
}

footer a {
    font-family: "Doran";          /* فونت هدر */
    color: #ebd1b6;                /* هم‌رنگ هدر */
    text-decoration: none;         /* حذف استایل لینک */
    border: 2px solid #ebd1b6;     /* بوردر */
    border-radius: 14px;           /* گوشه گرد */
    padding: 6px 18px;
    background: transparent;       /* بدون رنگ داخل */
    font-size: 16px;
    transition: 0.3s ease;
    margin-bottom: 5px;
}


.phone {
    font-family: "Nazanin";
    font-size: 18px;
}

/* ----------------------------- */
/*          کانتینر و کارت       */
/* ----------------------------- */
.container {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 95%;
    margin: auto;
}

.card {
    position: fixed;
    display: flex;
    flex-direction: column;
    width: 90%;
    max-width: 420px;
    top: 100px;
    bottom: 80px;     /* دقیقا بالای فوتر */
    left: 50%;
    /*height: calc(100vh - 130px - 60px*2);*/
    background: rgba(44, 40, 41, 0.8);
    border-radius: 18px;
    padding: 20px;
    font-family: "BBadr";
    overflow: hidden; /* overflow روی کارت اصلی خاموش */
    transform: translateX(-50%);

}

/* wrapper داخلی برای محتوا */
.card-inner {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-height: 100%;
    margin: auto 0; /* وقتی محتوا کم است، وسط قرار می‌گیرد */
    overflow-y: auto; /* وقتی محتوا زیاد است اسکرول فعال شود */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE 10+ */
}

/* پنهان کردن اسکرول در Chrome, Edge, Safari */
.card-inner::-webkit-scrollbar {
    display: none;
}

/* ----------------------------- */
/*          لوگو و پس‌زمینه      */
/* ----------------------------- */
#logo {
    width: 120px;
    margin-right: 20px;
}

#hekayat {
    width: 100px;
    margin-left: 20px;
}

#poster {
    margin: auto;
    box-shadow: 0px 2px 10px 0px #555;
    width: 100%;
    max-width: 250px;
    border-radius: 30px;
}

/* ----------------------------- */
/*          عنوان و پیام          */
/* ----------------------------- */
.title {
    text-align: center;
    font-size: 20px;
    color: #c4e2c0;
    letter-spacing: 3px;
    margin-bottom: 12px;
}

.message {
    line-height: 1.3;
    padding: 5px;
    min-height: 52px;
    margin-bottom: 26px;
    font-size: 22px;
    color: #ebd1b6;
    text-align: center;
}

/* ----------------------------- */
/*          استپ‌ها               */
/* ----------------------------- */
.step {
    display: none;
    animation: fadeSlide 0.6s ease forwards;
}

.step.active {
    display: block;
}

@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ----------------------------- */
/*          تذکرات              */
/* ----------------------------- */
#attentionmessage {
    font-size: 22px;
    line-height: 1.2;
    color: #fff;
    width: 90%;
    margin: auto;
    text-align: center;
}

/* ----------------------------- */
/*          دکمه موافقم          */
/* ----------------------------- */
.check-box {
    margin: auto;                  /* وسط کارت */
    width: 20%;                     /* عرض مشخص */
    border: 1px solid #efe;
    color: #efe;
    border-radius: 12px;
    padding: 8px 12px;
    margin-bottom: 12px;           /* فاصله با دکمه‌ها پایین */
    display: flex;
    justify-content: space-between; /* فاصله متن و تیک */
    align-items: center;
    cursor: pointer;
    transition:
        border-color 0.25s ease,
        color 0.25s ease,
        box-shadow 0.25s ease,
        transform 0.15s ease;
    outline: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

/* حالت فعال */
.check-box.active {
    border-color: #d4af37;
    color: #d4af37;
    box-shadow: 0 0 10px rgba(212,175,55,0.4);
}

/* افکت کلیک */
.check-box:active {
    transform: scale(0.96);
}

/* ----------------------------- */
/*          تیک کوچک              */
/* ----------------------------- */
.check-box .day-check {
    opacity: 0;
    transform: scale(0.6);
    transition: 0.2s ease;
}

.check-box.active .day-check {
    opacity: 1;
    transform: scale(1);
}

/* ----------------------------- */
/*          دکمه ادامه غیرفعال    */
/* ----------------------------- */

#accept:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

/* ----------------------------- */
/*          انیمیشن ورود          */
/* ----------------------------- */
@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* استفاده در استپ‌ها */
.step {
    display: none;
    animation: fadeSlide 0.6s ease forwards;
}

.step.active {
    display: block;
}


/* ----------------------------- */
/*          اینپوت‌ها             */
/* ----------------------------- */
input {
    width: 100%;
    padding: 12px 14px;
    margin-bottom: 14px;
    background: #0f0f0f;
    border: 1px solid #2c2c2c;
    border-radius: 10px;
    color: #fff;
}

.input-box {
    position: relative;
    margin-bottom: 18px;
}

.input-box input {
    width: 100%;
    padding: 14px 12px;
    border: 1px solid #c4e2c0;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0);
    color: #c4e2c0;
    font-size: 16px;
}

.input-box input:focus {
    outline: none;
    border-color: #d4af37;
}

.input-box label {
    position: absolute;
    top: 14px;
    right: 12px;
    color: #aaa;
    font-size: 16px;
    pointer-events: none;
    transition: all 0.2s ease-out;
    padding: 0 4px;
}

.input-box input:focus + label,
.input-box input:not(:placeholder-shown) + label {
    top: -24px;
    font-size: 16px;
    color: #d4af37;
}

/* حذف فلش‌ها در number */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

/* ----------------------------- */
/*          input-number          */
/* ----------------------------- */
.input-number {
    position: relative;
    width: 100%;
    display: flex;
    align-items: center;
    margin-bottom: 18px;
    gap: 6px;
}

.input-number .btn {
    top: 4px;
    position: absolute;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
    transition: 0.2s;
}

.btn-minus {
    left: -20px;
}
.btn-plus {
    left: 20px;
}

.input-number .btn:hover {
    transform: scale(1.05);
}

.input-number input {
    width: 100%;
    height: 44px;
    padding: 0 12px 0 96px;
    border: 1px solid #c4e2c0;
    border-radius: 10px;
    background: rgba(0,0,0,0);
    color: #c4e2c0;
    font-size: 16px;
    appearance: textfield;
}

/* ----------------------------- */
/*          دکمه‌ها               */
/* ----------------------------- */
button {
    /*box-shadow: 0px 0px 15px 0px #000;*/
    font-family: "Doran";
    font-weight: bold;
    font-size: 16px;
    width: 40%;
    float: left;
    margin-left: 8%;
    padding: 12px;
    border-radius: 10px;
    background: #9e6935;
    color: #ebd1b6;
    border: none;
    cursor: pointer;
    margin-bottom: 20px;
}

#start {
    margin: 20px auto;
    float: none;
}

/* ----------------------------- */
/*          انتخاب روز             */
/* ----------------------------- */
.day-box {
    font-size: 18px;
    border: 1px solid #efe;
    color: #efe;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    cursor: pointer;
    transition: 0.3s;
    outline: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.day-box:focus {
    outline: none;
}

.day-box.active {
    border-color: #d4af37;
    color: #d4af37;
}

.day-check {
    display: flex;
    align-items: center;
    opacity: 0;
    transition: 0.3s;
}

.day-box.active .day-check {
    opacity: 1;
}

/* ----------------------------- */
/*          کد نهایی              */
/* ----------------------------- */
.code-box {
    text-align: center;
    font-size: 36px;
    color: #d4af37;
    letter-spacing: 8px;
    margin-top: 20px;
    user-select: none;
}

/* ----------------------------- */
/*          خوش‌آمدگویی           */
/* ----------------------------- */
.welcome-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.welcome-step h2 {
    color: #c4e2c0;
    margin-bottom: 20px;
}

.welcome-step button {
    margin-top: 20px;
}

/* ----------------------------- */
/*          بخش اتصال             */
/* ----------------------------- */
.conect {
    text-align: left;
}

.conect img {
    position: relative;
    top: 40px;
}

.conect span {
    margin-left: 30px;
}


