/* البحث */
.search-section {
    margin-bottom: 30px;
}

.search-wrapper {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    padding: 20px;
}

.search-box {
    position: relative;
    margin-bottom: 20px;
}

.search-box input {
    width: 100%;
    padding: 12px 50px 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
}

.search-box input:focus {
    border-color: #374868;
    outline: none;
}

.search-btn {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: #374868;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 8px 15px;
    cursor: pointer;
}

/* تبويبات التصنيف */
.category-tabs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.category-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 15px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    color: #6c757d;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
}

.category-tab:hover {
    background: #e9ecef;
}

.category-tab.active {
    background: #374868;
    border-color: #374868;
    color: white;
}

/* بطاقات المصطلحات */
.terminology-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.term-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
    transition: all 0.3s;
    border: 1px solid #eee;
}

.term-card:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    transform: translateY(-3px);
}

.term-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.term-name {
    margin: 0;
    color: #2c3e50;
    font-size: 1.2rem;
    font-weight: 600;
}

.term-category {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    color: white;
}

.term-grade {
    margin: 10px 0;
    color: #495057;
}

.grade-value {
    font-weight: bold;
    color: #374868;
}

.term-definition {
    color: #6c757d;
    line-height: 1.6;
    margin: 15px 0;
    font-size: 14px;
    min-height: 60px;
}

.view-details {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #374868;
    text-decoration: none;
    font-weight: 500;
    margin-top: 10px;
}

.view-details:hover {
    color: #374868;
}

/* صفحة التفاصيل */
.term-detail-card {
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.1);
    padding: 30px;
    max-width: 800px;
    margin: 0 auto;
}

.term-header-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.term-title {
    margin: 0;
    color: #2c3e50;
    font-size: 2rem;
    font-weight: 700;
}

.term-category-detail {
    display: inline-block;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    color: white;
    margin-top: 10px;
}

.term-grade-badge {
    text-align: center;
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    min-width: 80px;
}

.grade-number {
    font-size: 2rem;
    font-weight: bold;
    color: #374868;
}

.grade-label {
    color: #6c757d;
    font-size: 14px;
}

.term-content {
    margin: 30px 0;
}

.term-content h3 {
    color: #2c3e50;
    margin: 25px 0 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f1f1f1;
}

.description-text {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    line-height: 1.8;
    color: #495057;
}

.analysis-content {
    background: #fff;
    border-left: 4px solid #374868;
    padding: 15px;
    border-radius: 0 8px 8px 0;
}

.examples-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.example-item {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
}

.example-item h4 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 16px;
}

.term-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.meta-item i {
    color: #374868;
    font-size: 20px;
}

.meta-item small {
    display: block;
    color: #6c757d;
    font-size: 12px;
}

.term-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

/* لا توجد نتائج */
.no-results {
    background: white;
    border-radius: 10px;
    padding: 50px 20px;
    text-align: center;
}

.results-info {
    text-align: center;
    color: #6c757d;
    font-size: 14px;
}

/* تجاوب */
@media (max-width: 768px) {
    .terminology-grid {
        grid-template-columns: 1fr;
    }
    
    .term-header-detail {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .term-meta {
        grid-template-columns: 1fr;
    }
    
    .term-actions {
        flex-direction: column;
    }
    
    .term-actions .th-btn {
        width: 100%;
    }
}
.space {
  padding-top: 0;
}