/* ========== کانتینر اصلی ========== */
.edu-nav-container {
    max-width: 1000px;
    margin: 20px auto;
    padding: 20px;
    font-family: 'Vazir', Tahoma, 'Segoe UI', sans-serif;
    direction: rtl;
    background: #f9f9f9;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.edu-nav-form {
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    border: 1px solid #e0e0e0;
}

.edu-nav-step {
    margin-bottom: 15px;
}

.edu-nav-step label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
    color: #333;
    font-size: 14px;
}

.edu-nav-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
    background: #fff;
    transition: 0.2s;
}

.edu-nav-select:focus {
    border-color: #0073aa;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0,115,170,0.1);
}

.edu-nav-path {
    margin: 15px 0;
    padding: 10px 15px;
    background: #f0f7ff;
    border-radius: 8px;
    font-size: 14px;
    color: #333;
    min-height: 30px;
}

.edu-path-label {
    color: #666;
}

.edu-path-items {
    font-weight: bold;
    color: #0073aa;
}

.edu-nav-submit {
    background: #0073aa;
    color: #fff;
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    transition: 0.2s;
    margin-top: 10px;
}

.edu-nav-submit:hover {
    background: #005a87;
}

.edu-nav-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ====== گرید محصولات ====== */
.edu-books-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.edu-book-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e0e0e0;
    overflow: hidden;
    transition: 0.3s;
    display: flex;
    flex-direction: column;
}

.edu-book-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.edu-book-image-wrapper {
    width: 100%;
    aspect-ratio: 300 / 440;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.edu-book-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #f5f5f5;
}

.edu-book-no-image {
    font-size: 60px;
    color: #ccc;
}

.edu-book-info {
    padding: 15px 18px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.edu-book-title {
    margin: 0 0 8px 0;
    font-size: 17px;
    color: #0073aa;
}

.edu-book-meta {
    margin-bottom: 8px;
}

.edu-type-badge {
    display: inline-block;
    background: #e9ecef;
    color: #495057;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 12px;
}

.edu-book-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    border-top: 1px solid #eee;
    padding-top: 12px;
    margin-top: auto;
}

.edu-book-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.edu-book-price {
    color: #e67e22;
    font-weight: bold;
    font-size: 16px;
}

.edu-book-link {
    background: #0073aa;
    color: #fff !important;
    padding: 6px 14px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 13px;
    transition: 0.2s;
    white-space: nowrap;
}

.edu-book-link:hover {
    background: #005a87;
}

.edu-demo-link {
    background: #6c757d;
}

.edu-demo-link:hover {
    background: #5a6268;
}

.edu-no-results {
    text-align: center;
    color: #999;
    padding: 30px;
    font-size: 16px;
}

.edu-error {
    color: #dc3232;
    text-align: center;
    padding: 20px;
}

/* ====== فیلد جستجو ====== */
.edu-search-input {
    width: 100%;
    padding: 8px 12px;
    margin-bottom: 8px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
    direction: rtl;
}

.edu-search-input:focus {
    border-color: #0073aa;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0,115,170,0.1);
}

.edu-search-results {
    position: relative;
    width: 100%;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    margin-bottom: 8px;
    max-height: 200px;
    overflow-y: auto;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 1000;
}

.edu-search-item {
    padding: 8px 12px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: 0.2s;
    font-size: 14px;
}

.edu-search-item:hover {
    background: #f0f7ff !important;
}

.edu-search-item-selected {
    background: #e8f0fe;
    font-weight: bold;
}

.edu-search-item:last-child {
    border-bottom: none;
}

.edu-search-results::-webkit-scrollbar {
    width: 6px;
}
.edu-search-results::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}
.edu-search-results::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 10px;
}
.edu-search-results::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* ====== صفحه‌بندی ====== */
.edu-pagination {
    text-align: center;
    margin-top: 20px;
    direction: ltr;
}

.edu-page-btn {
    margin: 0 5px;
    padding: 8px 14px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    color: #333;
    cursor: pointer;
    transition: 0.2s;
}

.edu-page-btn:hover {
    background: #e9e9e9;
}

.edu-page-btn.active {
    background: #0073aa !important;
    color: #fff !important;
    border-color: #0073aa;
}

.edu-page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ====== ریسپانسیو ====== */
@media (max-width: 600px) {
    .edu-nav-container {
        padding: 12px;
    }
    .edu-nav-form {
        padding: 12px;
    }
    .edu-books-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 15px;
    }
    .edu-book-title {
        font-size: 15px;
    }
    .edu-book-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    .edu-book-actions {
        justify-content: center;
    }
    .edu-book-link {
        text-align: center;
    }
}
@media (min-width: 601px) and (max-width: 900px) {
    .edu-books-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 20px;
    }
}