@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;700&display=swap');

:root {
    --primary-color: #007bff;
    --accent-color: #ff6f00;
    --text-color: #333;
    --light-bg: #f8f9fa;
    --dark-bg: #212529
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0
}

body {
    font-family: 'Vazirmatn', Tahoma, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    direction: rtl;
    background-color: #fff
}

a {
    text-decoration: none;
    color: var(--primary-color)
}

ul {
    list-style: none
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px)
    }
    to {
        opacity: 1;
        transform: translateY(0)
    }
}

@keyframes fadeIn {
    from {
        opacity: 0
    }
    to {
        opacity: 1
    }
}

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 50px;
    background-color: var(--dark-bg);
    color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    animation: fadeIn .5s ease-out
}

.main-header h1 {
    font-size: 24px;
    font-weight: 700
}

.main-nav ul {
    display: flex;
    gap: 30px
}

.main-nav a {
    color: #fff;
    font-weight: 400;
    transition: color .3s ease;
    padding-bottom: 5px
}

.main-nav a:hover {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color)
}

.hamburger-menu {
    display: none;
    background: 0 0;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001
}

.hamburger-menu .bar {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #fff;
    margin: 5px 0;
    transition: all .3s ease
}

.hero {
    background: url('../images/dakal-bg.jpg') no-repeat center center/cover;
    height: 500px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    isolation: isolate
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, .6);
    z-index: -1;
    animation: fadeIn 1s ease-out
}

.hero-text {
    color: #fff;
    max-width: 800px;
    animation: slideInUp .8s ease-out .2s backwards
}

.hero-text h2 {
    font-size: 48px;
    margin-bottom: 15px;
    font-weight: 700
}

.hero-text p {
    font-size: 20px;
    margin-bottom: 30px;
    opacity: .9
}

.cta-button {
    display: inline-block;
    background-color: var(--accent-color);
    color: #fff;
    padding: 12px 30px;
    border-radius: 5px;
    font-weight: 700;
    transition: background-color .3s ease, transform .2s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, .2)
}

.cta-button:hover {
    background-color: #e56300;
    transform: translateY(-2px)
}

.content-area {
    padding: 60px 50px;
    background-color: var(--light-bg);
    animation: fadeIn 1s ease-out .6s backwards
}

.news-item {
    background-color: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, .05);
    transition: transform .3s ease, box-shadow .3s ease;
    border-top: 5px solid var(--primary-color);
    animation: slideInUp .6s ease-out forwards;
    opacity: 0
}

.news-grid .news-item:nth-child(1) {
    animation-delay: .8s
}

.news-grid .news-item:nth-child(2) {
    animation-delay: 1s
}

.news-grid .news-item:nth-child(3) {
    animation-delay: 1.2s
}

.clients-section {
    padding: 60px 0;
    background-color: #fff;
    text-align: right;
    animation: fadeIn 1s ease-out 1.4s backwards;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee
}

.slider-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    overflow: hidden;
    height: 100px;
    padding: 0 40px
}

.clients-section .section-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--dark-bg);
    margin-bottom: 30px;
    padding-right: 50px;
    text-align: right
}

.clients-section .section-title::after {
    display: none
}

.clients-track {
    display: flex;
    overflow-x: hidden;
    width: 100%;
    scroll-behavior: smooth;
    white-space: nowrap
}

.client-logo-wrapper {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    padding: 10px 5px;
    height: 100px;
    width: 16.66%;
    transition: transform .3s ease;
    border-left: 1px solid #f0f0f0
}

.client-logo-wrapper:hover {
    transform: translateY(-5px)
}

.client-logo {
    max-width: 120px;
    max-height: 80px;
    width: auto;
    height: auto;
    opacity: .9;
    transition: all .4s ease;
    object-fit: contain
}

.client-logo-wrapper:hover .client-logo {
    opacity: 1;
    transform: scale(1.05)
}

.slider-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: 0 0;
    color: #999;
    border: none;
    padding: 20px 15px;
    cursor: pointer;
    font-size: 40px;
    z-index: 100;
    transition: color .3s ease, background-color .3s ease
}

