/* =========================================================
   ARIAN NOTICE SYSTEM
   هماهنگ با طراحی اصلی سایت
========================================================= */

/* ---------- Admin Notice Page ---------- */

.notice-admin-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 20px;
    margin-bottom: 18px;
    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.05);
}

.notice-admin-head {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 20px;
}

.notice-admin-icon {
    width: 50px;
    height: 50px;
    border-radius: 14px;
    background: #fff3e5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.notice-admin-head h3 {
    margin: 0 0 4px;
    font-size: 17px;
    font-weight: 800;
    color: var(--text);
}

.notice-admin-head p {
    margin: 0;
    color: var(--gray);
    font-size: 12px;
}

/* فرم */

.notice-form label {
    display: block;
    margin: 0 0 7px;
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
}

.notice-form .input {
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 15px;
}

.notice-textarea {
    min-height: 120px;
    resize: vertical;
    line-height: 1.9;
}

/* تاریخ */

.notice-date-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.notice-date-input {
    height: 50px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 13px;
    background: #fafafa;
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: .2s ease;
}

.notice-date-input:focus-within {
    border-color: var(--orange);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(255, 140, 26, .08);
}

.notice-date-input input {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    background: transparent;
    font-family: inherit;
    font-size: 13px;
    color: var(--text);
    text-align: right;
}

.notice-date-input input::placeholder {
    color: #aaa;
}

.notice-date-help {
    color: var(--gray);
    font-size: 11px;
    margin: -4px 2px 15px;
}

.notice-date-help strong {
    color: var(--orange);
}

/* پیام سیستم */

.notice-alert {
    border-radius: 12px;
    padding: 11px 13px;
    margin-bottom: 15px;
    font-size: 12px;
    font-weight: 600;
}

.notice-alert-success {
    background: #edf9f1;
    color: #1b9b49;
    border: 1px solid #d7f0df;
}

.notice-alert-error {
    background: #fff0f0;
    color: #d32f2f;
    border: 1px solid #ffd8d8;
}

/* لیست اطلاعیه */

.notice-list-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.notice-list-title h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 800;
}

.notice-list-title span {
    background: #fff3e5;
    color: var(--orange-dark);
    border-radius: 20px;
    padding: 5px 9px;
    font-size: 11px;
    font-weight: 700;
}

.notice-admin-item {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 15px;
    padding: 14px;
    margin-bottom: 11px;
    transition: .2s ease;
}

.notice-admin-item:hover {
    border-color: #ffd6ad;
    box-shadow: 0 5px 15px rgba(0,0,0,.04);
}

.notice-item-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.notice-item-top h3 {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 800;
}

.notice-item-icon {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    background: #fff3e5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.notice-status {
    display: inline-block;
    border-radius: 20px;
    padding: 4px 8px;
    font-size: 10px;
    font-weight: 700;
}

.notice-status.is-active {
    background: #edf9f1;
    color: #1b9b49;
}

.notice-status.is-off {
    background: #fff0f0;
    color: #d32f2f;
}

.notice-item-message {
    background: var(--bg);
    border-radius: 11px;
    padding: 10px 12px;
    margin: 12px 0;
    color: #666;
    font-size: 12px;
    line-height: 1.9;
    white-space: pre-wrap;
    word-break: break-word;
}

.notice-item-dates {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.notice-item-dates div {
    background: #fff8f1;
    border-radius: 10px;
    padding: 8px 10px;
}

.notice-item-dates span {
    display: block;
    color: #999;
    font-size: 10px;
    margin-bottom: 3px;
}

.notice-item-dates strong {
    color: var(--text);
    font-size: 12px;
}

.notice-item-actions {
    display: flex;
    gap: 8px;
    margin-top: 11px;
}

.notice-action {
    flex: 1;
    text-align: center;
    text-decoration: none;
    border-radius: 10px;
    padding: 9px;
    font-size: 11px;
    font-weight: 700;
    transition: .2s ease;
}

.notice-toggle {
    background: #fff3e5;
    color: var(--orange-dark);
}

.notice-delete {
    background: #fff0f0;
    color: #d32f2f;
}

.notice-action:hover {
    transform: translateY(-1px);
}

.notice-empty {
    text-align: center;
    padding: 35px 15px;
    color: var(--gray);
}

.notice-empty div {
    font-size: 34px;
    margin-bottom: 7px;
}

.notice-empty h3 {
    margin: 0 0 5px;
    color: var(--text);
    font-size: 15px;
}

.notice-empty p {
    margin: 0;
    font-size: 12px;
}


/* =========================================================
   STORE POPUP
========================================================= */

.arian-notice-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 18px;
    box-sizing: border-box;

    background: rgba(20, 20, 20, .65);

    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);

    animation: noticeOverlayIn .22s ease;
}

.arian-notice-modal {
    position: relative;

    width: 100%;
    max-width: 430px;
    max-height: 85vh;

    overflow-y: auto;

    box-sizing: border-box;

    background: #fff;

    border-radius: 22px;

    padding: 28px 21px 20px;

    text-align: center;

    box-shadow:
        0 20px 60px rgba(0,0,0,.25);

    animation: noticeModalIn .25s ease;
}

/* خط نارنجی بالای پنجره */

.arian-notice-modal::before {
    content: "";

    position: absolute;
    top: 0;
    left: 0;
    right: 0;

    height: 4px;

    border-radius: 22px 22px 0 0;

    background: linear-gradient(
        90deg,
        var(--orange-dark),
        var(--orange)
    );
}

/* دکمه × */

.arian-notice-close {
    position: absolute;

    top: 12px;
    left: 12px;

    width: 32px;
    height: 32px;

    border: none;
    border-radius: 50%;

    background: #f5f5f5;

    color: #777;

    font-family: Arial, sans-serif;
    font-size: 23px;
    line-height: 30px;

    cursor: pointer;

    transition: .2s ease;
}

