/* Estilos para Durable Objects Inspector & Modal */
.do-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 99999;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.do-modal-overlay.open {
    display: flex;
}

.do-modal-container {
    width: 100%;
    max-width: 980px;
    height: 85vh;
    max-height: 720px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #cbd5e1;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Geist Sans', sans-serif;
    color: #0f172a;
}

.do-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.do-modal-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
}

.do-title-icon {
    color: #0284c7;
}

.do-close-btn {
    background: transparent;
    border: none;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    color: #64748b;
    padding: 0 4px;
    transition: color 0.15s ease;
}

.do-close-btn:hover {
    color: #0f172a;
}

.do-modal-body {
    display: grid;
    grid-template-columns: 280px 1fr;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.do-sidebar {
    background: #f8fafc;
    border-right: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    padding: 14px;
    overflow-y: auto;
    gap: 14px;
}

.do-sidebar-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #475569;
}

.do-mini-btn {
    background: #e2e8f0;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    padding: 2px 6px;
    color: #334155;
}

.do-mini-btn:hover {
    background: #cbd5e1;
}

.do-namespaces-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
}

.do-ns-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.do-ns-title {
    font-size: 12px;
    color: #1e293b;
    padding: 2px 0;
}

.do-ns-class {
    font-size: 10.5px;
    color: #64748b;
}

.do-actors-sublist {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding-left: 6px;
}

.do-actor-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 8px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.do-actor-item:hover {
    border-color: #0284c7;
    background: #f0f9ff;
    transform: translateX(2px);
}

.do-actor-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #10b981;
    flex-shrink: 0;
}

.do-actor-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-family: 'Geist Mono', monospace;
    font-weight: 500;
}

.do-actor-keys {
    font-size: 10px;
    background: #e2e8f0;
    padding: 1px 5px;
    border-radius: 4px;
    color: #475569;
}

.do-create-actor-box {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.do-field-label {
    font-size: 11px;
    font-weight: 700;
    color: #334155;
    text-transform: uppercase;
}

.do-input-select, .do-input-text {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #cbd5e1;
    border-radius: 5px;
    font-size: 12px;
    box-sizing: border-box;
    font-family: inherit;
}

.do-btn-primary {
    background: #0284c7;
    color: #ffffff;
    border: none;
    padding: 7px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease;
}

.do-btn-primary:hover {
    background: #0369a1;
}

.do-content-panel {
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow-y: auto;
    background: #ffffff;
}

.do-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    flex: 1;
    color: #64748b;
    gap: 8px;
    padding: 40px;
}

.do-empty-icon {
    font-size: 40px;
    color: #0284c7;
}

.do-inspector-view {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.do-actor-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 12px;
}

.do-actor-headline h2 {
    margin: 0 0 4px 0;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.do-tag {
    font-size: 11px;
    background: #e0f2fe;
    color: #0369a1;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 600;
}

.do-actor-id-code {
    font-size: 11px;
    color: #64748b;
}

.do-actor-id-code code {
    background: #f1f5f9;
    padding: 2px 4px;
    border-radius: 4px;
    font-family: 'Geist Mono', monospace;
}

.do-actor-actions {
    display: flex;
    gap: 8px;
}

.do-action-btn {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 5px;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
}

.do-action-btn:hover {
    background: #e2e8f0;
}

.do-metrics-bar {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.do-metric-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
}

.do-metric-num {
    font-size: 20px;
    font-weight: 800;
    color: #0f172a;
}

.do-metric-lbl {
    font-size: 11px;
    color: #64748b;
}

.do-section-title {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-top: 4px;
}

.do-kv-table-container {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    max-height: 240px;
    overflow-y: auto;
}

.do-kv-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.do-kv-table th {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    text-align: left;
    padding: 8px 12px;
    color: #475569;
    font-weight: 600;
}

.do-kv-table td {
    padding: 8px 12px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: top;
}

.do-val-pre {
    margin: 0;
    font-family: 'Geist Mono', monospace;
    font-size: 11.5px;
    max-height: 80px;
    overflow-y: auto;
    background: #f8fafc;
    padding: 4px 6px;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
}

.do-del-btn {
    background: #fee2e2;
    color: #b91c1c;
    border: none;
    border-radius: 4px;
    padding: 3px 8px;
    cursor: pointer;
    font-weight: 700;
    font-size: 11px;
}

.do-del-btn:hover {
    background: #fecaca;
}

.do-empty-kv {
    padding: 20px;
    text-align: center;
    color: #94a3b8;
    font-size: 12px;
}

.do-rpc-tester {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.do-rpc-tester .do-input-text {
    flex: 1;
    min-width: 180px;
}

.do-rpc-result {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 10px;
    font-size: 12px;
}

.do-rpc-result pre {
    margin: 4px 0 0 0;
    font-family: 'Geist Mono', monospace;
    font-size: 11.5px;
}
