/* ============================================
   HERO SECTION STYLES - MODERN REDESIGN
   ============================================ */

.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg,
            var(--primary-lighter) 0%,
            var(--bg-primary) 50%,
            var(--primary-lighter) 100%);
    margin-top: 20px;
    padding: 0 0 30px 0;
    position: relative;
    overflow: hidden;
}

/* Animated background elements */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 80%, rgba(107, 142, 35, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(154, 205, 50, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(107, 142, 35, 0.05) 0%, transparent 50%);
    animation: backgroundFloat 20s ease-in-out infinite;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-content {
    animation: slideInLeft 1s ease-out;
}

.hero-section .hero-content .hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin: 50px 0 1.5rem 0;
    color: var(--primary-color) !important;
    line-height: 1.2;
    font-weight: 700;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.3s both;
    text-align: left !important;
    letter-spacing: 0.5px;
}

/* RTL alignment for Arabic and other RTL languages */
body.rtl .hero-section .hero-content .hero-title {
    text-align: right !important;
}

.hero-section .hero-content .hero-title .hero-brand {
    color: transparent !important;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 800;
    position: relative;
    display: inline-block;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.hero-title .hero-brand::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 2px;
    animation: expandWidth 1.5s ease-out 0.8s both;
}

.hero-title .hero-brand:hover {
    transform: scale(1.02);
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

body.rtl .hero-brand::after {
    left: auto;
    right: 0;
    background: linear-gradient(270deg, var(--primary-color), var(--primary-light));
    animation: expandWidthRTL 1.5s ease-out 0.8s both;
}

@keyframes expandWidthRTL {
    from {
        width: 0;
    }

    to {
        width: 80px;
    }
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-weight: 600;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.3s both;
}

.hero-description {
    font-size: clamp(1rem, 2vw, 1.1rem);
    margin-bottom: 2.5rem;
    color: var(--text-secondary);
    line-height: 1.8;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.6s both;
}

.hero-buttons {
    display: flex;
    justify-content: flex-start;
    gap: 1.5rem;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.9s both;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--white);
    box-shadow: 0 8px 25px rgba(107, 142, 35, 0.3);
    border: 2px solid transparent;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(107, 142, 35, 0.4);
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    position: relative;
}

.btn-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(107, 142, 35, 0.1), transparent);
    transition: left 0.5s;
}

.btn-secondary:hover::before {
    left: 100%;
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(107, 142, 35, 0.3);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
    animation: slideInRight 1s ease-out;
    position: relative;
}

.hero-icon {
    width: 320px;
    height: 360px;
    opacity: 0.9;
    animation: float 6s ease-in-out infinite;
    filter: drop-shadow(0 20px 40px var(--shadow-primary));
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.hero-icon:hover {
    transform: scale(1.05) rotate(5deg);
    filter: drop-shadow(0 25px 50px var(--shadow-medium));
}

/* Floating elements around the logo */
.hero-image::before,
.hero-image::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    opacity: 0.3;
    animation: floatAround 8s ease-in-out infinite;
}

