@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800;900&family=Noto+Kufi+Arabic:wght@300;400;500;600;700;800;900&display=swap');

:root {
    --primary: #0a3d6b;
    --primary-light: #1565a0;
    --primary-dark: #062a4a;
    --secondary: #c8a84e;
    --secondary-light: #e0c878;
    --accent: #2196F3;
    --success: #28a745;
    --white: #ffffff;
    --off-white: #f8f9fc;
    --gray-100: #f1f3f7;
    --gray-200: #e2e6ec;
    --gray-300: #c9ced6;
    --gray-500: #7a8594;
    --gray-700: #3d4654;
    --gray-900: #1a2332;
    --shadow-sm: 0 1px 3px rgba(10,61,107,0.08);
    --shadow-md: 0 4px 16px rgba(10,61,107,0.1);
    --shadow-lg: 0 8px 32px rgba(10,61,107,0.12);
    --shadow-xl: 0 16px 48px rgba(10,61,107,0.15);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: 'Cairo', 'Noto Kufi Arabic', sans-serif;
    direction: rtl;
    text-align: right;
    background: var(--off-white);
    color: var(--gray-900);
    line-height: 1.7;
    font-size: 15px;
    overflow-x: hidden;
}

h1,h2,h3,h4,h5,h6 { font-family: 'Noto Kufi Arabic','Cairo',sans-serif; font-weight: 700; line-height: 1.4; }

/* NAVBAR */
.navbar-main { background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%); padding: 0; box-shadow: var(--shadow-lg); position: sticky; top: 0; z-index: 1050; }
.navbar-main .navbar-brand { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.navbar-main .navbar-brand img { height: 48px; }
.navbar-main .navbar-brand span { color: var(--white); font-family: 'Noto Kufi Arabic',sans-serif; font-weight: 700; font-size: 14px; line-height: 1.3; border-right: 2px solid var(--secondary); padding-right: 12px; }
.navbar-main .nav-link { color: rgba(255,255,255,0.85) !important; font-weight: 500; font-size: 14px; padding: 18px 14px !important; position: relative; transition: var(--transition); white-space: nowrap; }
.navbar-main .nav-link:hover, .navbar-main .nav-link.active { color: var(--white) !important; background: rgba(255,255,255,0.1); }
.navbar-main .nav-link.active::after { content: ''; position: absolute; bottom: 0; right: 0; left: 0; height: 3px; background: var(--secondary); border-radius: 3px 3px 0 0; }

/* HERO */
.hero-section { background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 40%, var(--primary-light) 100%); position: relative; overflow: hidden; min-height: 85vh; display: flex; align-items: center; }
.hero-section::before { content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E"); z-index: 0; }
.hero-section::after { content: ''; position: absolute; bottom: -2px; left: 0; right: 0; height: 80px; background: var(--off-white); clip-path: ellipse(55% 100% at 50% 100%); z-index: 1; }
.hero-content { position: relative; z-index: 2; text-align: center; color: var(--white); padding: 60px 0 100px; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; background: rgba(200,168,78,0.2); border: 1px solid rgba(200,168,78,0.4); color: var(--secondary-light); padding: 6px 20px; border-radius: 50px; font-size: 13px; font-weight: 600; margin-bottom: 24px; backdrop-filter: blur(10px); }
.hero-org { font-size: 16px; font-weight: 500; opacity: 0.9; margin-bottom: 8px; }
.hero-title { font-family: 'Noto Kufi Arabic',sans-serif; font-size: clamp(24px,4vw,42px); font-weight: 800; line-height: 1.35; margin-bottom: 20px; text-shadow: 0 2px 20px rgba(0,0,0,0.2); }
.hero-slogan { display: inline-block; font-size: clamp(16px,2.5vw,22px); font-weight: 600; color: var(--secondary-light); background: rgba(200,168,78,0.12); border: 1px solid rgba(200,168,78,0.25); padding: 10px 32px; border-radius: var(--radius-lg); margin-bottom: 28px; backdrop-filter: blur(10px); }
.hero-meta { display: flex; justify-content: center; gap: 36px; flex-wrap: wrap; margin-bottom: 40px; }
.hero-meta-item { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 500; }
.hero-meta-item i { font-size: 18px; color: var(--secondary-light); }
.hero-minister { font-size: 15px; opacity: 0.85; margin-bottom: 40px; font-weight: 500; }
.hero-minister strong { color: var(--secondary-light); }

.countdown-wrap { display: flex; justify-content: center; gap: 16px; margin-bottom: 40px; flex-wrap: wrap; }
.countdown-item { background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.12); backdrop-filter: blur(20px); border-radius: var(--radius-lg); padding: 16px 20px; min-width: 90px; text-align: center; }
.countdown-item .number { display: block; font-family: 'Noto Kufi Arabic',sans-serif; font-size: 36px; font-weight: 800; color: var(--secondary-light); line-height: 1; }
.countdown-item .label { font-size: 12px; font-weight: 500; opacity: 0.8; margin-top: 4px; }

