@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&display=swap');

:root {
    /* Modern Technical Color Palette */
    --primary-color: #0077be;       /* Deep Blue */
    --secondary-color: #00b4d8;     /* Bright Cyan */
    --background-dark: #121212;     /* Deep Dark Background */
    --background-light: #1e1e1e;    /* Slightly Lighter Dark */
    --text-primary: #e0e0e0;        /* Light Gray Text */
    --text-secondary: #b0b0b0;      /* Muted Gray Text */
    --accent-color: #7e57c2;        /* Vibrant Purple */
    --success-color: #4caf50;       /* Green for Success */
    --error-color: #f44336;         /* Red for Errors */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', 'Cairo', sans-serif;
    transition: all 0.3s ease;
}

body {
    background-color: var(--background-dark);
    color: var(--text-primary);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    scrollbar-width: thin;
    scrollbar-color: var(--secondary-color) var(--background-light);
}

/* Custom Scrollbar */
body::-webkit-scrollbar {
    width: 8px;
}

body::-webkit-scrollbar-track {
    background: var(--background-light);
}

body::-webkit-scrollbar-thumb {
    background-color: var(--secondary-color);
    border-radius: 20px;
}

/* Header Styles */
header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1rem 2rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
}

/* Container Styles */
.container {
    background-color: var(--background-light);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
    padding: 20px;
    margin: 20px 0;
}

/* Card Styles */
.card, .airdrop-card {
    background-color: var(--background-dark);
    border: 1px solid var(--background-light);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.card:hover, .airdrop-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.4);
}

.card::before, .airdrop-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
}

/* Table Styles */
table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background-color: var(--background-light);
    border-radius: 8px;
    overflow: hidden;
}

table th {
    background-color: var(--primary-color);
    color: white;
    padding: 12px;
    text-align: left;
}

table td {
    padding: 12px;
    border-bottom: 1px solid var(--background-dark);
    color: var(--text-secondary);
}

/* Button Styles */
.btn, .button {
    background-color: var(--secondary-color);
    color: var(--background-dark);
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    display: inline-block;
    text-align: center;
}

.btn:hover, .button:hover {
    background-color: var(--accent-color);
    transform: scale(1.05);
}

/* Status Badge Styles */
.status-badge, .status {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: bold;
}

.status-available, .status.متاح {
    background-color: var(--success-color);
    color: white;
}

.status-soon, .status.قريبًا {
    background-color: var(--secondary-color);
    color: var(--background-dark);
}

.status-ended, .status.منتهي {
    background-color: var(--error-color);
    color: white;
}

/* Footer Styles */
footer {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-align: center;
    padding: 2rem 1rem;
    margin-top: auto;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
        margin: 10px;
    }
    
    table {
        font-size: 0.9em;
    }

    .airdrops-grid {
        grid-template-columns: 1fr;
    }
}

/* Additional Modern Touches */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

/* Glassmorphism Effect */
.glass-effect {
    background: rgba(30, 30, 30, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.125);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

/* Animated Gradient Background */
@keyframes gradient-animation {
    0% {background-position: 0% 50%;}
    50% {background-position: 100% 50%;}
    100% {background-position: 0% 50%;}
}

.gradient-bg {
    background: linear-gradient(-45deg, var(--primary-color), var(--secondary-color), var(--accent-color), var(--background-dark));
    background-size: 400% 400%;
    animation: gradient-animation 15s ease infinite;
}

/* Custom Styles for Specific Elements */
.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    perspective: 1000px;
    transition: all 0.4s ease;
}

.logo img {
    width: 100px;
    height: 100px;
    transition: all 0.4s ease;
    transform-style: preserve-3d;
}

.logo:hover img {
    transform: 
        rotate3d(0, 1, 0, 360deg)
        scale(1.05);
    filter: drop-shadow(0 10px 15px rgba(0,0,0,0.2));
}

.logo h1 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 2rem;
    transition: all 0.4s ease;
    background: linear-gradient(to right, #000, #fff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo:hover h1 {
    background: linear-gradient(to right, #fff, #000);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transform: translateX(10px);
}

nav {
    display: none;
}

#hero {
    text-align: center;
    padding: 4rem 2rem;
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
    color: white;
    margin-bottom: 3rem;
}

#hero h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

#hero p {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
}

main {
    flex: 1;
}

.section-header {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h2 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.section-header h2 i {
    color: var(--primary-color);
    font-size: 1.5rem;
}

.airdrops-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    padding: 1rem;
    max-width: 1400px;
    margin: 0 auto;
}