.hero-image::before {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.hero-image::after {
    bottom: 20%;
    right: 10%;
    animation-delay: 4s;
}

/* Hero Animations */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-60px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(60px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

@keyframes expandWidth {
    from {
        width: 0;
    }

    to {
        width: 80px;
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
    }

    33% {
        transform: translateY(-15px) rotate(1deg);
    }

    66% {
        transform: translateY(-8px) rotate(-1deg);
    }
}

@keyframes floatAround {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    25% {
        transform: translate(20px, -20px) scale(1.2);
    }

    50% {
        transform: translate(0, -40px) scale(1);
    }

    75% {
        transform: translate(-20px, -20px) scale(0.8);
    }
}

@keyframes backgroundFloat {

    0%,
    100% {
        transform: translate(0, 0) rotate(0deg);
    }

    33% {
        transform: translate(-10px, -10px) rotate(1deg);
    }

    66% {
        transform: translate(10px, -5px) rotate(-1deg);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        margin-top: 70px;
        padding-top: 0;
    }

    .hero-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: left;
    }

    /* RTL alignment for container */
    body.rtl .hero-container {
        text-align: right;
    }

    .hero-title {
        text-align: left;
    }

    .hero-section .hero-content .hero-title {
        font-size: clamp(2rem, 4.5vw, 3rem);
        text-align: left !important;
    }

    /* RTL alignment for mobile */
    body.rtl .hero-section .hero-content .hero-title {
        text-align: right !important;
    }

    .hero-section .hero-content .hero-title .hero-brand::after {
        left: 0;
        transform: none;
        width: 80%;
    }

    .hero-buttons {
        justify-content: flex-start;
    }

    /* RTL alignment for buttons */
    body.rtl .hero-buttons {
        justify-content: flex-end;
    }

    .hero-icon {
        width: 250px;
        height: 280px;
    }

    .hero-image::before,
    .hero-image::after {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero-section {
        margin-top: 65px;
        padding-top: 0;
        min-height: 90vh;
    }

    .hero-title {
        font-size: clamp(2rem, 4.5vw, 3rem);
        text-align: left !important;
    }

    /* RTL alignment for mobile */
    body.rtl .hero-title {
        text-align: right !important;
    }

    .hero-section .hero-content .hero-title .hero-brand::after {
        left: 0;
        transform: none;
        width: 80%;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }

    .hero-icon {
        width: 200px;
        height: 220px;
    }
}

@media (max-width: 360px) {
    .hero-section .hero-content .hero-title {
        font-size: clamp(1.6rem, 4vw, 2.2rem);
        text-align: left !important;
    }

    /* RTL alignment for small mobile */
    body.rtl .hero-section .hero-content .hero-title {
        text-align: right !important;
    }

    .hero-section .hero-content .hero-title .hero-brand::after {
        width: 80px;
        left: 0;
        transform: none;
    }
}

.hero-download {
    display: flex;
    gap: 1.5rem;
    margin-top: 2.5rem;
    justify-content: flex-start;
    align-items: center;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeInUp 1s ease-out 1.2s both;
}

/* RTL alignment for download section */
body.rtl .hero-download {
    justify-content: flex-end;
}

.hero-download-title {
    margin-top: 2.2rem;
    margin-bottom: 0.7rem;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: 0.01em;
    opacity: 0;
    animation: fadeInUp 1s ease-out 1.1s both;
}

.hero-download-sub {
    margin-bottom: 1.1rem;
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    opacity: 0;
    animation: fadeInUp 1s ease-out 1.15s both;
}

body.dark-mode .store-badge {
    box-shadow: 0 0 0 0 var(--primary-color), 0 8px 32px 0 rgba(107, 142, 35, 0.35);
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-radius: 10px;
    transition: box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1), background 0.3s, color 0.3s;
}

body.dark-mode .store-badge.playstore-badge:hover {
    background: #232e3a;
    color: var(--primary-light);
    box-shadow: 0 0 0 0 var(--primary-color), 0 12px 48px 0 rgba(107, 142, 35, 0.45);
}

.store-badge {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    background: var(--bg-primary);
    border-radius: 10px;
    box-shadow: 0 2px 12px var(--shadow-light);
    padding: 0.7rem 1.3rem;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1.05rem;
    transition: transform 0.18s, box-shadow 0.18s, background 0.18s;
    min-width: 160px;
    min-height: 56px;
    position: relative;
}

.store-badge img {
    width: 32px;
    height: 32px;
    margin-right: 0.5rem;
}

.store-badge span {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
    font-size: 1.05rem;
}

.store-badge small {
    font-size: 0.85em;
    color: var(--text-secondary);
    font-weight: 400;
}

.store-badge.playstore-badge:hover {
    background: #e3f2fd;
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 6px 20px var(--shadow-medium);
    color: var(--primary-color);
}

.coming-soon {
    opacity: 0.6;
    cursor: not-allowed;
    background: var(--bg-secondary);
}

@media (max-width: 768px) {
    .hero-download {
        justify-content: flex-start;
        gap: 1rem;
    }

    /* RTL alignment for mobile download */
    body.rtl .hero-download {
        justify-content: flex-end;
    }

    .store-badge {
        min-width: 140px;
        padding: 0.7rem 1rem;
        font-size: 0.98rem;
    }

    .store-badge img {
        width: 28px;
        height: 28px;
    }
}

@media (max-width: 480px) {
    .hero-download {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.7rem;
    }

    .store-badge {
        width: 100%;
        justify-content: flex-start;
        min-width: 0;
    }

    .hero-download-title {
        margin-top: 1.5rem;
        font-size: 1.05rem;
    }
}