/* تنظیمات پایه */
@font-face {
    font-family: 'IranYekan';
    src: url('/assets/iranyekanwebmedium.woff') format('woff');
    font-weight: 500; /* اگر فونت Medium است */
    font-style: normal;
    font-display: swap; /* جلوگیری از FOIT */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'IranYekan', Tahoma, sans-serif !important;
}

body {
    font-family: 'IranYekan', Tahoma, sans-serif !important;
    transition: all 0.3s ease;

    min-height: 100vh;
    background: linear-gradient(0deg,  #485143, #c4e1ff);

    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem;

    position: relative;
    overflow: hidden;
}
/* لایه متحرک روی گرادیان */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
            circle at var(--x, 50%) var(--y, 50%),
            rgba(255, 255, 255, 0.25),
            transparent 40%
    );
    pointer-events: none;
    transition: background 0.3s ease;
    mix-blend-mode: overlay; /* ترکیب رنگ با پسزمینه */
}

header {
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 3rem;
}

.site-logo {
    width: 80px;
    height: auto;
    object-fit: contain;
}

h1 {
    font-size: 2rem;
    color: #20303f;
}

/* استایل جستجو */
.search-container {
    transition: all 0.3s ease;
    width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin: 2rem 0;
}

#issnInput {
    transition: width 0.3s ease, padding 0.3s ease;
    width: 100%;
    max-width: 400px;
    padding: 1rem 1.5rem;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

#issnInput:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 0 2px #FFD700;
}

#searchBtn {
    width: 100%;
    padding: 1rem 3rem;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 1.1rem;
    cursor: pointer;

    transition: transform 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28),
    box-shadow 0.3s ease,
    font-size 0.3s ease;
    will-change: transform, box-shadow; /* بهبود Performance */
}

#searchBtn:hover {
    transform: translateY(-4px) scale(1.02); /* جذابیت بیشتر */
    box-shadow: 0 8px 12px rgba(0, 0, 0, 0.25);
}

/* انیمیشن لودینگ */
.loading-animation {
    display: flex;
    gap: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s;
}

.loader-circle {
    width: 20px;
    height: 20px;
    background: #FFD700;
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out;
}

.loader-circle:nth-child(1) { animation-delay: 0s; }
.loader-circle:nth-child(2) { animation-delay: 0.2s; }
.loader-circle:nth-child(3) { animation-delay: 0.4s; }

@keyframes bounce {
    0%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-20px);
    }
}




.center-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh; /* ارتفاع کافی برای وسطچینی */
    width: 100%;
}

.site-footer {
    margin-top: auto;
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.1);
    text-align: center;
    width: 100%;
}


@media (max-width: 515px) {
    .site-logo {
        width: 60px;
        transition: width 0.6s ease;
    }

    h1 {
        font-size: 1.5rem;
        transition: font-size 0.6s ease;
    }

    #issnInput {
        width: 90%;
        padding: 1.1rem 1.7rem;
        font-size: 1.1rem;
    }

    #searchBtn {
        width: 90%;
        padding: 1.1rem 3.2rem;
        font-size: 1.1rem;
    }
}

@media (min-width: 515px) {
    .site-logo {
        width: 80px;
        transition: width 0.6s ease;
    }

    h1 {
        font-size: 2rem;
        transition: font-size 0.6s ease;
    }
    #issnInput {
        width: 100%;
    }
    #searchBtn {
        width: 100%;
    }
}




/* افزودن انیمیشن Scale به المانهای جستجو */
@keyframes scaleIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.search-container {
    animation: scaleIn 0.5s ease-out;
}

