/* styles/more-tokens.css */

body {
    font-family: Arial, sans-serif;
    background-color: #121212;
    margin: 0;
    padding: 0;
    color: #fff;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Connection Status Indicator (specific to more-tokens page if needed, otherwise move to header.css or index.css) */
.connection-status {
    position: absolute;
    top: 10px;
    right: 20px;
    padding: 8px 16px;
    border: 2px solid #541767;
    border-radius: 20px;
    cursor: not-allowed;
    font-family: 'Comic Neue', cursive;
    font-size: 0.9em;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: transparent;
    color: #fff;
}

.connection-status.connected {
    background-color: #00ff7f;
    color: #121212;
    animation: pulse 1.5s infinite;
}

.connection-status.disconnected {
    background-color: #ff4d4d;
    color: #fff;
    animation: none;
}

.connection-status:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 10px rgba(255, 157, 0, 0.3);
}

/* Pulse animation for connected state */
@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.8; }
    100% { transform: scale(1); opacity: 1; }
}

main {
    padding: 2em;
    background-color: #121212;
    color: #fff;
    flex: 1;
}

/* Assuming More Tokens page has a token table similar to index.css */
.token-table-container {
    max-width: 1200px;
    margin: 1em auto;
    overflow-x: auto;
    background-color: #1a1a1a;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

.token-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background-color: #1a1a1a;
    font-size: 0.95em;
    table-layout: fixed;
}

.token-table th,
.token-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #2d2d2d;
    vertical-align: middle;
    color: #fff;
}

.token-table th {
    background: linear-gradient(135deg, #541767 0%, #022253 100%);
    color: white;
    font-weight: 600;
    position: sticky;
    top: 0;
    z-index: 20;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.token-table td {
    background-color: #1a1a1a;
    transition: background-color 0.2s ease;
}

.token-table tr:nth-child(even) td {
    background-color: #2d2d2d;
}

.token-table tr:hover td {
    background-color: #3d3d3d;
    cursor: pointer;
}

.token-table tr:last-child td {
    border-bottom: none;
}

/* Specific Column Widths for Better Layout */
.token-table th:first-child,
.token-table td:first-child { /* Token Name column */
    width: 20%;
    min-width: 150px;
}

.token-table th:nth-child(2),
.token-table td:nth-child(2) { /* Total Supply */
    width: 15%;
}

.token-table th:nth-child(3),
.token-table td:nth-child(3) { /* Holders */
    width: 10%;
}

.token-table th:nth-child(4),
.token-table td:nth-child(4) { /* Issuer Address */
    width: 25%;
    word-break: break-word;
    max-width: 250px;
}

.token-table th:nth-child(5),
.token-table td:nth-child(5) { /* XRP in Issuer Wallet */
    width: 15%;
}

.token-table th:nth-child(6),
.token-table td:nth-child(6) { /* XRP Value (USD) */
    width: 15%;
}

/* Sortable Token Name Column */
#token-name-header {
    position: relative;
    padding-right: 25px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#token-name-header:hover {
    background: linear-gradient(135deg, #431257 0%, #011c43 100%);
}

#token-name-arrow {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    transition: transform 0.3s ease;
    color: #fff;
}

#token-name-header:hover #token-name-arrow {
    transform: translateY(-50%) scale(1.2);
}

/* Sortable XRP Value Column */
#xrp-value-header {
    position: relative;
    padding-right: 25px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#xrp-value-header:hover {
    background: linear-gradient(135deg, #431257 0%, #011c43 100%);
}

#xrp-value-arrow {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    transition: transform 0.3s ease;
    color: #fff;
}

#xrp-value-header:hover #xrp-value-arrow {
    transform: translateY(-50%) scale(1.2);
}

/* Search Container Styles */
.search-container {
    max-width: 1200px;
    margin: 1em auto;
    text-align: center;
}

#token-search {
    width: 100%;
    max-width: 400px;
    padding: 0.8em;
    font-size: 1em;
    border: 1px solid #541767;
    border-radius: 4px;
    box-sizing: border-box;
    background-color: #1a1a1a;
    color: #fff;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

#token-search:focus {
    border-color: #ff9d00;
    outline: none;
    box-shadow: 0 0 5px rgba(255, 157, 0, 0.3);
}

#token-search::placeholder {
    color: #999;
}

.token-link {
    color: #ff9d00;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.token-link:hover {
    color: #ff9d00;
    text-decoration: underline;
}

/* Style for hidden rows */
.hidden-row {
    display: none;
}

footer {
    background: linear-gradient(90deg, #541767 0%, #022253 100%);
    color: #fff;
    text-align: center;
    padding: 1em 0;
    width: 100%;
}

.footer-links {
    margin-top: 0.5em;
}

.footer-links a {
    color: #ff9d00;
    text-decoration: none;
    font-size: 0.9em;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #e68c00;
    text-decoration: underline;
}

/* Media queries for mobile responsiveness */
@media (max-width: 768px) {
    main {
        padding: 1em;
    }

    .token-table-container {
        margin: 1em 0;
    }

    .token-table th,
    .token-table td {
        padding: 8px 10px;
    }

    .token-table th:first-child,
    .token-table td:first-child {
        min-width: 100px;
    }

    .token-table th:nth-child(4),
    .token-table td:nth-child(4) {
        max-width: 200px;
    }

    #token-search {
        max-width: 300px;
        padding: 0.6em;
    }
}

@media (max-width: 600px) {
    .token-table-container {
        margin: 0.5em 0;
        border-radius: 0;
    }

    .token-table {
        font-size: 0.85em;
        display: block;
        overflow-x: auto;
    }

    .token-table th,
    .token-table td {
        padding: 6px 8px;
        white-space: nowrap;
    }

    .token-table th:first-child,
    .token-table td:first-child {
        min-width: 120px;
        width: 25%;
    }

    .token-table th:nth-child(2),
    .token-table td:nth-child(2) {
        width: 15%;
        min-width: 80px;
    }

    .token-table th:nth-child(3),
    .token-table td:nth-child(3) {
        width: 10%;
        min-width: 60px;
    }

    .token-table th:nth-child(4),
    .token-table td:nth-child(4) {
        width: 30%;
        min-width: 150px;
        max-width: 200px;
        word-break: break-all;
        overflow-wrap: break-word;
        white-space: normal;
    }

    .token-table th:nth-child(5),
    .token-table td:nth-child(5) {
        width: 10%;
        min-width: 80px;
    }

    .token-table th:nth-child(6),
    .token-table td:nth-child(6) {
        width: 10%;
        min-width: 80px;
    }

    .token-table th {
        position: sticky;
        top: 0;
        z-index: 20;
    }

    #token-search {
        max-width: 250px;
        font-size: 0.9em;
    }

    .footer-links {
        display: flex;
        flex-direction: column;
        gap: 0.5em;
    }
}