/* Enhanced fish-public-29.css - All conflicts resolved and dynamic colors implemented */

/* Chat Message Styles */
#fish_custom_chat_box {
    background: #F7F7F7;
}

#fish_custom_chat_box .fish_message_form_wrapper {
    position: relative;
    font-weight: 400;
    line-height: 1.25em;
    letter-spacing: 0.025em;
    color: #333;
    padding: 0 1rem 1rem !important;
}

#fish_custom_chat_box #fish_message_input {
    border: 2px solid var(--fish-primary, #333333);
    width: 100%;
    height: 48px;
    background-image: none;
    background-color: white;
    padding: 15px;
    border-radius: 1.125rem;
    flex-grow: 2;
}

#fish_custom_chat_box #fish_message_send {
    position: absolute;
    right: 1rem;
    background: var(--fish-primary, #333333);
    border: 0;
    color: var(--fish-primary-text, white);
    height: 48px;
    top: 0;
    bottom: 0;
    width: 80px;
    border-radius: 0px 1.125rem 1.125rem 0px;
    cursor: pointer;
}

#fish_custom_chat_box .fish_messages_wrapper h2 {
    font-size: 18px !important;
    margin: 5px 0 16px !important;
    padding: 0 !important;
    color: #333 !important;
}

#fish_custom_chat_box .fish_messages_wrapper {
    max-height: 500px;
    overflow-y: auto;
    padding: 1rem;
    flex-shrink: 2;
}

#fish_custom_chat_box .fish_chat_message {
    margin-bottom: 10px;
}

#fish_custom_chat_box .fish_message_content {
    border-radius: 5px;
    padding: 10px;
    max-width: 80%;
    display: inline-block;
    box-sizing: border-box;
    padding: 0.5rem 1rem;
    background: #FFF;
    border-radius: 1.125rem 1.125rem 1.125rem 0;
    max-width: 66%;
    text-transform: none;
    box-shadow: 0 0 2rem rgba(0, 0, 0, 0.075), 0rem 1rem 1rem -1rem rgba(0, 0, 0, 0.1);
}

#fish_custom_chat_box .fish_message_time {
    font-size: 0.8em;
    color: #333;
    margin-top: 2px;
}

#fish_custom_chat_box .fish_chat_message.fish_right {
    text-align: right;
}

#fish_custom_chat_box .fish_chat_message.fish_right .fish_message_content {
    border-radius: 1.125rem 1.125rem 0 1.125rem;
    background: var(--fish-primary, #333) !important;
    color: var(--fish-primary-text, white);
}

#fish_custom_chat_box .fish_chat_message.fish_left {
    text-align: left;
    color: #333333 !important;
}

/* Main Wrapper Styles */
.fish_public_files_wrapper {
    min-height: 100vh;
    margin: auto;
}

.dt-layout-cell.dt-layout-full {
    overflow: auto;
}

.dt-layout-row,
#fish-files-table-2_info,
#fish-files-table_info {
    color: #333;
}

.fish_public_files_wrapper .fish_message_heading {
    font-size: 17px;
    color: #333;
    margin-bottom: 20px;
    font-weight: bold;
    text-transform: initial;
}

.fish_empty_files {
    text-align: center;
}

#fish_upload_wrapper {
    border-bottom: 1px solid #ddd;
    margin-bottom: 40px;
}

body .fish_upload_heading h2 {
    color: var(--fish-primary, #333) !important;
    font-size: 26px;
    padding: unset;
}

body #fish-files-table_wrapper,
body #fish-files-table-2_wrapper {
    border-bottom: 1px solid #ddd;
    margin-bottom: 40px;
    padding-bottom: 40px;
    margin-top: 10px;
}

body #fish-files-table_wrapper {
    border: unset !important;
    margin: unset !important;
}

/* Main Form Wrapper */
#fish-upload-form {
    font-family: 'Raleway', sans-serif;
    margin: 20px auto;
    padding: 30px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background-color: #ffffff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 50px;
}

