/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Hidden Admin Access Logo (bottom left) */
.admin-access-logo {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 40px;
    height: 40px;
    background: rgba(0, 255, 255, 0.1);
    border: 1px solid rgba(0, 255, 255, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    color: rgba(0, 255, 255, 0.6);
}

.admin-access-logo:hover {
    background: rgba(0, 255, 255, 0.2);
    border-color: rgba(0, 255, 255, 0.5);
    color: rgba(0, 255, 255, 1);
    transform: scale(1.1);
}

.admin-access-logo:active {
    transform: scale(0.95);
}

/* Write Button (bottom right) */
.write-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 12px 24px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.2) 0%, rgba(0, 170, 255, 0.2) 100%);
    border: 1px solid rgba(0, 212, 255, 0.5);
    border-radius: 12px;
    color: #00d4ff;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 12px rgba(0, 212, 255, 0.2);
}

.write-button:hover {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.3) 0%, rgba(0, 170, 255, 0.3) 100%);
    border-color: rgba(0, 212, 255, 0.8);
    color: #00ffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 212, 255, 0.3);
}

.write-button:active {
    transform: translateY(0);
}

.write-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Badge styles */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-success {
    background: rgba(76, 175, 80, 0.2);
    color: #4CAF50;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.badge-warning {
    background: rgba(255, 193, 7, 0.2);
    color: #FFC107;
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.stat-description {
    font-size: 12px;
    color: #888;
    margin-top: 8px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', sans-serif;
    background: #0f0f0f;
    background-image: linear-gradient(135deg, #0f0f0f 0%, #1a1a1a 100%);
    color: #ffffff;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 32px;
}

/* Header */
.header {
    background: rgba(15, 15, 15, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid #2a2a2a;
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 24px;
}

/* Online Status Indicator */
#onlineStatus {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', monospace;
}

.status-online {
    background: rgba(0, 255, 0, 0.1);
    border: 1px solid rgba(0, 255, 0, 0.3);
    color: #00ff00;
}

.status-offline {
    background: rgba(255, 0, 0, 0.1);
    border: 1px solid rgba(255, 0, 0, 0.3);
    color: #ff0000;
}

.logo {
    display: flex;
    align-items: center;
}

.logo h1 {
    display: none; /* Hide text, show logo instead */
}

.logo-image {
    height: auto;
    width: auto;
    max-height: 60px;
    filter: brightness(1.2);
    transition: all 0.3s ease;
    animation: logo-glow 3s ease-in-out infinite;
}

@keyframes logo-glow {
    0%, 100% {
        filter: brightness(1.2) drop-shadow(0 0 5px rgba(59, 130, 246, 0.5));
    }
    50% {
        filter: brightness(1.4) drop-shadow(0 0 15px rgba(59, 130, 246, 0.8));
    }
}

.logo:hover .logo-image {
    filter: brightness(1.5) drop-shadow(0 0 20px rgba(59, 130, 246, 1));
}

.nav {
    display: flex;
    gap: 24px;
}

.nav a {
    color: #888;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: color 0.2s;
}

.nav a.active {
    color: #00d4ff;
}

.nav a:hover {
    color: #00d4ff;
}

.search {
    position: relative;
    flex: 1;
    max-width: 500px;
}

.search input {
    width: 100%;
    padding: 12px 16px 12px 48px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search input:focus {
    outline: none;
    border-color: #00d4ff;
    box-shadow: 0 0 0 4px rgba(0, 212, 255, 0.1);
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: #666;
}

/* Stats Overview */
.stats-overview {
    padding: 48px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.stat-card {
    background: linear-gradient(135deg, #1a1a1a 0%, #252525 100%);
    border: 1px solid #2a2a2a;
    border-radius: 16px;
    padding: 32px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.stat-card:hover {
    border-color: #00d4ff;
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0, 212, 255, 0.15);
}

.stat-label {
    font-size: 13px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
    margin-bottom: 12px;
}

.stat-value {
    font-size: 36px;
    font-weight: 800;
    color: #00d4ff;
    letter-spacing: -0.03em;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', monospace;
}

/* Content */
.content {
    padding: 32px 0 80px;
}

.section-title {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 24px;
    color: #fff;
    letter-spacing: -0.5px;
}

.table-container {
    background: rgba(26, 26, 26, 0.8);
    border: 1px solid #2a2a2a;
    border-radius: 16px;
    overflow: hidden;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 20px 24px;
    text-align: left;
    border-bottom: 1px solid #2a2a2a;
}

.table th {
    background: transparent;
    color: #888;
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 2px solid #333;
}

.table td {
    color: #fff;
    font-size: 15px;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', monospace;
}

.table tr {
    transition: background 0.2s ease;
}

.table tr:hover {
    background: rgba(0, 212, 255, 0.05);
}

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

.hash-link {
    color: #00d4ff;
    text-decoration: none;
    transition: all 0.2s ease;
}

.hash-link:hover {
    color: #00b8e6;
    text-decoration: underline;
}

/* Loading */
.loading {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #666;
}

.loading::before {
    content: '';
    width: 20px;
    height: 20px;
    border: 3px solid #333;
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Block Details */
.block-details {
    background: rgba(26, 26, 26, 0.8);
    border: 1px solid #2a2a2a;
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 32px;
}

.detail-row {
    display: flex;
    padding: 16px 0;
    border-bottom: 1px solid #2a2a2a;
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-label {
    font-size: 13px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
    min-width: 200px;
}

.detail-value {
    flex: 1;
    font-size: 15px;
    color: #fff;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', monospace;
    word-break: break-all;
}

/* Navigation buttons */
.nav-buttons {
    display: flex;
    gap: 16px;
    margin-top: 24px;
}

.btn-secondary {
    padding: 12px 24px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    color: #fff;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    border-color: #00d4ff;
    background: #2a2a2a;
    color: #00d4ff;
}

/* Responsive */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .search {
        width: 100%;
        max-width: 100%;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .detail-row {
        flex-direction: column;
        gap: 8px;
    }
    
    .detail-label {
        min-width: auto;
    }
}
