:root {
    --primary-color: #1a73e8;
    --secondary-color: #34a853;
    --accent-color: #ea4335;
    --dark-color: #202124;
    --light-color: #f8f9fa;
    --gray-color: #5f6368;
    --border-color: #dadce0;
    
    /* Premium Additions */
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.2);
    --shadow-soft: 0 8px 32px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 15px 40px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Assistant', sans-serif;
    background-color: var(--light-color);
    color: var(--dark-color);
    line-height: 1.6;
    direction: rtl;
    -webkit-font-smoothing: antialiased;
}

/* Header & Top Bar */
.top-bar {
    background-color: var(--dark-color);
    color: white;
    padding: 10px 0;
    font-size: 0.9rem;
    font-weight: 600;
}

.top-bar .datetime {
    display: flex;
    align-items: center;
    gap: 20px;
}

.top-bar .social-icons a {
    color: rgba(255, 255, 255, 0.8);
    margin-right: 15px;
    font-size: 1.1rem;
    transition: var(--transition);
}

.top-bar .social-icons a:hover {
    color: white;
    transform: translateY(-2px);
}

/* Glassmorphism Navbar */
.navbar {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: var(--shadow-soft);
    padding: 0.8rem 0;
    z-index: 1030;
}

.navbar-brand {
    font-weight: 800;
    font-size: 2rem;
    color: var(--primary-color) !important;
    letter-spacing: -0.5px;
}

.navbar-brand span {
    color: var(--accent-color);
}

.nav-link {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--dark-color);
    padding: 0.5rem 1.2rem !important;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary-color);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 1.2rem;
    left: 1.2rem;
    height: 3px;
    background: var(--primary-color);
    border-radius: 3px;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.nav-link:hover::after, .nav-link.active::after {
    transform: scaleX(1);
}

.search-form {
    position: relative;
    width: 300px;
}

.search-form input {
    border-radius: 50px;
    padding-right: 45px;
    border: 1px solid var(--border-color);
    background: rgba(255,255,255,0.9);
    transition: var(--transition);
}

.search-form input:focus {
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.2);
    border-color: var(--primary-color);
}

.search-form button {
    position: absolute;
    right: 15px; /* Switched to right for RTL */
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--gray-color);
    transition: var(--transition);
}

.search-form button:hover {
    color: var(--primary-color);
}

/* News Ticker */
.news-ticker-container {
    background: white;
    border-bottom: 1px solid var(--border-color);
    padding: 8px 0;
    display: flex;
    align-items: center;
    overflow: hidden;
}
.ticker-label {
    background: var(--accent-color);
    color: white;
    padding: 4px 15px;
    border-radius: 30px;
    font-weight: 700;
    font-size: 0.9rem;
    white-space: nowrap;
    margin-left: 15px;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(234, 67, 53, 0.3);
}
.ticker-content {
    white-space: nowrap;
    animation: ticker 30s linear infinite;
    display: flex;
    gap: 30px;
}
.ticker-content:hover {
    animation-play-state: paused;
}
.ticker-item {
    color: var(--dark-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
}
.ticker-item:hover {
    color: var(--primary-color);
}
@keyframes ticker {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 550px;
    overflow: hidden;
    margin-bottom: 50px;
    border-radius: 0 0 30px 30px;
    box-shadow: var(--shadow-soft);
}

.hero-slider {
    height: 100%;
}

.hero-slide {
    height: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
    transition: background-image 0.5s ease-in-out;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.4) 50%, rgba(0,0,0,0.1) 100%);
}

.hero-content {
    position: absolute;
    bottom: 80px;
    right: 80px;
    left: 80px;
    color: white;
    z-index: 2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.hero-badge {
    background: linear-gradient(135deg, var(--accent-color), #c23321);
    color: white;
    padding: 6px 20px;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 800;
    display: inline-block;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(234, 67, 53, 0.4);
    letter-spacing: 0.5px;
}

.hero-title {
    font-size: 3.2rem;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-meta {
    display: flex;
    gap: 25px;
    font-size: 1.05rem;
    font-weight: 600;
    opacity: 0.95;
}

/* Section Headers */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 35px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.section-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--dark-color);
    position: relative;
    padding-bottom: 15px;
    margin-bottom: -16px;
    border-bottom: 4px solid var(--primary-color);
}

.view-all {
    color: var(--primary-color);
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    background: rgba(26, 115, 232, 0.05);
}

.view-all:hover {
    background: rgba(26, 115, 232, 0.1);
    transform: translateX(-5px);
}

/* Premium News Cards */
.news-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(0,0,0,0.02);
}

.news-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
}

.card-img-container {
    height: 220px;
    overflow: hidden;
    position: relative;
}

.news-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.news-card:hover img {
    transform: scale(1.08);
}

