@import url('colors.css');




/* Title Container */


.title-container {
    margin-bottom: 20px;
    text-align: center;
}

.title-text {
    color: var(--title-text-color);
}

.subtitle-text {
    color: var(--text-primary);
}



/* Welcome Container */


.welcome-container {
    color: var(--text-primary);
    margin-bottom: 20px;
}


/* Content Container */


.content-container {
    margin-bottom: 20px;
    color: var(--text-primary);
}


.content-container h1,
.content-container h2,
.content-container h3,
.content-container h4 {
    color: var(--title-text-color);
}


/* Basic Text */


.header-text {
    color: var(--text-primary);
}

.basic-text {
    color: var(--text-primary);
}

.basic-link {
    color: var(--button-5-color);
    text-decoration: none;
}

.basic-link:hover {
    color: var(--button-5-color-hover);
    text-decoration: underline;
}




/* Item Display Styles */


.item-meta {
    color: var(--text-secondary);
    padding: 8px 12px;
    margin-bottom: 30px;
    font-size: 1.1em;
    border: 2px solid var(--panel-border-color);
    border-radius: 12px;
}

.item-top-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.item-meta-column {
    flex: 1;
}

.item-actions-column {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.item-content-wrapper {
    /* Remove the flex: 1 since it's now handled by item-meta-column */
}

.item.selected .item-meta {
    border-color: var(--checkbox-1-border-color);
}

.item-date {
    color: var(--text-muted);
    font-size: 0.8em;
}

.item-id {
    color: var(--text-muted);
    font-size: 0.8em;
    margin-right: 2px;
    font-weight: 500;
}

.item-author {
    font-weight: 600;
    color: var(--post-author-color);
}

.item-title {
    margin: 5px 0px;
    font-weight: 600;
    font-size: 1.1em;
    font-style: italic;
    color: var(--post-title-color);
}

.item-content {
    white-space: pre-line;
    color: var(--text-primary);
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Link styling within item content */
.item-content a {
    color: var(--button-5-color);
    text-decoration: none;
}

.item-content a:hover {
    /* color: var(--text-tertiary) !important; */
    background-color: var(--button-5-background-color-hover);
    text-decoration: underline;
}

.item-content a:visited {
    color: var(--button-5-color);
    text-decoration: none;
}

.item-content a:active {
    color: var(--text-tertiary);
    text-decoration: none;
}

.item {
    position: relative;
    padding-left: 20px;
    padding-right: 20px;
    border-right: 2px solid transparent;
}

.item:hover {
    border-right-color: var(--text-primary);
}


.item-validations {
    margin: 5px 0px;
    font-size: 0.9em;
    color: var(--text-secondary);
    display: block;
    width: 100%;
}


.item-reposts {
    margin: 5px 0px;
    font-size: 0.9em;
    color: var(--text-secondary);
    display: block;
    width: 100%;
}




/* Item Actions */


.item-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-direction: row;
    justify-content: flex-end;
}

.btn-parent {
    color: var(--parent-button-color);
    text-decoration: none;
    border: 2px solid var(--parent-button-border-color);
    border-radius: 12px;
    padding: 0px 4px;
    min-width: 20px;
    text-align: center;
    display: inline-block;
}

.btn-parent:hover {
    background-color: var(--parent-button-background-color-hover);
}

.btn-parent-hidden {
    visibility: hidden;
    opacity: 0;
}



/* Inline buttons used within the content block */


.content-inline-button {
    border: 2px solid var(--button-5-color);
    color: var(--button-5-color);
    display: inline-block;
    cursor: pointer;
    padding: 6px 10px;
    margin: 0;
    background-color: transparent;
    text-decoration: none;
    font-weight: bold;
    border-radius: 4px;
    font-family: inherit;
    font-size: inherit;
}

.content-inline-button:hover {
    background-color: var(--button-5-background-color-hover);
}

.content-inline-button:visited {
    background-color: transparent;
    color: var(--button-5-color);
}

.content-inline-button:disabled {
    border-color: var(--button-5-color-disabled);
    color: var(--button-5-color-disabled);
    cursor: not-allowed;
    opacity: 0.6;
    pointer-events: none;
}

.button-spacer {
    display: inline-block;
    width: 10px;
    height: 10px;
}

.button-default {
    display: block;
    margin-bottom: 20px;
}



/* Inline links used within the content block */


.content-inline-link {
    display: inline-block;
    border: none;
    padding: 4px 8px;
    color: var(--button-5-color);
    text-decoration: none;
    font-weight: bold;
    cursor: pointer;
    font-family: inherit;
    font-size: 16px;
    background-color: transparent;
    border-radius: 4px;
}

.content-inline-link:hover {
    background-color: var(--button-5-background-color-hover);
}

.content-inline-link:visited {
    color: var(--button-5-color);
}

.content-inline-link:disabled {
    cursor: not-allowed;
    color: var(--button-5-color-disabled);
    opacity: 0.6;
    pointer-events: none;
    background-color: transparent;
}




/* Reply Badge and Dropdown */


.reply-badge {
    background-color: var(--reply-button-background-color);
    color: var(--text-primary);
    border: 2px solid var(--reply-button-border-color);
    padding: 2px 6px;
    border-radius: 12px;
    font-size: 0.8em;
    cursor: pointer;
    position: relative;
    display: inline-block;
    min-width: 60px;
    text-align: center;
}

.reply-badge-hidden {
    visibility: hidden;
    opacity: 0;
}

.reply-placeholder {
    color: transparent;
    user-select: none;
}

.reply-badge:hover {
    background-color: var(--reply-button-background-color-hover);
}

.reply-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--background-color);
    border: 2px solid var(--reply-button-border-color);
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    min-width: 250px;
    max-width: 350px;
    z-index: 1000;
    display: none;
    margin-top: 4px;
}

