:root {
    --primary-color: #00ff9d;
    --primary-dark: #00cc7d;
    --background-dark: #121212;
    --card-background: #1e1e1e;
    --header-background: #2a2a2a;
    --text-light: #ffffff;
    --text-muted: #888888;
    --success-color: #4caf50;
    --warning-color: #ff9800;
    --danger-color: #f44336;
    --border-color: #333333;
    --shadow-color: rgba(0, 0, 0, 0.2);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--background-dark);
    color: var(--text-light);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    transition: background-color 0.3s ease;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px 0;
    border-bottom: 1px solid var(--border-color);
    animation: fadeIn 1s ease-in-out;
}

.header h1 {
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(0, 255, 157, 0.3);
}

.header .subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.input-container {
    background-color: var(--card-background);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px var(--shadow-color);
    margin-bottom: 30px;
    animation: slideDown 0.5s ease-in-out;
}

.warning-text {
    color: var(--danger-color);
    font-size: 0.8rem;
    font-weight: bold;
    margin-top: 5px;
    text-align: left;
    position: absolute;
    bottom: -20px;
    left: 0;
}

.input-group {
    display: flex;
    margin-bottom: 20px; /* Increased from 10px to accommodate warning text */
    width: 100%;
    position: relative; /* Added to position the warning text */
}

input {
    flex: 1;
    padding: 15px;
    border: none;
    border-radius: 8px 0 0 8px;
    background-color: var(--header-background);
    color: var(--text-light);
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.1);
}

input:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-color);
}

button {
    padding: 15px 25px;
    background-color: var(--primary-color);
    color: var(--background-dark);
    border: none;
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    font-weight: bold;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

button:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

button:active {
    transform: translateY(0);
}

/* Loader styles */
.loader-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 50px 0;
    animation: fadeIn 0.5s ease-in-out;
}

.loader {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    position: relative;
    background: linear-gradient(45deg, transparent, transparent 40%, var(--primary-color));
    animation: rotate 1.5s linear infinite;
}

.loader-inner {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background-color: var(--background-dark);
    position: absolute;
    top: 5px;
    left: 5px;
}

.loading-text {
    margin-top: 20px;
    color: var(--primary-color);
    font-size: 1.2rem;
    font-weight: bold;
    animation: pulse 1.5s infinite;
}

.error {
    background-color: rgba(244, 67, 54, 0.1);
    color: var(--danger-color);
    padding: 15px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: center;
    border-left: 4px solid var(--danger-color);
    animation: slideIn 0.3s ease-in-out;
}

.chain-info {
    background-color: var(--card-background);
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px var(--shadow-color);
    animation: fadeIn 0.8s ease-in-out;
}

.chain-info h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.info-item {
    display: flex;
    flex-direction: column;
    background-color: var(--header-background);
    padding: 15px;
    border-radius: 8px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.info-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

.info-label {
    color: var(--primary-color);
    font-weight: bold;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-value {
    font-family: 'Courier New', monospace;
    font-size: 1.2rem;
    background-color: rgba(0, 0, 0, 0.2);
    padding: 8px;
    border-radius: 4px;
    word-break: break-all;
}

.table-container {
    background-color: var(--card-background);
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px var(--shadow-color);
    animation: slideUp 0.8s ease-in-out;
}

.table-container h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.table-wrapper {
    max-height: 70vh;
    overflow-y: auto;
    border-radius: 8px;
}

table {
    width: 100%;
    border-collapse: collapse;
    background-color: var(--card-background);
}

th, td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    background-color: var(--header-background);
    color: var(--primary-color);
    position: sticky;
    top: 0;
    z-index: 10;
}

tr:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.moniker-cell {
    font-weight: bold;
    color: var(--primary-color);
}

.address-cell {
    font-family: monospace;
    font-size: 0.9em;
    word-break: break-all;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.timestamp {
    text-align: center;
    color: var(--text-muted);
    margin-top: 20px;
    font-size: 0.9rem;
}

.footer {
    text-align: center;
    margin-top: 50px;
    padding: 20px 0;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideDown {
    from { transform: translateY(-20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateX(-20px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

/* Responsive design */
@media (max-width: 768px) {
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    .input-group {
        flex-direction: column;
    }
    
    input {
        border-radius: 8px 8px 0 0;
    }
    
    button {
        border-radius: 0 0 8px 8px;
    }
    
    .table-wrapper {
        overflow-x: auto;
    }
    
    table {
        min-width: 1000px;
    }
}

/* Status colors */
.status-bonded {
    color: var(--success-color);
    font-weight: bold;
}

.status-unbonded {
    color: var(--danger-color);
    font-weight: bold;
}

.status-unbonding {
    color: var(--warning-color);
    font-weight: bold;
}

.uptime-high {
    color: var(--success-color);
    font-weight: bold;
}

.uptime-medium {
    color: var(--warning-color);
    font-weight: bold;
}

.uptime-low {
    color: var(--danger-color);
    font-weight: bold;
}

.jailed {
    background-color: rgba(244, 67, 54, 0.1);
}

@keyframes blink {
    0% { opacity: 0.4; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.2); }
    100% { opacity: 0.4; transform: scale(0.8); }
}

@keyframes glow {
    0% { text-shadow: 0 0 5px rgba(255, 255, 255, 0.1); }
    50% { text-shadow: 0 0 15px rgba(255, 255, 255, 0.5); }
    100% { text-shadow: 0 0 5px rgba(255, 255, 255, 0.1); }
}

.status-emoji {
    display: inline-block;
    font-size: 1.2em;
}

.status-bonded .status-emoji {
    animation: blink 2s infinite, glow 2s infinite;
    color: var(--success-color);
}

.status-unbonded .status-emoji {
    animation: blink 1.5s infinite, glow 1.5s infinite;
    color: var(--danger-color);
}

.status-unbonding .status-emoji {
    animation: blink 2.5s infinite, glow 2.5s infinite;
    color: var(--warning-color);
}

.jail-emoji {
    display: inline-block;
    animation: blink 2s infinite;
}

.tombstone-emoji {
    display: inline-block;
    animation: blink 2.2s infinite;
}