/* ፋይል: assets/css/style.css */
:root {
    --primary: #0f4c81;
    --primary-dark: #0a355c;
    --primary-light: #e0f2fe;
    --accent: #0284c7;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-600: #475569;
    --slate-800: #1e293b;
    --slate-900: #0f172a;
    --success: #15803d;
    --danger: #b91c1c;
    --radius: 10px;
    --shadow-sm: 0 2px 6px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.09);
}

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

body {
    font-family: 'Segoe UI', 'Nyala', 'Abyssinica SIL', system-ui, -apple-system, sans-serif;
    background-color: var(--slate-50);
    color: var(--slate-800);
    line-height: 1.6;
}

.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 1.25rem;
}

.hidden { display: none !important; }
.mt-4 { margin-top: 1.75rem; }
.mt-5 { margin-top: 3rem; }
.bg-slate { background-color: var(--slate-100); }
.section-padding { padding: 3.5rem 0; }

/* Header & Navigation */
.site-header {
    background: #ffffff;
    border-bottom: 1px solid var(--slate-200);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 74px;
    gap: 1rem;
    flex-wrap: wrap;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    text-decoration: none;
    color: var(--slate-900);
}

.brand-badge {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: #fff;
    font-weight: 800;
    padding: 0.55rem 0.8rem;
    border-radius: 8px;
    letter-spacing: 0.5px;
}

.brand-logo strong {
    display: block;
    font-size: 1.15rem;
    color: var(--primary-dark);
}

.brand-logo small {
    color: var(--slate-600);
    font-size: 0.8rem;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.main-nav a {
    text-decoration: none;
    color: var(--slate-800);
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.main-nav a:hover { color: var(--accent); }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1.25rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    text-decoration: none;
    border: 1px solid transparent;
    transition: transform 0.15s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.btn:active { transform: translateY(1px); }
.btn-sm { padding: 0.42rem 0.85rem; font-size: 0.84rem; }
.btn-block { width: 100%; }

.btn-primary {
    background-color: var(--primary);
    color: #fff !important;
}
.btn-primary:hover {
    background-color: var(--primary-dark);
    box-shadow: 0 4px 12px rgba(15, 76, 129, 0.25);
}

.btn-outline {
    background: transparent;
    border-color: var(--primary);
    color: var(--primary) !important;
}
.btn-outline:hover { background: var(--primary-light); }

.btn-danger {
    background: var(--danger);
    color: #fff !important;
}

.btn-light {
    background: #ffffff;
    color: var(--primary-dark) !important;
}
.btn-outline-light {
    border: 1px solid rgba(255,255,255,0.6);
    color: #ffffff !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(125deg, #092c4c 0%, #0f4c81 55%, #0284c7 100%);
    color: #ffffff;
    padding: 4.5rem 0;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 2.5rem;
    align-items: center;
}

.hero-pill {
    display: inline-block;
    background: rgba(255, 255, 255, 0.15);
    padding: 0.35rem 0.9rem;
    border-radius: 999px;
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.hero-content h1 {
    font-size: 2.3rem;
    line-height: 1.25;
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.05rem;
    opacity: 0.92;
    margin-bottom: 1.75rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-stats {
    display: grid;
    gap: 1rem;
}

.stat-box {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius);
}

.stat-box h3 { font-size: 1.85rem; color: #38bdf8; }

/* Section Headers */
.section-header {
    margin-bottom: 2rem;
    border-left: 5px solid var(--primary);
    padding-left: 1rem;
}

.section-header h2 {
    font-size: 1.55rem;
    color: var(--slate-900);
}

.section-header p { color: var(--slate-600); }

/* News Grid & Cards */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.75rem;
}

.news-card {
    background: #fff;
    border-radius: var(--radius);
    border: 1px solid var(--slate-200);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.news-thumb {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    background: #000;
}

.video-wrapper iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
}

.news-placeholder {
    height: 200px;
    background: linear-gradient(135deg, var(--primary-dark), var(--accent));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
}

.news-body {
    padding: 1.35rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    color: var(--slate-600);
    margin-bottom: 0.6rem;
}

.news-title {
    font-size: 1.2rem;
    color: var(--slate-900);
    margin-bottom: 0.65rem;
}

.news-excerpt {
    font-size: 0.94rem;
    color: var(--slate-600);
    margin-bottom: 1rem;
}

.gallery-strip {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    margin-bottom: 0.85rem;
}

.gallery-thumb {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    border: 2px solid var(--slate-200);
    transition: border-color 0.2s;
}
.gallery-thumb:hover { border-color: var(--accent); }

.social-bar {
    display: flex;
    gap: 0.5rem;
    border-top: 1px solid var(--slate-200);
    padding-top: 0.85rem;
    margin-top: auto;
}

.social-btn {
    flex: 1;
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: 6px;
    padding: 0.45rem;
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--slate-800);
    cursor: pointer;
    transition: background 0.15s;
}
.social-btn:hover, .social-btn.liked {
    background: var(--primary-light);
    border-color: var(--accent);
    color: var(--primary-dark);
}

/* Comments Drawer */
.comments-drawer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px dashed var(--slate-200);
}

.comment-form input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--slate-200);
    border-radius: 6px;
    margin-bottom: 0.5rem;
    font-size: 0.88rem;
}

