/* Enhanced Search and Admin Panel Styles */
/* Simple, clean design for News Management System */

/* ========== SEARCH COMPONENT STYLES ========== */

.enhanced-search-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Arial', sans-serif;
}

.search-box {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.search-input {
    flex: 1;
    min-width: 250px;
    padding: 12px 16px;
    font-size: 16px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.3s;
}

.search-input:focus {
    border-color: #007cba;
    box-shadow: 0 0 0 3px rgba(0, 124, 186, 0.1);
}

.search-btn {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    background: #007cba;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s, transform 0.1s;
}

.search-btn:hover {
    background: #0056b3;
    transform: translateY(-1px);
}

.clear-btn {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s;
}

.clear-btn:hover {
    background: #5a6268;
}

.filter-controls {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.filter-group label {
    font-size: 14px;
    font-weight: 600;
    color: #495057;
}

.filter-select {
    padding: 8px 12px;
    font-size: 14px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    background: white;
    cursor: pointer;
    min-width: 150px;
}

.results-info {
    padding: 12px;
    margin-bottom: 20px;
    background: #e7f3ff;
    border-left: 4px solid #007cba;
    border-radius: 4px;
    font-weight: 600;
    color: #004085;
}

.search-results {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.result-item {
    padding: 20px;
    background: white;
    border: 1px solid #dee2e6;
    border-left: 4px solid #007cba;
    border-radius: 8px;
    transition: box-shadow 0.3s, transform 0.2s;
}

.result-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.result-header {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.result-kicker {
    padding: 4px 8px;
    background: #007cba;
    color: white;
    font-size: 12px;
    font-weight: 600;
    border-radius: 4px;
    text-transform: uppercase;
}

.result-session {
    padding: 4px 8px;
    background: #28a745;
    color: white;
    font-size: 12px;
    font-weight: 600;
    border-radius: 4px;
}

.result-title {
    margin: 0 0 10px 0;
    font-size: 20px;
    color: #1a1a1a;
    line-height: 1.4;
}

.result-title mark {
    background: #fff3cd;
    padding: 2px 4px;
    border-radius: 3px;
}

.result-excerpt {
    margin: 0 0 15px 0;
    color: #495057;
    line-height: 1.6;
}

.result-excerpt mark {
    background: #fff3cd;
    padding: 2px 4px;
    border-radius: 3px;
}

.result-meta {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    font-size: 14px;
    color: #6c757d;
}

.result-date,
.result-author,
.result-category {
    display: flex;
    align-items: center;
    gap: 5px;
}

.empty-results {
    text-align: center;
    padding: 60px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 2px dashed #dee2e6;
}

.empty-icon {
    font-size: 48px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.empty-results h3 {
    margin: 0 0 10px 0;
    color: #495057;
}

.empty-results p {
    margin: 0;
    color: #6c757d;
}

/* ========== ADMIN PANEL STYLES ========== */

.admin-login {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    padding: 20px;
}

.login-card {
    width: 100%;
    max-width: 400px;
    padding: 40px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.login-card h2 {
    margin: 0 0 10px 0;
    color: #1a1a1a;
    font-size: 24px;
}

.login-card p {
    margin: 0 0 20px 0;
    color: #6c757d;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 15px;
}

.password-input {
    padding: 12px 16px;
    font-size: 16px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    outline: none;
}

.password-input:focus {
    border-color: #007cba;
    box-shadow: 0 0 0 3px rgba(0, 124, 186, 0.1);
}

.login-btn {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    background: #007cba;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s;
}

.login-btn:hover {
    background: #0056b3;
}

.login-hint {
    font-size: 14px;
    color: #6c757d;
    font-style: italic;
}

.admin-interface {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Arial', sans-serif;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: linear-gradient(135deg, #007cba, #0056b3);
    color: white;
    border-radius: 8px;
    margin-bottom: 20px;
}

.admin-header h2 {
    margin: 0;
    font-size: 24px;
}

.logout-btn {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    background: white;
    color: #007cba;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.3s;
}

.logout-btn:hover {
    background: #f8f9fa;
}

.admin-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.add-article-section,
.recent-articles-section,
.instructions-section {
    padding: 25px;
    background: white;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.add-article-section h3,
.recent-articles-section h3,
.instructions-section h3 {
    margin: 0 0 20px 0;
    font-size: 20px;
    color: #1a1a1a;
    border-bottom: 2px solid #007cba;
    padding-bottom: 10px;
}

.article-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #495057;
}

.required {
    color: #dc3545;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 10px 14px;
    font-size: 15px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-family: 'Arial', sans-serif;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #007cba;
    box-shadow: 0 0 0 3px rgba(0, 124, 186, 0.1);
}

.form-group textarea {
    resize: vertical;
    font-family: 'Georgia', serif;
    line-height: 1.6;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.form-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    padding-top: 10px;
    border-top: 1px solid #dee2e6;
}

.save-btn {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s;
}

.save-btn:hover {
    background: #218838;
}

.reset-btn {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s;
}

.reset-btn:hover {
    background: #5a6268;
}

.download-btn {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    background: #007cba;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s;
}

.download-btn:hover {
    background: #0056b3;
}

.articles-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.article-item {
    padding: 15px;
    background: #f8f9fa;
    border-left: 4px solid #007cba;
    border-radius: 6px;
}

.article-item h4 {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: #1a1a1a;
}

.article-meta {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    font-size: 14px;
    color: #6c757d;
}

.no-articles {
    text-align: center;
    padding: 30px;
    color: #6c757d;
    font-style: italic;
}

.instructions-section ul {
    margin: 0;
    padding-left: 20px;
    line-height: 1.8;
    color: #495057;
}

.instructions-section li {
    margin-bottom: 8px;
}

/* ========== RESPONSIVE DESIGN ========== */

@media (max-width: 768px) {
    .search-box {
        flex-direction: column;
    }

    .search-input {
        min-width: 100%;
    }

    .filter-controls {
        flex-direction: column;
    }

    .filter-select {
        width: 100%;
    }

    .admin-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
    }

    .save-btn,
    .reset-btn,
    .download-btn {
        width: 100%;
    }
}

/* ========== PRINT STYLES ========== */

@media print {
    .search-box,
    .filter-controls,
    .admin-header,
    .form-actions,
    .logout-btn {
        display: none;
    }

    .result-item,
    .article-item {
        page-break-inside: avoid;
    }
}