.airdrop-card {
    background-color: var(--background-light);
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    position: relative;
    border: 1px solid var(--background-dark);
    cursor: pointer;
    transform: perspective(1000px) rotateX(0deg);
    transform-style: preserve-3d;
}

.airdrop-card:hover {
    transform: perspective(1000px) rotateX(-5deg) scale(1.03);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.airdrop-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid var(--background-dark);
}

.card-header h3 {
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    font-size: 1.1rem;
    max-width: 70%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.status {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: bold;
    text-transform: uppercase;
    margin-left: 10px;
}

.status.متاح {
    background-color: var(--success-color);
    color: white;
}

.status.منتهي {
    background-color: var(--error-color);
    color: white;
}

.card-details {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.detail-item {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.detail-item i {
    margin-left: 10px;
    color: var(--primary-color);
    width: 20px;
    text-align: center;
    font-size: 1rem;
}

.last-update {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background-color: var(--background-light);
    border-top: 1px solid var(--background-dark);
    font-size: 0.7rem;
    color: var(--text-secondary);
}

.tutorial-link {
    background-color: var(--primary-color);
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.8rem;
    transition: all 0.3s ease;
    display: inline-block;
}

.tutorial-link:hover {
    background-color: var(--accent-color);
    transform: scale(1.05);
}

.feature-card {
    background-color: var(--background-light);
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 6px 20px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border: 1px solid var(--background-dark);
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.feature-icon {
    background-color: var(--primary-color);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    transition: background-color 0.3s ease;
}

.feature-card:hover .feature-icon {
    background-color: var(--accent-color);
}

.feature-card h3 {
    margin: 0.8rem 0;
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: bold;
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.5;
    font-size: 0.8rem;
    margin: 0;
}

#airdropDashboard {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#airdropDashboard.active {
    display: flex;
}

.airdrop-dashboard {
    background-color: var(--background-light);
    width: 90%;
    max-width: 600px;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--background-dark);
    padding-bottom: 1rem;
}

.dashboard-details .detail-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--background-dark);
}

.dashboard-details .detail-row strong {
    color: var(--primary-color);
}

.dashboard-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
}

.add-airdrop-form {
    background-color: var(--background-light);
    width: 90%;
    max-width: 500px;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.form-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--background-dark);
    padding-bottom: 1rem;
}

.close-form {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--background-dark);
    border-radius: 5px;
    font-size: 0.9rem;
}

.form-group textarea {
    min-height: 100px;
}

.form-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
}

.btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--background-dark);
}

.btn-secondary {
    background-color: var(--background-light);
    color: var(--text-primary);
}

/* تم إزالة تنسيقات زر إضافة الإيردروب */

/* استجابة الشاشات */
@media screen and (max-width: 768px) {
    body {
        font-size: 14px;
    }

    header {
        flex-direction: column;
        padding: 1rem;
    }

    .logo {
        margin-bottom: 1rem;
    }

    nav ul {
        flex-direction: column;
        align-items: center;
    }

    nav ul li {
        margin: 0.5rem 0;
    }

    #hero {
        padding: 2rem 1rem;
    }

    .airdrops-grid,
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .airdrop-card,
    .feature-card {
        padding: 1rem;
    }

    .airdrop-details-modal {
        align-items: flex-end;
    }

    .airdrop-details-content {
        width: 100%;
        max-width: 100%;
        border-radius: 20px 20px 0 0;
        max-height: 80vh;
        overflow-y: auto;
    }

    .pagination {
        flex-wrap: wrap;
    }

    .pagination button {
        margin: 0.25rem;
    }
}

@media screen and (max-width: 480px) {
    body {
        font-size: 12px;
    }

    .feature-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }

    .section-header h2 {
        font-size: 1.2rem;
    }
}

/* دعم RTL للشاشات الصغيرة */
@media screen and (max-width: 768px) {
    html[dir="rtl"] body {
        direction: rtl;
        text-align: right;
    }
}

/* تنسيقات لوحة التحكم الإدارية */
.admin-dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background-color: var(--background-light);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-radius: 10px;
}

.admin-dashboard-container header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--background-dark);
}

.admin-dashboard-container header h1 {
    color: var(--text-primary);
    font-size: 2rem;
    margin: 0;
}

.dashboard-actions {
    margin-bottom: 20px;
    display: flex;
    justify-content: flex-end;
}

