* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 30px;
    text-align: center;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

main {
    padding: 40px 30px;
}

.form-section {
    margin-bottom: 30px;
}

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

.form-group label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 1rem;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
}

.help-text {
    display: block;
    margin-top: 6px;
    font-size: 0.875rem;
    color: #666;
}

.btn-primary {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.loading {
    text-align: center;
    padding: 40px;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.results-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #e0e0e0;
}

.results-section h2 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.8rem;
}

.block-height-display {
    background: #f8f9fa;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #667eea;
}

.block-height-display strong {
    color: #667eea;
}

.balances-display {
    margin-top: 20px;
}

.balance-item {
    background: #f8f9fa;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid #e0e0e0;
}

.balance-item:hover {
    background: #f0f0f0;
}

.asset-info {
    flex: 1;
}

.asset-name {
    font-weight: 600;
    color: #333;
    font-size: 1.1rem;
}

.asset-denom {
    color: #666;
    font-size: 0.875rem;
    margin-top: 4px;
}

.balance-amount {
    font-weight: 700;
    color: #667eea;
    font-size: 1.2rem;
    text-align: right;
}

.error-section {
    background: #fee;
    border: 2px solid #fcc;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.error-section h3 {
    color: #c33;
    margin-bottom: 10px;
}

.error-section p {
    color: #600;
}

.info-section {
    background: #e8f4fd;
    border: 2px solid #7ab8e8;
    border-radius: 8px;
    padding: 15px 20px;
    margin-top: 20px;
    color: #1976d2;
    font-weight: 500;
}

.no-balances {
    text-align: center;
    padding: 40px;
    color: #666;
    font-size: 1.1rem;
}

footer {
    background: #f8f9fa;
    padding: 20px;
    text-align: center;
    color: #666;
    font-size: 0.9rem;
}

@media (max-width: 600px) {
    .container {
        border-radius: 0;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    main {
        padding: 30px 20px;
    }
    
    .balance-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .balance-amount {
        text-align: left;
        margin-top: 10px;
    }
}
