:root {
    --primary: #009FB7;
    --primary-dark: #007C8A;
    --primary-light: #00B8D2;

    --secondary: #7A2A55;
    --secondary-dark: #5A193B;

    --gray-900: #1a1a1a;
    --gray-700: #444;
    --gray-500: #777;
    --gray-300: #ddd;
    --gray-100: #f5f5f5;

    --radius: 14px;
    --radius-sm: 10px;

    --shadow-soft: 0 4px 18px rgba(0,0,0,0.08);
    --shadow-hover: 0 6px 22px rgba(0,0,0,0.12);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

@font-face {
    font-family: 'Cairo';
    src: url('../fonts/Cairo-Regular.woff2') format('woff2'),
         url('../fonts/Cairo-Regular.woff') format('woff'),
         url('../fonts/Cairo-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}

body {
    font-family: "Cairo", sans-serif;
    background: #ffffff;
    color: #222;
}

input, textarea, select, button {
    font-family: 'Cairo', sans-serif !important;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* CONTAINER */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* TYPOGRAPHY UTILITIES */
.page-title {
    text-align: center;
    font-size: 32px;
    font-weight: 800;
    margin: 40px 0 30px;
}

/* =========================================
   NAVBAR
========================================= */
.navbar {
    width: 100%;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Brand */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-circle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #009FB7;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.brand-text span {
    display: block;
    line-height: 1.1;
}

.brand-title {
    font-weight: 700;
    font-size: 17px;
    color: #000;
}

.brand-subtitle {
    font-size: 13px;
    color: #777;
}

/* Menu */
.navbar-menu {
    display: flex;
    align-items: center;
    gap: 24px;
}

.navbar-links {
    display: flex;
    gap: 18px;
}

.navbar-links a {
    font-size: 15px;    
    transition: color .2s;
}
.workshop-card {
    border-radius: var(--radius);
}

.workshop-cover {
    height: 190px;
    transition: .4s;
}

.workshop-card:hover .workshop-cover {
    transform: scale(1.03);
}


/* ===============================
   زر تحميل الشهادة
=============================== */
.cert-download-btn {
    background: red !important;
    color: #fff !important;
}

.cert-download-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    width: 100%;
    padding: 12px 20px;
    margin-top: 12px;

    background: linear-gradient(135deg, #198754, #146c43);
    color: #fff;
    text-decoration: none;

    font-size: 15px;
    font-weight: 700;

    border-radius: 8px;
    box-shadow: 0 6px 14px rgba(0,0,0,0.15);

    transition: all 0.3s ease;
}

.cert-download-btn i {
    font-size: 18px;
}

/* Hover */
.cert-download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 22px rgba(0,0,0,0.25);
    background: linear-gradient(135deg, #1faa6f, #198754);
}

/* Active */
.cert-download-btn:active {
    transform: scale(0.98);
}

/* Login button */
.btn-login {
    padding: 8px 16px;
    background: #007C8A;
    color: #fff;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: background .2s, transform .2s;
}

.btn-login:hover {
    background: #006473;
    transform: translateY(-1px);
}

/* Burger for mobile */
.navbar-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}
.navbar {
    background: #fff;
    border-bottom: 1px solid var(--gray-300);
    box-shadow: 0 3px 10px rgba(0,0,0,0.03);
}

.navbar-links a {
    color: var(--gray-900);
    font-weight: 700;
}

.navbar-links a:hover {
    color: var(--primary-dark);
}
/* =========================================
   HERO (Home)
========================================= */

.home .hero {
    position: relative;
    padding: 80px 0;
    text-align: center;
    overflow: hidden;

    /* صورة الخلفية */
    background-image: url("/assets/images/herobg.png"); /* عدل المسار */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* الطبقة السوداء الخفيفة */
.home .hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(1, 43, 54, 0.673); /* شفافية اللون */
    z-index: 1;
}

/* محتوى الهيرو */
.home .hero-container {
    position: relative;
    z-index: 2;
}

/* العنوان */
.home .hero h1 {
    font-size: 36px;
    font-weight: 800;
    color: #ffffff;
}

/* الوصف */
.home .hero p {
    margin-top: 12px;
    font-size: 18px;
    color: #f1f1f1;
    line-height: 1.8;
}

/* موبايل */
@media (max-width: 768px) {
    .home .hero {
        padding: 60px 15px;
    }

    .home .hero h1 {
        font-size: 28px;
    }

    .home .hero p {
        font-size: 16px;
    }
}

/* =========================================
   HOME GRID (Workshops + News)
========================================= */
.content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 25px;
    margin: 40px auto 60px;
}

.card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e2e2e2;
    padding: 18px 20px;
}

/* Section header */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.section-header h2 {
    font-size: 20px;
    font-weight: 700;
}

.section-sub {
    font-size: 14px;
    color: #777;
    margin-bottom: 12px;
}

/* Small button */
.btn-small {
    padding: 8px 14px;
    font-size: 14px;
    border-radius: 8px;
    border: none;
    background: #007C8A;
    color: #fff;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: background .2s, transform .2s;
}

.btn-small i {
    font-size: 13px;
}

.btn-small:hover {
    background: #006473;
    transform: translateY(-1px);
}

/* =========================================
   HOME – Workshops Accordion
========================================= */
.workshop-list {
    margin-top: 8px;
}

.workshop-item {
    border-bottom: 1px solid #eee;
    padding: 10px 0;
}

.workshop-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    border: none;
    background: none;
    cursor: pointer;
    text-align: right;
}

