/* المؤسسة الوطنية للمخترعين الليبيين - NFLI Website */
/* بتصميم مستوحى من IFIA */

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

body {
    font-family: 'Cairo', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #ffffff;
    color: #333;
    font-size: 14px;
    line-height: 1.6;
    direction: rtl;
    text-align: right;
}

/* Header Section */
header {
    background-color: white;
    color: #1a2f4f;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.header-top {
    background-color: #0f1d30;
    padding: 10px 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logos-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo img {
    height: 60px;
    width: auto;
}

.logo h1 {
    font-size: 1.3rem;
    font-weight: bold;
    color: white;
    line-height: 1.3;
}

/* Navigation */
nav {
    background-color: #1a2f4f;
    border-top: 1px solid rgba(255,255,255,0.1);
}

nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 5px;
    padding: 0;
}

nav ul li {
    margin: 0;
}

nav ul li a {
    display: block;
    color: white;
    text-decoration: none;
    padding: 13px 18px;
    font-size: 13px;
    transition: all 0.3s ease;
    border-radius: 4px;
}

nav ul li a:hover,
nav ul li a.active {
    background-color: #2563eb;
    color: white;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(26, 47, 79, 0.85), rgba(26, 47, 79, 0.85)), 
                url('../images/gallery/tripoli-hero.jpg') center/cover no-repeat;
    color: white;
    padding: 70px 20px;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    font-weight: bold;
}

.hero p {
    font-size: 1.05rem;
    max-width: 800px;
    margin: 0 auto 25px;
}

.btn-group {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: bold;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: #dc2626;
    color: white;
}

.btn-primary:hover {
    background-color: #b91c1c;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(220, 38, 38, 0.3);
}

.btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background-color: white;
    color: #1a2f4f;
}

/* Section Styles */
section {
    padding: 50px 20px;
}

section:nth-child(even) {
    background-color: #f3f4f6;
}

section h2 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    color: #1a2f4f;
    text-align: center;
    font-weight: bold;
}

section .section-subtitle {
    text-align: center;
    color: #666;
    font-size: 13px;
    margin-bottom: 30px;
}

/* Cards */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    padding: 25px;
    transition: all 0.3s ease;
    border: 1px solid #e5e7eb;
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-3px);
}

.card h3 {
    font-size: 1.1rem;
    color: #1a2f4f;
    margin-bottom: 10px;
}

.card p {
    font-size: 13px;
    color: #666;
    line-height: 1.7;
}

/* News Cards */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.news-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.news-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-3px);
}

.news-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.news-content {
    padding: 20px;
}

.news-content h3 {
    font-size: 1.05rem;
    color: #1a2f4f;
    margin-bottom: 10px;
}

.news-content .date {
    color: #dc2626;
    font-size: 12px;
    margin-bottom: 10px;
    display: block;
}

.news-content p {
    font-size: 13px;
    color: #666;
    line-height: 1.6;
}

.news-content a {
    display: inline-block;
    margin-top: 10px;
    color: #2563eb;
    text-decoration: none;
    font-size: 13px;
    font-weight: bold;
}

.news-content a:hover {
    text-decoration: underline;
}

/* Image Gallery */
.image-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* Exhibition Links */
.exhibitions-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.exhibition-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    border-right: 4px solid #2563eb;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.exhibition-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateX(-5px);
}

.exhibition-card h3 {
    font-size: 1.05rem;
    color: #1a2f4f;
    margin-bottom: 8px;
}

.exhibition-card .date-location {
    color: #dc2626;
    font-size: 12px;
    margin-bottom: 10px;
    display: block;
}

.exhibition-card p {
    font-size: 13px;
    color: #666;
    margin-bottom: 12px;
}

.exhibition-card a {
    color: #2563eb;
    text-decoration: none;
    font-size: 13px;
    font-weight: bold;
}

.exhibition-card a:hover {
    text-decoration: underline;
}

/* Forms */
.form-section {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    max-width: 700px;
    margin: 30px auto;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    color: #1a2f4f;
    font-weight: 600;
    font-size: 13px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 13px;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #2563eb;
}

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

button[type="submit"] {
    background-color: #dc2626;
    color: white;
    padding: 12px 40px;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

button[type="submit"]:hover {
    background-color: #b91c1c;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(220, 38, 38, 0.3);
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
}

thead {
    background-color: #1a2f4f;
    color: white;
}

th, td {
    padding: 12px;
    text-align: right;
    border-bottom: 1px solid #e5e7eb;
    font-size: 13px;
}

tbody tr:hover {
    background-color: #f9fafb;
}

/* Footer */
footer {
    background-color: #0f1d30;
    color: white;
    padding: 40px 20px 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 25px;
}

.footer-section h3 {
    font-size: 1.05rem;
    margin-bottom: 12px;
    color: #2563eb;
}

.footer-section p,
.footer-section ul {
    font-size: 13px;
    line-height: 1.7;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 8px;
}

.footer-section a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #2563eb;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 12px;
    color: #9ca3af;
}

/* Responsive Design */
@media (max-width: 768px) {
    .logos-container {
        flex-direction: column;
        text-align: center;
    }
    
    .logo {
        justify-content: center;
    }
    
    nav ul {
        flex-direction: column;
        align-items: center;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .cards-grid,
    .news-grid,
    .exhibitions-list {
        grid-template-columns: 1fr;
    }
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mb-20 {
    margin-bottom: 20px;
}

.mt-30 {
    margin-top: 30px;
}