.reply-dropdown.show {
    display: block;
}

.reply-item {
    padding: 8px 12px;
    border-bottom: 1px solid var(--panel-border-color);
    cursor: pointer;
}

.reply-item:last-child {
    border-bottom: none;
}

.reply-item:hover {
    background-color: var(--background-color-secondary);
}

.reply-author {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9em;
}

.reply-preview {
    color: var(--text-primary);
    font-size: 0.85em;
    margin-top: 2px;
}




/* Item List Specific Styles */


.item-content-section {
    margin-top: 10px;
    margin-bottom: 10px;
}

.item-content-section-border {
    border: 1px solid var(--panel-border-color);
    margin: 10px 0;
}


.item-actions {
    margin-left: 20px;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.item-checkbox {
    position: absolute;
    left: -10px;
    top: 0.2em;
    width: 20px;
    height: 20px;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    border: 3px solid var(--checkbox-1-border-color);
    border-radius: 50%;
    background: var(--checkbox-1-background-color);
    transition: all 0.2s ease;
}

.item-checkbox:checked {
    background: var(--checkbox-1-background-color-checked);
    border-color: var(--checkbox-1-border-color);
}

.item-checkbox:hover {
    border-color: var(--checkbox-1-border-color);
}

.item-checkbox:checked:hover {
    background: var(--checkbox-1-background-color-checked);
    border-color: var(--checkbox-1-border-color);
}





/* Messages */


.messages {
    margin-bottom: 20px;
}
.messages .alert {
    padding: 12px 16px;
    margin-bottom: 10px;
    border-radius: 4px;
    border: 1px solid transparent;
}
.messages .alert-error {
    background-color: var(--error-red);
    color: var(--error-text);
    border-color: var(--error-border);
}
.messages .alert-success {
    background-color: var(--success-green);
    color: var(--success-text);
    border-color: var(--success-border);
}
.messages .alert-warning {
    background-color: var(--warning-yellow);
    color: var(--warning-text);
    border-color: var(--warning-border);
}
.messages .alert-info {
    background-color: var(--info-blue);
    color: var(--info-text);
    border-color: var(--info-border);
}




/* Buttons */


.btn {
    background-color: var(--button-1-background-color);
    border: 1px solid var(--button-1-background-color);
    color: var(--button-1-text-color);

    display: inline-block;

    cursor: pointer;

    padding: 10px 20px;
    text-decoration: none;
    border-radius: 4px;
    margin: 10px 0px;
    font-size: 16px;
    font-family: inherit;
    box-sizing: border-box;
    line-height: 1.5;
}

.btn:hover {
    background-color: var(--button-1-background-color-hover);
    border-color: var(--button-1-background-color-hover);
    color: var(--button-1-text-color-hover);
}


.btn-secondary {
    background-color: var(--button-1b-background-color);
    border: 1px solid var(--button-1b-background-color);
    color: var(--button-1b-text-color);
}

.btn-secondary:hover {
    background-color: var(--button-1b-background-color-hover);
    color: var(--button-1b-text-color-hover);
    border-color: var(--button-1b-background-color-hover);
}




/* Hidden on desktop, shown on mobile */


.btn-mobile-only {
    display: none;
}

.back-to-top-container {
    display: none;  /* Hidden by default */
    margin-bottom: 15px;
}




/* Forum Stats */


.stats-list {
    margin: 20px 0;
    padding: 0;
    list-style: none;
}

.stats-item {
    display: flex;
    justify-content: space-between;
    margin: 0;
    padding: 4px 0;
    border-bottom: 2px solid var(--panel-border-color);
}

.stats-item:last-child {
    border-bottom: none;
}

.stats-label {
    font-weight: 600;
    color: var(--text-primary);
}

.stats-value {
    font-weight: 600;
    color: var(--text-primary);
}




/* Pages section */
/* We force the buttons to be on separate rows, aligned to the right */


.pages-section {
    margin-top: 0px;
    padding-top: 0px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}


.pages-section .content-inline-button {
    width: 50%; /* Half the width of the sidebar */
    text-align: center;
    justify-content: center;
    display: flex;
    align-items: center;
    box-sizing: border-box;
}




/* Settings */


.settings-section {
    margin-bottom: 0px;
}

.settings-section h3 {
    margin: 0 0 10px 0;
    font-size: 1em;
    color: var(--text-primary);
}

#rate-limit-status {
    font-weight: 600;
    color: var(--text-primary);
}