/* File Upload Section */
.fish-file-upload {
    margin-bottom: 20px;
    position: relative;
    border: 2px dashed var(--fish-primary, #80C24A);
    padding: 25px;
    border-radius: 6px;
    text-align: center;
    background-color: var(--fish-accent, #f8f9fa);
}

.fish-file-upload label {
    display: block;
    font-size: 16px;
    color: var(--fish-secondary-text, #333);
    margin-bottom: 10px;
    margin-top: 15px;
}

#fish-file-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

#fish-file-list {
    margin-top: 15px;
    font-size: 14px;
    color: #666;
}

/* Message Field Section */
.fish-message-field {
    margin-bottom: 20px;
}

.fish-message-field label {
    display: block;
    margin-bottom: 8px;
    font-size: 16px;
    color: var(--fish-secondary-text, #333);
}

#fish-upload-form textarea {
    width: 100%;
    height: 120px;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 16px;
}

/* Button Styles */
#fish-upload-form button {
    background-color: var(--fish-primary, #80C24A);
    color: var(--fish-primary-text, #ffffff);
    border: none;
    padding: 12px 25px;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#fish-upload-form button:hover {
    background-color: var(--fish-hover, #88c05a);
}

/* DataTable Override - Nuclear Option */
.dataTables_paginate .paginate_button,
.dataTables_paginate .paginate_button *,
.dataTables_paginate .paginate_button span {
    color: var(--fish-primary, #80C24A) !important;
}

.dataTables_paginate .paginate_button:hover,
.dataTables_paginate .paginate_button:hover * {
    color: var(--fish-primary-text, #ffffff) !important;
    background: var(--fish-primary, #80C24A) !important;
}

/* DataTable Styles */
.fish-files-table {
    width: 100%;
    color: #333333;
    border-collapse: collapse;
    margin-top: 20px;
}

.fish-files-table thead th {
    background-color: var(--fish-table-header, #80C24A);
    color: var(--fish-table-header-text, #ffffff);
    padding: 10px;
    text-align: left;
    border: 1px solid #ddd;
}

.fish-files-table tbody td {
    padding: 10px;
    border: 1px solid #ddd;
    vertical-align: top;
}

.fish-files-table tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}

.fish-files-table tbody tr:hover {
    background-color: #e0e0e0;
}

.fish-files-table .copy-link-button {
    background-color: var(--fish-primary, #80C24A);
    color: var(--fish-primary-text, #ffffff);
    border: none;
    transition: .3s;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    font-size: 14px;
}

.fish-files-table_wrapper {
    color: #333;
    margin-top: 15px;
}

.fish-files-table .copy-link-button:hover {
    background-color: var(--fish-hover, #333333);
}

#fish-files-table-2_length select,
#fish-files-table_length select {
    width: 70px;
}

#fish-files-table-2_length,
#fish-files-table-2_filter,
#fish-files-table_length,
#fish-files-table_filter {
    margin-bottom: 10px;
    color: #333333;
}

.fish-files-table thead th {
    color: var(--fish-table-header-text, white) !important;
}

#fish-files-table_paginate,
#fish-files-table-2_paginate {
    color: #333;
}

.fish_form_success {
    color: var(--fish-primary, #80C24A);
    background-color: var(--fish-accent, #f8f9fa);
    font-size: 20px;
    margin-bottom: 10px;
    font-weight: bold;
    padding: 10px;
    border-radius: 4px;
    border: 1px solid var(--fish-primary, #80C24A);
}

/* File Preview Styles */
#fish-files-preview li {
    display: flex;
    flex-direction: row-reverse;
    width: fit-content;
    gap: 10px;
    word-wrap: anywhere;
    white-space: wrap;
    align-items: baseline;
}

#fish_user,
#fish_message {
    width: 100%;
}

#fish-files-preview ul {
    padding: 0;
}

#fish-post-title-by-user,
#fish-post-title {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 16px;
}

.fish_download_file {
    background: white;
    border: 1px solid gray;
    border-radius: 3px;
    width: 20px;
    vertical-align: middle;
    height: 20px;
}

.fish_remove_file.remove-file {
    background: white;
    border: 1px solid gray;
    border-radius: 3px;
}

/* Enhanced Audio Player Styles */
.fish-modern-audio-player {
    background: var(--fish-accent, #f8f9fa);
    border: 1px solid var(--fish-primary, #e9ecef);
    border-radius: 8px;
    padding: 15px;
    margin: 10px 0;
    max-width: 400px;
}

.fish-audio-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.fish-play-btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background-color: var(--fish-primary, #80C24A);
    color: var(--fish-primary-text, white);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

.fish-play-btn:hover {
    background-color: var(--fish-hover, #6fa83a);
}

.fish-audio-info {
    flex: 1;
}

.fish-audio-title {
    font-weight: bold;
    font-size: 14px;
    margin-bottom: 2px;
    color: var(--fish-secondary-text, #333);
}

.fish-audio-time {
    font-size: 12px;
    color: #666;
}

.fish-volume-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.fish-progress-container {
    position: relative;
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    cursor: pointer;
}

.fish-progress-bar {
    height: 100%;
    border-radius: 3px;
    width: 0%;
    position: relative;
    transition: width 0.1s;
    background-color: var(--fish-primary, #80C24A);
}

.fish-progress-handle {
    position: absolute;
    right: -6px;
    top: -3px;
    width: 12px;
    height: 12px;
    background: var(--fish-primary, #80C24A);
    border-radius: 50%;
    cursor: pointer;
}

/* Responsive Design */
@media screen and (max-width: 640px) {
    #fish-files-table-2_wrapper .dataTables_filter,
    #fish-files-table-2_wrapper .dataTables_length,
    #fish-files-table_wrapper .dataTables_length,
    #fish-files-table_wrapper .dataTables_filter {
        text-align: left;
    }

    .fish-modern-audio-player {
        max-width: 100%;
    }

    #fish-upload-form {
        margin: 10px;
        padding: 20px;
    }
}

/* NUCLEAR OPTION - Force pagination text colors */
.dataTables_wrapper .dataTables_paginate .paginate_button,
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
table.dataTable + .dataTables_wrapper .dataTables_paginate .paginate_button,
div.dataTables_wrapper div.dataTables_paginate .paginate_button,
.fish-files-table_wrapper .dataTables_paginate .paginate_button,
#fish-files-table_wrapper .dataTables_paginate .paginate_button,
#fish-files-table-2_wrapper .dataTables_paginate .paginate_button {
    color: #FF6600 !important;
    background: #f0f0f0 !important;
    border: 1px solid #FF6600 !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button:hover,
.fish-files-table_wrapper .dataTables_paginate .paginate_button:hover,
#fish-files-table_wrapper .dataTables_paginate .paginate_button:hover,
#fish-files-table-2_wrapper .dataTables_paginate .paginate_button:hover {
    color: white !important;
    background: #FF6600 !important;
}

/* Target everything inside pagination buttons */
.dataTables_paginate .paginate_button *,
.dataTables_paginate .paginate_button span,
.dataTables_paginate .paginate_button a {
    color: inherit !important;
}