.arian-notice-close:hover {
    background: #ffe9d2;
    color: var(--orange-dark);
}

/* آیکون */

.arian-notice-badge {
    width: 66px;
    height: 66px;

    margin: 0 auto 10px;

    border-radius: 19px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: #fff3e5;

    font-size: 31px;

    box-shadow:
        0 7px 20px rgba(255,140,26,.12);
}

/* عنوان کوچک */

.arian-notice-kicker {
    color: var(--orange-dark);

    font-size: 11px;
    font-weight: 800;

    margin-bottom: 6px;
}

/* محتوای اطلاعیه */

.arian-notice-content h2 {
    margin: 0 0 10px;

    color: var(--text);

    font-size: 20px;
    font-weight: 800;
}

.arian-notice-message {
    color: #666;

    font-size: 13px;

    line-height: 2;

    text-align: right;

    white-space: pre-wrap;

    word-break: break-word;
}

/* دکمه متوجه شدم */

.arian-notice-confirm {
    width: 100%;
    height: 50px;

    margin-top: 21px;

    border: none;
    border-radius: 13px;

    background:
        linear-gradient(
            135deg,
            var(--orange),
            var(--orange-dark)
        );

    color: #fff;

    font-family: inherit;

    font-size: 14px;
    font-weight: 800;

    cursor: pointer;

    box-shadow:
        0 8px 20px rgba(255,107,0,.18);

    transition: .2s ease;
}

.arian-notice-confirm:hover {
    transform: translateY(-2px);
    box-shadow:
        0 11px 24px rgba(255,107,0,.25);
}

.arian-notice-confirm:active {
    transform: scale(.98);
}


/* =========================================================
   ANIMATION
========================================================= */

@keyframes noticeOverlayIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes noticeModalIn {
    from {
        opacity: 0;
        transform: translateY(15px) scale(.96);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.notice-closing {
    opacity: 0 !important;
    transition: opacity .18s ease;
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 520px) {

    .notice-admin-card {
        padding: 16px;
        border-radius: 16px;
    }

    .notice-date-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .notice-date-input {
        margin-bottom: 13px;
    }

    .notice-admin-head {
        margin-bottom: 17px;
    }

    .arian-notice-overlay {
        padding: 13px;
    }

    .arian-notice-modal {
        max-width: 100%;
        border-radius: 20px;
        padding: 27px 17px 17px;
    }

    .arian-notice-badge {
        width: 58px;
        height: 58px;
        border-radius: 17px;
        font-size: 28px;
    }

    .arian-notice-content h2 {
        font-size: 18px;
    }

    .arian-notice-message {
        font-size: 12px;
        line-height: 1.95;
    }

    .arian-notice-confirm {
        height: 48px;
        font-size: 13px;
    }
}
/* =========================================================
   NOTICE FORM INPUTS - FIX
========================================================= */

.notice-form .input,
.notice-form input[type="text"],
.notice-form textarea {
    width: 100%;
    box-sizing: border-box;
    display: block;

    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 13px;

    padding: 12px 14px;

    font-family: "Vazirmatn", sans-serif;
    font-size: 14px;
    color: #2d2d2d;

    outline: none;

    transition:
        border-color .2s ease,
        box-shadow .2s ease,
        background .2s ease;
}

.notice-form .input:focus,
.notice-form input[type="text"]:focus,
.notice-form textarea:focus {

    border-color: var(--orange);

    background: #fff;

    box-shadow:
        0 0 0 3px rgba(255, 140, 26, .10);
}


/* عنوان اطلاعیه */

.notice-form input[name="title"] {
    height: 52px;

    font-size: 14px;
    font-weight: 600;

    text-align: right;

    padding-right: 16px;
    padding-left: 16px;

    background: #fafafa;
}

.notice-form input[name="title"]::placeholder {
    color: #aaa;
}


/* متن اطلاعیه */

.notice-form textarea[name="message"],
.notice-textarea {
    min-height: 135px;

    padding: 13px 15px;

    resize: vertical;

    line-height: 2;

    font-size: 13px;

    text-align: right;

    background: #fafafa;
}

.notice-form textarea[name="message"]::placeholder {
    color: #aaa;
}


/* عنوان لیبل ها */

.notice-form label {
    font-family: "Vazirmatn", sans-serif;

    font-size: 13px;
    font-weight: 700;

    color: #333;

    margin-bottom: 8px;
}


/* فاصله بهتر فیلدها */

.notice-form .input,
.notice-form textarea {
    margin-bottom: 16px;
}


/* تاریخ شمسی */

.notice-jalali-input {
    width: 100%;
    height: 52px;

    box-sizing: border-box;

    border: 1px solid #e3e3e3;
    border-radius: 13px;

    background: #fafafa;

    padding: 0 14px;

    font-family: "Vazirmatn", sans-serif;
    font-size: 13px;

    color: #333;

    direction: rtl;
    text-align: right;

    outline: none;

    transition: .2s ease;
}

.notice-jalali-input:focus {
    background: #fff;

    border-color: var(--orange);

    box-shadow:
        0 0 0 3px rgba(255, 140, 26, .10);
}

.notice-jalali-input::placeholder {
    color: #aaa;
}


/* موبایل */

@media (max-width: 520px) {

    .notice-form input[name="title"] {
        height: 50px;
        font-size: 13px;
    }

    .notice-form textarea[name="message"],
    .notice-textarea {
        min-height: 125px;
        font-size: 12px;
    }

    .notice-jalali-input {
        height: 50px;
        font-size: 12px;
    }
}