.quick-nav { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.quick-nav .btn { border-radius: var(--radius-md); padding: 10px 24px; font-weight: 600; font-size: 14px; transition: var(--transition); }
.btn-hero-primary { background: var(--secondary); color: var(--primary-dark); border: none; }
.btn-hero-primary:hover { background: var(--secondary-light); color: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(200,168,78,0.3); }
.btn-hero-outline { background: transparent; color: var(--white); border: 1.5px solid rgba(255,255,255,0.3); }
.btn-hero-outline:hover { background: rgba(255,255,255,0.1); color: var(--white); border-color: rgba(255,255,255,0.5); }

/* SECTIONS */
.section { padding: 80px 0; }
.section-header { text-align: center; margin-bottom: 48px; }
.section-title { font-family: 'Noto Kufi Arabic',sans-serif; font-size: 28px; font-weight: 800; color: var(--primary); margin-bottom: 12px; position: relative; display: inline-block; }
.section-title::after { content: ''; display: block; width: 60px; height: 3px; background: var(--secondary); margin: 12px auto 0; border-radius: 2px; }
.section-subtitle { font-size: 15px; color: var(--gray-500); max-width: 600px; margin: 0 auto; }

/* STATS */
.stats-bar { background: var(--white); padding: 32px 0; box-shadow: var(--shadow-md); position: relative; z-index: 5; margin-top: -30px; border-radius: var(--radius-xl); max-width: 1000px; margin-left: auto; margin-right: auto; }
.stat-item { text-align: center; padding: 16px; }
.stat-icon { width: 52px; height: 52px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: var(--white); border-radius: var(--radius-md); font-size: 22px; margin: 0 auto 12px; }
.stat-number { font-family: 'Noto Kufi Arabic',sans-serif; font-size: 28px; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 13px; color: var(--gray-500); font-weight: 500; }

/* PROGRAM */
.program-day-tabs .nav-link { background: var(--white); color: var(--primary); border: 2px solid var(--gray-200); border-radius: var(--radius-md); padding: 14px 28px; font-weight: 700; font-size: 15px; transition: var(--transition); }
.program-day-tabs .nav-link.active { background: var(--primary); color: var(--white); border-color: var(--primary); box-shadow: var(--shadow-md); }
.timeline-item { display: flex; gap: 20px; padding: 20px; margin-bottom: 12px; background: var(--white); border-radius: var(--radius-md); border-right: 4px solid var(--gray-200); transition: var(--transition); box-shadow: var(--shadow-sm); }
.timeline-item:hover { box-shadow: var(--shadow-md); transform: translateX(-4px); }
.timeline-item.type-speech { border-right-color: var(--primary); }
.timeline-item.type-presentation { border-right-color: var(--accent); }
.timeline-item.type-break, .timeline-item.type-lunch { border-right-color: var(--secondary); }
.timeline-item.type-discussion { border-right-color: var(--success); }
.timeline-item.type-opening, .timeline-item.type-closing { border-right-color: var(--primary-dark); }
.timeline-item.type-recommendations { border-right-color: #e91e63; }
.timeline-time { min-width: 70px; text-align: center; }
.timeline-time span { display: inline-block; background: var(--gray-100); color: var(--primary); font-weight: 700; font-size: 14px; padding: 6px 12px; border-radius: var(--radius-sm); }
.timeline-content h5 { font-size: 15px; font-weight: 700; color: var(--gray-900); margin-bottom: 4px; }
.timeline-content .speaker-name { font-size: 13px; color: var(--primary-light); font-weight: 600; }
.timeline-badge { display: inline-block; font-size: 11px; font-weight: 600; padding: 2px 10px; border-radius: 50px; margin-top: 6px; }
.badge-speech { background: rgba(10,61,107,0.1); color: var(--primary); }
.badge-presentation { background: rgba(33,150,243,0.1); color: var(--accent); }
.badge-break { background: rgba(200,168,78,0.15); color: #8a6d1b; }
.badge-discussion { background: rgba(40,167,69,0.1); color: var(--success); }

/* SPEAKERS */
.speaker-card { background: var(--white); border-radius: var(--radius-lg); padding: 28px 24px; text-align: center; box-shadow: var(--shadow-sm); transition: var(--transition); height: 100%; border: 1px solid var(--gray-200); }
.speaker-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-6px); border-color: var(--primary-light); }
.speaker-avatar { width: 80px; height: 80px; border-radius: 50%; background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: var(--white); display: flex; align-items: center; justify-content: center; font-size: 28px; font-weight: 800; margin: 0 auto 16px; border: 3px solid var(--secondary); }
.speaker-card h5 { font-size: 15px; font-weight: 700; color: var(--gray-900); margin-bottom: 6px; }
.speaker-card .position { font-size: 12px; color: var(--gray-500); margin-bottom: 12px; line-height: 1.5; }
.speaker-card .topic { font-size: 13px; color: var(--primary); font-weight: 600; background: rgba(10,61,107,0.05); padding: 8px 14px; border-radius: var(--radius-sm); line-height: 1.5; }

/* PARTICIPANTS */
.participants-filters { background: var(--white); padding: 20px; border-radius: var(--radius-lg); margin-bottom: 24px; box-shadow: var(--shadow-sm); }
.filter-btn { border: 1.5px solid var(--gray-200); background: var(--white); color: var(--gray-700); padding: 8px 18px; border-radius: var(--radius-sm); font-weight: 600; font-size: 13px; transition: var(--transition); cursor: pointer; font-family: 'Cairo',sans-serif; }
.filter-btn:hover, .filter-btn.active { background: var(--primary); color: var(--white); border-color: var(--primary); }
.participants-table { background: var(--white); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); }
.participants-table table { margin: 0; }
.participants-table thead { background: linear-gradient(135deg, var(--primary-dark), var(--primary)); color: var(--white); }
.participants-table thead th { font-weight: 600; font-size: 13px; padding: 14px 16px; border: none; }
.participants-table tbody td { padding: 12px 16px; font-size: 14px; border-color: var(--gray-100); vertical-align: middle; }
.participants-table tbody tr:hover { background: var(--gray-100); }
.region-badge { display: inline-block; padding: 3px 12px; border-radius: 50px; font-size: 12px; font-weight: 600; }
.region-tun { background: #e3f2fd; color: #1565c0; }
.region-north { background: #e8f5e9; color: #2e7d32; }
.region-center { background: #fff3e0; color: #e65100; }
.region-south1 { background: #fce4ec; color: #c62828; }
.region-south2 { background: #f3e5f5; color: #6a1b9a; }
.region-admin { background: var(--gray-100); color: var(--gray-700); }

/* DOCUMENTS */
.doc-card { background: var(--white); border-radius: var(--radius-md); padding: 24px; box-shadow: var(--shadow-sm); border: 1px solid var(--gray-200); transition: var(--transition); height: 100%; display: flex; flex-direction: column; }
.doc-card:hover { box-shadow: var(--shadow-md); border-color: var(--primary-light); }
.doc-icon { width: 52px; height: 52px; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; font-size: 22px; margin-bottom: 16px; }
.doc-icon.pdf { background: #ffeaea; color: #d32f2f; }
.doc-icon.ppt { background: #fff3e0; color: #e65100; }
.doc-icon.doc { background: #e3f2fd; color: #1565c0; }
.doc-icon.other { background: var(--gray-100); color: var(--gray-500); }
.doc-card h5 { font-size: 14px; font-weight: 700; margin-bottom: 8px; }
.doc-card .doc-meta { font-size: 12px; color: var(--gray-500); margin-top: auto; padding-top: 12px; border-top: 1px solid var(--gray-100); }

/* NEWS */
.news-card { background: var(--white); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); transition: var(--transition); height: 100%; }
.news-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.news-card-img { height: 200px; background: linear-gradient(135deg, var(--primary), var(--primary-light)); display: flex; align-items: center; justify-content: center; color: var(--white); font-size: 48px; }
.news-card-body { padding: 20px; }
.news-card-body h5 { font-size: 16px; font-weight: 700; margin-bottom: 8px; line-height: 1.5; }
.news-card-body p { font-size: 13px; color: var(--gray-500); line-height: 1.6; }
.news-date { font-size: 12px; color: var(--gray-500); display: flex; align-items: center; gap: 6px; }

/* RECOMMENDATIONS */
.rec-card { background: var(--white); border-radius: var(--radius-lg); padding: 28px; box-shadow: var(--shadow-sm); border-right: 5px solid var(--primary); margin-bottom: 16px; transition: var(--transition); }
.rec-card:hover { box-shadow: var(--shadow-md); }
.rec-number { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; background: var(--primary); color: var(--white); border-radius: 50%; font-weight: 800; font-size: 14px; margin-left: 14px; flex-shrink: 0; }

/* ABOUT */
.about-card { background: var(--white); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow-sm); border: 1px solid var(--gray-200); height: 100%; }
.about-icon { width: 56px; height: 56px; border-radius: var(--radius-md); background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: var(--white); display: flex; align-items: center; justify-content: center; font-size: 24px; margin-bottom: 16px; }

/* PAGE HEADER */
.page-header { background: linear-gradient(135deg, var(--primary-dark), var(--primary)); padding: 48px 0 56px; color: var(--white); position: relative; overflow: hidden; }
.page-header::after { content: ''; position: absolute; bottom: -2px; left: 0; right: 0; height: 40px; background: var(--off-white); clip-path: ellipse(55% 100% at 50% 100%); }
.page-header h1 { font-family: 'Noto Kufi Arabic',sans-serif; font-size: 30px; font-weight: 800; margin-bottom: 8px; }
.page-header .breadcrumb { background: none; padding: 0; margin: 0; }
.page-header .breadcrumb-item, .page-header .breadcrumb-item a { color: rgba(255,255,255,0.7); font-size: 13px; }
.page-header .breadcrumb-item.active { color: var(--secondary-light); }

/* FOOTER */
.footer { background: linear-gradient(135deg, var(--primary-dark), var(--gray-900)); color: var(--white); padding: 60px 0 0; }
.footer-brand img { height: 56px; margin-bottom: 16px; }
.footer h5 { font-size: 15px; font-weight: 700; margin-bottom: 20px; color: var(--secondary-light); }
.footer-links { list-style: none; padding: 0; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: rgba(255,255,255,0.7); text-decoration: none; font-size: 13px; transition: var(--transition); }
.footer-links a:hover { color: var(--white); padding-right: 8px; }
.footer-contact-item { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 12px; color: rgba(255,255,255,0.7); font-size: 13px; }
.footer-contact-item i { color: var(--secondary); margin-top: 4px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding: 20px 0; margin-top: 40px; text-align: center; font-size: 12px; color: rgba(255,255,255,0.5); }

/* SEARCH */
.search-input { border: 2px solid var(--gray-200); border-radius: var(--radius-md); padding: 10px 16px; padding-right: 42px; font-family: 'Cairo',sans-serif; font-size: 14px; transition: var(--transition); }
.search-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(10,61,107,0.1); outline: none; }

/* BUTTONS */
.btn-primary-custom { background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: var(--white); border: none; border-radius: var(--radius-md); padding: 10px 24px; font-weight: 600; font-size: 14px; transition: var(--transition); }
.btn-primary-custom:hover { background: linear-gradient(135deg, var(--primary-dark), var(--primary)); color: var(--white); box-shadow: var(--shadow-md); transform: translateY(-1px); }

/* ADMIN */
.admin-sidebar { background: linear-gradient(180deg, var(--primary-dark), var(--primary)); min-height: 100vh; width: 260px; position: fixed; right: 0; top: 0; z-index: 1040; padding-top: 20px; overflow-y: auto; }
.admin-sidebar .brand { color: var(--white); padding: 0 20px 20px; border-bottom: 1px solid rgba(255,255,255,0.1); margin-bottom: 10px; }
.admin-sidebar .nav-link { color: rgba(255,255,255,0.75); padding: 10px 24px; font-size: 14px; font-weight: 500; display: flex; align-items: center; gap: 10px; transition: var(--transition); }
.admin-sidebar .nav-link:hover, .admin-sidebar .nav-link.active { background: rgba(255,255,255,0.1); color: var(--white); }
.admin-sidebar .nav-link i { width: 20px; text-align: center; }
.admin-content { margin-right: 260px; padding: 24px; min-height: 100vh; background: var(--off-white); }
.admin-header { background: var(--white); padding: 16px 24px; border-radius: var(--radius-md); box-shadow: var(--shadow-sm); margin-bottom: 24px; display: flex; justify-content: space-between; align-items: center; }
.admin-card { background: var(--white); border-radius: var(--radius-md); padding: 24px; box-shadow: var(--shadow-sm); margin-bottom: 24px; }
.admin-stat { background: var(--white); border-radius: var(--radius-md); padding: 24px; box-shadow: var(--shadow-sm); display: flex; align-items: center; gap: 16px; }
.admin-stat .icon { width: 56px; height: 56px; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; font-size: 24px; }
.admin-stat .number { font-size: 28px; font-weight: 800; }
.admin-stat .label { font-size: 13px; color: var(--gray-500); }

/* LOGIN */
.login-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--primary-dark), var(--primary)); padding: 20px; }
.login-card { background: var(--white); border-radius: var(--radius-xl); padding: 40px; width: 100%; max-width: 420px; box-shadow: var(--shadow-xl); }
.login-card h2 { font-family: 'Noto Kufi Arabic',sans-serif; color: var(--primary); font-size: 22px; margin-bottom: 8px; }

/* FORMS */
.form-control, .form-select { font-family: 'Cairo',sans-serif; border: 1.5px solid var(--gray-200); border-radius: var(--radius-sm); padding: 10px 14px; font-size: 14px; transition: var(--transition); }
.form-control:focus, .form-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(10,61,107,0.08); }
.form-label { font-weight: 600; font-size: 13px; color: var(--gray-700); margin-bottom: 6px; }

/* UTILITIES */
.bg-primary-gradient { background: linear-gradient(135deg, var(--primary), var(--primary-light)); }
.text-primary-custom { color: var(--primary) !important; }
.animate-fade-in { animation: fadeInUp 0.6s ease forwards; opacity: 0; }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* RESPONSIVE */
@media (max-width: 992px) {
    .navbar-main .navbar-brand img { height: 36px; }
    .navbar-main .navbar-brand span { font-size: 12px; }
    .hero-section { min-height: auto; }
    .hero-content { padding: 40px 0 80px; }
    .countdown-item { min-width: 70px; padding: 12px; }
    .countdown-item .number { font-size: 26px; }
    .stats-bar { margin: -20px 16px 0; }
    .section { padding: 50px 0; }
    .admin-sidebar { display: none; }
    .admin-content { margin-right: 0; }
    .footer-brand img { height: 42px; }
}
@media (max-width: 576px) {
    .navbar-main .navbar-brand img { height: 30px; }
    .navbar-main .navbar-brand span { font-size: 11px; }
    .hero-title { font-size: 22px; }
    .hero-slogan { font-size: 15px; padding: 8px 20px; }
    .hero-meta { gap: 16px; }
    .countdown-wrap { gap: 8px; }
    .countdown-item { min-width: 60px; padding: 8px; }
    .countdown-item .number { font-size: 22px; }
    .page-header h1 { font-size: 22px; }
    .section-title { font-size: 22px; }
    .footer-brand img { height: 36px; }
}
@media print { .navbar-main, .footer, .quick-nav, .countdown-wrap { display: none; } .hero-section { min-height: auto; padding: 20px; } }
