/* General Styles */
body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: Arial, sans-serif;
    background-color: #000;
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    overflow: hidden;
}

.container {
    position: relative;
    z-index: 1;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.typed-text {
    font-size: 1.5rem;
    white-space: nowrap;
    overflow: hidden;
    border-right: 2px solid #fff;
    animation: typing 3s steps(14, end), blink-caret 0.75s step-end infinite;
}

/* Typing Animation */
@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

/* Cursor Blinking Animation */
@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: #fff; }
}

/* Background Image Animation */
@keyframes fadeInBackground {
    from { opacity: 0; }
    to { opacity: 1; }
}

.background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://about.shahinamani.ir/new-year/404/16.jpg'); /* Replace with your green background image */
    background-size: auto 100%;
    background-position: center;
    opacity: 0;
    animation: fadeInBackground 1s ease-in-out 3s forwards; /* Delay until after typing */
    z-index: 0;
}

/* Link Styles */
.link {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1rem;
    color: #fff;
    text-decoration: none;
    opacity: 0;
    animation: fadeInLink 1s ease-in-out 4s forwards; /* Delay until after background */
    z-index: 2;
}

.link:hover {
    text-decoration: underline;
}

/* Link Fade-In Animation */
@keyframes fadeInLink {
    from { opacity: 0; }
    to { opacity: 1; }
}