:root {
        --bg: #ffffff;
        --surface: #f3f4f6;
        --card: #ffffff;
        --purple: #6d28d9;
        --purple-light: #ede9fe;
        --text: #111827;
        --muted: #4b5563;
        --border: #e5e7eb;
      }
      * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
      }
      body {
        font-family: "Cairo", sans-serif;
        background: var(--bg);
        color: var(--text);
        min-height: 100vh;
        line-height: 1.6;
      }

      /* ── HEADER ── */
       /* الهيدر */
        .header {
            background: linear-gradient(135deg, #6a1b9a 0%, #9c27b0 100%);
            color: white;
            padding: 0;
            box-shadow: 0 2px 14px rgba(106,27,154,0.35);
            position: sticky;
            top: 0;
            z-index: 100;
        }

        .navbar {
            display: flex;
            justify-content: space-between;
            align-items: center;
            max-width: 1200px;
            margin: 0 auto;
            padding: 0 24px;
            height: 68px;
        }

        /* اللوجو */
        .logo-wrapper {
            display: flex;
            align-items: center;
            gap: 10px;
            text-decoration: none;
        }

        .logo {
            width: 54px;
            height: 54px;
            object-fit: contain;
            /* mix-blend-mode: screen يجعل الأبيض شفافاً على الخلفية الملونة */
            mix-blend-mode: screen;
            filter: brightness(1.15) contrast(1.1);
            transition: transform 0.25s ease, opacity 0.25s ease;
        }

        .logo-wrapper:hover .logo {
            transform: scale(1.08);
            opacity: 0.85;
        }

        .logo-text {
            display: flex;
            flex-direction: column;
            line-height: 1.25;
        }

        .logo-title {
            font-size: 17px;
            font-weight: bold;
            color: #fff;
            letter-spacing: 0.4px;
        }

        .logo-sub {
            font-size: 11px;
            color: rgba(255,255,255,0.65);
        }

        /* زر الرئيسية */
        .nav-links a {
            display: flex;
            align-items: center;
            gap: 7px;
            color: rgba(255,255,255,0.9);
            text-decoration: none;
            font-size: 14px;
            padding: 8px 16px;
            border-radius: 8px;
            background: rgba(255,255,255,0.12);
            border: 1px solid rgba(255,255,255,0.2);
            transition: background 0.2s, border-color 0.2s;
            margin-left: 0;
        }

        .nav-links a:hover {
            background: rgba(255,255,255,0.22);
            border-color: rgba(255,255,255,0.35);
        }
      header {
        background: var(--purple);
        position: sticky;
        top: 0;
        z-index: 300;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
        color: white;
      }
      .hdr {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 12px 24px;
      }
      .brand {
        display: flex;
        align-items: center;
        gap: 15px;
      }
      .brand-ico {
        width: 45px;
        height: 45px;
        background: white;
        border-radius: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 26px;
        font-weight: 900;
        color: var(--purple);
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
      }
      .brand-name {
        font-size: 22px;
        font-weight: 800;
        letter-spacing: 1px;
      }
      .brand-sub {
        font-size: 11px;
        opacity: 0.9;
      }

      /* ── MAIN ── */
      main {
        max-width: 1200px;
        margin: 0 auto;
        padding: 30px 20px;
      }

      /* ── HERO ── */
      .hero {
        text-align: center;
        margin-bottom: 40px;
      }
      .hero h1 {
        font-size: 32px;
        font-weight: 900;
        color: var(--purple);
        margin-bottom: 10px;
      }
      .hero p {
        font-size: 14px;
        color: var(--muted);
      }

      /* ── SEARCH ── */
      .search-area {
        max-width: 600px;
        margin: 0 auto 40px;
        position: relative;
      }
      .search-area input {
        width: 100%;
        padding: 14px 45px 14px 20px;
        border: 2px solid var(--border);
        border-radius: 30px;
        font-family: "Cairo", sans-serif;
        font-size: 15px;
        outline: none;
        transition: all 0.3s;
      }
      .search-area input:focus {
        border-color: var(--purple);
        box-shadow: 0 0 0 4px var(--purple-light);
      }
      .search-ico {
        position: absolute;
        right: 18px;
        top: 50%;
        transform: translateY(-50%);
        color: var(--muted);
        font-size: 18px;
      }

      /* ── GRID ── */
      .grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
        gap: 20px;
      }

      /* ── CARD ── */
      .card {
        background: var(--card);
        border: 1px solid var(--border);
        border-radius: 15px;
        overflow: hidden;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        flex-direction: column;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
      }
      .card:hover {
        transform: translateY(-5px);
        border-color: var(--purple);
        box-shadow: 0 10px 20px rgba(109, 40, 217, 0.1);
      }
      .card-top {
        padding: 20px;
        flex-grow: 1;
      }
      .card-path {
        font-size: 10px;
        font-weight: 700;
        color: var(--purple);
        text-transform: uppercase;
        margin-bottom: 8px;
        background: var(--purple-light);
        display: inline-block;
        padding: 2px 8px;
        border-radius: 5px;
      }
      .card-title {
        font-size: 16px;
        font-weight: 800;
        margin-bottom: 10px;
        color: var(--text);
      }
      .card-desc {
        font-size: 13px;
        color: var(--muted);
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
      }
      .card-footer {
        padding: 12px 20px;
        background: var(--surface);
        border-top: 1px solid var(--border);
        font-size: 11px;
        font-weight: 600;
        color: var(--muted);
      }

      /* ── OVERLAY ── */
      .overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(5px);
        z-index: 1000;
        align-items: center;
        justify-content: center;
        padding: 20px;
      }
      .overlay.open {
        display: flex;
      }
      .panel {
        background: white;
        width: 100%;
        max-width: 700px;
        border-radius: 20px;
        overflow: hidden;
        box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
        animation: slideUp 0.3s ease-out;
      }
      @keyframes slideUp {
        from {
          transform: translateY(20px);
          opacity: 0;
        }
        to {
          transform: translateY(0);
          opacity: 1;
        }
      }

      .panel-hdr {
        padding: 25px;
        background: var(--purple);
        color: white;
        position: relative;
      }
      .panel-title {
        font-size: 20px;
        font-weight: 800;
        margin-bottom: 5px;
      }
      .panel-path {
        font-size: 12px;
        opacity: 0.9;
      }
      .close-btn {
        position: absolute;
        left: 20px;
        top: 25px;
        background: rgba(255, 255, 255, 0.2);
        border: none;
        color: white;
        width: 35px;
        height: 35px;
        border-radius: 50%;
        cursor: pointer;
        font-size: 18px;
        display: flex;
        align-items: center;
        justify-content: center;
      }
      .close-btn:hover {
        background: rgba(255, 255, 255, 0.3);
      }

      .panel-body {
        padding: 30px;
      }
      .info-sec {
        margin-bottom: 25px;
      }
      .info-label {
        font-size: 12px;
        font-weight: 800;
        color: var(--purple);
        text-transform: uppercase;
        margin-bottom: 8px;
        display: block;
      }
      .info-content {
        font-size: 15px;
        background: var(--surface);
        padding: 15px;
        border-radius: 10px;
        border-right: 4px solid var(--purple);
      }
      .action-box {
        background: var(--purple-light);
        border: 1px solid var(--purple);
        color: var(--purple);
        font-weight: 700;
      }

      #empty {
        display: none;
        text-align: center;
        padding: 100px 20px;
        color: var(--muted);
        font-size: 18px;
      }