/* Page size controls */


.page-size-controls-sidebar {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    justify-content: flex-end;
}

.size-link-sidebar {
    background-color: var(--button-4-background-color);
    border: 2px solid var(--button-4-border-color);
    color: var(--button-4-text-color);

    display: inline-block;
    cursor: pointer;
    font-weight: bold;
    padding: 4px 8px;
    text-decoration: none;
    border-radius: 3px;
    font-size: 0.9em;
}

.size-link-sidebar:hover {
    background-color: var(--button-4-background-color-hover);
}

.size-link-sidebar:visited {
    background-color: var(--button-4-background-color);
    color: var(--button-4-text-color);
}

.size-link-sidebar.active {
    background-color: var(--button-4-background-color-active);
    color: var(--button-4-text-color-active);
    border-color: var(--button-4-background-color-active);
}




.actions-section {
    margin-top: 0px;
    padding-top: 0px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}


.actions-section .content-inline-button,
.actions-section .btn {
    width: 50%; /* Half the width of the sidebar */
    text-align: center;
    justify-content: center;
    display: flex;
    align-items: center;
    box-sizing: border-box;
}




/* Button Container */
/* Used for the top buttons on the home page */


.button-container {
    display: flex;
    flex-direction: row;
    gap: 10px;
    margin-bottom: 20px;
    width: fit-content;
}