.dashboard-actions button {
    background-color: var(--primary-color);
    color: var(--background-dark);
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.dashboard-actions button:hover {
    background-color: var(--accent-color);
}

.airdrops-table {
    background-color: var(--background-light);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    overflow-x: auto;
}

.airdrops-table table {
    width: 100%;
    border-collapse: collapse;
}

.airdrops-table th, .airdrops-table td {
    padding: 12px 15px;
    text-align: right;
    border-bottom: 1px solid var(--background-dark);
}

.airdrops-table th {
    background-color: var(--primary-color);
    color: var(--background-dark);
    font-weight: 700;
}

.airdrops-table .actions-column {
    display: flex;
    gap: 10px;
}

.airdrops-table .actions-column button {
    padding: 5px 10px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.airdrops-table .edit-btn {
    background-color: var(--primary-color);
    color: var(--background-dark);
}

.airdrops-table .delete-btn {
    background-color: var(--error-color);
    color: var(--background-dark);
}

.airdrops-table .edit-btn:hover {
    background-color: var(--accent-color);
}

.airdrops-table .delete-btn:hover {
    background-color: var(--error-color);
}

/* تنسيق النموذج المنبثق */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}

.modal-content {
    background-color: var(--background-light);
    margin: 10% auto;
    padding: 30px;
    border-radius: 10px;
    width: 80%;
    max-width: 600px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.modal .close {
    color: var(--text-secondary);
    float: left;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.modal .close:hover {
    color: var(--text-primary);
}

.modal form .form-group {
    margin-bottom: 15px;
}

.modal form label {
    display: block;
    margin-bottom: 5px;
    color: var(--text-primary);
}

.modal form input, 
.modal form textarea, 
.modal form select {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--background-dark);
    border-radius: 5px;
}

.modal form textarea {
    min-height: 100px;
}

.modal form button[type="submit"] {
    background-color: var(--primary-color);
    color: var(--background-dark);
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.modal form button[type="submit"]:hover {
    background-color: var(--accent-color);
}

.airdrop-details-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    direction: rtl;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s;
}

.airdrop-details-modal.show {
    display: flex;
    opacity: 1;
    visibility: visible;
}

.airdrop-details-content {
    background-color: var(--background-light);
    border-radius: 15px;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    position: relative;
    text-align: right;
    transform: scale(0.7);
    opacity: 0;
    transition: all 0.3s ease;
}

.airdrop-details-modal.show .airdrop-details-content {
    transform: scale(1);
    opacity: 1;
}

.airdrop-details-content .close-btn {
    position: absolute;
    top: 15px;
    left: 15px;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.airdrop-details-content .close-btn:hover {
    color: var(--error-color);
}

.airdrop-details-content h2 {
    margin-bottom: 1rem;
    color: var(--text-primary);
    text-align: center;
}

.airdrop-details-content .detail-item {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px;
    background-color: var(--background-dark);
    border-radius: 8px;
}

.airdrop-details-content .detail-item i {
    margin-left: 10px;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.airdrop-details-content .detail-item span {
    font-weight: bold;
    color: var(--text-primary);
}

.airdrop-details-content .tutorial-link {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--background-dark);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    text-decoration: none;
    margin-top: 1rem;
    transition: background-color 0.3s ease;
    width: 100%;
    text-align: center;
}

footer {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-align: center;
    padding: 2rem 1rem;
    margin-top: auto;
}

footer .footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

footer .copyright {
    margin-bottom: 1rem;
    font-weight: 300;
}

footer .social-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
}

footer .social-links a {
    color: white;
    font-size: 1.5rem;
    text-decoration: none;
    transition: transform 0.3s ease, color 0.3s ease;
    display: flex;
    align-items: center;
}

footer .social-links a:hover {
    transform: scale(1.2);
    color: var(--background-light);
}

footer .social-links a i {
    margin-left: 0.5rem;
}

@media (max-width: 768px) {
    footer {
        padding: 1.5rem 1rem;
    }
    
    footer .social-links {
        gap: 1rem;
    }
    
    footer .social-links a {
        font-size: 1.2rem;
    }
}

#platform-features {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: stretch;
    gap: 20px;
    padding: 50px 5%;
    background-color: var(--background-light);
}

.feature-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background-color: var(--background-dark);
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.feature-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.feature-card h3 {
    margin-bottom: 15px;
    color: var(--text-primary);
    font-weight: 700;
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

@media (max-width: 768px) {
    .airdrop-card {
        margin-bottom: 15px;
    }
}

/* أنماط شاشة التحميل */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    flex-direction: column;
}

.loading-spinner {
    border: 4px solid var(--background-light);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}

.loading-overlay p {
    color: white;
    margin-top: 15px;
    font-size: 18px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