.workshop-header h3 {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 4px;
}

.workshop-meta span {
    font-size: 13px;
    color: #666;
    margin-inline-end: 10px;
}

.toggle-icon {
    font-size: 18px;
    color: #007C8A;
}

/* Body */
.workshop-body {
    margin-top: 8px;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s ease, opacity .3s ease;
}

.workshop-item.open .workshop-body {
    opacity: 1;
}

.workshop-body .desc {
    font-size: 14px;
    color: #444;
    margin-bottom: 10px;
}

/* Apply buttons */
.btn-apply {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: none;
    background: #007C8A;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    transition: background .2s, transform .2s;
}

.btn-apply.green {
    background: #198754;
}

.btn-apply:hover {
    background: #006473;
    transform: translateY(-1px);
}

/* =========================================
   HOME – News List (side)
========================================= */
.news-card {
    /* unused here; for global page we use .news-page .news-card */
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.news-item {
    display: flex;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.news-img {
    width: 110px;
    height: 80px;
    border-radius: 10px;
    object-fit: cover;
}

.news-content h3 {
    font-size: 16px;
    margin-bottom: 4px;
}

.news-text {
    max-height: 46px;
    overflow: hidden;
    color: #555;
    line-height: 1.7;
    transition: max-height .4s ease;
    font-size: 14px;
}

.news-text.expanded {
    max-height: 2000px;
}

.news-more {
    margin-top: 4px;
    font-size: 14px;
    background: none;
    border: none;
    color: #007C8A;
    cursor: pointer;
    font-weight: 600;
}

/* =========================================
   WORKSHOPS PAGE
========================================= */
.workshops-page {
    margin-top: 40px;
    margin-bottom: 60px;
}

/* Search */
.search-box {
    max-width: 550px;
    margin: 0 auto 25px;
    display: flex;
    gap: 10px;
}

.search-box input {
    flex: 1;
    padding: 12px 13px;
    border-radius: 10px;
    border: 1px solid #ccc;
    font-size: 15px;
}

.search-box button {
    padding: 0 22px;
    border-radius: 10px;
    border: none;
    background: #007C8A;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.search-box button:hover {
    background: #006473;
}

/* Tabs */
.filters-tabs {
    text-align: center;
    margin-bottom: 25px;
}
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: .25s ease;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: var(--secondary);
    color: #fff;
}

.btn-secondary:hover {
    background: var(--secondary-dark);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: #fff;
}
.card,
.workshop-card,
.news-card,
.modal-box {
    box-shadow: var(--shadow-soft);
    transition: .25s ease;
}

.card:hover,
.workshop-card:hover,
.news-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-3px);
}

[data-animate] {
    opacity: 0;
    transform: translateY(20px) scale(.98);
    transition: opacity .5s ease, transform .5s ease;
}

[data-animate].in-view {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.tab-btn {
    padding: 9px 18px;
    margin: 4px;
    border-radius: 10px;
    border: none;
    background: #f2f2f2;
    cursor: pointer;
    font-size: 14px;
    transition: background .2s, color .2s, box-shadow .2s;
}

.tab-btn:hover {
    background: #e4e4e4;
}

.tab-btn.active {
    background: #007C8A;
    color: #fff;
    box-shadow: 0 3px 10px rgba(0,124,138,0.3);
}

/* Grid */
.workshops-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
    gap: 26px;
}

/* Card */
.workshop-card {
    background: #fff;
    overflow: hidden;
    box-shadow: 0 3px 14px rgba(0,0,0,0.08);
    transition: transform .25s, box-shadow .25s;
}

.workshop-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.workshop-cover {
    background-size: cover;
    background-position: center;
}

/* Content */
.workshop-content {
    padding: 18px 20px 20px;
}

.workshop-title {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 8px;
}

.workshop-content .workshop-meta {
    font-size: 13px;
    color: #555;
    margin-bottom: 14px;
}

.workshop-content .workshop-meta span {
    margin-inline-end: 10px;
}

/* Description */
.workshop-desc {
    font-size: 14px;
    color: #444;
    line-height: 1.7;
    margin-bottom: 16px;
    height: 45px;
    overflow: hidden;
}

/* Buttons */
.btn-register,
.btn-pdf {
    width: 100%;
    padding: 11px;
    border-radius: 10px;
    border: none;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    transition: background .2s, transform .2s;
}

.btn-register {
    background: #009FB7;
    color: #fff;
}

.btn-register:hover {
    background: #007C8A;
    transform: translateY(-1px);
}

.btn-pdf {
    background: #7A2A55;
    color: #fff;
}