.button-container .btn {
    margin-bottom: 0;
}




/* Topics Container */


.topics-container {
    margin: 20px 0;
}

.topics-list {
    margin-top: 10px;
}

.topic-item {
    margin: 5px 0;
}

.topic-item h4 {
    margin: 0;
    font-size: 1.1em;
    color: var(--text-primary);
}




/* Recent Posts Container */


.recent-posts-container {
    margin-top: 30px;
}

.recent-posts-container h2 {
    margin-bottom: 20px;
}




/* Form Styles */


.text-entry {
    margin-bottom: 20px;
}

.text-entry-label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    font-size: 20px;
}


.form-control, input, textarea, select {
    max-width: 100%;
    box-sizing: border-box;
}


.form-control {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 16px;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-blue);
}




/* Form-specific input styles */


#id_content {
    font-size: 18px !important;
    padding: 12px !important;
    height: auto !important;
}

#id_title {
    font-size: 18px !important;
    padding: 12px !important;
    height: auto !important;
}




/* Form Messages */


.error-message {
    color: var(--error-text);
    font-size: 0.9em;
    margin-top: 5px;
}

.help-text {
    font-size: 0.9em;
    color: var(--text-secondary);
    margin-top: 5px;
}

.form-errors {
    background-color: var(--error-red);
    color: var(--error-text);
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid var(--error-border);
}

/* Context Section */
.context-section {
    margin-bottom: 30px;
}

.context-title {
    font-size: 1.2em;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--text-primary);
}




/* Debug Info */


.debug-info {
    background-color: var(--secondary-gray-light);
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
    font-family: monospace;
    font-size: 0.9em;
    white-space: pre-wrap;
}




/* Button States */


.btn:disabled {
    background-color: var(--secondary-gray);
    cursor: not-allowed;
    opacity: 0.6;
}









/* Reply Button */


.btn-reply {
    background-color: var(--primary-green);
    color: var(--white);
    padding: 2px 4px;
    text-decoration: none;
    border-radius: 4px;
    margin-bottom: 0px;
    pointer-events: auto;
}

.btn-reply:hover {
    background-color: var(--primary-green-dark);
}




/* Pagination Styles */


.pagination {
    margin: 20px 0px;
}

.pagination form {
    display: inline;
    margin: 0;
}









/* Authentication Pages */
/* Register, Login, etc. */


.auth-page {
    line-height: 1.6;
    margin: 0;
    padding: 20px;
    background-color: var(--background-color);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.auth-container {
    max-width: 400px;
    width: 100%;
    background: var(--background-color);
    padding: 30px;
    border-radius: 8px;
}

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

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: var(--text-primary);
}

.form-control {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    box-sizing: border-box;
}

.auth-btn {
    width: 100%;
}

.error-message {
    color: var(--error-text);
    margin-bottom: 20px;
}

.register-link {
    text-align: center;
    margin-top: 20px;
}

.auth-page .form-group input {
    padding: 12px 16px;
    font-size: 16px;
    height: 48px;
    width: 100%;
    box-sizing: border-box;
}




/* Subscribe */


.centered-container {
    text-align: center;
    padding: 40px 20px;
}


.subscribe-info {
    background-color: var(--secondary-gray-light);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
}


.subscription-form {
    max-width: 500px;
    margin: 0 auto;
}


.subscribe-button-container {
    margin-top: 30px;
}


.subscribe-message {
    color: var(--text-primary);
    margin-top: 0px;
    padding-top: 0px;
}




/* Form Controls (if not already defined) */


.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 16px;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 2px rgba(0,123,255,0.25);
}

/* Form Messages */
.help-text {
    font-size: 0.9em;
    color: var(--text-secondary);
    margin-top: 5px;
}

.error-message {
    color: var(--error-text);
    font-size: 0.9em;
    margin-top: 5px;
}




/* Button Spacing */


.btn + .btn {
    margin-left: 10px;
}