.comment-input-row {
    display: flex;
    gap: 0.5rem;
}

.comments-list {
    max-height: 250px;
    overflow-y: auto;
    margin-top: 0.75rem;
    display: grid;
    gap: 0.65rem;
}

.comment-item {
    background: var(--slate-50);
    padding: 0.65rem 0.85rem;
    border-radius: 8px;
    font-size: 0.88rem;
}

.comment-head {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.25rem;
}

.official-reply {
    margin-top: 0.5rem;
    background: var(--primary-light);
    border-left: 3px solid var(--primary);
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    font-size: 0.85rem;
}

/* Documents & Filter Bar */
.filter-bar {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.75rem;
    flex-wrap: wrap;
}

.filter-bar input, .filter-bar select {
    padding: 0.65rem 0.9rem;
    border: 1px solid var(--slate-200);
    border-radius: 8px;
    font-size: 0.95rem;
    flex: 1;
    min-width: 200px;
}

.doc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.25rem;
}

.doc-card {
    background: #fff;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
    padding: 1.25rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    box-shadow: var(--shadow-sm);
}

.doc-icon {
    background: var(--primary-light);
    color: var(--primary-dark);
    font-weight: 800;
    padding: 0.85rem 0.7rem;
    border-radius: 8px;
    font-size: 0.85rem;
    min-width: 56px;
    text-align: center;
}

.doc-info { flex: 1; }
.doc-info h4 { margin: 0.35rem 0; color: var(--slate-900); }
.doc-info p { font-size: 0.88rem; color: var(--slate-600); margin-bottom: 0.5rem; }

.doc-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--slate-600);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
}
.badge-blue { background: #e0f2fe; color: #0369a1; }
.badge-green { background: #dcfce7; color: #15803d; }
.badge-amber { background: #fef3c7; color: #b45309; }
.badge-purple { background: #f3e8ff; color: #6d28d9; }

/* Forms, Cards & Tables in Dashboards */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1.25fr;
    gap: 1.75rem;
    align-items: start;
}

.card {
    background: #fff;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.card h3 {
    margin-bottom: 1.25rem;
    color: var(--primary-dark);
    font-size: 1.2rem;
}

.form-group { margin-bottom: 1rem; }
.form-group label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.35rem;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--slate-200);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
}

.divider {
    border: 0;
    border-top: 1px solid var(--slate-200);
    margin: 1.5rem 0;
}

.table-responsive { overflow-x: auto; }
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}
.data-table th, .data-table td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--slate-200);
    text-align: left;
}
.data-table th {
    background: var(--slate-50);
    color: var(--slate-900);
}

.inline-reset-form {
    display: flex;
    gap: 0.4rem;
}
.inline-reset-form input {
    padding: 0.35rem 0.6rem;
    border: 1px solid var(--slate-200);
    border-radius: 6px;
    width: 140px;
}

/* Staff Internal Peer-to-Peer Chat UI */
.chat-container {
    display: grid;
    grid-template-columns: 320px 1fr;
    height: 540px;
    padding: 0;
    overflow: hidden;
}

.chat-sidebar {
    border-right: 1px solid var(--slate-200);
    display: flex;
    flex-direction: column;
    background: var(--slate-50);
}

.chat-search-box {
    padding: 0.85rem;
    border-bottom: 1px solid var(--slate-200);
}
.chat-search-box input {
    width: 100%;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--slate-200);
    border-radius: 8px;
}

.chat-contacts {
    flex: 1;
    overflow-y: auto;
}

.contact-item {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--slate-200);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background 0.15s;
}
.contact-item:hover, .contact-item.active {
    background: var(--primary-light);
}