.slider-control:hover {
    color: var(--primary-color);
    background-color: rgba(255, 255, 255, .7)
}

.prev-btn {
    right: 0;
    border-radius: 0 50% 50% 0
}

.next-btn {
    left: 0;
    border-radius: 50% 0 0 50%
}

.main-footer {
    background-color: var(--dark-bg);
    color: #aaa;
    padding: 30px 50px;
    text-align: center;
    border-top: 3px solid var(--primary-color)
}

.footer-content p {
    margin: 5px 0;
    font-size: 14px
}

.login-body {
    background-color: var(--dark-bg);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px
}

.login-container {
    background-color: #fff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, .4);
    width: 100%;
    max-width: 400px;
    text-align: center;
    animation: fadeIn .8s ease-out
}

.login-container h2 {
    color: var(--primary-color);
    margin-bottom: 30px;
    font-size: 28px;
    font-weight: 700
}

.login-form .form-group {
    margin-bottom: 20px;
    text-align: right
}

.login-form label {
    display: block;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-color)
}

.login-form input[type=text], .login-form input[type=password] {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color .3s;
    direction: ltr;
    text-align: left
}

.login-form input[type=text]:focus, .login-form input[type=password]:focus {
    border-color: var(--accent-color);
    outline: 0;
    box-shadow: 0 0 5px rgba(255, 111, 0, .3)
}

.login-button {
    width: 100%;
    background-color: var(--primary-color);
    color: #fff;
    padding: 12px;
    border: none;
    border-radius: 6px;
    font-size: 18px;
    cursor: pointer;
    transition: background-color .3s, transform .2s;
    font-weight: 700;
    margin-top: 10px
}

.login-button:hover {
    background-color: #0056b3;
    transform: translateY(-1px)
}

.error-message {
    color: #dc3545;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-weight: 500
}

@media (max-width: 992px) {
    .news-grid {
        grid-template-columns:repeat(2, 1fr)
    }

    .client-logo-wrapper {
        width: 25%
    }
}

@media (max-width: 768px) {
    .main-header {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 15px 20px
    }

    .hamburger-menu {
        display: block;
        position: static;
        order: -1
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background-color: var(--dark-bg);
        transition: right .3s ease;
        z-index: 1000;
        padding: 80px 20px 20px;
        box-shadow: -5px 0 15px rgba(0, 0, 0, .1)
    }

    .main-nav.active {
        right: 0
    }

    .main-nav ul {
        flex-direction: column;
        gap: 0
    }

    .main-nav li {
        border-bottom: 1px solid rgba(255, 255, 255, .1)
    }

    .main-nav a {
        display: block;
        padding: 15px 10px;
        font-size: 18px;
        border-bottom: none !important
    }

    .main-nav a:hover {
        background-color: rgba(255, 255, 255, .1);
        border-bottom: none !important
    }

    .hamburger-menu.active .bar:nth-child(1) {
        transform: rotate(45deg) translate(6px, 6px)
    }

    .hamburger-menu.active .bar:nth-child(2) {
        opacity: 0
    }

    .hamburger-menu.active .bar:nth-child(3) {
        transform: rotate(-45deg) translate(6px, -6px)
    }

    .main-header h1 {
        font-size: 20px;
        margin-right: auto;
        margin-left: 20px
    }

    .content-area {
        padding: 40px 20px
    }

    .hero {
        height: 350px
    }

    .hero-text h2 {
        font-size: 28px
    }

    .hero-text p {
        font-size: 16px
    }

    .client-logo-wrapper {
        width: 50%;
        padding: 10px 5px
    }

    .slider-container {
        padding: 0 30px
    }

    .slider-control {
        padding: 15px 10px;
        font-size: 30px
    }
}

@media (max-width: 480px) {
    .main-header h1 {
        font-size: 18px
    }

    .hero {
        height: 300px
    }

    .hero-text h2 {
        font-size: 24px
    }

    .client-logo-wrapper {
        width: 50%
    }
}