/* Profile Settings */


.profile-settings .form-group {
    margin-bottom: 30px;
}


.profile-settings label {
    display: block;
    margin-bottom: 12px;
    font-weight: 600;
    font-size: 18px;
    color: var(--text-primary);
    line-height: 1.4;
}

.profile-settings input[type="url"] {
    width: 100%;
    padding: 18px 20px;
    font-size: 18px;
    line-height: 1.5;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--white);
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.profile-settings input[type="url"]:focus {
    outline: none;
    border-color: var(--primary-blue);
    background-color: var(--secondary-gray-light);
}

.profile-settings input[type="url"]:hover {
    border-color: var(--secondary-gray);
}

.profile-settings input[type="url"]::placeholder {
    color: var(--secondary-gray);
    font-size: 16px;
    font-style: italic;
}

.profile-settings .error-message {
    color: var(--error-text);
    font-size: 16px;
    margin-top: 10px;
    padding: 12px 16px;
    background-color: var(--error-red);
    border: 1px solid var(--error-border);
    border-radius: 6px;
    font-weight: 500;
}




.readonly-field {
    background-color: #f5f5f5;
    color: #666;
    cursor: not-allowed;
}

.readonly-field:focus {
    outline: none;
    border-color: #ccc;
    box-shadow: none;
}




/* Validation Styles */


.validations-section {
    margin-top: 20px;
    padding: 16px;
    background: var(--panel-bg-color);
}


.validations-title {
    margin: 0 0 16px 0;
    color: var(--text-secondary);
    font-size: 1em;
    display: flex;
    align-items: center;
    gap: 8px;
}


.validations-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}


.validation-item {
    padding: 3px 12px;
    background: var(--background-color);
    border: 2px solid var(--panel-border-color);
    border-radius: 8px;
}


.validation-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}


.validation-icon {
    color: var(--success-color, #28a745);
    font-weight: bold;
    font-size: 1.2em;
    flex: 2;
}


.validator-name {
    font-weight: 600;
    font-size: 0.9em;
    color: var(--text-secondary);
    flex: 5;
}


.validation-date {
    font-size: 0.9em;
    color: var(--text-secondary);
    flex-shrink: 0; /* Don't shrink */
    min-width: 140px; /* Fixed width for date */
    text-align: right; /* Right-align the date */
    font-family: 'Courier New', monospace; /* Monospace font */
}


.validation-notes {
    font-style: italic;
    color: var(--text-secondary);
    padding: 8px 0;
    border-top: 1px solid var(--border-color);
    margin-top: 8px;
}




/* Repost Styles */


.reposts-section {
    margin-top: 20px;
    padding: 16px;
    background: var(--panel-bg-color);
}


.reposts-title {
    margin: 0 0 16px 0;
    color: var(--text-secondary);
    font-size: 1em;
    display: flex;
    align-items: center;
}


.reposts-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}


.repost-item {
    padding: 3px 12px;
    background: var(--background-color);
    border: 2px solid var(--panel-border-color);
    border-radius: 8px;
    width: 100%;
}


.repost-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}


.repost-icon {
    color: var(--info-color, #17a2b8);
    font-weight: bold;
    font-size: 1.2em;
    flex: 1;
}


.platform-name {
    font-weight: 600;
    color: var(--text-secondary);
    flex: 1;
}


.republisher-name {
    font-size: 0.9em;
    color: var(--text-secondary);
}


.repost-link {
    font-size: 1.1em;
    flex: 3;
}


.repost-date {
    font-size: 0.9em;
    color: var(--text-secondary);
    flex-shrink: 0;
    min-width: 80px;
    text-align: right;
    font-family: 'Courier New', monospace;
}


.repost-notes {
    font-style: italic;
    color: var(--text-secondary);
    padding: 8px 0;
    border-top: 1px solid var(--border-color);
    margin-top: 8px;
}