.status-dot {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    margin-right: 6px;
}
.status-online { background: #22c55e; }
.status-offline { background: #94a3b8; }

.unread-pill {
    background: var(--danger);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.15rem 0.55rem;
    border-radius: 999px;
}

.chat-main {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.chat-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--slate-200);
    background: #fff;
}

.chat-messages {
    flex: 1;
    padding: 1.25rem;
    overflow-y: auto;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.msg-bubble {
    max-width: 72%;
    padding: 0.7rem 1rem;
    border-radius: 12px;
    font-size: 0.92rem;
    position: relative;
}
.msg-mine {
    align-self: flex-end;
    background: var(--primary);
    color: #fff;
    border-bottom-right-radius: 2px;
}
.msg-theirs {
    align-self: flex-start;
    background: #ffffff;
    border: 1px solid var(--slate-200);
    color: var(--slate-900);
    border-bottom-left-radius: 2px;
}
.msg-time {
    display: block;
    font-size: 0.72rem;
    opacity: 0.75;
    margin-top: 0.25rem;
}

.chat-input-bar {
    padding: 0.85rem 1.25rem;
    border-top: 1px solid var(--slate-200);
    background: #fff;
    display: flex;
    gap: 0.75rem;
}
.chat-input-bar input {
    flex: 1;
    padding: 0.65rem 0.9rem;
    border: 1px solid var(--slate-200);
    border-radius: 8px;
}

/* Login Page */
.login-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #092c4c, #0f4c81);
    padding: 1.5rem;
}
.login-card {
    background: #fff;
    width: 100%;
    max-width: 430px;
    padding: 2.25rem;
    border-radius: 14px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}
.login-brand {
    text-align: center;
    margin-bottom: 1.75rem;
}
.brand-emblem {
    width: 60px; height: 60px;
    background: var(--primary);
    color: #fff;
    font-weight: 800;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
}
.login-footer {
    margin-top: 1.25rem;
    text-align: center;
    font-size: 0.9rem;
}
.login-footer a { color: var(--primary); text-decoration: none; }

/* Alerts & Modals */
.alert {
    padding: 0.85rem 1.1rem;
    border-radius: 8px;
    margin-bottom: 1.25rem;
    font-weight: 600;
}
.alert-success { background: #dcfce7; color: var(--success); border: 1px solid #86efac; }
.alert-error { background: #fee2e2; color: var(--danger); border: 1px solid #fca5a5; }

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    padding: 1.5rem;
}
.modal-img-box img {
    max-width: 90vw;
    max-height: 85vh;
    border-radius: 10px;
}

.comment-admin-card {
    border: 1px solid var(--slate-200);
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 0.85rem;
}
.comment-admin-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.88rem;
    margin-bottom: 0.4rem;
}
.reply-box {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.65rem;
}
.reply-box input {
    flex: 1;
    padding: 0.45rem 0.75rem;
    border: 1px solid var(--slate-200);
    border-radius: 6px;
}

.site-footer {
    background: var(--slate-900);
    color: #cbd5e1;
    padding: 2rem 0;
    font-size: 0.9rem;
    text-align: center;
}

@media (max-width: 900px) {
    .hero-grid, .dashboard-grid, .chat-container {
        grid-template-columns: 1fr;
    }
    .chat-container { height: auto; }
    .chat-sidebar { max-height: 240px; }
    .chat-messages { height: 340px; }
}
/* === Logo & Public External Menu Links Styling === */
.brand-logo-img {
    width: 52px;
    height: 52px;
    object-fit: contain;
    border-radius: 8px;
    background: #ffffff;
    padding: 2px;
    border: 1px solid var(--slate-200);
    flex-shrink: 0;
}

.nav-container {
    max-width: 1380px; /* ተጨማሪዎቹ 4 ሊንኮች በነፃነት እንዲቀመጡ ሰፋ ያለ ኮንቴይነር */
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
}

.main-nav .nav-link {
    padding: 0.45rem 0.7rem;
    border-radius: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--slate-800);
    white-space: nowrap;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.main-nav .nav-link:hover {
    background-color: var(--primary-light);
    color: var(--primary-dark);
}

/* የEAIMS ውጭ ሊንኮች በሜኑው ላይ ጎልተው እንዲታዩ */
.main-nav .nav-external {
    background-color: var(--slate-50);
    border: 1px solid var(--slate-200);
    color: var(--primary-dark);
}

.main-nav .nav-external:hover {
    background-color: var(--primary);
    color: #ffffff !important;
    border-color: var(--primary);
}

.mobile-menu-btn {
    display: none;
    background: var(--slate-100);
    border: 1px solid var(--slate-200);
    border-radius: 8px;
    padding: 0.45rem 0.75rem;
    font-size: 1.25rem;
    cursor: pointer;
    color: var(--primary-dark);
}

/* ሞባይል እና ታብሌት ላይ ሜኑው በጥራት እንዲከፈት */
@media (max-width: 1120px) {
    .mobile-menu-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .main-nav {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        padding: 1rem 0;
        border-top: 1px solid var(--slate-200);
        gap: 0.5rem;
    }

    .main-nav.nav-open {
        display: flex;
    }

    .main-nav .nav-link,
    .main-nav .btn {
        width: 100%;
        text-align: left;
        justify-content: flex-start;
        padding: 0.65rem 0.9rem;
    }
}