.category-badge {
    position: absolute;
    top: 15px;
    right: 15px; /* RTL logic */
    background: var(--primary-color);
    color: white;
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 800;
    z-index: 2;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.card-body {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 15px;
    line-height: 1.4;
    color: var(--dark-color);
    transition: var(--transition);
}

.news-card:hover .card-title {
    color: var(--primary-color);
}

.card-excerpt {
    color: var(--gray-color);
    font-size: 1rem;
    margin-bottom: 20px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    line-height: 1.6;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    color: var(--gray-color);
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
    padding-top: 15px;
    margin-top: auto;
    font-weight: 600;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Trending Section */
.trending-section {
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
    padding: 60px 0;
    margin: 60px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.trending-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    height: 100%;
    display: flex;
    transition: var(--transition);
    border: 1px solid rgba(0,0,0,0.03);
}

.trending-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-5px);
}

.trending-img {
    width: 45%;
    min-height: 300px;
    overflow: hidden;
}

.trending-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.trending-card:hover .trending-img img {
    transform: scale(1.05);
}

.trending-content {
    width: 55%;
    padding: 40px;
    display: flex;
    flex-direction: column;
}

.trending-badge {
    background: linear-gradient(135deg, var(--accent-color), #d32f2f);
    color: white;
    padding: 6px 18px;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 800;
    display: inline-block;
    margin-bottom: 20px;
    align-self: flex-start;
    box-shadow: 0 4px 10px rgba(234, 67, 53, 0.3);
}

.trending-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.4;
    color: var(--dark-color);
    transition: var(--transition);
}

.trending-card:hover .trending-title {
    color: var(--primary-color);
}

.trending-excerpt {
    color: var(--gray-color);
    font-size: 1.1rem;
    margin-bottom: 25px;
    flex-grow: 1;
    line-height: 1.7;
}

/* Alerts Section */
.alert-list .alert {
    border-radius: 12px;
    border: none;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    margin-bottom: 18px;
    padding: 18px 25px;
}

.alert-list .alert:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.alert-list .alert i {
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.alert-list .alert:hover i {
    transform: scale(1.3) rotate(5deg);
}

.alert-list .alert-primary {
    background: linear-gradient(135deg, #1a73e8, #4285f4);
    color: white;
}

.alert-list .alert-danger {
    background: linear-gradient(135deg, #ea4335, #e57373);
    color: white;
}

.alert-list .alert-warning {
    background: linear-gradient(135deg, #fbbc04, #ffca28);
    color: white;
}

/* Newsletter Section */
.newsletter-section {
    background: linear-gradient(135deg, var(--primary-color), #0d47a1);
    padding: 80px 0;
    color: white;
    text-align: center;
    margin: 80px 0;
    border-radius: 30px;
    box-shadow: 0 15px 40px rgba(26, 115, 232, 0.3);
}

.newsletter-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.newsletter-form {
    max-width: 650px;
    margin: 0 auto;
    display: flex;
    gap: 15px;
    background: rgba(255,255,255,0.1);
    padding: 10px;
    border-radius: 50px;
}

.newsletter-form input {
    flex-grow: 1;
    padding: 18px 25px;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    background: white;
}

.newsletter-form button {
    background: var(--accent-color);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 0 40px;
    font-weight: 800;
    font-size: 1.1rem;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(234, 67, 53, 0.4);
}

.newsletter-form button:hover {
    background: #c23321;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(234, 67, 53, 0.5);
}

/* Footer */
.footer {
    background: var(--dark-color);
    color: white;
    padding: 80px 0 30px;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color), var(--secondary-color));
}

.footer-logo {
    font-size: 2.5rem;
    font-weight: 800;
    color: white;
    margin-bottom: 25px;
    display: inline-block;
    text-decoration: none;
}

.footer-logo span {
    color: var(--accent-color);
}

.footer-about {
    margin-bottom: 25px;
    color: rgba(255,255,255,0.7);
    line-height: 1.8;
    font-size: 1.05rem;
}

.footer-title {
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 15px;
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 60px;
    height: 4px;
    background: var(--primary-color);
    border-radius: 2px;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 15px;
}

.footer-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.05rem;
}

.footer-links a:hover {
    color: white;
    gap: 18px;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    color: white;
    transition: var(--transition);
    font-size: 1.2rem;
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(26, 115, 232, 0.4);
}

.copyright {
    text-align: center;
    padding-top: 35px;
    margin-top: 50px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
    font-size: 0.95rem;
}

/* Responsive Design */
@media (max-width: 992px) {
    .hero-section {
        height: 450px;
        border-radius: 0;
    }
    
    .hero-title {
        font-size: 2.2rem;
    }
    
    .trending-img {
        width: 100%;
        min-height: 250px;
    }
    
    .trending-content {
        width: 100%;
    }
    
    .trending-card {
        flex-direction: column;
    }
}

@media (max-width: 768px) {
    .hero-section {
        height: 400px;
    }
    
    .hero-content {
        right: 40px;
        left: 40px;
        bottom: 50px;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .top-bar .datetime {
        justify-content: center;
        margin-bottom: 10px;
    }
    .top-bar .social-icons {
        justify-content: center;
    }
    
    .newsletter-form {
        flex-direction: column;
        background: none;
        padding: 0;
    }
    .newsletter-form input, .newsletter-form button {
        border-radius: 12px;
    }
    .newsletter-form button {
        padding: 15px;
    }
}
