/* Event Tracking System Public Styles */

.ets-thread-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.ets-thread-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #eee;
}

.ets-thread-title {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 28px;
}

.ets-thread-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
    color: #666;
    font-size: 14px;
}

.ets-thread-status {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
}

.ets-status-open {
    background: #d4edda;
    color: #155724;
}

.ets-status-closed {
    background: #f8d7da;
    color: #721c24;
}

.ets-thread-tags {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.ets-tag {
    background: #e8f4fd;
    color: #1e8cbe;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
}

.ets-thread-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}

.ets-thread-posts {
    margin: 30px 0;
}

.ets-post {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
    position: relative;
}

.ets-post:hover {
    border-color: #999;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.ets-post-label {
    position: absolute;
    top: 10px;
    right: 10px;
}

.ets-label-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    color: #fff;
    font-weight: bold;
}

.ets-post-header {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.ets-post-author {
    font-weight: bold;
    color: #333;
}

.ets-post-date {
    color: #666;
    font-size: 14px;
}

.ets-post-alias-badge {
    background: #f0f0f0;
    color: #666;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
}

.ets-post-content {
    line-height: 1.6;
    color: #333;
}

.ets-post-content p {
    margin: 0 0 15px 0;
}

.ets-post-content p:last-child {
    margin-bottom: 0;
}

.ets-post-content a {
    color: #0073aa;
    text-decoration: none;
}

.ets-post-content a:hover {
    text-decoration: underline;
}

.ets-post-content strong {
    font-weight: bold;
}

.ets-post-content em {
    font-style: italic;
}

.ets-post-content ul,
.ets-post-content ol {
    margin: 15px 0;
    padding-left: 30px;
}

.ets-video-embed {
    margin: 15px 0;
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
}

.ets-video-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.ets-image-embed {
    margin: 15px 0;
    text-align: center;
}

.ets-image-embed img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
}

.ets-post-footer {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 10px;
}

.ets-post-footer .button {
    padding: 5px 10px;
    font-size: 13px;
}

.ets-new-post-form {
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 20px;
    margin-top: 30px;
}

.ets-new-post-form h3 {
    margin: 0 0 15px 0;
    color: #333;
}

.ets-form-group {
    margin-bottom: 15px;
}

.ets-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.ets-form-group textarea,
.ets-form-group input[type="text"],
.ets-form-group input[type="email"],
.ets-form-group select {
    width: 100%;
    max-width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 14px;
    line-height: 1.5;
}

.ets-form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.ets-char-count {
    margin-top: 5px;
    font-size: 12px;
    color: #666;
}

.ets-char-count .ets-char-current {
    font-weight: bold;
}

.ets-char-count .ets-char-current.too-long {
    color: #dc3232;
}

.ets-form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

#ets-alias-fields {
    margin-top: 10px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

#ets-alias-fields input {
    flex: 1;
    min-width: 200px;
}

.ets-thread-closed {
    text-align: center;
    padding: 30px;
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-top: 30px;
    color: #666;
}

.ets-login-prompt {
    text-align: center;
    padding: 30px;
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-top: 30px;
}

.ets-login-prompt p {
    margin: 0 0 15px 0;
    color: #666;
}

/* Threads list */
.ets-threads-list {
    max-width: 1000px;
    margin: 0 auto;
}

.ets-threads-search {
    margin-bottom: 20px;
}

.ets-threads-search form {
    display: flex;
    gap: 10px;
}

.ets-threads-search input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.ets-thread-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 15px;
}

.ets-thread-item h3 {
    margin: 0 0 10px 0;
}

.ets-thread-item h3 a {
    color: #333;
    text-decoration: none;
}

.ets-thread-item h3 a:hover {
    color: #0073aa;
}

.ets-thread-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 10px;
    font-size: 14px;
    color: #666;
}

.ets-thread-excerpt {
    color: #666;
    line-height: 1.5;
}

.ets-pagination {
    text-align: center;
    margin: 30px 0;
    padding: 20px 0;
    border-top: 1px solid #eee;
}

/* Tag search */
.ets-tag-search {
    max-width: 600px;
    margin: 0 auto 30px;
}

.ets-tag-search-form {
    display: flex;
    gap: 10px;
}

.ets-tag-search-input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.ets-tag-search-results {
    margin-top: 20px;
}

.ets-tag-result-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 10px;
}

.ets-tag-result-item h4 {
    margin: 0 0 10px 0;
    color: #333;
}

.ets-thread-info a {
    color: #0073aa;
    text-decoration: none;
    font-weight: bold;
    display: block;
    margin-bottom: 5px;
}

.ets-thread-info a:hover {
    text-decoration: underline;
}

.ets-result-meta {
    display: flex;
    gap: 15px;
    margin-top: 10px;
    font-size: 14px;
    color: #666;
}

/* User posts */
.ets-user-posts {
    max-width: 800px;
    margin: 0 auto;
}

.ets-user-post-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 15px;
}

.ets-post-thread-info {
    margin-bottom: 10px;
    font-size: 14px;
}

.ets-post-thread-info strong {
    color: #333;
}

.ets-post-thread-info a {
    color: #0073aa;
    text-decoration: none;
}

.ets-post-thread-info a:hover {
    text-decoration: underline;
}

.ets-post-content {
    margin-bottom: 10px;
    line-height: 1.5;
    color: #666;
}

.ets-post-meta {
    font-size: 14px;
    color: #999;
}

/* Registration form */
.ets-registration-form {
    max-width: 500px;
    margin: 0 auto;
    padding: 30px;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.ets-registration-form h2 {
    margin: 0 0 20px 0;
    text-align: center;
    color: #333;
}

.ets-form-message {
    padding: 10px 15px;
    margin-bottom: 20px;
    border-radius: 3px;
    text-align: center;
}

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

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

.ets-terms {
    margin-top: 20px;
    padding: 15px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 3px;
    max-height: 200px;
    overflow-y: auto;
}

.ets-terms-content {
    font-size: 14px;
    line-height: 1.5;
    color: #666;
}

/* Responsive adjustments */
@media screen and (max-width: 768px) {
    .ets-thread-container,
    .ets-threads-list,
    .ets-user-posts {
        padding: 10px;
    }
    
    .ets-thread-title {
        font-size: 24px;
    }
    
    .ets-thread-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .ets-post-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .ets-post-footer {
        flex-wrap: wrap;
    }
    
    .ets-form-actions {
        flex-direction: column;
    }
    
    .ets-form-actions .button {
        width: 100%;
    }
    
    #ets-alias-fields {
        flex-direction: column;
    }
    
    #ets-alias-fields input {
        min-width: 100%;
    }
}