/* General Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
}

a {
    color: #3498db;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Header Styles */
header {
    background-color: #2c3e50;
    color: white;
    padding: 30px 0;
    margin-bottom: 30px;
    text-align: center;
    border-radius: 5px;
    position: relative;
}

header h1 {
    margin-bottom: 10px;
}

/* User authentication */
.user-actions {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.auth-button {
    display: inline-block;
    padding: 8px 15px;
    background-color: #3498db;
    color: white;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
}

.auth-button:hover {
    background-color: #2980b9;
    text-decoration: none;
}

.logout-button {
    background-color: #e74c3c;
}

.logout-button:hover {
    background-color: #c0392b;
}

.admin-link {
    display: inline-block;
    padding: 8px 15px;
    background-color: #f39c12;
    color: white;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
}

.admin-link:hover {
    background-color: #d35400;
    text-decoration: none;
}

.user-info {
    font-size: 14px;
}

/* Flash messages */
.flash-message {
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 16px;
}

.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.warning {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Search Section */
.search-section {
    background-color: white;
    padding: 30px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 20px;
}

.form-row {
    display: flex;
    gap: 20px;
}

.form-group.half {
    width: 50%;
}

label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

input, select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

button {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #2980b9;
}

button:disabled {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

/* Results Section */
.results-section {
    background-color: white;
    padding: 30px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.results-section h2 {
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.no-results {
    text-align: center;
    color: #7f8c8d;
    padding: 20px;
}

.trial-card {
    border: 1px solid #eee;
    border-radius: 4px;
    padding: 20px;
    margin-bottom: 20px;
    transition: transform 0.2s;
}

.trial-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.trial-title {
    margin-bottom: 10px;
    color: #2c3e50;
}

.trial-details {
    margin-bottom: 15px;
    color: #7f8c8d;
}

.trial-location {
    font-style: italic;
    margin-bottom: 15px;
}

.view-details {
    display: inline-block;
    background-color: #2ecc71;
    color: white;
    padding: 8px 15px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
}

.view-details:hover {
    background-color: #27ae60;
    text-decoration: none;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
}

.pagination button {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    margin: 0 10px;
}

.pagination button:hover {
    background-color: #2980b9;
}

.pagination button:disabled {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

#page-info {
    font-size: 14px;
}

/* Footer */
footer {
    margin-top: 50px;
    background-color: #2c3e50;
    color: white;
    padding: 30px 0;
    text-align: center;
}

footer a {
    color: #3498db;
}

footer p {
    margin-bottom: 10px;
}

/* Responsive design */
@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .form-group.half {
        width: 100%;
    }
    
    .user-actions {
        position: relative;
        top: auto;
        right: auto;
        margin-top: 15px;
        justify-content: center;
    }
}

/* Trial detail page */
.trial-detail-container {
    background-color: white;
    padding: 30px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.trial-header {
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.trial-header h2 {
    margin-bottom: 10px;
    color: #2c3e50;
}

.trial-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
}

.meta-item {
    background-color: #f5f5f5;
    padding: 10px 15px;
    border-radius: 4px;
    font-size: 14px;
}

.meta-label {
    font-weight: bold;
    margin-right: 5px;
}

.trial-section {
    margin-bottom: 30px;
}

.trial-section h3 {
    margin-bottom: 10px;
    color: #2c3e50;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
}

.back-button {
    display: inline-block;
    background-color: #3498db;
    color: white;
    padding: 8px 15px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
    margin-top: 20px;
}

.back-button:hover {
    background-color: #2980b9;
    text-decoration: none;
}

/* Loading indicator */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

.loading-spinner {
    border: 5px solid #f3f3f3;
    border-top: 5px solid #3498db;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Gender Options */
.gender-options {
    display: flex;
    gap: 20px;
}

.gender-options label {
    display: flex;
    align-items: center;
    font-weight: normal;
    cursor: pointer;
}

.gender-options input[type="radio"] {
    width: auto;
    margin-right: 5px;
}

.trial-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 15px;
}

.view-details-btn {
    display: inline-block;
    background-color: #2ecc71;
    color: white;
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
    transition: background-color 0.3s;
}

.view-details-btn:hover {
    background-color: #27ae60;
    text-decoration: none;
} 