.btn-pdf:hover {
    background: #5a193b;
    transform: translateY(-1px);
}

/* =========================================
   NEWS PAGE
========================================= */
.news-page {
    margin-top: 40px;
    margin-bottom: 60px;
}

.news-page .news-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.news-page .news-card {
    display: flex;
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #e3e3e3;
    transition: .25s;
}
.news-page .news-card {
    border-radius: var(--radius);
}

.news-page .news-img {
    transition: .4s;
}

.news-page .news-card:hover .news-img {
    transform: scale(1.05);
}

.news-page .news-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

.news-img-wrapper {
    width: 200px;
    flex-shrink: 0;
}

.news-page .news-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Content */
.news-page .news-content {
    padding: 18px 20px;
    flex: 1;
}

.news-page .news-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.news-page .news-summary {
    font-size: 15px;
    color: #444;
    line-height: 1.8;
    margin-bottom: 10px;
}

.news-page .news-date {
    font-size: 14px;
    color: #777;
}

/* =========================================
   FOOTER
========================================= */
.footer {
    background: #f5f7fa;
    border-top: 1px solid #e0e0e0;
    padding: 30px 0;
    margin-top: 40px;
}

.footer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    text-align: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-logo {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #009FB7;
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-text h3 {
    font-size: 17px;
    font-weight: 700;
}

.footer-text p {
    font-size: 14px;
    color: #777;
}

.footer-copy {
    font-size: 14px;
    color: #444;
}

/* =========================================
   MODALS (الستايل الفخم)
========================================= */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.55);
    display: none;
    justify-content: center;
    align-items: center;
    padding: 40px 15px;
    z-index: 9999;
    overflow-y: auto;
}

.modal-overlay.active {
    display: flex;
}

.modal-box {
    background: #fff;
    width: 100%;
    max-width: 460px;
    border-radius: 16px;
    padding: 25px 28px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    animation: modalPop .25s ease;
    max-height: 95vh;
    overflow-y: auto;
}
.modal-box {
    border-radius: var(--radius);
    animation: modalPop .3s cubic-bezier(0.25, 1, 0.35, 1);
}

@keyframes modalPop {
    from {
        transform: translateY(20px) scale(.92);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes modalPop {
    0% { transform: translateY(25px) scale(.95); opacity: 0; }
    100% { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-close {
    border: none;
    background: none;
    font-size: 22px;
    position: absolute;
    top: 12px;
    left: 12px;
    cursor: pointer;
    color: #555;
}

.modal-close:hover {
    color: #000;
}

.modal-title {
    font-size: 21px;
    font-weight: 800;
    margin-bottom: 18px;
    text-align: center;
    color: #007C8A;
}

/* Modal form */
.modal-form .form-group {
    margin-bottom: 12px;
}

.modal-form label {
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 5px;
    display: block;
}

.modal-form .req {
    color: red;
}

.modal-form input,
.modal-form textarea {
    width: 100%;
    border-radius: 10px;
    border: 1px solid #dcdcdc;
    padding: 10px 12px;
    font-size: 15px;
    transition: border-color .2s, box-shadow .2s;
}

.modal-form input:focus,
.modal-form textarea:focus {
    border-color: #009FB7;
    box-shadow: 0 0 0 3px rgba(0,159,183,.18);
    outline: none;
}

/* Modal submit */
.btn-primary-full {
    width: 100%;
    padding: 11px;
    border-radius: 12px;
    border: none;
    background: #009FB7;
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
    transition: background .2s, transform .2s;
}

.btn-primary-full:hover {
    background: #007C8A;
    transform: translateY(-1px);
}

.btn-text { }
.btn-loading { display: none; }

.modal-results {
    margin-top: 15px;
    font-size: 14px;
}

/* Disable scroll behind modal */
body.modal-open {
    overflow: hidden;
}

/* =========================================
   RESPONSIVE
========================================= */
@media (max-width: 900px) {
    .content-grid {
        grid-template-columns: 1fr;
    }

    .navbar-toggle {
        display: block;
    }

    .navbar-menu {
        position: fixed;
        top: 70px;
        right: -100%;
        width: 260px;
        height: calc(100vh - 70px);
        background: #ffffff;
        flex-direction: column;
        align-items: flex-start;
        padding: 20px;
        gap: 18px;
        box-shadow: -4px 0 20px rgba(0,0,0,0.08);
        transition: right .3s;
    }

    .navbar-menu.active {
        right: 0;
    }

    .navbar-links {
        flex-direction: column;
        gap: 12px;
    }
}

@media (max-width: 700px) {
    .news-page .news-card {
        flex-direction: column;
        text-align: center;
    }

    .news-img-wrapper {
        width: 100%;
        height: 200px;
    }

    .news-page .news-img {
        height: 100%;
    }

    .search-box {
        flex-direction: column;
    }

    .search-box button {
        width: 100%;
        justify-content: center;
        padding: 10px 0;
    }
}

@media (max-width: 500px) {
    .hero h1 {
        font-size: 26px;
    }
}